Browse Source

[feat]基础资料模块:添加员工领料单,新增、修改页面, 修改采购单报价添加页面;增加采购报价物料信息表添加功能;新增请购单报价物料信息子表,新增请购单物料信息子表对象。

dev
zhangsiqi 6 months ago
parent
commit
c0ce049b57
  1. 151
      ruoyi-admin/src/main/java/com/ruoyi/system/controller/BaseEmpRequisiteOrderController.java
  2. 151
      ruoyi-admin/src/main/java/com/ruoyi/system/controller/BaseRequisitioningOrderChildController.java
  3. 19
      ruoyi-admin/src/main/java/com/ruoyi/system/controller/BaseRequisitioningOrderController.java
  4. 183
      ruoyi-admin/src/main/java/com/ruoyi/system/domain/BaseEmpRequisiteOrder.java
  5. 14
      ruoyi-admin/src/main/java/com/ruoyi/system/domain/BaseRequisitioningOrder.java
  6. 282
      ruoyi-admin/src/main/java/com/ruoyi/system/domain/BaseRequisitioningOrderChild.java
  7. 77
      ruoyi-admin/src/main/java/com/ruoyi/system/mapper/BaseEmpRequisiteOrderMapper.java
  8. 82
      ruoyi-admin/src/main/java/com/ruoyi/system/mapper/BaseRequisitioningOrderChildMapper.java
  9. 4
      ruoyi-admin/src/main/java/com/ruoyi/system/mapper/BaseRequisitioningOrderMapper.java
  10. 75
      ruoyi-admin/src/main/java/com/ruoyi/system/service/IBaseEmpRequisiteOrderService.java
  11. 79
      ruoyi-admin/src/main/java/com/ruoyi/system/service/IBaseRequisitioningOrderChildService.java
  12. 5
      ruoyi-admin/src/main/java/com/ruoyi/system/service/IBaseRequisitioningOrderService.java
  13. 126
      ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/BaseEmpRequisiteOrderServiceImpl.java
  14. 135
      ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/BaseRequisitioningOrderChildServiceImpl.java
  15. 40
      ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/BaseRequisitioningOrderServiceImpl.java
  16. 126
      ruoyi-admin/src/main/resources/mapper/system/BaseEmpRequisiteOrderMapper.xml
  17. 182
      ruoyi-admin/src/main/resources/mapper/system/BaseRequisitioningOrderChildMapper.xml
  18. 12
      ruoyi-admin/src/main/resources/mapper/system/BaseRequisitioningOrderMapper.xml
  19. 251
      ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/add.html
  20. 193
      ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/edit.html
  21. 1
      ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/purchaseQuote.html
  22. 173
      ruoyi-admin/src/main/resources/templates/system/empRequisiteOrder/add.html
  23. 171
      ruoyi-admin/src/main/resources/templates/system/empRequisiteOrder/edit.html
  24. 161
      ruoyi-admin/src/main/resources/templates/system/empRequisiteOrder/empRequisiteOrder.html
  25. 144
      ruoyi-admin/src/main/resources/templates/system/requesitioningChild/add.html
  26. 145
      ruoyi-admin/src/main/resources/templates/system/requesitioningChild/edit.html
  27. 250
      ruoyi-admin/src/main/resources/templates/system/requesitioningChild/requesitioningChild.html
  28. 9
      ruoyi-admin/src/main/resources/templates/system/requisitioning/add.html
  29. 17
      ruoyi-admin/src/main/resources/templates/system/requisitioning/edit.html

151
ruoyi-admin/src/main/java/com/ruoyi/system/controller/BaseEmpRequisiteOrderController.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.BaseEmpRequisiteOrder;
import com.ruoyi.system.service.IBaseEmpRequisiteOrderService;
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-14
*/
@Controller
@RequestMapping("/system/empRequisiteOrder")
public class BaseEmpRequisiteOrderController extends BaseController
{
private String prefix = "system/empRequisiteOrder";
@Autowired
private IBaseEmpRequisiteOrderService baseEmpRequisiteOrderService;
@RequiresPermissions("system:empRequisiteOrder:view")
@GetMapping()
public String empRequisiteOrder()
{
return prefix + "/empRequisiteOrder";
}
/**
* 查询员工领料单列表
*/
@RequiresPermissions("system:empRequisiteOrder:list")
@PostMapping("/list")
@ResponseBody
public TableDataInfo list(BaseEmpRequisiteOrder baseEmpRequisiteOrder)
{
startPage();
List<BaseEmpRequisiteOrder> list = baseEmpRequisiteOrderService.selectBaseEmpRequisiteOrderList(baseEmpRequisiteOrder);
return getDataTable(list);
}
/**
* 导出员工领料单列表
*/
@RequiresPermissions("system:empRequisiteOrder:export")
@Log(title = "员工领料单", businessType = BusinessType.EXPORT)
@PostMapping("/export")
@ResponseBody
public AjaxResult export(BaseEmpRequisiteOrder baseEmpRequisiteOrder)
{
List<BaseEmpRequisiteOrder> list = baseEmpRequisiteOrderService.selectBaseEmpRequisiteOrderList(baseEmpRequisiteOrder);
ExcelUtil<BaseEmpRequisiteOrder> util = new ExcelUtil<BaseEmpRequisiteOrder>(BaseEmpRequisiteOrder.class);
return util.exportExcel(list, "员工领料单数据");
}
/**
* 新增员工领料单
*/
@GetMapping("/add")
public String add()
{
return prefix + "/add";
}
/**
* 新增保存员工领料单
*/
@RequiresPermissions("system:empRequisiteOrder:add")
@Log(title = "员工领料单", businessType = BusinessType.INSERT)
@PostMapping("/add")
@ResponseBody
public AjaxResult addSave(BaseEmpRequisiteOrder baseEmpRequisiteOrder)
{
return toAjax(baseEmpRequisiteOrderService.insertBaseEmpRequisiteOrder(baseEmpRequisiteOrder));
}
/**
* 修改员工领料单
*/
@GetMapping("/edit/{requisiteId}")
public String edit(@PathVariable("requisiteId") Long requisiteId, ModelMap mmap)
{
BaseEmpRequisiteOrder baseEmpRequisiteOrder = baseEmpRequisiteOrderService.selectBaseEmpRequisiteOrderById(requisiteId);
mmap.put("baseEmpRequisiteOrder", baseEmpRequisiteOrder);
return prefix + "/edit";
}
/**
* 修改保存员工领料单
*/
@RequiresPermissions("system:empRequisiteOrder:edit")
@Log(title = "员工领料单", businessType = BusinessType.UPDATE)
@PostMapping("/edit")
@ResponseBody
public AjaxResult editSave(BaseEmpRequisiteOrder baseEmpRequisiteOrder)
{
return toAjax(baseEmpRequisiteOrderService.updateBaseEmpRequisiteOrder(baseEmpRequisiteOrder));
}
/**
* 删除员工领料单
*/
@RequiresPermissions("system:empRequisiteOrder:remove")
@Log(title = "员工领料单", businessType = BusinessType.DELETE)
@PostMapping( "/remove")
@ResponseBody
public AjaxResult remove(String ids)
{
return toAjax(baseEmpRequisiteOrderService.deleteBaseEmpRequisiteOrderByIds(ids));
}
/**
* 作废员工领料单
*/
@RequiresPermissions("system:empRequisiteOrder:cancel")
@Log(title = "员工领料单", businessType = BusinessType.CANCEL)
@GetMapping( "/cancel/{id}")
@ResponseBody
public AjaxResult cancel(@PathVariable("id") Long id){
return toAjax(baseEmpRequisiteOrderService.cancelBaseEmpRequisiteOrderById(id));
}
/**
* 恢复员工领料单
*/
@RequiresPermissions("system:empRequisiteOrder:restore")
@Log(title = "员工领料单", businessType = BusinessType.RESTORE)
@GetMapping( "/restore/{id}")
@ResponseBody
public AjaxResult restore(@PathVariable("id")Long id)
{
return toAjax(baseEmpRequisiteOrderService.restoreBaseEmpRequisiteOrderById(id));
}
}

151
ruoyi-admin/src/main/java/com/ruoyi/system/controller/BaseRequisitioningOrderChildController.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.BaseRequisitioningOrderChild;
import com.ruoyi.system.service.IBaseRequisitioningOrderChildService;
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-13
*/
@Controller
//@RequestMapping("/system/requesitioningChild")
public class BaseRequisitioningOrderChildController extends BaseController
{
private String prefix = "system/requesitioningChild";
@Autowired
private IBaseRequisitioningOrderChildService baseRequisitioningOrderChildService;
// @RequiresPermissions("system:requesitioningChild:view")
@GetMapping()
public String requesitioningChild()
{
return prefix + "/requesitioningChild";
}
/**
* 查询请购单列表
*/
@RequiresPermissions("system:requesitioningChild:list")
@PostMapping("/list")
@ResponseBody
public TableDataInfo list(BaseRequisitioningOrderChild baseRequisitioningOrderChild)
{
startPage();
List<BaseRequisitioningOrderChild> list = baseRequisitioningOrderChildService.selectBaseRequisitioningOrderChildList(baseRequisitioningOrderChild);
return getDataTable(list);
}
/**
* 导出请购单列表
*/
// @RequiresPermissions("system:requesitioningChild:export")
@Log(title = "请购单", businessType = BusinessType.EXPORT)
@PostMapping("/export")
@ResponseBody
public AjaxResult export(BaseRequisitioningOrderChild baseRequisitioningOrderChild)
{
List<BaseRequisitioningOrderChild> list = baseRequisitioningOrderChildService.selectBaseRequisitioningOrderChildList(baseRequisitioningOrderChild);
ExcelUtil<BaseRequisitioningOrderChild> util = new ExcelUtil<BaseRequisitioningOrderChild>(BaseRequisitioningOrderChild.class);
return util.exportExcel(list, "请购单数据");
}
/**
* 新增请购单
*/
@GetMapping("/add")
public String add()
{
return prefix + "/add";
}
/**
* 新增保存请购单
*/
// @RequiresPermissions("system:requesitioningChild:add")
@Log(title = "请购单", businessType = BusinessType.INSERT)
@PostMapping("/add")
@ResponseBody
public AjaxResult addSave(BaseRequisitioningOrderChild baseRequisitioningOrderChild)
{
return toAjax(baseRequisitioningOrderChildService.insertBaseRequisitioningOrderChild(baseRequisitioningOrderChild));
}
/**
* 修改请购单
*/
@GetMapping("/edit/{requisitioningChildId}")
public String edit(@PathVariable("requisitioningChildId") Long requisitioningChildId, ModelMap mmap)
{
BaseRequisitioningOrderChild baseRequisitioningOrderChild = baseRequisitioningOrderChildService.selectBaseRequisitioningOrderChildById(requisitioningChildId);
mmap.put("baseRequisitioningOrderChild", baseRequisitioningOrderChild);
return prefix + "/edit";
}
/**
* 修改保存请购单
*/
// @RequiresPermissions("system:requesitioningChild:edit")
@Log(title = "请购单", businessType = BusinessType.UPDATE)
@PostMapping("/edit")
@ResponseBody
public AjaxResult editSave(BaseRequisitioningOrderChild baseRequisitioningOrderChild)
{
return toAjax(baseRequisitioningOrderChildService.updateBaseRequisitioningOrderChild(baseRequisitioningOrderChild));
}
/**
* 删除请购单
*/
// @RequiresPermissions("system:requesitioningChild:remove")
@Log(title = "请购单", businessType = BusinessType.DELETE)
@PostMapping( "/remove")
@ResponseBody
public AjaxResult remove(String ids)
{
return toAjax(baseRequisitioningOrderChildService.deleteBaseRequisitioningOrderChildByIds(ids));
}
/**
* 作废请购单
*/
// @RequiresPermissions("system:requesitioningChild:cancel")
@Log(title = "请购单", businessType = BusinessType.CANCEL)
@GetMapping( "/cancel/{id}")
@ResponseBody
public AjaxResult cancel(@PathVariable("id") Long id){
return toAjax(baseRequisitioningOrderChildService.cancelBaseRequisitioningOrderChildById(id));
}
/**
* 恢复请购单
*/
// @RequiresPermissions("system:requesitioningChild:restore")
@Log(title = "请购单", businessType = BusinessType.RESTORE)
@GetMapping( "/restore/{id}")
@ResponseBody
public AjaxResult restore(@PathVariable("id")Long id)
{
return toAjax(baseRequisitioningOrderChildService.restoreBaseRequisitioningOrderChildById(id));
}
}

19
ruoyi-admin/src/main/java/com/ruoyi/system/controller/BaseRequisitioningOrderController.java

@ -1,6 +1,8 @@
package com.ruoyi.system.controller;
import java.util.List;
import com.ruoyi.system.service.IBaseRequisitioningOrderChildService;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
@ -34,6 +36,9 @@ public class BaseRequisitioningOrderController extends BaseController
@Autowired
private IBaseRequisitioningOrderService baseRequisitioningOrderService;
@Autowired
private IBaseRequisitioningOrderChildService baseRequisitioningOrderChildService;
@RequiresPermissions("system:requisitioning:view")
@GetMapping()
public String requisitioning()
@ -67,16 +72,20 @@ public class BaseRequisitioningOrderController extends BaseController
ExcelUtil<BaseRequisitioningOrder> util = new ExcelUtil<BaseRequisitioningOrder>(BaseRequisitioningOrder.class);
return util.exportExcel(list, "请购单数据");
}
/**
* 新增请购单
*/
@GetMapping("/add")
public String add()
{
return prefix + "/add";
}
public String add(){return prefix + "/add";}
@GetMapping("/detail/{id}")
public String detail(@PathVariable("id") Long id){
BaseRequisitioningOrder baseRequisitioningOrder = baseRequisitioningOrderService.selectBaseRequisitioningOrderById(id);
baseRequisitioningOrder.setRequisitioningId(id);
baseRequisitioningOrderService.selectBaseRequisitioningOrderList(baseRequisitioningOrder);
return prefix + "/detail";
}
/**
* 新增保存请购单
*/

183
ruoyi-admin/src/main/java/com/ruoyi/system/domain/BaseEmpRequisiteOrder.java

@ -0,0 +1,183 @@
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
*
* @author zhang
* @date 2024-05-14
*/
public class BaseEmpRequisiteOrder extends BaseEntity
{
private static final long serialVersionUID = 1L;
/** 员工号领料单索引id */
private Long requisiteId;
/** 审核状态 */
@Excel(name = "审核状态")
private String auditStatus;
/** 领料状态 */
@Excel(name = "领料状态")
private String requisitieStatus;
/** 领料单编号 */
@Excel(name = "领料单编号")
private String requisitieCode;
/** 关联销售订单号 */
@Excel(name = "关联销售订单号")
private String correlationCode;
/** 物料合计 */
@Excel(name = "物料合计")
private Long materialAmount;
/** 数量总计 */
@Excel(name = "数量总计")
private Long materialSum;
/** 不含税总价(RMB) */
@Excel(name = "不含税总价(RMB)")
private BigDecimal noRmbSum;
/** 含税总价(RMB) */
@Excel(name = "含税总价(RMB)")
private BigDecimal rmbSum;
/** 申请人 */
@Excel(name = "申请人")
private String applyUser;
/** 使用状态 */
@Excel(name = "使用状态")
private String useStatus;
public void setRequisiteId(Long requisiteId)
{
this.requisiteId = requisiteId;
}
public Long getRequisiteId()
{
return requisiteId;
}
public void setAuditStatus(String auditStatus)
{
this.auditStatus = auditStatus;
}
public String getAuditStatus()
{
return auditStatus;
}
public void setRequisitieStatus(String requisitieStatus)
{
this.requisitieStatus = requisitieStatus;
}
public String getRequisitieStatus()
{
return requisitieStatus;
}
public void setRequisitieCode(String requisitieCode)
{
this.requisitieCode = requisitieCode;
}
public String getRequisitieCode()
{
return requisitieCode;
}
public void setCorrelationCode(String correlationCode)
{
this.correlationCode = correlationCode;
}
public String getCorrelationCode()
{
return correlationCode;
}
public void setMaterialAmount(Long materialAmount)
{
this.materialAmount = materialAmount;
}
public Long getMaterialAmount()
{
return materialAmount;
}
public void setMaterialSum(Long materialSum)
{
this.materialSum = materialSum;
}
public Long getMaterialSum()
{
return materialSum;
}
public void setNoRmbSum(BigDecimal noRmbSum)
{
this.noRmbSum = noRmbSum;
}
public BigDecimal getNoRmbSum()
{
return noRmbSum;
}
public void setRmbSum(BigDecimal rmbSum)
{
this.rmbSum = rmbSum;
}
public BigDecimal getRmbSum()
{
return rmbSum;
}
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("requisiteId", getRequisiteId())
.append("auditStatus", getAuditStatus())
.append("requisitieStatus", getRequisitieStatus())
.append("requisitieCode", getRequisitieCode())
.append("correlationCode", getCorrelationCode())
.append("materialAmount", getMaterialAmount())
.append("materialSum", getMaterialSum())
.append("noRmbSum", getNoRmbSum())
.append("rmbSum", getRmbSum())
.append("applyUser", getApplyUser())
.append("createBy", getCreateBy())
.append("createTime", getCreateTime())
.append("updateBy", getUpdateBy())
.append("updateTime", getUpdateTime())
.append("remark", getRemark())
.append("useStatus", getUseStatus())
.toString();
}
}

14
ruoyi-admin/src/main/java/com/ruoyi/system/domain/BaseRequisitioningOrder.java

@ -60,7 +60,19 @@ public class BaseRequisitioningOrder extends BaseEntity
/** 使用状态 */
private String useStatus;
public void setRequisitioningId(Long requisitioningId)
private List<BaseRequisitioningOrderChild> baseRequisitioningOrderChildList;
public List<BaseRequisitioningOrderChild> getBaseRequisitioningOrderChildList() {
return baseRequisitioningOrderChildList;
}
public void setBaseRequisitioningOrderChildList(List<BaseRequisitioningOrderChild> baseRequisitioningOrderChildList) {
this.baseRequisitioningOrderChildList = baseRequisitioningOrderChildList;
}
public void setRequisitioningId(Long requisitioningId)
{
this.requisitioningId = requisitioningId;
}

282
ruoyi-admin/src/main/java/com/ruoyi/system/domain/BaseRequisitioningOrderChild.java

@ -0,0 +1,282 @@
package com.ruoyi.system.domain;
import java.math.BigDecimal;
import java.util.List;
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_requisitioning_order_child
*
* @author zhang
* @date 2024-05-13
*/
public class BaseRequisitioningOrderChild 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 Long 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(Long materialRmbSum)
{
this.materialRmbSum = materialRmbSum;
}
public Long 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();
}
}

77
ruoyi-admin/src/main/java/com/ruoyi/system/mapper/BaseEmpRequisiteOrderMapper.java

@ -0,0 +1,77 @@
package com.ruoyi.system.mapper;
import java.util.List;
import com.ruoyi.system.domain.BaseEmpRequisiteOrder;
/**
* 员工领料单Mapper接口
*
* @author zhang
* @date 2024-05-14
*/
public interface BaseEmpRequisiteOrderMapper
{
/**
* 查询员工领料单
*
* @param requisiteId 员工领料单ID
* @return 员工领料单
*/
public BaseEmpRequisiteOrder selectBaseEmpRequisiteOrderById(Long requisiteId);
/**
* 查询员工领料单列表
*
* @param baseEmpRequisiteOrder 员工领料单
* @return 员工领料单集合
*/
public List<BaseEmpRequisiteOrder> selectBaseEmpRequisiteOrderList(BaseEmpRequisiteOrder baseEmpRequisiteOrder);
/**
* 新增员工领料单
*
* @param baseEmpRequisiteOrder 员工领料单
* @return 结果
*/
public int insertBaseEmpRequisiteOrder(BaseEmpRequisiteOrder baseEmpRequisiteOrder);
/**
* 修改员工领料单
*
* @param baseEmpRequisiteOrder 员工领料单
* @return 结果
*/
public int updateBaseEmpRequisiteOrder(BaseEmpRequisiteOrder baseEmpRequisiteOrder);
/**
* 删除员工领料单
*
* @param requisiteId 员工领料单ID
* @return 结果
*/
public int deleteBaseEmpRequisiteOrderById(Long requisiteId);
/**
* 批量删除员工领料单
*
* @param requisiteIds 需要删除的数据ID
* @return 结果
*/
public int deleteBaseEmpRequisiteOrderByIds(String[] requisiteIds);
/**
* 作废员工领料单
*
* @param requisiteId 员工领料单ID
* @return 结果
*/
public int cancelBaseEmpRequisiteOrderById(Long requisiteId);
/**
* 恢复员工领料单
*
* @param requisiteId 员工领料单ID
* @return 结果
*/
public int restoreBaseEmpRequisiteOrderById(Long requisiteId);
}

82
ruoyi-admin/src/main/java/com/ruoyi/system/mapper/BaseRequisitioningOrderChildMapper.java

@ -0,0 +1,82 @@
package com.ruoyi.system.mapper;
import java.util.List;
import com.ruoyi.system.domain.BaseRequisitioningOrderChild;
/**
* 请购单Mapper接口
*
* @author zhang
* @date 2024-05-13
*/
public interface BaseRequisitioningOrderChildMapper
{
/**
* 查询请购单
*
* @param requisitioningChildId 请购单ID
* @return 请购单
*/
public BaseRequisitioningOrderChild selectBaseRequisitioningOrderChildById(Long requisitioningChildId);
/**
* 查询请购单列表
*
* @param baseRequisitioningOrderChild 请购单
* @return 请购单集合
*/
public List<BaseRequisitioningOrderChild> selectBaseRequisitioningOrderChildList(BaseRequisitioningOrderChild baseRequisitioningOrderChild);
/**
* 新增请购单
*
* @param baseRequisitioningOrderChild 请购单
* @return 结果
*/
public int insertBaseRequisitioningOrderChild(BaseRequisitioningOrderChild baseRequisitioningOrderChild);
/**
* 修改请购单
*
* @param baseRequisitioningOrderChild 请购单
* @return 结果
*/
public int updateBaseRequisitioningOrderChild(BaseRequisitioningOrderChild baseRequisitioningOrderChild);
/**
* 删除请购单
*
* @param requisitioningChildId 请购单ID
* @return 结果
*/
public int deleteBaseRequisitioningOrderChildById(Long requisitioningChildId);
/**
* 批量删除请购单
*
* @param requisitioningChildIds 需要删除的数据ID
* @return 结果
*/
public int deleteBaseRequisitioningOrderChildByIds(String[] requisitioningChildIds);
/**
* 作废请购单
*
* @param requisitioningChildId 请购单ID
* @return 结果
*/
public int cancelBaseRequisitioningOrderChildById(Long requisitioningChildId);
/**
* 恢复请购单
*
* @param requisitioningChildId 请购单ID
* @return 结果
*/
public int restoreBaseRequisitioningOrderChildById(Long requisitioningChildId);
public int deleteBaseRequisitioningOrderChildByQuoteId(String quoteId);
public int deleteBaseRequisitioningOrderChildByQuoteIds(String[] quoteIds);
}

4
ruoyi-admin/src/main/java/com/ruoyi/system/mapper/BaseRequisitioningOrderMapper.java

@ -74,4 +74,8 @@ public interface BaseRequisitioningOrderMapper
* @return 结果
*/
public int restoreBaseRequisitioningOrderById(Long requisitioningId);
int deleteBaseRequisitioningOrderByCode(String requisitioningCode);
List<BaseRequisitioningOrder> selectBaseRequisitioningOrderByIds(String[] ids);
}

75
ruoyi-admin/src/main/java/com/ruoyi/system/service/IBaseEmpRequisiteOrderService.java

@ -0,0 +1,75 @@
package com.ruoyi.system.service;
import java.util.List;
import com.ruoyi.system.domain.BaseEmpRequisiteOrder;
/**
* 员工领料单Service接口
*
* @author zhang
* @date 2024-05-14
*/
public interface IBaseEmpRequisiteOrderService
{
/**
* 查询员工领料单
*
* @param requisiteId 员工领料单ID
* @return 员工领料单
*/
public BaseEmpRequisiteOrder selectBaseEmpRequisiteOrderById(Long requisiteId);
/**
* 查询员工领料单列表
*
* @param baseEmpRequisiteOrder 员工领料单
* @return 员工领料单集合
*/
public List<BaseEmpRequisiteOrder> selectBaseEmpRequisiteOrderList(BaseEmpRequisiteOrder baseEmpRequisiteOrder);
/**
* 新增员工领料单
*
* @param baseEmpRequisiteOrder 员工领料单
* @return 结果
*/
public int insertBaseEmpRequisiteOrder(BaseEmpRequisiteOrder baseEmpRequisiteOrder);
/**
* 修改员工领料单
*
* @param baseEmpRequisiteOrder 员工领料单
* @return 结果
*/
public int updateBaseEmpRequisiteOrder(BaseEmpRequisiteOrder baseEmpRequisiteOrder);
/**
* 批量删除员工领料单
*
* @param ids 需要删除的数据ID
* @return 结果
*/
public int deleteBaseEmpRequisiteOrderByIds(String ids);
/**
* 删除员工领料单信息
*
* @param requisiteId 员工领料单ID
* @return 结果
*/
public int deleteBaseEmpRequisiteOrderById(Long requisiteId);
/**
* 作废员工领料单
* @param requisiteId 员工领料单ID
* @return
*/
int cancelBaseEmpRequisiteOrderById(Long requisiteId);
/**
* 恢复员工领料单
* @param requisiteId 员工领料单ID
* @return
*/
int restoreBaseEmpRequisiteOrderById(Long requisiteId);
}

79
ruoyi-admin/src/main/java/com/ruoyi/system/service/IBaseRequisitioningOrderChildService.java

