Commit 128df5d5 by 徐高华

区间删导购

parent 20b4f4e7
......@@ -533,7 +533,7 @@ public class WxStaffController extends WebBaseController {
// 删除店员
@HttpLimit
@RequestMapping("/staff-del")
public HaobanResponse staffDel(String wxEnterpriseId, String storeId, String clerkIds, String staffId) {
public HaobanResponse staffDel(String wxEnterpriseId, String storeId1, String clerkIds, String staffId) {
if (StringUtils.isAnyBlank(clerkIds)) {
return resultResponse(HaoBanErrCode.ERR_2);
}
......@@ -547,7 +547,7 @@ public class WxStaffController extends WebBaseController {
logger.info("导购不存在", clerkId);
continue;
}
com.gic.enterprise.api.dto.StoreDTO store = storeService.getStoreByIdNoStatus(storeId);
com.gic.enterprise.api.dto.StoreDTO store = storeService.getStoreByIdNoStatus(clerkDTO.getStoreId());
AuditDTO auditDTO = auditApiService.findByBindRelatedIdAndAuditType(clerkId,
AuditType.CLERK_DEL.getCode(), wxEnterpriseId, store.getEnterpriseId());
if (auditDTO != null) {
......@@ -559,7 +559,7 @@ public class WxStaffController extends WebBaseController {
audit.setCommitStaffName(staff.getStaffName());
audit.setCommitStaffId(staffId);
audit.setCommitStaffImg(staff.getHeadImg());
audit.setCommitStoreId(storeId);
audit.setCommitStoreId(clerkDTO.getStoreId());
audit.setCommitStoreName(store.getStoreName());
audit.setAuditStatus(AuditStatus.NO_AUDIT.getCode());
audit.setWxEnterpriseId(wxEnterpriseId);
......@@ -587,19 +587,19 @@ public class WxStaffController extends WebBaseController {
logger.info("导购不存在:{}", clerkId);
continue;
}
if (distributeApiService.getClerkMemberCount(clerkDTO.getEnterpriseId(), clerkId, storeId) == 0) {
if (distributeApiService.getClerkMemberCount(clerkDTO.getEnterpriseId(), clerkId, clerkDTO.getStoreId()) == 0) {
if (clerkDTO.getClerkType() == 1) {
logger.info("店长不能删除:{}", clerkId);
continue;
}
}
com.gic.enterprise.api.dto.StoreDTO store = storeService.getStoreByIdNoStatus(storeId);
com.gic.enterprise.api.dto.StoreDTO store = storeService.getStoreByIdNoStatus(clerkDTO.getStoreId());
StaffDTO staff = staffApiService.selectById(staffId);
AuditDTO audit = new AuditDTO();
audit.setCommitStaffName(staff.getStaffName());
audit.setCommitStaffId(staffId);
audit.setCommitStaffImg(staff.getHeadImg());
audit.setCommitStoreId(storeId);
audit.setCommitStoreId(clerkDTO.getStoreId());
audit.setCommitStoreName(store.getStoreName());
audit.setAuditStatus(AuditStatus.NOT_NEED_AUDIT.getCode());
audit.setWxEnterpriseId(wxEnterpriseId);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment