From 3c807c9364629d61e3f47b613642b499e8b83b29 Mon Sep 17 00:00:00 2001 From: zhangsiqi <2825463979@qq.com> Date: Wed, 15 May 2024 19:35:35 +0800 Subject: [PATCH] =?UTF-8?q?[feat]=E5=9F=BA=E7=A1=80=E8=B5=84=E6=96=99?= =?UTF-8?q?=E6=A8=A1=E5=9D=97=EF=BC=9A=E6=B7=BB=E5=8A=A0=E5=91=98=E5=B7=A5?= =?UTF-8?q?=E9=A2=86=E6=96=99=E5=8D=95=E7=89=A9=E6=96=99=E6=8A=A5=E4=BB=B7?= =?UTF-8?q?=E4=BF=A1=E6=81=AF=E8=A1=A8=EF=BC=8C=E6=B7=BB=E5=8A=A0=E9=A2=86?= =?UTF-8?q?=E6=96=99=E5=8D=95=E7=89=A9=E6=96=99=E5=AE=9E=E4=BD=93=E7=B1=BB?= =?UTF-8?q?=EF=BC=8C=E6=96=B0=E5=A2=9E=E5=91=98=E5=B7=A5=E9=A2=86=E6=96=99?= =?UTF-8?q?=E5=8D=95=E7=89=A9=E6=96=99=E6=8A=A5=E4=BB=B7=E4=BF=A1=E6=81=AF?= =?UTF-8?q?=E6=9F=A5=E8=AF=A2=E6=8E=A5=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../BaseEmpRequisiteOrderChildController.java | 151 ++++++++++ .../domain/BaseEmpRequisiteOrderChild.java | 281 ++++++++++++++++++ .../BaseEmpRequisiteOrderChildMapper.java | 77 +++++ .../IBaseEmpRequisiteOrderChildService.java | 75 +++++ ...BaseEmpRequisiteOrderChildServiceImpl.java | 126 ++++++++ .../BaseEmpRequisiteOrderChildMapper.xml | 165 ++++++++++ .../system/empRequisiteOrder/add.html | 18 ++ .../system/empRequisiteOrderChild/add.html | 141 +++++++++ .../system/empRequisiteOrderChild/edit.html | 142 +++++++++ .../empRequisiteOrderChild.html | 237 +++++++++++++++ 10 files changed, 1413 insertions(+) create mode 100644 ruoyi-admin/src/main/java/com/ruoyi/system/controller/BaseEmpRequisiteOrderChildController.java create mode 100644 ruoyi-admin/src/main/java/com/ruoyi/system/domain/BaseEmpRequisiteOrderChild.java create mode 100644 ruoyi-admin/src/main/java/com/ruoyi/system/mapper/BaseEmpRequisiteOrderChildMapper.java create mode 100644 ruoyi-admin/src/main/java/com/ruoyi/system/service/IBaseEmpRequisiteOrderChildService.java create mode 100644 ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/BaseEmpRequisiteOrderChildServiceImpl.java create mode 100644 ruoyi-admin/src/main/resources/mapper/system/BaseEmpRequisiteOrderChildMapper.xml create mode 100644 ruoyi-admin/src/main/resources/templates/system/empRequisiteOrderChild/add.html create mode 100644 ruoyi-admin/src/main/resources/templates/system/empRequisiteOrderChild/edit.html create mode 100644 ruoyi-admin/src/main/resources/templates/system/empRequisiteOrderChild/empRequisiteOrderChild.html diff --git a/ruoyi-admin/src/main/java/com/ruoyi/system/controller/BaseEmpRequisiteOrderChildController.java b/ruoyi-admin/src/main/java/com/ruoyi/system/controller/BaseEmpRequisiteOrderChildController.java new file mode 100644 index 00000000..89e5c641 --- /dev/null +++ b/ruoyi-admin/src/main/java/com/ruoyi/system/controller/BaseEmpRequisiteOrderChildController.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.BaseEmpRequisiteOrderChild; +import com.ruoyi.system.service.IBaseEmpRequisiteOrderChildService; +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-15 + */ +@Controller +@RequestMapping("/system/empRequisiteOrderChild") +public class BaseEmpRequisiteOrderChildController extends BaseController +{ + private String prefix = "system/empRequisiteOrderChild"; + + @Autowired + private IBaseEmpRequisiteOrderChildService baseEmpRequisiteOrderChildService; + + @RequiresPermissions("system:empRequisiteOrderChild:view") + @GetMapping() + public String empRequisiteOrderChild() + { + return prefix + "/empRequisiteOrderChild"; + } + + /** + * 查询员工单领料单物料信息列表 + */ + @RequiresPermissions("system:empRequisiteOrderChild:list") + @PostMapping("/list") + @ResponseBody + public TableDataInfo list(BaseEmpRequisiteOrderChild baseEmpRequisiteOrderChild) + { + startPage(); + List list = baseEmpRequisiteOrderChildService.selectBaseEmpRequisiteOrderChildList(baseEmpRequisiteOrderChild); + return getDataTable(list); + } + + /** + * 导出员工单领料单物料信息列表 + */ + @RequiresPermissions("system:empRequisiteOrderChild:export") + @Log(title = "员工单领料单物料信息", businessType = BusinessType.EXPORT) + @PostMapping("/export") + @ResponseBody + public AjaxResult export(BaseEmpRequisiteOrderChild baseEmpRequisiteOrderChild) + { + List list = baseEmpRequisiteOrderChildService.selectBaseEmpRequisiteOrderChildList(baseEmpRequisiteOrderChild); + ExcelUtil util = new ExcelUtil(BaseEmpRequisiteOrderChild.class); + return util.exportExcel(list, "员工单领料单物料信息数据"); + } + + /** + * 新增员工单领料单物料信息 + */ + @GetMapping("/add") + public String add() + { + return prefix + "/add"; + } + + /** + * 新增保存员工单领料单物料信息 + */ + @RequiresPermissions("system:empRequisiteOrderChild:add") + @Log(title = "员工单领料单物料信息", businessType = BusinessType.INSERT) + @PostMapping("/add") + @ResponseBody + public AjaxResult addSave(BaseEmpRequisiteOrderChild baseEmpRequisiteOrderChild) + { + return toAjax(baseEmpRequisiteOrderChildService.insertBaseEmpRequisiteOrderChild(baseEmpRequisiteOrderChild)); + } + + /** + * 修改员工单领料单物料信息 + */ + @GetMapping("/edit/{requisitioningChildId}") + public String edit(@PathVariable("requisitioningChildId") Long requisitioningChildId, ModelMap mmap) + { + BaseEmpRequisiteOrderChild baseEmpRequisiteOrderChild = baseEmpRequisiteOrderChildService.selectBaseEmpRequisiteOrderChildById(requisitioningChildId); + mmap.put("baseEmpRequisiteOrderChild", baseEmpRequisiteOrderChild); + return prefix + "/edit"; + } + + /** + * 修改保存员工单领料单物料信息 + */ + @RequiresPermissions("system:empRequisiteOrderChild:edit") + @Log(title = "员工单领料单物料信息", businessType = BusinessType.UPDATE) + @PostMapping("/edit") + @ResponseBody + public AjaxResult editSave(BaseEmpRequisiteOrderChild baseEmpRequisiteOrderChild) + { + return toAjax(baseEmpRequisiteOrderChildService.updateBaseEmpRequisiteOrderChild(baseEmpRequisiteOrderChild)); + } + + /** + * 删除员工单领料单物料信息 + */ + @RequiresPermissions("system:empRequisiteOrderChild:remove") + @Log(title = "员工单领料单物料信息", businessType = BusinessType.DELETE) + @PostMapping( "/remove") + @ResponseBody + public AjaxResult remove(String ids) + { + return toAjax(baseEmpRequisiteOrderChildService.deleteBaseEmpRequisiteOrderChildByIds(ids)); + } + + /** + * 作废员工单领料单物料信息 + */ + @RequiresPermissions("system:empRequisiteOrderChild:cancel") + @Log(title = "员工单领料单物料信息", businessType = BusinessType.CANCEL) + @GetMapping( "/cancel/{id}") + @ResponseBody + public AjaxResult cancel(@PathVariable("id") Long id){ + return toAjax(baseEmpRequisiteOrderChildService.cancelBaseEmpRequisiteOrderChildById(id)); + } + + /** + * 恢复员工单领料单物料信息 + */ + @RequiresPermissions("system:empRequisiteOrderChild:restore") + @Log(title = "员工单领料单物料信息", businessType = BusinessType.RESTORE) + @GetMapping( "/restore/{id}") + @ResponseBody + public AjaxResult restore(@PathVariable("id")Long id) + { + return toAjax(baseEmpRequisiteOrderChildService.restoreBaseEmpRequisiteOrderChildById(id)); + } + + +} diff --git a/ruoyi-admin/src/main/java/com/ruoyi/system/domain/BaseEmpRequisiteOrderChild.java b/ruoyi-admin/src/main/java/com/ruoyi/system/domain/BaseEmpRequisiteOrderChild.java new file mode 100644 index 00000000..c2d7eaad --- /dev/null +++ b/ruoyi-admin/src/main/java/com/ruoyi/system/domain/BaseEmpRequisiteOrderChild.java @@ -0,0 +1,281 @@ +package com.ruoyi.system.domain; + +import java.math.BigDecimal; +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_requisite_order_child + * + * @author zhang + * @date 2024-05-15 + */ +public class BaseEmpRequisiteOrderChild extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** 客户报价子表id */ + private Long requisitioningChildId; + + /** 关联员工领料单编号字段 */ + @Excel(name = "关联员工领料单编号字段") + private String quoteId; + + /** 物料表中的id */ + @Excel(name = "物料表中的id") + private Long materialId; + + /** 料号 */ + @Excel(name = "料号") + private String materialCode; + + /** 物料的图片 */ + @Excel(name = "物料的图片") + private String photoUrl; + + /** 物料的名称 */ + @Excel(name = "物料的名称") + private String materialName; + + /** 物料的类型 */ + @Excel(name = "物料的类型") + private String materialType; + + /** 物料的型号 */ + @Excel(name = "物料的型号") + private String materialModel; + + /** 物料的规格 */ + @Excel(name = "物料的规格") + private String specifications; + + /** 物料的品牌 */ + @Excel(name = "物料的品牌") + private String brand; + + /** 物料的描述 */ + @Excel(name = "物料的描述") + private String describe; + + /** 物料的数量 */ + @Excel(name = "物料的数量") + private Long materialNum; + + /** 物料的不含税单价(RMB) */ + @Excel(name = "物料的不含税单价(RMB)") + private BigDecimal materialRmb; + + /** 物料的含税单价(RMB) */ + @Excel(name = "物料的含税单价(RMB)") + private BigDecimal materialNoRmb; + + /** 物料的含税总价(RMB) */ + @Excel(name = "物料的含税总价(RMB)") + private BigDecimal materialNoRmbSum; + + /** 物料的不含税总价(RMB) */ + @Excel(name = "物料的不含税总价(RMB)") + private BigDecimal materialRmbSum; + + /** 删除状态 */ + @Excel(name = "删除状态") + private String useStatus; + + /** 审核状态 */ + @Excel(name = "审核状态") + private String auditStatus; + + public void setRequisitioningChildId(Long requisitioningChildId) + { + this.requisitioningChildId = requisitioningChildId; + } + + public Long getRequisitioningChildId() + { + return requisitioningChildId; + } + public void setQuoteId(String quoteId) + { + this.quoteId = quoteId; + } + + public String getQuoteId() + { + return quoteId; + } + public void setMaterialId(Long materialId) + { + this.materialId = materialId; + } + + public Long getMaterialId() + { + return materialId; + } + public void setMaterialCode(String materialCode) + { + this.materialCode = materialCode; + } + + public String getMaterialCode() + { + return materialCode; + } + public void setPhotoUrl(String photoUrl) + { + this.photoUrl = photoUrl; + } + + public String getPhotoUrl() + { + return photoUrl; + } + public void setMaterialName(String materialName) + { + this.materialName = materialName; + } + + public String getMaterialName() + { + return materialName; + } + public void setMaterialType(String materialType) + { + this.materialType = materialType; + } + + public String getMaterialType() + { + return materialType; + } + public void setMaterialModel(String materialModel) + { + this.materialModel = materialModel; + } + + public String getMaterialModel() + { + return materialModel; + } + public void setSpecifications(String specifications) + { + this.specifications = specifications; + } + + public String getSpecifications() + { + return specifications; + } + public void setBrand(String brand) + { + this.brand = brand; + } + + public String getBrand() + { + return brand; + } + public void setDescribe(String describe) + { + this.describe = describe; + } + + public String getDescribe() + { + return describe; + } + public void setMaterialNum(Long materialNum) + { + this.materialNum = materialNum; + } + + public Long getMaterialNum() + { + return materialNum; + } + public void setMaterialRmb(BigDecimal materialRmb) + { + this.materialRmb = materialRmb; + } + + public BigDecimal getMaterialRmb() + { + return materialRmb; + } + public void setMaterialNoRmb(BigDecimal materialNoRmb) + { + this.materialNoRmb = materialNoRmb; + } + + public BigDecimal getMaterialNoRmb() + { + return materialNoRmb; + } + public void setMaterialNoRmbSum(BigDecimal materialNoRmbSum) + { + this.materialNoRmbSum = materialNoRmbSum; + } + + public BigDecimal getMaterialNoRmbSum() + { + return materialNoRmbSum; + } + public void setMaterialRmbSum(BigDecimal materialRmbSum) + { + this.materialRmbSum = materialRmbSum; + } + + public BigDecimal getMaterialRmbSum() + { + return materialRmbSum; + } + public void setUseStatus(String useStatus) + { + this.useStatus = useStatus; + } + + public String getUseStatus() + { + return useStatus; + } + public void setAuditStatus(String auditStatus) + { + this.auditStatus = auditStatus; + } + + public String getAuditStatus() + { + return auditStatus; + } + + @Override + public String toString() { + return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) + .append("requisitioningChildId", getRequisitioningChildId()) + .append("quoteId", getQuoteId()) + .append("materialId", getMaterialId()) + .append("materialCode", getMaterialCode()) + .append("photoUrl", getPhotoUrl()) + .append("materialName", getMaterialName()) + .append("materialType", getMaterialType()) + .append("materialModel", getMaterialModel()) + .append("specifications", getSpecifications()) + .append("brand", getBrand()) + .append("describe", getDescribe()) + .append("materialNum", getMaterialNum()) + .append("materialRmb", getMaterialRmb()) + .append("materialNoRmb", getMaterialNoRmb()) + .append("materialNoRmbSum", getMaterialNoRmbSum()) + .append("materialRmbSum", getMaterialRmbSum()) + .append("remark", getRemark()) + .append("createBy", getCreateBy()) + .append("createTime", getCreateTime()) + .append("updateBy", getUpdateBy()) + .append("updateTime", getUpdateTime()) + .append("useStatus", getUseStatus()) + .append("auditStatus", getAuditStatus()) + .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 new file mode 100644 index 00000000..582fb052 --- /dev/null +++ b/ruoyi-admin/src/main/java/com/ruoyi/system/mapper/BaseEmpRequisiteOrderChildMapper.java @@ -0,0 +1,77 @@ +package com.ruoyi.system.mapper; + +import java.util.List; +import com.ruoyi.system.domain.BaseEmpRequisiteOrderChild; + +/** + * 员工单领料单物料信息Mapper接口 + * + * @author zhang + * @date 2024-05-15 + */ +public interface BaseEmpRequisiteOrderChildMapper +{ + /** + * 查询员工单领料单物料信息 + * + * @param requisitioningChildId 员工单领料单物料信息ID + * @return 员工单领料单物料信息 + */ + public BaseEmpRequisiteOrderChild selectBaseEmpRequisiteOrderChildById(Long requisitioningChildId); + + /** + * 查询员工单领料单物料信息列表 + * + * @param baseEmpRequisiteOrderChild 员工单领料单物料信息 + * @return 员工单领料单物料信息集合 + */ + public List selectBaseEmpRequisiteOrderChildList(BaseEmpRequisiteOrderChild baseEmpRequisiteOrderChild); + + /** + * 新增员工单领料单物料信息 + * + * @param baseEmpRequisiteOrderChild 员工单领料单物料信息 + * @return 结果 + */ + public int insertBaseEmpRequisiteOrderChild(BaseEmpRequisiteOrderChild baseEmpRequisiteOrderChild); + + /** + * 修改员工单领料单物料信息 + * + * @param baseEmpRequisiteOrderChild 员工单领料单物料信息 + * @return 结果 + */ + public int updateBaseEmpRequisiteOrderChild(BaseEmpRequisiteOrderChild baseEmpRequisiteOrderChild); + + /** + * 删除员工单领料单物料信息 + * + * @param requisitioningChildId 员工单领料单物料信息ID + * @return 结果 + */ + public int deleteBaseEmpRequisiteOrderChildById(Long requisitioningChildId); + + /** + * 批量删除员工单领料单物料信息 + * + * @param requisitioningChildIds 需要删除的数据ID + * @return 结果 + */ + public int deleteBaseEmpRequisiteOrderChildByIds(String[] requisitioningChildIds); + + /** + * 作废员工单领料单物料信息 + * + * @param requisitioningChildId 员工单领料单物料信息ID + * @return 结果 + */ + public int cancelBaseEmpRequisiteOrderChildById(Long requisitioningChildId); + + /** + * 恢复员工单领料单物料信息 + * + * @param requisitioningChildId 员工单领料单物料信息ID + * @return 结果 + */ + public int restoreBaseEmpRequisiteOrderChildById(Long requisitioningChildId); +} diff --git a/ruoyi-admin/src/main/java/com/ruoyi/system/service/IBaseEmpRequisiteOrderChildService.java b/ruoyi-admin/src/main/java/com/ruoyi/system/service/IBaseEmpRequisiteOrderChildService.java new file mode 100644 index 00000000..47270c99 --- /dev/null +++ b/ruoyi-admin/src/main/java/com/ruoyi/system/service/IBaseEmpRequisiteOrderChildService.java @@ -0,0 +1,75 @@ +package com.ruoyi.system.service; + +import java.util.List; +import com.ruoyi.system.domain.BaseEmpRequisiteOrderChild; + +/** + * 员工单领料单物料信息Service接口 + * + * @author zhang + * @date 2024-05-15 + */ +public interface IBaseEmpRequisiteOrderChildService +{ + /** + * 查询员工单领料单物料信息 + * + * @param requisitioningChildId 员工单领料单物料信息ID + * @return 员工单领料单物料信息 + */ + public BaseEmpRequisiteOrderChild selectBaseEmpRequisiteOrderChildById(Long requisitioningChildId); + + /** + * 查询员工单领料单物料信息列表 + * + * @param baseEmpRequisiteOrderChild 员工单领料单物料信息 + * @return 员工单领料单物料信息集合 + */ + public List selectBaseEmpRequisiteOrderChildList(BaseEmpRequisiteOrderChild baseEmpRequisiteOrderChild); + + /** + * 新增员工单领料单物料信息 + * + * @param baseEmpRequisiteOrderChild 员工单领料单物料信息 + * @return 结果 + */ + public int insertBaseEmpRequisiteOrderChild(BaseEmpRequisiteOrderChild baseEmpRequisiteOrderChild); + + /** + * 修改员工单领料单物料信息 + * + * @param baseEmpRequisiteOrderChild 员工单领料单物料信息 + * @return 结果 + */ + public int updateBaseEmpRequisiteOrderChild(BaseEmpRequisiteOrderChild baseEmpRequisiteOrderChild); + + /** + * 批量删除员工单领料单物料信息 + * + * @param ids 需要删除的数据ID + * @return 结果 + */ + public int deleteBaseEmpRequisiteOrderChildByIds(String ids); + + /** + * 删除员工单领料单物料信息信息 + * + * @param requisitioningChildId 员工单领料单物料信息ID + * @return 结果 + */ + public int deleteBaseEmpRequisiteOrderChildById(Long requisitioningChildId); + + /** + * 作废员工单领料单物料信息 + * @param requisitioningChildId 员工单领料单物料信息ID + * @return + */ + int cancelBaseEmpRequisiteOrderChildById(Long requisitioningChildId); + + /** + * 恢复员工单领料单物料信息 + * @param requisitioningChildId 员工单领料单物料信息ID + * @return + */ + int restoreBaseEmpRequisiteOrderChildById(Long requisitioningChildId); +} diff --git a/ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/BaseEmpRequisiteOrderChildServiceImpl.java b/ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/BaseEmpRequisiteOrderChildServiceImpl.java new file mode 100644 index 00000000..f9c36d2b --- /dev/null +++ b/ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/BaseEmpRequisiteOrderChildServiceImpl.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.BaseEmpRequisiteOrderChildMapper; +import com.ruoyi.system.domain.BaseEmpRequisiteOrderChild; +import com.ruoyi.system.service.IBaseEmpRequisiteOrderChildService; +import com.ruoyi.common.core.text.Convert; + +/** + * 员工单领料单物料信息Service业务层处理 + * + * @author zhang + * @date 2024-05-15 + */ +@Service +public class BaseEmpRequisiteOrderChildServiceImpl implements IBaseEmpRequisiteOrderChildService +{ + @Autowired + private BaseEmpRequisiteOrderChildMapper baseEmpRequisiteOrderChildMapper; + + /** + * 查询员工单领料单物料信息 + * + * @param requisitioningChildId 员工单领料单物料信息ID + * @return 员工单领料单物料信息 + */ + @Override + public BaseEmpRequisiteOrderChild selectBaseEmpRequisiteOrderChildById(Long requisitioningChildId) + { + return baseEmpRequisiteOrderChildMapper.selectBaseEmpRequisiteOrderChildById(requisitioningChildId); + } + + /** + * 查询员工单领料单物料信息列表 + * + * @param baseEmpRequisiteOrderChild 员工单领料单物料信息 + * @return 员工单领料单物料信息 + */ + @Override + public List selectBaseEmpRequisiteOrderChildList(BaseEmpRequisiteOrderChild baseEmpRequisiteOrderChild) + { + return baseEmpRequisiteOrderChildMapper.selectBaseEmpRequisiteOrderChildList(baseEmpRequisiteOrderChild); + } + + /** + * 新增员工单领料单物料信息 + * + * @param baseEmpRequisiteOrderChild 员工单领料单物料信息 + * @return 结果 + */ + @Override + public int insertBaseEmpRequisiteOrderChild(BaseEmpRequisiteOrderChild baseEmpRequisiteOrderChild) + { + String loginName = ShiroUtils.getLoginName(); + baseEmpRequisiteOrderChild.setCreateBy(loginName); + baseEmpRequisiteOrderChild.setCreateTime(DateUtils.getNowDate()); + return baseEmpRequisiteOrderChildMapper.insertBaseEmpRequisiteOrderChild(baseEmpRequisiteOrderChild); + } + + /** + * 修改员工单领料单物料信息 + * + * @param baseEmpRequisiteOrderChild 员工单领料单物料信息 + * @return 结果 + */ + @Override + public int updateBaseEmpRequisiteOrderChild(BaseEmpRequisiteOrderChild baseEmpRequisiteOrderChild) + { + String loginName = ShiroUtils.getLoginName(); + baseEmpRequisiteOrderChild.setUpdateBy(loginName); + baseEmpRequisiteOrderChild.setUpdateTime(DateUtils.getNowDate()); + return baseEmpRequisiteOrderChildMapper.updateBaseEmpRequisiteOrderChild(baseEmpRequisiteOrderChild); + } + + /** + * 删除员工单领料单物料信息对象 + * + * @param ids 需要删除的数据ID + * @return 结果 + */ + @Override + public int deleteBaseEmpRequisiteOrderChildByIds(String ids) + { + return baseEmpRequisiteOrderChildMapper.deleteBaseEmpRequisiteOrderChildByIds(Convert.toStrArray(ids)); + } + + /** + * 删除员工单领料单物料信息信息 + * + * @param requisitioningChildId 员工单领料单物料信息ID + * @return 结果 + */ + @Override + public int deleteBaseEmpRequisiteOrderChildById(Long requisitioningChildId) + { + return baseEmpRequisiteOrderChildMapper.deleteBaseEmpRequisiteOrderChildById(requisitioningChildId); + } + + /** + * 作废员工单领料单物料信息 + * + * @param requisitioningChildId 员工单领料单物料信息ID + * @return 结果 + */ + @Override + public int cancelBaseEmpRequisiteOrderChildById(Long requisitioningChildId) + { + return baseEmpRequisiteOrderChildMapper.cancelBaseEmpRequisiteOrderChildById(requisitioningChildId); + } + + /** + * 恢复员工单领料单物料信息信息 + * + * @param requisitioningChildId 员工单领料单物料信息ID + * @return 结果 + */ + @Override + public int restoreBaseEmpRequisiteOrderChildById(Long requisitioningChildId) + { + return baseEmpRequisiteOrderChildMapper.restoreBaseEmpRequisiteOrderChildById(requisitioningChildId); + } +} diff --git a/ruoyi-admin/src/main/resources/mapper/system/BaseEmpRequisiteOrderChildMapper.xml b/ruoyi-admin/src/main/resources/mapper/system/BaseEmpRequisiteOrderChildMapper.xml new file mode 100644 index 00000000..9dbc8af1 --- /dev/null +++ b/ruoyi-admin/src/main/resources/mapper/system/BaseEmpRequisiteOrderChildMapper.xml @@ -0,0 +1,165 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + select requisitioning_child_id, quote_id, material_id, material_code, photoUrl, material_name, material_type, material_model, specifications, brand, describe, materialNum, materialRmb, materialNoRmb, materialNoRmbSum, materialRmbSum, remark, create_by, create_time, update_by, update_time, use_status, audit_status from base_emp_requisite_order_child + + + + + + + + insert into base_emp_requisite_order_child + + quote_id, + material_id, + material_code, + photoUrl, + material_name, + material_type, + material_model, + specifications, + brand, + describe, + materialNum, + materialRmb, + materialNoRmb, + materialNoRmbSum, + materialRmbSum, + remark, + create_by, + create_time, + update_by, + update_time, + use_status, + audit_status, + + + #{quoteId}, + #{materialId}, + #{materialCode}, + #{photoUrl}, + #{materialName}, + #{materialType}, + #{materialModel}, + #{specifications}, + #{brand}, + #{describe}, + #{materialNum}, + #{materialRmb}, + #{materialNoRmb}, + #{materialNoRmbSum}, + #{materialRmbSum}, + #{remark}, + #{createBy}, + #{createTime}, + #{updateBy}, + #{updateTime}, + #{useStatus}, + #{auditStatus}, + + + + + update base_emp_requisite_order_child + + quote_id = #{quoteId}, + material_id = #{materialId}, + material_code = #{materialCode}, + photoUrl = #{photoUrl}, + material_name = #{materialName}, + material_type = #{materialType}, + material_model = #{materialModel}, + specifications = #{specifications}, + brand = #{brand}, + describe = #{describe}, + materialNum = #{materialNum}, + materialRmb = #{materialRmb}, + materialNoRmb = #{materialNoRmb}, + materialNoRmbSum = #{materialNoRmbSum}, + materialRmbSum = #{materialRmbSum}, + remark = #{remark}, + create_by = #{createBy}, + create_time = #{createTime}, + update_by = #{updateBy}, + update_time = #{updateTime}, + use_status = #{useStatus}, + audit_status = #{auditStatus}, + + where requisitioning_child_id = #{requisitioningChildId} + + + + delete from base_emp_requisite_order_child where requisitioning_child_id = #{requisitioningChildId} + + + + delete from base_emp_requisite_order_child where requisitioning_child_id in + + #{requisitioningChildId} + + + + + update base_emp_requisite_order_child set del_flag = '1' where requisitioning_child_id = #{requisitioningChildId} + + + + update base_emp_requisite_order_child set del_flag = '0' where requisitioning_child_id = #{requisitioningChildId} + + + \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/system/empRequisiteOrder/add.html b/ruoyi-admin/src/main/resources/templates/system/empRequisiteOrder/add.html index bf24c45a..d8350c83 100644 --- a/ruoyi-admin/src/main/resources/templates/system/empRequisiteOrder/add.html +++ b/ruoyi-admin/src/main/resources/templates/system/empRequisiteOrder/add.html @@ -168,6 +168,24 @@ $.operate.save(prefix + "/add", $('#form-empRequisiteOrder-add').serialize()); } } + + function getSelections(){ + $.ajax({ + url: ctx + "system/requisitioning/getEmpUserName", + type: "get", + dataType: "json", + success: function (data) { + console.log(data); + $("select[name='dept']").append($('').val(data.deptName).html(data.deptName)); + $("select[name='userName']").append($('').val(data.userName).html(data.userName)); + $("select[name='post']").append($('').val(data.postName).html(data.postName)); + + + // $select.trigger('change'); + } + }); + + } \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/system/empRequisiteOrderChild/add.html b/ruoyi-admin/src/main/resources/templates/system/empRequisiteOrderChild/add.html new file mode 100644 index 00000000..e1e46d2c --- /dev/null +++ b/ruoyi-admin/src/main/resources/templates/system/empRequisiteOrderChild/add.html @@ -0,0 +1,141 @@ + + + + + + +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ + 代码生成请选择字典属性 +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ + 代码生成请选择字典属性 +
+
+
+ +
+ +
+
+
+
+ + + + \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/system/empRequisiteOrderChild/edit.html b/ruoyi-admin/src/main/resources/templates/system/empRequisiteOrderChild/edit.html new file mode 100644 index 00000000..aa8353d2 --- /dev/null +++ b/ruoyi-admin/src/main/resources/templates/system/empRequisiteOrderChild/edit.html @@ -0,0 +1,142 @@ + + + + + + +
+
+ +
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ + 代码生成请选择字典属性 +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ + 代码生成请选择字典属性 +
+
+
+ +
+ +
+
+
+
+ + + + \ 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 new file mode 100644 index 00000000..61e27efc --- /dev/null +++ b/ruoyi-admin/src/main/resources/templates/system/empRequisiteOrderChild/empRequisiteOrderChild.html @@ -0,0 +1,237 @@ + + + + + + +
+
+
+
+
+
    +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • +  搜索 +  重置 +
  • +
+
+
+
+ + +
+
+
+
+
+ + + + \ No newline at end of file