@ -0,0 +1,79 @@
package com.ruoyi.system.service;
import java.util.List;
import com.ruoyi.system.domain.BaseRequisitioningOrderChild;
/**
* 请购单Service接口
*
* @author zhang
* @date 2024-05-13
*/
public interface IBaseRequisitioningOrderChildService
{
/**
* 查询请购单
*
* @param requisitioningChildId 请购单ID
* @return 请购单
*/
public BaseRequisitioningOrderChild selectBaseRequisitioningOrderChildById(Long requisitioningChildId);
/**
* 查询请购单列表
*
* @param baseRequisitioningOrderChild 请购单
* @return 请购单集合
*/
public List<BaseRequisitioningOrderChild> selectBaseRequisitioningOrderChildList(BaseRequisitioningOrderChild baseRequisitioningOrderChild);
/**
* 新增请购单
*
* @param baseRequisitioningOrderChild 请购单
* @return 结果
*/
public int insertBaseRequisitioningOrderChild(BaseRequisitioningOrderChild baseRequisitioningOrderChild);
/**
* 修改请购单
*
* @param baseRequisitioningOrderChild 请购单
* @return 结果
*/
public int updateBaseRequisitioningOrderChild(BaseRequisitioningOrderChild baseRequisitioningOrderChild);
/**
* 批量删除请购单
*
* @param ids 需要删除的数据ID
* @return 结果
*/
public int deleteBaseRequisitioningOrderChildByIds(String ids);
/**
* 删除请购单信息
*
* @param requisitioningChildId 请购单ID
* @return 结果
*/
public int deleteBaseRequisitioningOrderChildById(Long requisitioningChildId);
/**
* 作废请购单
* @param requisitioningChildId 请购单ID
* @return
*/
int cancelBaseRequisitioningOrderChildById(Long requisitioningChildId);
/**
* 恢复请购单
* @param requisitioningChildId 请购单ID
* @return
*/
int restoreBaseRequisitioningOrderChildById(Long requisitioningChildId);
int deleteBaseRequisitioningOrderChildByQuoteId(String quoteId);
int deleteBaseRequisitioningOrderChildByQuoteIds(String quoteIds);
}

5
ruoyi-admin/src/main/java/com/ruoyi/system/service/IBaseRequisitioningOrderService.java

@ -72,4 +72,9 @@ public interface IBaseRequisitioningOrderService
* @return
*/
int restoreBaseRequisitioningOrderById(Long requisitioningId);
int deleteBaseRequisitioningOrderByCode(String requisitioningCode);
List<BaseRequisitioningOrder> selectBaseRequisitioningOrderByIds(String ids);
}

126
ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/BaseEmpRequisiteOrderServiceImpl.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.BaseEmpRequisiteOrderMapper;
import com.ruoyi.system.domain.BaseEmpRequisiteOrder;
import com.ruoyi.system.service.IBaseEmpRequisiteOrderService;
import com.ruoyi.common.core.text.Convert;
/**
* 员工领料单Service业务层处理
*
* @author zhang
* @date 2024-05-14
*/
@Service
public class BaseEmpRequisiteOrderServiceImpl implements IBaseEmpRequisiteOrderService
{
@Autowired
private BaseEmpRequisiteOrderMapper baseEmpRequisiteOrderMapper;
/**
* 查询员工领料单
*
* @param requisiteId 员工领料单ID
* @return 员工领料单
*/
@Override
public BaseEmpRequisiteOrder selectBaseEmpRequisiteOrderById(Long requisiteId)
{
return baseEmpRequisiteOrderMapper.selectBaseEmpRequisiteOrderById(requisiteId);
}
/**
* 查询员工领料单列表
*
* @param baseEmpRequisiteOrder 员工领料单
* @return 员工领料单
*/
@Override
public List<BaseEmpRequisiteOrder> selectBaseEmpRequisiteOrderList(BaseEmpRequisiteOrder baseEmpRequisiteOrder)
{
return baseEmpRequisiteOrderMapper.selectBaseEmpRequisiteOrderList(baseEmpRequisiteOrder);
}
/**
* 新增员工领料单
*
* @param baseEmpRequisiteOrder 员工领料单
* @return 结果
*/
@Override
public int insertBaseEmpRequisiteOrder(BaseEmpRequisiteOrder baseEmpRequisiteOrder)
{
String loginName = ShiroUtils.getLoginName();
baseEmpRequisiteOrder.setCreateBy(loginName);
baseEmpRequisiteOrder.setCreateTime(DateUtils.getNowDate());
return baseEmpRequisiteOrderMapper.insertBaseEmpRequisiteOrder(baseEmpRequisiteOrder);
}
/**
* 修改员工领料单
*
* @param baseEmpRequisiteOrder 员工领料单
* @return 结果
*/
@Override
public int updateBaseEmpRequisiteOrder(BaseEmpRequisiteOrder baseEmpRequisiteOrder)
{
String loginName = ShiroUtils.getLoginName();
baseEmpRequisiteOrder.setUpdateBy(loginName);
baseEmpRequisiteOrder.setUpdateTime(DateUtils.getNowDate());
return baseEmpRequisiteOrderMapper.updateBaseEmpRequisiteOrder(baseEmpRequisiteOrder);
}
/**
* 删除员工领料单对象
*
* @param ids 需要删除的数据ID
* @return 结果
*/
@Override
public int deleteBaseEmpRequisiteOrderByIds(String ids)
{
return baseEmpRequisiteOrderMapper.deleteBaseEmpRequisiteOrderByIds(Convert.toStrArray(ids));
}
/**
* 删除员工领料单信息
*
* @param requisiteId 员工领料单ID
* @return 结果
*/
@Override
public int deleteBaseEmpRequisiteOrderById(Long requisiteId)
{
return baseEmpRequisiteOrderMapper.deleteBaseEmpRequisiteOrderById(requisiteId);
}
/**
* 作废员工领料单
*
* @param requisiteId 员工领料单ID
* @return 结果
*/
@Override
public int cancelBaseEmpRequisiteOrderById(Long requisiteId)
{
return baseEmpRequisiteOrderMapper.cancelBaseEmpRequisiteOrderById(requisiteId);
}
/**
* 恢复员工领料单信息
*
* @param requisiteId 员工领料单ID
* @return 结果
*/
@Override
public int restoreBaseEmpRequisiteOrderById(Long requisiteId)
{
return baseEmpRequisiteOrderMapper.restoreBaseEmpRequisiteOrderById(requisiteId);
}
}

135
ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/BaseRequisitioningOrderChildServiceImpl.java

@ -0,0 +1,135 @@
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.BaseRequisitioningOrderChildMapper;
import com.ruoyi.system.domain.BaseRequisitioningOrderChild;
import com.ruoyi.system.service.IBaseRequisitioningOrderChildService;
import com.ruoyi.common.core.text.Convert;
/**
* 请购单Service业务层处理
*
* @author zhang
* @date 2024-05-13
*/
@Service
public class BaseRequisitioningOrderChildServiceImpl implements IBaseRequisitioningOrderChildService
{
@Autowired
private BaseRequisitioningOrderChildMapper baseRequisitioningOrderChildMapper;
/**
* 查询请购单
*
* @param requisitioningChildId 请购单ID
* @return 请购单
*/
@Override
public BaseRequisitioningOrderChild selectBaseRequisitioningOrderChildById(Long requisitioningChildId)
{
return baseRequisitioningOrderChildMapper.selectBaseRequisitioningOrderChildById(requisitioningChildId);
}
/**
* 查询请购单列表
*
* @param baseRequisitioningOrderChild 请购单
* @return 请购单
*/
@Override
public List<BaseRequisitioningOrderChild> selectBaseRequisitioningOrderChildList(BaseRequisitioningOrderChild baseRequisitioningOrderChild)
{
return baseRequisitioningOrderChildMapper.selectBaseRequisitioningOrderChildList(baseRequisitioningOrderChild);
}
/**
* 新增请购单
*
* @param baseRequisitioningOrderChild 请购单
* @return 结果
*/
@Override
public int insertBaseRequisitioningOrderChild(BaseRequisitioningOrderChild baseRequisitioningOrderChild)
{
String loginName = ShiroUtils.getLoginName();
baseRequisitioningOrderChild.setCreateBy(loginName);
baseRequisitioningOrderChild.setCreateTime(DateUtils.getNowDate());
return baseRequisitioningOrderChildMapper.insertBaseRequisitioningOrderChild(baseRequisitioningOrderChild);
}
/**
* 修改请购单
*
* @param baseRequisitioningOrderChild 请购单
* @return 结果
*/
@Override
public int updateBaseRequisitioningOrderChild(BaseRequisitioningOrderChild baseRequisitioningOrderChild)
{
String loginName = ShiroUtils.getLoginName();
baseRequisitioningOrderChild.setUpdateBy(loginName);
baseRequisitioningOrderChild.setUpdateTime(DateUtils.getNowDate());
return baseRequisitioningOrderChildMapper.updateBaseRequisitioningOrderChild(baseRequisitioningOrderChild);
}
/**
* 删除请购单对象
*
* @param ids 需要删除的数据ID
* @return 结果
*/
@Override
public int deleteBaseRequisitioningOrderChildByIds(String ids)
{
return baseRequisitioningOrderChildMapper.deleteBaseRequisitioningOrderChildByIds(Convert.toStrArray(ids));
}
/**
* 删除请购单信息
*
* @param requisitioningChildId 请购单ID
* @return 结果
*/
@Override
public int deleteBaseRequisitioningOrderChildById(Long requisitioningChildId)
{
return baseRequisitioningOrderChildMapper.deleteBaseRequisitioningOrderChildById(requisitioningChildId);
}
/**
* 作废请购单
*
* @param requisitioningChildId 请购单ID
* @return 结果
*/
@Override
public int cancelBaseRequisitioningOrderChildById(Long requisitioningChildId)
{
return baseRequisitioningOrderChildMapper.cancelBaseRequisitioningOrderChildById(requisitioningChildId);
}
/**
* 恢复请购单信息
*
* @param requisitioningChildId 请购单ID
* @return 结果
*/
@Override
public int restoreBaseRequisitioningOrderChildById(Long requisitioningChildId)
{
return baseRequisitioningOrderChildMapper.restoreBaseRequisitioningOrderChildById(requisitioningChildId);
}
@Override
public int deleteBaseRequisitioningOrderChildByQuoteId(String quoteId) {
return baseRequisitioningOrderChildMapper.deleteBaseRequisitioningOrderChildByQuoteId(quoteId);
}
@Override
public int deleteBaseRequisitioningOrderChildByQuoteIds(String quoteIds) {
return baseRequisitioningOrderChildMapper.deleteBaseRequisitioningOrderChildByQuoteIds(Convert.toStrArray(quoteIds));
}
}

40
ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/BaseRequisitioningOrderServiceImpl.java

