付款单
This commit is contained in:
parent
10c7641298
commit
e243af795d
|
|
@ -1,5 +1,6 @@
|
||||||
package com.nu.modules.cgd.controller;
|
package com.nu.modules.cgd.controller;
|
||||||
|
|
||||||
|
import java.math.BigDecimal;
|
||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
@ -10,6 +11,7 @@ import java.io.UnsupportedEncodingException;
|
||||||
import java.net.URLDecoder;
|
import java.net.URLDecoder;
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import javax.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import org.jeecg.common.api.vo.Result;
|
import org.jeecg.common.api.vo.Result;
|
||||||
import org.jeecg.common.system.query.QueryGenerator;
|
import org.jeecg.common.system.query.QueryGenerator;
|
||||||
import org.jeecg.common.system.query.QueryRuleEnum;
|
import org.jeecg.common.system.query.QueryRuleEnum;
|
||||||
|
|
@ -39,136 +41,168 @@ import io.swagger.annotations.ApiOperation;
|
||||||
import org.jeecg.common.aspect.annotation.AutoLog;
|
import org.jeecg.common.aspect.annotation.AutoLog;
|
||||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @Description: nu_invoicing_cgd_info
|
* @Description: nu_invoicing_cgd_info
|
||||||
* @Author: jeecg-boot
|
* @Author: jeecg-boot
|
||||||
* @Date: 2025-09-26
|
* @Date: 2025-09-26
|
||||||
* @Version: V1.0
|
* @Version: V1.0
|
||||||
*/
|
*/
|
||||||
@Api(tags="nu_invoicing_cgd_info")
|
@Api(tags = "nu_invoicing_cgd_info")
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping("/cgd/nuInvoicingCgdInfo")
|
@RequestMapping("/cgd/nuInvoicingCgdInfo")
|
||||||
@Slf4j
|
@Slf4j
|
||||||
public class NuInvoicingCgdInfoController extends JeecgController<NuInvoicingCgdInfo, INuInvoicingCgdInfoService> {
|
public class NuInvoicingCgdInfoController extends JeecgController<NuInvoicingCgdInfo, INuInvoicingCgdInfoService> {
|
||||||
@Autowired
|
@Autowired
|
||||||
private INuInvoicingCgdInfoService nuInvoicingCgdInfoService;
|
private INuInvoicingCgdInfoService nuInvoicingCgdInfoService;
|
||||||
|
|
||||||
/**
|
|
||||||
* 分页列表查询
|
|
||||||
*
|
|
||||||
* @param nuInvoicingCgdInfo
|
|
||||||
* @param pageNo
|
|
||||||
* @param pageSize
|
|
||||||
* @param req
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
//@AutoLog(value = "nu_invoicing_cgd_info-分页列表查询")
|
|
||||||
@ApiOperation(value="nu_invoicing_cgd_info-分页列表查询", notes="nu_invoicing_cgd_info-分页列表查询")
|
|
||||||
@GetMapping(value = "/list")
|
|
||||||
public Result<IPage<NuInvoicingCgdInfo>> queryPageList(NuInvoicingCgdInfo nuInvoicingCgdInfo,
|
|
||||||
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
|
||||||
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
|
|
||||||
HttpServletRequest req) {
|
|
||||||
QueryWrapper<NuInvoicingCgdInfo> queryWrapper = QueryGenerator.initQueryWrapper(nuInvoicingCgdInfo, req.getParameterMap());
|
|
||||||
Page<NuInvoicingCgdInfo> page = new Page<NuInvoicingCgdInfo>(pageNo, pageSize);
|
|
||||||
IPage<NuInvoicingCgdInfo> pageList = nuInvoicingCgdInfoService.page(page, queryWrapper);
|
|
||||||
return Result.OK(pageList);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 添加
|
|
||||||
*
|
|
||||||
* @param nuInvoicingCgdInfo
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
@AutoLog(value = "nu_invoicing_cgd_info-添加")
|
|
||||||
@ApiOperation(value="nu_invoicing_cgd_info-添加", notes="nu_invoicing_cgd_info-添加")
|
|
||||||
@PostMapping(value = "/add")
|
|
||||||
public Result<String> add(@RequestBody NuInvoicingCgdInfo nuInvoicingCgdInfo) {
|
|
||||||
nuInvoicingCgdInfoService.save(nuInvoicingCgdInfo);
|
|
||||||
return Result.OK("添加成功!");
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 编辑
|
|
||||||
*
|
|
||||||
* @param nuInvoicingCgdInfo
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
@AutoLog(value = "nu_invoicing_cgd_info-编辑")
|
|
||||||
@ApiOperation(value="nu_invoicing_cgd_info-编辑", notes="nu_invoicing_cgd_info-编辑")
|
|
||||||
@RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST})
|
|
||||||
public Result<String> edit(@RequestBody NuInvoicingCgdInfo nuInvoicingCgdInfo) {
|
|
||||||
nuInvoicingCgdInfoService.updateById(nuInvoicingCgdInfo);
|
|
||||||
return Result.OK("编辑成功!");
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 通过id删除
|
|
||||||
*
|
|
||||||
* @param id
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
@AutoLog(value = "nu_invoicing_cgd_info-通过id删除")
|
|
||||||
@ApiOperation(value="nu_invoicing_cgd_info-通过id删除", notes="nu_invoicing_cgd_info-通过id删除")
|
|
||||||
@DeleteMapping(value = "/delete")
|
|
||||||
public Result<String> delete(@RequestParam(name="id",required=true) String id) {
|
|
||||||
nuInvoicingCgdInfoService.removeById(id);
|
|
||||||
return Result.OK("删除成功!");
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 批量删除
|
|
||||||
*
|
|
||||||
* @param ids
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
@AutoLog(value = "nu_invoicing_cgd_info-批量删除")
|
|
||||||
@ApiOperation(value="nu_invoicing_cgd_info-批量删除", notes="nu_invoicing_cgd_info-批量删除")
|
|
||||||
@DeleteMapping(value = "/deleteBatch")
|
|
||||||
public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
|
|
||||||
this.nuInvoicingCgdInfoService.removeByIds(Arrays.asList(ids.split(",")));
|
|
||||||
return Result.OK("批量删除成功!");
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 通过id查询
|
|
||||||
*
|
|
||||||
* @param id
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
//@AutoLog(value = "nu_invoicing_cgd_info-通过id查询")
|
|
||||||
@ApiOperation(value="nu_invoicing_cgd_info-通过id查询", notes="nu_invoicing_cgd_info-通过id查询")
|
|
||||||
@GetMapping(value = "/queryById")
|
|
||||||
public Result<NuInvoicingCgdInfo> queryById(@RequestParam(name="id",required=true) String id) {
|
|
||||||
NuInvoicingCgdInfo nuInvoicingCgdInfo = nuInvoicingCgdInfoService.getById(id);
|
|
||||||
if(nuInvoicingCgdInfo==null) {
|
|
||||||
return Result.error("未找到对应数据");
|
|
||||||
}
|
|
||||||
return Result.OK(nuInvoicingCgdInfo);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 导出excel
|
* 分页列表查询
|
||||||
*
|
*
|
||||||
* @param request
|
* @param nuInvoicingCgdInfo
|
||||||
* @param nuInvoicingCgdInfo
|
* @param pageNo
|
||||||
*/
|
* @param pageSize
|
||||||
|
* @param req
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
//@AutoLog(value = "nu_invoicing_cgd_info-分页列表查询")
|
||||||
|
@ApiOperation(value = "nu_invoicing_cgd_info-分页列表查询", notes = "nu_invoicing_cgd_info-分页列表查询")
|
||||||
|
@GetMapping(value = "/list")
|
||||||
|
public Result<IPage<NuInvoicingCgdInfo>> queryPageList(NuInvoicingCgdInfo nuInvoicingCgdInfo,
|
||||||
|
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
|
||||||
|
@RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
|
||||||
|
HttpServletRequest req) {
|
||||||
|
QueryWrapper<NuInvoicingCgdInfo> queryWrapper = QueryGenerator.initQueryWrapper(nuInvoicingCgdInfo, req.getParameterMap());
|
||||||
|
Page<NuInvoicingCgdInfo> page = new Page<NuInvoicingCgdInfo>(pageNo, pageSize);
|
||||||
|
IPage<NuInvoicingCgdInfo> pageList = nuInvoicingCgdInfoService.page(page, queryWrapper);
|
||||||
|
return Result.OK(pageList);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 添加
|
||||||
|
*
|
||||||
|
* @param nuInvoicingCgdInfo
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "nu_invoicing_cgd_info-添加")
|
||||||
|
@ApiOperation(value = "nu_invoicing_cgd_info-添加", notes = "nu_invoicing_cgd_info-添加")
|
||||||
|
@PostMapping(value = "/add")
|
||||||
|
public Result<String> add(@RequestBody NuInvoicingCgdInfo nuInvoicingCgdInfo) {
|
||||||
|
nuInvoicingCgdInfoService.save(nuInvoicingCgdInfo);
|
||||||
|
return Result.OK("添加成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 编辑
|
||||||
|
*
|
||||||
|
* @param nuInvoicingCgdInfo
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "nu_invoicing_cgd_info-编辑")
|
||||||
|
@ApiOperation(value = "nu_invoicing_cgd_info-编辑", notes = "nu_invoicing_cgd_info-编辑")
|
||||||
|
@RequestMapping(value = "/edit", method = {RequestMethod.PUT, RequestMethod.POST})
|
||||||
|
public Result<String> edit(@RequestBody NuInvoicingCgdInfo nuInvoicingCgdInfo) {
|
||||||
|
nuInvoicingCgdInfoService.updateById(nuInvoicingCgdInfo);
|
||||||
|
return Result.OK("编辑成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 通过id删除
|
||||||
|
*
|
||||||
|
* @param id
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "nu_invoicing_cgd_info-通过id删除")
|
||||||
|
@ApiOperation(value = "nu_invoicing_cgd_info-通过id删除", notes = "nu_invoicing_cgd_info-通过id删除")
|
||||||
|
@DeleteMapping(value = "/delete")
|
||||||
|
public Result<String> delete(@RequestParam(name = "id", required = true) String id) {
|
||||||
|
nuInvoicingCgdInfoService.removeById(id);
|
||||||
|
return Result.OK("删除成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除
|
||||||
|
*
|
||||||
|
* @param ids
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "nu_invoicing_cgd_info-批量删除")
|
||||||
|
@ApiOperation(value = "nu_invoicing_cgd_info-批量删除", notes = "nu_invoicing_cgd_info-批量删除")
|
||||||
|
@DeleteMapping(value = "/deleteBatch")
|
||||||
|
public Result<String> deleteBatch(@RequestParam(name = "ids", required = true) String ids) {
|
||||||
|
this.nuInvoicingCgdInfoService.removeByIds(Arrays.asList(ids.split(",")));
|
||||||
|
return Result.OK("批量删除成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 通过id查询
|
||||||
|
*
|
||||||
|
* @param id
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
//@AutoLog(value = "nu_invoicing_cgd_info-通过id查询")
|
||||||
|
@ApiOperation(value = "nu_invoicing_cgd_info-通过id查询", notes = "nu_invoicing_cgd_info-通过id查询")
|
||||||
|
@GetMapping(value = "/queryById")
|
||||||
|
public Result<NuInvoicingCgdInfo> queryById(@RequestParam(name = "id", required = true) String id) {
|
||||||
|
NuInvoicingCgdInfo nuInvoicingCgdInfo = nuInvoicingCgdInfoService.getById(id);
|
||||||
|
if (nuInvoicingCgdInfo == null) {
|
||||||
|
return Result.error("未找到对应数据");
|
||||||
|
}
|
||||||
|
return Result.OK(nuInvoicingCgdInfo);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导出excel
|
||||||
|
*
|
||||||
|
* @param request
|
||||||
|
* @param nuInvoicingCgdInfo
|
||||||
|
*/
|
||||||
@RequestMapping(value = "/exportXls")
|
@RequestMapping(value = "/exportXls")
|
||||||
public ModelAndView exportXls(HttpServletRequest request, NuInvoicingCgdInfo nuInvoicingCgdInfo) {
|
public ModelAndView exportXls(HttpServletRequest request, NuInvoicingCgdInfo nuInvoicingCgdInfo) {
|
||||||
return super.exportXls(request, nuInvoicingCgdInfo, NuInvoicingCgdInfo.class, "nu_invoicing_cgd_info");
|
return super.exportXls(request, nuInvoicingCgdInfo, NuInvoicingCgdInfo.class, "nu_invoicing_cgd_info");
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 通过excel导入数据
|
* 通过excel导入数据
|
||||||
*
|
*
|
||||||
* @param request
|
* @param request
|
||||||
* @param response
|
* @param response
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
||||||
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
||||||
return super.importExcel(request, response, NuInvoicingCgdInfo.class);
|
return super.importExcel(request, response, NuInvoicingCgdInfo.class);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页列表查询-查询“拣货”的
|
||||||
|
*
|
||||||
|
* @param nuInvoicingCgdInfo
|
||||||
|
* @param pageNo
|
||||||
|
* @param pageSize
|
||||||
|
* @param req
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@ApiOperation(value = "nu_invoicing_cgd_info-分页列表查询“拣货”的", notes = "nu_invoicing_cgd_info-分页列表查询“拣货”的")
|
||||||
|
@GetMapping(value = "/listAndJh")
|
||||||
|
public Result<IPage<NuInvoicingCgdInfo>> queryPageListAndJh(NuInvoicingCgdInfo nuInvoicingCgdInfo,
|
||||||
|
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
|
||||||
|
@RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
|
||||||
|
HttpServletRequest req) {
|
||||||
|
Page<NuInvoicingCgdInfo> page = new Page<NuInvoicingCgdInfo>(pageNo, pageSize);
|
||||||
|
IPage<NuInvoicingCgdInfo> pageList = nuInvoicingCgdInfoService.pageList(page, nuInvoicingCgdInfo);
|
||||||
|
return Result.OK(pageList);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 计算已完结采购单+拣货 总价
|
||||||
|
*
|
||||||
|
* @param nuInvoicingCgdInfo
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@ApiOperation(value = "nu_invoicing_cgd_info-计算已完结采购单+拣货 总价", notes = "nu_invoicing_cgd_info-计算已完结采购单+拣货 总价")
|
||||||
|
@GetMapping(value = "/calcTotalPrice")
|
||||||
|
public Result<BigDecimal> calcTotalPrice(NuInvoicingCgdInfo nuInvoicingCgdInfo) {
|
||||||
|
return Result.OK(nuInvoicingCgdInfoService.calcTotalPrice(nuInvoicingCgdInfo));
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -10,6 +10,8 @@ import java.io.UnsupportedEncodingException;
|
||||||
import java.net.URLDecoder;
|
import java.net.URLDecoder;
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import javax.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
|
import org.apache.commons.lang.StringUtils;
|
||||||
import org.jeecg.common.api.vo.Result;
|
import org.jeecg.common.api.vo.Result;
|
||||||
import org.jeecg.common.system.query.QueryGenerator;
|
import org.jeecg.common.system.query.QueryGenerator;
|
||||||
import org.jeecg.common.system.query.QueryRuleEnum;
|
import org.jeecg.common.system.query.QueryRuleEnum;
|
||||||
|
|
@ -39,125 +41,136 @@ import io.swagger.annotations.ApiOperation;
|
||||||
import org.jeecg.common.aspect.annotation.AutoLog;
|
import org.jeecg.common.aspect.annotation.AutoLog;
|
||||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @Description: nu_invoicing_cgd_main
|
* @Description: nu_invoicing_cgd_main
|
||||||
* @Author: jeecg-boot
|
* @Author: jeecg-boot
|
||||||
* @Date: 2025-09-26
|
* @Date: 2025-09-26
|
||||||
* @Version: V1.0
|
* @Version: V1.0
|
||||||
*/
|
*/
|
||||||
@Api(tags="nu_invoicing_cgd_main")
|
@Api(tags = "nu_invoicing_cgd_main")
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping("/cgd/nuInvoicingCgdMain")
|
@RequestMapping("/cgd/nuInvoicingCgdMain")
|
||||||
@Slf4j
|
@Slf4j
|
||||||
public class NuInvoicingCgdMainController extends JeecgController<NuInvoicingCgdMain, INuInvoicingCgdMainService> {
|
public class NuInvoicingCgdMainController extends JeecgController<NuInvoicingCgdMain, INuInvoicingCgdMainService> {
|
||||||
@Autowired
|
@Autowired
|
||||||
private INuInvoicingCgdMainService nuInvoicingCgdMainService;
|
private INuInvoicingCgdMainService nuInvoicingCgdMainService;
|
||||||
|
|
||||||
/**
|
|
||||||
* 分页列表查询
|
|
||||||
*
|
|
||||||
* @param nuInvoicingCgdMain
|
|
||||||
* @param pageNo
|
|
||||||
* @param pageSize
|
|
||||||
* @param req
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
//@AutoLog(value = "采购单-分页列表查询")
|
|
||||||
@ApiOperation(value="采购单-分页列表查询", notes="采购单-分页列表查询")
|
|
||||||
@GetMapping(value = "/list")
|
|
||||||
public Result<IPage<NuInvoicingCgdMain>> queryPageList(NuInvoicingCgdMain nuInvoicingCgdMain,
|
|
||||||
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
|
||||||
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
|
|
||||||
HttpServletRequest req) {
|
|
||||||
QueryWrapper<NuInvoicingCgdMain> queryWrapper = QueryGenerator.initQueryWrapper(nuInvoicingCgdMain, req.getParameterMap());
|
|
||||||
Page<NuInvoicingCgdMain> page = new Page<NuInvoicingCgdMain>(pageNo, pageSize);
|
|
||||||
IPage<NuInvoicingCgdMain> pageList = nuInvoicingCgdMainService.page(page, queryWrapper);
|
|
||||||
return Result.OK(pageList);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 添加
|
|
||||||
*
|
|
||||||
* @param nuInvoicingCgdMain
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
@AutoLog(value = "采购单-添加")
|
|
||||||
@ApiOperation(value="采购单-添加", notes="采购单-添加")
|
|
||||||
@RequiresPermissions("cgd:nu_invoicing_cgd_main:add")
|
|
||||||
@PostMapping(value = "/add")
|
|
||||||
public Result<String> add(@RequestBody NuInvoicingCgdMain nuInvoicingCgdMain) {
|
|
||||||
nuInvoicingCgdMainService.save(nuInvoicingCgdMain);
|
|
||||||
return Result.OK("添加成功!");
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 编辑
|
|
||||||
*
|
|
||||||
* @param nuInvoicingCgdMain
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
@AutoLog(value = "采购单-编辑")
|
|
||||||
@ApiOperation(value="采购单-编辑", notes="采购单-编辑")
|
|
||||||
@RequiresPermissions("cgd:nu_invoicing_cgd_main:edit")
|
|
||||||
@RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST})
|
|
||||||
public Result<String> edit(@RequestBody NuInvoicingCgdMain nuInvoicingCgdMain) {
|
|
||||||
nuInvoicingCgdMainService.updateById(nuInvoicingCgdMain);
|
|
||||||
return Result.OK("编辑成功!");
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 通过id删除
|
|
||||||
*
|
|
||||||
* @param id
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
@AutoLog(value = "采购单-通过id删除")
|
|
||||||
@ApiOperation(value="采购单-通过id删除", notes="采购单-通过id删除")
|
|
||||||
@RequiresPermissions("cgd:nu_invoicing_cgd_main:delete")
|
|
||||||
@DeleteMapping(value = "/delete")
|
|
||||||
public Result<String> delete(@RequestParam(name="id",required=true) String id) {
|
|
||||||
nuInvoicingCgdMainService.removeById(id);
|
|
||||||
return Result.OK("删除成功!");
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 批量删除
|
|
||||||
*
|
|
||||||
* @param ids
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
@AutoLog(value = "采购单-批量删除")
|
|
||||||
@ApiOperation(value="采购单-批量删除", notes="采购单-批量删除")
|
|
||||||
@RequiresPermissions("cgd:nu_invoicing_cgd_main:deleteBatch")
|
|
||||||
@DeleteMapping(value = "/deleteBatch")
|
|
||||||
public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
|
|
||||||
this.nuInvoicingCgdMainService.removeByIds(Arrays.asList(ids.split(",")));
|
|
||||||
return Result.OK("批量删除成功!");
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 通过id查询
|
|
||||||
*
|
|
||||||
* @param id
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
//@AutoLog(value = "采购单-通过id查询")
|
|
||||||
@ApiOperation(value="采购单-通过id查询", notes="采购单-通过id查询")
|
|
||||||
@GetMapping(value = "/queryById")
|
|
||||||
public Result<NuInvoicingCgdMain> queryById(@RequestParam(name="id",required=true) String id) {
|
|
||||||
NuInvoicingCgdMain nuInvoicingCgdMain = nuInvoicingCgdMainService.getById(id);
|
|
||||||
if(nuInvoicingCgdMain==null) {
|
|
||||||
return Result.error("未找到对应数据");
|
|
||||||
}
|
|
||||||
return Result.OK(nuInvoicingCgdMain);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 导出excel
|
* 分页列表查询
|
||||||
*
|
*
|
||||||
* @param request
|
* @param nuInvoicingCgdMain
|
||||||
* @param nuInvoicingCgdMain
|
* @param pageNo
|
||||||
*/
|
* @param pageSize
|
||||||
|
* @param req
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
//@AutoLog(value = "采购单-分页列表查询")
|
||||||
|
@ApiOperation(value = "采购单-分页列表查询", notes = "采购单-分页列表查询")
|
||||||
|
@GetMapping(value = "/list")
|
||||||
|
public Result<IPage<NuInvoicingCgdMain>> queryPageList(NuInvoicingCgdMain nuInvoicingCgdMain,
|
||||||
|
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
|
||||||
|
@RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
|
||||||
|
HttpServletRequest req) {
|
||||||
|
QueryWrapper<NuInvoicingCgdMain> queryWrapper = QueryGenerator.initQueryWrapper(nuInvoicingCgdMain, req.getParameterMap());
|
||||||
|
Page<NuInvoicingCgdMain> page = new Page<NuInvoicingCgdMain>(pageNo, pageSize);
|
||||||
|
//付款单-生成采购单
|
||||||
|
if ("fukuandan".equals(nuInvoicingCgdMain.getResourceFrontView())) {
|
||||||
|
//没选择供应商时不应返回结果
|
||||||
|
if (StringUtils.isBlank(nuInvoicingCgdMain.getGysId())) {
|
||||||
|
Page<NuInvoicingCgdMain> emptyPage = new Page<>(pageNo, pageSize);
|
||||||
|
return Result.OK(emptyPage);
|
||||||
|
}else{
|
||||||
|
//生成付款单只查询“已完结”采购单
|
||||||
|
queryWrapper.eq("cgd_type","2");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
IPage<NuInvoicingCgdMain> pageList = nuInvoicingCgdMainService.page(page, queryWrapper);
|
||||||
|
return Result.OK(pageList);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 添加
|
||||||
|
*
|
||||||
|
* @param nuInvoicingCgdMain
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "采购单-添加")
|
||||||
|
@ApiOperation(value = "采购单-添加", notes = "采购单-添加")
|
||||||
|
@RequiresPermissions("cgd:nu_invoicing_cgd_main:add")
|
||||||
|
@PostMapping(value = "/add")
|
||||||
|
public Result<String> add(@RequestBody NuInvoicingCgdMain nuInvoicingCgdMain) {
|
||||||
|
nuInvoicingCgdMainService.save(nuInvoicingCgdMain);
|
||||||
|
return Result.OK("添加成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 编辑
|
||||||
|
*
|
||||||
|
* @param nuInvoicingCgdMain
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "采购单-编辑")
|
||||||
|
@ApiOperation(value = "采购单-编辑", notes = "采购单-编辑")
|
||||||
|
@RequiresPermissions("cgd:nu_invoicing_cgd_main:edit")
|
||||||
|
@RequestMapping(value = "/edit", method = {RequestMethod.PUT, RequestMethod.POST})
|
||||||
|
public Result<String> edit(@RequestBody NuInvoicingCgdMain nuInvoicingCgdMain) {
|
||||||
|
nuInvoicingCgdMainService.updateById(nuInvoicingCgdMain);
|
||||||
|
return Result.OK("编辑成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 通过id删除
|
||||||
|
*
|
||||||
|
* @param id
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "采购单-通过id删除")
|
||||||
|
@ApiOperation(value = "采购单-通过id删除", notes = "采购单-通过id删除")
|
||||||
|
@RequiresPermissions("cgd:nu_invoicing_cgd_main:delete")
|
||||||
|
@DeleteMapping(value = "/delete")
|
||||||
|
public Result<String> delete(@RequestParam(name = "id", required = true) String id) {
|
||||||
|
nuInvoicingCgdMainService.removeById(id);
|
||||||
|
return Result.OK("删除成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除
|
||||||
|
*
|
||||||
|
* @param ids
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "采购单-批量删除")
|
||||||
|
@ApiOperation(value = "采购单-批量删除", notes = "采购单-批量删除")
|
||||||
|
@RequiresPermissions("cgd:nu_invoicing_cgd_main:deleteBatch")
|
||||||
|
@DeleteMapping(value = "/deleteBatch")
|
||||||
|
public Result<String> deleteBatch(@RequestParam(name = "ids", required = true) String ids) {
|
||||||
|
this.nuInvoicingCgdMainService.removeByIds(Arrays.asList(ids.split(",")));
|
||||||
|
return Result.OK("批量删除成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 通过id查询
|
||||||
|
*
|
||||||
|
* @param id
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
//@AutoLog(value = "采购单-通过id查询")
|
||||||
|
@ApiOperation(value = "采购单-通过id查询", notes = "采购单-通过id查询")
|
||||||
|
@GetMapping(value = "/queryById")
|
||||||
|
public Result<NuInvoicingCgdMain> queryById(@RequestParam(name = "id", required = true) String id) {
|
||||||
|
NuInvoicingCgdMain nuInvoicingCgdMain = nuInvoicingCgdMainService.getById(id);
|
||||||
|
if (nuInvoicingCgdMain == null) {
|
||||||
|
return Result.error("未找到对应数据");
|
||||||
|
}
|
||||||
|
return Result.OK(nuInvoicingCgdMain);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导出excel
|
||||||
|
*
|
||||||
|
* @param request
|
||||||
|
* @param nuInvoicingCgdMain
|
||||||
|
*/
|
||||||
@RequiresPermissions("cgd:nu_invoicing_cgd_main:exportXls")
|
@RequiresPermissions("cgd:nu_invoicing_cgd_main:exportXls")
|
||||||
@RequestMapping(value = "/exportXls")
|
@RequestMapping(value = "/exportXls")
|
||||||
public ModelAndView exportXls(HttpServletRequest request, NuInvoicingCgdMain nuInvoicingCgdMain) {
|
public ModelAndView exportXls(HttpServletRequest request, NuInvoicingCgdMain nuInvoicingCgdMain) {
|
||||||
|
|
@ -165,12 +178,12 @@ public class NuInvoicingCgdMainController extends JeecgController<NuInvoicingCgd
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 通过excel导入数据
|
* 通过excel导入数据
|
||||||
*
|
*
|
||||||
* @param request
|
* @param request
|
||||||
* @param response
|
* @param response
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@RequiresPermissions("cgd:nu_invoicing_cgd_main:importExcel")
|
@RequiresPermissions("cgd:nu_invoicing_cgd_main:importExcel")
|
||||||
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
||||||
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
||||||
|
|
@ -178,22 +191,22 @@ public class NuInvoicingCgdMainController extends JeecgController<NuInvoicingCgd
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@AutoLog(value = "采购单-审核")
|
@AutoLog(value = "采购单-审核")
|
||||||
@ApiOperation(value="采购单-审核", notes="采购单-审核")
|
@ApiOperation(value = "采购单-审核", notes = "采购单-审核")
|
||||||
@RequiresPermissions("cgd:nu_invoicing_cgd_main:add")
|
@RequiresPermissions("cgd:nu_invoicing_cgd_main:add")
|
||||||
@PostMapping(value = "/auditInfo")
|
@PostMapping(value = "/auditInfo")
|
||||||
public Result<String> auditInfo(@RequestBody NuInvoicingCgdMain nuInvoicingCgdMain) {
|
public Result<String> auditInfo(@RequestBody NuInvoicingCgdMain nuInvoicingCgdMain) {
|
||||||
nuInvoicingCgdMainService.auditInfo(nuInvoicingCgdMain);
|
nuInvoicingCgdMainService.auditInfo(nuInvoicingCgdMain);
|
||||||
return Result.OK("添加成功!");
|
return Result.OK("添加成功!");
|
||||||
}
|
}
|
||||||
|
|
||||||
@AutoLog(value = "采购单-入库操作")
|
@AutoLog(value = "采购单-入库操作")
|
||||||
@ApiOperation(value="采购单-入库操作", notes="采购单-入库操作")
|
@ApiOperation(value = "采购单-入库操作", notes = "采购单-入库操作")
|
||||||
@RequiresPermissions("cgd:nu_invoicing_cgd_main:add")
|
@RequiresPermissions("cgd:nu_invoicing_cgd_main:add")
|
||||||
@PostMapping(value = "/rukuInfo")
|
@PostMapping(value = "/rukuInfo")
|
||||||
public Result<String> rukuInfo(@RequestBody NuInvoicingCgdMain nuInvoicingCgdMain) {
|
public Result<String> rukuInfo(@RequestBody NuInvoicingCgdMain nuInvoicingCgdMain) {
|
||||||
nuInvoicingCgdMainService.rukuInfo(nuInvoicingCgdMain);
|
nuInvoicingCgdMainService.rukuInfo(nuInvoicingCgdMain);
|
||||||
return Result.OK("添加成功!");
|
return Result.OK("添加成功!");
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -22,119 +22,175 @@ import lombok.experimental.Accessors;
|
||||||
/**
|
/**
|
||||||
* @Description: nu_invoicing_cgd_info
|
* @Description: nu_invoicing_cgd_info
|
||||||
* @Author: jeecg-boot
|
* @Author: jeecg-boot
|
||||||
* @Date: 2025-09-26
|
* @Date: 2025-09-26
|
||||||
* @Version: V1.0
|
* @Version: V1.0
|
||||||
*/
|
*/
|
||||||
@Data
|
@Data
|
||||||
@TableName("nu_invoicing_cgd_info")
|
@TableName("nu_invoicing_cgd_info")
|
||||||
@Accessors(chain = true)
|
@Accessors(chain = true)
|
||||||
@EqualsAndHashCode(callSuper = false)
|
@EqualsAndHashCode(callSuper = false)
|
||||||
@ApiModel(value="nu_invoicing_cgd_info对象", description="nu_invoicing_cgd_info")
|
@ApiModel(value = "nu_invoicing_cgd_info对象", description = "nu_invoicing_cgd_info")
|
||||||
public class NuInvoicingCgdInfo implements Serializable {
|
public class NuInvoicingCgdInfo implements Serializable {
|
||||||
private static final long serialVersionUID = 1L;
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
/**id*/
|
/**
|
||||||
@TableId(type = IdType.ASSIGN_ID)
|
* id
|
||||||
|
*/
|
||||||
|
@TableId(type = IdType.ASSIGN_ID)
|
||||||
@ApiModelProperty(value = "id")
|
@ApiModelProperty(value = "id")
|
||||||
private String id;
|
private String id;
|
||||||
/**createBy*/
|
/**
|
||||||
|
* createBy
|
||||||
|
*/
|
||||||
@ApiModelProperty(value = "createBy")
|
@ApiModelProperty(value = "createBy")
|
||||||
private String createBy;
|
private String createBy;
|
||||||
/**createTime*/
|
/**
|
||||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
* createTime
|
||||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
*/
|
||||||
|
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
@ApiModelProperty(value = "createTime")
|
@ApiModelProperty(value = "createTime")
|
||||||
private Date createTime;
|
private Date createTime;
|
||||||
/**updateBy*/
|
/**
|
||||||
|
* updateBy
|
||||||
|
*/
|
||||||
@ApiModelProperty(value = "updateBy")
|
@ApiModelProperty(value = "updateBy")
|
||||||
private String updateBy;
|
private String updateBy;
|
||||||
/**updateTime*/
|
/**
|
||||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
* updateTime
|
||||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
*/
|
||||||
|
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
@ApiModelProperty(value = "updateTime")
|
@ApiModelProperty(value = "updateTime")
|
||||||
private Date updateTime;
|
private Date updateTime;
|
||||||
/**sysOrgCode*/
|
/**
|
||||||
|
* sysOrgCode
|
||||||
|
*/
|
||||||
@ApiModelProperty(value = "sysOrgCode")
|
@ApiModelProperty(value = "sysOrgCode")
|
||||||
private String sysOrgCode;
|
private String sysOrgCode;
|
||||||
/**采购单id*/
|
/**
|
||||||
@Excel(name = "采购单id", width = 15)
|
* 采购单id
|
||||||
|
*/
|
||||||
|
@Excel(name = "采购单id", width = 15)
|
||||||
@ApiModelProperty(value = "采购单id")
|
@ApiModelProperty(value = "采购单id")
|
||||||
private String cgdId;
|
private String cgdId;
|
||||||
/**物料id*/
|
/**
|
||||||
@Excel(name = "物料id", width = 15)
|
* 物料id
|
||||||
|
*/
|
||||||
|
@Excel(name = "物料id", width = 15)
|
||||||
@ApiModelProperty(value = "物料id")
|
@ApiModelProperty(value = "物料id")
|
||||||
private String wlId;
|
private String wlId;
|
||||||
/**物料编码*/
|
/**
|
||||||
@Excel(name = "物料编码", width = 15)
|
* 物料编码
|
||||||
|
*/
|
||||||
|
@Excel(name = "物料编码", width = 15)
|
||||||
@ApiModelProperty(value = "物料编码")
|
@ApiModelProperty(value = "物料编码")
|
||||||
private String wlMaterialNo;
|
private String wlMaterialNo;
|
||||||
/**物料名称*/
|
/**
|
||||||
@Excel(name = "物料名称", width = 15)
|
* 物料名称
|
||||||
|
*/
|
||||||
|
@Excel(name = "物料名称", width = 15)
|
||||||
@ApiModelProperty(value = "物料名称")
|
@ApiModelProperty(value = "物料名称")
|
||||||
private String wlName;
|
private String wlName;
|
||||||
/**采购单位*/
|
/**
|
||||||
@Excel(name = "采购单位", width = 15)
|
* 采购单位
|
||||||
|
*/
|
||||||
|
@Excel(name = "采购单位", width = 15)
|
||||||
@ApiModelProperty(value = "采购单位")
|
@ApiModelProperty(value = "采购单位")
|
||||||
private String wlUnits;
|
private String wlUnits;
|
||||||
/**规格型号*/
|
/**
|
||||||
@Excel(name = "规格型号", width = 15)
|
* 规格型号
|
||||||
|
*/
|
||||||
|
@Excel(name = "规格型号", width = 15)
|
||||||
@ApiModelProperty(value = "规格型号")
|
@ApiModelProperty(value = "规格型号")
|
||||||
private String wlSpecificationModel;
|
private String wlSpecificationModel;
|
||||||
/**上限*/
|
/**
|
||||||
@Excel(name = "上限", width = 15)
|
* 上限
|
||||||
|
*/
|
||||||
|
@Excel(name = "上限", width = 15)
|
||||||
@ApiModelProperty(value = "上限")
|
@ApiModelProperty(value = "上限")
|
||||||
private String wlUpperLimit;
|
private String wlUpperLimit;
|
||||||
/**下限*/
|
/**
|
||||||
@Excel(name = "下限", width = 15)
|
* 下限
|
||||||
|
*/
|
||||||
|
@Excel(name = "下限", width = 15)
|
||||||
@ApiModelProperty(value = "下限")
|
@ApiModelProperty(value = "下限")
|
||||||
private String wlLowerLimit;
|
private String wlLowerLimit;
|
||||||
/**供应商id*/
|
/**
|
||||||
@Excel(name = "供应商id", width = 15)
|
* 供应商id
|
||||||
|
*/
|
||||||
|
@Excel(name = "供应商id", width = 15)
|
||||||
@ApiModelProperty(value = "供应商id")
|
@ApiModelProperty(value = "供应商id")
|
||||||
private String suppliersId;
|
private String suppliersId;
|
||||||
/**供应商名称*/
|
/**
|
||||||
@Excel(name = "供应商名称", width = 15)
|
* 供应商名称
|
||||||
|
*/
|
||||||
|
@Excel(name = "供应商名称", width = 15)
|
||||||
@ApiModelProperty(value = "供应商名称")
|
@ApiModelProperty(value = "供应商名称")
|
||||||
private String suppliersName;
|
private String suppliersName;
|
||||||
/**请购数量*/
|
/**
|
||||||
@Excel(name = "请购数量", width = 15)
|
* 请购数量
|
||||||
|
*/
|
||||||
|
@Excel(name = "请购数量", width = 15)
|
||||||
@ApiModelProperty(value = "请购数量")
|
@ApiModelProperty(value = "请购数量")
|
||||||
private Integer purchaseQuantity;
|
private Integer purchaseQuantity;
|
||||||
/**银行*/
|
/**
|
||||||
@Excel(name = "银行", width = 15)
|
* 银行
|
||||||
|
*/
|
||||||
|
@Excel(name = "银行", width = 15)
|
||||||
@ApiModelProperty(value = "银行")
|
@ApiModelProperty(value = "银行")
|
||||||
private String brand;
|
private String brand;
|
||||||
/**库房*/
|
/**
|
||||||
@Excel(name = "库房", width = 15)
|
* 库房
|
||||||
|
*/
|
||||||
|
@Excel(name = "库房", width = 15)
|
||||||
@ApiModelProperty(value = "库房")
|
@ApiModelProperty(value = "库房")
|
||||||
private String nuId;
|
private String nuId;
|
||||||
/**入库数量*/
|
/**
|
||||||
@Excel(name = "入库数量", width = 15)
|
* 入库数量
|
||||||
|
*/
|
||||||
|
@Excel(name = "入库数量", width = 15)
|
||||||
@ApiModelProperty(value = "入库数量")
|
@ApiModelProperty(value = "入库数量")
|
||||||
private Integer rksl;
|
private Integer rksl;
|
||||||
/**未入库数量*/
|
/**
|
||||||
@Excel(name = "未入库数量", width = 15)
|
* 未入库数量
|
||||||
|
*/
|
||||||
|
@Excel(name = "未入库数量", width = 15)
|
||||||
@ApiModelProperty(value = "未入库数量")
|
@ApiModelProperty(value = "未入库数量")
|
||||||
private Integer wrksl;
|
private Integer wrksl;
|
||||||
/**销账数量*/
|
/**
|
||||||
|
* 销账数量
|
||||||
|
*/
|
||||||
@Excel(name = "销账数量", width = 15)
|
@Excel(name = "销账数量", width = 15)
|
||||||
@ApiModelProperty(value = "销账数量")
|
@ApiModelProperty(value = "销账数量")
|
||||||
private Integer xzsl;
|
private Integer xzsl;
|
||||||
/**采购单价*/
|
/**
|
||||||
@Excel(name = "采购单价", width = 15)
|
* 采购单价
|
||||||
|
*/
|
||||||
|
@Excel(name = "采购单价", width = 15)
|
||||||
@ApiModelProperty(value = "采购单价")
|
@ApiModelProperty(value = "采购单价")
|
||||||
private BigDecimal procurementPrice;
|
private BigDecimal procurementPrice;
|
||||||
/**到货单价*/
|
/**
|
||||||
@Excel(name = "到货单价", width = 15)
|
* 到货单价
|
||||||
|
*/
|
||||||
|
@Excel(name = "到货单价", width = 15)
|
||||||
@ApiModelProperty(value = "到货单价")
|
@ApiModelProperty(value = "到货单价")
|
||||||
private BigDecimal arrivalPrice;
|
private BigDecimal arrivalPrice;
|
||||||
/**物料类别*/
|
/**
|
||||||
|
* 物料类别
|
||||||
|
*/
|
||||||
private String categoryId;
|
private String categoryId;
|
||||||
/**物料类型*/
|
/**
|
||||||
|
* 物料类型
|
||||||
|
*/
|
||||||
private String typeId;
|
private String typeId;
|
||||||
/**用药类型*/
|
/**
|
||||||
|
* 用药类型
|
||||||
|
*/
|
||||||
private String medicationId;
|
private String medicationId;
|
||||||
/**单据状态 0待入库 1挂账中 2已入库 3已销账*/
|
/**
|
||||||
|
* 单据状态 0待入库 1挂账中 2已入库 3已销账
|
||||||
|
*/
|
||||||
@Dict(dicCode = "cgd_wl_status")
|
@Dict(dicCode = "cgd_wl_status")
|
||||||
private String status;
|
private String status;
|
||||||
private String dhbl;
|
private String dhbl;
|
||||||
|
|
@ -159,6 +215,15 @@ public class NuInvoicingCgdInfo implements Serializable {
|
||||||
private java.lang.String medicationName;
|
private java.lang.String medicationName;
|
||||||
|
|
||||||
|
|
||||||
|
@TableField(exist = false)
|
||||||
|
private BigDecimal crkje;
|
||||||
|
@TableField(exist = false)
|
||||||
|
private String crksl;
|
||||||
|
@TableField(exist = false)
|
||||||
|
private BigDecimal xiaoJi;
|
||||||
|
@TableField(exist = false)
|
||||||
|
private BigDecimal zongJinE;
|
||||||
|
|
||||||
// // 格式化getter方法
|
// // 格式化getter方法
|
||||||
// public BigDecimal getProcurementPrice() {
|
// public BigDecimal getProcurementPrice() {
|
||||||
// BigDecimal result = procurementPrice != null ? procurementPrice.setScale(2, RoundingMode.DOWN) : null;
|
// BigDecimal result = procurementPrice != null ? procurementPrice.setScale(2, RoundingMode.DOWN) : null;
|
||||||
|
|
|
||||||
|
|
@ -154,4 +154,8 @@ public class NuInvoicingCgdMain implements Serializable {
|
||||||
/**采购的物料信息*/
|
/**采购的物料信息*/
|
||||||
@TableField(exist = false)
|
@TableField(exist = false)
|
||||||
private List<NuInvoicingCgdInfo> cgdInfoList;
|
private List<NuInvoicingCgdInfo> cgdInfoList;
|
||||||
|
|
||||||
|
/**来源于哪个前端界面*/
|
||||||
|
@TableField(exist = false)
|
||||||
|
private String resourceFrontView;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -3,8 +3,10 @@ package com.nu.modules.cgd.mapper;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
import com.baomidou.mybatisplus.core.toolkit.Constants;
|
import com.baomidou.mybatisplus.core.toolkit.Constants;
|
||||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
|
import com.nu.modules.cgd.entity.NuInvoicingCgdMain;
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
import com.nu.modules.cgd.entity.NuInvoicingCgdInfo;
|
import com.nu.modules.cgd.entity.NuInvoicingCgdInfo;
|
||||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
|
@ -20,4 +22,10 @@ public interface NuInvoicingCgdInfoMapper extends BaseMapper<NuInvoicingCgdInfo>
|
||||||
List<NuInvoicingCgdInfo> queryCgdInfoList(Page<NuInvoicingCgdInfo> page, @Param(Constants.WRAPPER) QueryWrapper<NuInvoicingCgdInfo> queryWrapper);
|
List<NuInvoicingCgdInfo> queryCgdInfoList(Page<NuInvoicingCgdInfo> page, @Param(Constants.WRAPPER) QueryWrapper<NuInvoicingCgdInfo> queryWrapper);
|
||||||
|
|
||||||
List<NuInvoicingCgdInfo> selectWlNumList(@Param("params") NuInvoicingCgdInfo nuInvoicingCgdInfo);
|
List<NuInvoicingCgdInfo> selectWlNumList(@Param("params") NuInvoicingCgdInfo nuInvoicingCgdInfo);
|
||||||
|
|
||||||
|
IPage<NuInvoicingCgdMain> getWjcgdByGys(IPage<NuInvoicingCgdMain> page, @Param("dto") NuInvoicingCgdMain dto);
|
||||||
|
|
||||||
|
List<NuInvoicingCgdInfo> totalPrice(@Param("dto") NuInvoicingCgdInfo nuInvoicingCgdInfo);
|
||||||
|
|
||||||
|
IPage<NuInvoicingCgdInfo> pageList(IPage<NuInvoicingCgdInfo> page, @Param("dto") NuInvoicingCgdInfo nuInvoicingCgdInfo);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -3,19 +3,57 @@
|
||||||
<mapper namespace="com.nu.modules.cgd.mapper.NuInvoicingCgdInfoMapper">
|
<mapper namespace="com.nu.modules.cgd.mapper.NuInvoicingCgdInfoMapper">
|
||||||
|
|
||||||
<select id="queryCgdInfoList" resultType="com.nu.modules.cgd.entity.NuInvoicingCgdInfo">
|
<select id="queryCgdInfoList" resultType="com.nu.modules.cgd.entity.NuInvoicingCgdInfo">
|
||||||
select a.*,b.material_img,b.tag_type,c.item_text as tagName,d.kcsl from nu_invoicing_cgd_info a
|
select a.*, b.material_img, b.tag_type, c.item_text as tagName, d.kcsl
|
||||||
left join nu_config_material_info b on a.wl_id = b.id
|
from nu_invoicing_cgd_info a
|
||||||
left join sys_dict_item c on b.tag_type = c.item_value and c.dict_id = '1978662656563613698'
|
left join nu_config_material_info b on a.wl_id = b.id
|
||||||
LEFT JOIN nu_warehouse_material_info d on a.wl_id = d.wl_id
|
left join sys_dict_item c on b.tag_type = c.item_value and c.dict_id = '1978662656563613698'
|
||||||
${ew.customSqlSegment}
|
LEFT JOIN nu_warehouse_material_info d on a.wl_id = d.wl_id
|
||||||
|
${ew.customSqlSegment}
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
|
||||||
<select id="selectWlNumList" resultType="com.nu.modules.cgd.entity.NuInvoicingCgdInfo">
|
<select id="selectWlNumList" resultType="com.nu.modules.cgd.entity.NuInvoicingCgdInfo">
|
||||||
select b.nu_id,b.wl_id,sum(purchase_quantity) as purchase_quantity from nu_invoicing_cgd_main a
|
select b.nu_id, b.wl_id, sum(purchase_quantity) as purchase_quantity
|
||||||
inner join nu_invoicing_cgd_info b on a.id = b.cgd_id
|
from nu_invoicing_cgd_main a
|
||||||
where a.status in (0,1)
|
inner join nu_invoicing_cgd_info b on a.id = b.cgd_id
|
||||||
and b.nu_id = #{params.nuId} and b.wl_id = #{params.wlId}
|
where a.status in (0, 1)
|
||||||
GROUP BY b.nu_id,b.wl_id
|
and b.nu_id = #{params.nuId}
|
||||||
|
and b.wl_id = #{params.wlId}
|
||||||
|
GROUP BY b.nu_id, b.wl_id
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="getWjcgdByGys" resultType="com.nu.modules.cgd.entity.NuInvoicingCgdMain">
|
||||||
|
select info.*
|
||||||
|
from nu_invoicing_cgd_info info
|
||||||
|
left join nu_invoicing_cgd_main main on info.cgd_id = main.id
|
||||||
|
where main.id = #{dto.id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="totalPrice" resultType="com.nu.modules.cgd.entity.NuInvoicingCgdInfo">
|
||||||
|
select crk.new_price AS crkje,crk.crk_num AS crksl
|
||||||
|
from nu_invoicing_cgd_info info
|
||||||
|
left join nu_warehouse_material_crk_info crk on crk.cgd_id = info.cgd_id and crk.wl_id = info.wl_id
|
||||||
|
<where>
|
||||||
|
crk.crk_status = 1 and crk.crk_type = 1
|
||||||
|
<if test="dto.cgdId != null and dto.cgdId != ''">
|
||||||
|
and crk.cgd_id in
|
||||||
|
<foreach collection="dto.cgdId.split(',')" item="id" open="(" separator="," close=")">
|
||||||
|
#{id}
|
||||||
|
</foreach>
|
||||||
|
</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="pageList" resultType="com.nu.modules.cgd.entity.NuInvoicingCgdInfo">
|
||||||
|
select info.*,crk.new_price AS crkje,crk.crk_num AS crksl
|
||||||
|
from nu_invoicing_cgd_info info
|
||||||
|
left join nu_warehouse_material_crk_info crk on crk.cgd_id = info.cgd_id and crk.wl_id = info.wl_id
|
||||||
|
<where>
|
||||||
|
crk.crk_status = 1 and crk.crk_type = 1
|
||||||
|
<if test="dto.cgdId != null and dto.cgdId != ''">
|
||||||
|
and crk.cgd_id = #{dto.cgdId}
|
||||||
|
</if>
|
||||||
|
</where>
|
||||||
|
order by crk.create_by desc
|
||||||
</select>
|
</select>
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|
@ -1,7 +1,13 @@
|
||||||
package com.nu.modules.cgd.service;
|
package com.nu.modules.cgd.service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
import com.nu.modules.cgd.entity.NuInvoicingCgdInfo;
|
import com.nu.modules.cgd.entity.NuInvoicingCgdInfo;
|
||||||
import com.baomidou.mybatisplus.extension.service.IService;
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
import com.nu.modules.cgd.entity.NuInvoicingCgdMain;
|
||||||
|
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @Description: nu_invoicing_cgd_info
|
* @Description: nu_invoicing_cgd_info
|
||||||
|
|
@ -11,4 +17,9 @@ import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
*/
|
*/
|
||||||
public interface INuInvoicingCgdInfoService extends IService<NuInvoicingCgdInfo> {
|
public interface INuInvoicingCgdInfoService extends IService<NuInvoicingCgdInfo> {
|
||||||
|
|
||||||
|
IPage<NuInvoicingCgdMain> getWjcgdByGys(NuInvoicingCgdMain dto, Integer pageNo, Integer pageSize);
|
||||||
|
|
||||||
|
IPage<NuInvoicingCgdInfo> pageList(Page<NuInvoicingCgdInfo> page, NuInvoicingCgdInfo nuInvoicingCgdInfo);
|
||||||
|
|
||||||
|
BigDecimal calcTotalPrice(NuInvoicingCgdInfo nuInvoicingCgdInfo);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,19 +1,80 @@
|
||||||
package com.nu.modules.cgd.service.impl;
|
package com.nu.modules.cgd.service.impl;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
import com.nu.modules.cgd.entity.NuInvoicingCgdInfo;
|
import com.nu.modules.cgd.entity.NuInvoicingCgdInfo;
|
||||||
|
import com.nu.modules.cgd.entity.NuInvoicingCgdMain;
|
||||||
import com.nu.modules.cgd.mapper.NuInvoicingCgdInfoMapper;
|
import com.nu.modules.cgd.mapper.NuInvoicingCgdInfoMapper;
|
||||||
import com.nu.modules.cgd.service.INuInvoicingCgdInfoService;
|
import com.nu.modules.cgd.service.INuInvoicingCgdInfoService;
|
||||||
|
import org.apache.commons.lang.StringUtils;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
import java.math.BigDecimal;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @Description: nu_invoicing_cgd_info
|
* @Description: nu_invoicing_cgd_info
|
||||||
* @Author: jeecg-boot
|
* @Author: jeecg-boot
|
||||||
* @Date: 2025-09-26
|
* @Date: 2025-09-26
|
||||||
* @Version: V1.0
|
* @Version: V1.0
|
||||||
*/
|
*/
|
||||||
@Service
|
@Service
|
||||||
public class NuInvoicingCgdInfoServiceImpl extends ServiceImpl<NuInvoicingCgdInfoMapper, NuInvoicingCgdInfo> implements INuInvoicingCgdInfoService {
|
public class NuInvoicingCgdInfoServiceImpl extends ServiceImpl<NuInvoicingCgdInfoMapper, NuInvoicingCgdInfo> implements INuInvoicingCgdInfoService {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public IPage<NuInvoicingCgdMain> getWjcgdByGys(NuInvoicingCgdMain dto, Integer pageNo, Integer pageSize) {
|
||||||
|
IPage<NuInvoicingCgdMain> page = new Page<>(pageNo, pageSize);
|
||||||
|
return baseMapper.getWjcgdByGys(page, dto);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public IPage<NuInvoicingCgdInfo> pageList(Page<NuInvoicingCgdInfo> page, NuInvoicingCgdInfo dto) {
|
||||||
|
//计算总金额
|
||||||
|
BigDecimal totalSum = BigDecimal.ZERO; // 用来存储总和
|
||||||
|
{
|
||||||
|
//采购单下所有已入库物料的价格、数量
|
||||||
|
List<NuInvoicingCgdInfo> totalPriceList = baseMapper.totalPrice(dto);
|
||||||
|
for (NuInvoicingCgdInfo item : totalPriceList) {
|
||||||
|
if (item.getCrkje() != null && StringUtils.isNotBlank(item.getCrksl())) {
|
||||||
|
// 计算每条记录的 crkje * crksl
|
||||||
|
BigDecimal totalPrice = item.getCrkje().multiply(new BigDecimal(item.getCrksl()));
|
||||||
|
totalSum = totalSum.add(totalPrice); // 将每条记录的结果累加到 totalSum
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//分页数据
|
||||||
|
IPage<NuInvoicingCgdInfo> result = baseMapper.pageList(page, dto);
|
||||||
|
List<NuInvoicingCgdInfo> records = result.getRecords();
|
||||||
|
for (int i = 0; i < records.size(); i++) {
|
||||||
|
NuInvoicingCgdInfo item = records.get(i);
|
||||||
|
if (item.getCrkje() != null && StringUtils.isNotBlank(item.getCrksl())) {
|
||||||
|
// 计算每条记录的 crkje * crksl
|
||||||
|
item.setXiaoJi(item.getCrkje().multiply(new BigDecimal(item.getCrksl())));
|
||||||
|
//总金额
|
||||||
|
item.setZongJinE(totalSum);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public BigDecimal calcTotalPrice(NuInvoicingCgdInfo dto) {
|
||||||
|
BigDecimal totalSum = BigDecimal.ZERO;
|
||||||
|
{
|
||||||
|
//采购单下所有已入库物料的价格、数量
|
||||||
|
List<NuInvoicingCgdInfo> totalPriceList = baseMapper.totalPrice(dto);
|
||||||
|
for (NuInvoicingCgdInfo item : totalPriceList) {
|
||||||
|
if (item.getCrkje() != null && StringUtils.isNotBlank(item.getCrksl())) {
|
||||||
|
// 计算每条记录的 crkje * crksl
|
||||||
|
BigDecimal totalPrice = item.getCrkje().multiply(new BigDecimal(item.getCrksl()));
|
||||||
|
totalSum = totalSum.add(totalPrice); // 将每条记录的结果累加到 totalSum
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return totalSum;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,180 @@
|
||||||
|
package com.nu.modules.fkd.controller;
|
||||||
|
|
||||||
|
import java.util.Arrays;
|
||||||
|
import java.util.HashMap;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
import java.util.stream.Collectors;
|
||||||
|
import java.io.IOException;
|
||||||
|
import java.io.UnsupportedEncodingException;
|
||||||
|
import java.net.URLDecoder;
|
||||||
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
import org.jeecg.common.api.vo.Result;
|
||||||
|
import org.jeecg.common.system.query.QueryGenerator;
|
||||||
|
import org.jeecg.common.system.query.QueryRuleEnum;
|
||||||
|
import org.jeecg.common.util.oConvertUtils;
|
||||||
|
import com.nu.modules.fkd.entity.NuInvoicingFkdInfo;
|
||||||
|
import com.nu.modules.fkd.service.INuInvoicingFkdInfoService;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
|
||||||
|
import org.jeecgframework.poi.excel.ExcelImportUtil;
|
||||||
|
import org.jeecgframework.poi.excel.def.NormalExcelConstants;
|
||||||
|
import org.jeecgframework.poi.excel.entity.ExportParams;
|
||||||
|
import org.jeecgframework.poi.excel.entity.ImportParams;
|
||||||
|
import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
|
||||||
|
import org.jeecg.common.system.base.controller.JeecgController;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
import org.springframework.web.multipart.MultipartFile;
|
||||||
|
import org.springframework.web.multipart.MultipartHttpServletRequest;
|
||||||
|
import org.springframework.web.servlet.ModelAndView;
|
||||||
|
import com.alibaba.fastjson.JSON;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
|
import org.jeecg.common.aspect.annotation.AutoLog;
|
||||||
|
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 进销存-付款单详细信息
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2025-11-21
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
@Api(tags="进销存-付款单详细信息")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/fkd/nuInvoicingFkdInfo")
|
||||||
|
@Slf4j
|
||||||
|
public class NuInvoicingFkdInfoController extends JeecgController<NuInvoicingFkdInfo, INuInvoicingFkdInfoService> {
|
||||||
|
@Autowired
|
||||||
|
private INuInvoicingFkdInfoService nuInvoicingFkdInfoService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页列表查询
|
||||||
|
*
|
||||||
|
* @param nuInvoicingFkdInfo
|
||||||
|
* @param pageNo
|
||||||
|
* @param pageSize
|
||||||
|
* @param req
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
//@AutoLog(value = "进销存-付款单详细信息-分页列表查询")
|
||||||
|
@ApiOperation(value="进销存-付款单详细信息-分页列表查询", notes="进销存-付款单详细信息-分页列表查询")
|
||||||
|
@GetMapping(value = "/list")
|
||||||
|
public Result<IPage<NuInvoicingFkdInfo>> queryPageList(NuInvoicingFkdInfo nuInvoicingFkdInfo,
|
||||||
|
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
||||||
|
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
|
||||||
|
HttpServletRequest req) {
|
||||||
|
QueryWrapper<NuInvoicingFkdInfo> queryWrapper = QueryGenerator.initQueryWrapper(nuInvoicingFkdInfo, req.getParameterMap());
|
||||||
|
Page<NuInvoicingFkdInfo> page = new Page<NuInvoicingFkdInfo>(pageNo, pageSize);
|
||||||
|
IPage<NuInvoicingFkdInfo> pageList = nuInvoicingFkdInfoService.page(page, queryWrapper);
|
||||||
|
return Result.OK(pageList);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 添加
|
||||||
|
*
|
||||||
|
* @param nuInvoicingFkdInfo
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "进销存-付款单详细信息-添加")
|
||||||
|
@ApiOperation(value="进销存-付款单详细信息-添加", notes="进销存-付款单详细信息-添加")
|
||||||
|
@RequiresPermissions("fkd:nu_invoicing_fkd_info:add")
|
||||||
|
@PostMapping(value = "/add")
|
||||||
|
public Result<String> add(@RequestBody NuInvoicingFkdInfo nuInvoicingFkdInfo) {
|
||||||
|
nuInvoicingFkdInfoService.save(nuInvoicingFkdInfo);
|
||||||
|
return Result.OK("添加成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 编辑
|
||||||
|
*
|
||||||
|
* @param nuInvoicingFkdInfo
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "进销存-付款单详细信息-编辑")
|
||||||
|
@ApiOperation(value="进销存-付款单详细信息-编辑", notes="进销存-付款单详细信息-编辑")
|
||||||
|
@RequiresPermissions("fkd:nu_invoicing_fkd_info:edit")
|
||||||
|
@RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST})
|
||||||
|
public Result<String> edit(@RequestBody NuInvoicingFkdInfo nuInvoicingFkdInfo) {
|
||||||
|
nuInvoicingFkdInfoService.updateById(nuInvoicingFkdInfo);
|
||||||
|
return Result.OK("编辑成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 通过id删除
|
||||||
|
*
|
||||||
|
* @param id
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "进销存-付款单详细信息-通过id删除")
|
||||||
|
@ApiOperation(value="进销存-付款单详细信息-通过id删除", notes="进销存-付款单详细信息-通过id删除")
|
||||||
|
@RequiresPermissions("fkd:nu_invoicing_fkd_info:delete")
|
||||||
|
@DeleteMapping(value = "/delete")
|
||||||
|
public Result<String> delete(@RequestParam(name="id",required=true) String id) {
|
||||||
|
nuInvoicingFkdInfoService.removeById(id);
|
||||||
|
return Result.OK("删除成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除
|
||||||
|
*
|
||||||
|
* @param ids
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "进销存-付款单详细信息-批量删除")
|
||||||
|
@ApiOperation(value="进销存-付款单详细信息-批量删除", notes="进销存-付款单详细信息-批量删除")
|
||||||
|
@RequiresPermissions("fkd:nu_invoicing_fkd_info:deleteBatch")
|
||||||
|
@DeleteMapping(value = "/deleteBatch")
|
||||||
|
public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
|
||||||
|
this.nuInvoicingFkdInfoService.removeByIds(Arrays.asList(ids.split(",")));
|
||||||
|
return Result.OK("批量删除成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 通过id查询
|
||||||
|
*
|
||||||
|
* @param id
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
//@AutoLog(value = "进销存-付款单详细信息-通过id查询")
|
||||||
|
@ApiOperation(value="进销存-付款单详细信息-通过id查询", notes="进销存-付款单详细信息-通过id查询")
|
||||||
|
@GetMapping(value = "/queryById")
|
||||||
|
public Result<NuInvoicingFkdInfo> queryById(@RequestParam(name="id",required=true) String id) {
|
||||||
|
NuInvoicingFkdInfo nuInvoicingFkdInfo = nuInvoicingFkdInfoService.getById(id);
|
||||||
|
if(nuInvoicingFkdInfo==null) {
|
||||||
|
return Result.error("未找到对应数据");
|
||||||
|
}
|
||||||
|
return Result.OK(nuInvoicingFkdInfo);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导出excel
|
||||||
|
*
|
||||||
|
* @param request
|
||||||
|
* @param nuInvoicingFkdInfo
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("fkd:nu_invoicing_fkd_info:exportXls")
|
||||||
|
@RequestMapping(value = "/exportXls")
|
||||||
|
public ModelAndView exportXls(HttpServletRequest request, NuInvoicingFkdInfo nuInvoicingFkdInfo) {
|
||||||
|
return super.exportXls(request, nuInvoicingFkdInfo, NuInvoicingFkdInfo.class, "进销存-付款单详细信息");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 通过excel导入数据
|
||||||
|
*
|
||||||
|
* @param request
|
||||||
|
* @param response
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("fkd:nu_invoicing_fkd_info:importExcel")
|
||||||
|
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
||||||
|
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
||||||
|
return super.importExcel(request, response, NuInvoicingFkdInfo.class);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,265 @@
|
||||||
|
package com.nu.modules.fkd.controller;
|
||||||
|
|
||||||
|
import java.time.LocalDate;
|
||||||
|
import java.time.format.DateTimeFormatter;
|
||||||
|
import java.util.Arrays;
|
||||||
|
import java.util.HashMap;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
import java.util.stream.Collectors;
|
||||||
|
import java.io.IOException;
|
||||||
|
import java.io.UnsupportedEncodingException;
|
||||||
|
import java.net.URLDecoder;
|
||||||
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
|
import cn.hutool.core.util.IdUtil;
|
||||||
|
import com.alibaba.fastjson.JSONObject;
|
||||||
|
import com.nu.modules.cgd.entity.NuInvoicingCgdMain;
|
||||||
|
import com.nu.modules.cgd.service.INuInvoicingCgdInfoService;
|
||||||
|
import com.nu.modules.configSuppliersInfo.entity.ConfigSuppliersInfo;
|
||||||
|
import com.nu.modules.configSuppliersInfo.service.IConfigSuppliersInfoService;
|
||||||
|
import com.nu.modules.fkd.entity.NuInvoicingFkdInfo;
|
||||||
|
import com.nu.modules.fkd.service.INuInvoicingFkdInfoService;
|
||||||
|
import org.jeecg.common.api.vo.Result;
|
||||||
|
import org.jeecg.common.system.api.ISysBaseAPI;
|
||||||
|
import org.jeecg.common.system.query.QueryGenerator;
|
||||||
|
import org.jeecg.common.system.query.QueryRuleEnum;
|
||||||
|
import org.jeecg.common.util.oConvertUtils;
|
||||||
|
import com.nu.modules.fkd.entity.NuInvoicingFkdMain;
|
||||||
|
import com.nu.modules.fkd.service.INuInvoicingFkdMainService;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
|
||||||
|
import org.jeecgframework.poi.excel.ExcelImportUtil;
|
||||||
|
import org.jeecgframework.poi.excel.def.NormalExcelConstants;
|
||||||
|
import org.jeecgframework.poi.excel.entity.ExportParams;
|
||||||
|
import org.jeecgframework.poi.excel.entity.ImportParams;
|
||||||
|
import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
|
||||||
|
import org.jeecg.common.system.base.controller.JeecgController;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
import org.springframework.web.multipart.MultipartFile;
|
||||||
|
import org.springframework.web.multipart.MultipartHttpServletRequest;
|
||||||
|
import org.springframework.web.servlet.ModelAndView;
|
||||||
|
import com.alibaba.fastjson.JSON;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
|
import org.jeecg.common.aspect.annotation.AutoLog;
|
||||||
|
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 进销存-付款单主信息
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2025-11-21
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
@Api(tags = "进销存-付款单主信息")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/fkd/nuInvoicingFkdMain")
|
||||||
|
@Slf4j
|
||||||
|
public class NuInvoicingFkdMainController extends JeecgController<NuInvoicingFkdMain, INuInvoicingFkdMainService> {
|
||||||
|
@Autowired
|
||||||
|
private INuInvoicingFkdMainService nuInvoicingFkdMainService;
|
||||||
|
@Autowired
|
||||||
|
private ISysBaseAPI sysBaseAPI;
|
||||||
|
@Autowired
|
||||||
|
private IConfigSuppliersInfoService suppliersInfoService;
|
||||||
|
@Autowired
|
||||||
|
private INuInvoicingFkdInfoService invoicingFkdInfoService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页列表查询
|
||||||
|
*
|
||||||
|
* @param nuInvoicingFkdMain
|
||||||
|
* @param pageNo
|
||||||
|
* @param pageSize
|
||||||
|
* @param req
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
//@AutoLog(value = "进销存-付款单主信息-分页列表查询")
|
||||||
|
@ApiOperation(value = "进销存-付款单主信息-分页列表查询", notes = "进销存-付款单主信息-分页列表查询")
|
||||||
|
@GetMapping(value = "/list")
|
||||||
|
public Result<IPage<NuInvoicingFkdMain>> queryPageList(NuInvoicingFkdMain nuInvoicingFkdMain,
|
||||||
|
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
|
||||||
|
@RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
|
||||||
|
HttpServletRequest req) {
|
||||||
|
// 自定义查询规则
|
||||||
|
Map<String, QueryRuleEnum> customeRuleMap = new HashMap<>();
|
||||||
|
// 自定义多选的查询规则为:LIKE_WITH_OR
|
||||||
|
customeRuleMap.put("status", QueryRuleEnum.LIKE_WITH_OR);
|
||||||
|
QueryWrapper<NuInvoicingFkdMain> queryWrapper = QueryGenerator.initQueryWrapper(nuInvoicingFkdMain, req.getParameterMap(), customeRuleMap);
|
||||||
|
Page<NuInvoicingFkdMain> page = new Page<NuInvoicingFkdMain>(pageNo, pageSize);
|
||||||
|
IPage<NuInvoicingFkdMain> pageList = nuInvoicingFkdMainService.page(page, queryWrapper);
|
||||||
|
return Result.OK(pageList);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生成新的付款单
|
||||||
|
*
|
||||||
|
* @param dto
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "进销存-付款单主信息-添加")
|
||||||
|
@ApiOperation(value = "进销存-付款单主信息-添加", notes = "进销存-付款单主信息-添加")
|
||||||
|
@RequiresPermissions("fkd:nu_invoicing_fkd_main:add")
|
||||||
|
@PostMapping(value = "/add")
|
||||||
|
public Result<String> add(@RequestBody NuInvoicingFkdMain dto) {
|
||||||
|
NuInvoicingFkdMain saveData = new NuInvoicingFkdMain();
|
||||||
|
//查询当前编码
|
||||||
|
QueryWrapper<NuInvoicingFkdMain> qw = new QueryWrapper<>();
|
||||||
|
qw.orderByDesc("create_time");
|
||||||
|
List<NuInvoicingFkdMain> list = nuInvoicingFkdMainService.list(qw);
|
||||||
|
String fkdOrder = "001";
|
||||||
|
if (list != null && list.size() > 0) {
|
||||||
|
int fkdNoOrder = list.get(0).getFkdNoOrder();
|
||||||
|
fkdOrder = String.format("%03d", fkdNoOrder + 1);
|
||||||
|
saveData.setFkdNoOrder(fkdNoOrder + 1);
|
||||||
|
} else {
|
||||||
|
saveData.setFkdNoOrder(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
//查询机构编码
|
||||||
|
JSONObject deptInfo = sysBaseAPI.getDeptInfo();
|
||||||
|
|
||||||
|
//查询供应商开户行信息
|
||||||
|
QueryWrapper<ConfigSuppliersInfo> khhQw = new QueryWrapper<>();
|
||||||
|
khhQw.eq("id", dto.getGysId());
|
||||||
|
ConfigSuppliersInfo khhInfo = suppliersInfoService.getOne(khhQw);
|
||||||
|
|
||||||
|
//规则 F+机构编码+年月日+排序
|
||||||
|
saveData.setFkdNo("F" + deptInfo.getString("code") + LocalDate.now().format(DateTimeFormatter.ofPattern("yyyyMMdd")) + fkdOrder);
|
||||||
|
saveData.setGysId(dto.getGysId());
|
||||||
|
saveData.setGysName(dto.getGysName());
|
||||||
|
if (khhInfo != null) {
|
||||||
|
saveData.setOpeningBank(khhInfo.getOpeningBank());
|
||||||
|
saveData.setOpeningBankNo(khhInfo.getOpeningBankNo());
|
||||||
|
}
|
||||||
|
saveData.setTotalPrice(dto.getTotalPrice());
|
||||||
|
saveData.setStatus("0");
|
||||||
|
|
||||||
|
|
||||||
|
nuInvoicingFkdMainService.save(saveData);
|
||||||
|
|
||||||
|
//添加子表数据
|
||||||
|
String cgdIds = dto.getCgdIds();
|
||||||
|
String[] cgdIdsArr = cgdIds.split(",");
|
||||||
|
for (int i = 0; i < cgdIdsArr.length; i++) {
|
||||||
|
NuInvoicingFkdInfo fkdInfo = new NuInvoicingFkdInfo();
|
||||||
|
fkdInfo.setCgdId(cgdIdsArr[i]);
|
||||||
|
fkdInfo.setPkId(saveData.getId());
|
||||||
|
invoicingFkdInfoService.save(fkdInfo);
|
||||||
|
}
|
||||||
|
|
||||||
|
return Result.OK("添加成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 编辑
|
||||||
|
*
|
||||||
|
* @param nuInvoicingFkdMain
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "进销存-付款单主信息-编辑")
|
||||||
|
@ApiOperation(value = "进销存-付款单主信息-编辑", notes = "进销存-付款单主信息-编辑")
|
||||||
|
@RequiresPermissions("fkd:nu_invoicing_fkd_main:edit")
|
||||||
|
@RequestMapping(value = "/edit", method = {RequestMethod.PUT, RequestMethod.POST})
|
||||||
|
public Result<String> edit(@RequestBody NuInvoicingFkdMain nuInvoicingFkdMain) {
|
||||||
|
nuInvoicingFkdMainService.updateById(nuInvoicingFkdMain);
|
||||||
|
return Result.OK("编辑成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 通过id删除
|
||||||
|
*
|
||||||
|
* @param id
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "进销存-付款单主信息-通过id删除")
|
||||||
|
@ApiOperation(value = "进销存-付款单主信息-通过id删除", notes = "进销存-付款单主信息-通过id删除")
|
||||||
|
@RequiresPermissions("fkd:nu_invoicing_fkd_main:delete")
|
||||||
|
@DeleteMapping(value = "/delete")
|
||||||
|
public Result<String> delete(@RequestParam(name = "id", required = true) String id) {
|
||||||
|
nuInvoicingFkdMainService.removeById(id);
|
||||||
|
return Result.OK("删除成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除
|
||||||
|
*
|
||||||
|
* @param ids
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "进销存-付款单主信息-批量删除")
|
||||||
|
@ApiOperation(value = "进销存-付款单主信息-批量删除", notes = "进销存-付款单主信息-批量删除")
|
||||||
|
@RequiresPermissions("fkd:nu_invoicing_fkd_main:deleteBatch")
|
||||||
|
@DeleteMapping(value = "/deleteBatch")
|
||||||
|
public Result<String> deleteBatch(@RequestParam(name = "ids", required = true) String ids) {
|
||||||
|
this.nuInvoicingFkdMainService.removeByIds(Arrays.asList(ids.split(",")));
|
||||||
|
return Result.OK("批量删除成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 通过id查询
|
||||||
|
*
|
||||||
|
* @param id
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
//@AutoLog(value = "进销存-付款单主信息-通过id查询")
|
||||||
|
@ApiOperation(value = "进销存-付款单主信息-通过id查询", notes = "进销存-付款单主信息-通过id查询")
|
||||||
|
@GetMapping(value = "/queryById")
|
||||||
|
public Result<NuInvoicingFkdMain> queryById(@RequestParam(name = "id", required = true) String id) {
|
||||||
|
NuInvoicingFkdMain nuInvoicingFkdMain = nuInvoicingFkdMainService.getById(id);
|
||||||
|
if (nuInvoicingFkdMain == null) {
|
||||||
|
return Result.error("未找到对应数据");
|
||||||
|
}
|
||||||
|
return Result.OK(nuInvoicingFkdMain);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导出excel
|
||||||
|
*
|
||||||
|
* @param request
|
||||||
|
* @param nuInvoicingFkdMain
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("fkd:nu_invoicing_fkd_main:exportXls")
|
||||||
|
@RequestMapping(value = "/exportXls")
|
||||||
|
public ModelAndView exportXls(HttpServletRequest request, NuInvoicingFkdMain nuInvoicingFkdMain) {
|
||||||
|
return super.exportXls(request, nuInvoicingFkdMain, NuInvoicingFkdMain.class, "进销存-付款单主信息");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 通过excel导入数据
|
||||||
|
*
|
||||||
|
* @param request
|
||||||
|
* @param response
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("fkd:nu_invoicing_fkd_main:importExcel")
|
||||||
|
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
||||||
|
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
||||||
|
return super.importExcel(request, response, NuInvoicingFkdMain.class);
|
||||||
|
}
|
||||||
|
|
||||||
|
// /**
|
||||||
|
// * 根据供应商查询已完结付款单
|
||||||
|
// *
|
||||||
|
// * @param dto
|
||||||
|
// * @param pageNo
|
||||||
|
// * @param pageSize
|
||||||
|
// * @param req
|
||||||
|
// * @return
|
||||||
|
// */
|
||||||
|
// //@AutoLog(value = "进销存-根据供应商查询已完结付款单")
|
||||||
|
// @ApiOperation(value = "进销存-付款单主信息-分页列表查询", notes = "进销存-根据供应商查询已完结付款单")
|
||||||
|
// @GetMapping(value = "/getWjcgdByGys")
|
||||||
|
// public Result<IPage<NuInvoicingCgdMain>> getWjcgdByGys(NuInvoicingCgdMain dto,
|
||||||
|
// @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
|
||||||
|
// @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
|
||||||
|
// HttpServletRequest req) {
|
||||||
|
// return Result.OK(invoicingCgdInfoService.getWjcgdByGys(dto, pageNo, pageSize));
|
||||||
|
// }
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,65 @@
|
||||||
|
package com.nu.modules.fkd.entity;
|
||||||
|
|
||||||
|
import java.io.Serializable;
|
||||||
|
import java.io.UnsupportedEncodingException;
|
||||||
|
import java.util.Date;
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
import com.baomidou.mybatisplus.annotation.IdType;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableId;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableLogic;
|
||||||
|
import org.jeecg.common.constant.ProvinceCityArea;
|
||||||
|
import org.jeecg.common.util.SpringContextUtils;
|
||||||
|
import lombok.Data;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import org.jeecgframework.poi.excel.annotation.Excel;
|
||||||
|
import org.jeecg.common.aspect.annotation.Dict;
|
||||||
|
import io.swagger.annotations.ApiModel;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.EqualsAndHashCode;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 进销存-付款单详细信息
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2025-11-21
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@TableName("nu_invoicing_fkd_info")
|
||||||
|
@Accessors(chain = true)
|
||||||
|
@EqualsAndHashCode(callSuper = false)
|
||||||
|
@ApiModel(value="nu_invoicing_fkd_info对象", description="进销存-付款单详细信息")
|
||||||
|
public class NuInvoicingFkdInfo implements Serializable {
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
/**id*/
|
||||||
|
@TableId(type = IdType.ASSIGN_ID)
|
||||||
|
@ApiModelProperty(value = "id")
|
||||||
|
private java.lang.String id;
|
||||||
|
/**采购单id nu_invoicing_cgd_main.id*/
|
||||||
|
@Excel(name = "采购单id nu_invoicing_cgd_main.id", width = 15)
|
||||||
|
@ApiModelProperty(value = "采购单id nu_invoicing_cgd_main.id")
|
||||||
|
private java.lang.String cgdId;
|
||||||
|
/**主表id nu_invoicing_fkd_main.id*/
|
||||||
|
@Excel(name = "主表id nu_invoicing_fkd_main.id", width = 15)
|
||||||
|
@ApiModelProperty(value = "主表id nu_invoicing_fkd_main.id")
|
||||||
|
private java.lang.String pkId;
|
||||||
|
/**createBy*/
|
||||||
|
@ApiModelProperty(value = "createBy")
|
||||||
|
private java.lang.String createBy;
|
||||||
|
/**createTime*/
|
||||||
|
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
|
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||||
|
@ApiModelProperty(value = "createTime")
|
||||||
|
private java.util.Date createTime;
|
||||||
|
/**updateBy*/
|
||||||
|
@ApiModelProperty(value = "updateBy")
|
||||||
|
private java.lang.String updateBy;
|
||||||
|
/**updateTime*/
|
||||||
|
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
|
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||||
|
@ApiModelProperty(value = "updateTime")
|
||||||
|
private java.util.Date updateTime;
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,108 @@
|
||||||
|
package com.nu.modules.fkd.entity;
|
||||||
|
|
||||||
|
import java.io.Serializable;
|
||||||
|
import java.io.UnsupportedEncodingException;
|
||||||
|
import java.util.Date;
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.*;
|
||||||
|
import org.jeecg.common.constant.ProvinceCityArea;
|
||||||
|
import org.jeecg.common.util.SpringContextUtils;
|
||||||
|
import lombok.Data;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import org.jeecgframework.poi.excel.annotation.Excel;
|
||||||
|
import org.jeecg.common.aspect.annotation.Dict;
|
||||||
|
import io.swagger.annotations.ApiModel;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.EqualsAndHashCode;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 进销存-付款单主信息
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2025-11-21
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@TableName("nu_invoicing_fkd_main")
|
||||||
|
@Accessors(chain = true)
|
||||||
|
@EqualsAndHashCode(callSuper = false)
|
||||||
|
@ApiModel(value="nu_invoicing_fkd_main对象", description="进销存-付款单主信息")
|
||||||
|
public class NuInvoicingFkdMain implements Serializable {
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
/**id*/
|
||||||
|
@TableId(type = IdType.ASSIGN_ID)
|
||||||
|
@ApiModelProperty(value = "id")
|
||||||
|
private java.lang.String id;
|
||||||
|
/**createBy*/
|
||||||
|
@ApiModelProperty(value = "createBy")
|
||||||
|
private java.lang.String createBy;
|
||||||
|
/**createTime*/
|
||||||
|
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
|
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||||
|
@ApiModelProperty(value = "createTime")
|
||||||
|
private java.util.Date createTime;
|
||||||
|
/**updateBy*/
|
||||||
|
@ApiModelProperty(value = "updateBy")
|
||||||
|
private java.lang.String updateBy;
|
||||||
|
/**updateTime*/
|
||||||
|
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
|
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||||
|
@ApiModelProperty(value = "updateTime")
|
||||||
|
private java.util.Date updateTime;
|
||||||
|
/**付款单单号*/
|
||||||
|
@Excel(name = "付款单单号", width = 15)
|
||||||
|
@ApiModelProperty(value = "付款单单号")
|
||||||
|
private java.lang.String fkdNo;
|
||||||
|
/**供应商*/
|
||||||
|
@Excel(name = "供应商", width = 15, dictTable = "nu_invoicing_fkd_main", dicText = "gys_name", dicCode = "gys_id")
|
||||||
|
@Dict(dictTable = "nu_invoicing_fkd_main", dicText = "gys_name", dicCode = "gys_id")
|
||||||
|
@ApiModelProperty(value = "供应商")
|
||||||
|
private java.lang.String gysId;
|
||||||
|
/**供应商名称*/
|
||||||
|
@Excel(name = "供应商名称", width = 15)
|
||||||
|
@ApiModelProperty(value = "供应商名称")
|
||||||
|
private java.lang.String gysName;
|
||||||
|
/**供应商开户行*/
|
||||||
|
@Excel(name = "供应商开户行", width = 15)
|
||||||
|
@ApiModelProperty(value = "供应商开户行")
|
||||||
|
private java.lang.String openingBank;
|
||||||
|
/**供应商开户行账号*/
|
||||||
|
@Excel(name = "供应商开户行账号", width = 15)
|
||||||
|
@ApiModelProperty(value = "供应商开户行账号")
|
||||||
|
private java.lang.String openingBankNo;
|
||||||
|
/**总金额*/
|
||||||
|
@Excel(name = "总金额", width = 15)
|
||||||
|
@ApiModelProperty(value = "总金额")
|
||||||
|
private java.math.BigDecimal totalPrice;
|
||||||
|
/**付款状态*/
|
||||||
|
@Excel(name = "付款状态", width = 15, dicCode = "invoicing_payment_status")
|
||||||
|
@Dict(dicCode = "invoicing_payment_status")
|
||||||
|
@ApiModelProperty(value = "付款状态")
|
||||||
|
private java.lang.String status;
|
||||||
|
/**付款时间*/
|
||||||
|
@Excel(name = "付款时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
|
||||||
|
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
|
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||||
|
@ApiModelProperty(value = "付款时间")
|
||||||
|
private java.util.Date fksj;
|
||||||
|
/**付款凭证(多张)*/
|
||||||
|
@Excel(name = "付款凭证(多张)", width = 15)
|
||||||
|
@ApiModelProperty(value = "付款凭证(多张)")
|
||||||
|
private java.lang.String fkpz;
|
||||||
|
/**发票(多张)*/
|
||||||
|
@Excel(name = "发票(多张)", width = 15)
|
||||||
|
@ApiModelProperty(value = "发票(多张)")
|
||||||
|
private java.lang.String fp;
|
||||||
|
/**备注*/
|
||||||
|
@Excel(name = "备注", width = 15)
|
||||||
|
@ApiModelProperty(value = "备注")
|
||||||
|
private java.lang.String bz;
|
||||||
|
/**编号*/
|
||||||
|
private int fkdNoOrder;
|
||||||
|
|
||||||
|
@TableField(exist = false)
|
||||||
|
private String cgdIds;
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,17 @@
|
||||||
|
package com.nu.modules.fkd.mapper;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
import com.nu.modules.fkd.entity.NuInvoicingFkdInfo;
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 进销存-付款单详细信息
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2025-11-21
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
public interface NuInvoicingFkdInfoMapper extends BaseMapper<NuInvoicingFkdInfo> {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,17 @@
|
||||||
|
package com.nu.modules.fkd.mapper;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
import com.nu.modules.fkd.entity.NuInvoicingFkdMain;
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 进销存-付款单主信息
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2025-11-21
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
public interface NuInvoicingFkdMainMapper extends BaseMapper<NuInvoicingFkdMain> {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,5 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="com.nu.modules.fkd.mapper.NuInvoicingFkdInfoMapper">
|
||||||
|
|
||||||
|
</mapper>
|
||||||
|
|
@ -0,0 +1,5 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="com.nu.modules.fkd.mapper.NuInvoicingFkdMainMapper">
|
||||||
|
|
||||||
|
</mapper>
|
||||||
|
|
@ -0,0 +1,14 @@
|
||||||
|
package com.nu.modules.fkd.service;
|
||||||
|
|
||||||
|
import com.nu.modules.fkd.entity.NuInvoicingFkdInfo;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 进销存-付款单详细信息
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2025-11-21
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
public interface INuInvoicingFkdInfoService extends IService<NuInvoicingFkdInfo> {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,14 @@
|
||||||
|
package com.nu.modules.fkd.service;
|
||||||
|
|
||||||
|
import com.nu.modules.fkd.entity.NuInvoicingFkdMain;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 进销存-付款单主信息
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2025-11-21
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
public interface INuInvoicingFkdMainService extends IService<NuInvoicingFkdMain> {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,19 @@
|
||||||
|
package com.nu.modules.fkd.service.impl;
|
||||||
|
|
||||||
|
import com.nu.modules.fkd.entity.NuInvoicingFkdInfo;
|
||||||
|
import com.nu.modules.fkd.mapper.NuInvoicingFkdInfoMapper;
|
||||||
|
import com.nu.modules.fkd.service.INuInvoicingFkdInfoService;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 进销存-付款单详细信息
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2025-11-21
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class NuInvoicingFkdInfoServiceImpl extends ServiceImpl<NuInvoicingFkdInfoMapper, NuInvoicingFkdInfo> implements INuInvoicingFkdInfoService {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,21 @@
|
||||||
|
package com.nu.modules.fkd.service.impl;
|
||||||
|
|
||||||
|
import com.nu.modules.cgd.service.INuInvoicingCgdInfoService;
|
||||||
|
import com.nu.modules.fkd.entity.NuInvoicingFkdMain;
|
||||||
|
import com.nu.modules.fkd.mapper.NuInvoicingFkdMainMapper;
|
||||||
|
import com.nu.modules.fkd.service.INuInvoicingFkdMainService;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 进销存-付款单主信息
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2025-11-21
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class NuInvoicingFkdMainServiceImpl extends ServiceImpl<NuInvoicingFkdMainMapper, NuInvoicingFkdMain> implements INuInvoicingFkdMainService {
|
||||||
|
|
||||||
|
}
|
||||||
Loading…
Reference in New Issue