|
|
@@ -116,9 +116,9 @@ public class CompanyController extends BaseController
|
|
|
public R add(@RequestBody Company company)
|
|
|
{
|
|
|
LoginUser loginUser = tokenService.getLoginUser(ServletUtils.getRequest());
|
|
|
-// if(company.getDeptId() != null){//位置迁移到实现类中
|
|
|
-// company.setDeptId(loginUser.getDeptId());
|
|
|
-// }
|
|
|
+ if(company.getDeptId() != null){
|
|
|
+ company.setDeptId(loginUser.getDeptId());
|
|
|
+ }
|
|
|
company.setCreateBy(loginUser.getUsername());
|
|
|
company.setOldDeptId(loginUser.getDeptId());
|
|
|
company.setAdmin(loginUser.isAdmin());
|
|
|
@@ -126,7 +126,7 @@ public class CompanyController extends BaseController
|
|
|
company.setAppId(Md5Utils.hash(company.getUserName()));
|
|
|
company.setAppKey(Md5Utils.hash(company.getPassword()));
|
|
|
company.setOmsCode("SF.1");
|
|
|
- return companyService.insertCompany(company,loginUser.getDeptId());
|
|
|
+ return companyService.insertCompany(company);
|
|
|
}
|
|
|
|
|
|
/**
|