@ -1,8 +1,13 @@
package com.ruoyi.system.service.impl;
import java.util.ArrayList;
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.BaseRequisitioningOrderChild;
import com.ruoyi.system.mapper.BaseRequisitioningOrderChildMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.BaseRequisitioningOrderMapper;
@ -22,6 +27,12 @@ public class BaseRequisitioningOrderServiceImpl implements IBaseRequisitioningOr
@Autowired
private BaseRequisitioningOrderMapper baseRequisitioningOrderMapper;
@Autowired
private BaseRequisitioningOrderChildMapper baseRequisitioningOrderChildMapper;
@Autowired
private RedisCache redisCache;
/**
* 查询请购单
*
@ -58,6 +69,14 @@ public class BaseRequisitioningOrderServiceImpl implements IBaseRequisitioningOr
String loginName = ShiroUtils.getLoginName();
baseRequisitioningOrder.setCreateBy(loginName);
baseRequisitioningOrder.setCreateTime(DateUtils.getNowDate());
baseRequisitioningOrder.setRequisitioningCode(redisCache.generateBillNo("QG"));
List<BaseRequisitioningOrderChild> childList = baseRequisitioningOrder.getBaseRequisitioningOrderChildList();
for (BaseRequisitioningOrderChild child: childList) {
child.setQuoteId(baseRequisitioningOrder.getRequisitioningCode());
child.setCreateBy(loginName);
child.setCreateTime(DateUtils.getNowDate());
baseRequisitioningOrderChildMapper.insertBaseRequisitioningOrderChild(child);
}
return baseRequisitioningOrderMapper.insertBaseRequisitioningOrder(baseRequisitioningOrder);
}
@ -73,6 +92,17 @@ public class BaseRequisitioningOrderServiceImpl implements IBaseRequisitioningOr
String loginName = ShiroUtils.getLoginName();
baseRequisitioningOrder.setUpdateBy(loginName);
baseRequisitioningOrder.setUpdateTime(DateUtils.getNowDate());
String requisitioningCode = baseRequisitioningOrder.getRequisitioningCode();
baseRequisitioningOrderChildMapper.deleteBaseRequisitioningOrderChildByQuoteId(baseRequisitioningOrder.getRequisitioningCode());
if (baseRequisitioningOrder.getBaseRequisitioningOrderChildList() != null) {
List<BaseRequisitioningOrderChild> childList = baseRequisitioningOrder.getBaseRequisitioningOrderChildList();
for (BaseRequisitioningOrderChild child: childList) {
child.setQuoteId(requisitioningCode);
child.setUpdateBy(loginName);
child.setUpdateTime(DateUtils.getNowDate());
baseRequisitioningOrderChildMapper.insertBaseRequisitioningOrderChild(child);
}
}
return baseRequisitioningOrderMapper.updateBaseRequisitioningOrder(baseRequisitioningOrder);
}
@ -123,4 +153,14 @@ public class BaseRequisitioningOrderServiceImpl implements IBaseRequisitioningOr
{
return baseRequisitioningOrderMapper.restoreBaseRequisitioningOrderById(requisitioningId);
}
@Override
public int deleteBaseRequisitioningOrderByCode(String requisitioningCode) {
baseRequisitioningOrderChildMapper.deleteBaseRequisitioningOrderChildByQuoteId(requisitioningCode);
return baseRequisitioningOrderMapper.deleteBaseRequisitioningOrderByCode(requisitioningCode);
}
@Override
public List<BaseRequisitioningOrder> selectBaseRequisitioningOrderByIds(String ids){
return baseRequisitioningOrderMapper.selectBaseRequisitioningOrderByIds(Convert.toStrArray(ids));
}
}

126
ruoyi-admin/src/main/resources/mapper/system/BaseEmpRequisiteOrderMapper.xml

@ -0,0 +1,126 @@
<?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.ruoyi.system.mapper.BaseEmpRequisiteOrderMapper">
<resultMap type="BaseEmpRequisiteOrder" id="BaseEmpRequisiteOrderResult">
<result property="requisiteId" column="requisite_id" />
<result property="auditStatus" column="audit_status" />
<result property="requisitieStatus" column="requisitie_status" />
<result property="requisitieCode" column="requisitie_code" />
<result property="correlationCode" column="correlation_code" />
<result property="materialAmount" column="material_amount" />
<result property="materialSum" column="material_sum" />
<result property="noRmbSum" column="noRmbSum" />
<result property="rmbSum" column="rmbSum" />
<result property="applyUser" column="apply_user" />
<result property="createBy" column="create_by" />
<result property="createTime" column="create_time" />
<result property="updateBy" column="update_by" />
<result property="updateTime" column="update_time" />
<result property="remark" column="remark" />
<result property="useStatus" column="use_status" />
</resultMap>
<sql id="selectBaseEmpRequisiteOrderVo">
select requisite_id, audit_status, requisitie_status, requisitie_code, correlation_code, material_amount, material_sum, noRmbSum, rmbSum, apply_user, create_by, create_time, update_by, update_time, remark, use_status from base_emp_requisite_order
</sql>
<select id="selectBaseEmpRequisiteOrderList" parameterType="BaseEmpRequisiteOrder" resultMap="BaseEmpRequisiteOrderResult">
<include refid="selectBaseEmpRequisiteOrderVo"/>
<where>
<if test="auditStatus != null and auditStatus != ''"> and audit_status = #{auditStatus}</if>
<if test="requisitieStatus != null and requisitieStatus != ''"> and requisitie_status = #{requisitieStatus}</if>
<if test="requisitieCode != null and requisitieCode != ''"> and requisitie_code = #{requisitieCode}</if>
<if test="correlationCode != null and correlationCode != ''"> and correlation_code = #{correlationCode}</if>
<if test="applyUser != null and applyUser != ''"> and apply_user = #{applyUser}</if>
<if test="createBy != null and createBy != ''"> and create_by = #{createBy}</if>
</where>
</select>
<select id="selectBaseEmpRequisiteOrderById" parameterType="Long" resultMap="BaseEmpRequisiteOrderResult">
<include refid="selectBaseEmpRequisiteOrderVo"/>
where requisite_id = #{requisiteId}
</select>
<insert id="insertBaseEmpRequisiteOrder" parameterType="BaseEmpRequisiteOrder" useGeneratedKeys="true" keyProperty="requisiteId">
insert into base_emp_requisite_order
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="auditStatus != null">audit_status,</if>
<if test="requisitieStatus != null">requisitie_status,</if>
<if test="requisitieCode != null">requisitie_code,</if>
<if test="correlationCode != null">correlation_code,</if>
<if test="materialAmount != null">material_amount,</if>
<if test="materialSum != null">material_sum,</if>
<if test="noRmbSum != null">noRmbSum,</if>
<if test="rmbSum != null">rmbSum,</if>
<if test="applyUser != null">apply_user,</if>
<if test="createBy != null">create_by,</if>
<if test="createTime != null">create_time,</if>
<if test="updateBy != null">update_by,</if>
<if test="updateTime != null">update_time,</if>
<if test="remark != null">remark,</if>
<if test="useStatus != null">use_status,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="auditStatus != null">#{auditStatus},</if>
<if test="requisitieStatus != null">#{requisitieStatus},</if>
<if test="requisitieCode != null">#{requisitieCode},</if>
<if test="correlationCode != null">#{correlationCode},</if>
<if test="materialAmount != null">#{materialAmount},</if>
<if test="materialSum != null">#{materialSum},</if>
<if test="noRmbSum != null">#{noRmbSum},</if>
<if test="rmbSum != null">#{rmbSum},</if>
<if test="applyUser != null">#{applyUser},</if>
<if test="createBy != null">#{createBy},</if>
<if test="createTime != null">#{createTime},</if>
<if test="updateBy != null">#{updateBy},</if>
<if test="updateTime != null">#{updateTime},</if>
<if test="remark != null">#{remark},</if>
<if test="useStatus != null">#{useStatus},</if>
</trim>
</insert>
<update id="updateBaseEmpRequisiteOrder" parameterType="BaseEmpRequisiteOrder">
update base_emp_requisite_order
<trim prefix="SET" suffixOverrides=",">
<if test="auditStatus != null">audit_status = #{auditStatus},</if>
<if test="requisitieStatus != null">requisitie_status = #{requisitieStatus},</if>
<if test="requisitieCode != null">requisitie_code = #{requisitieCode},</if>
<if test="correlationCode != null">correlation_code = #{correlationCode},</if>
<if test="materialAmount != null">material_amount = #{materialAmount},</if>
<if test="materialSum != null">material_sum = #{materialSum},</if>
<if test="noRmbSum != null">noRmbSum = #{noRmbSum},</if>
<if test="rmbSum != null">rmbSum = #{rmbSum},</if>
<if test="applyUser != null">apply_user = #{applyUser},</if>
<if test="createBy != null">create_by = #{createBy},</if>
<if test="createTime != null">create_time = #{createTime},</if>
<if test="updateBy != null">update_by = #{updateBy},</if>
<if test="updateTime != null">update_time = #{updateTime},</if>
<if test="remark != null">remark = #{remark},</if>
<if test="useStatus != null">use_status = #{useStatus},</if>
</trim>
where requisite_id = #{requisiteId}
</update>
<delete id="deleteBaseEmpRequisiteOrderById" parameterType="Long">
delete from base_emp_requisite_order where requisite_id = #{requisiteId}
</delete>
<delete id="deleteBaseEmpRequisiteOrderByIds" parameterType="String">
delete from base_emp_requisite_order where requisite_id in
<foreach item="requisiteId" collection="array" open="(" separator="," close=")">
#{requisiteId}
</foreach>
</delete>
<update id="cancelBaseEmpRequisiteOrderById" parameterType="Long">
update base_emp_requisite_order set del_flag = '1' where requisite_id = #{requisiteId}
</update>
<update id="restoreBaseEmpRequisiteOrderById" parameterType="Long">
update base_emp_requisite_order set del_flag = '0' where requisite_id = #{requisiteId}
</update>
</mapper>

182
ruoyi-admin/src/main/resources/mapper/system/BaseRequisitioningOrderChildMapper.xml

@ -0,0 +1,182 @@
<?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.ruoyi.system.mapper.BaseRequisitioningOrderChildMapper">
<resultMap type="BaseRequisitioningOrderChild" id="BaseRequisitioningOrderChildResult">
<result property="requisitioningChildId" column="requisitioning_child_id" />
<result property="quoteId" column="quote_id" />
<result property="materialId" column="material_id" />
<result property="materialCode" column="material_code" />
<result property="photoUrl" column="photoUrl" />
<result property="materialName" column="material_name" />
<result property="materialType" column="material_type" />
<result property="materialModel" column="material_model" />
<result property="specifications" column="specifications" />
<result property="brand" column="brand" />
<result property="describe" column="describe" />
<result property="materialNum" column="materialNum" />
<result property="materialRmb" column="materialRmb" />
<result property="materialNoRmb" column="materialNoRmb" />
<result property="materialNoRmbSum" column="materialNoRmbSum" />
<result property="materialRmbSum" column="materialRmbSum" />
<result property="remark" column="remark" />
<result property="createBy" column="create_by" />
<result property="createTime" column="create_time" />
<result property="updateBy" column="update_by" />
<result property="updateTime" column="update_time" />
<result property="useStatus" column="use_status" />
<result property="auditStatus" column="audit_status" />
</resultMap>
<sql id="selectBaseRequisitioningOrderChildVo">
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_requisitioning_order_child
</sql>
<select id="selectBaseRequisitioningOrderChildList" parameterType="BaseRequisitioningOrderChild" resultMap="BaseRequisitioningOrderChildResult">
<include refid="selectBaseRequisitioningOrderChildVo"/>
<where>
<if test="quoteId != null and quoteId != ''"> and quote_id = #{quoteId}</if>
<if test="materialId != null "> and material_id = #{materialId}</if>
<if test="materialCode != null and materialCode != ''"> and material_code = #{materialCode}</if>
<if test="photoUrl != null and photoUrl != ''"> and photoUrl = #{photoUrl}</if>
<if test="materialName != null and materialName != ''"> and material_name like concat('%', #{materialName}, '%')</if>
<if test="materialType != null and materialType != ''"> and material_type = #{materialType}</if>
<if test="materialModel != null and materialModel != ''"> and material_model = #{materilaModel}</if>
<if test="specifications != null and specifications != ''"> and specifications = #{specifications}</if>
<if test="brand != null and brand != ''"> and brand = #{brand}</if>
<if test="describe != null and describe != ''"> and describe = #{describe}</if>
<if test="materialNum != null "> and materialNum = #{materialNum}</if>
<if test="materialRmb != null "> and materialRmb = #{materialRmb}</if>
<if test="materialNoRmb != null "> and materialNoRmb = #{materialNoRmb}</if>
<if test="materialNoRmbSum != null "> and materialNoRmbSum = #{materialNoRmbSum}</if>
<if test="materialRmbSum != null "> and materialRmbSum = #{materialRmbSum}</if>
<if test="remark != null and remark != ''"> and remark = #{remark}</if>
<if test="createBy != null and createBy != ''"> and create_by = #{createBy}</if>
<if test="params.beginCreateTime != null and params.beginCreateTime != '' and params.endCreateTime != null and params.endCreateTime != ''"> and create_time between #{params.beginCreateTime} and #{params.endCreateTime}</if>
<if test="updateBy != null and updateBy != ''"> and update_by = #{updateBy}</if>
<if test="useStatus != null and useStatus != ''"> and use_status = #{useStatus}</if>
<if test="auditStatus != null and auditStatus != ''"> and audit_status = #{auditStatus}</if>
</where>
</select>
<select id="selectBaseRequisitioningOrderChildById" parameterType="Long" resultMap="BaseRequisitioningOrderChildResult">
<include refid="selectBaseRequisitioningOrderChildVo"/>
where requisitioning_child_id = #{requisitioningChildId}
</select>
<insert id="insertBaseRequisitioningOrderChild" parameterType="BaseRequisitioningOrderChild" useGeneratedKeys="true" keyProperty="requisitioningChildId">
insert into base_requisitioning_order_child
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="quoteId != null">quote_id,</if>
<if test="materialId != null">material_id,</if>
<if test="materialCode != null">material_code,</if>
<if test="photoUrl != null">photoUrl,</if>
<if test="materialName != null">material_name,</if>
<if test="materialType != null">material_type,</if>
<if test="materialModel != null">material_model,</if>
<if test="specifications != null">specifications,</if>
<if test="brand != null">brand,</if>
<if test="describe != null">describe,</if>
<if test="materialNum != null">materialNum,</if>
<if test="materialRmb != null">materialRmb,</if>
<if test="materialNoRmb != null">materialNoRmb,</if>
<if test="materialNoRmbSum != null">materialNoRmbSum,</if>
<if test="materialRmbSum != null">materialRmbSum,</if>
<if test="remark != null">remark,</if>
<if test="createBy != null">create_by,</if>
<if test="createTime != null">create_time,</if>
<if test="updateBy != null">update_by,</if>
<if test="updateTime != null">update_time,</if>
<if test="useStatus != null">use_status,</if>
<if test="auditStatus != null">audit_status,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="quoteId != null">#{quoteId},</if>
<if test="materialId != null">#{materialId},</if>
<if test="materialCode != null">#{materialCode},</if>
<if test="photoUrl != null">#{photoUrl},</if>
<if test="materialName != null">#{materialName},</if>
<if test="materialType != null">#{materialType},</if>
<if test="materialModel != null">#{materialModel},</if>
<if test="specifications != null">#{specifications},</if>
<if test="brand != null">#{brand},</if>
<if test="describe != null">#{describe},</if>
<if test="materialNum != null">#{materialNum},</if>
<if test="materialRmb != null">#{materialRmb},</if>
<if test="materialNoRmb != null">#{materialNoRmb},</if>
<if test="materialNoRmbSum != null">#{materialNoRmbSum},</if>
<if test="materialRmbSum != null">#{materialRmbSum},</if>
<if test="remark != null">#{remark},</if>
<if test="createBy != null">#{createBy},</if>
<if test="createTime != null">#{createTime},</if>
<if test="updateBy != null">#{updateBy},</if>
<if test="updateTime != null">#{updateTime},</if>
<if test="useStatus != null">#{useStatus},</if>
<if test="auditStatus != null">#{auditStatus},</if>
</trim>
</insert>
<update id="updateBaseRequisitioningOrderChild" parameterType="BaseRequisitioningOrderChild">
update base_requisitioning_order_child
<trim prefix="SET" suffixOverrides=",">
<if test="quoteId != null">quote_id = #{quoteId},</if>
<if test="materialId != null">material_id = #{materialId},</if>
<if test="materialCode != null">material_code = #{materialCode},</if>
<if test="photoUrl != null">photoUrl = #{photoUrl},</if>
<if test="materialName != null">material_name = #{materialName},</if>
<if test="materialType != null">material_type = #{materialType},</if>
<if test="materialModel != null">material_model = #{materialModel},</if>
<if test="specifications != null">specifications = #{specifications},</if>
<if test="brand != null">brand = #{brand},</if>
<if test="describe != null">`describe` = #{describe},</if>
<if test="materialNum != null">materialNum = #{materialNum},</if>
<if test="materialRmb != null">materialRmb = #{materialRmb},</if>
<if test="materialNoRmb != null">materialNoRmb = #{materialNoRmb},</if>
<if test="materialNoRmbSum != null">materialNoRmbSum = #{materialNoRmbSum},</if>
<if test="materialRmbSum != null">materialRmbSum = #{materialRmbSum},</if>
<if test="remark != null">remark = #{remark},</if>
<if test="createBy != null">create_by = #{createBy},</if>
<if test="createTime != null">create_time = #{createTime},</if>
<if test="updateBy != null">update_by = #{updateBy},</if>
<if test="updateTime != null">update_time = #{updateTime},</if>
<if test="useStatus != null">use_status = #{useStatus},</if>
<if test="auditStatus != null">audit_status = #{auditStatus},</if>
</trim>
where requisitioning_child_id = #{requisitioningChildId}
</update>
<delete id="deleteBaseRequisitioningOrderChildById" parameterType="Long">
delete from base_requisitioning_order_child where requisitioning_child_id = #{requisitioningChildId}
</delete>
<delete id="deleteBaseRequisitioningOrderChildByQuoteId" parameterType="String">
delete from base_requisitioning_order_child where quote_id = #{qoteId}
</delete>
<delete id="deleteBaseRequisitioningOrderChildByQuoteIds" parameterType="String">
delete from base_requisitioning_order_child where quote_id in
<foreach item="quoteId" collection="array" open="(" separator="," close=")">
#{quoteId}
</foreach>
</delete>
<delete id="deleteBaseRequisitioningOrderChildByIds" parameterType="String">
delete from base_requisitioning_order_child where requisitioning_child_id in
<foreach item="requisitioningChildId" collection="array" open="(" separator="," close=")">
#{requisitioningChildId}
</foreach>
</delete>
<update id="cancelBaseRequisitioningOrderChildById" parameterType="Long">
update base_requisitioning_order_child set del_flag = '1' where requisitioning_child_id = #{requisitioningChildId}
</update>
<update id="restoreBaseRequisitioningOrderChildById" parameterType="Long">
update base_requisitioning_order_child set del_flag = '0' where requisitioning_child_id = #{requisitioningChildId}
</update>
</mapper>

12
ruoyi-admin/src/main/resources/mapper/system/BaseRequisitioningOrderMapper.xml

@ -60,7 +60,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<include refid="selectBaseRequisitioningOrderVo"/>
where requisitioning_id = #{requisitioningId}
</select>
<select id="selectBaseRequisitioningOrderByIds" parameterType="String" resultMap="BaseRequisitioningOrderResult">
<include refid="selectBaseRequisitioningOrderVo"/>
where requisitioning_id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</select>
<insert id="insertBaseRequisitioningOrder" parameterType="BaseRequisitioningOrder" useGeneratedKeys="true" keyProperty="requisitioningId">
insert into base_requisitioning_order
<trim prefix="(" suffix=")" suffixOverrides=",">
@ -131,6 +138,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
#{requisitioningId}
</foreach>
</delete>
<delete id="deleteBaseRequisitioningOrderByCode" parameterType="String">
delete from base_requisitioning_order where requisitioning_code = #{requisitioningId}
</delete>
<update id="cancelBaseRequisitioningOrderById" parameterType="Long">
update base_requisitioning_order set del_flag = '1' where requisitioning_id = #{requisitioningId}

251
ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/add.html

@ -7,112 +7,231 @@
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
<form class="form-horizontal m" id="form-purchaseQuote-add">
<div class="form-group">
<label class="col-sm-3 control-label">采购报价单号:</label>
<div class="col-sm-8">
<input name="purchaseQuoteCode" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">采购员:</label>
<label class="col-sm-3 control-label is-required">采购报价单号:</label>
<div class="col-sm-8">
<select name="purchaseBuyer" class="form-control m-b">
<option value="">所有</option>
</select>
<span class="help-block m-b-none"><i class="fa fa-info-circle"></i> 代码生成请选择字典属性</span>
<input name="purchaseQuoteCode" class="form-control" type="text" required>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">供应商ID:</label>
<div class="col-sm-8">
<input name="supplierQuoteCode" class="form-control" type="text">
<select name="supplierCode" class="form-control">
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">供应商名称:</label>
<div class="col-sm-8">
<input name="supplierName" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">税率:</label>
<div class="col-sm-8">
<input name="taxRate" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料合计:</label>
<div class="col-sm-8">
<input name="materialAmount" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">定价时间:</label>
<div class="col-sm-8">
<input name="pricingDate" class="form-control" type="text">
<select name="supplierName" class="form-control">
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">料号:</label>
<div class="col-sm-8">
<input name="materialNo" class="form-control" type="text">
<label class="col-sm-3 control-label">定价日期:</label>
<div class="input-group date">
<input name="pricingDate" class="form-control" placeholder="yyyy-MM-dd" type="text">
<span class="input-group-addon"><i class="fa fa-calendar"></i></span>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">录入时间:</label>
<div class="col-sm-8">
<input name="firstAddTime" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">修改时间:</label>
<div class="form-group">
<label class="col-sm-3 control-label">备注说明:</label>
<div class="col-sm-8">
<input name="updateInfoTime" class="form-control" type="text">
<textarea name="remark" class="form-control"></textarea>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料名称:</label>
<div class="col-sm-8">
<input name="materialName" class="form-control" type="text">
</div>
<label class="col-sm-3 control-label">附件:</label>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">审核状态</label>
<label class="col-sm-3 control-label">税率:</label>
<div class="col-sm-8">
<div class="radio-box" th:each="dict : ${@dict.getType('auditStatus')}">
<input type="radio" th:id="${'auditStatus_' + dict.dictCode}" name="auditStatus" th:value="${dict.dictValue}" th:checked="${dict.default}">
<label th:for="${'auditStatus_' + dict.dictCode}" th:text="${dict.dictLabel}"></label>
<div class="input-group">
<input name="rmbTax" id="rmbTax_add" class="form-control" placeholder="13" />
<span class="input-group-addon">%</span>
</div>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">使用状态:</label>
<div class="col-sm-8">
<div class="radio-box" th:each="dict : ${@dict.getType('useStatus')}">
<input type="radio" th:id="${'useStatus_' + dict.dictCode}" name="useStatus" th:value="${dict.dictValue}" th:checked="${dict.default}">
<label th:for="${'useStatus_' + dict.dictCode}" th:text="${dict.dictLabel}"></label>
</div>
</form>
<div class="container">
<div class="form-row">
<div class="btn-group-sm" id="toolbar" role="group">
<span>选择报价信息</span>
<a class="btn btn-success" onclick="insertRow()">
<i class="fa fa-plus"></i> 添加物料
</a>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">备注:</label>
<div class="col-sm-8">
<textarea name="remark" class="form-control"></textarea>
<div class="row">
<div class="col-sm-12 select-table table-striped">
<table id="bootstrap-sub-table-purchaseQuoteChild"></table>
</div>
</div>
</form>
</div>
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var prefix = ctx + "purchase/purchaseQuote"
$("#form-purchaseQuote-add").validate({
focusCleanup: true
$("#form-purchaseQuote-add").validate({focusCleanup: true});
$(function() {
var options = {
id:'bootstrap-sub-table-purchaseQuoteChild',
// url: ctx + "system/quoteChild/list",
pagination: false,
sidePagination: "client",
model: "物料报价信息",
columns: [
{checkbox: true},
{field: 'index',align: 'center', title: "序号",
formatter: function (value, row, index) {
var columnIndex = $.common.sprintf("<input type='hidden' name='index' value='%s'>", $.table.serialNumber(index));
return columnIndex + $.table.serialNumber(index);
}
},
{title: '物料索引id',field: 'materialId',align: 'center',visible: false},
{title: '料号',field: 'materialCode',align: 'center'},
{title: '物料名称',field: 'materialName',align: 'center'},
{title: '图片',field: 'photoUrl',
formatter: function(value, row, index) {
return $.table.imageView(value);
}
},
{title: '物料类型',field: 'materialType',align: 'center',
formatter: function(value, row, index) {
return $.table.selectCategoryLabel(materialTypeDatas, value);
}
},
{ title: '描述',field: 'describe',align: 'center'},
{title: '品牌',field: 'brand',align: 'center'},
{ title: '单位',field: 'unit',align: 'center',
formatter: function(value, row, index) {
return $.table.selectDictLabel(sysUnitClassDatas, value);
}
},
{title: '加工方式',field: 'processMethod',align: 'center',
formatter: function(value, row, index) {
return $.table.selectDictLabel(processMethodDatas, value);
}
},
{title: '最新报价',field: 'materialSole',align: 'center',},
{title: '物料的数量', field: 'materialNum',align: 'center',editable: true,},
{title: '物料的不含税单价(RMB)',field: 'materialNoRmb',align: 'center',},
{title: '物料的含税单价(RMB)',field: 'materialRmb',align: 'center',},
{title: '录入人',field: 'createBy',align: 'center',visible: false},
{title: '录入时间',field: 'createTime',align: 'center',visible: false },
{title: '更新人',field: 'updateBy',align: 'center',visible: false},
{title: '上次更新时间',field: 'updateTime',align: 'center',visible: false},
{title: '备注',field: 'remark',align: 'center'},
{title: '操作', align: 'center',
formatter: function (value, row, index) {
var actions = [];
actions.push('<a class="btn btn-danger btn-xs" href="javascript:void(0)" onclick="removeRow(\'' + row.id + '\')"><i class="fa fa-remove"></i>删除</a> ');
return actions.join('');
}
}
]
};
$.table.init(options);
selectSupplierCode();
selectSupplierName();
});
function doSubmit(index, layero,uniqueId){
console.log(uniqueId);
var iframeWin = window[layero.find('iframe')[0]['name']];
var rowData = iframeWin.$('#bootstrap-select-table').bootstrapTable('getSelections')[0];
console.log("rowData: "+rowData);
$("#bootstrap-sub-table-purchaseQuoteChild").bootstrapTable('insertRow', {
index:1,
row: {
materialId:rowData.id,
materialCode: rowData.materialNo,
materialName: rowData.materialName,
materialType: rowData.materialType,
describe: rowData.describe,
brand: rowData.brand,
unit: rowData.unit,
processMethod: rowData.processMethod,
materialSole: '',
photoUrl: rowData.photoUrl,
materialNum: 1,
materialRmb: "",
materialNoRmb: "",
materialNoRmbSum: "",
materialRmbSum: "",
remark: ""
}
})
layer.close(index);
}
function insertRow() {
var url = ctx + "erp/material/select";
var options = {
title: '选择料号',
url: url,
callBack: doSubmit
};
$.modal.openOptions(options);
}
/* 删除指定表格行 */
function removeRow(id){
$("#bootstrap-sub-table-requisitionChild").bootstrapTable('remove', {
field: 'id',
values: id
})
}
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/add", $('#form-purchaseQuote-add').serialize());
}
}
//获取供应商
function selectSupplierCode(){
$.ajax({
url: 'erp/supplier/getSupplier',
type: "post",
dataType: "json",
success: function (data) {
if (res.rows.length > 0) {
var usertData = res.rows;
//alert(JSON.stringify(data));
for (let i in usertData) {
// console.log(finishProductData[i].finishProductCode)
$("#form-purchaseQuote-add select[name='supplierCode']").append(
"<option value='" + usertData[i].supplierCode + "'>" + usertData[i].supplierCode + "</option>");
}
} else {
$.modal.msgError(res.msg);
}
}
});
}
function selectSupplierName(){
$.ajax({
url: 'erp/supplier/getSupplier',
type: "post",
dataType: "json",
success: function (data) {
if (res.rows.length > 0) {
var usertData = res.rows;
//alert(JSON.stringify(data));
for (let i in usertData) {
// console.log(finishProductData[i].finishProductCode)
$("#form-purchaseQuote-add select[name='supplierName']").append(
"<option value='" + usertData[i].supplierName + "'>" + usertData[i].supplierName + "</option>");
}
} else {
$.modal.msgError(res.msg);
}
}
});
}
$("input[name='pricingDate']").datetimepicker({
format: "yyyy-mm-dd",
minView: "month",
autoclose: true
});
</script>
</body>
</html>

