新增企业端查询起草组成员
This commit is contained in:
+32
-13
@@ -78,19 +78,7 @@ public class PayDraftingGroupSubItemController extends JeroController<PayDraftin
|
||||
@Resource
|
||||
private IPayContactsManagementTemporaryService payContactsManagementTemporaryService;
|
||||
@Resource
|
||||
private IPayMailBillService payMailBillService;
|
||||
@Resource
|
||||
private IPayPackCompanyService payPackCompanyService;
|
||||
@Resource
|
||||
private IPayMailBillProjectService payMailBillProjectService;
|
||||
@Resource
|
||||
private IPayIncomeContractAssociatedService payIncomeContractAssociatedService;
|
||||
@Resource
|
||||
private ISysUserService sysUserService;
|
||||
@Resource
|
||||
private IPayPackCompanyProjectService payPackCompanyProjectService;
|
||||
@Resource
|
||||
private IPayIncomeContractService payIncomeContractService;
|
||||
|
||||
/**
|
||||
* 分页列表查询
|
||||
@@ -122,7 +110,7 @@ public class PayDraftingGroupSubItemController extends JeroController<PayDraftin
|
||||
return Result.error("起草组不存在!");
|
||||
}
|
||||
LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
|
||||
if(!rolePermissionService.getRolePermission("draftingGroup:underStudy:search") && !Objects.equals(payDraftingGroup.getPrincipalIdA(),sysUser.getId())){
|
||||
if(!rolePermissionService.getRolePermission("draftingGroupMember:search") && !Objects.equals(payDraftingGroup.getPrincipalIdA(),sysUser.getId())){
|
||||
return Result.error("数据权限不足!");
|
||||
}
|
||||
Page<PayDraftingGroupSubItem> page = new Page<>(pageNo, pageSize);
|
||||
@@ -502,4 +490,35 @@ public class PayDraftingGroupSubItemController extends JeroController<PayDraftin
|
||||
payDraftingGroupSubItemService.checkRegister(checkVO);
|
||||
return Result.OK("审核成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页列表查询
|
||||
*
|
||||
* @param payDraftingGroupSubItem 起草组成员
|
||||
* @return
|
||||
*/
|
||||
@ApiOperation(value = "企业端-查询起草组成员", notes = "起草组成员-分页列表查询")
|
||||
@GetMapping(value = "/getItemById")
|
||||
public Result<?> query(PayDraftingGroupSubItem payDraftingGroupSubItem,
|
||||
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
|
||||
@RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
|
||||
@RequestParam(name = "paymentDate", required = false) String paymentDate) {
|
||||
if (!StringUtils.isBlank(payDraftingGroupSubItem.getChargeCompanyTemporaryName()) && payDraftingGroupSubItem.getChargeCompanyTemporaryName().length() > 50) {
|
||||
return Result.error("成员单位长度不能大于50个字符");
|
||||
}
|
||||
if (StringUtils.isBlank(payDraftingGroupSubItem.getDraftingGroupId())) {
|
||||
return Result.error("起草组id不能为空!");
|
||||
}
|
||||
if (StringUtils.isBlank(payDraftingGroupSubItem.getId())) {
|
||||
return Result.error("起草组成员id不能为空!");
|
||||
}
|
||||
PayDraftingGroup payDraftingGroup = payDraftingGroupService.getById(payDraftingGroupSubItem.getDraftingGroupId());
|
||||
if(Objects.isNull(payDraftingGroup)){
|
||||
return Result.error("起草组不存在!");
|
||||
}
|
||||
Page<PayDraftingGroupSubItem> page = new Page<>(pageNo, pageSize);
|
||||
IPage<PayDraftingGroupSubItem> pageList = payDraftingGroupSubItemService.queryPageList(page, payDraftingGroupSubItem, paymentDate);
|
||||
PayDraftingGroupSubItem item = pageList.getRecords().get(0);
|
||||
return Result.OK(item);
|
||||
}
|
||||
}
|
||||
|
||||
+3
@@ -34,6 +34,9 @@
|
||||
AND pcm.company_name LIKE
|
||||
concat('%',concat(#{payDraftingGroupSubItem.chargeCompanyTemporaryName},'%'))
|
||||
</if>
|
||||
<if test="payDraftingGroupSubItem.id != null and payDraftingGroupSubItem.id != ''">
|
||||
AND pdgs.id = #{payDraftingGroupSubItem.id}
|
||||
</if>
|
||||
</where>
|
||||
GROUP BY pdgs.id
|
||||
ORDER BY pdgs.create_time desc
|
||||
|
||||
Reference in New Issue
Block a user