Commit 6aee4b2a authored by zhangyingbin's avatar zhangyingbin

更新根据id删除orgUsr表数据

parent 26d455ee
......@@ -18,6 +18,7 @@ import com.yeejoin.amos.boot.module.ugp.biz.service.impl.OrgServiceImpl;
import com.yeejoin.amos.boot.module.ugp.biz.service.impl.ProjectResourceServiceImpl;
import com.yeejoin.amos.boot.module.ugp.biz.service.impl.ProjectServiceImpl;
import com.yeejoin.amos.boot.module.ugp.biz.service.impl.WelderServiceImpl;
import com.yeejoin.amos.feign.privilege.Privilege;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.apache.poi.ss.formula.functions.T;
......@@ -154,10 +155,12 @@ public class WelderController extends BaseController {
* @return
*/
@TycloudOperation(ApiLevel = UserType.AGENCY,needAuth = false)
@DeleteMapping(value = "/{sequenceNbr}")
@DeleteMapping(value = "/deleteOneById/{sequenceNbr}")
@ApiOperation(httpMethod = "GET", value = "根据sequenceNbr删除人员信息表", notes = "根据sequenceNbr删除人员信息表")
public void deleteOneById(@PathVariable String sequenceNbr) throws Exception {
public ResponseModel<String> deleteOneById(@PathVariable String sequenceNbr) throws Exception {
Privilege.agencyUserClient.multDeleteUser(orgServiceImpl.getOrgUsrById(sequenceNbr).getAmosOrgId());
orgServiceImpl.delectInfo(sequenceNbr);
return ResponseHelper.buildResponse("ok");
}
}
......@@ -18,6 +18,7 @@ import com.yeejoin.amos.feign.privilege.util.DesUtil;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Service;
import org.typroject.tyboot.core.foundation.utils.ValidationUtil;
import java.util.*;
import java.util.stream.Collectors;
......@@ -87,6 +88,7 @@ public class WelderServiceImpl {
*/
@BusinessIdentify
public OrgUsrDto savePerson(JSONObject jsonObject, String bizOrgType, String sequenceNbr){
if(ValidationUtil.isEmpty(sequenceNbr)){
Long companyId = orgService.getReginParams().getCompany().getSequenceNbr();
Set<String> roleNameSet = new HashSet<>();
List<RoleModel> userRoleList = new ArrayList<>();
......@@ -123,6 +125,8 @@ public class WelderServiceImpl {
//创建用户
agencyUserModel = Privilege.agencyUserClient.create(agencyUserModel).getResult();
jsonObject.put("amosOrgId",agencyUserModel.getSequenceNbr());
}
return orgService.dataHandling(jsonObject,bizOrgType,sequenceNbr);
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment