组织架构图

pull/218/head
Chengliang 2 years ago
parent ef71054c94
commit f78ba6f6b3

@ -538,8 +538,8 @@ public class ChartServiceImpl extends Service implements ChartService {
rs.executeQuery("select id,data_id,super_id,type,on_job_num,staff_num,creator,create_time,update_time from jcl_org_onjob");
while (rs.next()) {
Integer type = Util.getIntValue(rs.getString("type"));
String dataIdName = "";
String superIdName = "";
String dataIdName;
String superIdName;
if (ModuleTypeEnum.subcompanyfielddefined.getValue().equals(type)) {
dataIdName = subCompanyComInfo.getSubCompanyname(Util.null2String((rs.getString("data_id"))));
superIdName = subCompanyComInfo.getSubCompanyname(Util.null2String((rs.getString("super_id"))));
@ -613,6 +613,7 @@ public class ChartServiceImpl extends Service implements ChartService {
rst.commit();
}catch (Exception e) {
result.put("errorMsg",e.getMessage());
rst.rollback();
}

@ -0,0 +1,42 @@
package weaver.interfaces.organization.cronjob;
import com.engine.common.util.ServiceUtil;
import com.engine.organization.entity.chart.params.StatisticsParam;
import com.engine.organization.service.ChartService;
import com.engine.organization.service.impl.ChartServiceImpl;
import org.apache.commons.lang3.StringUtils;
import weaver.hrm.User;
import weaver.interfaces.schedule.BaseCronJob;
/**
* @Author liang.cheng
* @Date 2023/9/14 9:20 AM
* @Description:
* @Version 1.0
*/
public class StatisticsPersonCron extends BaseCronJob {
private ChartService getChartService(User user) {
return ServiceUtil.getService(ChartServiceImpl.class, user);
}
private String companyId;
public String getCompanyId() {
return companyId;
}
public void setCompanyId(String companyId) {
this.companyId = companyId;
}
@Override
public void execute() {
Integer value = StringUtils.isNotBlank(companyId) ? Integer.parseInt(companyId) : null;
StatisticsParam build = StatisticsParam.builder().companyId(value).build();
User user = new User();
user.setUid(1);
getChartService(user).recordStatistics(build);
}
}
Loading…
Cancel
Save