作者 徐治堂

项目后台完成

  1 +<?php
  2 +/**
  3 + * Created by PhpStorm.
  4 + * User: wz
  5 + * Date: 2018/7/4
  6 + * Time: 17:23
  7 + */
  8 +
  9 +namespace app\admin\controller;
  10 +
  11 +
  12 +use app\admin\model\ZjOrderModel;
  13 +use cmf\controller\AdminBaseController;
  14 +use think\Db;
  15 +
  16 +class DataStatiController extends AdminBaseController
  17 +{
  18 + public function index()
  19 + {
  20 + $where=[];
  21 + $where1=[];
  22 +
  23 + $date=date('Y-m-d');
  24 + $date1=date('Y-m-d',strtotime('+1 day'));
  25 + $time=strtotime($date);
  26 + $time1=strtotime($date1);
  27 + $where['create_time']=['egt',$time];
  28 + $where1['create_time']=['lt',$time1];
  29 + $order=new ZjOrderModel();
  30 + $num['0']=$order->orderNum($where,$where1);
  31 + $price['0']=$order->priceNum($where,$where1);
  32 +
  33 + $data=date('w')-1;
  34 + $data1=8-date('w');
  35 + $date= date('Y-m-d',strtotime("-$data day"));
  36 + $date1=date('Y-m-d',strtotime("+$data1 day"));
  37 + $time=strtotime($date);
  38 + $time1=strtotime($date1);
  39 + $where['create_time']=['egt',$time];
  40 + $where1['create_time']=['lt',$time1];
  41 + $order=new ZjOrderModel();
  42 + $num['1']=$order->orderNum($where,$where1);
  43 + $price['1']=$order->priceNum($where,$where1);
  44 +
  45 +
  46 + $data=date('m')+1;
  47 + $date=date('Y-m-1');
  48 + if ($data=='13'){
  49 + $data=$date('Y')+1;
  50 + $date1=date("$data-1-1");
  51 + }else{
  52 + $date1=date("Y-$data-1");
  53 + }
  54 + $time=strtotime($date);
  55 + $time1=strtotime($date1);
  56 + $where['create_time']=['egt',$time];
  57 + $where1['create_time']=['lt',$time1];
  58 + $order=new ZjOrderModel();
  59 + $num['2']=$order->orderNum($where,$where1);
  60 + $price['2']=$order->priceNum($where,$where1);
  61 +
  62 + $this->assign('num',$num);
  63 + $this->assign('price',$price);
  64 + return $this->fetch();
  65 + }
  66 +}
1 -<?php  
2 -/**  
3 - * Created by PhpStorm.  
4 - * User: wz  
5 - * Date: 2018/7/4  
6 - * Time: 16:42  
7 - */  
8 -  
9 -namespace app\admin\controller;  
10 -  
11 -  
12 -use cmf\controller\AdminBaseController;  
13 -  
14 -class ZjComment extends AdminBaseController  
15 -{  
16 -  
17 -}  
  1 +<?php
  2 +/**
  3 + * Created by PhpStorm.
  4 + * User: wz
  5 + * Date: 2018/7/4
  6 + * Time: 16:42
  7 + */
  8 +
  9 +namespace app\admin\controller;
  10 +
  11 +
  12 +use ClassesWithParents\D;
  13 +use cmf\controller\AdminBaseController;
  14 +use think\Db;
  15 +
  16 +class ZjCommentController extends AdminBaseController
  17 +{
  18 + /**
  19 + * 评论管理首页
  20 + */
  21 + public function index()
  22 + {
  23 + $where=[];
  24 + if ($this->request->isPost()){
  25 + $in=input('post.');
  26 + if (strlen($in['ser_type'])>'0'){
  27 + $where['s.ser_type']=$in['ser_type'];
  28 + }
  29 + if (strlen($in['name'])>'0'){
  30 + $where['s.id']=$in['name'];
  31 + }
  32 + if (strlen($in['level'])>'0'){
  33 + $where['c.level']=$in['level'];
  34 + }
  35 + }
  36 + $com=Db::name('zj_comment')->alias('c')->join('user u','c.user_id=u.id')->join('zj_service s','c.service_id=s.id')->field('c.*,u.user_nickname as uname')->where($where)->paginate('10');
  37 + $service=Db::name('zj_service')->field('id,name,ser_type')->select();//查询服务名称 联动筛选
  38 +
  39 + $this->assign('allservice',$service);
  40 + $this->assign('allcom',$com);
  41 + return $this->fetch();
  42 + }
  43 +
  44 + /**
  45 + * 评论显示与隐藏
  46 + */
  47 + public function comstate()
  48 + {
  49 + $param=$this->request->param();
  50 + if ($param){
  51 + $id=$this->request->param('ids/a');
  52 + if ($param['yes']=='1'){
  53 + $com=Db::name('zj_comment')->where(['id'=>['in',$id]])->update(['is_sta'=>'1']);
  54 + }else{
  55 + $com=Db::name('zj_comment')->where(['id'=>['in',$id]])->update(['is_sta'=>'0']);
  56 + }
  57 + if ($com){
  58 + $this->success('评论可见度修改成功','');
  59 + }else{
  60 + $this->error('评论可见度修改失败');
  61 + }
  62 + }
  63 + }
  64 +
  65 + /**
  66 + * 删除评论
  67 + */
  68 + public function delete()
  69 + {
  70 + if ($this->request->param()){
  71 + $id=$this->request->param('ids/a');
  72 + $del=Db::name('zj_comment')->where(['id'=>['in',$id]])->delete();
  73 + if($del){
  74 + $this->success('评论删除成功','');
  75 + }else{
  76 + $this->error('评论删除失败');
  77 + }
  78 + }
  79 + }
  80 +
  81 +}
@@ -32,6 +32,9 @@ class ZjOrderController extends AdminBaseController @@ -32,6 +32,9 @@ class ZjOrderController extends AdminBaseController
32 if (strlen($in['ser_type'])>'0'){ 32 if (strlen($in['ser_type'])>'0'){
33 $where['s.ser_type']=$in['ser_type']; 33 $where['s.ser_type']=$in['ser_type'];
34 } 34 }
  35 + if (strlen($in['order_num'])>'0'){
  36 + $where['o.order_num']=$in['order_num'];
  37 + }
