diff --git a/ruoyi-admin/src/main/java/com/ruoyi/system/controller/BaseEmpRequisiteOrderController.java b/ruoyi-admin/src/main/java/com/ruoyi/system/controller/BaseEmpRequisiteOrderController.java index 85a087c5..0a9cffcc 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/system/controller/BaseEmpRequisiteOrderController.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/system/controller/BaseEmpRequisiteOrderController.java @@ -147,5 +147,9 @@ public class BaseEmpRequisiteOrderController extends BaseController return toAjax(baseEmpRequisiteOrderService.restoreBaseEmpRequisiteOrderById(id)); } - + @RequestMapping("/getId") + @ResponseBody + public AjaxResult getId(String requisiteId){ + return AjaxResult.success(baseEmpRequisiteOrderService.getId()); + } } diff --git a/ruoyi-admin/src/main/java/com/ruoyi/system/controller/BaseExpenseAccountChildController.java b/ruoyi-admin/src/main/java/com/ruoyi/system/controller/BaseExpenseAccountChildController.java new file mode 100644 index 00000000..0b4cd7fe --- /dev/null +++ b/ruoyi-admin/src/main/java/com/ruoyi/system/controller/BaseExpenseAccountChildController.java @@ -0,0 +1,151 @@ +package com.ruoyi.system.controller; + +import java.util.List; +import org.apache.shiro.authz.annotation.RequiresPermissions; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Controller; +import org.springframework.ui.ModelMap; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.ResponseBody; +import com.ruoyi.common.annotation.Log; +import com.ruoyi.common.enums.BusinessType; +import com.ruoyi.system.domain.BaseExpenseAccountChild; +import com.ruoyi.system.service.IBaseExpenseAccountChildService; +import com.ruoyi.common.core.controller.BaseController; +import com.ruoyi.common.core.domain.AjaxResult; +import com.ruoyi.common.utils.poi.ExcelUtil; +import com.ruoyi.common.core.page.TableDataInfo; + +/** + * 报销单分类子Controller + * + * @author zhang + * @date 2024-05-20 + */ +@Controller +@RequestMapping("/system/expenseChild") +public class BaseExpenseAccountChildController extends BaseController +{ + private String prefix = "system/baseExpenseChild"; + + @Autowired + private IBaseExpenseAccountChildService baseExpenseAccountChildService; + +// @RequiresPermissions("system:expenseChild:view") + @GetMapping() + public String expenseChild() + { + return prefix + "/baseExpenseChild"; + } + + /** + * 查询报销单分类子列表 + */ +// @RequiresPermissions("system:expenseChild:list") + @PostMapping("/list") + @ResponseBody + public TableDataInfo list(BaseExpenseAccountChild baseExpenseAccountChild) + { + startPage(); + List list = baseExpenseAccountChildService.selectBaseExpenseAccountChildList(baseExpenseAccountChild); + return getDataTable(list); + } + + /** + * 导出报销单分类子列表 + */ +// @RequiresPermissions("system:expenseChild:export") + @Log(title = "报销单分类子", businessType = BusinessType.EXPORT) + @PostMapping("/export") + @ResponseBody + public AjaxResult export(BaseExpenseAccountChild baseExpenseAccountChild) + { + List list = baseExpenseAccountChildService.selectBaseExpenseAccountChildList(baseExpenseAccountChild); + ExcelUtil util = new ExcelUtil(BaseExpenseAccountChild.class); + return util.exportExcel(list, "报销单分类子数据"); + } + + /** + * 新增报销单分类子 + */ + @GetMapping("/add") + public String add() + { + return prefix + "/add"; + } + + /** + * 新增保存报销单分类子 + */ +// @RequiresPermissions("system:expenseChild:add") + @Log(title = "报销单分类子", businessType = BusinessType.INSERT) + @PostMapping("/add") + @ResponseBody + public AjaxResult addSave(BaseExpenseAccountChild baseExpenseAccountChild) + { + return toAjax(baseExpenseAccountChildService.insertBaseExpenseAccountChild(baseExpenseAccountChild)); + } + + /** + * 修改报销单分类子 + */ + @GetMapping("/edit/{expenseChildId}") + public String edit(@PathVariable("expenseChildId") Long expenseChildId, ModelMap mmap) + { + BaseExpenseAccountChild baseExpenseAccountChild = baseExpenseAccountChildService.selectBaseExpenseAccountChildById(expenseChildId); + mmap.put("baseExpenseAccountChild", baseExpenseAccountChild); + return prefix + "/edit"; + } + + /** + * 修改保存报销单分类子 + */ +// @RequiresPermissions("system:expenseChild:edit") + @Log(title = "报销单分类子", businessType = BusinessType.UPDATE) + @PostMapping("/edit") + @ResponseBody + public AjaxResult editSave(BaseExpenseAccountChild baseExpenseAccountChild) + { + return toAjax(baseExpenseAccountChildService.updateBaseExpenseAccountChild(baseExpenseAccountChild)); + } + + /** + * 删除报销单分类子 + */ +// @RequiresPermissions("system:expenseChild:remove") + @Log(title = "报销单分类子", businessType = BusinessType.DELETE) + @PostMapping( "/remove") + @ResponseBody + public AjaxResult remove(String ids) + { + return toAjax(baseExpenseAccountChildService.deleteBaseExpenseAccountChildByIds(ids)); + } + + /** + * 作废报销单分类子 + */ +// @RequiresPermissions("system:expenseChild:cancel") + @Log(title = "报销单分类子", businessType = BusinessType.CANCEL) + @GetMapping( "/cancel/{id}") + @ResponseBody + public AjaxResult cancel(@PathVariable("id") Long id){ + return toAjax(baseExpenseAccountChildService.cancelBaseExpenseAccountChildById(id)); + } + + /** + * 恢复报销单分类子 + */ +// @RequiresPermissions("system:expenseChild:restore") + @Log(title = "报销单分类子", businessType = BusinessType.RESTORE) + @GetMapping( "/restore/{id}") + @ResponseBody + public AjaxResult restore(@PathVariable("id")Long id) + { + return toAjax(baseExpenseAccountChildService.restoreBaseExpenseAccountChildById(id)); + } + + +} diff --git a/ruoyi-admin/src/main/java/com/ruoyi/system/controller/BaseExpenseAccountController.java b/ruoyi-admin/src/main/java/com/ruoyi/system/controller/BaseExpenseAccountController.java new file mode 100644 index 00000000..2c0fae8e --- /dev/null +++ b/ruoyi-admin/src/main/java/com/ruoyi/system/controller/BaseExpenseAccountController.java @@ -0,0 +1,155 @@ +package com.ruoyi.system.controller; + +import java.util.List; +import org.apache.shiro.authz.annotation.RequiresPermissions; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Controller; +import org.springframework.ui.ModelMap; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.ResponseBody; +import com.ruoyi.common.annotation.Log; +import com.ruoyi.common.enums.BusinessType; +import com.ruoyi.system.domain.BaseExpenseAccount; +import com.ruoyi.system.service.IBaseExpenseAccountService; +import com.ruoyi.common.core.controller.BaseController; +import com.ruoyi.common.core.domain.AjaxResult; +import com.ruoyi.common.utils.poi.ExcelUtil; +import com.ruoyi.common.core.page.TableDataInfo; + +/** + * 报销单Controller + * + * @author zhang + * @date 2024-05-20 + */ +@Controller +@RequestMapping("/system/baseExpense") +public class BaseExpenseAccountController extends BaseController +{ + private String prefix = "system/baseExpense"; + + @Autowired + private IBaseExpenseAccountService baseExpenseAccountService; + + @RequiresPermissions("system:baseExpense:view") + @GetMapping() + public String baseExpense() + { + return prefix + "/baseExpense"; + } + + /** + * 查询报销单列表 + */ + @RequiresPermissions("system:baseExpense:list") + @PostMapping("/list") + @ResponseBody + public TableDataInfo list(BaseExpenseAccount baseExpenseAccount) + { + startPage(); + List list = baseExpenseAccountService.selectBaseExpenseAccountList(baseExpenseAccount); + return getDataTable(list); + } + + /** + * 导出报销单列表 + */ + @RequiresPermissions("system:baseExpense:export") + @Log(title = "报销单", businessType = BusinessType.EXPORT) + @PostMapping("/export") + @ResponseBody + public AjaxResult export(BaseExpenseAccount baseExpenseAccount) + { + List list = baseExpenseAccountService.selectBaseExpenseAccountList(baseExpenseAccount); + ExcelUtil util = new ExcelUtil(BaseExpenseAccount.class); + return util.exportExcel(list, "报销单数据"); + } + + /** + * 新增报销单 + */ + @GetMapping("/add") + public String add() + { + return prefix + "/add"; + } + + /** + * 新增保存报销单 + */ + @RequiresPermissions("system:baseExpense:add") + @Log(title = "报销单", businessType = BusinessType.INSERT) + @PostMapping("/add") + @ResponseBody + public AjaxResult addSave(BaseExpenseAccount baseExpenseAccount) + { + return toAjax(baseExpenseAccountService.insertBaseExpenseAccount(baseExpenseAccount)); + } + + /** + * 修改报销单 + */ + @GetMapping("/edit/{expenseId}") + public String edit(@PathVariable("expenseId") Long expenseId, ModelMap mmap) + { + BaseExpenseAccount baseExpenseAccount = baseExpenseAccountService.selectBaseExpenseAccountById(expenseId); + mmap.put("baseExpenseAccount", baseExpenseAccount); + return prefix + "/edit"; + } + + /** + * 修改保存报销单 + */ + @RequiresPermissions("system:baseExpense:edit") + @Log(title = "报销单", businessType = BusinessType.UPDATE) + @PostMapping("/edit") + @ResponseBody + public AjaxResult editSave(BaseExpenseAccount baseExpenseAccount) + { + return toAjax(baseExpenseAccountService.updateBaseExpenseAccount(baseExpenseAccount)); + } + + /** + * 删除报销单 + */ + @RequiresPermissions("system:baseExpense:remove") + @Log(title = "报销单", businessType = BusinessType.DELETE) + @PostMapping( "/remove") + @ResponseBody + public AjaxResult remove(String ids) + { + return toAjax(baseExpenseAccountService.deleteBaseExpenseAccountByIds(ids)); + } + + /** + * 作废报销单 + */ + @RequiresPermissions("system:baseExpense:cancel") + @Log(title = "报销单", businessType = BusinessType.CANCEL) + @GetMapping( "/cancel/{id}") + @ResponseBody + public AjaxResult cancel(@PathVariable("id") Long id){ + return toAjax(baseExpenseAccountService.cancelBaseExpenseAccountById(id)); + } + + /** + * 恢复报销单 + */ + @RequiresPermissions("system:baseExpense:restore") + @Log(title = "报销单", businessType = BusinessType.RESTORE) + @GetMapping( "/restore/{id}") + @ResponseBody + public AjaxResult restore(@PathVariable("id")Long id) + { + return toAjax(baseExpenseAccountService.restoreBaseExpenseAccountById(id)); + } + + @RequestMapping("/getId") + @ResponseBody + public AjaxResult getId(){ + return AjaxResult.success(baseExpenseAccountService.getId()); + } +} diff --git a/ruoyi-admin/src/main/java/com/ruoyi/system/domain/BaseExpenseAccount.java b/ruoyi-admin/src/main/java/com/ruoyi/system/domain/BaseExpenseAccount.java new file mode 100644 index 00000000..93987c47 --- /dev/null +++ b/ruoyi-admin/src/main/java/com/ruoyi/system/domain/BaseExpenseAccount.java @@ -0,0 +1,262 @@ +package com.ruoyi.system.domain; + +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; +import com.ruoyi.common.annotation.Excel; +import com.ruoyi.common.core.domain.BaseEntity; + +/** + * 报销单对象 base_emp_expense_account + * + * @author zhang + * @date 2024-05-20 + */ +public class BaseExpenseAccount extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** 报销单索引id */ + private Long expenseId; + + /** 上级审核状态 */ + @Excel(name = "上级审核状态") + private String auditStatus; + + /** 总经理审核状态 */ + @Excel(name = "总经理审核状态") + private String managerAuditStatus; + + /** 财务审核状态 */ + @Excel(name = "财务审核状态") + private String financeAuditStatus; + + /** 报销单编号 */ + @Excel(name = "报销单编号") + private String expenseCode; + + /** 部门 */ + @Excel(name = "部门") + private String deptName; + + /** 岗位 */ + @Excel(name = "岗位") + private String postName; + + /** 姓名 */ + @Excel(name = "姓名") + private String fullName; + + /** 报销方式 */ + @Excel(name = "报销方式") + private String expenseMethod; + + /** 是否是委外/采购采销 */ + @Excel(name = "是否是委外/采购采销") + private String isPurchaseOutsource; + + /** 供应商ID */ + @Excel(name = "供应商ID") + private String supplierCode; + + /** 对公收款方 */ + @Excel(name = "对公收款方") + private String corporatePayee; + + /** 对公收款账户 */ + @Excel(name = "对公收款账户") + private String corporateReceivingAccount; + + /** 对公开户行 */ + @Excel(name = "对公开户行") + private String publicAccountBanks; + + /** 申请人 */ + @Excel(name = "申请人") + private String applyUser; + + /** 使用状态 */ + @Excel(name = "使用状态") + private String useStatus; + + private String del_flag; + + public String getDel_flag() { + return del_flag; + } + + public void setDel_flag(String del_flag) { + this.del_flag = del_flag; + } + + public void setExpenseId(Long expenseId) + { + this.expenseId = expenseId; + } + + public Long getExpenseId() + { + return expenseId; + } + public void setAuditStatus(String auditStatus) + { + this.auditStatus = auditStatus; + } + + public String getAuditStatus() + { + return auditStatus; + } + public void setManagerAuditStatus(String managerAuditStatus) + { + this.managerAuditStatus = managerAuditStatus; + } + + public String getManagerAuditStatus() + { + return managerAuditStatus; + } + public void setFinanceAuditStatus(String financeAuditStatus) + { + this.financeAuditStatus = financeAuditStatus; + } + + public String getFinanceAuditStatus() + { + return financeAuditStatus; + } + public void setExpenseCode(String expenseCode) + { + this.expenseCode = expenseCode; + } + + public String getExpenseCode() + { + return expenseCode; + } + public void setDeptName(String deptName) + { + this.deptName = deptName; + } + + public String getDeptName() + { + return deptName; + } + public void setPostName(String postName) + { + this.postName = postName; + } + + public String getPostName() + { + return postName; + } + public void setFullName(String fullName) + { + this.fullName = fullName; + } + + public String getFullName() + { + return fullName; + } + public void setExpenseMethod(String expenseMethod) + { + this.expenseMethod = expenseMethod; + } + + public String getExpenseMethod() + { + return expenseMethod; + } + public void setIsPurchaseOutsource(String isPurchaseOutsource) + { + this.isPurchaseOutsource = isPurchaseOutsource; + } + + public String getIsPurchaseOutsource() + { + return isPurchaseOutsource; + } + public void setSupplierCode(String supplierCode) + { + this.supplierCode = supplierCode; + } + + public String getSupplierCode() + { + return supplierCode; + } + public void setCorporatePayee(String corporatePayee) + { + this.corporatePayee = corporatePayee; + } + + public String getCorporatePayee() + { + return corporatePayee; + } + public void setCorporateReceivingAccount(String corporateReceivingAccount) + { + this.corporateReceivingAccount = corporateReceivingAccount; + } + + public String getCorporateReceivingAccount() + { + return corporateReceivingAccount; + } + public void setPublicAccountBanks(String publicAccountBanks) + { + this.publicAccountBanks = publicAccountBanks; + } + + public String getPublicAccountBanks() + { + return publicAccountBanks; + } + public void setApplyUser(String applyUser) + { + this.applyUser = applyUser; + } + + public String getApplyUser() + { + return applyUser; + } + public void setUseStatus(String useStatus) + { + this.useStatus = useStatus; + } + + public String getUseStatus() + { + return useStatus; + } + + @Override + public String toString() { + return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) + .append("expenseId", getExpenseId()) + .append("auditStatus", getAuditStatus()) + .append("managerAuditStatus", getManagerAuditStatus()) + .append("financeAuditStatus", getFinanceAuditStatus()) + .append("expenseCode", getExpenseCode()) + .append("deptName", getDeptName()) + .append("postName", getPostName()) + .append("fullName", getFullName()) + .append("expenseMethod", getExpenseMethod()) + .append("isPurchaseOutsource", getIsPurchaseOutsource()) + .append("supplierCode", getSupplierCode()) + .append("corporatePayee", getCorporatePayee()) + .append("corporateReceivingAccount", getCorporateReceivingAccount()) + .append("publicAccountBanks", getPublicAccountBanks()) + .append("applyUser", getApplyUser()) + .append("createBy", getCreateBy()) + .append("createTime", getCreateTime()) + .append("updateBy", getUpdateBy()) + .append("updateTime", getUpdateTime()) + .append("remark", getRemark()) + .append("useStatus", getUseStatus()) + .toString(); + } +} diff --git a/ruoyi-admin/src/main/java/com/ruoyi/system/domain/BaseExpenseAccountChild.java b/ruoyi-admin/src/main/java/com/ruoyi/system/domain/BaseExpenseAccountChild.java new file mode 100644 index 00000000..e9562476 --- /dev/null +++ b/ruoyi-admin/src/main/java/com/ruoyi/system/domain/BaseExpenseAccountChild.java @@ -0,0 +1,184 @@ +package com.ruoyi.system.domain; + +import java.util.Date; +import com.fasterxml.jackson.annotation.JsonFormat; +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; +import com.ruoyi.common.annotation.Excel; +import com.ruoyi.common.core.domain.BaseEntity; + +/** + * 报销单分类子对象 base_expense_account_child + * + * @author zhang + * @date 2024-05-20 + */ +public class BaseExpenseAccountChild extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** 报销单分项子表 */ + private Long expenseChildId; + + /** 关联报销单号 */ + @Excel(name = "关联报销单号") + private String quoteId; + + /** 成本类型 */ + @Excel(name = "成本类型") + private String costType; + + /** 成本小类 */ + @Excel(name = "成本小类") + private String costSmallType; + + /** 用途 */ + @Excel(name = "用途") + private String purpose; + + /** 金额 */ + @Excel(name = "金额") + private String amounts; + + /** 报销时间 */ + @JsonFormat(pattern = "yyyy-MM-dd") + @Excel(name = "报销时间", width = 30, dateFormat = "yyyy-MM-dd") + private Date expenseTime; + + /** 出差单号 */ + @Excel(name = "出差单号") + private String evectionCode; + + /** 采购单号 */ + @Excel(name = "采购单号") + private String purcahseCode; + + /** 委外单号 */ + @Excel(name = "委外单号") + private String outsourceCode; + + /** 删除状态 */ + private String delFlag; + + public void setExpenseChildId(Long expenseChildId) + { + this.expenseChildId = expenseChildId; + } + + public Long getExpenseChildId() + { + return expenseChildId; + } + public void setQuoteId(String quoteId) + { + this.quoteId = quoteId; + } + + public String getQuoteId() + { + return quoteId; + } + public void setCostType(String costType) + { + this.costType = costType; + } + + public String getCostType() + { + return costType; + } + public void setCostSmallType(String costSmallType) + { + this.costSmallType = costSmallType; + } + + public String getCostSmallType() + { + return costSmallType; + } + public void setPurpose(String purpose) + { + this.purpose = purpose; + } + + public String getPurpose() + { + return purpose; + } + public void setAmounts(String amounts) + { + this.amounts = amounts; + } + + public String getAmounts() + { + return amounts; + } + public void setExpenseTime(Date expenseTime) + { + this.expenseTime = expenseTime; + } + + public Date getExpenseTime() + { + return expenseTime; + } + public void setEvectionCode(String evectionCode) + { + this.evectionCode = evectionCode; + } + + public String getEvectionCode() + { + return evectionCode; + } + public void setPurcahseCode(String purcahseCode) + { + this.purcahseCode = purcahseCode; + } + + public String getPurcahseCode() + { + return purcahseCode; + } + public void setOutsourceCode(String outsourceCode) + { + this.outsourceCode = outsourceCode; + } + + public String getOutsourceCode() + { + return outsourceCode; + } + public void setDelFlag(String delFlag) + { + this.delFlag = delFlag; + } + + public String getDelFlag() + { + return delFlag; + } + + @Override + public String toString() { + return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) + .append("expenseChildId", getExpenseChildId()) + .append("quoteId", getQuoteId()) + .append("cost type", getCostType()) + .append("costSmallType", getCostSmallType()) + .append("purpose", getPurpose()) + .append("amounts", getAmounts()) + .append("expenseTime", getExpenseTime()) + .append("evectionCode", getEvectionCode()) + .append("purcahseCode", getPurcahseCode()) + .append("outsourceCode", getOutsourceCode()) + .append("createTime", getCreateTime()) + .append("createBy", getCreateBy()) + .append("updateBy", getUpdateBy()) + .append("updateTime", getUpdateTime()) + .append("delFlag", getDelFlag()) + .append("remark", getRemark()) + .toString(); + } +} diff --git a/ruoyi-admin/src/main/java/com/ruoyi/system/mapper/BaseEmpRequisiteOrderChildMapper.java b/ruoyi-admin/src/main/java/com/ruoyi/system/mapper/BaseEmpRequisiteOrderChildMapper.java index 582fb052..c5fb7d76 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/system/mapper/BaseEmpRequisiteOrderChildMapper.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/system/mapper/BaseEmpRequisiteOrderChildMapper.java @@ -51,6 +51,10 @@ public interface BaseEmpRequisiteOrderChildMapper */ public int deleteBaseEmpRequisiteOrderChildById(Long requisitioningChildId); + + public int deleteBaseEmpRequisiteOrderChildByCode(String code); + + public int deleteBaseEmpRequisiteOrderChildByCodes(String[] codes); /** * 批量删除员工单领料单物料信息 * @@ -59,6 +63,7 @@ public interface BaseEmpRequisiteOrderChildMapper */ public int deleteBaseEmpRequisiteOrderChildByIds(String[] requisitioningChildIds); + /** * 作废员工单领料单物料信息 * diff --git a/ruoyi-admin/src/main/java/com/ruoyi/system/mapper/BaseExpenseAccountChildMapper.java b/ruoyi-admin/src/main/java/com/ruoyi/system/mapper/BaseExpenseAccountChildMapper.java new file mode 100644 index 00000000..3485345e --- /dev/null +++ b/ruoyi-admin/src/main/java/com/ruoyi/system/mapper/BaseExpenseAccountChildMapper.java @@ -0,0 +1,77 @@ +package com.ruoyi.system.mapper; + +import java.util.List; +import com.ruoyi.system.domain.BaseExpenseAccountChild; + +/** + * 报销单分类子Mapper接口 + * + * @author zhang + * @date 2024-05-20 + */ +public interface BaseExpenseAccountChildMapper +{ + /** + * 查询报销单分类子 + * + * @param expenseChildId 报销单分类子ID + * @return 报销单分类子 + */ + public BaseExpenseAccountChild selectBaseExpenseAccountChildById(Long expenseChildId); + + /** + * 查询报销单分类子列表 + * + * @param baseExpenseAccountChild 报销单分类子 + * @return 报销单分类子集合 + */ + public List selectBaseExpenseAccountChildList(BaseExpenseAccountChild baseExpenseAccountChild); + + /** + * 新增报销单分类子 + * + * @param baseExpenseAccountChild 报销单分类子 + * @return 结果 + */ + public int insertBaseExpenseAccountChild(BaseExpenseAccountChild baseExpenseAccountChild); + + /** + * 修改报销单分类子 + * + * @param baseExpenseAccountChild 报销单分类子 + * @return 结果 + */ + public int updateBaseExpenseAccountChild(BaseExpenseAccountChild baseExpenseAccountChild); + + /** + * 删除报销单分类子 + * + * @param expenseChildId 报销单分类子ID + * @return 结果 + */ + public int deleteBaseExpenseAccountChildById(Long expenseChildId); + + /** + * 批量删除报销单分类子 + * + * @param expenseChildIds 需要删除的数据ID + * @return 结果 + */ + public int deleteBaseExpenseAccountChildByIds(String[] expenseChildIds); + + /** + * 作废报销单分类子 + * + * @param expenseChildId 报销单分类子ID + * @return 结果 + */ + public int cancelBaseExpenseAccountChildById(Long expenseChildId); + + /** + * 恢复报销单分类子 + * + * @param expenseChildId 报销单分类子ID + * @return 结果 + */ + public int restoreBaseExpenseAccountChildById(Long expenseChildId); +} diff --git a/ruoyi-admin/src/main/java/com/ruoyi/system/mapper/BaseExpenseAccountMapper.java b/ruoyi-admin/src/main/java/com/ruoyi/system/mapper/BaseExpenseAccountMapper.java new file mode 100644 index 00000000..a8fdc2d2 --- /dev/null +++ b/ruoyi-admin/src/main/java/com/ruoyi/system/mapper/BaseExpenseAccountMapper.java @@ -0,0 +1,77 @@ +package com.ruoyi.system.mapper; + +import java.util.List; +import com.ruoyi.system.domain.BaseExpenseAccount; + +/** + * 报销单Mapper接口 + * + * @author zhang + * @date 2024-05-20 + */ +public interface BaseExpenseAccountMapper +{ + /** + * 查询报销单 + * + * @param expenseId 报销单ID + * @return 报销单 + */ + public BaseExpenseAccount selectBaseExpenseAccountById(Long expenseId); + + /** + * 查询报销单列表 + * + * @param baseExpenseAccount 报销单 + * @return 报销单集合 + */ + public List selectBaseExpenseAccountList(BaseExpenseAccount baseExpenseAccount); + + /** + * 新增报销单 + * + * @param baseExpenseAccount 报销单 + * @return 结果 + */ + public int insertBaseExpenseAccount(BaseExpenseAccount baseExpenseAccount); + + /** + * 修改报销单 + * + * @param baseExpenseAccount 报销单 + * @return 结果 + */ + public int updateBaseExpenseAccount(BaseExpenseAccount baseExpenseAccount); + + /** + * 删除报销单 + * + * @param expenseId 报销单ID + * @return 结果 + */ + public int deleteBaseExpenseAccountById(Long expenseId); + + /** + * 批量删除报销单 + * + * @param expenseIds 需要删除的数据ID + * @return 结果 + */ + public int deleteBaseExpenseAccountByIds(String[] expenseIds); + + /** + * 作废报销单 + * + * @param expenseId 报销单ID + * @return 结果 + */ + public int cancelBaseExpenseAccountById(Long expenseId); + + /** + * 恢复报销单 + * + * @param expenseId 报销单ID + * @return 结果 + */ + public int restoreBaseExpenseAccountById(Long expenseId); +} diff --git a/ruoyi-admin/src/main/java/com/ruoyi/system/service/IBaseExpenseAccountChildService.java b/ruoyi-admin/src/main/java/com/ruoyi/system/service/IBaseExpenseAccountChildService.java new file mode 100644 index 00000000..c015d483 --- /dev/null +++ b/ruoyi-admin/src/main/java/com/ruoyi/system/service/IBaseExpenseAccountChildService.java @@ -0,0 +1,75 @@ +package com.ruoyi.system.service; + +import java.util.List; +import com.ruoyi.system.domain.BaseExpenseAccountChild; + +/** + * 报销单分类子Service接口 + * + * @author zhang + * @date 2024-05-20 + */ +public interface IBaseExpenseAccountChildService +{ + /** + * 查询报销单分类子 + * + * @param expenseChildId 报销单分类子ID + * @return 报销单分类子 + */ + public BaseExpenseAccountChild selectBaseExpenseAccountChildById(Long expenseChildId); + + /** + * 查询报销单分类子列表 + * + * @param baseExpenseAccountChild 报销单分类子 + * @return 报销单分类子集合 + */ + public List selectBaseExpenseAccountChildList(BaseExpenseAccountChild baseExpenseAccountChild); + + /** + * 新增报销单分类子 + * + * @param baseExpenseAccountChild 报销单分类子 + * @return 结果 + */ + public int insertBaseExpenseAccountChild(BaseExpenseAccountChild baseExpenseAccountChild); + + /** + * 修改报销单分类子 + * + * @param baseExpenseAccountChild 报销单分类子 + * @return 结果 + */ + public int updateBaseExpenseAccountChild(BaseExpenseAccountChild baseExpenseAccountChild); + + /** + * 批量删除报销单分类子 + * + * @param ids 需要删除的数据ID + * @return 结果 + */ + public int deleteBaseExpenseAccountChildByIds(String ids); + + /** + * 删除报销单分类子信息 + * + * @param expenseChildId 报销单分类子ID + * @return 结果 + */ + public int deleteBaseExpenseAccountChildById(Long expenseChildId); + + /** + * 作废报销单分类子 + * @param expenseChildId 报销单分类子ID + * @return + */ + int cancelBaseExpenseAccountChildById(Long expenseChildId); + + /** + * 恢复报销单分类子 + * @param expenseChildId 报销单分类子ID + * @return + */ + int restoreBaseExpenseAccountChildById(Long expenseChildId); +} diff --git a/ruoyi-admin/src/main/java/com/ruoyi/system/service/IBaseExpenseAccountService.java b/ruoyi-admin/src/main/java/com/ruoyi/system/service/IBaseExpenseAccountService.java new file mode 100644 index 00000000..22c779d6 --- /dev/null +++ b/ruoyi-admin/src/main/java/com/ruoyi/system/service/IBaseExpenseAccountService.java @@ -0,0 +1,78 @@ +package com.ruoyi.system.service; + +import java.util.List; +import com.ruoyi.system.domain.BaseExpenseAccount; + +/** + * 报销单Service接口 + * + * @author zhang + * @date 2024-05-20 + */ +public interface IBaseExpenseAccountService +{ + /** + * 查询报销单 + * + * @param expenseId 报销单ID + * @return 报销单 + */ + public BaseExpenseAccount selectBaseExpenseAccountById(Long expenseId); + + /** + * 查询报销单列表 + * + * @param baseExpenseAccount 报销单 + * @return 报销单集合 + */ + public List selectBaseExpenseAccountList(BaseExpenseAccount baseExpenseAccount); + + /** + * 新增报销单 + * + * @param baseExpenseAccount 报销单 + * @return 结果 + */ + public int insertBaseExpenseAccount(BaseExpenseAccount baseExpenseAccount); + + /** + * 修改报销单 + * + * @param baseExpenseAccount 报销单 + * @return 结果 + */ + public int updateBaseExpenseAccount(BaseExpenseAccount baseExpenseAccount); + + /** + * 批量删除报销单 + * + * @param ids 需要删除的数据ID + * @return 结果 + */ + public int deleteBaseExpenseAccountByIds(String ids); + + /** + * 删除报销单信息 + * + * @param expenseId 报销单ID + * @return 结果 + */ + public int deleteBaseExpenseAccountById(Long expenseId); + + /** + * 作废报销单 + * @param expenseId 报销单ID + * @return + */ + int cancelBaseExpenseAccountById(Long expenseId); + + /** + * 恢复报销单 + * @param expenseId 报销单ID + * @return + */ + int restoreBaseExpenseAccountById(Long expenseId); + + + public Object getId(); +} diff --git a/ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/BaseEmpRequisiteOrderServiceImpl.java b/ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/BaseEmpRequisiteOrderServiceImpl.java index 613286a0..0438a4d9 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/BaseEmpRequisiteOrderServiceImpl.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/BaseEmpRequisiteOrderServiceImpl.java @@ -1,14 +1,23 @@ package com.ruoyi.system.service.impl; +import java.math.BigDecimal; +import java.math.RoundingMode; import java.util.List; + +import com.ruoyi.common.core.redis.RedisCache; import com.ruoyi.common.utils.DateUtils; import com.ruoyi.common.utils.ShiroUtils; +import com.ruoyi.system.domain.BaseEmpRequisiteOrderChild; +import com.ruoyi.system.domain.BaseRequisitioningOrderChild; +import com.ruoyi.system.mapper.BaseEmpRequisiteOrderChildMapper; +import com.ruoyi.system.service.ISysUserService; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import com.ruoyi.system.mapper.BaseEmpRequisiteOrderMapper; import com.ruoyi.system.domain.BaseEmpRequisiteOrder; import com.ruoyi.system.service.IBaseEmpRequisiteOrderService; import com.ruoyi.common.core.text.Convert; +import org.springframework.transaction.annotation.Transactional; /** * 员工领料单Service业务层处理 @@ -21,6 +30,14 @@ public class BaseEmpRequisiteOrderServiceImpl implements IBaseEmpRequisiteOrderS { @Autowired private BaseEmpRequisiteOrderMapper baseEmpRequisiteOrderMapper; + @Autowired + private BaseEmpRequisiteOrderChildMapper baseEmpRequisiteOrderChildMapper; + + @Autowired + private RedisCache redisCache; + + @Autowired + private ISysUserService userService; /** * 查询员工领料单 @@ -53,11 +70,41 @@ public class BaseEmpRequisiteOrderServiceImpl implements IBaseEmpRequisiteOrderS * @return 结果 */ @Override + @Transactional(rollbackFor = NullPointerException.class) public int insertBaseEmpRequisiteOrder(BaseEmpRequisiteOrder baseEmpRequisiteOrder) { String loginName = ShiroUtils.getLoginName(); baseEmpRequisiteOrder.setCreateBy(loginName); baseEmpRequisiteOrder.setCreateTime(DateUtils.getNowDate()); + if (baseEmpRequisiteOrder.getRequisitieCode() == null) { + baseEmpRequisiteOrder.setRequisitieCode(redisCache.generateBillNo("QG")); + } + List childList = baseEmpRequisiteOrder.getBaseEmpRequisiteOrderChildList(); + Long materialSum = 0L; + BigDecimal materialRmbSum = new BigDecimal(0); + BigDecimal materialNoRmbSum = new BigDecimal(0); + //物料合计 + Integer childSize = childList.size(); + if (childSize > 0) { + for (BaseEmpRequisiteOrderChild child : childList) { + //物料数量 + materialSum += child.getMaterialNum(); + //物料不含税总价(RMB) + materialRmbSum = child.getMaterialRmbSum().setScale(2, RoundingMode.HALF_UP).add(materialNoRmbSum); + //物料含税总价(RMB) + materialNoRmbSum = child.getMaterialNoRmbSum().setScale(2, RoundingMode.HALF_UP).add(materialNoRmbSum); + child.setQuoteId(baseEmpRequisiteOrder.getRequisitieCode()); + child.setCreateBy(loginName); + child.setCreateTime(DateUtils.getNowDate()); + baseEmpRequisiteOrderChildMapper.insertBaseEmpRequisiteOrderChild(child); + } + } + baseEmpRequisiteOrder.setAuditStatus("1"); + baseEmpRequisiteOrder.setUseStatus("1"); + baseEmpRequisiteOrder.setMaterialAmount(Long.valueOf(childSize)); + baseEmpRequisiteOrder.setMaterialSum(materialSum); + baseEmpRequisiteOrder.setRmbSum(materialRmbSum); + baseEmpRequisiteOrder.setNoRmbSum(materialNoRmbSum); return baseEmpRequisiteOrderMapper.insertBaseEmpRequisiteOrder(baseEmpRequisiteOrder); } @@ -68,11 +115,42 @@ public class BaseEmpRequisiteOrderServiceImpl implements IBaseEmpRequisiteOrderS * @return 结果 */ @Override + @Transactional(rollbackFor = NullPointerException.class) public int updateBaseEmpRequisiteOrder(BaseEmpRequisiteOrder baseEmpRequisiteOrder) { String loginName = ShiroUtils.getLoginName(); baseEmpRequisiteOrder.setUpdateBy(loginName); baseEmpRequisiteOrder.setUpdateTime(DateUtils.getNowDate()); + baseEmpRequisiteOrderChildMapper.deleteBaseEmpRequisiteOrderChildByCode(baseEmpRequisiteOrder.getRequisitieCode()); + if (baseEmpRequisiteOrder.getRequisitieCode() == null) { + baseEmpRequisiteOrder.setRequisitieCode(redisCache.generateBillNo("QG")); + } + List childList = baseEmpRequisiteOrder.getBaseEmpRequisiteOrderChildList(); + Long materialSum = 0L; + BigDecimal materialRmbSum = new BigDecimal(0); + BigDecimal materialNoRmbSum = new BigDecimal(0); + //物料合计 + Integer childSize = childList.size(); + if (childSize > 0) { + for (BaseEmpRequisiteOrderChild child : childList) { + //物料数量 + materialSum += child.getMaterialNum(); + //物料不含税总价(RMB) + materialRmbSum = child.getMaterialRmbSum().setScale(2, RoundingMode.HALF_UP).add(materialNoRmbSum); + //物料含税总价(RMB) + materialNoRmbSum = child.getMaterialNoRmbSum().setScale(2, RoundingMode.HALF_UP).add(materialNoRmbSum); + child.setQuoteId(baseEmpRequisiteOrder.getRequisitieCode()); + child.setCreateBy(loginName); + child.setCreateTime(DateUtils.getNowDate()); + baseEmpRequisiteOrderChildMapper.insertBaseEmpRequisiteOrderChild(child); + } + } + baseEmpRequisiteOrder.setAuditStatus("1"); + baseEmpRequisiteOrder.setUseStatus("1"); + baseEmpRequisiteOrder.setMaterialAmount(Long.valueOf(childSize)); + baseEmpRequisiteOrder.setMaterialSum(materialSum); + baseEmpRequisiteOrder.setRmbSum(materialRmbSum); + baseEmpRequisiteOrder.setNoRmbSum(materialNoRmbSum); return baseEmpRequisiteOrderMapper.updateBaseEmpRequisiteOrder(baseEmpRequisiteOrder); } @@ -123,4 +201,10 @@ public class BaseEmpRequisiteOrderServiceImpl implements IBaseEmpRequisiteOrderS { return baseEmpRequisiteOrderMapper.restoreBaseEmpRequisiteOrderById(requisiteId); } + + //todo 生成员工领料单编号 + @Override + public Object getId() { + return redisCache.generateBillNo("YGLL"); + } } diff --git a/ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/BaseExpenseAccountChildServiceImpl.java b/ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/BaseExpenseAccountChildServiceImpl.java new file mode 100644 index 00000000..5b9c9eef --- /dev/null +++ b/ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/BaseExpenseAccountChildServiceImpl.java @@ -0,0 +1,126 @@ +package com.ruoyi.system.service.impl; + +import java.util.List; +import com.ruoyi.common.utils.DateUtils; +import com.ruoyi.common.utils.ShiroUtils; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; +import com.ruoyi.system.mapper.BaseExpenseAccountChildMapper; +import com.ruoyi.system.domain.BaseExpenseAccountChild; +import com.ruoyi.system.service.IBaseExpenseAccountChildService; +import com.ruoyi.common.core.text.Convert; + +/** + * 报销单分类子Service业务层处理 + * + * @author zhang + * @date 2024-05-20 + */ +@Service +public class BaseExpenseAccountChildServiceImpl implements IBaseExpenseAccountChildService +{ + @Autowired + private BaseExpenseAccountChildMapper baseExpenseAccountChildMapper; + + /** + * 查询报销单分类子 + * + * @param expenseChildId 报销单分类子ID + * @return 报销单分类子 + */ + @Override + public BaseExpenseAccountChild selectBaseExpenseAccountChildById(Long expenseChildId) + { + return baseExpenseAccountChildMapper.selectBaseExpenseAccountChildById(expenseChildId); + } + + /** + * 查询报销单分类子列表 + * + * @param baseExpenseAccountChild 报销单分类子 + * @return 报销单分类子 + */ + @Override + public List selectBaseExpenseAccountChildList(BaseExpenseAccountChild baseExpenseAccountChild) + { + return baseExpenseAccountChildMapper.selectBaseExpenseAccountChildList(baseExpenseAccountChild); + } + + /** + * 新增报销单分类子 + * + * @param baseExpenseAccountChild 报销单分类子 + * @return 结果 + */ + @Override + public int insertBaseExpenseAccountChild(BaseExpenseAccountChild baseExpenseAccountChild) + { + baseExpenseAccountChild.setCreateTime(DateUtils.getNowDate()); + String loginName = ShiroUtils.getLoginName(); + baseExpenseAccountChild.setCreateBy(loginName); + return baseExpenseAccountChildMapper.insertBaseExpenseAccountChild(baseExpenseAccountChild); + } + + /** + * 修改报销单分类子 + * + * @param baseExpenseAccountChild 报销单分类子 + * @return 结果 + */ + @Override + public int updateBaseExpenseAccountChild(BaseExpenseAccountChild baseExpenseAccountChild) + { + String loginName = ShiroUtils.getLoginName(); + baseExpenseAccountChild.setUpdateBy(loginName); + baseExpenseAccountChild.setUpdateTime(DateUtils.getNowDate()); + return baseExpenseAccountChildMapper.updateBaseExpenseAccountChild(baseExpenseAccountChild); + } + + /** + * 删除报销单分类子对象 + * + * @param ids 需要删除的数据ID + * @return 结果 + */ + @Override + public int deleteBaseExpenseAccountChildByIds(String ids) + { + return baseExpenseAccountChildMapper.deleteBaseExpenseAccountChildByIds(Convert.toStrArray(ids)); + } + + /** + * 删除报销单分类子信息 + * + * @param expenseChildId 报销单分类子ID + * @return 结果 + */ + @Override + public int deleteBaseExpenseAccountChildById(Long expenseChildId) + { + return baseExpenseAccountChildMapper.deleteBaseExpenseAccountChildById(expenseChildId); + } + + /** + * 作废报销单分类子 + * + * @param expenseChildId 报销单分类子ID + * @return 结果 + */ + @Override + public int cancelBaseExpenseAccountChildById(Long expenseChildId) + { + return baseExpenseAccountChildMapper.cancelBaseExpenseAccountChildById(expenseChildId); + } + + /** + * 恢复报销单分类子信息 + * + * @param expenseChildId 报销单分类子ID + * @return 结果 + */ + @Override + public int restoreBaseExpenseAccountChildById(Long expenseChildId) + { + return baseExpenseAccountChildMapper.restoreBaseExpenseAccountChildById(expenseChildId); + } +} diff --git a/ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/BaseExpenseAccountServiceImpl.java b/ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/BaseExpenseAccountServiceImpl.java new file mode 100644 index 00000000..8ea6503f --- /dev/null +++ b/ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/BaseExpenseAccountServiceImpl.java @@ -0,0 +1,136 @@ +package com.ruoyi.system.service.impl; + +import java.util.List; + +import com.ruoyi.common.core.redis.RedisCache; +import com.ruoyi.common.utils.DateUtils; +import com.ruoyi.common.utils.ShiroUtils; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; +import com.ruoyi.system.mapper.BaseExpenseAccountMapper; +import com.ruoyi.system.domain.BaseExpenseAccount; +import com.ruoyi.system.service.IBaseExpenseAccountService; +import com.ruoyi.common.core.text.Convert; + +/** + * 报销单Service业务层处理 + * + * @author zhang + * @date 2024-05-20 + */ +@Service +public class BaseExpenseAccountServiceImpl implements IBaseExpenseAccountService +{ + @Autowired + private BaseExpenseAccountMapper baseExpenseAccountMapper; + + @Autowired + private RedisCache redisCache; + + /** + * 查询报销单 + * + * @param expenseId 报销单ID + * @return 报销单 + */ + @Override + public BaseExpenseAccount selectBaseExpenseAccountById(Long expenseId) + { + return baseExpenseAccountMapper.selectBaseExpenseAccountById(expenseId); + } + + /** + * 查询报销单列表 + * + * @param baseExpenseAccount 报销单 + * @return 报销单 + */ + @Override + public List selectBaseExpenseAccountList(BaseExpenseAccount baseExpenseAccount) + { + return baseExpenseAccountMapper.selectBaseExpenseAccountList(baseExpenseAccount); + } + + /** + * 新增报销单 + * + * @param baseExpenseAccount 报销单 + * @return 结果 + */ + @Override + public int insertBaseExpenseAccount(BaseExpenseAccount baseExpenseAccount) + { + String loginName = ShiroUtils.getLoginName(); + baseExpenseAccount.setCreateBy(loginName); + baseExpenseAccount.setCreateTime(DateUtils.getNowDate()); + return baseExpenseAccountMapper.insertBaseExpenseAccount(baseExpenseAccount); + } + + /** + * 修改报销单 + * + * @param baseExpenseAccount 报销单 + * @return 结果 + */ + @Override + public int updateBaseExpenseAccount(BaseExpenseAccount baseExpenseAccount) + { + String loginName = ShiroUtils.getLoginName(); + baseExpenseAccount.setUpdateBy(loginName); + baseExpenseAccount.setUpdateTime(DateUtils.getNowDate()); + return baseExpenseAccountMapper.updateBaseExpenseAccount(baseExpenseAccount); + } + + /** + * 删除报销单对象 + * + * @param ids 需要删除的数据ID + * @return 结果 + */ + @Override + public int deleteBaseExpenseAccountByIds(String ids) + { + return baseExpenseAccountMapper.deleteBaseExpenseAccountByIds(Convert.toStrArray(ids)); + } + + /** + * 删除报销单信息 + * + * @param expenseId 报销单ID + * @return 结果 + */ + @Override + public int deleteBaseExpenseAccountById(Long expenseId) + { + return baseExpenseAccountMapper.deleteBaseExpenseAccountById(expenseId); + } + + /** + * 作废报销单 + * + * @param expenseId 报销单ID + * @return 结果 + */ + @Override + public int cancelBaseExpenseAccountById(Long expenseId) + { + return baseExpenseAccountMapper.cancelBaseExpenseAccountById(expenseId); + } + + /** + * 恢复报销单信息 + * + * @param expenseId 报销单ID + * @return 结果 + */ + @Override + public int restoreBaseExpenseAccountById(Long expenseId) + { + return baseExpenseAccountMapper.restoreBaseExpenseAccountById(expenseId); + } + + @Override + public Object getId() { + return redisCache.generateBillNo("BX"); + } +} diff --git a/ruoyi-admin/src/main/resources/mapper/system/BaseEmpRequisiteOrderChildMapper.xml b/ruoyi-admin/src/main/resources/mapper/system/BaseEmpRequisiteOrderChildMapper.xml index 9dbc8af1..7c538aff 100644 --- a/ruoyi-admin/src/main/resources/mapper/system/BaseEmpRequisiteOrderChildMapper.xml +++ b/ruoyi-admin/src/main/resources/mapper/system/BaseEmpRequisiteOrderChildMapper.xml @@ -126,7 +126,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" material_model = #{materialModel}, specifications = #{specifications}, brand = #{brand}, - describe = #{describe}, + `describe` = #{describe}, materialNum = #{materialNum}, materialRmb = #{materialRmb}, materialNoRmb = #{materialNoRmb}, @@ -146,14 +146,21 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" delete from base_emp_requisite_order_child where requisitioning_child_id = #{requisitioningChildId} - + + delete from base_emp_requisite_order_child where quote_id = #{code} + delete from base_emp_requisite_order_child where requisitioning_child_id in #{requisitioningChildId} - + + delete from base_emp_requisite_order_child where requisitioning_child_id in + + #{code} + + update base_emp_requisite_order_child set del_flag = '1' where requisitioning_child_id = #{requisitioningChildId} diff --git a/ruoyi-admin/src/main/resources/mapper/system/BaseExpenseAccountChildMapper.xml b/ruoyi-admin/src/main/resources/mapper/system/BaseExpenseAccountChildMapper.xml new file mode 100644 index 00000000..fb098f40 --- /dev/null +++ b/ruoyi-admin/src/main/resources/mapper/system/BaseExpenseAccountChildMapper.xml @@ -0,0 +1,133 @@ + + + + + + + + + + + + + + + + + + + + + + + + + select expense_child_id, quote_id, cost_type, cost_small_type, + purpose, amounts, expense_time, evection_code, purcahse_code, + outsource_code, create_time, create_by, update_by, update_time, + del_flag, remark + from base_expense_account_child + + + + + + + + insert into base_expense_account_child + + quote_id, + cost_type, + cost_small_type, + purpose, + amounts, + expense_time, + evection_code, + purcahse_code, + outsource_code, + create_time, + create_by, + update_by, + update_time, + del_flag, + remark, + + + #{quoteId}, + #{costType}, + #{costSmallType}, + #{purpose}, + #{amounts}, + #{expenseTime}, + #{evectionCode}, + #{purcahseCode}, + #{outsourceCode}, + #{createTime}, + #{createBy}, + #{updateBy}, + #{updateTime}, + #{delFlag}, + #{remark}, + + + + + update base_expense_account_child + + quote_id = #{quoteId}, + cost_type = #{costType}, + cost_small_type = #{costSmallType}, + purpose = #{purpose}, + amounts = #{amounts}, + expense_time = #{expenseTime}, + evection_code = #{evectionCode}, + purcahse_code = #{purcahseCode}, + outsource_code = #{outsourceCode}, + create_time = #{createTime}, + create_by = #{createBy}, + update_by = #{updateBy}, + update_time = #{updateTime}, + del_flag = #{delFlag}, + remark = #{remark}, + + where expense_child_id = #{expenseChildId} + + + + delete from base_expense_account_child where expense_child_id = #{expenseChildId} + + + + delete from base_expense_account_child where expense_child_id in + + #{expenseChildId} + + + + + update base_expense_account_child set del_flag = '1' where expense_child_id = #{expenseChildId} + + + + update base_expense_account_child set del_flag = '0' where expense_child_id = #{expenseChildId} + + + \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/mapper/system/BaseExpenseAccountMapper.xml b/ruoyi-admin/src/main/resources/mapper/system/BaseExpenseAccountMapper.xml new file mode 100644 index 00000000..3ddc8565 --- /dev/null +++ b/ruoyi-admin/src/main/resources/mapper/system/BaseExpenseAccountMapper.xml @@ -0,0 +1,151 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + select expense_id, audit_status, manager_audit_status, finance_audit_status, + expense_code, deptName, postName, fullName, expense_method, is_purchase_outsource, + supplier_code, corporate_payee, corporate_receiving_account, public_account_banks, + apply_user, create_by, create_time, update_by, update_time, remark, use_status,del_flag + from base_expense_account + + + + + + + + insert into base_emp_expense_account + + audit_status, + manager_audit_status, + finance_audit_status, + expense_code, + deptName, + postName, + fullName, + expense_method, + is_purchase_outsource, + supplier_code, + corporate_payee, + corporate_receiving_account, + public_account_banks, + apply_user, + create_by, + create_time, + update_by, + update_time, + remark, + use_status, + + + #{auditStatus}, + #{managerAuditStatus}, + #{financeAuditStatus}, + #{expenseCode}, + #{deptName}, + #{postName}, + #{fullName}, + #{expenseMethod}, + #{isPurchaseOutsource}, + #{supplierCode}, + #{corporatePayee}, + #{corporateReceivingAccount}, + #{publicAccountBanks}, + #{applyUser}, + #{createBy}, + #{createTime}, + #{updateBy}, + #{updateTime}, + #{remark}, + #{useStatus}, + + + + + update base_emp_expense_account + + audit_status = #{auditStatus}, + manager_audit_status = #{managerAuditStatus}, + finance_audit_status = #{financeAuditStatus}, + expense_code = #{expenseCode}, + deptName = #{deptName}, + postName = #{postName}, + fullName = #{fullName}, + expense_method = #{expenseMethod}, + is_purchase_outsource = #{isPurchaseOutsource}, + supplier_code = #{supplierCode}, + corporate_payee = #{corporatePayee}, + corporate_receiving_account = #{corporateReceivingAccount}, + public_account_banks = #{publicAccountBanks}, + apply_user = #{applyUser}, + create_by = #{createBy}, + create_time = #{createTime}, + update_by = #{updateBy}, + update_time = #{updateTime}, + remark = #{remark}, + use_status = #{useStatus}, + + where expense_id = #{expenseId} + + + + delete from base_emp_expense_account where expense_id = #{expenseId} + + + + delete from base_emp_expense_account where expense_id in + + #{expenseId} + + + + + update base_emp_expense_account set del_flag = '1' where expense_id = #{expenseId} + + + + update base_emp_expense_account set del_flag = '0' where expense_id = #{expenseId} + + + \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/system/baseExpense/add.html b/ruoyi-admin/src/main/resources/templates/system/baseExpense/add.html new file mode 100644 index 00000000..bfa9b111 --- /dev/null +++ b/ruoyi-admin/src/main/resources/templates/system/baseExpense/add.html @@ -0,0 +1,175 @@ + + + + + + +
+
+ +
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+
+
+
+ 报销分类信息 + + 添加报销 + +
+
+
+
+
+
+
+ + + + \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/system/baseExpense/baseExpense.html b/ruoyi-admin/src/main/resources/templates/system/baseExpense/baseExpense.html new file mode 100644 index 00000000..af0a7710 --- /dev/null +++ b/ruoyi-admin/src/main/resources/templates/system/baseExpense/baseExpense.html @@ -0,0 +1,155 @@ + + + + + + +
+
+
+
+
+
    +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + + - + +
  • +
  • +  搜索 +  重置 +
  • +
+
+
+
+ + +
+
+
+
+
+ + + + \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/system/baseExpense/edit.html b/ruoyi-admin/src/main/resources/templates/system/baseExpense/edit.html new file mode 100644 index 00000000..a802f95a --- /dev/null +++ b/ruoyi-admin/src/main/resources/templates/system/baseExpense/edit.html @@ -0,0 +1,183 @@ + + + + + + +
+
+ +
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+
+ +
+ +
+
+
+ +
+ +
+
+ +
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ + +
+
+
+
+ 报销分类信息 + + 添加报销 + +
+
+
+
+
+
+
+ + + + \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/system/baseExpenseChild/add.html b/ruoyi-admin/src/main/resources/templates/system/baseExpenseChild/add.html new file mode 100644 index 00000000..17226728 --- /dev/null +++ b/ruoyi-admin/src/main/resources/templates/system/baseExpenseChild/add.html @@ -0,0 +1,108 @@ + + + + + + + +
+
+
+ +
+ +
+
+
+ +
+ + 代码生成请选择字典属性 +
+
+
+ +
+ + 代码生成请选择字典属性 +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+
+ + +
+
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+
+ + + + + \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/system/baseExpenseChild/baseExpenseChild.html b/ruoyi-admin/src/main/resources/templates/system/baseExpenseChild/baseExpenseChild.html new file mode 100644 index 00000000..4022b236 --- /dev/null +++ b/ruoyi-admin/src/main/resources/templates/system/baseExpenseChild/baseExpenseChild.html @@ -0,0 +1,163 @@ + + + + + + +
+
+
+
+
+
    +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • +  搜索 +  重置 +
  • +
+
+
+
+ + +
+
+
+
+
+ + + + \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/system/baseExpenseChild/edit.html b/ruoyi-admin/src/main/resources/templates/system/baseExpenseChild/edit.html new file mode 100644 index 00000000..a10dca27 --- /dev/null +++ b/ruoyi-admin/src/main/resources/templates/system/baseExpenseChild/edit.html @@ -0,0 +1,103 @@ + + + + + + + +
+
+ +
+ +
+ +
+
+
+ +
+ + 代码生成请选择字典属性 +
+
+
+ +
+ + 代码生成请选择字典属性 +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+
+ + +
+
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+
+ + + + + \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/system/empRequisiteOrderChild/empRequisiteOrderChild.html b/ruoyi-admin/src/main/resources/templates/system/empRequisiteOrderChild/empRequisiteOrderChild.html index 61e27efc..a09f5486 100644 --- a/ruoyi-admin/src/main/resources/templates/system/empRequisiteOrderChild/empRequisiteOrderChild.html +++ b/ruoyi-admin/src/main/resources/templates/system/empRequisiteOrderChild/empRequisiteOrderChild.html @@ -97,12 +97,6 @@ 添加 - - 修改 - - - 删除 - 导出 diff --git a/ruoyi-admin/src/main/resources/templates/system/requesitioningChild/requesitioningChild.html b/ruoyi-admin/src/main/resources/templates/system/requesitioningChild/requesitioningChild.html index 2e953df0..4c643985 100644 --- a/ruoyi-admin/src/main/resources/templates/system/requesitioningChild/requesitioningChild.html +++ b/ruoyi-admin/src/main/resources/templates/system/requesitioningChild/requesitioningChild.html @@ -10,22 +10,10 @@
    -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • @@ -34,71 +22,26 @@
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • - + -
  • - +
  • -
  • - - -
  • @@ -114,12 +57,6 @@ 添加 - - 修改 - - - 删除 - 导出