导出用户优化

This commit is contained in:
evoxwht 2023-03-30 17:46:36 +08:00
parent 56efb28b32
commit 9b20b37749
4 changed files with 27 additions and 12 deletions

View File

@ -72,7 +72,8 @@ class ExportExcel extends AuthController
['label_id', ''],
['now_money', 'normal'],
['field_key', ''],
['isMember', '']
['isMember', ''],
['ids', []]
]);
return app('json')->success($this->service->exportUserList($where));
}

View File

@ -37,7 +37,11 @@ class UserLabel extends AuthController
/**
* 标签列表
* @param int $label_cate
* @return mixed
* @throws \think\db\exception\DataNotFoundException
* @throws \think\db\exception\DbException
* @throws \think\db\exception\ModelNotFoundException
*/
public function index($label_cate = 0)
{
@ -60,8 +64,10 @@ class UserLabel extends AuthController
/**
* 保存标签表单数据
* @param int $id
* @return mixed
* @throws \think\db\exception\DataNotFoundException
* @throws \think\db\exception\DbException
* @throws \think\db\exception\ModelNotFoundException
*/
public function save()
{

View File

@ -244,6 +244,10 @@ class UserWechatUserDao extends BaseDao
if (isset($where['is_del'])) {
$model->where($userAlias . 'is_del', $where['is_del']);
}
if (isset($where['ids']) && count($where['ids'])) {
$model->whereIn($userAlias . 'uid', $where['ids']);
}
return $field ? $model->field($field) : $model;
}

View File

@ -1043,6 +1043,9 @@ export default {
});
this.userFrom.label_id = activeIds.join(',');
}
if (this.ids.length) {
this.userFrom.ids = this.ids;
}
this.userFrom.user_type = this.userFrom.user_type || '';
this.userFrom.status = this.userFrom.status || '';
this.userFrom.sex = this.userFrom.sex || '';
@ -1353,14 +1356,15 @@ img {
color: #808695;
}
}
.demo-drawer-footer{
width: 100%;
position: absolute;
bottom: 0;
left: 0;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
background: #fff;
}
.demo-drawer-footer {
width: 100%;
position: absolute;
bottom: 0;
left: 0;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
background: #fff;
}
</style>