|
|
|
@ -6,6 +6,8 @@ import com.api.browser.bean.SearchConditionOption;
|
|
|
|
|
import com.api.browser.util.ConditionType;
|
|
|
|
|
import com.api.hrm.bean.HrmFieldBean;
|
|
|
|
|
import com.api.hrm.util.HrmFieldSearchConditionComInfo;
|
|
|
|
|
import com.cloudstore.eccom.constant.WeaBoolAttr;
|
|
|
|
|
import com.cloudstore.eccom.pc.table.WeaTableColumn;
|
|
|
|
|
import com.cloudstore.eccom.result.WeaResultMsg;
|
|
|
|
|
import com.engine.core.impl.Service;
|
|
|
|
|
import com.engine.hrm.util.face.HrmFaceCheckManager;
|
|
|
|
@ -40,6 +42,7 @@ import com.engine.organization.util.OrganizationAssert;
|
|
|
|
|
import com.engine.organization.util.db.DBType;
|
|
|
|
|
import com.engine.organization.util.db.MapperProxyFactory;
|
|
|
|
|
import com.engine.organization.util.detach.DetachUtil;
|
|
|
|
|
import com.engine.organization.util.page.Column;
|
|
|
|
|
import com.engine.organization.util.page.PageUtil;
|
|
|
|
|
import com.engine.organization.util.tree.SearchTreeUtil;
|
|
|
|
|
import org.apache.commons.collections.CollectionUtils;
|
|
|
|
@ -74,6 +77,9 @@ public class HrmResourceServiceImpl extends Service implements HrmResourceServic
|
|
|
|
|
|
|
|
|
|
private static final String RIGHT_NAME = "Roster:All";
|
|
|
|
|
|
|
|
|
|
private static final String level = getFieldName("职等");
|
|
|
|
|
private static final String grade = getFieldName("职级");
|
|
|
|
|
|
|
|
|
|
private HrmRelationMapper getHrmRelationMapper() {
|
|
|
|
|
return MapperProxyFactory.getProxy(HrmRelationMapper.class);
|
|
|
|
|
}
|
|
|
|
@ -118,6 +124,22 @@ public class HrmResourceServiceImpl extends Service implements HrmResourceServic
|
|
|
|
|
OrganizationWeaTable<HrmResourceVO> table = new OrganizationWeaTable<>(user, HrmResourceVO.class);
|
|
|
|
|
String sqlWhere = buildSqlWhere(params);
|
|
|
|
|
table.setSqlwhere(sqlWhere);
|
|
|
|
|
|
|
|
|
|
List<WeaTableColumn> weaTableColumnList = new ArrayList<>();
|
|
|
|
|
WeaTableColumn weaTableColumn = new WeaTableColumn();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
List<com.alibaba.fastjson.JSONObject> jsonObjectList = getHrmResourceMapper().queryAllResColumns(level,grade);
|
|
|
|
|
// for (com.alibaba.fastjson.JSONObject jsonObject : jsonObjectList){
|
|
|
|
|
// System.out.println(jsonObject.getString("level_name"));
|
|
|
|
|
// weaTableColumn.setText("职等");
|
|
|
|
|
// weaTableColumn.setDisplay(WeaBoolAttr.TRUE);
|
|
|
|
|
// weaTableColumn.setColumn("levelName");
|
|
|
|
|
// weaTableColumnList.add(weaTableColumn);
|
|
|
|
|
// }
|
|
|
|
|
// table.setColumns(weaTableColumnList);
|
|
|
|
|
|
|
|
|
|
// weaTableColumnList = columns.stream().map(v -> new WeaTableColumn("100", v.getTitle(), v.getKey())).collect(Collectors.toList());
|
|
|
|
|
WeaResultMsg result = new WeaResultMsg(false);
|
|
|
|
|
result.putAll(table.makeDataResult());
|
|
|
|
|
result.success();
|
|
|
|
@ -869,4 +891,14 @@ public class HrmResourceServiceImpl extends Service implements HrmResourceServic
|
|
|
|
|
options.add(0, searchConditionOption);
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private static String getFieldName(String fieldabel) {
|
|
|
|
|
RecordSet recordSet = new RecordSet();
|
|
|
|
|
String fieldname = null;
|
|
|
|
|
recordSet.executeQuery("select fieldname from jcl_org_field where fieldlabel='" + fieldabel+"'");
|
|
|
|
|
if (recordSet.next()) {
|
|
|
|
|
fieldname = recordSet.getString("fieldname");
|
|
|
|
|
}
|
|
|
|
|
return fieldname;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|