123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687 |
- <?php
- namespace app\api\controller;
- use think\facade\Lang;
- class Memberconsult extends MobileMember {
- public function initialize() {
- parent::initialize();
- Lang::load(base_path() . 'home/lang/' . config('lang.default_lang') . '/sellerconsult.lang.php');
- }
-
- public function index() {
- $this->my_consult();
- }
- public function my_consult() {
-
- $consult_model = model('consult');
- $search_array = array();
- if (input('param.type') != '') {
- if (input('param.type') == 'to_reply') {
- $search_array[] = array('consult_reply', '=', '');
- }
- if (input('param.type') == 'replied') {
- $search_array[] = array('consult_reply', '<>', '');
- }
- }
- $search_array[] = array('member_id', '=', $this->member_info['member_id']);
- $list_consult = $consult_model->getConsultList($search_array);
-
- $consult_type = rkcache('consulttype', true);
- $result = array_merge(array('consult_list' => $list_consult, 'consult_type' => $consult_type), mobile_page($consult_model->page_info));
- ds_json_encode(10000, '', $result);
- }
- }
|