|
@@ -16,7 +16,9 @@ import org.fouram.core.util.ConfConfig;
|
|
|
import org.fouram.core.util.JSONUtil;
|
|
|
import org.fouram.core.util.JsonNodeUtil;
|
|
|
import org.fouram.core.util.Tools;
|
|
|
+import org.fouram.dto.input.GetCancelIngoreListDTO;
|
|
|
import org.fouram.dto.input.GetToBeConfirmedListDTO;
|
|
|
+import org.fouram.dto.output.GetCancelIngoreListOutput;
|
|
|
import org.fouram.dto.output.GetToBeConfirmedListOutput;
|
|
|
import org.fouram.entity.SapOrg;
|
|
|
import org.fouram.entity.SapUser;
|
|
@@ -96,6 +98,10 @@ public class SapUserService extends BaseService {
|
|
|
if (sapUserDb == null) {
|
|
|
this.saveSapUser(sapUser);
|
|
|
} else {
|
|
|
+ // 如果是忽略INGORE,保留INGORE状态
|
|
|
+ if(SapUserResultEnum.INGORE.getCode().equals(sapUserDb.getResult())) {
|
|
|
+ sapUser.setResult(SapUserResultEnum.INGORE.getCode());
|
|
|
+ }
|
|
|
this.updateSapUser(sapUser);
|
|
|
}
|
|
|
}
|
|
@@ -396,6 +402,15 @@ public class SapUserService extends BaseService {
|
|
|
public void updateIngore(String personId) throws Exception {
|
|
|
updateResultByUserId(SapUserResultEnum.INGORE.getCode(), personId);
|
|
|
}
|
|
|
+
|
|
|
+ public void updateCancelIngore(String personId) throws Exception {
|
|
|
+ SapUser sapUser = selectByUserId(personId);
|
|
|
+ String result = getCheckResultByWx(sapUser);
|
|
|
+ if(StringUtils.isBlank(result)) {
|
|
|
+ result = SapUserResultEnum.NORMAL.getCode();
|
|
|
+ }
|
|
|
+ updateResultByUserId(result, personId);
|
|
|
+ }
|
|
|
|
|
|
public void updateAllNormalSyncWxResult() throws Exception {
|
|
|
List<SapUser> normalSapUsers = this.selectPrimaryListByResult(SapUserResultEnum.NORMAL.getCode());
|
|
@@ -403,4 +418,18 @@ public class SapUserService extends BaseService {
|
|
|
this.updateSyncWxResult(sapUser.getPersonId());
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
+ @SuppressWarnings("unchecked")
|
|
|
+ public GetCancelIngoreListOutput selectCancelIngorePrimaryList(GetCancelIngoreListDTO dto) throws Exception {
|
|
|
+ PageData pd = new PageData();
|
|
|
+ pd.put("name", dto.getName());
|
|
|
+ pd.put("result", SapUserResultEnum.INGORE.getCode());
|
|
|
+ if (dto.getPageNumber() != null && dto.getPageSize() != null) {
|
|
|
+ pd.put("pageCurrent", String.valueOf(dto.getPageSize() * (dto.getPageNumber() - 1)));
|
|
|
+ pd.put("pageSize", String.valueOf(dto.getPageSize()));
|
|
|
+ }
|
|
|
+ List<SapUser> data = (List<SapUser>) findList("SapUserMapper.selectCancelIngorePrimaryList", pd);
|
|
|
+ Long total = (Long) findObject("SapUserMapper.selectCancelIngorePrimaryTotal", dto);
|
|
|
+ return GetCancelIngoreListOutput.builder().data(toInfoDetails(data)).total(total).build();
|
|
|
+ }
|
|
|
}
|