diff --git a/jeecg-boot/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/innovationvoucher/controller/InnovationVoucherController.java b/jeecg-boot/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/innovationvoucher/controller/InnovationVoucherController.java index 275e769..b846932 100644 --- a/jeecg-boot/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/innovationvoucher/controller/InnovationVoucherController.java +++ b/jeecg-boot/jeecg-module-demo/src/main/java/org/jeecg/modules/demo/innovationvoucher/controller/InnovationVoucherController.java @@ -172,6 +172,74 @@ public class InnovationVoucherController extends JeecgController> queryPageList4(InnovationVoucher innovationVoucher, + @RequestParam(name="pageNo", defaultValue="1") Integer pageNo, + @RequestParam(name="pageSize", defaultValue="10") Integer pageSize, + HttpServletRequest req) { + LoginUser loginUser = (LoginUser) SecurityUtils.getSubject().getPrincipal(); + QueryWrapper queryWrapper = QueryGenerator.initQueryWrapper(innovationVoucher, req.getParameterMap()); + queryWrapper.eq("apply_dept",loginUser.getOrgId()); + queryWrapper.eq("state","3"); + queryWrapper.eq("use_state","1"); + queryWrapper.eq("sf_state","0"); + Page page = new Page(pageNo, pageSize); + IPage pageList = innovationVoucherService.page(page, queryWrapper); + return Result.OK(pageList); + } + + /** + * 分页列表查询 + * + * @param innovationVoucher + * @param pageNo + * @param pageSize + * @param req + * @return + */ + //@AutoLog(value = "创新券表-分页列表查询") + @ApiOperation(value="创新券表-分页列表查询", notes="创新券表-分页列表查询") + @GetMapping(value = "/list5") + public Result> queryPageList5(InnovationVoucher innovationVoucher, + @RequestParam(name="pageNo", defaultValue="1") Integer pageNo, + @RequestParam(name="pageSize", defaultValue="10") Integer pageSize, + HttpServletRequest req) { + LoginUser loginUser = (LoginUser) SecurityUtils.getSubject().getPrincipal(); + QueryWrapper queryWrapper = QueryGenerator.initQueryWrapper(innovationVoucher, req.getParameterMap()); + if(loginUser.getRoleCode().indexOf("quxian_admin")!= -1){ + //县区管理员角色 + queryWrapper.eq("sf_state","0"); + queryWrapper.eq("sf_sqdx_sta","1"); + queryWrapper.in("dxsh_sta",1,2,3); + queryWrapper.in("dxsh_flag",1,2); + Page page = new Page(pageNo, pageSize); + IPage pageList = innovationVoucherService.page(page, queryWrapper); + return Result.OK(pageList); + } + if(loginUser.getRoleCode().indexOf("kejiju_admin")!= -1){ + //市科技局管理员角色 + queryWrapper.eq("sf_state","0"); + queryWrapper.eq("sf_sqdx_sta","1"); + queryWrapper.in("dxsh_sta",2,3); + queryWrapper.in("dxsh_flag",0,2); + Page page = new Page(pageNo, pageSize); + IPage pageList = innovationVoucherService.page(page, queryWrapper); + return Result.OK(pageList); + } + return Result.OK(null); + } + /** * 添加 * @@ -227,8 +295,8 @@ public class InnovationVoucherController extends JeecgController edit1(@RequestBody InnovationVoucher innovationVoucher) { - LoginUser loginUser = (LoginUser) SecurityUtils.getSubject().getPrincipal(); - if(sysDepartService.getById(loginUser.getOrgId()).getOrgCategory().equals("3")){ + + if(sysDepartService.getById(innovationVoucher.getProDept()).getOrgCategory().equals("3")){ innovationVoucher.setFlag("1"); }else{ innovationVoucher.setFlag("0"); @@ -238,6 +306,28 @@ public class InnovationVoucherController extends JeecgController edit3(@RequestBody InnovationVoucher innovationVoucher) { + + if(sysDepartService.getById(innovationVoucher.getApplyDept()).getOrgCategory().equals("3")){ + innovationVoucher.setDxshFlag("1"); + }else{ + innovationVoucher.setDxshFlag("0"); + } + innovationVoucher.setDxshSta("4"); + innovationVoucherService.updateById(innovationVoucher); + return Result.OK("驳回成功!"); + } + /** * 编辑 * @@ -326,6 +416,30 @@ public class InnovationVoucherController extends JeecgController tjdxsh(@RequestParam(name="id",required=true) String id) { + InnovationVoucher innovationVoucher = innovationVoucherService.getById(id); + if(innovationVoucher==null) { + return Result.error("未找到对应数据"); + } + if(innovationVoucher.getDxshFlag().equals("0")){ + innovationVoucher.setDxshSta("2"); + }else { + innovationVoucher.setDxshSta("1"); + } + innovationVoucher.setSfSqdxSta("1"); + innovationVoucher.setDxReject(""); + innovationVoucherService.updateById(innovationVoucher); + return Result.OK("提交兑现审核成功!"); + } + /** * 审核通过 * @@ -355,6 +469,35 @@ public class InnovationVoucherController extends JeecgController dxshtg(@RequestParam(name="id",required=true) String id) { + InnovationVoucher innovationVoucher = innovationVoucherService.getById(id); + if(innovationVoucher==null) { + return Result.error("未找到对应数据"); + } + if(innovationVoucher.getDxshFlag().equals("0")){ + innovationVoucher.setDxshSta("3"); + } + if(innovationVoucher.getDxshFlag().equals("1")){ + innovationVoucher.setDxshSta("2"); + innovationVoucher.setDxshFlag("2"); + } + if(innovationVoucher.getDxshFlag().equals("2")&&innovationVoucher.getDxshSta().equals("2")){ + innovationVoucher.setDxshSta("3"); + } + //instrument.setFlag("2"); + innovationVoucherService.updateById(innovationVoucher); + return Result.OK("兑现审核通过成功!"); + } + /** * 同意使用 * @@ -369,6 +512,11 @@ public class InnovationVoucherController extends JeecgController edit2(@RequestBody Instrument instrument) { - LoginUser loginUser = (LoginUser) SecurityUtils.getSubject().getPrincipal(); - if(sysDepartService.getById(loginUser.getOrgId()).getOrgCategory().equals("3")){ + //LoginUser loginUser = (LoginUser) SecurityUtils.getSubject().getPrincipal(); + if(sysDepartService.getById(instrument.getDeclarationUnit()).getOrgCategory().equals("3")){ instrument.setFlag("1"); }else{ instrument.setFlag("0"); diff --git a/jeecgboot-vue3/src/views/innovationvoucher/InnovationVoucher.api.ts b/jeecgboot-vue3/src/views/innovationvoucher/InnovationVoucher.api.ts index 8fde77e..96eebeb 100644 --- a/jeecgboot-vue3/src/views/innovationvoucher/InnovationVoucher.api.ts +++ b/jeecgboot-vue3/src/views/innovationvoucher/InnovationVoucher.api.ts @@ -8,18 +8,23 @@ enum Api { list1 = '/innovationvoucher/innovationVoucher/list1', list2 = '/innovationvoucher/innovationVoucher/list2', list3 = '/innovationvoucher/innovationVoucher/list3', + list4 = '/innovationvoucher/innovationVoucher/list4', + list5 = '/innovationvoucher/innovationVoucher/list5', save='/innovationvoucher/innovationVoucher/add', edit='/innovationvoucher/innovationVoucher/edit', edit1='/innovationvoucher/innovationVoucher/edit1', edit2='/innovationvoucher/innovationVoucher/edit2', + edit3='/innovationvoucher/innovationVoucher/edit3', deleteOne = '/innovationvoucher/innovationVoucher/delete', deleteBatch = '/innovationvoucher/innovationVoucher/deleteBatch', importExcel = '/innovationvoucher/innovationVoucher/importExcel', exportXls = '/innovationvoucher/innovationVoucher/exportXls', tjsh = '/innovationvoucher/innovationVoucher/tjsh', + tjdxsh = '/innovationvoucher/innovationVoucher/tjdxsh', tysy = '/innovationvoucher/innovationVoucher/tysy', jjsy = '/innovationvoucher/innovationVoucher/jjsy', shtg = '/innovationvoucher/innovationVoucher/shtg', + dxshtg = '/innovationvoucher/innovationVoucher/dxshtg', } export const tjsh = (params,handleSuccess) => { return defHttp.get({url: Api.tjsh, params}, {joinParamsToUrl: true}).then(() => { @@ -27,6 +32,12 @@ export const tjsh = (params,handleSuccess) => { }); } +export const tjdxsh = (params,handleSuccess) => { + return defHttp.get({url: Api.tjdxsh, params}, {joinParamsToUrl: true}).then(() => { + handleSuccess(); + }); +} + export const tysy = (params,handleSuccess) => { return defHttp.get({url: Api.tysy, params}, {joinParamsToUrl: true}).then(() => { handleSuccess(); @@ -49,6 +60,11 @@ export const saveOrUpdate2 = (params, isUpdate) => { return defHttp.post({ url: url, params }, { isTransformResponse: false }); } +export const saveOrUpdate3 = (params, isUpdate) => { + let url = isUpdate ? Api.edit3 : Api.save; + return defHttp.post({ url: url, params }, { isTransformResponse: false }); +} + /** * 导出api @@ -73,12 +89,22 @@ export const list2 = (params) => defHttp.get({ url: Api.list2, params }); export const list3 = (params) => defHttp.get({ url: Api.list3, params }); +export const list4 = (params) => defHttp.get({ url: Api.list4, params }); + +export const list5 = (params) => defHttp.get({ url: Api.list5, params }); + export const shtg = (params,handleSuccess) => { return defHttp.get({url: Api.shtg, params}, {joinParamsToUrl: true}).then(() => { handleSuccess(); }); } +export const dxshtg = (params,handleSuccess) => { + return defHttp.get({url: Api.dxshtg, params}, {joinParamsToUrl: true}).then(() => { + handleSuccess(); + }); +} + /** * 删除单个 * @param params diff --git a/jeecgboot-vue3/src/views/innovationvoucher/InnovationVoucherList4.vue b/jeecgboot-vue3/src/views/innovationvoucher/InnovationVoucherList4.vue new file mode 100644 index 0000000..db06fbc --- /dev/null +++ b/jeecgboot-vue3/src/views/innovationvoucher/InnovationVoucherList4.vue @@ -0,0 +1,304 @@ + + + + + diff --git a/jeecgboot-vue3/src/views/innovationvoucher/InnovationVoucherList5.vue b/jeecgboot-vue3/src/views/innovationvoucher/InnovationVoucherList5.vue new file mode 100644 index 0000000..ff3ee65 --- /dev/null +++ b/jeecgboot-vue3/src/views/innovationvoucher/InnovationVoucherList5.vue @@ -0,0 +1,332 @@ + + + + + diff --git a/jeecgboot-vue3/src/views/innovationvoucher/components/InnovationVoucherForm1.vue b/jeecgboot-vue3/src/views/innovationvoucher/components/InnovationVoucherForm1.vue index 8377b5d..c031952 100644 --- a/jeecgboot-vue3/src/views/innovationvoucher/components/InnovationVoucherForm1.vue +++ b/jeecgboot-vue3/src/views/innovationvoucher/components/InnovationVoucherForm1.vue @@ -40,6 +40,7 @@ proType: '', proMoney: undefined, attachment: '', + proDept:'', }); const { createMessage } = useMessage(); const labelCol = ref({ xs: { span: 24 }, sm: { span: 5 } }); diff --git a/jeecgboot-vue3/src/views/innovationvoucher/components/InnovationVoucherForm3.vue b/jeecgboot-vue3/src/views/innovationvoucher/components/InnovationVoucherForm3.vue new file mode 100644 index 0000000..dce2cb6 --- /dev/null +++ b/jeecgboot-vue3/src/views/innovationvoucher/components/InnovationVoucherForm3.vue @@ -0,0 +1,152 @@ + + + + + diff --git a/jeecgboot-vue3/src/views/innovationvoucher/components/InnovationVoucherModal3.vue b/jeecgboot-vue3/src/views/innovationvoucher/components/InnovationVoucherModal3.vue new file mode 100644 index 0000000..629ce62 --- /dev/null +++ b/jeecgboot-vue3/src/views/innovationvoucher/components/InnovationVoucherModal3.vue @@ -0,0 +1,77 @@ + + + + + + diff --git a/jeecgboot-vue3/src/views/instrument/components/InstrumentForm2.vue b/jeecgboot-vue3/src/views/instrument/components/InstrumentForm2.vue index c672d66..b902ce1 100644 --- a/jeecgboot-vue3/src/views/instrument/components/InstrumentForm2.vue +++ b/jeecgboot-vue3/src/views/instrument/components/InstrumentForm2.vue @@ -39,6 +39,7 @@ const formData = reactive>({ id: '', reject: '', + declarationUnit:'', }); const { createMessage } = useMessage(); const labelCol = ref({ xs: { span: 24 }, sm: { span: 5 } });