193
ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/edit.html

@ -13,102 +13,165 @@
<input name="purchaseQuoteCode" th:field="*{purchaseQuoteCode}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">采购员:</label>
<div class="col-sm-8">
<select name="purchaseBuyer" class="form-control m-b">
<option value="">所有</option>
</select>
<span class="help-block m-b-none"><i class="fa fa-info-circle"></i> 代码生成请选择字典属性</span>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">供应商ID:</label>
<div class="col-sm-8">
<input name="supplierQuoteCode" th:field="*{supplierQuoteCode}" class="form-control" type="text">
<select id="supplierCode" name="supplierCode" th:field="*{supplierCode}" class="form-control"></select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">供应商名称:</label>
<div class="col-sm-8">
<input name="supplierName" th:field="*{supplierName}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">税率:</label>
<div class="col-sm-8">
<input name="taxRate" th:field="*{taxRate}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料合计:</label>
<div class="col-sm-8">
<input name="materialAmount" th:field="*{materialAmount}" class="form-control" type="text">
<select name="supplierName" th:field="*{supplierName}" class="form-control"></select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">定价时间:</label>
<div class="col-sm-8">
<input name="pricingDate" th:field="*{pricingDate}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">料号:</label>
<div class="col-sm-8">
<input name="materialNo" th:field="*{materialNo}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">录入时间:</label>
<div class="col-sm-8">
<input name="firstAddTime" th:field="*{firstAddTime}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">修改时间:</label>
<div class="form-group">
<label class="col-sm-3 control-label">备注说明:</label>
<div class="col-sm-8">
<input name="updateInfoTime" th:field="*{updateInfoTime}" class="form-control" type="text">
<textarea name="remark" class="form-control" th:field="*{remark}"></textarea>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料名称:</label>
<div class="col-sm-8">
<input name="materialName" th:field="*{materialName}" class="form-control" type="text">
</div>
<div class="form-group">
<label class="col-sm-3 control-label" th:text="'附件'"></label>附件:</label>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">审核状态</label>
<div class="form-group">
<label class="col-sm-3 control-label">税率:</label>
<div class="col-sm-8">
<div class="radio-box" th:each="dict : ${@dict.getType('auditStatus')}">
<input type="radio" th:id="${'auditStatus_' + dict.dictCode}" name="auditStatus" th:value="${dict.dictValue}" th:field="*{auditStatus}">
<label th:for="${'auditStatus_' + dict.dictCode}" th:text="${dict.dictLabel}"></label>
</div>
<input name="taxRate" th:field="*{taxRate}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">使用状态:</label>
<div class="col-sm-8">
<div class="radio-box" th:each="dict : ${@dict.getType('useStatus')}">
<input type="radio" th:id="${'useStatus_' + dict.dictCode}" name="useStatus" th:value="${dict.dictValue}" th:field="*{useStatus}">
<label th:for="${'useStatus_' + dict.dictCode}" th:text="${dict.dictLabel}"></label>
</div>
</div>
</form>
<div class="container">
<div class="form-row">
<div class="btn-group-sm" id="toolbar" role="group">
<span>选择报价信息</span>
<a class="btn btn-success" onclick="insertRow()">
<i class="fa fa-plus"></i> 添加物料
</a>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">备注:</label>
<div class="col-sm-8">
<textarea name="remark" class="form-control">[[*{remark}]]</textarea>
<div class="row">
<div class="col-sm-12 select-table table-striped">
<table id="bootstrap-sub-table-purchaseQuoteChild"></table>
</div>
</div>
</form>
</div>
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var prefix = ctx + "purchase/purchaseQuote";
$("#form-purchaseQuote-edit").validate({
focusCleanup: true
$("#form-purchaseQuote-edit").validate({focusCleanup: true});
$(function() {
var options = {
id:'bootstrap-sub-table-requisitionChild',
// url: ctx + "system/quoteChild/list",
pagination: false,
sidePagination: "client",
model: "物料报价信息",
columns: [
{checkbox: true},
{field: 'index',align: 'center', title: "序号",
formatter: function (value, row, index) {
var columnIndex = $.common.sprintf("<input type='hidden' name='index' value='%s'>", $.table.serialNumber(index));
return columnIndex + $.table.serialNumber(index);
}
},
{title: '物料索引id',field: 'materialId',align: 'center',visible: false},
{title: '料号',field: 'materialCode',align: 'center'},
{title: '物料名称',field: 'materialName',align: 'center'},
{title: '图片',field: 'photoUrl',
formatter: function(value, row, index) {
return $.table.imageView(value);
}
},
{title: '物料类型',field: 'materialType',align: 'center',
formatter: function(value, row, index) {
return $.table.selectCategoryLabel(materialTypeDatas, value);
}
},
{ title: '描述',field: 'describe',align: 'center'},
{title: '品牌',field: 'brand',align: 'center'},
{ title: '单位',field: 'unit',align: 'center',
formatter: function(value, row, index) {
return $.table.selectDictLabel(sysUnitClassDatas, value);
}
},
{title: '加工方式',field: 'processMethod',align: 'center',
formatter: function(value, row, index) {
return $.table.selectDictLabel(processMethodDatas, value);
}
},
{title:'最新报价',field: 'materialSole',align: 'center',},
{title: '物料的数量', field: 'materialNum',align: 'center',editable: true,},
{title: '物料的不含税单价(RMB)',field: 'materialNoRmb',align: 'center',},
{title: '物料的含税单价(RMB)',field: 'materialRmb',align: 'center',},
{title: '录入人',field: 'createBy',align: 'center',visible: false},
{title: '录入时间',field: 'createTime',align: 'center',visible: false },
{title: '更新人',field: 'updateBy',align: 'center',visible: false},
{title: '上次更新时间',field: 'updateTime',align: 'center',visible: false},
{title: '备注',field: 'remark',align: 'center'},
{title: '操作', align: 'center',
formatter: function (value, row, index) {
var actions = [];
actions.push('<a class="btn btn-danger btn-xs" href="javascript:void(0)" onclick="removeRow(\'' + row.id + '\')"><i class="fa fa-remove"></i>删除</a> ');
return actions.join('');
}
}
],
};
$.table.init(options);
});
function doSubmit(index, layero,uniqueId){
console.log(uniqueId);
var iframeWin = window[layero.find('iframe')[0]['name']];
var rowData = iframeWin.$('#bootstrap-select-table').bootstrapTable('getSelections')[0];
console.log("rowData: "+rowData);
$("#bootstrap-sub-table-purchaseQuoteChild").bootstrapTable('insertRow', {
index:1,
row: {
materialId:rowData.id,
materialCode: rowData.materialNo,
materialName: rowData.materialName,
materialType: rowData.materialType,
describe: rowData.describe,
brand: rowData.brand,
unit: rowData.unit,
processMethod: rowData.processMethod,
photoUrl: rowData.photoUrl,
materialSole: '',
materialNum: 1,
materialRmb: "",
materialNoRmb: "",
materialNoRmbSum: "",
materialRmbSum: "",
remark: ""
}
})
layer.close(index);
}
function insertRow() {
var url = ctx + "erp/material/select";
var options = {
title: '选择料号',
url: url,
callBack: doSubmit
};
$.modal.openOptions(options);
}
/* 删除指定表格行 */
function removeRow(id){
$("#bootstrap-sub-table-requisitionChild").bootstrapTable('remove', {
field: 'id',
values: id
})
}
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/edit", $('#form-purchaseQuote-edit').serialize());

1
ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/purchaseQuote.html

@ -47,7 +47,6 @@
<label>采购员:</label>
<select name="purchaseBuyer">
<option value="">所有</option>
<option value="-1">代码生成请选择字典属性</option>
</select>
</li>
<li>

173
ruoyi-admin/src/main/resources/templates/system/empRequisiteOrder/add.html

@ -0,0 +1,173 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
<th:block th:include="include :: header('新增员工领料单')" />
</head>
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
<form class="form-horizontal m" id="form-empRequisiteOrder-add">
<div class="form-group">
<label class="col-sm-3 control-label">领料单编号:</label>
<div class="col-sm-8">
<input name="requisitieCode" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">关联销售订单号:</label>
<div class="col-sm-8">
<input name="correlationCode" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">用途:</label>
<div class="col-sm-8">
<input name="remark" class="form-control" type="text">
</div>
</div>
</form>
<div class="container">
<div class="form-row">
<div class="btn-group-sm" id="toolbar" role="group">
<span>选择报价信息</span>
<a class="btn btn-success" onclick="insertRow()">
<i class="fa fa-plus"></i> 添加物料
</a>
</div>
</div>
<div class="row">
<div class="col-sm-12 select-table table-striped">
<table id="bootstrap-sub-table-empRequisitionChild"></table>
</div>
</div>
</div>
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var materialTypeDatas = [[${@category.getChildByCode('materialType')}]];
var auditStatusDatas = [[${@dict.getType('auditStatus')}]];
var sysUnitClassDatas = [[${@dict.getType('sys_unit_class')}]];
var processMethodDatas = [[${@dict.getType('processMethod')}]];
var prefix = ctx + "system/empRequisiteOrder"
$("#form-empRequisiteOrder-add").validate({
focusCleanup: true
});
//获取子表信息
$(function() {
var options = {
id:'bootstrap-sub-table-empRequisitionChild',
pagination: false,
sidePagination: "client",
model: "物料报价信息",
columns: [
{checkbox: true},
{field: 'index',align: 'center', title: "序号",
formatter: function (value, row, index) {
var columnIndex = $.common.sprintf("<input type='hidden' name='index' value='%s'>", $.table.serialNumber(index));
return columnIndex + $.table.serialNumber(index);
}
},
{title: '物料索引id',field: 'materialId',align: 'center',visible: false},
{title: '料号',field: 'materialCode',align: 'center'},
{title: '物料名称',field: 'materialName',align: 'center'},
{title: '图片',field: 'photoUrl',
formatter: function(value, row, index) {
return $.table.imageView(value);
}
},
{title: '物料类型',field: 'materialType',align: 'center',
formatter: function(value, row, index) {
return $.table.selectCategoryLabel(materialTypeDatas, value);
}
},
{title: '型号',field: 'materialModel',align: 'center'},
{title: '规格',field: 'specification',align: 'center'},
{ title: '描述',field: 'describe',align: 'center'},
{title: '品牌',field: 'brand',align: 'center'},
{ title: '单位',field: 'unit',align: 'center',
formatter: function(value, row, index) {
return $.table.selectDictLabel(sysUnitClassDatas, value);
}
},
{title: '加工方式',field: 'processMethod',align: 'center',
formatter: function(value, row, index) {
return $.table.selectDictLabel(processMethodDatas, value);
}
},
{title: '物料的数量', field: 'materialNum',align: 'center',editable: true,},
{title: '物料的不含税单价(RMB)',field: 'materialNoRmb',align: 'center',},
{title: '物料的含税单价(RMB)',field: 'materialRmb',align: 'center',},
{title: '物料的含税总价(RMB)',field: 'materialNoRmbSum',align: 'center',},
{title: '物料的不含税总价(RMB)',field: 'materialRmbSum',align: 'center',},
{title: '录入人',field: 'createBy',align: 'center',visible: false},
{title: '录入时间',field: 'createTime',align: 'center',visible: false },
{title: '更新人',field: 'updateBy',align: 'center',visible: false},
{title: '上次更新时间',field: 'updateTime',align: 'center',visible: false},
{title: '备注',field: 'remark',align: 'center',editable: true},
{title: '操作', align: 'center',
formatter: function (value, row, index) {
var actions = [];
actions.push('<a class="btn btn-danger btn-xs" href="javascript:void(0)" onclick="removeRow(\'' + row.id + '\')"><i class="fa fa-remove"></i>删除</a> ');
return actions.join('');
}
}
],
onEditableSave:function(field, row, oldValue, $el){
row.materialNoRmbSum = Number(row.materialNum * Number(row.materialNoRmb)).toFixed(2);
row.materialRmbSum = Number(row.materialRmb * row.materialNum).toFixed(2);
},
};
$.table.init(options);
});
function doSubmit(index, layero,uniqueId){
console.log(uniqueId);
var iframeWin = window[layero.find('iframe')[0]['name']];
var rowData = iframeWin.$('#bootstrap-select-table').bootstrapTable('getSelections')[0];
console.log("rowData: "+rowData);
$("#bootstrap-sub-table-empRequisitionChild").bootstrapTable('insertRow', {
index:1,
row: {
materialId:rowData.id,
materialCode: rowData.materialNo,
materialName: rowData.materialName,
materialType: rowData.materialType,
describe: rowData.describe,
brand: rowData.brand,
unit: rowData.unit,
processMethod: rowData.processMethod,
photoUrl: rowData.photoUrl,
materialNum: "",
materialRmb: "",
materialNoRmb: "",
materialNoRmbSum: "",
materialRmbSum: "",
remark: ""
}
})
layer.close(index);
}
function insertRow() {
var url = ctx + "erp/material/select";
var options = {
title: '选择料号',
url: url,
callBack: doSubmit
};
$.modal.openOptions(options);
}
/* 删除指定表格行 */
function removeRow(id){
$("#bootstrap-sub-table-empRequisitionChild").bootstrapTable('remove', {
field: 'id',
values: id
})
}
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/add", $('#form-empRequisiteOrder-add').serialize());
}
}
</script>
</body>
</html>

