Procházet zdrojové kódy

密度测量,销售出货单

sunxianglong před 3 měsíci
rodič
revize
fb82006a71

+ 18 - 8
src/main/java/com/jeesite/modules/mes/entity/MesMdcl.java

@@ -20,6 +20,7 @@ import com.jeesite.common.mybatis.annotation.Table;
 		@Column(name="bao_code", attrName="baoCode", label="包号"),
 		@Column(name="md_value", attrName="mdValue", label="密度值"),
 		@Column(name="di_value", attrName="diValue", label="DI值"),
+		@Column(name="remark", attrName="remark", label="备注"),
 		@Column(name="result", attrName="result", label="判定结果"),
 		@Column(name="create_by", attrName="createBy", label="创建人", isUpdate=false, isQuery=false),
 		@Column(name="create_date", attrName="createDate", label="创建时间", isUpdate=false, isQuery=false, isUpdateForce=true),
@@ -28,23 +29,32 @@ import com.jeesite.common.mybatis.annotation.Table;
 	}, orderBy="a.update_date DESC"
 )
 public class MesMdcl extends DataEntity<MesMdcl> {
-	
+
 	private static final long serialVersionUID = 1L;
 	private String luCode;		// 炉号
 	private String baoCode;		// 包号
 	private String mdValue;		// 密度值
 	private String diValue;		// DI值
 	private String result;		// 判定结果
+	private String remark;     //备注
 	private List imgList = ListUtils.newArrayList(); // 图片
 
+	public String getRemark() {
+		return remark;
+	}
+
+	public void setRemark(String remark) {
+		this.remark = remark;
+	}
+
 	public MesMdcl() {
 		this(null);
 	}
-	
+
 	public MesMdcl(String id){
 		super(id);
 	}
-	
+
 	@Size(min=0, max=64, message="炉号长度不能超过 64 个字符")
 	public String getLuCode() {
 		return luCode;
@@ -53,7 +63,7 @@ public class MesMdcl extends DataEntity<MesMdcl> {
 	public void setLuCode(String luCode) {
 		this.luCode = luCode;
 	}
-	
+
 	@Size(min=0, max=64, message="包号长度不能超过 64 个字符")
 	public String getBaoCode() {
 		return baoCode;
@@ -62,7 +72,7 @@ public class MesMdcl extends DataEntity<MesMdcl> {
 	public void setBaoCode(String baoCode) {
 		this.baoCode = baoCode;
 	}
-	
+
 	@Size(min=0, max=64, message="密度值长度不能超过 64 个字符")
 	public String getMdValue() {
 		return mdValue;
@@ -71,7 +81,7 @@ public class MesMdcl extends DataEntity<MesMdcl> {
 	public void setMdValue(String mdValue) {
 		this.mdValue = mdValue;
 	}
-	
+
 	@Size(min=0, max=64, message="DI值长度不能超过 64 个字符")
 	public String getDiValue() {
 		return diValue;
@@ -97,5 +107,5 @@ public class MesMdcl extends DataEntity<MesMdcl> {
 	public void setImgList(List imgList) {
 		this.imgList = imgList;
 	}
-	
-}
+
+}

+ 21 - 10
src/main/java/com/jeesite/modules/mes/entity/MesProductSale.java

@@ -18,6 +18,7 @@ import com.jeesite.common.mybatis.mapper.query.QueryType;
 		@Column(name="doc_line_no", attrName="docLineNo", label="行号"),
 		@Column(name="lot_code", attrName="lotCode", label="批号"),
 		@Column(name="cp_code", attrName="cpCode", label="成品号"),
+		@Column(name="sale_qty", attrName="saleQty", label="销售数量"),
 		@Column(name="sh_state", attrName="shState", label="审核状态", comment="审核状态(1=审核后,2=弃审,3=删除)"),
 		@Column(name="mes_state", attrName="mesState", label="mes完成情况", comment="mes完成情况(1=未扫码,2=已扫码)"),
 		@Column(name="create_by", attrName="createBy", label="创建人", isUpdate=false, isQuery=false),
@@ -27,23 +28,33 @@ import com.jeesite.common.mybatis.mapper.query.QueryType;
 	}, orderBy="a.update_date DESC"
 )
 public class MesProductSale extends DataEntity<MesProductSale> {
-	
+
 	private static final long serialVersionUID = 1L;
 	private String saleOrder;		// 销售订单号
 	private String docLineNo;		// 行号
 	private String lotCode;		// 批号
 	private String cpCode;		// 成品号
+
+	private String saleQty;   //销售数量
 	private String shState;		// 审核状态(1=审核后,2=弃审,3=删除)
 	private String mesState;		// mes完成情况(1=未扫码,2=已扫码)
 
 	public MesProductSale() {
 		this(null);
 	}
-	
+
 	public MesProductSale(String id){
 		super(id);
 	}
-	
+
+	public String getSaleQty() {
+		return saleQty;
+	}
+
+	public void setSaleQty(String saleQty) {
+		this.saleQty = saleQty;
+	}
+
 	@Size(min=0, max=64, message="销售订单号长度不能超过 64 个字符")
 	public String getSaleOrder() {
 		return saleOrder;
@@ -52,7 +63,7 @@ public class MesProductSale extends DataEntity<MesProductSale> {
 	public void setSaleOrder(String saleOrder) {
 		this.saleOrder = saleOrder;
 	}
-	
+
 	@Size(min=0, max=64, message="行号长度不能超过 64 个字符")
 	public String getDocLineNo() {
 		return docLineNo;
@@ -61,7 +72,7 @@ public class MesProductSale extends DataEntity<MesProductSale> {
 	public void setDocLineNo(String docLineNo) {
 		this.docLineNo = docLineNo;
 	}
-	
+
 	@Size(min=0, max=64, message="批号长度不能超过 64 个字符")
 	public String getLotCode() {
 		return lotCode;
@@ -70,7 +81,7 @@ public class MesProductSale extends DataEntity<MesProductSale> {
 	public void setLotCode(String lotCode) {
 		this.lotCode = lotCode;
 	}
-	
+
 	@Size(min=0, max=64, message="成品号长度不能超过 64 个字符")
 	public String getCpCode() {
 		return cpCode;
@@ -79,7 +90,7 @@ public class MesProductSale extends DataEntity<MesProductSale> {
 	public void setCpCode(String cpCode) {
 		this.cpCode = cpCode;
 	}
-	
+
 	@Size(min=0, max=1, message="审核状态长度不能超过 1 个字符")
 	public String getShState() {
 		return shState;
@@ -88,7 +99,7 @@ public class MesProductSale extends DataEntity<MesProductSale> {
 	public void setShState(String shState) {
 		this.shState = shState;
 	}
-	
+
 	@Size(min=0, max=1, message="mes完成情况长度不能超过 1 个字符")
 	public String getMesState() {
 		return mesState;
@@ -97,5 +108,5 @@ public class MesProductSale extends DataEntity<MesProductSale> {
 	public void setMesState(String mesState) {
 		this.mesState = mesState;
 	}
-	
-}
+
+}

+ 2 - 2
src/main/java/com/jeesite/modules/mes/web/MesMaterialRkController.java

@@ -177,10 +177,10 @@ public class MesMaterialRkController extends BaseController {
 			return resp;
 		}
 
-		Double srcDocLineNo;
+		Long srcDocLineNo;
 		Double pcQty;
 		try {
-			srcDocLineNo = Double.valueOf(srcDocLineNoStr);
+			srcDocLineNo = Long.valueOf(srcDocLineNoStr);
 			pcQty = Double.valueOf(qtyStr);
 		} catch (NumberFormatException e) {
 			resp.setResult(Global.FALSE);

+ 5 - 0
src/main/java/com/jeesite/modules/mes/web/MesProductSaleController.java

@@ -118,6 +118,9 @@ public class MesProductSaleController extends BaseController {
 		if (StringUtils.isBlank(mesProductSale.getShState())) {
 			return renderResult(Global.FALSE, text("审核状态不能为空!"));
 		}
+		if (StringUtils.isBlank(mesProductSale.getSaleQty())) {
+			return renderResult(Global.FALSE, text("销售数量不能为空!"));
+		}
 		// 弃审(2)、删除(3):按销售订单号+行号+批号+成品号同步更新审核状态
 		if ("2".equals(mesProductSale.getShState()) || "3".equals(mesProductSale.getShState())) {
 			MesProductSale query = new MesProductSale();
@@ -152,4 +155,6 @@ public class MesProductSaleController extends BaseController {
 		return renderResult(Global.TRUE, text("保存成功!"));
 	}
 
+
+
 }

+ 1 - 0
src/main/resources/config/application.yml

@@ -742,6 +742,7 @@ shiro:
     ${adminPath}/mes/mesMaterialLl/codeList= anon
     ${adminPath}/mes/mesMaterialLl/codeInfo= anon
     ${adminPath}/mes/mesMaterialTl/mesMaterialTl= anon
+    ${adminPath}/mes/mesProductCncParam/batchsave= anon
     
     
   

+ 18 - 6
src/main/resources/views/modules/mes/mesMdclList.html

@@ -56,13 +56,25 @@
 $('#dataGrid').dataGrid({
 	searchForm: $("#searchForm"),
 	columnModel: [
-		{header:'${text("炉号")}', name:'luCode', index:'a.lu_code', width:150, align:"left", frozen:true, formatter: function(val, obj, row, act){
+		{header:'${text("炉号")}', name:'luCode', index:'a.lu_code', width:150, align:"center", frozen:true, formatter: function(val, obj, row, act){
 			return '<a href="${ctx}/mes/mesMdcl/form?id='+row.id+'" class="btnList" data-title="${text("编辑密度测量表")}">'+(val||row.id)+'</a>';
 		}},
-		{header:'${text("包号")}', name:'baoCode', index:'a.bao_code', width:150, align:"left"},
-		{header:'${text("密度值")}', name:'mdValue', index:'a.md_value', width:150, align:"left"},
-		{header:'${text("DI值")}', name:'diValue', index:'a.di_value', width:150, align:"left"},
+		{header:'${text("包号")}', name:'baoCode', index:'a.bao_code', width:150, align:"center"},
+		{header:'${text("密度标准")}', name:'mdStandard', width:100, align:"center", sortable:false, formatter: function(){
+			return '≥2.6';
+		}},
+		{header:'${text("单位")}', name:'unit', width:100, align:"center", sortable:false, formatter: function(){
+			return 'g/cm3';
+		}},
+		{header:'${text("密度值")}', name:'mdValue', index:'a.md_value', width:150, align:"center"},
+		{header:'${text("DI标准")}', name:'diStandard', width:100, align:"center", sortable:false, formatter: function(){
+			return '≤0.8';
+		}},
+		{header:'${text("DI值")}', name:'diValue', index:'a.di_value', width:150, align:"center"},
 		{header:'${text("判定结果")}', name:'result', index:'a.result', width:100, align:"center"},
+		{header:'${text("类型")}', name:'type', width:130, align:"center", sortable:false, formatter: function(){
+			return '熔炼密度检测';
+		}},
 		{header:'${text("更新时间")}', name:'updateDate', index:'a.update_date', width:150, align:"center"},
 		{header:'${text("操作")}', name:'actions', width:120, formatter: function(val, obj, row, act){
 			var actions = [];
@@ -75,7 +87,7 @@ $('#dataGrid').dataGrid({
 	],
 	// 加载成功后执行事件
 	ajaxSuccess: function(data){
-		
+
 	}
 });
-</script>
+</script>

+ 21 - 3
src/main/resources/views/modules/mes/mesProductSaleForm.html

@@ -53,9 +53,23 @@
 					<div class="col-xs-6">
 						<div class="form-group">
 							<label class="control-label col-sm-4" title="">
+								<span class="required hide">*</span> ${text('销售数量')}:<i class="fa icon-question hide"></i></label>
+							<div class="col-sm-8">
+								<#form:input path="saleQty" maxlength="64" class="form-control"/>
+							</div>
+						</div>
+					</div>
+					<div class="col-xs-6">
+						<div class="form-group">
+							<label class="control-label col-sm-4" title="">
 								<span class="required hide">*</span> ${text('审核状态')}:<i class="fa icon-question hide"></i></label>
 							<div class="col-sm-8">
-								<#form:input path="shState" maxlength="1" class="form-control"/>
+								<select name="shState" class="form-control">
+									<option value="">${text('请选择')}</option>
+									<option value="1" ${mesProductSale.shState == '1' ? 'selected' : ''}>${text('审核后')}</option>
+									<option value="2" ${mesProductSale.shState == '2' ? 'selected' : ''}>${text('弃审')}</option>
+									<option value="3" ${mesProductSale.shState == '3' ? 'selected' : ''}>${text('删除')}</option>
+								</select>
 							</div>
 						</div>
 					</div>
@@ -64,7 +78,11 @@
 							<label class="control-label col-sm-4" title="">
 								<span class="required hide">*</span> ${text('mes完成情况')}:<i class="fa icon-question hide"></i></label>
 							<div class="col-sm-8">
-								<#form:input path="mesState" maxlength="1" class="form-control"/>
+								<select name="mesState" class="form-control">
+									<option value="">${text('请选择')}</option>
+									<option value="1" ${mesProductSale.mesState == '1' ? 'selected' : ''}>${text('未扫码')}</option>
+									<option value="2" ${mesProductSale.mesState == '2' ? 'selected' : ''}>${text('已扫码')}</option>
+								</select>
 							</div>
 						</div>
 					</div>
@@ -97,4 +115,4 @@ $("#inputForm").validate({
 		}, "json");
     }
 });
-</script>
+</script>

+ 31 - 8
src/main/resources/views/modules/mes/mesProductSaleList.html

@@ -42,14 +42,23 @@
 				</div>
 				<div class="form-group">
 					<label class="control-label">${text('审核状态')}:</label>
-					<div class="control-inline">
-						<#form:input path="shState" maxlength="1" class="form-control width-120"/>
+					<div class="control-inline width-120">
+						<select name="shState" class="form-control">
+							<option value="">${text('全部')}</option>
+							<option value="1" ${mesProductSale.shState == '1' ? 'selected' : ''}>${text('审核后')}</option>
+							<option value="2" ${mesProductSale.shState == '2' ? 'selected' : ''}>${text('弃审')}</option>
+							<option value="3" ${mesProductSale.shState == '3' ? 'selected' : ''}>${text('删除')}</option>
+						</select>
 					</div>
 				</div>
 				<div class="form-group">
 					<label class="control-label">${text('mes完成情况')}:</label>
-					<div class="control-inline">
-						<#form:input path="mesState" maxlength="1" class="form-control width-120"/>
+					<div class="control-inline width-120">
+						<select name="mesState" class="form-control">
+							<option value="">${text('全部')}</option>
+							<option value="1" ${mesProductSale.mesState == '1' ? 'selected' : ''}>${text('未扫码')}</option>
+							<option value="2" ${mesProductSale.mesState == '2' ? 'selected' : ''}>${text('已扫码')}</option>
+						</select>
 					</div>
 				</div>
 				<div class="form-group">
@@ -71,11 +80,25 @@ $('#dataGrid').dataGrid({
 		{header:'${text("销售订单号")}', name:'saleOrder', index:'a.sale_order', width:150, align:"left", frozen:true, formatter: function(val, obj, row, act){
 			return '<a href="${ctx}/mes/mesProductSale/form?id='+row.id+'" class="btnList" data-title="${text("编辑销售出货单表")}">'+(val||row.id)+'</a>';
 		}},
-		{header:'${text("行号")}', name:'docLineNo', index:'a.doc_line_no', width:150, align:"left"},
+		{header:'${text("行号")}', name:'docLineNo', index:'a.doc_line_no', width:100, align:"left"},
 		{header:'${text("批号")}', name:'lotCode', index:'a.lot_code', width:150, align:"left"},
 		{header:'${text("成品号")}', name:'cpCode', index:'a.cp_code', width:150, align:"left"},
-		{header:'${text("审核状态")}', name:'shState', index:'a.sh_state', width:150, align:"left"},
-		{header:'${text("mes完成情况")}', name:'mesState', index:'a.mes_state', width:150, align:"left"},
+		{header:'${text("销售数量")}', name:'saleQty', index:'a.sale_qty', width:100, align:"center"},
+		{header:'${text("审核状态")}', name:'shState', index:'a.sh_state', width:100, align:"center", formatter: function(val, obj, row, act){
+			var stateMap = {
+				'1': '${text("审核后")}',
+				'2': '${text("弃审")}',
+				'3': '${text("删除")}'
+			};
+			return stateMap[String(val)] || '${text("未知")}';
+		}},
+		{header:'${text("mes完成情况")}', name:'mesState', index:'a.mes_state', width:100, align:"center", formatter: function(val, obj, row, act){
+			var stateMap = {
+				'1': '${text("未扫码")}',
+				'2': '${text("已扫码")}'
+			};
+			return stateMap[String(val)] || '${text("未知")}';
+		}},
 		{header:'${text("更新时间")}', name:'updateDate', index:'a.update_date', width:150, align:"center"},
 		{header:'${text("操作")}', name:'actions', width:120, formatter: function(val, obj, row, act){
 			var actions = [];
@@ -91,4 +114,4 @@ $('#dataGrid').dataGrid({
 		
 	}
 });
-</script>
+</script>