35 } 38 }
36 $admin=Db::name('role_user')->field('user_id')->where('role_id','3')->select(); 39 $admin=Db::name('role_user')->field('user_id')->where('role_id','3')->select();
37 foreach ($admin as $k=>$val){ 40 foreach ($admin as $k=>$val){
@@ -40,6 +43,25 @@ class ZjOrderController extends AdminBaseController @@ -40,6 +43,25 @@ class ZjOrderController extends AdminBaseController
40 $aname=Db::name('user')->field('user_login,id')->where(['id'=>['in',$id]])->select(); 43 $aname=Db::name('user')->field('user_login,id')->where(['id'=>['in',$id]])->select();
41 $order=new ZjOrderModel(); 44 $order=new ZjOrderModel();
42 $all=$order->selectAll($where); 45 $all=$order->selectAll($where);
  46 +
  47 + $aa=['0','0','0','0'];
  48 + $zd=['0','0','0'];
  49 + foreach ($all as $k=>$val){
  50 + if ($val['order_type']=='0'){
  51 + $aa['1']+=$val['whole'];
  52 + $zd['0']+='1';
  53 + }elseif ($val['order_type']=='1'){
  54 + $aa['2']+=$val['whole'];
  55 + $zd['1']+='1';
  56 + }else{
  57 + $aa['3']+=$val['whole'];
  58 + $zd['2']+='1';
  59 + }
  60 + }
  61 + $ser=Db::name('zj_service_type')->select();
  62 + $this->assign('aa',$aa);
  63 + $this->assign('zd',$zd);
  64 + $this->assign('ser',$ser);
43 $this->assign('allorder',$all); 65 $this->assign('allorder',$all);
44 $this->assign('admin',$aname); 66 $this->assign('admin',$aname);
45 67
@@ -59,7 +81,7 @@ class ZjOrderController extends AdminBaseController @@ -59,7 +81,7 @@ class ZjOrderController extends AdminBaseController
59 $where['s.ser_type']=$in['ser_type']; 81 $where['s.ser_type']=$in['ser_type'];
60 } 82 }
61 if (strlen($in['name'])>'0'){ 83 if (strlen($in['name'])>'0'){
62 - $where['s.name']=$in['name']; 84 + $where['s.id']=$in['name'];
63 } 85 }
64 if (strlen($in['date_min'])>'0'){ 86 if (strlen($in['date_min'])>'0'){
65 $where['o.contact_date']=['egt',$in['date_min']]; 87 $where['o.contact_date']=['egt',$in['date_min']];
@@ -73,10 +95,12 @@ class ZjOrderController extends AdminBaseController @@ -73,10 +95,12 @@ class ZjOrderController extends AdminBaseController
73 95
74 } 96 }
75 97
76 - $service=Db::name('zj_service')->field('id,name,ser_type')->select();//查询服务价格 我的订单联动筛选 98 + $service=Db::name('zj_service')->field('id,name,ser_type')->select();//查询服务名称 我的订单联动筛选
77 $contact=Db::name('zj_contact')->select();//预约具体时间 99 $contact=Db::name('zj_contact')->select();//预约具体时间
78 $order=new ZjOrderModel(); 100 $order=new ZjOrderModel();
79 $all=$order->selectAll($where); 101 $all=$order->selectAll($where);
  102 + $ser=Db::name('zj_service_type')->select();
  103 + $this->assign('ser',$ser);
80 $this->assign('allcon',$contact); 104 $this->assign('allcon',$contact);
81 $this->assign('allorder',$all); 105 $this->assign('allorder',$all);
82 $this->assign('allservice',$service); 106 $this->assign('allservice',$service);
@@ -114,7 +138,6 @@ class ZjOrderController extends AdminBaseController @@ -114,7 +138,6 @@ class ZjOrderController extends AdminBaseController
114 $this->assign('admin',$aname); 138 $this->assign('admin',$aname);
115 return $this->fetch(); 139 return $this->fetch();
116 } 140 }
117 -  
118 } 141 }
119 142
120 /** 143 /**
@@ -134,7 +157,7 @@ class ZjOrderController extends AdminBaseController @@ -134,7 +157,7 @@ class ZjOrderController extends AdminBaseController
134 $where['o.order_type']=$in['order_type']; 157 $where['o.order_type']=$in['order_type'];
135 } 158 }
136 if (strlen($in['name'])>'0'){ 159 if (strlen($in['name'])>'0'){
137 - $where['s.name']=$in['name']; 160 + $where['s.id']=$in['name'];
138 } 161 }
139 if (strlen($in['date_min'])>'0'){ 162 if (strlen($in['date_min'])>'0'){
140 $where['o.contact_date']=['egt',$in['date_min']]; 163 $where['o.contact_date']=['egt',$in['date_min']];
@@ -145,12 +168,17 @@ class ZjOrderController extends AdminBaseController @@ -145,12 +168,17 @@ class ZjOrderController extends AdminBaseController
145 if (strlen($in['contact_time'])>'0'){ 168 if (strlen($in['contact_time'])>'0'){
146 $where['o.contact_time']=$in['contact_time']; 169 $where['o.contact_time']=$in['contact_time'];
147 } 170 }
  171 + if (strlen($in['order_num'])>'0'){
  172 + $where['o.order_num']=$in['order_num'];
  173 + }
148 } 174 }
149 175
150 $service=Db::name('zj_service')->field('id,name,ser_type')->select();//查询服务名称 我的订单联动筛选 176 $service=Db::name('zj_service')->field('id,name,ser_type')->select();//查询服务名称 我的订单联动筛选
151 $contact=Db::name('zj_contact')->select();//预约具体时间 177 $contact=Db::name('zj_contact')->select();//预约具体时间
152 $order=new ZjOrderModel(); 178 $order=new ZjOrderModel();
153 $all=$order->selectAll($where); 179 $all=$order->selectAll($where);
  180 + $ser=Db::name('zj_service_type')->select();
  181 + $this->assign('ser',$ser);
154 $this->assign('allcon',$contact); 182 $this->assign('allcon',$contact);
155 $this->assign('allorder',$all); 183 $this->assign('allorder',$all);
156 $this->assign('allservice',$service); 184 $this->assign('allservice',$service);
@@ -19,7 +19,8 @@ class ZjServiceController extends AdminBaseController @@ -19,7 +19,8 @@ class ZjServiceController extends AdminBaseController
19 */ 19 */
20 public function index() 20 public function index()
21 { 21 {
22 - $all=Db::name('zj_service')->field('id,ser_type,name,price_ori,price_new,describes,apply,create_time,update_time,is_dis,is_rec'); 22 + $all=Db::name('zj_service')->alias('s')->join('zj_service_type t','s.ser_type=t.id')
  23 + ->field('s.id,s.ser_type,s.name,s.price_ori,s.price_new,s.describes,s.apply,s.create_time,s.update_time,s.is_dis,s.is_rec,t.name as tname');
23 if ($this->request->isPost()){ 24 if ($this->request->isPost()){
24 $arr=input('post.'); 25 $arr=input('post.');
25 //搜索条件 26 //搜索条件
@@ -36,6 +37,8 @@ class ZjServiceController extends AdminBaseController @@ -36,6 +37,8 @@ class ZjServiceController extends AdminBaseController
36 } 37 }
37 38
38 $all=$all->order('id','asc')->paginate(10); 39 $all=$all->order('id','asc')->paginate(10);
  40 + $ser=Db::name('zj_service_type')->select();
  41 + $this->assign('ser',$ser);
39 $this->assign('allser',$all); 42 $this->assign('allser',$all);
40 return $this->fetch(); 43 return $this->fetch();
41 } 44 }
@@ -44,6 +47,8 @@ class ZjServiceController extends AdminBaseController @@ -44,6 +47,8 @@ class ZjServiceController extends AdminBaseController
44 */ 47 */
45 public function add() 48 public function add()
46 { 49 {
  50 + $ser=Db::name('zj_service_type')->select();
  51 + $this->assign('ser',$ser);
47 return $this->fetch(); 52 return $this->fetch();
48 } 53 }
49 54
@@ -86,6 +91,8 @@ class ZjServiceController extends AdminBaseController @@ -86,6 +91,8 @@ class ZjServiceController extends AdminBaseController
86 if ($this->request->param()){ 91 if ($this->request->param()){
87 $id=input('param.id'); 92 $id=input('param.id');
88 $one=Db::name('zj_service')->where('id',$id)->find(); 93 $one=Db::name('zj_service')->where('id',$id)->find();
  94 + $ser=Db::name('zj_service_type')->select();
  95 + $this->assign('ser',$ser);
89 $this->assign('one',$one); 96 $this->assign('one',$one);
90 return $this->fetch(); 97 return $this->fetch();
91 } 98 }
@@ -183,4 +190,21 @@ class ZjServiceController extends AdminBaseController @@ -183,4 +190,21 @@ class ZjServiceController extends AdminBaseController
183 } 190 }
184 } 191 }
185 192
  193 + /**
  194 + *添加服务分类
  195 + */
  196 + public function addType()
  197 + {
  198 + if ($this->request->param()){
  199 + $name=input('param.name');
  200 + $type=Db::name('zj_service_type')->insert(['name'=>$name]);
  201 + if ($type){
  202 + $this->success('增加分类成功','');
  203 + }else{
  204 + $this->error('增加分类失败');
  205 + }
  206 + }
  207 + return $this->fetch();
  208 + }
  209 +
