You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
weaver-hrm-organization/src/com/engine/organization/wrapper/JobWrapper.java

160 lines
3.8 KiB
Java

3 years ago
package com.engine.organization.wrapper;
import com.api.browser.bean.SearchConditionItem;
3 years ago
import com.engine.common.util.ServiceUtil;
import com.engine.core.impl.Service;
import com.engine.organization.entity.job.param.JobSearchParam;
3 years ago
import com.engine.organization.entity.searchtree.SearchTreeParams;
import com.engine.organization.service.JobService;
import com.engine.organization.service.impl.JobServiceImpl;
import com.engine.organization.util.OrganizationFormItemUtil;
import com.engine.organization.util.response.ReturnResult;
3 years ago
import weaver.hrm.User;
import java.util.ArrayList;
import java.util.Collection;
import java.util.List;
3 years ago
import java.util.Map;
/**
* @description: TODO
* @author:dxfeng
* @createTime: 2022/05/27
* @version: 1.0
*/
public class JobWrapper extends Service {
private JobService getJobService(User user) {
return ServiceUtil.getService(JobServiceImpl.class, user);
}
/**
*
*
* @param params
* @return
*/
3 years ago
public Map<String, Object> getSearchTree(SearchTreeParams params) {
return getJobService(user).getSearchTree(params);
}
/**
*
*
* @param param
* @return
*/
public Map<String, Object> listPage(JobSearchParam param) {
return getJobService(user).listPage(param);
}
/**
*
*
* @return
*/
public Map<String, Object> getHasRight() {
return getJobService(user).getHasRight();
}
/**
*
*
* @return
*/
public Map<String, Object> getSearchCondition() {
return getJobService(user).getSearchCondition();
}
/**
*
*
* @return
*/
public Map<String, Object> getSaveForm() {
return getJobService(user).getSaveForm();
}
/**
*
*
* @param params
* @return
*/
public Map<String, Object> getJobBaseForm(Map<String, Object> params) {
return getJobService(user).getJobBaseForm(params);
}
/**
*
*
* @param params
* @return
*/
public int saveBaseForm(JobSearchParam params) {
return getJobService(user).saveBaseForm(params);
}
/**
*
*
* @param params
* @return
*/
public int updateForm(Map<String, Object> params) {
return getJobService(user).updateForm(params);
}
/**
*
*
* @param id
* @param departmentId
* @return
*/
public int copyJobItem(long id, long departmentId) {
return getJobService(user).copyJobItem(id, departmentId);
}
/**
* @param params
* @return
*/
public int updateForbiddenTagById(JobSearchParam params) {
return getJobService(user).updateForbiddenTagById(params);
}
/**
* ID
*
* @param ids
* @return
*/
public int deleteByIds(Collection<Long> ids) {
return getJobService(user).deleteByIds(ids);
}
/**
*
* @return
*/
public ReturnResult getCopyForm() {
List<SearchConditionItem> condition = new ArrayList<>();
SearchConditionItem deptBrowserItem = OrganizationFormItemUtil.browserItem(user, 2, 16, 2, false, "复制到", "161", "department", "deptBrowser");
deptBrowserItem.setRules("required|string");
condition.add(deptBrowserItem);
return ReturnResult.successed(condition);
}
/**
*
* @param jobId
* @return
*/
public ReturnResult getHrmListByJobId(Long jobId) {
Map<String, Object> hrmListByJobId = getJobService(user).getHrmListByJobId(jobId);
return ReturnResult.successed(hrmListByJobId);
}
3 years ago
}