171
ruoyi-admin/src/main/resources/templates/system/empRequisiteOrder/edit.html

@ -0,0 +1,171 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
<th:block th:include="include :: header('修改员工领料单')" />
</head>
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
<form class="form-horizontal m" id="form-empRequisiteOrder-edit" th:object="${baseEmpRequisiteOrder}">
<input name="requisiteId" th:field="*{requisiteId}" type="hidden">
<div class="form-group">
<label class="col-sm-3 control-label">领料单编号:</label>
<div class="col-sm-8">
<input name="requisitieCode" th:field="*{requisitieCode}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">关联销售订单号:</label>
<div class="col-sm-8">
<input name="correlationCode" th:field="*{correlationCode}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">用途:</label>
<div class="col-sm-8">
<input name="remark" th:field="*{remark}" class="form-control" type="text">
</div>
</div>
</form>
<div class="container">
<div class="form-row">
<div class="btn-group-sm" id="toolbar" role="group">
<span>选择报价信息</span>
<a class="btn btn-success" onclick="insertRow()">
<i class="fa fa-plus"></i> 添加物料
</a>
</div>
</div>
<div class="row">
<div class="col-sm-12 select-table table-striped">
<table id="bootstrap-sub-table-empRequisitionChild"></table>
</div>
</div>
</div>
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var materialTypeDatas = [[${@category.getChildByCode('materialType')}]];
var auditStatusDatas = [[${@dict.getType('auditStatus')}]];
var sysUnitClassDatas = [[${@dict.getType('sys_unit_class')}]];
var processMethodDatas = [[${@dict.getType('processMethod')}]];
var prefix = ctx + "system/empRequisiteOrder"
var prefix = ctx + "system/empRequisiteOrder";
$("#form-empRequisiteOrder-edit").validate({focusCleanup: true});
//获取子表信息
$(function() {
var options = {
id:'bootstrap-sub-table-empRequisitionChild',
pagination: false,
sidePagination: "client",
model: "物料报价信息",
columns: [
{checkbox: true},
{field: 'index',align: 'center', title: "序号",
formatter: function (value, row, index) {
var columnIndex = $.common.sprintf("<input type='hidden' name='index' value='%s'>", $.table.serialNumber(index));
return columnIndex + $.table.serialNumber(index);
}
},
{title: '物料索引id',field: 'materialId',align: 'center',visible: false},
{title: '料号',field: 'materialCode',align: 'center'},
{title: '物料名称',field: 'materialName',align: 'center'},
{title: '图片',field: 'photoUrl',
formatter: function(value, row, index) {
return $.table.imageView(value);
}
},
{title: '物料类型',field: 'materialType',align: 'center',
formatter: function(value, row, index) {
return $.table.selectCategoryLabel(materialTypeDatas, value);
}
},
{title: '型号',field: 'materialModel',align: 'center'},
{title: '规格',field: 'specification',align: 'center'},
{ title: '描述',field: 'describe',align: 'center'},
{title: '品牌',field: 'brand',align: 'center'},
{ title: '单位',field: 'unit',align: 'center',
formatter: function(value, row, index) {
return $.table.selectDictLabel(sysUnitClassDatas, value);
}
},
{title: '加工方式',field: 'processMethod',align: 'center',
formatter: function(value, row, index) {
return $.table.selectDictLabel(processMethodDatas, value);
}
},
{title: '物料的数量', field: 'materialNum',align: 'center',editable: true,},
{title: '物料的不含税单价(RMB)',field: 'materialNoRmb',align: 'center',},
{title: '物料的含税单价(RMB)',field: 'materialRmb',align: 'center',},
{title: '物料的含税总价(RMB)',field: 'materialNoRmbSum',align: 'center',},
{title: '物料的不含税总价(RMB)',field: 'materialRmbSum',align: 'center',},
{title: '录入人',field: 'createBy',align: 'center',visible: false},
{title: '录入时间',field: 'createTime',align: 'center',visible: false },
{title: '更新人',field: 'updateBy',align: 'center',visible: false},
{title: '上次更新时间',field: 'updateTime',align: 'center',visible: false},
{title: '备注',field: 'remark',align: 'center',editable: true},
{title: '操作', align: 'center',
formatter: function (value, row, index) {
var actions = [];
actions.push('<a class="btn btn-danger btn-xs" href="javascript:void(0)" onclick="removeRow(\'' + row.id + '\')"><i class="fa fa-remove"></i>删除</a> ');
return actions.join('');
}
}
],
onEditableSave:function(field, row, oldValue, $el){
row.materialNoRmbSum = Number(row.materialNum * Number(row.materialNoRmb)).toFixed(2);
row.materialRmbSum = Number(row.materialRmb * row.materialNum).toFixed(2);
},
};
$.table.init(options);
});
function doSubmit(index, layero,uniqueId){
console.log(uniqueId);
var iframeWin = window[layero.find('iframe')[0]['name']];
var rowData = iframeWin.$('#bootstrap-select-table').bootstrapTable('getSelections')[0];
console.log("rowData: "+rowData);
$("#bootstrap-sub-table-empRequisitionChild").bootstrapTable('insertRow', {
index:1,
row: {
materialId:rowData.id,
materialCode: rowData.materialNo,
materialName: rowData.materialName,
materialType: rowData.materialType,
describe: rowData.describe,
brand: rowData.brand,
unit: rowData.unit,
processMethod: rowData.processMethod,
photoUrl: rowData.photoUrl,
materialNum: "",
materialRmb: "",
materialNoRmb: "",
materialNoRmbSum: "",
materialRmbSum: "",
remark: ""
}
})
layer.close(index);
}
function insertRow() {
var url = ctx + "erp/material/select";
var options = {
title: '选择料号',
url: url,
callBack: doSubmit
};
$.modal.openOptions(options);
}
/* 删除指定表格行 */
function removeRow(id){
$("#bootstrap-sub-table-empRequisitionChild").bootstrapTable('remove', {
field: 'id',
values: id
})
}
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/edit", $('#form-empRequisiteOrder-edit').serialize());
}
}
</script>
</body>
</html>

