|
@@ -609,16 +609,20 @@ public class SapUserService extends BaseService {
|
|
|
SapPerPersonal perPersonal = sapPerPersonalService.selectOneByPersonId(user.getPersonId());
|
|
|
if (perPersonal != null) {
|
|
|
// 1 男 2 女
|
|
|
- if ("M".equals(perPersonal.getGender())) {
|
|
|
- reqdata.setSex(1);
|
|
|
- } else if ("F".equals(perPersonal.getGender())) {
|
|
|
- reqdata.setSex(2);
|
|
|
+ if (StringUtils.isNotBlank(perPersonal.getGender())) {
|
|
|
+ if ("M".equals(perPersonal.getGender())) {
|
|
|
+ reqdata.setSex(1);
|
|
|
+ } else if ("F".equals(perPersonal.getGender())) {
|
|
|
+ reqdata.setSex(2);
|
|
|
+ }
|
|
|
}
|
|
|
// 1 未婚 2 已婚[未婚/已婚/已育/离婚]
|
|
|
- if ("未婚".equals(perPersonal.getMaritalStatus()) || "离婚".equals(perPersonal.getMaritalStatus())) {
|
|
|
- reqdata.setMarriage(1);
|
|
|
- } else if ("已婚".equals(perPersonal.getMaritalStatus()) || "已育".equals(perPersonal.getMaritalStatus())) {
|
|
|
- reqdata.setMarriage(2);
|
|
|
+ if (StringUtils.isNotBlank(perPersonal.getMaritalStatus())) {
|
|
|
+ if ("未婚".equals(perPersonal.getMaritalStatus()) || "离婚".equals(perPersonal.getMaritalStatus())) {
|
|
|
+ reqdata.setMarriage(1);
|
|
|
+ } else if ("已婚".equals(perPersonal.getMaritalStatus()) || "已育".equals(perPersonal.getMaritalStatus())) {
|
|
|
+ reqdata.setMarriage(2);
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
String url = "http://cmcadmin.info666.com/hr/emp/modifyEmpInfo";
|