优化了agent

This commit is contained in:
lik
2026-10-31 18:51:20 +08:00
parent ab584c5fa8
commit 02d57f82dc
22 changed files with 193 additions and 155 deletions
+1 -2
View File
@@ -249,8 +249,7 @@ EmployeeSchema.statics.findOnlineAttendants = async function (options = {}) {
// ==================== 索引定义 ====================
EmployeeSchema.index({ "profile.name": 1 });
EmployeeSchema.index({ employeeNo: 1 });
EmployeeSchema.index({ userId: 1 });
// 注意:employeeNo(unique+sparse)与 userId 的索引在字段定义处声明,勿在此重复声明
EmployeeSchema.index({ orgId: 1, role: 1, status: 1 });
EmployeeSchema.index({ role: 1, status: 1 });
EmployeeSchema.index({ "profile.phone": 1 });