Browse Source

Merge remote-tracking branch 'origin/dev' into dev

dev
zhangsiqi 7 months ago
parent
commit
b7c17c5c3f
  1. 177
      ruoyi-admin/src/main/java/com/ruoyi/erp/controller/ErpDevelopModifyorderController.java
  2. 169
      ruoyi-admin/src/main/java/com/ruoyi/erp/domain/ErpDevelopModifyorder.java
  3. 77
      ruoyi-admin/src/main/java/com/ruoyi/erp/mapper/ErpDevelopModifyorderMapper.java
  4. 75
      ruoyi-admin/src/main/java/com/ruoyi/erp/service/IErpDevelopModifyorderService.java
  5. 126
      ruoyi-admin/src/main/java/com/ruoyi/erp/service/impl/ErpDevelopModifyorderServiceImpl.java
  6. 148
      ruoyi-admin/src/main/java/com/ruoyi/system/controller/developReviseOrderController.java
  7. 78
      ruoyi-admin/src/main/java/com/ruoyi/system/mapper/DevelopReviseOrderMapper.java
  8. 76
      ruoyi-admin/src/main/java/com/ruoyi/system/service/IDevelopReviseOrderService.java
  9. 65
      ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/DevelopReviseOrderServiceImpl.java
  10. 158
      ruoyi-admin/src/main/resources/mapper/erp/ErpDevelopModifyorderMapper.xml
  11. 147
      ruoyi-admin/src/main/resources/mapper/system/DevelopReviseorderMapper.xml
  12. 166
      ruoyi-admin/src/main/resources/templates/erp/developModifyOrder/add.html
  13. 148
      ruoyi-admin/src/main/resources/templates/erp/developModifyOrder/detail.html
  14. 229
      ruoyi-admin/src/main/resources/templates/erp/developModifyOrder/developModifyOrder.html
  15. 148
      ruoyi-admin/src/main/resources/templates/erp/developModifyOrder/edit.html
  16. 1
      ruoyi-admin/src/main/resources/templates/sales/afterSalesNotice/add.html
  17. 1
      ruoyi-admin/src/main/resources/templates/sales/afterSalesNotice/edit.html
  18. 133
      ruoyi-admin/src/main/resources/templates/system/developReviseOrder/add.html
  19. 164
      ruoyi-admin/src/main/resources/templates/system/developReviseOrder/developReviseOrder.html
  20. 50
      ruoyi-admin/src/main/resources/templates/system/developReviseOrder/edit.html
  21. 6
      ruoyi-system/src/main/java/com/ruoyi/system/mapper/SysUserMapper.java
  22. 7
      ruoyi-system/src/main/java/com/ruoyi/system/service/ISysUserService.java
  23. 11
      ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysUserServiceImpl.java
  24. 8
      ruoyi-system/src/main/resources/mapper/system/SysUserMapper.xml

177
ruoyi-admin/src/main/java/com/ruoyi/erp/controller/ErpDevelopModifyorderController.java

@ -0,0 +1,177 @@
package com.ruoyi.erp.controller;
import java.util.List;
import com.ruoyi.common.core.domain.entity.SysUser;
import com.ruoyi.system.service.ISysUserService;
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.erp.domain.ErpDevelopModifyorder;
import com.ruoyi.erp.service.IErpDevelopModifyorderService;
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 刘晓旭
* @date 2024-04-18
*/
@Controller
@RequestMapping("/erp/developModifyOrder")
public class ErpDevelopModifyorderController extends BaseController
{
private String prefix = "erp/developModifyOrder";
@Autowired
private ISysUserService sysUserService;
@Autowired
private IErpDevelopModifyorderService erpDevelopModifyorderService;
@RequiresPermissions("erp:developModifyOrder:view")
@GetMapping()
public String developModifyOrder()
{
return prefix + "/developModifyOrder";
}
/**
* 查询开发修改单列表
*/
@RequiresPermissions("erp:developModifyOrder:list")
@PostMapping("/list")
@ResponseBody
public TableDataInfo list(ErpDevelopModifyorder erpDevelopModifyorder)
{
startPage();
List<ErpDevelopModifyorder> list = erpDevelopModifyorderService.selectErpDevelopModifyorderList(erpDevelopModifyorder);
return getDataTable(list);
}
/**
* 查找所有的工程员
* */
@ResponseBody
@PostMapping("/getEngineerList")
public AjaxResult getEngineerList(String roleKey){
List<SysUser> engineerList = sysUserService.getSpecificRoleList(roleKey);
return AjaxResult.success(engineerList);
}
/**
* 导出开发修改单列表
*/
@RequiresPermissions("erp:developModifyOrder:export")
@Log(title = "开发修改单", businessType = BusinessType.EXPORT)
@PostMapping("/export")
@ResponseBody
public AjaxResult export(ErpDevelopModifyorder erpDevelopModifyorder)
{
List<ErpDevelopModifyorder> list = erpDevelopModifyorderService.selectErpDevelopModifyorderList(erpDevelopModifyorder);
ExcelUtil<ErpDevelopModifyorder> util = new ExcelUtil<ErpDevelopModifyorder>(ErpDevelopModifyorder.class);
return util.exportExcel(list, "开发修改单数据");
}
/**
* 新增开发修改单
*/
@GetMapping("/add")
public String add()
{
return prefix + "/add";
}
/**
* 新增保存开发修改单
*/
@RequiresPermissions("erp:developModifyOrder:add")
@Log(title = "开发修改单", businessType = BusinessType.INSERT)
@PostMapping("/add")
@ResponseBody
public AjaxResult addSave(ErpDevelopModifyorder erpDevelopModifyorder)
{
return toAjax(erpDevelopModifyorderService.insertErpDevelopModifyorder(erpDevelopModifyorder));
}
/**
* 修改开发修改单
*/
@GetMapping("/edit/{developOrderId}")
public String edit(@PathVariable("developOrderId") Long developOrderId, ModelMap mmap)
{
ErpDevelopModifyorder erpDevelopModifyorder = erpDevelopModifyorderService.selectErpDevelopModifyorderById(developOrderId);
mmap.put("erpDevelopModifyorder", erpDevelopModifyorder);
return prefix + "/edit";
}
/**
* 修改保存开发修改单
*/
@RequiresPermissions("erp:developModifyOrder:edit")
@Log(title = "开发修改单", businessType = BusinessType.UPDATE)
@PostMapping("/edit")
@ResponseBody
public AjaxResult editSave(ErpDevelopModifyorder erpDevelopModifyorder)
{
return toAjax(erpDevelopModifyorderService.updateErpDevelopModifyorder(erpDevelopModifyorder));
}
/**
* 查看开发修改单详情
* */
@GetMapping("/detail/{developOrderId}")
public String detail(@PathVariable("developOrderId") Long developOrderId, ModelMap mmap){
ErpDevelopModifyorder erpDevelopModifyorder = erpDevelopModifyorderService.selectErpDevelopModifyorderById(developOrderId);
mmap.put("erpDevelopModifyorder",erpDevelopModifyorder);
return prefix+ "/detail";
}
/**
* 删除开发修改单
*/
@RequiresPermissions("erp:developModifyOrder:remove")
@Log(title = "开发修改单", businessType = BusinessType.DELETE)
@PostMapping( "/remove")
@ResponseBody
public AjaxResult remove(String ids)
{
return toAjax(erpDevelopModifyorderService.deleteErpDevelopModifyorderByIds(ids));
}
/**
* 作废开发修改单
*/
@RequiresPermissions("erp:developModifyOrder:cancel")
@Log(title = "开发修改单", businessType = BusinessType.CANCEL)
@GetMapping( "/cancel/{id}")
@ResponseBody
public AjaxResult cancel(@PathVariable("id") Long id){
return toAjax(erpDevelopModifyorderService.cancelErpDevelopModifyorderById(id));
}
/**
* 恢复开发修改单
*/
@RequiresPermissions("erp:developModifyOrder:restore")
@Log(title = "开发修改单", businessType = BusinessType.RESTORE)
@GetMapping( "/restore/{id}")
@ResponseBody
public AjaxResult restore(@PathVariable("id")Long id)
{
return toAjax(erpDevelopModifyorderService.restoreErpDevelopModifyorderById(id));
}
}

169
ruoyi-admin/src/main/java/com/ruoyi/system/domain/DevelopReviseOrder.java → ruoyi-admin/src/main/java/com/ruoyi/erp/domain/ErpDevelopModifyorder.java

