<?php

namespace app\admin\controller;

use think\Lang;
class Mbfeedback extends AdminControl
{
    public function _initialize()
    {
        parent::_initialize(); // TODO: Change the autogenerated stub
        Lang::load(APP_PATH . 'admin/lang/zh-cn/mobile.lang.php');
    }
    /**
     * 意见反馈
     */
    public function flist(){
        $model_mb_feedback = Model('mbfeedback');
        $list = $model_mb_feedback->getMbFeedbackList(array(), 10);

       $this->assign('list', $list);
       $this->assign('page', $model_mb_feedback->page_info->render());
       $this->setAdminCurItem('index');
       return $this->fetch('index');
    }

    /**
     * 删除
     */
    public function del(){
        $model_mb_feedback = Model('mbfeedback');
        $result = $model_mb_feedback->delMbFeedback($_POST['feedback_id']);
        if ($result){
            $this->success(lang('ds_common_op_succ'));
        }else {
            $this->error(lang('ds_common_op_fail'));
        }
    }
    protected function getAdminItemList()
    {
        $menu=array(
            array(
            'text'=>lang('feedback_mange_title'),'name'=>'index','url'=>''
        ),
    );
        return $menu;
    }
}