正在显示
6 个修改的文件
包含
141 行增加
和
67 行删除
@@ -54,17 +54,17 @@ class Item extends Backend | @@ -54,17 +54,17 @@ class Item extends Backend | ||
54 | list($where, $sort, $order, $offset, $limit) = $this->buildparams(); | 54 | list($where, $sort, $order, $offset, $limit) = $this->buildparams(); |
55 | 55 | ||
56 | $list = $this->model | 56 | $list = $this->model |
57 | - ->with(['user','ronda','radar','campus']) | ||
58 | - ->where($where) | ||
59 | - ->order($sort, $order) | ||
60 | - ->paginate($limit); | 57 | + ->with(['user','ronda','radar','campus']) |
58 | + ->where($where) | ||
59 | + ->order($sort, $order) | ||
60 | + ->paginate($limit); | ||
61 | 61 | ||
62 | foreach ($list as $row) { | 62 | foreach ($list as $row) { |
63 | - | 63 | + |
64 | $row->getRelation('user')->visible(['username','teach_phone']); | 64 | $row->getRelation('user')->visible(['username','teach_phone']); |
65 | - $row->getRelation('ronda')->visible(['title']); | ||
66 | - $row->getRelation('radar')->visible(['title']); | ||
67 | - $row->getRelation('campus')->visible(['title']); | 65 | + $row->getRelation('ronda')->visible(['title']); |
66 | + $row->getRelation('radar')->visible(['title']); | ||
67 | + $row->getRelation('campus')->visible(['title']); | ||
68 | } | 68 | } |
69 | 69 | ||
70 | $result = array("total" => $list->total(), "rows" => $list->items()); | 70 | $result = array("total" => $list->total(), "rows" => $list->items()); |
@@ -130,7 +130,7 @@ class Item extends Backend | @@ -130,7 +130,7 @@ class Item extends Backend | ||
130 | $res = db('study_score_log l') | 130 | $res = db('study_score_log l') |
131 | ->join('study s', 's.id = l.study_id') | 131 | ->join('study s', 's.id = l.study_id') |
132 | ->where('item_id', $data['id']) | 132 | ->where('item_id', $data['id']) |
133 | - ->field('l.study_id,sum(l.score) as sum_score,s.name,s.unique,s.team_id,s.school,s.grade') | 133 | + ->field('l.study_id,sum(l.score) as sum_score,s.name,s.unique,s.team,s.school,s.grade') |
134 | ->group('l.study_id') | 134 | ->group('l.study_id') |
135 | ->order('sum_score', 'desc') | 135 | ->order('sum_score', 'desc') |
136 | ->select(); | 136 | ->select(); |
@@ -139,7 +139,7 @@ class Item extends Backend | @@ -139,7 +139,7 @@ class Item extends Backend | ||
139 | $list[] = [ | 139 | $list[] = [ |
140 | 'name' => $v['name'], | 140 | 'name' => $v['name'], |
141 | 'unique' => $v['unique'], | 141 | 'unique' => $v['unique'], |
142 | - 'title' => db('team')->where('id',$v['team_id'])->value('title'), | 142 | + 'title' => db('team')->where('title',$v['team'])->value('title'), |
143 | 'school' => $v['school'], | 143 | 'school' => $v['school'], |
144 | 'grade' => $v['grade'], | 144 | 'grade' => $v['grade'], |
145 | 'score' => $v['sum_score'] | 145 | 'score' => $v['sum_score'] |
1 | <?php | 1 | <?php |
2 | 2 | ||
3 | return [ | 3 | return [ |
4 | - 'Campus_id' => '届次', | ||
5 | - 'Ronda_id' => '所属场次', | ||
6 | - 'Title' => '项目名称', | ||
7 | - 'Radar_id' => '所属维度', | ||
8 | - 'User_id' => '所属老师', | ||
9 | - 'Details' => '项目详情', | ||
10 | - 'Score' => '可获积分', | ||
11 | - 'Createtime' => '创建时间', | ||
12 | - 'Updatetime' => '更新时间', | ||
13 | - 'User.username' => '用户名', | ||
14 | - 'User.teach_phone' => '老师手机号', | ||
15 | - 'Ronda.title' => '场次名称', | ||
16 | - 'Radar.title' => '维度名称', | ||
17 | - 'Campus.title' => '届次' | 4 | + 'Title' => '名称', |
5 | + 'Details' => '详情', | ||
6 | + 'Ronda_ids' => '场次', | ||
7 | + 'Campus_ids' => '校区', | ||
8 | + 'Radar_ids' => '所属维度', | ||
9 | + 'User_id' => '所属老师', | ||
10 | + 'Images' => '项目图片', | ||
11 | + 'Score' => '积分', | ||
12 | + 'Createtime' => '创建时间', | ||
13 | + 'Updatetime' => '更新时间', | ||
14 | + 'Campus.title' => '校区名称', | ||
15 | + 'Ronda.title' => '场次名称', | ||
16 | + 'Radar.title' => '维度名称', | ||
17 | + 'User.id' => 'ID', | ||
18 | + 'User.group_id' => '组别ID', | ||
19 | + 'User.username' => '用户名', | ||
20 | + 'User.nickname' => '昵称', | ||
21 | + 'User.password' => '密码', | ||
22 | + 'User.salt' => '密码盐', | ||
23 | + 'User.email' => '电子邮箱', | ||
24 | + 'User.mobile' => '手机号', | ||
25 | + 'User.avatar' => '头像', | ||
26 | + 'User.level' => '等级', | ||
27 | + 'User.gender' => '性别', | ||
28 | + 'User.birthday' => '生日', | ||
29 | + 'User.bio' => '格言', | ||
30 | + 'User.money' => '余额', | ||
31 | + 'User.score' => '积分', | ||
32 | + 'User.successions' => '连续登录天数', | ||
33 | + 'User.maxsuccessions' => '最大连续登录天数', | ||
34 | + 'User.prevtime' => '上次登录时间', | ||
35 | + 'User.logintime' => '登录时间', | ||
36 | + 'User.loginip' => '登录IP', | ||
37 | + 'User.loginfailure' => '失败次数', | ||
38 | + 'User.joinip' => '加入IP', | ||
39 | + 'User.jointime' => '加入时间', | ||
40 | + 'User.createtime' => '创建时间', | ||
41 | + 'User.updatetime' => '更新时间', | ||
42 | + 'User.token' => 'Token', | ||
43 | + 'User.status' => '状态', | ||
44 | + 'User.verification' => '验证', | ||
45 | + 'User.teach_phone' => '老师手机号', | ||
46 | + 'User.is_teach' => '是否为老师', | ||
47 | + 'User.is_teach 0' => '否', | ||
48 | + 'User.is_teach 1' => '是', | ||
49 | + 'User.bind_study' => '是否绑定学生信息', | ||
50 | + 'User.bind_study 0' => '否', | ||
51 | + 'User.bind_study 1' => '是' | ||
18 | ]; | 52 | ]; |
@@ -25,35 +25,38 @@ class Item extends Model | @@ -25,35 +25,38 @@ class Item extends Model | ||
25 | 25 | ||
26 | // 追加属性 | 26 | // 追加属性 |
27 | protected $append = [ | 27 | protected $append = [ |
28 | - 'campus_text' | 28 | + |
29 | ]; | 29 | ]; |
30 | + | ||
30 | 31 | ||
31 | - public function getCampusTextAttr($value,$data){ | ||
32 | - $cid = db('ronda')->where('id',$data['ronda_id'])->value('campus_id'); | ||
33 | - $list = db('campus')->where('id',$cid)->value('title'); | ||
34 | - return $list; | ||
35 | - } | 32 | + |
36 | 33 | ||
37 | 34 | ||
38 | 35 | ||
39 | - public function user() | 36 | + |
37 | + | ||
38 | + | ||
39 | + | ||
40 | + public function campus() | ||
40 | { | 41 | { |
41 | - return $this->belongsTo('User', 'user_id', 'id', [], 'LEFT')->setEagerlyType(0); | 42 | + return $this->belongsTo('Campus', 'campus_ids', 'id', [], 'LEFT')->setEagerlyType(0); |
42 | } | 43 | } |
43 | 44 | ||
45 | + | ||
44 | public function ronda() | 46 | public function ronda() |
45 | { | 47 | { |
46 | - return $this->belongsTo('Ronda', 'ronda_id', 'id', [], 'LEFT')->setEagerlyType(0); | 48 | + return $this->belongsTo('Ronda', 'ronda_ids', 'id', [], 'LEFT')->setEagerlyType(0); |
47 | } | 49 | } |
48 | 50 | ||
49 | 51 | ||
50 | public function radar() | 52 | public function radar() |
51 | { | 53 | { |
52 | - return $this->belongsTo('Radar', 'radar_id', 'id', [], 'LEFT')->setEagerlyType(0); | 54 | + return $this->belongsTo('Radar', 'radar_ids', 'id', [], 'LEFT')->setEagerlyType(0); |
53 | } | 55 | } |
54 | 56 | ||
55 | - public function campus() | 57 | + |
58 | + public function user() | ||
56 | { | 59 | { |
57 | - return $this->belongsTo('Campus', 'campus_id', 'id', [], 'LEFT')->setEagerlyType(0); | 60 | + return $this->belongsTo('User', 'user_id', 'nickname', [], 'LEFT')->setEagerlyType(0); |
58 | } | 61 | } |
59 | } | 62 | } |
@@ -7,39 +7,53 @@ | @@ -7,39 +7,53 @@ | ||
7 | </div> | 7 | </div> |
8 | </div> | 8 | </div> |
9 | <div class="form-group"> | 9 | <div class="form-group"> |
10 | - <label class="control-label col-xs-12 col-sm-2">{:__('Campus_id')}:</label> | 10 | + <label class="control-label col-xs-12 col-sm-2">{:__('Ronda_ids')}:</label> |
11 | <div class="col-xs-12 col-sm-8"> | 11 | <div class="col-xs-12 col-sm-8"> |
12 | - <input id="c-campus_id" data-rule="required" data-source="campus/index" class="form-control selectpage" data-field="title" name="row[campus_id]" type="text" value=""> | 12 | + <input id="c-ronda_ids" data-rule="required" data-source="ronda/index" data-multiple="true" data-field="title" class="form-control selectpage" name="row[ronda_ids]" type="text" value=""> |
13 | </div> | 13 | </div> |
14 | </div> | 14 | </div> |
15 | <div class="form-group"> | 15 | <div class="form-group"> |
16 | - <label class="control-label col-xs-12 col-sm-2">{:__('Ronda_id')}:</label> | 16 | + <label class="control-label col-xs-12 col-sm-2">{:__('Campus_ids')}:</label> |
17 | <div class="col-xs-12 col-sm-8"> | 17 | <div class="col-xs-12 col-sm-8"> |
18 | - <input id="c-ronda_id" data-rule="required" data-source="ronda/index" class="form-control" data-field="id" name="row[ronda_id]" type="text" value=""> | 18 | + <input id="c-campus_ids" data-rule="required" data-source="campus/index" data-multiple="true" data-field="title" class="form-control selectpage" name="row[campus_ids]" type="text" value=""> |
19 | </div> | 19 | </div> |
20 | </div> | 20 | </div> |
21 | <div class="form-group"> | 21 | <div class="form-group"> |
22 | - <label class="control-label col-xs-12 col-sm-2">{:__('Radar_id')}:</label> | 22 | + <label class="control-label col-xs-12 col-sm-2">{:__('Radar_ids')}:</label> |
23 | <div class="col-xs-12 col-sm-8"> | 23 | <div class="col-xs-12 col-sm-8"> |
24 | - <input id="c-radar_id" data-rule="required" data-source="radar/index" class="form-control selectpage" data-field="title" name="row[radar_id]" type="text" value=""> | 24 | + <input id="c-radar_ids" data-rule="required" data-source="radar/index" data-multiple="true" data-field="title" class="form-control selectpage" name="row[radar_ids]" type="text" value=""> |
25 | </div> | 25 | </div> |
26 | </div> | 26 | </div> |
27 | <div class="form-group"> | 27 | <div class="form-group"> |
28 | <label class="control-label col-xs-12 col-sm-2">{:__('User_id')}:</label> | 28 | <label class="control-label col-xs-12 col-sm-2">{:__('User_id')}:</label> |
29 | <div class="col-xs-12 col-sm-8"> | 29 | <div class="col-xs-12 col-sm-8"> |
30 | - <input id="c-user_id" data-rule="required" data-source="user/user/index" data-field="nickname" class="form-control selectpage" name="row[user_id]" type="text" value=""> | 30 | + <input id="c-user_id" data-rule="required" data-source="user/user/index" data-field="nickname" class="form-control selectpage" name="row[user_id]" type="text" value=""> |
31 | + </div> | ||
32 | + </div> | ||
33 | + <div class="form-group"> | ||
34 | + <label class="control-label col-xs-12 col-sm-2">{:__('Images')}:</label> | ||
35 | + <div class="col-xs-12 col-sm-8"> | ||
36 | + <div class="input-group"> | ||
37 | + <input id="c-images" class="form-control" size="50" name="row[images]" type="text"> | ||
38 | + <div class="input-group-addon no-border no-padding"> | ||
39 | + <span><button type="button" id="faupload-images" class="btn btn-danger faupload" data-input-id="c-images" data-mimetype="image/gif,image/jpeg,image/png,image/jpg,image/bmp,image/webp" data-multiple="true" data-preview-id="p-images"><i class="fa fa-upload"></i> {:__('Upload')}</button></span> | ||
40 | + <span><button type="button" id="fachoose-images" class="btn btn-primary fachoose" data-input-id="c-images" data-mimetype="image/*" data-multiple="true"><i class="fa fa-list"></i> {:__('Choose')}</button></span> | ||
41 | + </div> | ||
42 | + <span class="msg-box n-right" for="c-images"></span> | ||
43 | + </div> | ||
44 | + <ul class="row list-inline faupload-preview" id="p-images"></ul> | ||
31 | </div> | 45 | </div> |
32 | </div> | 46 | </div> |
33 | <div class="form-group"> | 47 | <div class="form-group"> |
34 | <label class="control-label col-xs-12 col-sm-2">{:__('Score')}:</label> | 48 | <label class="control-label col-xs-12 col-sm-2">{:__('Score')}:</label> |
35 | <div class="col-xs-12 col-sm-8"> | 49 | <div class="col-xs-12 col-sm-8"> |
36 | - <input id="c-score" class="form-control" step="0.01" name="row[score]" type="number"> | 50 | + <input id="c-score" class="form-control" step="0.01" name="row[score]" type="text"> |
37 | </div> | 51 | </div> |
38 | </div> | 52 | </div> |
39 | <div class="form-group"> | 53 | <div class="form-group"> |
40 | <label class="control-label col-xs-12 col-sm-2">{:__('Details')}:</label> | 54 | <label class="control-label col-xs-12 col-sm-2">{:__('Details')}:</label> |
41 | <div class="col-xs-12 col-sm-8"> | 55 | <div class="col-xs-12 col-sm-8"> |
42 | - <textarea id="c-details" class="form-control" rows="5" name="row[details]" cols="50"></textarea> | 56 | + <textarea id="c-details" class="form-control " rows="5" name="row[details]" cols="50"></textarea> |
43 | </div> | 57 | </div> |
44 | </div> | 58 | </div> |
45 | <div class="form-group layer-footer"> | 59 | <div class="form-group layer-footer"> |
@@ -7,39 +7,53 @@ | @@ -7,39 +7,53 @@ | ||
7 | </div> | 7 | </div> |
8 | </div> | 8 | </div> |
9 | <div class="form-group"> | 9 | <div class="form-group"> |
10 | - <label class="control-label col-xs-12 col-sm-2">{:__('Campus_id')}:</label> | 10 | + <label class="control-label col-xs-12 col-sm-2">{:__('Ronda_ids')}:</label> |
11 | <div class="col-xs-12 col-sm-8"> | 11 | <div class="col-xs-12 col-sm-8"> |
12 | - <input id="c-campus_id" data-rule="required" data-source="campus/index" class="form-control selectpage" name="row[campus_id]" data-field="title" type="text" value="{$row.campus_id|htmlentities}"> | 12 | + <input id="c-ronda_ids" data-rule="required" data-source="ronda/index" data-multiple="true" data-field="title" class="form-control selectpage" name="row[ronda_ids]" type="text" value="{$row.ronda_ids|htmlentities}"> |
13 | </div> | 13 | </div> |
14 | </div> | 14 | </div> |
15 | <div class="form-group"> | 15 | <div class="form-group"> |
16 | - <label class="control-label col-xs-12 col-sm-2">{:__('Ronda_id')}:</label> | 16 | + <label class="control-label col-xs-12 col-sm-2">{:__('Campus_ids')}:</label> |
17 | <div class="col-xs-12 col-sm-8"> | 17 | <div class="col-xs-12 col-sm-8"> |
18 | - <input id="c-ronda_id" data-rule="required" data-source="ronda/index" class="form-control" name="row[ronda.title]" data-field="title" type="text" value="{$row.ronda.title|htmlentities}"> | 18 | + <input id="c-campus_ids" data-rule="required" data-source="campus/index" data-multiple="true" data-field="title" class="form-control selectpage" name="row[campus_ids]" type="text" value="{$row.campus_ids|htmlentities}"> |
19 | </div> | 19 | </div> |
20 | </div> | 20 | </div> |
21 | <div class="form-group"> | 21 | <div class="form-group"> |
22 | - <label class="control-label col-xs-12 col-sm-2">{:__('Radar_id')}:</label> | 22 | + <label class="control-label col-xs-12 col-sm-2">{:__('Radar_ids')}:</label> |
23 | <div class="col-xs-12 col-sm-8"> | 23 | <div class="col-xs-12 col-sm-8"> |
24 | - <input id="c-radar_id" data-rule="required" data-source="radar/index" class="form-control selectpage" name="row[radar_id]" data-field="title" type="text" value="{$row.radar_id|htmlentities}"> | 24 | + <input id="c-radar_ids" data-rule="required" data-source="radar/index" data-multiple="true" data-field="title" class="form-control selectpage" name="row[radar_ids]" type="text" value="{$row.radar_ids|htmlentities}"> |
25 | </div> | 25 | </div> |
26 | </div> | 26 | </div> |
27 | <div class="form-group"> | 27 | <div class="form-group"> |
28 | <label class="control-label col-xs-12 col-sm-2">{:__('User_id')}:</label> | 28 | <label class="control-label col-xs-12 col-sm-2">{:__('User_id')}:</label> |
29 | <div class="col-xs-12 col-sm-8"> | 29 | <div class="col-xs-12 col-sm-8"> |
30 | - <input id="c-user_id" data-rule="required" data-source="user/user/index" data-field="username" class="form-control selectpage" name="row[user_id]" type="text" value="{$row.user_id|htmlentities}"> | 30 | + <input id="c-user_id" data-rule="required" data-source="user/user/index" data-field="nickname" class="form-control selectpage" name="row[user_id]" type="text" value="{$row.user_id|htmlentities}"> |
31 | + </div> | ||
32 | + </div> | ||
33 | + <div class="form-group"> | ||
34 | + <label class="control-label col-xs-12 col-sm-2">{:__('Images')}:</label> | ||
35 | + <div class="col-xs-12 col-sm-8"> | ||
36 | + <div class="input-group"> | ||
37 | + <input id="c-images" class="form-control" size="50" name="row[images]" type="text" value="{$row.images|htmlentities}"> | ||
38 | + <div class="input-group-addon no-border no-padding"> | ||
39 | + <span><button type="button" id="faupload-images" class="btn btn-danger faupload" data-input-id="c-images" data-mimetype="image/gif,image/jpeg,image/png,image/jpg,image/bmp,image/webp" data-multiple="true" data-preview-id="p-images"><i class="fa fa-upload"></i> {:__('Upload')}</button></span> | ||
40 | + <span><button type="button" id="fachoose-images" class="btn btn-primary fachoose" data-input-id="c-images" data-mimetype="image/*" data-multiple="true"><i class="fa fa-list"></i> {:__('Choose')}</button></span> | ||
41 | + </div> | ||
42 | + <span class="msg-box n-right" for="c-images"></span> | ||
43 | + </div> | ||
44 | + <ul class="row list-inline faupload-preview" id="p-images"></ul> | ||
31 | </div> | 45 | </div> |
32 | </div> | 46 | </div> |
33 | <div class="form-group"> | 47 | <div class="form-group"> |
34 | <label class="control-label col-xs-12 col-sm-2">{:__('Score')}:</label> | 48 | <label class="control-label col-xs-12 col-sm-2">{:__('Score')}:</label> |
35 | <div class="col-xs-12 col-sm-8"> | 49 | <div class="col-xs-12 col-sm-8"> |
36 | - <input id="c-score" class="form-control" step="0.01" name="row[score]" type="number" value="{$row.score|htmlentities}"> | 50 | + <input id="c-score" class="form-control" step="0.01" name="row[score]" type="text" value="{$row.score|htmlentities}"> |
37 | </div> | 51 | </div> |
38 | </div> | 52 | </div> |
39 | <div class="form-group"> | 53 | <div class="form-group"> |
40 | <label class="control-label col-xs-12 col-sm-2">{:__('Details')}:</label> | 54 | <label class="control-label col-xs-12 col-sm-2">{:__('Details')}:</label> |
41 | <div class="col-xs-12 col-sm-8"> | 55 | <div class="col-xs-12 col-sm-8"> |
42 | - <textarea id="c-details" class="form-control" rows="5" name="row[details]" cols="50">{$row.details|htmlentities}</textarea> | 56 | + <textarea id="c-details" class="form-control editor" rows="5" name="row[details]" cols="50">{$row.details|htmlentities}</textarea> |
43 | </div> | 57 | </div> |
44 | </div> | 58 | </div> |
45 | <div class="form-group layer-footer"> | 59 | <div class="form-group layer-footer"> |
@@ -2,7 +2,7 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin | @@ -2,7 +2,7 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin | ||
2 | 2 | ||
3 | var Controller = { | 3 | var Controller = { |
4 | index: function () { | 4 | index: function () { |
5 | - // 初始化表格参数配置 | 5 | +// 初始化表格参数配置 |
6 | Table.api.init({ | 6 | Table.api.init({ |
7 | extend: { | 7 | extend: { |
8 | index_url: 'item/index' + location.search, | 8 | index_url: 'item/index' + location.search, |
@@ -17,7 +17,7 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin | @@ -17,7 +17,7 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin | ||
17 | 17 | ||
18 | var table = $("#table"); | 18 | var table = $("#table"); |
19 | 19 | ||
20 | - // 初始化表格 | 20 | +// 初始化表格 |
21 | table.bootstrapTable({ | 21 | table.bootstrapTable({ |
22 | url: $.fn.bootstrapTable.defaults.extend.index_url, | 22 | url: $.fn.bootstrapTable.defaults.extend.index_url, |
23 | pk: 'id', | 23 | pk: 'id', |
@@ -26,7 +26,7 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin | @@ -26,7 +26,7 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin | ||
26 | fixedRightNumber: 1, | 26 | fixedRightNumber: 1, |
27 | showToggle: false,//浏览模式功能关闭 | 27 | showToggle: false,//浏览模式功能关闭 |
28 | showColumns: false,//显示隐藏列功能关闭 | 28 | showColumns: false,//显示隐藏列功能关闭 |
29 | - //commonSearch: false, //关闭通用搜索按钮 | 29 | +//commonSearch: false, //关闭通用搜索按钮 |
30 | showExport: false,//导出功能关闭 | 30 | showExport: false,//导出功能关闭 |
31 | clickToSelect: false, //是否启用点击选中 | 31 | clickToSelect: false, //是否启用点击选中 |
32 | dblClickToEdit: false, //是否启用双击编辑 | 32 | dblClickToEdit: false, //是否启用双击编辑 |
@@ -34,20 +34,28 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin | @@ -34,20 +34,28 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin | ||
34 | [ | 34 | [ |
35 | {checkbox: true}, | 35 | {checkbox: true}, |
36 | {field: 'id', title: __('Id'), operate: false}, | 36 | {field: 'id', title: __('Id'), operate: false}, |
37 | - // {field: 'campus_id', title: __('Campus_id')}, | ||
38 | - // {field: 'ronda_id', title: __('Ronda_id')}, | 37 | +// {field: 'campus_id', title: __('Campus_id')}, |
38 | +// {field: 'ronda_id', title: __('Ronda_id')}, | ||
39 | {field: 'campus.title', title: __('所属校区'), operate: 'LIKE'}, | 39 | {field: 'campus.title', title: __('所属校区'), operate: 'LIKE'}, |
40 | {field: 'ronda.title', title: __('场次'), operate: false}, | 40 | {field: 'ronda.title', title: __('场次'), operate: false}, |
41 | {field: 'title', title: __('Title'), operate: 'LIKE'}, | 41 | {field: 'title', title: __('Title'), operate: 'LIKE'}, |
42 | - // {field: 'radar_id', title: __('Radar_id')}, | ||
43 | - // {field: 'user_id', title: __('User_id')}, | ||
44 | - {field: 'score', title: __('可获积分'), operate:false}, | 42 | +// {field: 'radar_id', title: __('Radar_id')}, |
43 | +// {field: 'user_id', title: __('User_id')}, | ||
44 | + {field: 'score', title: __('可获积分'), operate: false}, | ||
45 | {field: 'user.nickname', title: __('管理老师'), operate: false}, | 45 | {field: 'user.nickname', title: __('管理老师'), operate: false}, |
46 | {field: 'user.teach_phone', title: __('User.teach_phone'), operate: false}, | 46 | {field: 'user.teach_phone', title: __('User.teach_phone'), operate: false}, |
47 | {field: 'radar.title', title: __('Radar.title'), operate: false}, | 47 | {field: 'radar.title', title: __('Radar.title'), operate: false}, |
48 | - {field: 'createtime', title: __('Createtime'), operate:false, addclass:'datetimerange', autocomplete:false, formatter: Table.api.formatter.datetime}, | ||
49 | - //{field: 'updatetime', title: __('Updatetime'), operate:'RANGE', addclass:'datetimerange', autocomplete:false, formatter: Table.api.formatter.datetime}, | ||
50 | - {field: 'operate', title: __('Operate'), table: table, events: Table.api.events.operate, | 48 | + { |
49 | + field: 'createtime', | ||
50 | + title: __('Createtime'), | ||
51 | + operate: false, | ||
52 | + addclass: 'datetimerange', | ||
53 | + autocomplete: false, | ||
54 | + formatter: Table.api.formatter.datetime | ||
55 | + }, | ||
56 | +//{field: 'updatetime', title: __('Updatetime'), operate:'RANGE', addclass:'datetimerange', autocomplete:false, formatter: Table.api.formatter.datetime}, | ||
57 | + { | ||
58 | + field: 'operate', title: __('Operate'), table: table, events: Table.api.events.operate, | ||
51 | buttons: [ | 59 | buttons: [ |
52 | { | 60 | { |
53 | name: 'details', | 61 | name: 'details', |
@@ -61,12 +69,13 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin | @@ -61,12 +69,13 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin | ||
61 | }, | 69 | }, |
62 | }, | 70 | }, |
63 | ], | 71 | ], |
64 | - formatter: Table.api.formatter.operate} | 72 | + formatter: Table.api.formatter.operate |
73 | + } | ||
65 | ] | 74 | ] |
66 | ] | 75 | ] |
67 | }); | 76 | }); |
68 | 77 | ||
69 | - // 为表格绑定事件 | 78 | +// 为表格绑定事件 |
70 | Table.api.bindevent(table); | 79 | Table.api.bindevent(table); |
71 | }, | 80 | }, |
72 | add: function () { | 81 | add: function () { |
-
请 注册 或 登录 后发表评论