@ -1,25 +1,25 @@
package com.ruoyi.system.domain;
package com.ruoyi.erp.domain;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
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;
/**
* 开发修改单对象 develop_reviseorder
* 开发修改单对象 erp_develop_modifyorder
*
* @author ruoyi
* @date 2023-12-12
* @author 刘晓旭
* @date 2024-04-18
*/
public class DevelopReviseOrder extends BaseEntity
public class ErpDevelopModifyorder extends BaseEntity
{
private static final long serialVersionUID = 1L;
/** 开发修改单编号 */
private Long oderId;
/** 开发修改单ID */
private Long developOrderId;
/** 开发修改单号 */
@Excel(name = "开发修改单号")
/** 开发修改单号 */
@Excel(name = "开发修改单号")
private String developOderCode;
/** 料号 */
@ -28,7 +28,7 @@ public class DevelopReviseOrder extends BaseEntity
/** 采购入库状态 */
@Excel(name = "采购入库状态")
private String eceiptStatus;
private String purchaseStorageStatus;
/** 品质状态 */
@Excel(name = "品质状态")
@ -38,12 +38,18 @@ public class DevelopReviseOrder extends BaseEntity
@Excel(name = "审核状态")
private String auditStatus;
/** 完成状态 */
/** 确认状态 */
@Excel(name = "确认状态")
private String completeStatus;
/** 完成状态 */
@Excel(name = "完成状态")
private String finshStatus;
/** 使用状态 */
@Excel(name = "使用状态")
private String useStatus;
/** 物料名称 */
@Excel(name = "物料名称")
private String materialName;
@ -52,41 +58,49 @@ public class DevelopReviseOrder extends BaseEntity
@Excel(name = "物料类型")
private String materialType;
/** 图片 */
@Excel(name = "图片")
private String materialPhotoUrl;
/** 单位 */
@Excel(name = "单位")
private String unit;
/** 图片地址 */
@Excel(name = "图片地址")
private String photoUrl;
private String materialUnit;
/** 品牌 */
@Excel(name = "品牌")
private String brand;
private String materialBrand;
/** 描述 */
@Excel(name = "描述")
private String describe;
private String materialDescribe;
/** 加工方式 */
@Excel(name = "加工方式")
private String processMethod;
private String materialProcessMode;
/** 工程员 */
@Excel(name = "工程员")
private Long userId;
/** 工程员姓名 */
@Excel(name = "工程员姓名")
private String userName;
public void setOderId(Long oderId)
public void setDevelopOrderId(Long developOrderId)
{
this.oderId = oderId;
this.developOrderId = developOrderId;
}
public Long getOderId()
public Long getDevelopOrderId()
{
return oderId;
return developOrderId;
}
public void setDevelopOderCode(String developOderCode)
public void setDevelopOderCode(String developOderCode)
{
this.developOderCode = developOderCode;
}
public String getDevelopOderCode()
public String getDevelopOderCode()
{
return developOderCode;
}
@ -99,14 +113,14 @@ public class DevelopReviseOrder extends BaseEntity
{
return materialNo;
}
public void setEceiptStatus(String eceiptStatus)
public void setPurchaseStorageStatus(String purchaseStorageStatus)
{
this.eceiptStatus = eceiptStatus;
this.purchaseStorageStatus = purchaseStorageStatus;
}
public String getEceiptStatus()
public String getPurchaseStorageStatus()
{
return eceiptStatus;
return purchaseStorageStatus;
}
public void setQualityStatus(String qualityStatus)
{
@ -135,6 +149,24 @@ public class DevelopReviseOrder extends BaseEntity
{
return completeStatus;
}
public void setFinshStatus(String finshStatus)
{
this.finshStatus = finshStatus;
}
public String getFinshStatus()
{
return finshStatus;
}
public void setUseStatus(String useStatus)
{
this.useStatus = useStatus;
}
public String getUseStatus()
{
return useStatus;
}
public void setMaterialName(String materialName)
{
this.materialName = materialName;
@ -153,80 +185,93 @@ public class DevelopReviseOrder extends BaseEntity
{
return materialType;
}
public void setUnit(String unit)
public void setMaterialPhotoUrl(String materialPhotoUrl)
{
this.unit = unit;
this.materialPhotoUrl = materialPhotoUrl;
}
public String getUnit()
public String getMaterialPhotoUrl()
{
return unit;
return materialPhotoUrl;
}
public void setPhotoUrl(String photoUrl)
public void setMaterialUnit(String materialUnit)
{
this.photoUrl = photoUrl;
this.materialUnit = materialUnit;
}
public String getPhotoUrl()
public String getMaterialUnit()
{
return photoUrl;
return materialUnit;
}
public void setBrand(String brand)
public void setMaterialBrand(String materialBrand)
{
this.brand = brand;
this.materialBrand = materialBrand;
}
public String getBrand()
public String getMaterialBrand()
{
return brand;
return materialBrand;
}
public void setDescribe(String describe)
public void setMaterialDescribe(String materialDescribe)
{
this.describe = describe;
this.materialDescribe = materialDescribe;
}
public String getDescribe()
public String getMaterialDescribe()
{
return describe;
return materialDescribe;
}
public void setProcessMethod(String processMethod)
public void setMaterialProcessMode(String materialProcessMode)
{
this.processMethod = processMethod;
this.materialProcessMode = materialProcessMode;
}
public String getProcessMethod()
public String getMaterialProcessMode()
{
return processMethod;
return materialProcessMode;
}
public void setUserId(Long userId)
{
this.userId = userId;
}
public String getFinshStatus() {
return finshStatus;
public Long getUserId()
{
return userId;
}
public void setUserName(String userName)
{
this.userName = userName;
}
public void setFinshStatus(String finshStatus) {
this.finshStatus = finshStatus;
public String getUserName()
{
return userName;
}
@Override
public String toString() {
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
.append("oderId", getOderId())
.append("developOrderId", getDevelopOrderId())
.append("developOderCode", getDevelopOderCode())
.append("materialNo", getMaterialNo())
.append("eceiptStatus", getEceiptStatus())
.append("purchaseStorageStatus", getPurchaseStorageStatus())
.append("qualityStatus", getQualityStatus())
.append("auditStatus", getAuditStatus())
.append("completeStatus", getCompleteStatus())
.append("finshStatus", getFinshStatus())
.append("useStatus", getUseStatus())
.append("materialName", getMaterialName())
.append("materialType", getMaterialType())
.append("unit", getUnit())
.append("photoUrl", getPhotoUrl())
.append("brand", getBrand())
.append("describe", getDescribe())
.append("processMethod", getProcessMethod())
.append("materialPhotoUrl", getMaterialPhotoUrl())
.append("materialUnit", getMaterialUnit())
.append("materialBrand", getMaterialBrand())
.append("materialDescribe", getMaterialDescribe())
.append("materialProcessMode", getMaterialProcessMode())
.append("userId", getUserId())
.append("createBy", getCreateBy())
.append("createTime", getCreateTime())
.append("userName", getUserName())
.append("updateBy", getUpdateBy())
.append("updateTime", getUpdateTime())
.append("remark", getRemark())

77
ruoyi-admin/src/main/java/com/ruoyi/erp/mapper/ErpDevelopModifyorderMapper.java

@ -0,0 +1,77 @@
package com.ruoyi.erp.mapper;
import java.util.List;
import com.ruoyi.erp.domain.ErpDevelopModifyorder;
/**
* 开发修改单Mapper接口
*
* @author 刘晓旭
* @date 2024-04-18
*/
public interface ErpDevelopModifyorderMapper
{
/**
* 查询开发修改单
*
* @param developOrderId 开发修改单ID
* @return 开发修改单
*/
public ErpDevelopModifyorder selectErpDevelopModifyorderById(Long developOrderId);
/**
* 查询开发修改单列表
*
* @param erpDevelopModifyorder 开发修改单
* @return 开发修改单集合
*/
public List<ErpDevelopModifyorder> selectErpDevelopModifyorderList(ErpDevelopModifyorder erpDevelopModifyorder);
/**
* 新增开发修改单
*
* @param erpDevelopModifyorder 开发修改单
* @return 结果
*/
public int insertErpDevelopModifyorder(ErpDevelopModifyorder erpDevelopModifyorder);
/**
* 修改开发修改单
*
* @param erpDevelopModifyorder 开发修改单
* @return 结果
*/
public int updateErpDevelopModifyorder(ErpDevelopModifyorder erpDevelopModifyorder);
/**
* 删除开发修改单
*
* @param developOrderId 开发修改单ID
* @return 结果
*/
public int deleteErpDevelopModifyorderById(Long developOrderId);
/**
* 批量删除开发修改单
*
* @param developOrderIds 需要删除的数据ID
* @return 结果
*/
public int deleteErpDevelopModifyorderByIds(String[] developOrderIds);
/**
* 作废开发修改单
*
* @param developOrderId 开发修改单ID
* @return 结果
*/
public int cancelErpDevelopModifyorderById(Long developOrderId);
/**
* 恢复开发修改单
*
* @param developOrderId 开发修改单ID
* @return 结果
*/
public int restoreErpDevelopModifyorderById(Long developOrderId);
}

75
ruoyi-admin/src/main/java/com/ruoyi/erp/service/IErpDevelopModifyorderService.java

@ -0,0 +1,75 @@
package com.ruoyi.erp.service;
import java.util.List;
import com.ruoyi.erp.domain.ErpDevelopModifyorder;
/**
* 开发修改单Service接口
*
* @author 刘晓旭
* @date 2024-04-18
*/
public interface IErpDevelopModifyorderService
{
/**
* 查询开发修改单
*
* @param developOrderId 开发修改单ID
* @return 开发修改单
*/
public ErpDevelopModifyorder selectErpDevelopModifyorderById(Long developOrderId);
/**
* 查询开发修改单列表
*
* @param erpDevelopModifyorder 开发修改单
* @return 开发修改单集合
*/
public List<ErpDevelopModifyorder> selectErpDevelopModifyorderList(ErpDevelopModifyorder erpDevelopModifyorder);
/**
* 新增开发修改单
*
* @param erpDevelopModifyorder 开发修改单
* @return 结果
*/
public int insertErpDevelopModifyorder(ErpDevelopModifyorder erpDevelopModifyorder);
/**
* 修改开发修改单
*
* @param erpDevelopModifyorder 开发修改单
* @return 结果
*/
public int updateErpDevelopModifyorder(ErpDevelopModifyorder erpDevelopModifyorder);
/**
* 批量删除开发修改单
*
* @param ids 需要删除的数据ID
* @return 结果
*/
public int deleteErpDevelopModifyorderByIds(String ids);
/**
* 删除开发修改单信息
*
* @param developOrderId 开发修改单ID
* @return 结果
*/
public int deleteErpDevelopModifyorderById(Long developOrderId);
/**
* 作废开发修改单
* @param developOrderId 开发修改单ID
* @return
*/
int cancelErpDevelopModifyorderById(Long developOrderId);
/**
* 恢复开发修改单
* @param developOrderId 开发修改单ID
* @return
*/
int restoreErpDevelopModifyorderById(Long developOrderId);
}

126
ruoyi-admin/src/main/java/com/ruoyi/erp/service/impl/ErpDevelopModifyorderServiceImpl.java

@ -0,0 +1,126 @@
package com.ruoyi.erp.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.erp.mapper.ErpDevelopModifyorderMapper;
import com.ruoyi.erp.domain.ErpDevelopModifyorder;
import com.ruoyi.erp.service.IErpDevelopModifyorderService;
import com.ruoyi.common.core.text.Convert;
/**
* 开发修改单Service业务层处理
*
* @author 刘晓旭
* @date 2024-04-18
*/
@Service
public class ErpDevelopModifyorderServiceImpl implements IErpDevelopModifyorderService
{
@Autowired
private ErpDevelopModifyorderMapper erpDevelopModifyorderMapper;
/**
* 查询开发修改单
*
* @param developOrderId 开发修改单ID
* @return 开发修改单
*/
@Override
public ErpDevelopModifyorder selectErpDevelopModifyorderById(Long developOrderId)
{
return erpDevelopModifyorderMapper.selectErpDevelopModifyorderById(developOrderId);
}
/**
* 查询开发修改单列表
*
* @param erpDevelopModifyorder 开发修改单
* @return 开发修改单
*/
@Override
public List<ErpDevelopModifyorder> selectErpDevelopModifyorderList(ErpDevelopModifyorder erpDevelopModifyorder)
{
return erpDevelopModifyorderMapper.selectErpDevelopModifyorderList(erpDevelopModifyorder);
}
/**
* 新增开发修改单
*
* @param erpDevelopModifyorder 开发修改单
* @return 结果
*/
@Override
public int insertErpDevelopModifyorder(ErpDevelopModifyorder erpDevelopModifyorder)
{
String loginName = ShiroUtils.getLoginName();
erpDevelopModifyorder.setCreateBy(loginName);
erpDevelopModifyorder.setCreateTime(DateUtils.getNowDate());
return erpDevelopModifyorderMapper.insertErpDevelopModifyorder(erpDevelopModifyorder);
}
/**
* 修改开发修改单
*
* @param erpDevelopModifyorder 开发修改单
* @return 结果
*/
@Override
public int updateErpDevelopModifyorder(ErpDevelopModifyorder erpDevelopModifyorder)
{
String loginName = ShiroUtils.getLoginName();
erpDevelopModifyorder.setUpdateBy(loginName);
erpDevelopModifyorder.setUpdateTime(DateUtils.getNowDate());
return erpDevelopModifyorderMapper.updateErpDevelopModifyorder(erpDevelopModifyorder);
}
/**
* 删除开发修改单对象
*
* @param ids 需要删除的数据ID
* @return 结果
*/
@Override
public int deleteErpDevelopModifyorderByIds(String ids)
{
return erpDevelopModifyorderMapper.deleteErpDevelopModifyorderByIds(Convert.toStrArray(ids));
}
/**
* 删除开发修改单信息
*
* @param developOrderId 开发修改单ID
* @return 结果
*/
@Override
public int deleteErpDevelopModifyorderById(Long developOrderId)
{
return erpDevelopModifyorderMapper.deleteErpDevelopModifyorderById(developOrderId);
}
/**
* 作废开发修改单
*
* @param developOrderId 开发修改单ID
* @return 结果
*/
@Override
public int cancelErpDevelopModifyorderById(Long developOrderId)
{
return erpDevelopModifyorderMapper.cancelErpDevelopModifyorderById(developOrderId);
}
/**
* 恢复开发修改单信息
*
* @param developOrderId 开发修改单ID
* @return 结果
*/
@Override
public int restoreErpDevelopModifyorderById(Long developOrderId)
{
return erpDevelopModifyorderMapper.restoreErpDevelopModifyorderById(developOrderId);
}
}

148
ruoyi-admin/src/main/java/com/ruoyi/system/controller/developReviseOrderController.java

@ -1,148 +0,0 @@
package com.ruoyi.system.controller;
import com.ruoyi.common.annotation.Log;
import com.ruoyi.common.core.controller.BaseController;
import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.common.core.page.TableDataInfo;
import com.ruoyi.common.enums.BusinessType;
import com.ruoyi.common.utils.poi.ExcelUtil;
import com.ruoyi.system.domain.DevelopReviseOrder;
import com.ruoyi.system.service.IDevelopReviseOrderService;
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.*;
import java.util.List;
/**
* 开发修改单Controller
*
* @author ruoyi
* @date 2023-12-12
*/
@Controller
@RequestMapping("/system/developReviseOrder")
public class developReviseOrderController extends BaseController
{
private String prefix = "system/developReviseOrder";
@Autowired
private IDevelopReviseOrderService developReviseOrderService;
@RequiresPermissions("erp:developReviseOrder:view")
@GetMapping()
public String developReviseOrder()
{
return prefix + "/developReviseOrder";
}
/**
* 查询开发修改单列表
*/
@RequiresPermissions("erp:developReviseOrder:list")
@PostMapping("/list")
@ResponseBody
public TableDataInfo list(DevelopReviseOrder developReviseOrder)
{
startPage();
List<DevelopReviseOrder> list = developReviseOrderService.selectDevelopReviseOrderList(developReviseOrder);
return getDataTable(list);
}
/**
* 导出开发修改单列表
*/
@RequiresPermissions("erp:developReviseOrder:export")
@Log(title = "开发修改单", businessType = BusinessType.EXPORT)
@PostMapping("/export")
@ResponseBody
public AjaxResult export(DevelopReviseOrder developReviseOrder)
{
List<DevelopReviseOrder> list = developReviseOrderService.selectDevelopReviseOrderList(developReviseOrder);
ExcelUtil<DevelopReviseOrder> util = new ExcelUtil<DevelopReviseOrder>(DevelopReviseOrder.class);
return util.exportExcel(list, "开发修改单数据");
}
/**
* 新增开发修改单
*/
@GetMapping("/add")
public String add()
{
return prefix + "/add";
}
/**
* 新增保存开发修改单
*/
@RequiresPermissions("erp:developReviseOrder:add")
@Log(title = "开发修改单", businessType = BusinessType.INSERT)
@PostMapping("/add")
@ResponseBody
public AjaxResult addSave(DevelopReviseOrder developReviseOrder)
{
return toAjax(developReviseOrderService.insertDevelopReviseOrder(developReviseOrder));
}
/**
* 修改开发修改单
*/
@GetMapping("/edit/{oderId}")
public String edit(@PathVariable("oderId") Long oderId, ModelMap mmap)
{
DevelopReviseOrder developReviseOrder = developReviseOrderService.selectDevelopReviseOrderById(oderId);
mmap.put("developReviseOrder", developReviseOrder);
return prefix + "/edit";
}
/**
* 修改保存开发修改单
*/
@RequiresPermissions("erp:developReviseOrder:edit")
@Log(title = "开发修改单", businessType = BusinessType.UPDATE)
@PostMapping("/edit")
@ResponseBody
public AjaxResult editSave(DevelopReviseOrder developReviseOrder)
{
return toAjax(developReviseOrderService.updateDevelopReviseOrder(developReviseOrder));
}
/**
* 删除开发修改单
*/
@RequiresPermissions("erp:developReviseOrder:remove")
@Log(title = "开发修改单", businessType = BusinessType.DELETE)
@PostMapping( "/remove")
@ResponseBody
public AjaxResult remove(String ids)
{
return toAjax(developReviseOrderService.deleteDevelopReviseOrderByIds(ids));
}
/**
* 作废开发修改单
*/
@RequiresPermissions("erp:developReviseOrder:cancel")
@Log(title = "开发修改单", businessType = BusinessType.CANCEL)
@GetMapping( "/cancel/{id}")
@ResponseBody
public AjaxResult cancel(@PathVariable("id") Long id){
return toAjax(developReviseOrderService.cancelDevelopReviseOrderById(id));
}
/**
* 恢复开发修改单
*/
@RequiresPermissions("erp:developReviseOrder:restore")
@Log(title = "开发修改单", businessType = BusinessType.RESTORE)
@GetMapping( "/restore/{id}")
@ResponseBody
public AjaxResult restore(@PathVariable("id")Long id)
{
return toAjax(developReviseOrderService.restoreDevelopReviseOrderById(id));
}
}

78
ruoyi-admin/src/main/java/com/ruoyi/system/mapper/DevelopReviseOrderMapper.java

@ -1,78 +0,0 @@
package com.ruoyi.system.mapper;
import com.ruoyi.system.domain.DevelopReviseOrder;
import java.util.List;
/**
* 开发修改单Mapper接口
*
* @author ruoyi
* @date 2023-12-12
*/
public interface DevelopReviseOrderMapper
{
/**
* 查询开发修改单
*
* @param oderId 开发修改单ID
* @return 开发修改单
*/
public DevelopReviseOrder selectDevelopReviseOrderById(Long oderId);
/**
* 查询开发修改单列表
*
* @param developReviseOrder 开发修改单
* @return 开发修改单集合
*/
public List<DevelopReviseOrder> selectDevelopReviseOrderList(DevelopReviseOrder developReviseOrder);
/**
* 新增开发修改单
*
* @param developReviseOrder 开发修改单
* @return 结果
*/
public int insertDevelopReviseOrder(DevelopReviseOrder developReviseOrder);
/**
* 修改开发修改单
*
* @param developReviseOrder 开发修改单
* @return 结果
*/
public int updateDevelopReviseOrder(DevelopReviseOrder developReviseOrder);
/**
* 删除开发修改单
*
* @param oderId 开发修改单ID
* @return 结果
*/
public int deleteDevelopReviseOrderById(Long oderId);
/**
* 批量删除开发修改单
*
* @param oderIds 需要删除的数据ID
* @return 结果
*/
public int deleteDevelopReviseOrderByIds(String[] oderIds);
/**
* 作废开发修改单
*
* @param oderId 开发修改单ID
* @return 结果
*/
public int cancelDevelopReviseOrderById(Long oderId);
/**
* 恢复开发修改单
*
* @param oderId 开发修改单ID
* @return 结果
*/
public int restoreDevelopReviseOrderById(Long oderId);
}

76
ruoyi-admin/src/main/java/com/ruoyi/system/service/IDevelopReviseOrderService.java

@ -1,76 +0,0 @@
package com.ruoyi.system.service;
import com.ruoyi.system.domain.DevelopReviseOrder;
import java.util.List;
/**
* 开发修改单Service接口
*
* @author ruoyi
* @date 2023-12-12
*/
public interface IDevelopReviseOrderService
{
/**
* 查询开发修改单
*
* @param oderId 开发修改单ID
* @return 开发修改单
*/
public DevelopReviseOrder selectDevelopReviseOrderById(Long oderId);
/**
* 查询开发修改单列表
*
* @param developReviseOrder 开发修改单
* @return 开发修改单集合
*/
public List<DevelopReviseOrder> selectDevelopReviseOrderList(DevelopReviseOrder developReviseOrder);
/**
* 新增开发修改单
*
* @param developReviseOrder 开发修改单
* @return 结果
*/
public int insertDevelopReviseOrder(DevelopReviseOrder developReviseOrder);
/**
* 修改开发修改单
*
* @param developReviseOrder 开发修改单
* @return 结果
*/
public int updateDevelopReviseOrder(DevelopReviseOrder developReviseOrder);
/**
* 批量删除开发修改单
*
* @param ids 需要删除的数据ID
* @return 结果
*/
public int deleteDevelopReviseOrderByIds(String ids);
/**
* 删除开发修改单信息
*
* @param oderId 开发修改单ID
* @return 结果
*/
public int deleteDevelopReviseOrderById(Long oderId);
/**
* 作废开发修改单
* @param oderId 开发修改单ID
* @return
*/
int cancelDevelopReviseOrderById(Long oderId);
/**
* 恢复开发修改单
* @param oderId 开发修改单ID
* @return
*/
int restoreDevelopReviseOrderById(Long oderId);
}

65
ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/DevelopReviseOrderServiceImpl.java

@ -1,65 +0,0 @@
package com.ruoyi.system.service.impl;
import com.ruoyi.common.core.text.Convert;
import com.ruoyi.common.utils.DateUtils;
import com.ruoyi.common.utils.ShiroUtils;
import com.ruoyi.system.domain.DevelopReviseOrder;
import com.ruoyi.system.mapper.DevelopReviseOrderMapper;
import com.ruoyi.system.service.IDevelopReviseOrderService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.List;
/**
* 开发修改单Service业务层处理
*
* @author ruoyi
* @date 2023-12-12
*/
@Service
public class DevelopReviseOrderServiceImpl implements IDevelopReviseOrderService
{
@Autowired
private DevelopReviseOrderMapper developReviseOrderMapper;
@Override
public DevelopReviseOrder selectDevelopReviseOrderById(Long oderId) {
return developReviseOrderMapper.selectDevelopReviseOrderById(oderId);
}
@Override
public List<DevelopReviseOrder> selectDevelopReviseOrderList(DevelopReviseOrder developReviseOrder) {
return developReviseOrderMapper.selectDevelopReviseOrderList(developReviseOrder);
}
@Override
public int insertDevelopReviseOrder(DevelopReviseOrder developReviseOrder) {
return developReviseOrderMapper.insertDevelopReviseOrder(developReviseOrder);
}
@Override
public int updateDevelopReviseOrder(DevelopReviseOrder developReviseOrder) {
return developReviseOrderMapper.updateDevelopReviseOrder(developReviseOrder);
}
@Override
public int deleteDevelopReviseOrderByIds(String ids) {
return developReviseOrderMapper.deleteDevelopReviseOrderByIds(Convert.toStrArray(ids));
}
@Override
public int deleteDevelopReviseOrderById(Long oderId) {
return developReviseOrderMapper.deleteDevelopReviseOrderById(oderId);
}
@Override
public int cancelDevelopReviseOrderById(Long oderId) {
return developReviseOrderMapper.cancelDevelopReviseOrderById(oderId);
}
@Override
public int restoreDevelopReviseOrderById(Long oderId) {
return developReviseOrderMapper.restoreDevelopReviseOrderById(oderId);
}
}

158
ruoyi-admin/src/main/resources/mapper/erp/ErpDevelopModifyorderMapper.xml

@ -0,0 +1,158 @@
<?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.erp.mapper.ErpDevelopModifyorderMapper">
<resultMap type="ErpDevelopModifyorder" id="ErpDevelopModifyorderResult">
<result property="developOrderId" column="develop_order_id" />
<result property="developOderCode" column="develop_oder_code" />
<result property="materialNo" column="material_no" />
<result property="purchaseStorageStatus" column="purchase_storage_status" />
<result property="qualityStatus" column="quality_status" />
<result property="auditStatus" column="audit_status" />
<result property="completeStatus" column="complete_status" />
<result property="finshStatus" column="finsh_status" />
<result property="useStatus" column="use_status" />
<result property="materialName" column="material_name" />
<result property="materialType" column="material_type" />
<result property="materialPhotoUrl" column="material_photo_url" />
<result property="materialUnit" column="material_unit" />
<result property="materialBrand" column="material_brand" />
<result property="materialDescribe" column="material_describe" />
<result property="materialProcessMode" column="material_process_mode" />
<result property="userId" column="user_id" />
<result property="createBy" column="create_by" />
<result property="createTime" column="create_time" />
<result property="userName" column="user_name" />
<result property="updateBy" column="update_by" />
<result property="updateTime" column="update_time" />
<result property="remark" column="remark" />
</resultMap>
<sql id="selectErpDevelopModifyorderVo">
select develop_order_id, develop_oder_code, material_no, purchase_storage_status, quality_status, audit_status, complete_status, finsh_status, use_status, material_name, material_type, material_photo_url, material_unit, material_brand, material_describe, material_process_mode, user_id, create_by, create_time, user_name, update_by, update_time, remark from erp_develop_modifyorder
</sql>
<select id="selectErpDevelopModifyorderList" parameterType="ErpDevelopModifyorder" resultMap="ErpDevelopModifyorderResult">
select edm.develop_order_id, edm.develop_oder_code, edm.material_no, edm.purchase_storage_status, edm.quality_status, edm.audit_status, edm.complete_status, edm.finsh_status, edm.use_status, edm.material_name, edm.material_type, edm.material_photo_url, edm.material_unit, edm.material_brand, edm.material_describe, edm.material_process_mode, edm.user_id, edm.create_by, edm.create_time, edm.update_by, edm.update_time, edm.remark,su.user_name
from erp_develop_modifyorder edm
left join sys_user su on su.user_id = edm.user_id
<where>
<if test="developOderCode != null and developOderCode != ''"> and edm.develop_oder_code = #{developOderCode}</if>
<if test="materialNo != null and materialNo != ''"> and edm.material_no = #{materialNo}</if>
<if test="auditStatus != null and auditStatus != ''"> and edm.audit_status = #{auditStatus}</if>
<if test="finshStatus != null and finshStatus != ''"> and edm.finsh_status = #{finshStatus}</if>
<if test="materialName != null and materialName != ''"> and edm.material_name like concat('%', #{materialName}, '%')</if>
<if test="userId != null "> and edm.user_id = #{userId}</if>
<if test="createTime != null "> and edm.create_time = #{createTime}</if>
</where>
</select>
<select id="selectErpDevelopModifyorderById" parameterType="Long" resultMap="ErpDevelopModifyorderResult">
<include refid="selectErpDevelopModifyorderVo"/>
where develop_order_id = #{developOrderId}
</select>
<insert id="insertErpDevelopModifyorder" parameterType="ErpDevelopModifyorder" useGeneratedKeys="true" keyProperty="developOrderId">
insert into erp_develop_modifyorder
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="developOderCode != null">develop_oder_code,</if>
<if test="materialNo != null">material_no,</if>
<if test="purchaseStorageStatus != null">purchase_storage_status,</if>
<if test="qualityStatus != null">quality_status,</if>
<if test="auditStatus != null">audit_status,</if>
<if test="completeStatus != null">complete_status,</if>
<if test="finshStatus != null">finsh_status,</if>
<if test="useStatus != null">use_status,</if>
<if test="materialName != null">material_name,</if>
<if test="materialType != null">material_type,</if>
<if test="materialPhotoUrl != null">material_photo_url,</if>
<if test="materialUnit != null">material_unit,</if>
<if test="materialBrand != null">material_brand,</if>
<if test="materialDescribe != null">material_describe,</if>
<if test="materialProcessMode != null">material_process_mode,</if>
<if test="userId != null">user_id,</if>
<if test="createBy != null">create_by,</if>
<if test="createTime != null">create_time,</if>
<if test="userName != null">user_name,</if>
<if test="updateBy != null">update_by,</if>
<if test="updateTime != null">update_time,</if>
<if test="remark != null">remark,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="developOderCode != null">#{developOderCode},</if>
<if test="materialNo != null">#{materialNo},</if>
<if test="purchaseStorageStatus != null">#{purchaseStorageStatus},</if>
<if test="qualityStatus != null">#{qualityStatus},</if>
<if test="auditStatus != null">#{auditStatus},</if>
<if test="completeStatus != null">#{completeStatus},</if>
<if test="finshStatus != null">#{finshStatus},</if>
<if test="useStatus != null">#{useStatus},</if>
<if test="materialName != null">#{materialName},</if>
<if test="materialType != null">#{materialType},</if>
<if test="materialPhotoUrl != null">#{materialPhotoUrl},</if>
<if test="materialUnit != null">#{materialUnit},</if>
<if test="materialBrand != null">#{materialBrand},</if>
<if test="materialDescribe != null">#{materialDescribe},</if>
<if test="materialProcessMode != null">#{materialProcessMode},</if>
<if test="userId != null">#{userId},</if>
<if test="createBy != null">#{createBy},</if>
<if test="createTime != null">#{createTime},</if>
<if test="userName != null">#{userName},</if>
<if test="updateBy != null">#{updateBy},</if>
<if test="updateTime != null">#{updateTime},</if>
<if test="remark != null">#{remark},</if>
</trim>
</insert>
<update id="updateErpDevelopModifyorder" parameterType="ErpDevelopModifyorder">
update erp_develop_modifyorder
<trim prefix="SET" suffixOverrides=",">
<if test="developOderCode != null">develop_oder_code = #{developOderCode},</if>
<if test="materialNo != null">material_no = #{materialNo},</if>
<if test="purchaseStorageStatus != null">purchase_storage_status = #{purchaseStorageStatus},</if>
<if test="qualityStatus != null">quality_status = #{qualityStatus},</if>
<if test="auditStatus != null">audit_status = #{auditStatus},</if>
<if test="completeStatus != null">complete_status = #{completeStatus},</if>
<if test="finshStatus != null">finsh_status = #{finshStatus},</if>
<if test="useStatus != null">use_status = #{useStatus},</if>
<if test="materialName != null">material_name = #{materialName},</if>
<if test="materialType != null">material_type = #{materialType},</if>
<if test="materialPhotoUrl != null">material_photo_url = #{materialPhotoUrl},</if>
<if test="materialUnit != null">material_unit = #{materialUnit},</if>
<if test="materialBrand != null">material_brand = #{materialBrand},</if>
<if test="materialDescribe != null">material_describe = #{materialDescribe},</if>
<if test="materialProcessMode != null">material_process_mode = #{materialProcessMode},</if>
<if test="userId != null">user_id = #{userId},</if>
<if test="createBy != null">create_by = #{createBy},</if>
<if test="createTime != null">create_time = #{createTime},</if>
<if test="userName != null">user_name = #{userName},</if>
<if test="updateBy != null">update_by = #{updateBy},</if>
<if test="updateTime != null">update_time = #{updateTime},</if>
<if test="remark != null">remark = #{remark},</if>
</trim>
where develop_order_id = #{developOrderId}
</update>
<delete id="deleteErpDevelopModifyorderById" parameterType="Long">
delete from erp_develop_modifyorder where develop_order_id = #{developOrderId}
</delete>
<delete id="deleteErpDevelopModifyorderByIds" parameterType="String">
delete from erp_develop_modifyorder where develop_order_id in
<foreach item="developOrderId" collection="array" open="(" separator="," close=")">
#{developOrderId}
</foreach>
</delete>
<update id="cancelErpDevelopModifyorderById" parameterType="Long">
update erp_develop_modifyorder set del_flag = '1' where develop_order_id = #{developOrderId}
</update>
<update id="restoreErpDevelopModifyorderById" parameterType="Long">
update erp_develop_modifyorder set del_flag = '0' where develop_order_id = #{developOrderId}
</update>
</mapper>

147
ruoyi-admin/src/main/resources/mapper/system/DevelopReviseorderMapper.xml

@ -1,147 +0,0 @@
<?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.DevelopReviseOrderMapper">
<resultMap type="DevelopReviseOrder" id="DevelopReviseOrderResult">
<result property="oderId" column="oderId" />
<result property="developOderCode" column="develop_oder_code" />
<result property="materialNo" column="materialNo" />
<result property="eceiptStatus" column="eceipt_status" />
<result property="qualityStatus" column="quality_status" />
<result property="auditStatus" column="audit_status" />
<result property="completeStatus" column="complete_status" />
<result property="finshStatus" column="finsh_status" />
<result property="materialName" column="materialName" />
<result property="materialType" column="materialType" />
<result property="unit" column="unit" />
<result property="photoUrl" column="photoUrl" />
<result property="brand" column="brand" />
<result property="describe" column="describe" />
<result property="processMethod" column="processMethod" />
<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" />
</resultMap>
<sql id="selectDevelopReviseOrderVo">
select oderId, develop_oder_code, materialNo, eceipt_status, quality_status, audit_status, complete_status,finsh_status, materialName, materialType, unit, photoUrl, brand, describe, processMethod, create_by, create_time, update_by, update_time, remark from develop_reviseorder
</sql>
<select id="selectDevelopReviseOrderList" parameterType="DevelopReviseOrder" resultMap="DevelopReviseOrderResult">
<include refid="selectDevelopReviseOrderVo"/>
<where>
<if test="developOderCode != null and developOderCode != ''"> and develop_oderCode = #{developOdercode}</if>
<if test="materialNo != null and materialNo != ''"> and materialNo = #{materialNo}</if>
<if test="eceiptStatus != null and eceiptStatus != ''"> and eceipt_status = #{eceiptStatus}</if>
<if test="auditStatus != null and auditStatus != ''"> and audit_status = #{auditStatus}</if>
<if test="completeStatus != null and completeStatus != ''"> and complete_status = #{completeStatus}</if>
<if test="finshStatus != null and finshStatus != ''"> and finsh_status = #{finshStatus}</if>
<if test="materialName != null and materialName != ''"> and materialName like concat('%', #{materialName}, '%')</if>
<if test="materialType != null and materialType != ''"> and materialType = #{materialType}</if>
<if test="photoUrl != null and photoUrl != ''"> and photoUrl = #{photoUrl}</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>
</where>
</select>
<select id="selectDevelopReviseOrderById" parameterType="Long" resultMap="DevelopReviseOrderResult">
<include refid="selectDevelopReviseOrderVo"/>
where oderId = #{oderId}
</select>
<insert id="insertDevelopReviseOrder" parameterType="DevelopReviseOrder" useGeneratedKeys="true" keyProperty="oderId">
insert into develop_reviseorder
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="developOdercode != null">develop_oderCode,</if>
<if test="materialNo != null">materialNo,</if>
<if test="eceiptStatus != null">eceipt_status,</if>
<if test="qualityStatus != null">quality_status,</if>
<if test="auditStatus != null">audit_status,</if>
<if test="completeStatus != null">complete_status,</if>
<if test="finshStatus != null">finsh_status,</if>
<if test="materialName != null">materialName,</if>
<if test="materialType != null">materialType,</if>
<if test="unit != null">unit,</if>
<if test="photoUrl != null">photoUrl,</if>
<if test="brand != null">brand,</if>
<if test="describe != null">describe,</if>
<if test="processMethod != null">processMethod,</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>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="developOdercode != null">#{developOdercode},</if>
<if test="materialNo != null">#{materialNo},</if>
<if test="eceiptStatus != null">#{eceiptStatus},</if>
<if test="qualityStatus != null">#{qualityStatus},</if>
<if test="auditStatus != null">#{auditStatus},</if>
<if test="completeStatus != null">#{completeStatus},</if>
<if test="finshStatus != null">#{finshStatus},</if>
<if test="materialName != null">#{materialName},</if>
<if test="materialType != null">#{materialType},</if>
<if test="unit != null">#{unit},</if>
<if test="photoUrl != null">#{photoUrl},</if>
<if test="brand != null">#{brand},</if>
<if test="describe != null">#{describe},</if>
<if test="processMethod != null">#{processMethod},</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>
</trim>
</insert>
<update id="updateDevelopReviseOrder" parameterType="DevelopReviseOrder">
update develop_reviseorder
<trim prefix="SET" suffixOverrides=",">
<if test="developOdercode != null">develop_oderCode = #{developOdercode},</if>
<if test="materialNo != null">materialNo = #{materialNo},</if>
<if test="eceiptStatus != null">eceipt_status = #{eceiptStatus},</if>
<if test="qualityStatus != null">quality_status = #{qualityStatus},</if>
<if test="auditStatus != null">audit_status = #{auditStatus},</if>
<if test="completeStatus != null">complete_status = #{completeStatus},</if>
<if test="finshStatus != null">finsh_status = #{finshStatus},</if>
<if test="materialName != null">materialName = #{materialName},</if>
<if test="materialType != null">materialType = #{materialType},</if>
<if test="unit != null">unit = #{unit},</if>
<if test="photoUrl != null">photoUrl = #{photoUrl},</if>
<if test="brand != null">brand = #{brand},</if>
<if test="describe != null">describe = #{describe},</if>
<if test="processMethod != null">processMethod = #{processMethod},</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>
</trim>
where oderId = #{oderId}
</update>
<delete id="deleteDevelopReviseOrderById" parameterType="Long">
delete from develop_reviseorder where oderId = #{oderId}
</delete>
<delete id="deleteDevelopReviseOrderByIds" parameterType="String">
delete from develop_reviseorder where oderId in
<foreach item="oderId" collection="array" open="(" separator="," close=")">
#{oderId}
</foreach>
</delete>
<update id="cancelDevelopReviseOrderById" parameterType="Long">
update develop_reviseorder set use_status = '1' where oderId = #{oderId}
</update>
<update id="restoreDevelopReviseOrderById" parameterType="Long">
update develop_reviseorder set use_status = '0' where oderId = #{oderId}
</update>
</mapper>

166
ruoyi-admin/src/main/resources/templates/erp/developModifyOrder/add.html

@ -0,0 +1,166 @@
<!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-developModifyOrder-add">
<div class="form-group">
<label class="col-sm-3 control-label">开发修改单号:</label>
<div class="col-sm-8">
<input name="developOderCode" 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" 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="purchaseStorageStatus" class="form-control m-b" th:with="type=${@dict.getType('eceiptStatus')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">品质状态:</label>
<div class="col-sm-8">
<select name="qualityStatus" class="form-control m-b" th:with="type=${@dict.getType('qualityStatus')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">审核状态:</label>
<div class="col-sm-8">
<select name="auditStatus" class="form-control m-b" th:with="type=${@dict.getType('auditStatus')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">确认状态:</label>
<div class="col-sm-8">
<select name="completeStatus" class="form-control m-b" th:with="type=${@dict.getType('completeStatus')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">完成状态:</label>
<div class="col-sm-8">
<select name="finshStatus" class="form-control m-b" th:with="type=${@dict.getType('finshStatus')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">使用状态:</label>
<div class="col-sm-8">
<select name="useStatus" class="form-control m-b" th:with="type=${@dict.getType('useStatus')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</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">
<input name="materialType" 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="materialPhotoUrl" 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="materialUnit" 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="materialBrand" 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="materialDescribe" 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="materialProcessMode" 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 id="userId_add" name="userId" class="form-control m-b">
<option value="">所有</option>
</select>
</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>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var prefix = ctx + "erp/developModifyOrder"
$("#form-developModifyOrder-add").validate({
focusCleanup: true
});
$(function () {
$.ajax({
url: ctx + 'erp/developModifyOrder/getEngineerList',
type: 'post',
data: { roleKey: 'gcwyRole' },
success: function (res) {
if (res.data.length > 0) {
var userData = res.data;
for (let i in userData) {
$("#userId_add").append(
"<option value='" + userData[i].userId + "'>" + userData[i].userName + "</option>" // 显示用户姓名
);
}
$("userId_add").val(userData[i].userId).trigger("change");
} else {
$.modal.msgError(res.msg);
}
}
});
})
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/add", $('#form-developModifyOrder-add').serialize());
}
}
</script>
</body>
</html>

148
ruoyi-admin/src/main/resources/templates/erp/developModifyOrder/detail.html

@ -0,0 +1,148 @@
<!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-developModifyOrder-detail" th:object="${erpDevelopModifyorder}">
<input name="developOrderId" th:field="*{developOrderId}" type="hidden">
<div class="form-group">
<label class="col-sm-3 control-label">开发修改单号:</label>
<div class="col-sm-8">
<input name="developOderCode" th:field="*{developOderCode}" 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">
<select name="purchaseStorageStatus" class="form-control m-b" th:with="type=${@dict.getType('eceiptStatus')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{purchaseStorageStatus}"></option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">品质状态:</label>
<div class="col-sm-8">
<select name="qualityStatus" class="form-control m-b" th:with="type=${@dict.getType('qualityStatus')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{qualityStatus}"></option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">审核状态:</label>
<div class="col-sm-8">
<select name="auditStatus" class="form-control m-b" th:with="type=${@dict.getType('auditStatus')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{auditStatus}"></option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">确认状态:</label>
<div class="col-sm-8">
<select name="completeStatus" class="form-control m-b" th:with="type=${@dict.getType('completeStatus')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{completeStatus}"></option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">完成状态:</label>
<div class="col-sm-8">
<select name="finshStatus" class="form-control m-b" th:with="type=${@dict.getType('finshStatus')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{finshStatus}"></option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">使用状态:</label>
<div class="col-sm-8">
<select name="useStatus" class="form-control m-b" th:with="type=${@dict.getType('useStatus')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{useStatus}"></option>
</select>
</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">
<input name="materialType" th:field="*{materialType}" 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="materialPhotoUrl" th:field="*{materialPhotoUrl}" 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="materialUnit" th:field="*{materialUnit}" 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="materialBrand" th:field="*{materialBrand}" 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="materialDescribe" th:field="*{materialDescribe}" 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="materialProcessMode" th:field="*{materialProcessMode}" 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="userId" class="form-control m-b">
<option value="">所有</option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">工程员姓名:</label>
<div class="col-sm-8">
<input name="userName" th:field="*{userName}" 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>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var prefix = ctx + "erp/developModifyOrder";
$("#form-developModifyOrder-detail").validate({
focusCleanup: true
});
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/detail", $('#form-developModifyOrder-detail').serialize());
}
}
</script>
</body>
</html>

229
ruoyi-admin/src/main/resources/templates/erp/developModifyOrder/developModifyOrder.html

@ -0,0 +1,229 @@
<!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="developOderCode"/>
</li>
<li>
<label>料号:</label>
<input type="text" name="materialNo"/>
</li>
<li>
<label>物料名称:</label>
<input type="text" name="materialName"/>
</li>
<li>
<label>审核状态:</label>
<select name="auditStatus" th:with="type=${@dict.getType('auditStatus')}">
<option value="">所有</option>
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</li>
<li>
<label>工程员:</label>
<select name="userId">
<option value="">所有</option>
<option value="-1">代码生成请选择字典属性</option>
</select>
</li>
<li>
<label>完成状态:</label>
<select name="finshStatus" th:with="type=${@dict.getType('finshStatus')}">
<option value="">所有</option>
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</li>
<li>
<label>录入时间:</label>
<input type="text" class="time-input" placeholder="请选择录入时间" name="createTime"/>
</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="erp:developModifyOrder:add">
<i class="fa fa-plus"></i> 添加
</a>
<a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="erp:developModifyOrder:edit">
<i class="fa fa-edit"></i> 修改
</a>
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="erp:developModifyOrder:remove">
<i class="fa fa-remove"></i> 删除
</a>
<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="erp:developModifyOrder: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('erp:developModifyOrder:edit')}]];
var detailFlag = [[${@permission.hasPermi('erp:developModifyOrder:detail')}]];
var removeFlag = [[${@permission.hasPermi('erp:developModifyOrder:remove')}]];
var cancelFlag = [[${@permission.hasPermi('erp:developModifyOrder:cancel')}]];
var restoreFlag = [[${@permission.hasPermi('erp:developModifyOrder:restore')}]];
var purchaseStorageStatusDatas = [[${@dict.getType('eceiptStatus')}]];
var qualityStatusDatas = [[${@dict.getType('qualityStatus')}]];
var auditStatusDatas = [[${@dict.getType('auditStatus')}]];
var completeStatusDatas = [[${@dict.getType('completeStatus')}]];
var finshStatusDatas = [[${@dict.getType('finshStatus')}]];
var useStatusDatas = [[${@dict.getType('useStatus')}]];
var prefix = ctx + "erp/developModifyOrder";
$(function() {
var options = {
url: prefix + "/list",
createUrl: prefix + "/add",
updateUrl: prefix + "/edit/{id}",
detailUrl: prefix + "/detail/{id}",
removeUrl: prefix + "/remove",
cancelUrl: prefix + "/cancel/{id}",
restoreUrl: prefix + "/restore/{id}",
exportUrl: prefix + "/export",
modalName: "开发修改单",
columns: [{
checkbox: true
},
{
title: '开发修改单ID',
field: 'developOrderId',
visible: false
},
{
title: '审核状态',
field: 'auditStatus',
formatter: function (value, row, index) {
return $.table.selectDictLabel(auditStatusDatas, value);
}
},
{
title: '完成状态',
field: 'finshStatus',
formatter: function (value, row, index) {
return $.table.selectDictLabel(finshStatusDatas, value);
}
},
{
title: '确认状态',
field: 'completeStatus',
formatter: function (value, row, index) {
return $.table.selectDictLabel(completeStatusDatas, value);
}
},
{
title: '开发修改单号',
field: 'developOderCode',
},
{
title: '采购入库状态',
field: 'purchaseStorageStatus',
formatter: function (value, row, index) {
return $.table.selectDictLabel(purchaseStorageStatusDatas, value);
}
},
{
title: '品质状态',
field: 'qualityStatus',
formatter: function (value, row, index) {
return $.table.selectDictLabel(qualityStatusDatas, value);
}
},
{
title: '工程员',
field: 'userName',
},
{
title: '料号',
field: 'materialNo',
},
{
title: '图片',
field: 'materialPhotoUrl',
},
{
title: '物料名称',
field: 'materialName',
},
{
title: '物料类型',
field: 'materialType',
},
{
title: '单位',
field: 'materialUnit',
},
{
title: '品牌',
field: 'materialBrand',
},
{
title: '描述',
field: 'materialDescribe',
},
{
title: '加工方式',
field: 'materialProcessMode',
},
{
title: '录入时间',
field: 'createTime',
},
{
title: '更新人',
field: 'updateBy',
},
{
title: '上次更新时间',
field: 'updateTime',
},
// {
// 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.developOrderId + '\')"><i class="fa fa-edit"></i>编辑</a> ');
actions.push('<a class="btn btn-success btn-xs ' + detailFlag + '" href="javascript:void(0)" onclick="$.operate.detail(\'' + row.developOrderId + '\')"><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.developOrderId + '\')"><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>

148
ruoyi-admin/src/main/resources/templates/erp/developModifyOrder/edit.html

@ -0,0 +1,148 @@
<!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-developModifyOrder-edit" th:object="${erpDevelopModifyorder}">
<input name="developOrderId" th:field="*{developOrderId}" type="hidden">
<div class="form-group">
<label class="col-sm-3 control-label">开发修改单号:</label>
<div class="col-sm-8">
<input name="developOderCode" th:field="*{developOderCode}" 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">
<select name="purchaseStorageStatus" class="form-control m-b" th:with="type=${@dict.getType('eceiptStatus')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{purchaseStorageStatus}"></option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">品质状态:</label>
<div class="col-sm-8">
<select name="qualityStatus" class="form-control m-b" th:with="type=${@dict.getType('qualityStatus')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{qualityStatus}"></option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">审核状态:</label>
<div class="col-sm-8">
<select name="auditStatus" class="form-control m-b" th:with="type=${@dict.getType('auditStatus')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{auditStatus}"></option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">确认状态:</label>
<div class="col-sm-8">
<select name="completeStatus" class="form-control m-b" th:with="type=${@dict.getType('completeStatus')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{completeStatus}"></option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">完成状态:</label>
<div class="col-sm-8">
<select name="finshStatus" class="form-control m-b" th:with="type=${@dict.getType('finshStatus')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{finshStatus}"></option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">使用状态:</label>
<div class="col-sm-8">
<select name="useStatus" class="form-control m-b" th:with="type=${@dict.getType('useStatus')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{useStatus}"></option>
</select>
</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">
<input name="materialType" th:field="*{materialType}" 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="materialPhotoUrl" th:field="*{materialPhotoUrl}" 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="materialUnit" th:field="*{materialUnit}" 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="materialBrand" th:field="*{materialBrand}" 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="materialDescribe" th:field="*{materialDescribe}" 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="materialProcessMode" th:field="*{materialProcessMode}" 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="userId" class="form-control m-b">
<option value="">所有</option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">工程员姓名:</label>
<div class="col-sm-8">
<input name="userName" th:field="*{userName}" 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>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var prefix = ctx + "erp/developModifyOrder";
$("#form-developModifyOrder-edit").validate({
focusCleanup: true
});
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/edit", $('#form-developModifyOrder-edit').serialize());
}
}
</script>
</body>
</html>

1
ruoyi-admin/src/main/resources/templates/sales/afterSalesNotice/add.html

@ -115,7 +115,6 @@
<select name="instanceType" 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">

1
ruoyi-admin/src/main/resources/templates/sales/afterSalesNotice/edit.html

@ -116,7 +116,6 @@
<select name="instanceType" 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">

133
ruoyi-admin/src/main/resources/templates/system/developReviseOrder/add.html

@ -1,133 +0,0 @@
<!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-developReviseOrder-add">
<input name="oderId" class="form-control" type="text" hidden="hidden">
<h5>添加开发修改单</h5>
<div class="form-group">
<label class="col-sm-3 control-label is-required" >生产单号:</label>
<div class="col-sm-8">
<input name="developOderCode" class="form-control" type="text" re>
</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">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">采购入库状态:</label>
<div class="col-sm-8">
<select name="purchaseStatus" class="form-control m-b select2" th:with="childList=${@dict.getType('purchaseStatus')}"required>
<option th:each="dict : ${childList}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">品质状态:</label>
<div class="col-sm-8">
<select name="qualityStatus" class="form-control m-b select2" th:with="childList=${@dict.getType('qualityStatus')}"required>
<option th:each="dict : ${childList}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">审核状态:</label>
<div class="col-sm-8">
<select name="auditStatus" class="form-control m-b select2" th:with="childList=${@dict.getType('auditStatus')}"required>
<option th:each="dict : ${childList}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">完成状态:</label>
<div class="col-sm-8">
<select name="finishStatus" class="form-control m-b select2" th:with="childList=${@dict.getType('finishStatus')}"required>
<option th:each="dict : ${childList}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</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>
<select readonly id="selectMaterialType" name="materialType" class="form-control m-b select2-multiple" th:with="childList=${@category.getChildByCode('materialType')}" required>
<optgroup>
<option value=""></option>
</optgroup>
<optgroup th:each="child: ${childList}" th:label="${child.name}">
<option th:each="childSon: ${child.children}" th:value="${childSon.code}" th:text="${#strings.concat(child.name,'-',childSon.name)}"></option>
</optgroup>
</select>
<input type="text" id="materialType" name="materialType" hidden />
</div>
<div class="form-group">
<label class="col-sm-3 control-label">单位:</label>
<div class="col-sm-8">
<input name="unit" 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="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">
<select id="selectProcessingMethod" name="processingMethod" class="form-control m-b select2" th:with="childList=${@category.getChildByCode('processingMethod')}" required>
<optgroup>
<option value=""></option>
</optgroup>
<optgroup th:each="child: ${childList}" th:label="${child.name}">
<option th:each="childSon: ${child.children}" th:value="${childSon.code}" th:text="${#strings.concat(child.name,'-',childSon.name)}"></option>
</optgroup>
</select>
</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>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var prefix = ctx + "system/developReviseOrder"
$("#form-developReviseOrder-add").validate({
focusCleanup: true
});
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/add", $('#form-developReviseOrder-add').serialize());
}
}
</script>
</body>
</html>

164
ruoyi-admin/src/main/resources/templates/system/developReviseOrder/developReviseOrder.html

@ -1,164 +0,0 @@
<!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="developOdercode"/>
</li>
<li>
<label>料号:</label>
<input type="text" name="materialNo"/>
</li>
<li>
<label>物料名称:</label>
<input type="text" name="materialName"/>
</li>
<li>
<label>审核状态:</label>
<select name="auditStatus" th:with="type=${@dict.getType('auditStatus')}">
<option value="">所有</option>
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</li>
<li>
<label>工程员:</label>
<select name="saleStaff" id="selectsaleStaff" >
</select>
</li>
<li>
<label>完成状态:</label>
<select name="" th:with="type=${@dict.getType('finshStatus')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</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>
<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="erp:developReviseOrder:add">
<i class="fa fa-plus"></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('erp:developReviseOrder:edit')}]];
var removeFlag = [[${@permission.hasPermi('erp:developReviseOrder:remove')}]];
var cancelFlag = [[${@permission.hasPermi('erp:developReviseOrder:cancel')}]];
var restoreFlag = [[${@permission.hasPermi('erp:developReviseOrder:restore')}]];
var auditStatusDatas = [[${@dict.getType('auditStatus')}]];
var materialTypeDatas = [[${@dict.getType('ck_meterialt_type')}]];
var completeStatusDatas = [[${@dict.getType('completeStatus')}]];
var unitDatas = [[${@dict.getType('sys_unit_class')}]];
var processMethodDatas = [[${@dict.getType('processMethod')}]];
var userName = [[${@permission.getPrincipalProperty('userName')}]];
var prefix = ctx + "system/developReviseOrder";
$(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
},
{
field: 'auditStatus',
title: '审核状态',
formatter: function(value, row, index) {
return $.table.selectDictLabel(auditStatusDatas, value);
}
},
{field: 'finshStatus',title: '完成状态'},
{field: 'oderId', title: '开发修改单编号',visible: false},
{field: 'developOdercode',title: '开发修改单单号'},
{field:'completeStatus',title:'确认状态'},
{field: 'eceiptStatus',title: '采购入库状态'},
{field: 'qualityStatus',title: '品质状态'},
{field: 'staffNo', title: '员工ID', visible: false},
{field: 'saleStaff', title: '工程员'},
{field: 'materialNo',title: '料号'},
{field: 'materialName',title: '物料名称'},
{field: 'materialType',title: '物料类型',
formatter: function(value, row, index) {return $.table.selectDictLabel(materialTypeDatas, value);}
},
{field: 'unit',title: '单位',
formatter: function(value, row, index) {return $.table.selectDictLabel(unitDatas, value);}
},
{field: 'photoUrl',title: '图片地址'},
{field: 'brand',title: '品牌'},
{field: 'describe',title: '描述'},
{field: 'processMethod',title: '加工方式',
formatter: function(value, row, index) {return $.table.selectDictLabel(processMethodDatas, value);}
},
{field: 'createBy',title: '录入人'},
{field: 'createTime',title: '录入时间'},
{field: 'remark',title: '备注信息'},
{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.oderId + '\')"><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.oderId + '\')"><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);
});
$.ajax({
url: ctx + 'system/user/list',
type: 'post',
success: function (res) {
console.log(res)
if (res.rows.length > 0) {
var usertData = res.rows;
//alert(JSON.stringify(data));
for (let i in usertData) {
// console.log(finishProductData[i].finishProductCode)
$("#selectsaleStaff").append(
"<option value='" + usertData[i].userName + "'>" + usertData[i].userName + "</option>");
}
$("#selectsaleStaff").val(userName).trigger("change");
} else {
$.modal.msgError(res.msg);
}
}
});
</script>
</body>
</html>

50
ruoyi-admin/src/main/resources/templates/system/developReviseOrder/edit.html

@ -1,50 +0,0 @@
<!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-developReviseOrder-edit" th:object="${developReviseorder}">
<input name="oderId" th:field="*{oderId}" type="hidden">
<div class="form-group">
<label class="col-sm-3 control-label">开发修改单单号:</label>
<div class="col-sm-8">
<input name="developOderCode" th:field="*{developOderCode}" 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="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="remark" th:field="*{remark}" class="form-control" type="text">
</div>
</div>
</form>
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var prefix = ctx + "system/developReviseOrder";
$("#form-developReviseOrder-edit").validate({
focusCleanup: true
});
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/edit", $('#form-developReviseOrder-edit').serialize());
}
}
</script>
</body>
</html>

