DeptAPIService.java
1.22 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
package com.huaheng.pc.u8.service;
import com.huaheng.api.general.service.BasicDataApiService;
import com.huaheng.framework.web.domain.AjaxResult;
import com.huaheng.pc.config.warehouseCompany.service.WarehouseCompanyService;
import com.huaheng.pc.system.dept.domain.Dept;
import com.huaheng.pc.system.dept.service.IDeptService;
import com.huaheng.pc.u8.domain.ICSDepartmentModel;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import javax.annotation.Resource;
import java.util.Date;
@Service
public class DeptAPIService {
@Resource
IDeptService iDeptService;
@Resource
private WarehouseCompanyService warehouseCompanyService;
@Autowired
BasicDataApiService basicDataApiService;
@Transactional
public AjaxResult ICSDepartment(ICSDepartmentModel ICSDepartment) {
Dept dept = new Dept();
dept.setCode(ICSDepartment.getcDepCode());
dept.setDeptName(ICSDepartment.getcDepName());
dept.setCreateTime(new Date());
dept.setUpdateTime(new Date());
AjaxResult ajaxResult = basicDataApiService.dept(dept);
return ajaxResult;
}
}