refactor(work): remove BaseAuth enterprise wechat dao dependency
Made-with: Cursor
This commit is contained in:
@@ -217,3 +217,24 @@
|
||||
| 5 | `/adminapi/login/info` | GET | anonymous | 无 | 待预发填写 | 待预发填写 | 登录页配置 | 待测 | 当前本地无完整接口运行环境。 |
|
||||
| 5 | `/adminapi/jnotice` | GET | admin | token | 待预发填写 | 待预发填写 | 通知数据 | 待测 | 当前本地无 admin token。 |
|
||||
| 5 | `/supplierapi/jnotice` | GET | supplier | token | 待预发填写 | 待预发填写 | 通知数据 | 待测 | 当前本地无 supplier token。 |
|
||||
|
||||
## 阶段 6.1:企业微信 DAO 搜索
|
||||
|
||||
### 自动化检查
|
||||
|
||||
| 命令 | 结果 | 备注 |
|
||||
|------|------|------|
|
||||
| `php -l app/dao/work/WorkMemberDao.php` | 通过 | PHP 提示 `swoole_loader` 已加载,不影响语法检查结果。 |
|
||||
| `php -l app/dao/work/WorkWelcomeDao.php` | 通过 | PHP 提示 `swoole_loader` 已加载,不影响语法检查结果。 |
|
||||
| `php -l app/dao/work/WorkGroupMsgSendResultDao.php` | 通过 | PHP 提示 `swoole_loader` 已加载,不影响语法检查结果。 |
|
||||
| `php -l app/dao/work/WorkClientDao.php` | 通过 | PHP 提示 `swoole_loader` 已加载,不影响语法检查结果。 |
|
||||
| `php -l app/dao/work/WorkGroupMsgTaskDao.php` | 通过 | PHP 提示 `swoole_loader` 已加载,不影响语法检查结果。 |
|
||||
| `rg "BaseAuth" app/dao/work --glob "*.php"` | 通过 | 企业微信 DAO 已无 `BaseAuth` 引用。 |
|
||||
|
||||
### 手工回归记录
|
||||
|
||||
| 阶段 | 接口/命令 | 方法 | 身份 | 关键参数 | HTTP 状态 | 业务 `status` | 关键字段 | 结果 | 备注 |
|
||||
|------|-----------|------|------|----------|-----------|---------------|----------|------|------|
|
||||
| 6.1 | 企业微信客户列表 | GET | admin | token、筛选条件 | 待预发填写 | 待预发填写 | `list`、`count` | 待测 | 当前项目未启用企业微信,部署验证时确认明确错误或正常列表。 |
|
||||
| 6.1 | 企业微信成员列表 | GET | admin | token、筛选条件 | 待预发填写 | 待预发填写 | `list`、`count` | 待测 | 当前项目未启用企业微信,部署验证时确认明确错误或正常列表。 |
|
||||
| 6.1 | 企业微信欢迎语列表 | GET | admin | token、筛选条件 | 待预发填写 | 待预发填写 | `list`、`count` | 待测 | 当前项目未启用企业微信,部署验证时确认明确错误或正常列表。 |
|
||||
|
||||
@@ -8,7 +8,7 @@ namespace app\dao\work;
|
||||
|
||||
use app\dao\BaseDao;
|
||||
use app\model\work\WorkClient;
|
||||
use crmeb\basic\BaseAuth;
|
||||
use app\services\dao\SearchConditionBuilder;
|
||||
use crmeb\basic\BaseModel;
|
||||
use crmeb\traits\SearchDaoTrait;
|
||||
use think\db\exception\DbException;
|
||||
@@ -38,13 +38,7 @@ class WorkClientDao extends BaseDao
|
||||
*/
|
||||
public function searchWhere(array $where, bool $authWhere = true)
|
||||
{
|
||||
[$with, $whereKey] = app()->make(BaseAuth::class)->________(array_keys($where), $this->setModel());
|
||||
$whereData = [];
|
||||
foreach ($whereKey as $key) {
|
||||
if (isset($where[$key])) {
|
||||
$whereData[$key] = $where[$key];
|
||||
}
|
||||
}
|
||||
[$with] = app()->make(SearchConditionBuilder::class)->build(array_keys($where), $this->setModel());
|
||||
|
||||
return $this->getModel()->withSearch($with, $where)->when(!empty($where['label']) || !empty($where['notLabel']), function ($query) use ($where) {
|
||||
$query->whereIn('id', function ($query) use ($where) {
|
||||
|
||||
@@ -8,7 +8,7 @@ namespace app\dao\work;
|
||||
|
||||
use app\dao\BaseDao;
|
||||
use app\model\work\WorkGroupMsgSendResult;
|
||||
use crmeb\basic\BaseAuth;
|
||||
use app\services\dao\SearchConditionBuilder;
|
||||
use crmeb\traits\SearchDaoTrait;
|
||||
|
||||
/**
|
||||
@@ -35,13 +35,7 @@ class WorkGroupMsgSendResultDao extends BaseDao
|
||||
*/
|
||||
public function searchWhere(array $where, bool $authWhere = true)
|
||||
{
|
||||
[$with, $whereKey] = app()->make(BaseAuth::class)->________(array_keys($where), $this->setModel());
|
||||
$whereData = [];
|
||||
foreach ($whereKey as $key) {
|
||||
if (isset($where[$key]) && 'timeKey' !== $key) {
|
||||
$whereData[$key] = $where[$key];
|
||||
}
|
||||
}
|
||||
[$with] = app()->make(SearchConditionBuilder::class)->build(array_keys($where), $this->setModel());
|
||||
|
||||
return $this->getModel()->withSearch($with, $where)->when(!empty($where['client_name']), function ($query) use ($where) {
|
||||
$query->whereIn('external_userid', function ($query) use ($where) {
|
||||
|
||||
@@ -6,7 +6,7 @@ namespace app\dao\work;
|
||||
|
||||
use app\dao\BaseDao;
|
||||
use app\model\work\WorkGroupMsgTask;
|
||||
use crmeb\basic\BaseAuth;
|
||||
use app\services\dao\SearchConditionBuilder;
|
||||
use crmeb\traits\SearchDaoTrait;
|
||||
|
||||
/**
|
||||
@@ -33,13 +33,7 @@ class WorkGroupMsgTaskDao extends BaseDao
|
||||
*/
|
||||
public function searchWhere(array $where, bool $authWhere = true)
|
||||
{
|
||||
[$with, $whereKey] = app()->make(BaseAuth::class)->________(array_keys($where), $this->setModel());
|
||||
$whereData = [];
|
||||
foreach ($whereKey as $key) {
|
||||
if (isset($where[$key]) && 'timeKey' !== $key) {
|
||||
$whereData[$key] = $where[$key];
|
||||
}
|
||||
}
|
||||
[$with] = app()->make(SearchConditionBuilder::class)->build(array_keys($where), $this->setModel());
|
||||
|
||||
return $this->getModel()->withSearch($with, $where)->when(!empty($where['user_name']), function ($query) use ($where) {
|
||||
$query->whereIn('userid', function ($query) use ($where) {
|
||||
|
||||
@@ -8,7 +8,7 @@ namespace app\dao\work;
|
||||
|
||||
use app\dao\BaseDao;
|
||||
use app\model\work\WorkMember;
|
||||
use crmeb\basic\BaseAuth;
|
||||
use app\services\dao\SearchConditionBuilder;
|
||||
use crmeb\basic\BaseModel;
|
||||
use crmeb\traits\SearchDaoTrait;
|
||||
|
||||
@@ -37,7 +37,7 @@ class WorkMemberDao extends BaseDao
|
||||
*/
|
||||
public function searchWhere(array $where, bool $authWhere = true)
|
||||
{
|
||||
[$with] = app()->make(BaseAuth::class)->________(array_keys($where), $this->setModel());
|
||||
[$with] = app()->make(SearchConditionBuilder::class)->build(array_keys($where), $this->setModel());
|
||||
return $this->getModel()->withSearch($with, $where)
|
||||
->when(!empty($where['name']), function ($query) use ($where) {
|
||||
$query->where('id|name|mobile', 'like', '%' . $where['name'] . '%');
|
||||
|
||||
@@ -8,7 +8,7 @@ namespace app\dao\work;
|
||||
|
||||
use app\dao\BaseDao;
|
||||
use app\model\work\WorkWelcome;
|
||||
use crmeb\basic\BaseAuth;
|
||||
use app\services\dao\SearchConditionBuilder;
|
||||
use crmeb\basic\BaseModel;
|
||||
use crmeb\traits\SearchDaoTrait;
|
||||
|
||||
@@ -37,7 +37,7 @@ class WorkWelcomeDao extends BaseDao
|
||||
*/
|
||||
public function searchWhere(array $where, bool $authWhere = true)
|
||||
{
|
||||
[$with] = app()->make(BaseAuth::class)->________(array_keys($where), $this->setModel());
|
||||
[$with] = app()->make(SearchConditionBuilder::class)->build(array_keys($where), $this->setModel());
|
||||
|
||||
return $this->getModel()->withSearch($with, $where)->when(!empty($where['userids']), function ($query) use ($where) {
|
||||
$query->whereIn('id', function ($query) use ($where) {
|
||||
|
||||
Reference in New Issue
Block a user