186 } 210 }
@@ -14,12 +14,32 @@ use think\Db; @@ -14,12 +14,32 @@ use think\Db;
14 14
15 class ZjOrderModel extends Model 15 class ZjOrderModel extends Model
16 { 16 {
  17 + /**
  18 + * 获取订单数据
  19 + */
17 public function selectAll($where) 20 public function selectAll($where)
18 { 21 {
19 - $all=Db::name('zj_order')->alias('o')->join('zj_service s','o.service_id=s.id')->join('user u','o.user_id=u.id')->join('zj_contact c','o.contact_time=c.id')->join('user y','o.admin_id=y.id','left')  
20 - ->field('o.*,s.ser_type,s.name as sname,u.user_nickname as uname,y.user_login as aname,c.contact') 22 + $all=Db::name('zj_order')->alias('o')->join('zj_service s','o.service_id=s.id')->join('user u','o.user_id=u.id')->join('zj_contact c','o.contact_time=c.id')->join('user y','o.admin_id=y.id','left')->join('zj_service_type t','s.ser_type=t.id')
  23 + ->field('o.*,s.ser_type,s.name as sname,u.user_nickname as uname,y.user_login as aname,c.contact,t.name as tname')
21 ->where($where)->order('o.create_time','desc')->paginate(10); 24 ->where($where)->order('o.create_time','desc')->paginate(10);
22 return $all; 25 return $all;
23 } 26 }
24 27
  28 + /**
  29 + * 新增订单数量统计
  30 + */
  31 + public function orderNum($where,$where1)
  32 + {
  33 + return Db::name('zj_order')->where($where)->where($where1)->count('id');
  34 + }
  35 +
  36 + /**
  37 + * 新增订单金额统计
  38 + */
  39 + public function priceNum($where,$where1)
  40 + {
  41 + return Db::name('zj_order')->where($where)->where($where1)->sum('whole');
  42 + }
  43 +
  44 +
25 } 45 }
@@ -88,7 +88,7 @@ class PortalCategoryModel extends Model @@ -88,7 +88,7 @@ class PortalCategoryModel extends Model
88 $tpl = "<tr> 88 $tpl = "<tr>
89 <td><input name='list_orders[\$id]' type='text' size='3' value='\$list_order' class='input-order'></td> 89 <td><input name='list_orders[\$id]' type='text' size='3' value='\$list_order' class='input-order'></td>
90 <td>\$id</td> 90 <td>\$id</td>
91 - <td>\$spacer <a href='\$url' target='_blank'>\$name</a></td> 91 + <td>\$spacer \$name</td>
92 <td>\$description</td> 92 <td>\$description</td>
93 <td>\$str_action</td> 93 <td>\$str_action</td>
94 </tr>"; 94 </tr>";
@@ -94,13 +94,27 @@ class AdminIndexController extends AdminBaseController @@ -94,13 +94,27 @@ class AdminIndexController extends AdminBaseController
94 */ 94 */
95 public function ban() 95 public function ban()
96 { 96 {
97 - $id = input('param.id', 0, 'intval'); 97 + $id = input('param.id');
  98 + $phone = input('param.mobile');
  99 + $result=true;
98 if ($id) { 100 if ($id) {
99 - $result = Db::name("user")->where(["id" => $id, "user_type" => 2])->setField('user_status', 0); 101 + Db::startTrans();
  102 + try{
  103 + Db::name('user')->where(["id" => $id, "user_type" => 2])->setField('user_status', 0);
  104 + Db::name('zj_deluser')->insert(['phone'=>$phone]);
  105 + // 提交事务
  106 + Db::commit();
  107 + $result=true;
  108 + } catch (\Exception $e) {
  109 + // 回滚事务
  110 + Db::rollback();
  111 + $result=false;
  112 + }
  113 +
100 if ($result) { 114 if ($result) {
101 $this->success("会员拉黑成功!", "adminIndex/index"); 115 $this->success("会员拉黑成功!", "adminIndex/index");
102 } else { 116 } else {
103 - $this->error('会员拉黑失败,会员不存在,或者是管理员!'); 117 + $this->error('会员拉黑失败!');
104 } 118 }
105 } else { 119 } else {
106 $this->error('数据传入失败!'); 120 $this->error('数据传入失败!');
@@ -122,25 +136,30 @@ class AdminIndexController extends AdminBaseController @@ -122,25 +136,30 @@ class AdminIndexController extends AdminBaseController
122 */ 136 */
123 public function cancelBan() 137 public function cancelBan()
124 { 138 {
125 - $id = input('param.id', 0, 'intval'); 139 + $id = input('param.id');
  140 + $phone = input('param.mobile');
  141 + $result=true;
126 if ($id) { 142 if ($id) {
127 - Db::name("user")->where(["id" => $id, "user_type" => 2])->setField('user_status', 1);  
128 - $this->success("会员启用成功!", ''); 143 + Db::startTrans();
  144 + try{
  145 + Db::name('user')->where(["id" => $id, "user_type" => 2])->setField('user_status', 1);
  146 + Db::name('zj_deluser')->where('phone',$phone)->delete();
  147 + // 提交事务
  148 + Db::commit();
  149 + $result=true;
  150 + } catch (\Exception $e) {
  151 + // 回滚事务
  152 + Db::rollback();
  153 + $result=false;
  154 + }
  155 + if ($result) {
  156 + $this->success("会员启用成功!", '');
  157 + } else {
  158 + $this->error('会员启用失败!');
  159 + }
129 } else { 160 } else {
130 $this->error('数据传入失败!'); 161 $this->error('数据传入失败!');
131 } 162 }
132 } 163 }
133 164
134 - /**  
135 - * 用户删除  
136 - */  
137 - public function delete()  
138 - {  
139 - $id = $this->request->param('id', 0, 'intval');  
140 - if (Db::name('user')->delete($id) !== false) {  
141 - $this->success("删除成功!");  
142 - } else {  
143 - $this->error("删除失败!");  
144 - }  
145 - }  
146 } 165 }
1 <?php 1 <?php
2 return array ( 2 return array (
  3 + 'ADMIN_DATASTATI_INDEX' => '数据统计',
3 'ADMIN_HOOK_INDEX' => '钩子管理', 4 'ADMIN_HOOK_INDEX' => '钩子管理',
4 'ADMIN_HOOK_PLUGINLISTORDER' => '钩子插件排序', 5 'ADMIN_HOOK_PLUGINLISTORDER' => '钩子插件排序',
5 'ADMIN_HOOK_PLUGINS' => '钩子插件管理', 6 'ADMIN_HOOK_PLUGINS' => '钩子插件管理',
@@ -118,14 +119,17 @@ return array ( @@ -118,14 +119,17 @@ return array (
118 'ADMIN_USER_INDEX' => '管理员', 119 'ADMIN_USER_INDEX' => '管理员',
119 'ADMIN_USER_USERINFO' => '个人信息', 120 'ADMIN_USER_USERINFO' => '个人信息',
120 'ADMIN_USER_USERINFOPOST' => '管理员个人信息修改提交', 121 'ADMIN_USER_USERINFOPOST' => '管理员个人信息修改提交',
  122 + 'ADMIN_ZJCOMMENT_INDEX' => '评论管理',
121 'ADMIN_ZJORDER_DEFAULT' => '订单管理', 123 'ADMIN_ZJORDER_DEFAULT' => '订单管理',
122 'ADMIN_ZJORDER_ETC' => '待分配订单', 124 'ADMIN_ZJORDER_ETC' => '待分配订单',
123 'ADMIN_ZJORDER_INDEX' => '全部订单', 125 'ADMIN_ZJORDER_INDEX' => '全部订单',
124 'ADMIN_ZJORDER_MEORDER' => '我的订单', 126 'ADMIN_ZJORDER_MEORDER' => '我的订单',
125 'ADMIN_ZJSERVICE_ADD' => '添加服务', 127 'ADMIN_ZJSERVICE_ADD' => '添加服务',
126 'ADMIN_ZJSERVICE_ADDPOST' => '添加服务提交', 128 'ADMIN_ZJSERVICE_ADDPOST' => '添加服务提交',
  129 + 'ADMIN_ZJSERVICE_ADDTYPE' => '添加服务分类',
  130 + 'ADMIN_ZJSERVICE_DEFAULT' => '服务管理',
127 'ADMIN_ZJSERVICE_DELETE' => '删除服务', 131 'ADMIN_ZJSERVICE_DELETE' => '删除服务',
128 - 'ADMIN_ZJSERVICE_INDEX' => '服务管理', 132 + 'ADMIN_ZJSERVICE_INDEX' => '全部服务',
129 'ADMIN_ZJSERVICE_PUBLISH' => '发布与取消发布服务', 133 'ADMIN_ZJSERVICE_PUBLISH' => '发布与取消发布服务',
130 'ADMIN_ZJSERVICE_RECOMMEND' => '推荐与取消推荐服务', 134 'ADMIN_ZJSERVICE_RECOMMEND' => '推荐与取消推荐服务',
131 'ADMIN_ZJ_REWARD_INDEX' => '分享佣金', 135 'ADMIN_ZJ_REWARD_INDEX' => '分享佣金',
  1 +<include file="public@header"/>
  2 +<style>
  3 + div.data{
  4 + width: 200px;
  5 + height: 150px;
  6 + text-align: center;
  7 + margin: 20px;
  8 + background: #55ACEE;
  9 + color:white;
  10 + }
  11 + div.data p{
  12 + font-size: 18px;
  13 + font-weight: 900;
  14 + margin-top: 20px;
  15 + }
  16 + div.data span{
  17 + font-size: 40px;
  18 + font-weight: 900;
  19 + }
  20 +</style>
  21 +</head>
  22 +<body>
  23 +<div class="wrap js-check-wrap">
  24 + <div class="row">
  25 + <div class="col-md-1 data">
  26 + <p>今日新增订单</p>
  27 + <span>{$num.0}</span>
  28 + </div>
  29 + <div class="col-md-1 data">
  30 + <p>本周新增订单</p>
  31 + <span>{$num.1}</span>
  32 + </div>
  33 + <div class="col-md-1 data">
  34 + <p>本月新增订单</p>
  35 + <span>{$num.2}</span>
  36 + </div>
  37 + </div>
  38 +
  39 + <div class="row">
  40 +
  41 + <div class="col-md-1 data">
  42 + <p>今日订单金额</p>
  43 + <span>{$price.0}</span>
  44 + </div>
  45 + <div class="col-md-1 data">
  46 + <p>本周订单金额</p>
  47 + <span>{$price.1}</span>
  48 + </div>
  49 + <div class="col-md-1 data">
  50 + <p>本月订单金额</p>
  51 + <span>{$price.2}</span>
  52 + </div>
  53 + </div>
  54 +
  55 +</div>
  56 +<script type="text/javascript" src="__STATIC__/js/admin.js"></script>
  57 +</body>
  58 +</html>
  1 +<include file="public@header"/>
  2 +</head>
  3 +<body>
  4 +<div class="wrap js-check-wrap">
  5 + <ul class="nav nav-tabs">
  6 + <li class="active"><a>评论管理</a></li>
  7 + </ul>
  8 + <form class="well form-inline margin-top-20" method="post" action="{:url('zj_comment/index')}">
  9 + 服务分类:
  10 + <select class="form-control" name="ser_type" id="classo" onchange="teacherChange(this.options[this.selectedIndex].value)">
  11 + <option value>选择服务类别</option>
  12 + <option value="0">简历服务</option>
  13 + <option value="1">职业规划</option>
  14 + <option value="2">面试辅导</option>
  15 + </select>&nbsp;&nbsp;
  16 +
  17 + 服务名称:
  18 + <select class="form-control" id="classobj" name="name">
  19 + <option value>选择服务名称</option>
  20 + <foreach name="allservice" item="val">
  21 + <option value="{$val.id}">{$val.name}</option>
  22 + </foreach>
  23 + </select>&nbsp;&nbsp;
  24 + 评论星级:
  25 + <select class="form-control" name="level">
  26 + <option value>选择星级</option>
  27 + <option value="1">1星</option>
  28 + <option value="2">2星</option>
  29 + <option value="3">3星</option>
  30 + <option value="4">4星</option>
  31 + <option value="5">5星</option>
  32 + </select>&nbsp;&nbsp;
  33 + <input type="submit" class="btn btn-primary" value="搜索" />
  34 + <a class="btn btn-danger" href="{:url('zj_comment/index')}">清空</a>
  35 + </form>
  36 + <form action="" method="post" class="form-horizontal js-ajax-form margin-top-20">
  37 + <div class="table-actions">
  38 + <button class="btn btn-primary btn-sm js-ajax-submit" type="submit" data-action="{:url('zj_comment/comstate',array('yes'=>'1'))}" data-subcheck="true">
  39 + 显示
  40 + </button>
  41 + <button class="btn btn-primary btn-sm js-ajax-submit" type="submit" data-action="{:url('zj_comment/comstate',array('yes'=>'0'))}" data-subcheck="true">
  42 + 隐藏
  43 + </button>
  44 + <button class="btn btn-danger btn-sm js-ajax-submit" type="submit"
  45 + data-action="{:url('zj_comment/delete')}" data-subcheck="true" data-msg="您确定删除吗?">
  46 + 删除
  47 + </button>
  48 + </div>
  49 + <table class="table table-hover table-bordered">
  50 + <thead>
  51 + <tr>
  52 + <th width="15">
  53 + <label>
  54 + <input type="checkbox" class="js-check-all" data-direction="x" data-checklist="js-check-x">
  55 + </label>
  56 + </th>
  57 + <th>评论用户</th>
  58 + <th>所购服务</th>
  59 + <th>评论星级</th>
  60 + <th>评论时间</th>
  61 + <th>评论内容</th>
  62 + <th>评论状态</th>
  63 + <th>操作</th>
  64 + </tr>
  65 + </thead>
  66 + <tbody>
  67 + <foreach name="allcom" item="vo">
  68 + <tr>
  69 + <td>
  70 + <input type="checkbox" class="js-check" data-yid="js-check-y" data-xid="js-check-x" name="ids[]"
  71 + value="{$vo.id}" title="ID:{$vo.id}">
  72 + </td>
  73 + <td>{$vo['uname']}</td>
  74 + <td>{$vo['ser_name']}</td>
  75 + <td>{$vo['level']}星</td>
  76 + <td>{:date('Y-m-d H-i-s',$vo['create_time'])}</td>
  77 + <td>{$vo['content']}</td>
  78 + <td>
  79 + <if condition="$vo['is_sta'] eq 0">
  80 + 未显示
  81 + <else>
  82 + 已显示
  83 + </if>
  84 + </td>
  85 + <td>
  86 + <a href="{:url('zj_order/one',array('id'=>$vo['order_id']))}">关联订单详情</a>
  87 + <a class="js-ajax-delete" href="{:url('zj_comment/delete',array('ids'=>$vo['id']))}">删除评论</a>
  88 + </td>
  89 + </tr>
  90 + </foreach>
  91 + </tbody>
  92 + </table>
  93 + <div class="pagination">{$allcom->render()}</div>
  94 + </form>
  95 +</div>
  96 +<script type="text/javascript" src="__STATIC__/js/admin.js"></script>
  97 +<script type="text/javascript">
  98 +
  99 + var ar1={:json_encode($allservice)};//后台传入服务名称
  100 + //当选择指向类时改变目标的下拉菜单
  101 + function teacherChange(area){
  102 + var tobj=document.getElementById('classobj');
  103 + removeAllOptions(tobj);
  104 + var option = document.createElement("option");
  105 + option.text = "选择服务名称";
  106 + option.value = "";
  107 + tobj.add(option);
  108 +
  109 + for(m=0;m<ar1.length;m++){
  110 + if (ar1[m]['ser_type']==area&&area!=''){
  111 + var option = document.createElement("option");
  112 + option.text = ar1[m]['name'];
  113 + option.value = ar1[m]['id'];
  114 + tobj.add(option);
  115 + }else if(area==''){
  116 + var option = document.createElement("option");
  117 + option.text = ar1[m]['name'];
  118 + option.value = ar1[m]['id'];
  119 + tobj.add(option);
  120 + }
  121 + }
  122 + }
  123 + //移除option 当中所有元素
  124 + function removeAllOptions(selectbox)
  125 + {
  126 + var i;
  127 + for(i=selectbox.options.length-1;i>=0;i--)
  128 + {
  129 + selectbox.remove(i);
  130 + }
  131 + }
  132 +
  133 +</script>
  134 +</body>
  135 +</html>
@@ -9,17 +9,17 @@ @@ -9,17 +9,17 @@
9 服务分类: 9 服务分类:
10 <select class="form-control" name="ser_type" id="classo" onchange="teacherChange(this.options[this.selectedIndex].value)"> 10 <select class="form-control" name="ser_type" id="classo" onchange="teacherChange(this.options[this.selectedIndex].value)">
11 <option value>选择服务类别</option> 11 <option value>选择服务类别</option>
12 - <option value="0">简历服务</option>  
13 - <option value="1">职业规划</option>  
14 - <option value="2">面试辅导</option>  
15 - </select> 12 + <foreach name="ser" item="vo">
  13 + <option value="{$vo.id}">{$vo.name}</option>
  14 + </foreach>
  15 + </select>&nbsp;&nbsp;
16 服务名称: 16 服务名称:
17 <select class="form-control" id="classobj" name="name"> 17 <select class="form-control" id="classobj" name="name">
18 <option value>选择服务名称</option> 18 <option value>选择服务名称</option>
19 <foreach name="allservice" item="val"> 19 <foreach name="allservice" item="val">
20 <option value="{$val.id}">{$val.name}</option> 20 <option value="{$val.id}">{$val.name}</option>
21 </foreach> 21 </foreach>
22 - </select> 22 + </select>&nbsp;&nbsp;
23 预约时间: 23 预约时间:
24 <input type="date" class="form-control time" name="date_min"> 24 <input type="date" class="form-control time" name="date_min">
25 - 25 -
@@ -29,13 +29,13 @@ @@ -29,13 +29,13 @@
29 <foreach name="allcon" item="val"> 29 <foreach name="allcon" item="val">
30 <option value="{$val.id}">{$val['contact']}</option> 30 <option value="{$val.id}">{$val['contact']}</option>
31 </foreach> 31 </foreach>
32 - </select> 32 + </select>&nbsp;&nbsp;
33 <input type="submit" class="btn btn-primary" value="搜索" /> 33 <input type="submit" class="btn btn-primary" value="搜索" />
34 <a class="btn btn-danger" href="{:url('zj_order/etc')}">清空</a> 34 <a class="btn btn-danger" href="{:url('zj_order/etc')}">清空</a>
35 </form> 35 </form>
36 <form class="form-inline" action="{:url('zj_order/etcten')}" method="post"> 36 <form class="form-inline" action="{:url('zj_order/etcten')}" method="post">
37 <div class="table-actions"> 37 <div class="table-actions">
38 - <button class="btn btn-primary btn-sm" type="submit" data-subcheck="true" onclick="ck()"> 38 + <button class="btn btn-primary btn-sm" type="submit" data-subcheck="true">
39 分配导师 39 分配导师
40 </button> 40 </button>
41 </div> 41 </div>
@@ -47,9 +47,6 @@ @@ -47,9 +47,6 @@
47 <input type="checkbox" class="js-check-all" data-direction="x" data-checklist="js-check-x"> 47 <input type="checkbox" class="js-check-all" data-direction="x" data-checklist="js-check-x">
48 </label> 48 </label>
49 </th> 49 </th>
50 - <notempty name="category">  
51 - <th width="50">{:lang('SORT')}</th>  
52 - </notempty>  
53 <th>订单编号</th> 50 <th>订单编号</th>
54 <th>所购服务</th> 51 <th>所购服务</th>
55 <th>服务分类</th> 52 <th>服务分类</th>
@@ -69,15 +66,7 @@ @@ -69,15 +66,7 @@
69 </td> 66 </td>
70 <td>{$vo['order_num']}</td> 67 <td>{$vo['order_num']}</td>
71 <td>{$vo['sname']}</td> 68 <td>{$vo['sname']}</td>
72 - <td>  
73 - <if condition="$vo['ser_type'] eq 0">  
74 - 简历服务  
75 - <elseif condition="$vo['ser_type'] eq 1">  
76 - 职业规划  
77 - <elseif condition="$vo['ser_type'] eq 2">  
78 - 面试辅导  
79 - </if>  
80 - </td> 69 + <td>{$vo['tname']}</td>
81 <td>{$vo['uname']}</td> 70 <td>{$vo['uname']}</td>
82 <td>{$vo['phone']}</td> 71 <td>{$vo['phone']}</td>
83 <td> 72 <td>
@@ -35,15 +35,7 @@ @@ -35,15 +35,7 @@
35 </td> 35 </td>
36 <td>{$vo['order_num']}</td> 36 <td>{$vo['order_num']}</td>
37 <td>{$vo['sname']}</td> 37 <td>{$vo['sname']}</td>
38 - <td>  
39 - <if condition="$vo['ser_type'] eq 0">  
40 - 简历服务  
41 - <elseif condition="$vo['ser_type'] eq 1">  
42 - 职业规划  
43 - <elseif condition="$vo['ser_type'] eq 2">  
44 - 面试辅导  
45 - </if>  
46 - </td> 38 + <td>{$vo['tname']}</td>
47 <td>{$vo['uname']}</td> 39 <td>{$vo['uname']}</td>
48 <td>{$vo['phone']}</td> 40 <td>{$vo['phone']}</td>
49 <td> 41 <td>
@@ -15,22 +15,23 @@ @@ -15,22 +15,23 @@
15 <option value="3">已分配</option> 15 <option value="3">已分配</option>
16 <option value="4">待评论</option> 16 <option value="4">待评论</option>
17 <option value="5">已完成</option> 17 <option value="5">已完成</option>
18 - </select> 18 + </select>&nbsp;&nbsp;
19 导师: 19 导师:
20 <select class="form-control" name="aid"> 20 <select class="form-control" name="aid">
21 <option value>选择导师</option> 21 <option value>选择导师</option>
22 <foreach name="admin" item="val"> 22 <foreach name="admin" item="val">
23 <option value="{$val.id}">{$val.user_login}</option> 23 <option value="{$val.id}">{$val.user_login}</option>
24 </foreach> 24 </foreach>
25 - </select> 25 + </select>&nbsp;&nbsp;
26 服务分类: 26 服务分类:
27 <select class="form-control" name="ser_type"> 27 <select class="form-control" name="ser_type">
28 <option value>选择服务分类</option> 28 <option value>选择服务分类</option>
29 - <option value="0">简历服务</option>  
30 - <option value="1">职业规划</option>  
31 - <option value="2">面试辅导</option>  
32 - </select>  
33 - 29 + <foreach name="ser" item="vo">
  30 + <option value="{$vo.id}">{$vo.name}</option>
  31 + </foreach>
  32 + </select>&nbsp;&nbsp;
  33 + 订单编号:
  34 + <input type="text" name="order_num" placeholder="请输入12位订单编号" class="form-control">&nbsp;&nbsp;
34 <input type="submit" class="btn btn-primary" value="搜索" /> 35 <input type="submit" class="btn btn-primary" value="搜索" />
35 <a class="btn btn-danger" href="{:url('zj_order/index')}">清空</a> 36 <a class="btn btn-danger" href="{:url('zj_order/index')}">清空</a>
36 </form> 37 </form>
@@ -57,15 +58,7 @@ @@ -57,15 +58,7 @@
57 <tr> 58 <tr>
58 <td>{$vo['order_num']}</td> 59 <td>{$vo['order_num']}</td>
59 <td>{$vo['sname']}</td> 60 <td>{$vo['sname']}</td>
60 - <td>  
61 - <if condition="$vo['ser_type'] eq 0">  
62 - 简历服务  
63 - <elseif condition="$vo['ser_type'] eq 1">  
64 - 职业规划  
65 - <elseif condition="$vo['ser_type'] eq 2">  
66 - 面试辅导  
67 - </if>  
68 - </td> 61 + <td>{$vo['tname']}</td>
69 <td>{$vo['uname']}</td> 62 <td>{$vo['uname']}</td>
70 <td>{$vo['name']}</td> 63 <td>{$vo['name']}</td>
71 <td> 64 <td>
@@ -126,6 +119,44 @@ @@ -126,6 +119,44 @@
126 </foreach> 119 </foreach>
127 </tbody> 120 </tbody>
128 </table> 121 </table>
  122 + <table class="table table-bordered" style="width: 80%;">
  123 + <thead>
  124 + <tr>
  125 + <th style="width: 25%;">已取消订单数量</th>
  126 + <th style="width: 25%;">未支付订单数量</th>
  127 + <th style="width: 25%;">已支付订单数量</th>
  128 + <th style="width: 25%;">总订单数量</th>
  129 + </tr>
  130 + </thead>
  131 + <tbody>
  132 + <tr>
  133 + <td>{$zd.0}</td>
  134 + <td>{$zd.1}</td>
  135 + <td>{$zd.2}</td>
  136 + <td>{$zd['0']+$zd['1']+$zd['2']}</td>
  137 + </tr>
  138 + </tbody>
  139 + </table>
  140 + <table class="table table-bordered" style="width: 100%;">
  141 + <thead>
  142 + <tr>
  143 + <th style="width: 20%;">已取消订单金额</th>
  144 + <th style="width: 20%;">未支付订单金额</th>
  145 + <th style="width: 20%;">已支付订单金额</th>
  146 + <th style="width: 20%;">未支付加已支付订单金额</th>
  147 + <th style="width: 20%;">所有订单总金额</th>
  148 + </tr>
  149 + </thead>
  150 + <tbody>
  151 + <tr>
  152 + <td>{$aa.1}</td>
  153 + <td>{$aa.2}</td>
  154 + <td>{$aa.3}</td>
  155 + <td>{$aa['2']+$aa['3']}</td>
  156 + <td>{$aa['1']+$aa['2']+$aa['3']}</td>
  157 + </tr>
  158 + </tbody>
  159 + </table>
129 <div class="pagination">{$allorder->render()}</div> 160 <div class="pagination">{$allorder->render()}</div>
130 </div> 161 </div>
131 <script src="__STATIC__/js/admin.js"></script> 162 <script src="__STATIC__/js/admin.js"></script>
@@ -9,10 +9,10 @@ @@ -9,10 +9,10 @@
9 服务分类: 9 服务分类:
10 <select class="form-control" name="ser_type" id="classo" onchange="teacherChange(this.options[this.selectedIndex].value)"> 10 <select class="form-control" name="ser_type" id="classo" onchange="teacherChange(this.options[this.selectedIndex].value)">
11 <option value>选择服务类别</option> 11 <option value>选择服务类别</option>
12 - <option value="0">简历服务</option>  
13 - <option value="1">职业规划</option>  
14 - <option value="2">面试辅导</option>  
15 - </select> 12 + <foreach name="ser" item="vo">
  13 + <option value="{$vo.id}">{$vo.name}</option>
  14 + </foreach>
  15 + </select>&nbsp;&nbsp;
16 16
17 服务名称: 17 服务名称:
18 <select class="form-control" id="classobj" name="name"> 18 <select class="form-control" id="classobj" name="name">
@@ -20,24 +20,26 @@ @@ -20,24 +20,26 @@
20 <foreach name="allservice" item="val"> 20 <foreach name="allservice" item="val">
21 <option value="{$val.id}">{$val.name}</option> 21 <option value="{$val.id}">{$val.name}</option>
22 </foreach> 22 </foreach>
23 - </select> 23 + </select>&nbsp;&nbsp;
24 订单状态: 24 订单状态:
25 <select class="form-control" name="order_type"> 25 <select class="form-control" name="order_type">
26 <option value>选择订单状态</option> 26 <option value>选择订单状态</option>
27 <option value="3">未完成</option> 27 <option value="3">未完成</option>
28 <option value="4">待评论</option> 28 <option value="4">待评论</option>
29 <option value="5">订单完成</option> 29 <option value="5">订单完成</option>
30 - </select>  
31 - 预约时间:  
32 - <input type="date" class="form-control time" name="date_min"> 30 + </select>&nbsp;&nbsp;
  31 + 预约时间:
  32 + <input type="date" class="form-control time" name="date_min" style="width: 150px;">
33 - 33 -
34 - <input type="date" class="form-control time" name="date_max"> 34 + <input type="date" class="form-control time" name="date_max" style="width: 150px;">
35 <select class="form-control" name="contact_time"> 35 <select class="form-control" name="contact_time">
36 <option value>选择时间</option> 36 <option value>选择时间</option>
37 <foreach name="allcon" item="val"> 37 <foreach name="allcon" item="val">
38 <option value="{$val.id}">{$val['contact']}</option> 38 <option value="{$val.id}">{$val['contact']}</option>
39 </foreach> 39 </foreach>
40 - </select> 40 + </select>&nbsp;&nbsp;<br/>
  41 + 订单编号:
  42 + <input type="text" name="order_num" placeholder="请输入12位订单编号" class="form-control">&nbsp;&nbsp;
41 <input type="submit" class="btn btn-primary" value="搜索" /> 43 <input type="submit" class="btn btn-primary" value="搜索" />
42 <a class="btn btn-danger" href="{:url('zj_order/meorder')}">清空</a> 44 <a class="btn btn-danger" href="{:url('zj_order/meorder')}">清空</a>
43 </form> 45 </form>
@@ -59,15 +61,7 @@ @@ -59,15 +61,7 @@
59 <tr> 61 <tr>
60 <td>{$vo['order_num']}</td> 62 <td>{$vo['order_num']}</td>
61 <td>{$vo['sname']}</td> 63 <td>{$vo['sname']}</td>
62 - <td>  
63 - <if condition="$vo['ser_type'] eq 0">  
64 - 简历服务  
65 - <elseif condition="$vo['ser_type'] eq 1">  
66 - 职业规划  
67 - <elseif condition="$vo['ser_type'] eq 2">  
68 - 面试辅导  
69 - </if>  
70 - </td> 64 + <td>{$vo['tname']}</td>
71 <td>{$vo['uname']}</td> 65 <td>{$vo['uname']}</td>
72 <td>{$vo['name']}</td> 66 <td>{$vo['name']}</td>
73 <td> 67 <td>
@@ -91,13 +85,7 @@ @@ -91,13 +85,7 @@
91 <script src="__STATIC__/js/admin.js"></script> 85 <script src="__STATIC__/js/admin.js"></script>
92 <script type="text/javascript"> 86 <script type="text/javascript">
93 87
94 - var time=new Date();  
95 - var year=time.getFullYear();  
96 - var month=time.getMonth()+1 < 10 ?'0'+(time.getMonth()+1):time.getMonth()+1;  
97 - var date=time.getDate() < 10?'0'+(time.getDate()-2):time.getDate()-2;  
98 - $('.time').attr('min',year+'-'+month+'-'+date);  
99 -  
100 - var ar1={:json_encode($allservice)};//后台传入服务价格 88 + var ar1={:json_encode($allservice)};//后台传入服务名称
101 //当选择指向类时改变目标的下拉菜单 89 //当选择指向类时改变目标的下拉菜单
102 function teacherChange(area){ 90 function teacherChange(area){
103 var tobj=document.getElementById('classobj'); 91 var tobj=document.getElementById('classobj');
@@ -131,8 +119,6 @@ @@ -131,8 +119,6 @@
131 } 119 }
132 } 120 }
133 121
134 -  
135 -  
136 </script> 122 </script>
137 </body> 123 </body>
138 </html> 124 </html>
@@ -24,15 +24,7 @@ @@ -24,15 +24,7 @@
24 </tr> 24 </tr>
25 <tr> 25 <tr>
26 <th>服务分类</th> 26 <th>服务分类</th>
27 - <td>  
28 - <if condition="$one['ser_type'] eq 0">  
29 - 简历服务  
30 - <elseif condition="$one['ser_type'] eq 1">  
31 - 职业规划  
32 - <elseif condition="$one['ser_type'] eq 2">  
33 - 面试辅导  
34 - </if>  
35 - </td> 27 + <td>{$one['tname']}</td>
36 </tr> 28 </tr>
37 <tr> 29 <tr>
38 <th>服务价格</th> 30 <th>服务价格</th>
@@ -33,9 +33,9 @@ @@ -33,9 +33,9 @@
33 <label for="input-ser-ser" class="col-sm-2 control-label"><span class="form-required">*</span>服务分类</label> 33 <label for="input-ser-ser" class="col-sm-2 control-label"><span class="form-required">*</span>服务分类</label>
34 <div class="col-md-6 col-sm-10"> 34 <div class="col-md-6 col-sm-10">
35 <select class="form-control" name="ser_type" id="input-ser-ser"> 35 <select class="form-control" name="ser_type" id="input-ser-ser">
36 - <option value="0">咨询服务</option>  
37 - <option value="1">职业规划</option>  
38 - <option value="2">面试辅导</option> 36 + <foreach name="ser" item="val">
  37 + <option value="{$val.id}">{$val.name}</option>
  38 + </foreach>
39 </select> 39 </select>
40 </div> 40 </div>
41 </div> 41 </div>
  1 +<include file="public@header" />
  2 +</head>
  3 +<body>
  4 +<div class="wrap js-check-wrap">
  5 + <ul class="nav nav-tabs">
  6 + <li class="active"><a href="#A" data-toggle="tab">添加服务分类</a></li>
  7 + </ul>
  8 + <form class="form-horizontal js-ajax-form margin-top-20" role="form" action="{:url('zj_service/addType')}" method="post">
  9 + <fieldset>
  10 + <div class="tabbable">
  11 + <div class="tab-content">
  12 + <div class="tab-pane active" id="A">
  13 + <div class="form-group">
  14 + <label for="input-ser-type" class="col-sm-2 control-label"><span class="form-required">*</span>服务分类</label>
  15 + <div class="col-md-6 col-sm-10">
  16 + <input type="text" class="form-control" id="input-ser-type" name="name" placeholder="请输入新的分类">
  17 + </div>
  18 + </div>
  19 + <div class="form-group">
  20 + <div class="col-sm-offset-2 col-sm-10">
  21 + <button type="submit" class="btn btn-primary js-ajax-submit">保存</button>
  22 + </div>
  23 + </div>
  24 + </div>
  25 + </div>
  26 + </div>
  27 + </fieldset>
  28 + </form>
  29 +</div>
  30 +<script type="text/javascript" src="__STATIC__/js/admin.js"></script>
  31 +</body>
  32 +</html>
@@ -34,9 +34,9 @@ @@ -34,9 +34,9 @@
34 <label for="input-ser-ser" class="col-sm-2 control-label">服务分类</label> 34 <label for="input-ser-ser" class="col-sm-2 control-label">服务分类</label>
35 <div class="col-md-6 col-sm-10"> 35 <div class="col-md-6 col-sm-10">
36 <select class="form-control" name="ser_type" id="input-ser-ser"> 36 <select class="form-control" name="ser_type" id="input-ser-ser">
37 - <option value="0" <if condition="$one['ser_type'] eq 0">selected</if>>咨询服务</option>  
38 - <option value="1" <if condition="$one['ser_type'] eq 1">selected</if>>职业规划</option>  
39 - <option value="2" <if condition="$one['ser_type'] eq 2">selected</if>>面试辅导</option> 37 + <foreach name="ser" item="val">
  38 + <option value="{$val.id}" <if condition="$val['id'] eq $one.ser_type">selected</if>>{$val.name}</option>
  39 + </foreach>
40 </select> 40 </select>
41 </div> 41 </div>
42 </div> 42 </div>
@@ -10,9 +10,9 @@ @@ -10,9 +10,9 @@
10 服务分类: 10 服务分类:
11 <select class="form-control" name="ser_type"> 11 <select class="form-control" name="ser_type">
12 <option value>选择服务类别</option> 12 <option value>选择服务类别</option>
13 - <option value="0">简历服务</option>  
14 - <option value="1">职业规划</option>  
15 - <option value="2">面试辅导</option> 13 + <foreach name="ser" item="vo">
  14 + <option value="{$vo.id}">{$vo.name}</option>
  15 + </foreach>
16 </select> 16 </select>
17 17
18 适用阶段: 18 适用阶段:
@@ -87,15 +87,7 @@ @@ -87,15 +87,7 @@
87 </td> 87 </td>
88 <td>{$vo['id']}</td> 88 <td>{$vo['id']}</td>
89 <td>{$vo['name']}</td> 89 <td>{$vo['name']}</td>
90 - <td>  
91 - <if condition="$vo['ser_type'] eq 0">  
92 - 简历服务  
93 - <elseif condition="$vo['ser_type'] eq 1">  
94 - 职业规划  
95 - <elseif condition="$vo['ser_type'] eq 2">  
96 - 面试辅导  
97 - </if>  
98 - </td> 90 + <td>{$vo['tname']}</td>
99 <td>{$vo['price_ori']}</td> 91 <td>{$vo['price_ori']}</td>
100 <td>{$vo['price_new']}</td> 92 <td>{$vo['price_new']}</td>
101 <td>{$vo['describes']}</td> 93 <td>{$vo['describes']}</td>
@@ -63,6 +63,7 @@ @@ -63,6 +63,7 @@
63 <th width="50">ID</th> 63 <th width="50">ID</th>
64 <th>标题</th> 64 <th>标题</th>
65 <th>分类</th> 65 <th>分类</th>
  66 + <th>作者</th>
66 <th width="130">更新时间</th> 67 <th width="130">更新时间</th>
67 <th width="130">发布时间</th> 68 <th width="130">发布时间</th>
68 <th width="70">状态</th> 69 <th width="70">状态</th>
@@ -93,6 +94,7 @@ @@ -93,6 +94,7 @@
93 </span>&nbsp; 94 </span>&nbsp;
94 </foreach> 95 </foreach>
95 </td> 96 </td>
  97 + <td>{$vo.user_login}</td>
96 <td width="20%"> 98 <td width="20%">
97 <notempty name="vo.update_time"> 99 <notempty name="vo.update_time">
98 {:date('Y-m-d H:i',$vo['update_time'])} 100 {:date('Y-m-d H:i',$vo['update_time'])}
@@ -50,11 +50,10 @@ @@ -50,11 +50,10 @@
50 <td>{$vo.balance}</td> 50 <td>{$vo.balance}</td>
51 <td>{$user_statuses[$vo['user_status']]}</td> 51 <td>{$user_statuses[$vo['user_status']]}</td>
52 <td> 52 <td>
53 - <a class="js-ajax-delete" href="{:url('adminIndex/delete',array('id'=>$vo['id']))}">{:lang('DELETE')}</a>  
54 <if condition="$vo['user_status'] eq 1"> 53 <if condition="$vo['user_status'] eq 1">
55 - <a href="{:url('adminIndex/ban',array('id'=>$vo['id']))}" class="js-ajax-dialog-btn" data-msg="{:lang('BLOCK_USER_CONFIRM_MESSAGE')}">{:lang('BLOCK_USER')}</a> 54 + <a href="{:url('adminIndex/ban',array('id'=>$vo['id'],'mobile'=>$vo['mobile']))}" class="js-ajax-dialog-btn" data-msg="{:lang('BLOCK_USER_CONFIRM_MESSAGE')}">{:lang('BLOCK_USER')}</a>
56 <else /> 55 <else />
57 - <a href="{:url('adminIndex/cancelban',array('id'=>$vo['id']))}" class="js-ajax-dialog-btn" data-msg="{:lang('ACTIVATE_USER_CONFIRM_MESSAGE')}">{:lang('ACTIVATE_USER')}</a> 56 + <a href="{:url('adminIndex/cancelban',array('id'=>$vo['id'],'mobile'=>$vo['mobile']))}" class="js-ajax-dialog-btn" data-msg="{:lang('ACTIVATE_USER_CONFIRM_MESSAGE')}">{:lang('ACTIVATE_USER')}</a>
58 </if> 57 </if>
59 </td> 58 </td>
60 </tr> 59 </tr>