6
ruoyi-system/src/main/java/com/ruoyi/system/mapper/SysUserMapper.java

@ -127,6 +127,12 @@ public interface SysUserMapper
public List<SysUser> selectAllUser();
/**
* 查找所有工程员
* */
public List<SysUser> selectSpecificRoleList(String roleKey);
@MapKey("id")
List<Map<String,String>> selectUserSelList(String userName);
}

7
ruoyi-system/src/main/java/com/ruoyi/system/service/ISysUserService.java

@ -77,6 +77,13 @@ public interface ISysUserService
*/
public List<SysUserRole> selectUserRoleByUserId(Long userId);
/**
* 查找所有工程员
*
* @return 工程员列表
*/
public List<SysUser> getSpecificRoleList(String roleKey);
/**
* 通过用户ID删除用户
*

11
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/SysUserServiceImpl.java

@ -151,6 +151,17 @@ public class SysUserServiceImpl implements ISysUserService
return userRoleMapper.selectUserRoleByUserId(userId);
}
/**
* 查找所有工程员
*
* @return 工程员列表
*/
@Override
public List<SysUser> getSpecificRoleList(String roleKey) {
List<SysUser> sysUsers = userMapper.selectSpecificRoleList(roleKey);
return sysUsers;
}
/**
* 通过用户ID删除用户
*

8
ruoyi-system/src/main/resources/mapper/system/SysUserMapper.xml

@ -228,6 +228,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="selectAllUser" resultType="SysUser" resultMap="SysUserResult">
select sys_user.user_name from sys_user
</select>
<select id="selectSpecificRoleList" parameterType="String" resultType="SysUser" resultMap="SysUserResult">
SELECT su.user_name, su.user_id
FROM sys_user su
JOIN sys_user_role sur ON su.user_id = sur.user_id
JOIN sys_role sr ON sr.role_id = sur.role_id
WHERE sr.role_key = #{roleKey}
</select>
<select id="selectUserSelList" resultType="java.util.Map">
select
login_name as id

Loading…
Cancel
Save