161
ruoyi-admin/src/main/resources/templates/system/empRequisiteOrder/empRequisiteOrder.html

@ -0,0 +1,161 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head>
<th:block th:include="include :: header('员工领料单列表')" />
</head>
<body class="gray-bg">
<div class="container-div">
<div class="row">
<div class="col-sm-12 search-collapse">
<form id="formId">
<div class="select-list">
<ul>
<li>
<label>领料单单号:</label>
<input type="text" name="requisitieCode"/>
</li>
<li>
<label>关联单号:</label>
<input type="text" name="correlationCode"/>
</li>
<li>
<label>创建人:</label>
<input type="text" name="applyUser"/>
</li>
<li>
<label>录入时间:</label>
<input type="text" class="time-input" id="startTime" placeholder="开始时间" name="params[beginCreateTime1]"/>
<span>-</span>
<input type="text" class="time-input" id="endTime" placeholder="结束时间" name="params[endCreateTime1]"/>
</li>
<li>
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i>&nbsp;搜索</a>
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i>&nbsp;重置</a>
</li>
</ul>
</div>
</form>
</div>
<div class="btn-group-sm" id="toolbar" role="group">
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="system:empRequisiteOrder:add">
<i class="fa fa-plus"></i> 添加
</a>
<a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="system:empRequisiteOrder:edit">
<i class="fa fa-edit"></i> 修改
</a>
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="system:empRequisiteOrder:remove">
<i class="fa fa-remove"></i> 删除
</a>
<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="system:empRequisiteOrder:export">
<i class="fa fa-download"></i> 导出
</a>
</div>
<div class="col-sm-12 select-table table-striped">
<table id="bootstrap-table"></table>
</div>
</div>
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var editFlag = [[${@permission.hasPermi('system:empRequisiteOrder:edit')}]];
var removeFlag = [[${@permission.hasPermi('system:empRequisiteOrder:remove')}]];
var cancelFlag = [[${@permission.hasPermi('system:empRequisiteOrder:cancel')}]];
var restoreFlag = [[${@permission.hasPermi('system:empRequisiteOrder:restore')}]];
var auditStatusDatas = [[${@dict.getType('auditStatus')}]];
var requisitieStatusDatas = [[${@dict.getType('pickStatus')}]];
var useStatusDatas = [[${@dict.getType('useStatus')}]];
var prefix = ctx + "system/empRequisiteOrder";
$(function() {
var options = {
url: prefix + "/list",
createUrl: prefix + "/add",
updateUrl: prefix + "/edit/{id}",
removeUrl: prefix + "/remove",
cancelUrl: prefix + "/cancel/{id}",
restoreUrl: prefix + "/restore/{id}",
exportUrl: prefix + "/export",
modalName: "员工领料单",
columns: [{
checkbox: true
},
{
title: '员工号领料单索引id',
field: 'requisiteId',
visible: false
},
{
title: '审核状态',
field: 'auditStatus',
formatter: function(value, row, index) {
return $.table.selectDictLabel(auditStatusDatas, value);
}
},
{
title: '领料状态',
field: 'requisitieStatus',
formatter: function(value, row, index) {
return $.table.selectDictLabel(requisitieStatusDatas, value);
}
},
{
title: '领料单编号',
field: 'requisitieCode',
},
{
title: '关联销售订单号',
field: 'correlationCode',
},
{
title: '物料合计',
field: 'materialAmount',
},
{
title: '数量总计',
field: 'materialSum',
},
{
title: '不含税总价(RMB)',
field: 'noRmbSum',
},
{
title: '含税总价(RMB)',
field: 'rmbSum',
},
{
title: '申请人',
field: 'applyUser',
},
{
title: '备注',
field: 'remark',
},
{
title: '使用状态',
field: 'useStatus',
formatter: function(value, row, index) {
return $.table.selectDictLabel(useStatusDatas, value);
}
},
{
title: '操作',
align: 'center',
formatter: function(value, row, index) {
var actions = [];
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.requisiteId + '\')"><i class="fa fa-edit"></i>编辑</a> ');
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.requisiteId + '\')"><i class="fa fa-remove"></i>删除</a> ');
if(row.delFlag == '0'){
actions.push('<a class="btn btn-danger btn-xs ' + cancelFlag + '" href="javascript:void(0)" onclick="$.operate.cancel(\'' + row.id + '\')"><i class="fa fa-remove"></i>作废</a> ');
}else{
actions.push('<a class="btn btn-success btn-xs ' + restoreFlag + '" href="javascript:void(0)" onclick="$.operate.restore(\'' + row.id + '\')"><i class="fa fa-window-restore"></i>恢复</a> ');
}
return actions.join('');
}
}]
};
$.table.init(options);
});
</script>
</body>
</html>

144
ruoyi-admin/src/main/resources/templates/system/requesitioningChild/add.html

@ -0,0 +1,144 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
<th:block th:include="include :: header('新增请购单')" />
</head>
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
<form class="form-horizontal m" id="form-requesitioningChild-add">
<div class="form-group">
<label class="col-sm-3 control-label">关联请购单编号字段:</label>
<div class="col-sm-8">
<input name="quoteId" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料表中的id:</label>
<div class="col-sm-8">
<input name="materialId" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">料号:</label>
<div class="col-sm-8">
<input name="materialCode" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料的图片:</label>
<div class="col-sm-8">
<input name="photoUrl" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料的名称:</label>
<div class="col-sm-8">
<input name="materialName" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料的类型:</label>
<div class="col-sm-8">
<select name="materialType" class="form-control m-b">
<option value="">所有</option>
</select>
<span class="help-block m-b-none"><i class="fa fa-info-circle"></i> 代码生成请选择字典属性</span>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料的型号:</label>
<div class="col-sm-8">
<input name="materialModel" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料的规格:</label>
<div class="col-sm-8">
<input name="specifications" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料的品牌:</label>
<div class="col-sm-8">
<input name="brand" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料的描述:</label>
<div class="col-sm-8">
<input name="describe" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料的数量:</label>
<div class="col-sm-8">
<input name="materialNum" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料的不含税单价(RMB):</label>
<div class="col-sm-8">
<input name="materialRmb" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料的含税单价(RMB):</label>
<div class="col-sm-8">
<input name="materialNoRmb" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料的含税总价(RMB):</label>
<div class="col-sm-8">
<input name="materialNoRmbSum" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料的不含税总价(RMB):</label>
<div class="col-sm-8">
<input name="materialRmbSum" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">备注:</label>
<div class="col-sm-8">
<textarea name="remark" class="form-control"></textarea>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">删除状态:</label>
<div class="col-sm-8">
<div class="radio-box">
<input type="radio" name="useStatus" value="">
<label th:for="useStatus" th:text="未知"></label>
</div>
<span class="help-block m-b-none"><i class="fa fa-info-circle"></i> 代码生成请选择字典属性</span>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">审核状态:</label>
<div class="col-sm-8">
<div class="radio-box">
<input type="radio" name="auditStatus" value="">
<label th:for="auditStatus" th:text="未知"></label>
</div>
<span class="help-block m-b-none"><i class="fa fa-info-circle"></i> 代码生成请选择字典属性</span>
</div>
</div>
</form>
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var prefix = ctx + "system/requesitioningChild"
$("#form-requesitioningChild-add").validate({
focusCleanup: true
});
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/add", $('#form-requesitioningChild-add').serialize());
}
}
</script>
</body>
</html>

