|
@@ -127,4 +127,40 @@ class VolunteerController extends AdminBaseController |
|
@@ -127,4 +127,40 @@ class VolunteerController extends AdminBaseController |
127
|
$this->success('操作成功!','');
|
127
|
$this->success('操作成功!','');
|
128
|
}
|
128
|
}
|
129
|
}
|
129
|
}
|
|
|
130
|
+
|
|
|
131
|
+ public function daochu(){
|
|
|
132
|
+ $where=[];
|
|
|
133
|
+ $param = $this->request->param();
|
|
|
134
|
+ $startTime = empty($param['start_time']) ? 0 : strtotime($param['start_time']);
|
|
|
135
|
+ $endTime = empty($param['end_time']) ? 0 : strtotime($param['end_time']);
|
|
|
136
|
+ if (!empty($startTime) && !empty($endTime)) {
|
|
|
137
|
+ $where['create_time'] = [['>= time', $startTime], ['<= time', $endTime]];
|
|
|
138
|
+ } else {
|
|
|
139
|
+ if (!empty($startTime)) {
|
|
|
140
|
+ $where['create_time'] = ['>= time', $startTime];
|
|
|
141
|
+ }
|
|
|
142
|
+ if (!empty($endTime)) {
|
|
|
143
|
+ $where['create_time'] = ['<= time', $endTime];
|
|
|
144
|
+ }
|
|
|
145
|
+ }
|
|
|
146
|
+ $category = empty($param['category']) ? '' : $param['category'];
|
|
|
147
|
+ if (!empty($category)) {
|
|
|
148
|
+ $where['status'] = ['eq', "$category"];
|
|
|
149
|
+ }
|
|
|
150
|
+ $type = empty($param['type']) ? '' : $param['type'];
|
|
|
151
|
+ if (!empty($type)) {
|
|
|
152
|
+ $where['type'] = ['eq', "$type"];
|
|
|
153
|
+ }
|
|
|
154
|
+ $keyword = empty($param['keyword']) ? '' : $param['keyword'];
|
|
|
155
|
+ if (!empty($keyword)) {
|
|
|
156
|
+ $where['name|province|city|county|email|move_phone|fixed_phone|card_number|school|postcode|nation|politics|sex|urgency_phone|qq'] = ['like', "%$keyword%"];
|
|
|
157
|
+ }
|
|
|
158
|
+ $data=Db::name('volunteer')
|
|
|
159
|
+ ->where('delete_time',0)
|
|
|
160
|
+ ->where($where)
|
|
|
161
|
+ ->order('create_time desc')
|
|
|
162
|
+ ->select();
|
|
|
163
|
+ dump($data);
|
|
|
164
|
+
|
|
|
165
|
+ }
|
130
|
} |
166
|
} |