Taxzhengzhou.php 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643
  1. <?php defined('BASEPATH') OR exit('No direct script access allowed');
  2. class Taxzhengzhou extends Start_Controller {
  3. public function __construct(){
  4. parent::__construct();
  5. $this->load->library('session');
  6. $this->load->_model('Model_taxzhengzhou','taxzhengzhou');
  7. $this->load->_model('Model_taxzhengzhousk','taxzhengzhousk');
  8. $this->load->_model('Model_taxzhengzhoush','taxzhengzhoush');
  9. $this->load->_model('Model_fullorder','fullorder');
  10. $this->load->_model('Model_fullordertt','fullordertt');
  11. $this->load->_model('Model_fullordersmt','fullordersmt');
  12. }
  13. //定义方法的调用规则 获取URI第二段值
  14. public function _remap($arg,$arg_array)
  15. {
  16. if($arg == 'add')//添加
  17. {
  18. $this->_add();
  19. }
  20. else if($arg == 'edit')//修改
  21. {
  22. $this->_edit($arg_array);
  23. }
  24. else if($arg == 'skadd')//添加
  25. {
  26. $this->_skadd();
  27. }
  28. else if($arg == 'skedit')//修改
  29. {
  30. $this->_skedit($arg_array);
  31. }
  32. else if($arg == 'sk')//修改
  33. {
  34. $this->_sk($arg_array);
  35. }
  36. else if($arg == 'addsh')//添加
  37. {
  38. $this->_addsh($arg_array);
  39. }
  40. else if($arg == 'sh')//添加
  41. {
  42. $this->_sh($arg_array);
  43. }
  44. else if($arg == 'shlist')//添加
  45. {
  46. $this->_shlist($arg_array);
  47. }
  48. else if($arg == 'wc')//添加
  49. {
  50. $this->_wc($arg_array);
  51. }
  52. else if($arg == 'drexcel')//添加
  53. {
  54. $this->_drexcel($arg_array);
  55. }
  56. else if($arg == 'ding')//添加
  57. {
  58. $this->_ding($arg_array);
  59. }
  60. else
  61. {
  62. $this->_index();
  63. }
  64. }
  65. //管理
  66. public function _index()
  67. {
  68. $post = $this->input->post(NULL, TRUE);
  69. if(isset($post['page']))
  70. {
  71. $page = $this->input->post('page',true);
  72. $perpage = $this->input->post('perpage',true);
  73. $continent = $this->input->post('continent',true);
  74. $express = $this->input->post('express',true);
  75. $ename = $this->input->post('ename',true);
  76. $zname = $this->input->post('zname',true);
  77. $where = "1=1 ";
  78. if($continent)
  79. {
  80. $where .= " and continent = '$continent'";
  81. }
  82. if($express)
  83. {
  84. $where .= " and express = '$express'";
  85. }
  86. if($ename)
  87. {
  88. $where .= " and ename = '$ename'";
  89. }
  90. if($zname)
  91. {
  92. $where .= " and zname = '$zname'";
  93. }
  94. //数据排序
  95. $order_str = "id asc";
  96. if(empty($page))
  97. {
  98. $start = 0;
  99. $perpage = 1;
  100. }
  101. else
  102. {
  103. $start = ($page - 1)*$perpage;
  104. }
  105. //取得信息列表
  106. $info_list = $this->taxzhengzhou->find_all($where,'id,orderno,apptype,batchnumber,packno,goodsvalue,insuredFee,ht,itemno,iedate,createtime,accountingdate,sh',$order_str,$start,$perpage);
  107. foreach ($info_list as $key=>$value)
  108. {
  109. if($value['apptype'] == '1')
  110. {
  111. $info_list[$key]['apptype'] = '新增';
  112. }
  113. else if($value['apptype'] == '2')
  114. {
  115. $info_list[$key]['apptype'] = '变更';
  116. }
  117. else if($value['apptype'] == '3')
  118. {
  119. $info_list[$key]['apptype'] = '删除';
  120. }
  121. if($value['sh'] == '0')
  122. {
  123. $info_list[$key]['sh'] = '待审核';
  124. }
  125. else if($value['sh'] == '1')
  126. {
  127. $info_list[$key]['sh'] = '不通过';
  128. }
  129. else if($value['sh'] == '2')
  130. {
  131. $info_list[$key]['sh'] = '通过';
  132. }
  133. if($value['sh'] != 2)
  134. {
  135. $info_list[$key]['orderno'] = "<h9 class='windowtwo' data-h='/taxzhengzhou/edit/".$value['id']."' data-t='订单管理' data-h2='/taxzhengzhou/shlist/".$value['id']."' data-t2='审核详情'><p>".$value['orderno']."</p></h9>";
  136. }
  137. else
  138. {
  139. $info_list[$key]['orderno'] = "<h9 class='windowtwo' data-h='/taxzhengzhou/wc/".$value['id']."' data-t='订单管理' data-h2='/taxzhengzhou/shlist/".$value['id']."' data-t2='审核详情'><p>".$value['orderno']."</p></h9>";
  140. }
  141. $info_list[$key]['iedate'] = date('Y-m-d',$value['iedate']);
  142. $info_list[$key]['createtime'] = date('Y-m-d h:i:s',$value['createtime']);
  143. $info_list[$key]['accountingdate'] = date('Y-m-d h:i:s',$value['accountingdate']);
  144. }
  145. $total = $this->taxzhengzhou->find_count($where);
  146. $pagenum = ceil($total/$perpage);
  147. $over = $total-($start+$perpage);
  148. $rows = array('total'=>$total,'over'=>$over,'pagenum'=>$pagenum,'rows'=>($info_list));
  149. echo json_encode($rows);exit;
  150. }
  151. $this->_Template('tax_zhengzhou',$this->data);
  152. }
  153. //添加
  154. public function _add()
  155. {
  156. $post = $this->input->post(NULL, TRUE);
  157. if(isset($post['apptype']))
  158. {
  159. $createtime = $this->input->post('createtime',true);
  160. $post['createtime'] = strtotime($createtime);
  161. $iedate = $this->input->post('iedate',true);
  162. $post['iedate'] = strtotime($iedate);
  163. $accountingdate = $this->input->post('accountingdate',true);
  164. $post['accountingdate'] = strtotime($accountingdate);
  165. if($this->taxzhengzhou->insert($post))
  166. {
  167. echo json_encode(array('msg'=>'添加成功','success'=>true));exit;
  168. }
  169. else
  170. {
  171. echo json_encode(array('msg'=>'添加失败,请重试','success'=>false));exit;
  172. }
  173. }
  174. $this->_Template('tax_zhengzhou_add',$this->data);
  175. }
  176. //修改
  177. public function _edit($arg_array)
  178. {
  179. $post = $this->input->post(NULL, TRUE);
  180. if(isset($post['id']))
  181. {
  182. $id = $this->input->post('id',true);
  183. $post['sh'] = 0;
  184. $createtime = $this->input->post('createtime',true);
  185. $post['createtime'] = strtotime($createtime);
  186. $iedate = $this->input->post('iedate',true);
  187. $post['iedate'] = strtotime($iedate);
  188. $accountingdate = $this->input->post('accountingdate',true);
  189. $post['accountingdate'] = strtotime($accountingdate);
  190. if($this->taxzhengzhou->save($post,$id))
  191. {
  192. echo json_encode(array('msg'=>'修改成功','success'=>true));exit;
  193. }
  194. else
  195. {
  196. echo json_encode(array('msg'=>'修改失败,请重试','success'=>false));exit;
  197. }
  198. }
  199. $arg_array = $arg_array[0];
  200. $taxzhengzhou = $this->taxzhengzhou->read($arg_array);
  201. $this->data['taxzhengzhou'] = $taxzhengzhou;
  202. $this->_Template('tax_zhengzhou_edit',$this->data);
  203. }
  204. public function _sk()
  205. {
  206. $post = $this->input->post(NULL, TRUE);
  207. if(isset($post['page']))
  208. {
  209. $page = $this->input->post('page',true);
  210. $perpage = $this->input->post('perpage',true);
  211. $continent = $this->input->post('continent',true);
  212. $express = $this->input->post('express',true);
  213. $ename = $this->input->post('ename',true);
  214. $zname = $this->input->post('zname',true);
  215. $where = "1=1 ";
  216. if($continent)
  217. {
  218. $where .= " and continent = '$continent'";
  219. }
  220. if($express)
  221. {
  222. $where .= " and express = '$express'";
  223. }
  224. if($ename)
  225. {
  226. $where .= " and ename = '$ename'";
  227. }
  228. if($zname)
  229. {
  230. $where .= " and zname = '$zname'";
  231. }
  232. //数据排序
  233. $order_str = "id asc";
  234. if(empty($page))
  235. {
  236. $start = 0;
  237. $perpage = 1;
  238. }
  239. else
  240. {
  241. $start = ($page - 1)*$perpage;
  242. }
  243. //取得信息列表
  244. $info_list = $this->taxzhengzhousk->find_all($where,'id,orderno,charge,accountingdate',$order_str,$start,$perpage);
  245. foreach ($info_list as $key=>$value)
  246. {
  247. $info_list[$key]['accountingdate'] = date('Y-m-d h:i:s',$value['accountingdate']);
  248. }
  249. $total = $this->taxzhengzhousk->find_count($where);
  250. $pagenum = ceil($total/$perpage);
  251. $over = $total-($start+$perpage);
  252. $rows = array('total'=>$total,'over'=>$over,'pagenum'=>$pagenum,'rows'=>($info_list));
  253. echo json_encode($rows);exit;
  254. }
  255. $this->_Template('tax_zhengzhou_sk',$this->data);
  256. }
  257. //添加
  258. public function _skadd()
  259. {
  260. $post = $this->input->post(NULL, TRUE);
  261. if(isset($post['apptype']))
  262. {
  263. $createtime = $this->input->post('createtime',true);
  264. $post['createtime'] = strtotime($createtime);
  265. $accountingdate = $this->input->post('accountingdate',true);
  266. $post['accountingdate'] = strtotime($accountingdate);
  267. if($this->taxzhengzhousk->insert($post))
  268. {
  269. echo json_encode(array('msg'=>'添加成功','success'=>true));exit;
  270. }
  271. else
  272. {
  273. echo json_encode(array('msg'=>'添加失败,请重试','success'=>false));exit;
  274. }
  275. }
  276. $this->_Template('tax_zhengzhou_sk_add',$this->data);
  277. }
  278. //修改
  279. public function _skedit($arg_array)
  280. {
  281. $post = $this->input->post(NULL, TRUE);
  282. if(isset($post['id']))
  283. {
  284. $id = $this->input->post('id',true);
  285. $createtime = $this->input->post('createtime',true);
  286. $post['createtime'] = strtotime($createtime);
  287. $accountingdate = $this->input->post('accountingdate',true);
  288. $post['accountingdate'] = strtotime($accountingdate);
  289. if($this->taxzhengzhousk->save($post,$id))
  290. {
  291. echo json_encode(array('msg'=>'修改成功','success'=>true));exit;
  292. }
  293. else
  294. {
  295. echo json_encode(array('msg'=>'修改失败,请重试','success'=>false));exit;
  296. }
  297. }
  298. $arg_array = $arg_array[0];
  299. $taxzhengzhousk = $this->taxzhengzhousk->read($arg_array);
  300. $this->data['taxzhengzhousk'] = $taxzhengzhousk;
  301. $this->_Template('tax_zhengzhou_sk_edit',$this->data);
  302. }
  303. public function _addsh($arg_array)
  304. {
  305. $post = $this->input->post(NULL, TRUE);
  306. if(isset($post['uid']))
  307. {
  308. $this->db->trans_begin();
  309. $id = $this->input->post('uid',true);
  310. $this->taxzhengzhou->save(array('sh'=>$post['sh']),$id);
  311. $post['time'] = time();
  312. $this->taxzhengzhoush->insert($post);
  313. if ($this->db->trans_status() === TRUE)
  314. {
  315. $this->db->trans_commit();
  316. echo json_encode(array('msg'=>'提交成功','success'=>true));exit;
  317. }
  318. else
  319. {
  320. $this->db->trans_rollback();
  321. echo json_encode(array('msg'=>'提交失败,请重试','success'=>false));exit;
  322. }
  323. }
  324. $arg_array = $arg_array[0];
  325. $taxzhengzhou = $this->taxzhengzhou->read($arg_array);
  326. $this->data['taxzhengzhou'] = $taxzhengzhou;
  327. $this->_Template('tax_zhengzhou_addsh',$this->data);
  328. }
  329. public function _wc($arg_array)
  330. {
  331. $post = $this->input->post(NULL, TRUE);
  332. $arg_array = $arg_array[0];
  333. $taxzhengzhou = $this->taxzhengzhou->read($arg_array);
  334. $this->data['taxzhengzhou'] = $taxzhengzhou;
  335. $this->_Template('tax_zhengzhou_wc',$this->data);
  336. }
  337. public function _sh($arg_array)
  338. {
  339. $post = $this->input->post(NULL, TRUE);
  340. if(isset($post['page']))
  341. {
  342. $page = $this->input->post('page',true);
  343. $perpage = $this->input->post('perpage',true);
  344. $continent = $this->input->post('continent',true);
  345. $express = $this->input->post('express',true);
  346. $ename = $this->input->post('ename',true);
  347. $zname = $this->input->post('zname',true);
  348. $where = "sh=0 ";
  349. if($continent)
  350. {
  351. $where .= " and continent = '$continent'";
  352. }
  353. if($express)
  354. {
  355. $where .= " and express = '$express'";
  356. }
  357. if($ename)
  358. {
  359. $where .= " and ename = '$ename'";
  360. }
  361. if($zname)
  362. {
  363. $where .= " and zname = '$zname'";
  364. }
  365. //数据排序
  366. $order_str = "id asc";
  367. if(empty($page))
  368. {
  369. $start = 0;
  370. $perpage = 1;
  371. }
  372. else
  373. {
  374. $start = ($page - 1)*$perpage;
  375. }
  376. //取得信息列表
  377. $info_list = $this->taxzhengzhou->find_all($where,'id,orderno,apptype,batchnumber,packno,goodsvalue,insuredFee,payno,itemno,iedate,createtime,accountingdate',$order_str,$start,$perpage);
  378. foreach ($info_list as $key=>$value)
  379. {
  380. if($value['apptype'] == '1')
  381. {
  382. $info_list[$key]['apptype'] = '新增';
  383. }
  384. else if($value['apptype'] == '2')
  385. {
  386. $info_list[$key]['apptype'] = '变更';
  387. }
  388. else if($value['apptype'] == '3')
  389. {
  390. $info_list[$key]['apptype'] = '删除';
  391. }
  392. $info_list[$key]['iedate'] = date('Y-m-d',$value['iedate']);
  393. $info_list[$key]['createtime'] = date('Y-m-d h:i:s',$value['createtime']);
  394. $info_list[$key]['accountingdate'] = date('Y-m-d h:i:s',$value['accountingdate']);
  395. }
  396. $total = $this->taxzhengzhou->find_count($where);
  397. $pagenum = ceil($total/$perpage);
  398. $over = $total-($start+$perpage);
  399. $rows = array('total'=>$total,'over'=>$over,'pagenum'=>$pagenum,'rows'=>($info_list));
  400. echo json_encode($rows);exit;
  401. }
  402. $this->_Template('tax_zhengzhou_sh',$this->data);
  403. }
  404. public function _shlist($arg_array)
  405. {
  406. $where = "uid = '".$arg_array[0]."'";
  407. $info_list = $this->taxzhengzhoush->find_all($where,'title,shname,time,sh','id desc');
  408. foreach ($info_list as $key=>$value)
  409. {
  410. if($value['sh'] == 2)
  411. {
  412. $info_list[$key]['title'] = '审核通过';
  413. }
  414. $info_list[$key]['time'] = date('Y-m-d h:i',$value['time']);
  415. }
  416. $this->data['data'] = $info_list;
  417. $this->_Template('tax_zhengzhou_shlist',$this->data);
  418. }
  419. public function _drexcel($arg_array)
  420. {
  421. $dir = '/data/excel/'.date('Ymd',time()).'/';
  422. $config['upload_path'] = '.'.$dir ;
  423. $config['file_name'] = date('Ymd_His_',time()).rand(1000,9999);
  424. $config['allowed_types'] = 'xls|xlsx|csv';
  425. $config['max_size'] = 10240;
  426. $this->load->library('upload', $config);
  427. $this->upload->initialize($config);
  428. if ($this->upload->do_upload('userfile'))
  429. {
  430. $full_path = $dir.$this->upload->data('file_name');
  431. $fileName = '.' . $full_path;
  432. if (!file_exists($fileName))
  433. {
  434. echo json_encode(array('msg'=>"上传失败,请重试",'success'=>false));exit;
  435. }
  436. else
  437. {
  438. libxml_use_internal_errors(true);
  439. require_once "./data/excel/PHPExcel/IOFactory.php";
  440. $phpExcel = PHPExcel_IOFactory::load($fileName);// 载入当前文件
  441. $phpExcel->setActiveSheetIndex(0);// 设置为默认表
  442. $sheetCount = $phpExcel->getSheetCount();// 获取表格数量
  443. $row = $phpExcel->getActiveSheet()->getHighestRow();// 获取行数
  444. $column = $phpExcel->getActiveSheet()->getHighestColumn();// 获取列数
  445. ++$column;//如果列数大于26行
  446. $list = array();
  447. for ($i = 2; $i <= $row; $i++) // 行数循环
  448. {
  449. $data = array();
  450. for ($c = 'A'; $c != $column; $c++) // 列数循环
  451. {
  452. $data[] = $phpExcel->getActiveSheet()->getCell($c . $i)->getValue();
  453. }
  454. $list[] = $data;
  455. }
  456. }
  457. $i = 0;$j = 0;$ed = array();$dn = '';$ds = 'get_number';
  458. foreach ($list as $key=>$value)
  459. {
  460. if($value[0] == '')
  461. {
  462. continue;
  463. }
  464. if($value[0] == '订单号')
  465. {
  466. $dn = 0;
  467. $ds = 'get_orderinfo';
  468. continue;
  469. }
  470. else if ($value[0] == '序号')
  471. {
  472. $dn = 19;
  473. continue;
  474. }
  475. else
  476. {
  477. $dlz = $this->fullorder->$ds($value[0]);
  478. $smt = $this->fullordersmt->$ds($value[0]);
  479. $dlz2 = $this->fullorder->$ds($value[9]);
  480. $smt2 = $this->fullordersmt->$ds($value[9]);
  481. if($dlz || $smt)
  482. {
  483. $dn = 0;
  484. }
  485. if($dlz2 || $smt2)
  486. {
  487. $dn = 9;
  488. }
  489. }
  490. $dgs = 'fullorder';
  491. $dd = $this->fullorder->$ds($value[$dn]);
  492. if(!$dd)
  493. {
  494. $dd = $this->fullordersmt->$ds($value[$dn]);
  495. $dgs = 'fullordersmt';
  496. }
  497. if(!$dd)
  498. {
  499. $ed[] = $value[$dn];
  500. $j++;
  501. }
  502. else
  503. {
  504. $this->$dgs->save(array('gw'=>$arg_array[0]),$dd['id']);
  505. $i++;
  506. }
  507. }
  508. if($j > 0)
  509. {
  510. $tt = date('Ymd',time());
  511. $title = '无法识别信息-'.$tt;
  512. $titlename = "<table border=1><tr><td>错误详情</td></tr></table>";
  513. $tail = "\n";
  514. $filename = $title.".xls";
  515. $ecl = $this->excel->get_fz3($ed,$titlename,$filename,$tail);
  516. $dir = '/data/excel/'.$time.'/';
  517. $file_name = 'error_'.$time.rand(1000,9999);
  518. if(!is_dir('.'.$dir))mkdir('.'.$dir,0777);
  519. $myfile = fopen(".".$dir.$file_name.".xls", "w") or die();
  520. fwrite($myfile,$ecl);
  521. fclose($myfile);
  522. $error = $dir.$file_name.'.xls';
  523. echo json_encode(array('msg'=>'导入成功,'.$j.'条异常,','error'=>$error,'success'=>true));exit;
  524. }
  525. else
  526. {
  527. echo json_encode(array('msg'=>'导入成功!共导入'.$i.'条','error'=>1,'success'=>true));exit;
  528. }
  529. }
  530. }
  531. public function _ding()
  532. {
  533. $post = $this->input->post(NULL, TRUE);
  534. if(isset($_SESSION['api']))
  535. {
  536. $user = $this->user->get_api($_SESSION['api']);
  537. $usp = $user;
  538. $fgshop = "";$sid = "";$wid="";$wtype="";
  539. $usersp = explode('|',trim($user['shop'],'|'));
  540. $userwh = explode('|',trim($user['warehouse'],'|'));
  541. foreach ($usersp as $value)
  542. {
  543. $fgshop .= " shop = ".$value." or";
  544. $sid .= " id = ".$value." or";
  545. }
  546. foreach ($userwh as $value)
  547. {
  548. $wid .= " id = ".$value." or";
  549. $wtype .= " type = ".$value." or";
  550. }
  551. }
  552. if(isset($post['page']))
  553. {
  554. $page = $this->input->post('page',true);
  555. $perpage = $this->input->post('perpage',true);
  556. $ht = $this->input->post('ht',true);
  557. $orderno = $this->input->post('orderno',true);
  558. $timetk = $this->input->post('timetk',true);
  559. $timetj = $this->input->post('timetj',true);
  560. $timetk = strtotime($timetk);
  561. $timetj = strtotime($timetj);
  562. $where = "gw != 0 and dtime > '$timetk' and dtime < '$timetj'";;
  563. if($ht)
  564. {
  565. $tax = $this->taxzhengzhou->get_ht($ht);
  566. $where .= " and gw = '".$tax['id']."'";
  567. }
  568. if($orderno)
  569. {
  570. $tax = $this->taxzhengzhou->get_orderno($orderno);
  571. $where .= " and gw = '".$tax['id']."'";
  572. }
  573. //数据排序
  574. $order_str = "dtime desc";
  575. if(empty($page))
  576. {
  577. $start = 0;
  578. $perpage = 1;
  579. }
  580. else
  581. {
  582. $start = ($page - 1)*$perpage;
  583. }
  584. $info_list = array();
  585. $info_listsmt = array();
  586. $dlz = 0; $smt = 0;
  587. //取得信息列表
  588. $info_list = $this->fullorder->find_all($where,'id,orderinfo,number,name,dtime,waybill',$order_str,$start,$perpage);
  589. //格式化数据
  590. foreach ($info_list as $key=>$value)
  591. {
  592. $info_list[$key]['dtime'] = date('Y-m-d H:i:s',$value['dtime']);
  593. $info_list[$key]['orderinfo'] = "<h9 class='window' data-h='/finance/product/dlz/".$value['id']."' data-t='订单号:".$value['orderinfo']."'><p>".$value['orderinfo']."</p></h9>";
  594. }
  595. $dlz += $this->fullorder->find_count($where);
  596. $info_listsmt = $this->fullordersmt->find_all($where,'id,orderinfo,number,name,dtime,waybill',$order_str,$start,$perpage);
  597. //格式化数据
  598. foreach ($info_listsmt as $key=>$value)
  599. {
  600. $info_listsmt[$key]['dtime'] = date('Y-m-d H:i:s',$value['dtime']);
  601. $info_listsmt[$key]['orderinfo'] = "<h9 class='window' data-h='/finance/product/smt/".$value['id']."' data-t='订单号:".$value['orderinfo']."'><p>".$value['orderinfo']."</p></h9>";
  602. }
  603. $smt += $this->fullordersmt->find_count($where);
  604. //$total += $this->fullorder_smt->find_count($where);
  605. $total = $dlz+$smt;
  606. $rows = array_merge($info_list,$info_listsmt);
  607. //$rows = array_slice($rows,$start,$perpage);
  608. $pagenum = ceil($total/$perpage);
  609. $over = $total-($start+$perpage);
  610. $tmp = array();
  611. foreach ($rows as $key => $val)
  612. {
  613. $tmp[$key] = $val['dtime'];
  614. }
  615. array_multisort($tmp,SORT_DESC,$rows);
  616. $rows = array('total'=>$total,'over'=>$over,'pagenum'=>$pagenum,'rows'=>($rows),'cs'=>$where);//array_merge($info_list,$info_list_smt,$info_listsmt)
  617. echo json_encode($rows);exit;
  618. }
  619. $this->_Template('tax_zhengzhou_ding',$this->data);
  620. }
  621. public function _ck()
  622. {
  623. }
  624. }