145
ruoyi-admin/src/main/resources/templates/system/requesitioningChild/edit.html

@ -0,0 +1,145 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
<th:block th:include="include :: header('修改请购单')" />
</head>
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
<form class="form-horizontal m" id="form-requesitioningChild-edit" th:object="${baseRequisitioningOrderChild}">
<input name="requisitioningChildId" th:field="*{requisitioningChildId}" type="hidden">
<div class="form-group">
<label class="col-sm-3 control-label">关联请购单编号字段:</label>
<div class="col-sm-8">
<input name="quoteId" th:field="*{quoteId}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料表中的id:</label>
<div class="col-sm-8">
<input name="materialId" th:field="*{materialId}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">料号:</label>
<div class="col-sm-8">
<input name="materialCode" th:field="*{materialCode}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料的图片:</label>
<div class="col-sm-8">
<input name="photoUrl" th:field="*{photoUrl}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料的名称:</label>
<div class="col-sm-8">
<input name="materialName" th:field="*{materialName}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料的类型:</label>
<div class="col-sm-8">
<select name="materialType" class="form-control m-b">
<option value="">所有</option>
</select>
<span class="help-block m-b-none"><i class="fa fa-info-circle"></i> 代码生成请选择字典属性</span>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料的型号:</label>
<div class="col-sm-8">
<input name="materialModel" th:field="*{materialModel}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料的规格:</label>
<div class="col-sm-8">
<input name="specifications" th:field="*{specifications}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料的品牌:</label>
<div class="col-sm-8">
<input name="brand" th:field="*{brand}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料的描述:</label>
<div class="col-sm-8">
<input name="describe" th:field="*{describe}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料的数量:</label>
<div class="col-sm-8">
<input name="materialNum" th:field="*{materialNum}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料的不含税单价(RMB):</label>
<div class="col-sm-8">
<input name="materialRmb" th:field="*{materialRmb}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料的含税单价(RMB):</label>
<div class="col-sm-8">
<input name="materialNoRmb" th:field="*{materialNoRmb}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料的含税总价(RMB):</label>
<div class="col-sm-8">
<input name="materialNoRmbSum" th:field="*{materialNoRmbSum}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">物料的不含税总价(RMB):</label>
<div class="col-sm-8">
<input name="materialRmbSum" th:field="*{materialRmbSum}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">备注:</label>
<div class="col-sm-8">
<textarea name="remark" class="form-control">[[*{remark}]]</textarea>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">删除状态:</label>
<div class="col-sm-8">
<div class="radio-box">
<input type="radio" name="useStatus" value="">
<label th:for="useStatus" th:text="未知"></label>
</div>
<span class="help-block m-b-none"><i class="fa fa-info-circle"></i> 代码生成请选择字典属性</span>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">审核状态:</label>
<div class="col-sm-8">
<div class="radio-box">
<input type="radio" name="auditStatus" value="">
<label th:for="auditStatus" th:text="未知"></label>
</div>
<span class="help-block m-b-none"><i class="fa fa-info-circle"></i> 代码生成请选择字典属性</span>
</div>
</div>
</form>
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var prefix = ctx + "system/requesitioningChild";
$("#form-requesitioningChild-edit").validate({
focusCleanup: true
});
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/edit", $('#form-requesitioningChild-edit').serialize());
}
}
</script>
</body>
</html>

250
ruoyi-admin/src/main/resources/templates/system/requesitioningChild/requesitioningChild.html

@ -0,0 +1,250 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head>
<th:block th:include="include :: header('请购单列表')" />
</head>
<body class="gray-bg">
<div class="container-div">
<div class="row">
<div class="col-sm-12 search-collapse">
<form id="formId">
<div class="select-list">
<ul>
<li>
<label>关联请购单编号字段:</label>
<input type="text" name="quoteId"/>
</li>
<li>
<label>物料表中的id:</label>
<input type="text" name="materialId"/>
</li>
<li>
<label>料号:</label>
<input type="text" name="materialCode"/>
</li>
<li>
<label>物料的图片:</label>
<input type="text" name="photoUrl"/>
</li>
<li>
<label>物料的名称:</label>
<input type="text" name="materialName"/>
</li>
<li>
<label>物料的类型:</label>
<select name="materialType">
<option value="">所有</option>
<option value="-1">代码生成请选择字典属性</option>
</select>
</li>
<li>
<label>物料的型号:</label>
<input type="text" name="materialModel"/>
</li>
<li>
<label>物料的规格:</label>
<input type="text" name="specifications"/>
</li>
<li>
<label>物料的品牌:</label>
<input type="text" name="brand"/>
</li>
<li>
<label>物料的描述:</label>
<input type="text" name="describe"/>
</li>
<li>
<label>物料的数量:</label>
<input type="text" name="materialNum"/>
</li>
<li>
<label>物料的不含税单价(RMB):</label>
<input type="text" name="materialRmb"/>
</li>
<li>
<label>物料的含税单价(RMB):</label>
<input type="text" name="materialNoRmb"/>
</li>
<li>
<label>物料的含税总价(RMB):</label>
<input type="text" name="materialNoRmbSum"/>
</li>
<li>
<label>物料的不含税总价(RMB):</label>
<input type="text" name="materialRmbSum"/>
</li>
<li>
<label>创建人:</label>
<input type="text" name="createBy"/>
</li>
<li class="select-time">
<label>创建时间:</label>
<input type="text" class="time-input" id="startTime" placeholder="开始时间" name="params[beginCreateTime]"/>
<span>-</span>
<input type="text" class="time-input" id="endTime" placeholder="结束时间" name="params[endCreateTime]"/>
</li>
<li>
<label>修改人:</label>
<input type="text" name="updateBy"/>
</li>
<li>
<label>删除状态:</label>
<select name="useStatus">
<option value="">所有</option>
<option value="-1">代码生成请选择字典属性</option>
</select>
</li>
<li>
<label>审核状态:</label>
<select name="auditStatus">
<option value="">所有</option>
<option value="-1">代码生成请选择字典属性</option>
</select>
</li>
<li>
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i>&nbsp;搜索</a>
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i>&nbsp;重置</a>
</li>
</ul>
</div>
</form>
</div>
<div class="btn-group-sm" id="toolbar" role="group">
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="requesitioningChild:requesitioningChild:add">
<i class="fa fa-plus"></i> 添加
</a>
<a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="requesitioningChild:requesitioningChild:edit">
<i class="fa fa-edit"></i> 修改
</a>
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="requesitioningChild:requesitioningChild:remove">
<i class="fa fa-remove"></i> 删除
</a>
<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="requesitioningChild:requesitioningChild:export">
<i class="fa fa-download"></i> 导出
</a>
</div>
<div class="col-sm-12 select-table table-striped">
<table id="bootstrap-table"></table>
</div>
</div>
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var editFlag = [[${@permission.hasPermi('requesitioningChild:requesitioningChild:edit')}]];
var removeFlag = [[${@permission.hasPermi('requesitioningChild:requesitioningChild:remove')}]];
var cancelFlag = [[${@permission.hasPermi('requesitioningChild:requesitioningChild:cancel')}]];
var restoreFlag = [[${@permission.hasPermi('requesitioningChild:requesitioningChild:restore')}]];
var prefix = ctx + "system/requesitioningChild";
$(function() {
var options = {
url: prefix + "/list",
createUrl: prefix + "/add",
updateUrl: prefix + "/edit/{id}",
removeUrl: prefix + "/remove",
cancelUrl: prefix + "/cancel/{id}",
restoreUrl: prefix + "/restore/{id}",
exportUrl: prefix + "/export",
modalName: "请购单",
columns: [{
checkbox: true
},
{
title: '客户报价子表id',
field: 'requisitioningChildId',
visible: false
},
{
title: '关联请购单编号字段',
field: 'quoteId',
},
{
title: '物料表中的id',
field: 'materialId',
},
{
title: '料号',
field: 'materialCode',
},
{
title: '物料的图片',
field: 'photoUrl',
},
{
title: '物料的名称',
field: 'materialName',
},
{
title: '物料的类型',
field: 'materialType',
},
{
title: '物料的型号',
field: 'materialModel',
},
{
title: '物料的规格',
field: 'specifications',
},
{
title: '物料的品牌',
field: 'brand',
},
{
title: '物料的描述',
field: 'describe',
},
{
title: '物料的数量',
field: 'materialNum',
},
{
title: '物料的不含税单价(RMB)',
field: 'materialRmb',
},
{
title: '物料的含税单价(RMB)',
field: 'materialNoRmb',
},
{
title: '物料的含税总价(RMB)',
field: 'materialNoRmbSum',
},
{
title: '物料的不含税总价(RMB)',
field: 'materialRmbSum',
},
{
title: '备注',
field: 'remark',
},
{
title: '删除状态',
field: 'useStatus',
},
{
title: '审核状态',
field: 'auditStatus',
},
{
title: '操作',
align: 'center',
formatter: function(value, row, index) {
var actions = [];
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.requisitioningChildId + '\')"><i class="fa fa-edit"></i>编辑</a> ');
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.requisitioningChildId + '\')"><i class="fa fa-remove"></i>删除</a> ');
if(row.delFlag == '0'){
actions.push('<a class="btn btn-danger btn-xs ' + cancelFlag + '" href="javascript:void(0)" onclick="$.operate.cancel(\'' + row.id + '\')"><i class="fa fa-remove"></i>作废</a> ');
}else{
actions.push('<a class="btn btn-success btn-xs ' + restoreFlag + '" href="javascript:void(0)" onclick="$.operate.restore(\'' + row.id + '\')"><i class="fa fa-window-restore"></i>恢复</a> ');
}
return actions.join('');
}
}]
};
$.table.init(options);
});
</script>
</body>
</html>

9
ruoyi-admin/src/main/resources/templates/system/requisitioning/add.html

@ -15,13 +15,13 @@
<div class="form-group">
<label class="col-sm-3 control-label">岗位:</label>
<div class="col-sm-8">
<select name="" class="form-control"></select>
<select name="post" class="form-control"></select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">姓名:</label>
<div class="col-sm-8">
<select name="post" class="form-control"></select>
<select name="userName" class="form-control"></select>
</div>
</div>
<div class="form-group">
@ -59,7 +59,6 @@
$(function() {
var options = {
id:'bootstrap-sub-table-requisitionChild',
// url: ctx + "system/quoteChild/list",
pagination: false,
sidePagination: "client",
model: "物料报价信息",
@ -84,6 +83,8 @@
return $.table.selectCategoryLabel(materialTypeDatas, value);
}
},
{title: '型号',field: 'materialModel',align: 'center'},
{title: '规格',field: 'specification',align: 'center'},
{ title: '描述',field: 'describe',align: 'center'},
{title: '品牌',field: 'brand',align: 'center'},
{ title: '单位',field: 'unit',align: 'center',
@ -115,8 +116,6 @@
}
],
onEditableSave:function(field, row, oldValue, $el){
row.materialNoRmb = Number(row.materialNoRmb).toFixed(2);
row.materialRmb = Number(row.materialNoRmb * Number(1));
row.materialNoRmbSum = Number(row.materialNum * Number(row.materialNoRmb)).toFixed(2);
row.materialRmbSum = Number(row.materialRmb * row.materialNum).toFixed(2);
},

17
ruoyi-admin/src/main/resources/templates/system/requisitioning/edit.html

@ -22,13 +22,13 @@
<div class="form-group">
<label class="col-sm-3 control-label">岗位:</label>
<div class="col-sm-8">
<select name="" class="form-control"></select>
<select name="post" class="form-control"></select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">姓名:</label>
<div class="col-sm-8">
<select name="post" class="form-control"></select>
<select name="username" class="form-control"></select>
</div>
</div>
<div class="form-group">
@ -117,8 +117,6 @@
}
],
onEditableSave:function(field, row, oldValue, $el){
row.materialNoRmb = Number(row.materialNoRmb).toFixed(2);
row.materialRmb = Number(row.materialNoRmb * Number(1));
row.materialNoRmbSum = Number(row.materialNum * Number(row.materialNoRmb)).toFixed(2);
row.materialRmbSum = Number(row.materialRmb * row.materialNum).toFixed(2);
},
@ -173,6 +171,17 @@
$.operate.save(prefix + "/edit", $('#form-requisitioning-edit').serialize());
}
}
function getDeptSelect(){
}
function getPostSelect(){
}
function getUserName(){
}
</script>
</body>
</html>
Loading…
Cancel
Save