Commit f37e2510 by 江和松

物料清单明细页面操作处理、提交处理

parent d6dd4825
...@@ -73,6 +73,12 @@ public enum DdynamicEnum { ...@@ -73,6 +73,12 @@ public enum DdynamicEnum {
INVENT_RECORD_BLOCK_ID("invent_record_block_id","inventCode","inventName","HGPZ005.queryComboBox"), INVENT_RECORD_BLOCK_ID("invent_record_block_id","inventCode","inventName","HGPZ005.queryComboBox"),
/** /**
* 模块:存货档案
* 用途:存货档案下拉框,带id名称等信息
* 编写:
*/
PRODUCT_BLOCK_ID("product_block_id","inventCode","inventName","id","inventType","HGPZ005.queryProductComboBox"),
/**
* 模块:存货档案(ALL) * 模块:存货档案(ALL)
* 用途:存货档案下拉框 * 用途:存货档案下拉框
* 编写: * 编写:
......
...@@ -12,6 +12,7 @@ import org.apache.commons.collections.CollectionUtils; ...@@ -12,6 +12,7 @@ import org.apache.commons.collections.CollectionUtils;
import org.apache.commons.collections.MapUtils; import org.apache.commons.collections.MapUtils;
import org.apache.commons.lang.StringUtils; import org.apache.commons.lang.StringUtils;
import java.util.Collection;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
...@@ -23,7 +24,7 @@ import lombok.extern.slf4j.Slf4j; ...@@ -23,7 +24,7 @@ import lombok.extern.slf4j.Slf4j;
*/ */
@Slf4j @Slf4j
public class DaoUtils { public class DaoUtils {
/** /**
* count 查询 * count 查询
* *
...@@ -36,7 +37,7 @@ public class DaoUtils { ...@@ -36,7 +37,7 @@ public class DaoUtils {
List<Integer> countMaps = DaoBase.getInstance().query(sqlName, paramMap); List<Integer> countMaps = DaoBase.getInstance().query(sqlName, paramMap);
return CollectionUtils.isEmpty(countMaps) ? 0 : countMaps.get(0).intValue(); return CollectionUtils.isEmpty(countMaps) ? 0 : countMaps.get(0).intValue();
} }
/** /**
* insert method. * insert method.
* *
...@@ -56,7 +57,7 @@ public class DaoUtils { ...@@ -56,7 +57,7 @@ public class DaoUtils {
} }
DaoBase.getInstance().insert(sql, obj); DaoBase.getInstance().insert(sql, obj);
} }
/** /**
* update method. * update method.
* *
...@@ -71,7 +72,24 @@ public class DaoUtils { ...@@ -71,7 +72,24 @@ public class DaoUtils {
} }
return DaoBase.getInstance().update(sql, obj); return DaoBase.getInstance().update(sql, obj);
} }
/**
* update method.
*
* @param sql
* @param parameters
*/
public static int updateBatch(String sql, Collection parameters) {
parameters.forEach(obj->{
if (obj instanceof DaoEPBase) {
setRevisor((DaoEPBase) obj, true);
} else if (obj instanceof Map) {
setRevisor((Map) obj, true);
}
});
return DaoBase.getInstance().updateBatch(sql, parameters);
}
/** /**
* 创建人工号 创建人姓名 创建人岗号 创建时刻 * 创建人工号 创建人姓名 创建人岗号 创建时刻
* *
...@@ -136,7 +154,7 @@ public class DaoUtils { ...@@ -136,7 +154,7 @@ public class DaoUtils {
log.error("写入创建时刻失败:{}", e.getMessage(), e); log.error("写入创建时刻失败:{}", e.getMessage(), e);
} }
} }
/** /**
* 创建人工号 创建人姓名 创建时刻. * 创建人工号 创建人姓名 创建时刻.
* *
...@@ -197,7 +215,7 @@ public class DaoUtils { ...@@ -197,7 +215,7 @@ public class DaoUtils {
log.warn("写入创建时刻失败", e); log.warn("写入创建时刻失败", e);
} }
} }
/** /**
* 修改人工号 修改人姓名 修改人岗号 修改时刻 记录修改代理人工号 记录修改代理人姓名. * 修改人工号 修改人姓名 修改人岗号 修改时刻 记录修改代理人工号 记录修改代理人姓名.
* *
...@@ -232,7 +250,7 @@ public class DaoUtils { ...@@ -232,7 +250,7 @@ public class DaoUtils {
log.warn("写入修改时刻失败", e); log.warn("写入修改时刻失败", e);
} }
} }
/** /**
* 修改人工号 修改人姓名 修改人岗号 修改时刻 记录修改代理人工号 记录修改代理人姓名. * 修改人工号 修改人姓名 修改人岗号 修改时刻 记录修改代理人工号 记录修改代理人姓名.
* *
...@@ -264,5 +282,5 @@ public class DaoUtils { ...@@ -264,5 +282,5 @@ public class DaoUtils {
// 修改时间 // 修改时间
map.put("updatedTime", DateUtils.shortDateTime()); map.put("updatedTime", DateUtils.shortDateTime());
} }
} }
...@@ -236,7 +236,7 @@ public class HGConstant { ...@@ -236,7 +236,7 @@ public class HGConstant {
// 未提交 // 未提交
public static final Integer WTJ = 0; public static final Integer WTJ = 0;
// 已提交 // 已提交
public static final Integer YTJ = 2; public static final Integer YTJ = 1;
} }
} }
...@@ -315,6 +315,30 @@ ...@@ -315,6 +315,30 @@
ORDER BY INVENT_CODE ORDER BY INVENT_CODE
</select> </select>
<select id="queryProductComboBox" parameterClass="java.util.HashMap"
resultClass="java.util.HashMap">
SELECT DISTINCT
a.ID as "id",
a.INVENT_TYPE as "inventType",
a.INVENT_CODE as "inventCode",
a.INVENT_NAME as "inventName",
b.PAR_INVENT_TYPE as "parInventType"
FROM ${hggpSchema}.HGPZ005 a
left join ${hggpSchema}.hgpz004 b on a.INVENT_TYPE = b.INVENT_TYPE and b.STATUS=1 and b.DELETE_FLAG = 0
WHERE a.DELETE_FLAG = 0
AND a.STATUS=1
<isNotEmpty prepend=" AND " property="accountCode">
a.ACCOUNT_CODE = #accountCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="inventType">
a.INVENT_TYPE = #inventType#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="parInventType">
b.PAR_INVENT_TYPE = #parInventType#
</isNotEmpty>
ORDER BY INVENT_CODE
</select>
<!-- 缺省下拉框 --> <!-- 缺省下拉框 -->
<select id="queryComboBoxAll" parameterClass="java.util.HashMap" resultClass="java.util.HashMap"> <select id="queryComboBoxAll" parameterClass="java.util.HashMap" resultClass="java.util.HashMap">
SELECT DISTINCT SELECT DISTINCT
......
...@@ -40,6 +40,7 @@ public class HGSC004 extends DaoEPBase { ...@@ -40,6 +40,7 @@ public class HGSC004 extends DaoEPBase {
public static final String FIELD_updated_by = "updatedBy"; /* 更新人*/ public static final String FIELD_updated_by = "updatedBy"; /* 更新人*/
public static final String FIELD_updated_name = "updatedName"; /* 修改人名称*/ public static final String FIELD_updated_name = "updatedName"; /* 修改人名称*/
public static final String FIELD_updated_time = "updatedTime"; /* 更新时间*/ public static final String FIELD_updated_time = "updatedTime"; /* 更新时间*/
public static final String FIELD_del_status = "delStatus"; /* 数据状态 0:保存,1:删除*/
public static final String COL_id = "id"; /* 主键*/ public static final String COL_id = "id"; /* 主键*/
public static final String COL_blueprint_id = "blueprint_id"; /* 蓝图id*/ public static final String COL_blueprint_id = "blueprint_id"; /* 蓝图id*/
...@@ -60,6 +61,7 @@ public class HGSC004 extends DaoEPBase { ...@@ -60,6 +61,7 @@ public class HGSC004 extends DaoEPBase {
public static final String COL_updated_by = "updated_by"; /* 更新人*/ public static final String COL_updated_by = "updated_by"; /* 更新人*/
public static final String COL_updated_name = "updated_name"; /* 修改人名称*/ public static final String COL_updated_name = "updated_name"; /* 修改人名称*/
public static final String COL_updated_time = "updated_time"; /* 更新时间*/ public static final String COL_updated_time = "updated_time"; /* 更新时间*/
public static final String COL_del_status = "del_status"; /* 数据状态 0:保存,1:删除*/
public static final String QUERY = "HGSC004.query"; public static final String QUERY = "HGSC004.query";
public static final String COUNT = "HGSC004.count"; public static final String COUNT = "HGSC004.count";
...@@ -67,8 +69,8 @@ public class HGSC004 extends DaoEPBase { ...@@ -67,8 +69,8 @@ public class HGSC004 extends DaoEPBase {
public static final String UPDATE = "HGSC004.update"; public static final String UPDATE = "HGSC004.update";
public static final String DELETE = "HGSC004.delete"; public static final String DELETE = "HGSC004.delete";
public static final String BATCH_DELETE = "HGSC004.batchDelete"; public static final String BATCH_DELETE = "HGSC004.batchDelete";
public static final String BATCH_SUBMIT = "HGSC004.batchSubmit"; public static final String UPDATE_DEL = "HGSC004.updateDel";
public static final String UPDATE_MATERIAL_STATUS = "HGSC004.updateMaterialStatus";
private Long id = new Long(0); /* 主键*/ private Long id = new Long(0); /* 主键*/
private Long blueprintId = new Long(0); /* 蓝图id*/ private Long blueprintId = new Long(0); /* 蓝图id*/
...@@ -89,6 +91,7 @@ public class HGSC004 extends DaoEPBase { ...@@ -89,6 +91,7 @@ public class HGSC004 extends DaoEPBase {
private String updatedBy = " "; /* 更新人*/ private String updatedBy = " "; /* 更新人*/
private String updatedName = " "; /* 修改人名称*/ private String updatedName = " "; /* 修改人名称*/
private String updatedTime = " "; /* 更新时间*/ private String updatedTime = " "; /* 更新时间*/
private Integer delStatus = new Integer(0); /* 数据状态 0:保存,1:删除*/
/** /**
* initialize the metadata. * initialize the metadata.
...@@ -199,7 +202,9 @@ public class HGSC004 extends DaoEPBase { ...@@ -199,7 +202,9 @@ public class HGSC004 extends DaoEPBase {
eiColumn.setDescName("更新时间"); eiColumn.setDescName("更新时间");
eiMetadata.addMeta(eiColumn); eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_del_status);
eiColumn.setDescName("数据状态 0:保存,1:删除");
eiMetadata.addMeta(eiColumn);
} }
/** /**
...@@ -513,6 +518,15 @@ public class HGSC004 extends DaoEPBase { ...@@ -513,6 +518,15 @@ public class HGSC004 extends DaoEPBase {
public void setUpdatedTime(String updatedTime) { public void setUpdatedTime(String updatedTime) {
this.updatedTime = updatedTime; this.updatedTime = updatedTime;
} }
public Integer getDelStatus() {
return delStatus;
}
public void setDelStatus(Integer delStatus) {
this.delStatus = delStatus;
}
/** /**
* get the value from Map. * get the value from Map.
* *
...@@ -540,6 +554,7 @@ public class HGSC004 extends DaoEPBase { ...@@ -540,6 +554,7 @@ public class HGSC004 extends DaoEPBase {
setUpdatedBy(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_updated_by)), updatedBy)); setUpdatedBy(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_updated_by)), updatedBy));
setUpdatedName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_updated_name)), updatedName)); setUpdatedName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_updated_name)), updatedName));
setUpdatedTime(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_updated_time)), updatedTime)); setUpdatedTime(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_updated_time)), updatedTime));
setDelStatus(NumberUtils.toInteger(StringUtils.toString(map.get(FIELD_del_status)), delStatus));
} }
/** /**
...@@ -568,6 +583,7 @@ public class HGSC004 extends DaoEPBase { ...@@ -568,6 +583,7 @@ public class HGSC004 extends DaoEPBase {
map.put(FIELD_updated_by, StringUtils.toString(updatedBy, eiMetadata.getMeta(FIELD_updated_by))); map.put(FIELD_updated_by, StringUtils.toString(updatedBy, eiMetadata.getMeta(FIELD_updated_by)));
map.put(FIELD_updated_name, StringUtils.toString(updatedName, eiMetadata.getMeta(FIELD_updated_name))); map.put(FIELD_updated_name, StringUtils.toString(updatedName, eiMetadata.getMeta(FIELD_updated_name)));
map.put(FIELD_updated_time, StringUtils.toString(updatedTime, eiMetadata.getMeta(FIELD_updated_time))); map.put(FIELD_updated_time, StringUtils.toString(updatedTime, eiMetadata.getMeta(FIELD_updated_time)));
map.put(FIELD_del_status, StringUtils.toString(delStatus, eiMetadata.getMeta(FIELD_del_status)));
return map; return map;
} }
......
...@@ -31,9 +31,14 @@ public class HGSC004A extends DaoEPBase { ...@@ -31,9 +31,14 @@ public class HGSC004A extends DaoEPBase {
public static final String FIELD_proj_name = "projName"; /* 项目名称(预留)*/ public static final String FIELD_proj_name = "projName"; /* 项目名称(预留)*/
public static final String FIELD_parent_prod_code = "parentProdCode"; /* 父节点-产品编码*/ public static final String FIELD_parent_prod_code = "parentProdCode"; /* 父节点-产品编码*/
public static final String FIELD_parent_prod_name = "parentProdName"; /* 父节点-产品名称*/ public static final String FIELD_parent_prod_name = "parentProdName"; /* 父节点-产品名称*/
public static final String FIELD_leaf = "leaf"; /* 是否有叶子节点*/
public static final String FIELD_sort = "sort"; /* 排序字段*/
public static final String FIELD_lv = "lv"; /* 层级*/
public static final String FIELD_material_id = "materialId"; /* 物料清单id*/ public static final String FIELD_material_id = "materialId"; /* 物料清单id*/
public static final String FIELD_product_id = "productId"; /* 产品id*/
public static final String FIELD_product_code = "productCode"; /* 产品编号*/ public static final String FIELD_product_code = "productCode"; /* 产品编号*/
public static final String FIELD_product_name = "productName"; /* 产品名称*/ public static final String FIELD_product_name = "productName"; /* 产品名称*/
public static final String FIELD_product_type = "productType"; /* 产品type*/
public static final String FIELD_product_status = "productStatus"; /* 产品状态 0:未提交,1:已提交*/ public static final String FIELD_product_status = "productStatus"; /* 产品状态 0:未提交,1:已提交*/
public static final String FIELD_change_type = "changeType"; /* 变更类型:默认0,1:增加,2:替换,3:删除*/ public static final String FIELD_change_type = "changeType"; /* 变更类型:默认0,1:增加,2:替换,3:删除*/
public static final String FIELD_quantity = "quantity"; /* 数量*/ public static final String FIELD_quantity = "quantity"; /* 数量*/
...@@ -57,9 +62,14 @@ public class HGSC004A extends DaoEPBase { ...@@ -57,9 +62,14 @@ public class HGSC004A extends DaoEPBase {
public static final String COL_proj_name = "proj_name"; /* 项目名称(预留)*/ public static final String COL_proj_name = "proj_name"; /* 项目名称(预留)*/
public static final String COL_parent_prod_code = "parent_prod_code"; /* 父节点-产品编码*/ public static final String COL_parent_prod_code = "parent_prod_code"; /* 父节点-产品编码*/
public static final String COL_parent_prod_name = "parent_prod_name"; /* 父节点-产品名称*/ public static final String COL_parent_prod_name = "parent_prod_name"; /* 父节点-产品名称*/
public static final String COL_leaf = "leaf"; /* 是否有叶子节点*/
public static final String COL_sort = "sort"; /* 排序字段*/
public static final String COL_lv = "lv"; /* 层级*/
public static final String COL_material_id = "material_id"; /* 物料清单id*/ public static final String COL_material_id = "material_id"; /* 物料清单id*/
public static final String COL_product_id = "product_id"; /* 产品id*/
public static final String COL_product_code = "product_code"; /* 产品编号*/ public static final String COL_product_code = "product_code"; /* 产品编号*/
public static final String COL_product_name = "product_name"; /* 产品名称*/ public static final String COL_product_name = "product_name"; /* 产品名称*/
public static final String COL_product_type = "product_type"; /* 产品类型*/
public static final String COL_product_status = "product_status"; /* 产品状态 0:未提交,1:已提交*/ public static final String COL_product_status = "product_status"; /* 产品状态 0:未提交,1:已提交*/
public static final String COL_change_type = "change_type"; /* 变更类型:默认0,1:增加,2:替换,3:删除*/ public static final String COL_change_type = "change_type"; /* 变更类型:默认0,1:增加,2:替换,3:删除*/
public static final String COL_quantity = "quantity"; /* 数量*/ public static final String COL_quantity = "quantity"; /* 数量*/
...@@ -79,6 +89,11 @@ public class HGSC004A extends DaoEPBase { ...@@ -79,6 +89,11 @@ public class HGSC004A extends DaoEPBase {
public static final String INSERT = "HGSC004A.insert"; public static final String INSERT = "HGSC004A.insert";
public static final String UPDATE = "HGSC004A.update"; public static final String UPDATE = "HGSC004A.update";
public static final String DELETE = "HGSC004A.delete"; public static final String DELETE = "HGSC004A.delete";
public static final String BATCH_DELETE = "HGSC004A.batchDelete";
public static final String QUERY_ALL = "HGSC004A.queryAll";
public static final String UPDATE_PRODUCT_STATUS = "HGSC004A.updateProductStatus";
private Long id = new Long(0); /* 主键*/ private Long id = new Long(0); /* 主键*/
private String companyCode = " "; /* 公司编码(预留)*/ private String companyCode = " "; /* 公司编码(预留)*/
...@@ -89,9 +104,14 @@ public class HGSC004A extends DaoEPBase { ...@@ -89,9 +104,14 @@ public class HGSC004A extends DaoEPBase {
private String projName = " "; /* 项目名称(预留)*/ private String projName = " "; /* 项目名称(预留)*/
private String parentProdCode = " "; /* 父节点-产品编码*/ private String parentProdCode = " "; /* 父节点-产品编码*/
private String parentProdName = " "; /* 父节点-产品名称*/ private String parentProdName = " "; /* 父节点-产品名称*/
private Integer leaf = new Integer(1); /* 是否有叶子节点*/
private Integer sort = new Integer(1); /* 排序字段*/
private Integer lv = new Integer(0);; /* 树的层级*/
private Long materialId = new Long(0); /* 物料清单id*/ private Long materialId = new Long(0); /* 物料清单id*/
private Long productId = new Long(0); /* 产品id*/
private String productCode = " "; /* 产品编号*/ private String productCode = " "; /* 产品编号*/
private String productName = " "; /* 产品名称*/ private String productName = " "; /* 产品名称*/
private String productType = " "; /* 产品id*/
private Integer productStatus = new Integer(0); /* 产品状态 0:未提交,1:已提交*/ private Integer productStatus = new Integer(0); /* 产品状态 0:未提交,1:已提交*/
private Integer changeType = new Integer(0); /* 变更类型:默认0,1:增加,2:替换,3:删除*/ private Integer changeType = new Integer(0); /* 变更类型:默认0,1:增加,2:替换,3:删除*/
private Integer quantity = new Integer(0); /* 数量*/ private Integer quantity = new Integer(0); /* 数量*/
...@@ -159,6 +179,18 @@ public class HGSC004A extends DaoEPBase { ...@@ -159,6 +179,18 @@ public class HGSC004A extends DaoEPBase {
eiColumn.setDescName("父节点-产品名称"); eiColumn.setDescName("父节点-产品名称");
eiMetadata.addMeta(eiColumn); eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_leaf);
eiColumn.setDescName("是否有叶子节点");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_sort);
eiColumn.setDescName("排序字段");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_lv);
eiColumn.setDescName("层级");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_material_id); eiColumn = new EiColumn(FIELD_material_id);
eiColumn.setType("N"); eiColumn.setType("N");
eiColumn.setScaleLength(0); eiColumn.setScaleLength(0);
...@@ -166,6 +198,12 @@ public class HGSC004A extends DaoEPBase { ...@@ -166,6 +198,12 @@ public class HGSC004A extends DaoEPBase {
eiColumn.setDescName("物料清单id"); eiColumn.setDescName("物料清单id");
eiMetadata.addMeta(eiColumn); eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_product_id);
eiColumn.setFieldLength(20);
eiColumn.setDescName("产品Id");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_product_code); eiColumn = new EiColumn(FIELD_product_code);
eiColumn.setFieldLength(32); eiColumn.setFieldLength(32);
eiColumn.setDescName("产品编号"); eiColumn.setDescName("产品编号");
...@@ -176,6 +214,11 @@ public class HGSC004A extends DaoEPBase { ...@@ -176,6 +214,11 @@ public class HGSC004A extends DaoEPBase {
eiColumn.setDescName("产品名称"); eiColumn.setDescName("产品名称");
eiMetadata.addMeta(eiColumn); eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_product_type);
eiColumn.setFieldLength(32);
eiColumn.setDescName("产品类型");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_product_status); eiColumn = new EiColumn(FIELD_product_status);
eiColumn.setType("N"); eiColumn.setType("N");
eiColumn.setScaleLength(0); eiColumn.setScaleLength(0);
...@@ -663,6 +706,47 @@ public class HGSC004A extends DaoEPBase { ...@@ -663,6 +706,47 @@ public class HGSC004A extends DaoEPBase {
public void setUpdatedTime(String updatedTime) { public void setUpdatedTime(String updatedTime) {
this.updatedTime = updatedTime; this.updatedTime = updatedTime;
} }
public Integer getLeaf() {
return leaf;
}
public void setLeaf(Integer leaf) {
this.leaf = leaf;
}
public Integer getSort() {
return sort;
}
public void setSort(Integer sort) {
this.sort = sort;
}
public Integer getLv() {
return lv;
}
public void setLv(Integer lv) {
this.lv = lv;
}
public Long getProductId() {
return productId;
}
public void setProductId(Long productId) {
this.productId = productId;
}
public String getProductType() {
return productType;
}
public void setProductType(String productType) {
this.productType = productType;
}
/** /**
* get the value from Map. * get the value from Map.
* *
...@@ -680,9 +764,14 @@ public class HGSC004A extends DaoEPBase { ...@@ -680,9 +764,14 @@ public class HGSC004A extends DaoEPBase {
setProjName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_proj_name)), projName)); setProjName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_proj_name)), projName));
setParentProdCode(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_parent_prod_code)), parentProdCode)); setParentProdCode(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_parent_prod_code)), parentProdCode));
setParentProdName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_parent_prod_name)), parentProdName)); setParentProdName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_parent_prod_name)), parentProdName));
setLeaf(NumberUtils.toInteger(StringUtils.toString(map.get(FIELD_leaf)), leaf));
setSort(NumberUtils.toInteger(StringUtils.toString(map.get(FIELD_sort)), sort));
setLv(NumberUtils.toInteger(StringUtils.toString(map.get(FIELD_lv)), lv));
setMaterialId(NumberUtils.toLong(StringUtils.toString(map.get(FIELD_material_id)), materialId)); setMaterialId(NumberUtils.toLong(StringUtils.toString(map.get(FIELD_material_id)), materialId));
setProductCode(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_product_code)), productCode)); setProductCode(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_product_code)), productCode));
setProductName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_product_name)), productName)); setProductName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_product_name)), productName));
setProductId(NumberUtils.toLong(StringUtils.toString(map.get(FIELD_product_id)), productId));
setProductType(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_product_type)), productType));
setProductStatus(NumberUtils.toInteger(StringUtils.toString(map.get(FIELD_product_status)), productStatus)); setProductStatus(NumberUtils.toInteger(StringUtils.toString(map.get(FIELD_product_status)), productStatus));
setChangeType(NumberUtils.toInteger(StringUtils.toString(map.get(FIELD_change_type)), changeType)); setChangeType(NumberUtils.toInteger(StringUtils.toString(map.get(FIELD_change_type)), changeType));
setQuantity(NumberUtils.toInteger(StringUtils.toString(map.get(FIELD_quantity)), quantity)); setQuantity(NumberUtils.toInteger(StringUtils.toString(map.get(FIELD_quantity)), quantity));
...@@ -714,9 +803,14 @@ public class HGSC004A extends DaoEPBase { ...@@ -714,9 +803,14 @@ public class HGSC004A extends DaoEPBase {
map.put(FIELD_proj_name, StringUtils.toString(projName, eiMetadata.getMeta(FIELD_proj_name))); map.put(FIELD_proj_name, StringUtils.toString(projName, eiMetadata.getMeta(FIELD_proj_name)));
map.put(FIELD_parent_prod_code, StringUtils.toString(parentProdCode, eiMetadata.getMeta(FIELD_parent_prod_code))); map.put(FIELD_parent_prod_code, StringUtils.toString(parentProdCode, eiMetadata.getMeta(FIELD_parent_prod_code)));
map.put(FIELD_parent_prod_name, StringUtils.toString(parentProdName, eiMetadata.getMeta(FIELD_parent_prod_name))); map.put(FIELD_parent_prod_name, StringUtils.toString(parentProdName, eiMetadata.getMeta(FIELD_parent_prod_name)));
map.put(FIELD_leaf, StringUtils.toString(leaf, eiMetadata.getMeta(FIELD_leaf)));
map.put(FIELD_sort, StringUtils.toString(sort, eiMetadata.getMeta(FIELD_sort)));
map.put(FIELD_lv, StringUtils.toString(lv, eiMetadata.getMeta(FIELD_lv)));
map.put(FIELD_material_id, StringUtils.toString(materialId, eiMetadata.getMeta(FIELD_material_id))); map.put(FIELD_material_id, StringUtils.toString(materialId, eiMetadata.getMeta(FIELD_material_id)));
map.put(FIELD_product_code, StringUtils.toString(productCode, eiMetadata.getMeta(FIELD_product_code))); map.put(FIELD_product_code, StringUtils.toString(productCode, eiMetadata.getMeta(FIELD_product_code)));
map.put(FIELD_product_name, StringUtils.toString(productName, eiMetadata.getMeta(FIELD_product_name))); map.put(FIELD_product_name, StringUtils.toString(productName, eiMetadata.getMeta(FIELD_product_name)));
map.put(FIELD_product_id, StringUtils.toString(productId, eiMetadata.getMeta(FIELD_product_id)));
map.put(FIELD_product_type, StringUtils.toString(productName, eiMetadata.getMeta(FIELD_product_type)));
map.put(FIELD_product_status, StringUtils.toString(productStatus, eiMetadata.getMeta(FIELD_product_status))); map.put(FIELD_product_status, StringUtils.toString(productStatus, eiMetadata.getMeta(FIELD_product_status)));
map.put(FIELD_change_type, StringUtils.toString(changeType, eiMetadata.getMeta(FIELD_change_type))); map.put(FIELD_change_type, StringUtils.toString(changeType, eiMetadata.getMeta(FIELD_change_type)));
map.put(FIELD_quantity, StringUtils.toString(quantity, eiMetadata.getMeta(FIELD_quantity))); map.put(FIELD_quantity, StringUtils.toString(quantity, eiMetadata.getMeta(FIELD_quantity)));
......
package com.baosight.hggp.hg.sc.service; package com.baosight.hggp.hg.sc.service;
import cn.hutool.core.bean.BeanUtil;
import com.baosight.hggp.common.DdynamicEnum; import com.baosight.hggp.common.DdynamicEnum;
import com.baosight.hggp.core.dao.DaoUtils; import com.baosight.hggp.core.dao.DaoUtils;
import com.baosight.hggp.core.security.UserSessionUtils; import com.baosight.hggp.core.security.UserSessionUtils;
import com.baosight.hggp.hg.constant.HGConstant; import com.baosight.hggp.hg.constant.HGConstant;
import com.baosight.hggp.hg.sc.domain.HGSC003; import com.baosight.hggp.hg.sc.domain.HGSC003;
import com.baosight.hggp.hg.sc.domain.HGSC004; import com.baosight.hggp.hg.sc.domain.HGSC004;
import com.baosight.hggp.hg.sc.domain.HGSC004A;
import com.baosight.hggp.util.*; import com.baosight.hggp.util.*;
import com.baosight.iplat4j.core.ei.EiConstant; import com.baosight.iplat4j.core.ei.EiConstant;
import com.baosight.iplat4j.core.ei.EiInfo; import com.baosight.iplat4j.core.ei.EiInfo;
import com.baosight.iplat4j.core.exception.PlatException; import com.baosight.iplat4j.core.exception.PlatException;
import com.baosight.iplat4j.core.service.impl.ServiceBase; import com.baosight.iplat4j.core.service.impl.ServiceBase;
import org.springframework.util.CollectionUtils;
import java.util.*; import java.util.*;
import java.util.stream.Collectors;
/** /**
...@@ -58,7 +62,26 @@ public class ServiceHGSC004 extends ServiceBase { ...@@ -58,7 +62,26 @@ public class ServiceHGSC004 extends ServiceBase {
List<Map> resultRows = inInfo.getBlock(EiConstant.resultBlock).getRows(); List<Map> resultRows = inInfo.getBlock(EiConstant.resultBlock).getRows();
// 蓝图ids // 蓝图ids
List<Long> ids = ObjectUtils.listKey(resultRows, HGSC004.FIELD_id); List<Long> ids = ObjectUtils.listKey(resultRows, HGSC004.FIELD_id);
DaoUtils.update(HGSC004.BATCH_DELETE, new HashMap<String,Object>(){{put("ids",ids);}}); //变更清单里面的公司、项目信息
Map<String,Object> map = new HashMap<>();
map.put("ids",ids);
List<HGSC004> hgsc004List = this.dao.query(HGSC004.QUERY,map, 0, -999999);
for(HGSC004 hgsc004 : hgsc004List){
//如果
if(hgsc004.getMaterialStatus().intValue() == HGConstant.MaterialStatus.WTJ.intValue()){
//变更清单里面的公司、项目信息
Map<String,Object> mapA = new HashMap<>();
mapA.put("materialIds",ids);
List<HGSC004A> hgsc004AList = dao.query(HGSC004A.QUERY_ALL,mapA, 0, -999999);
if(!CollectionUtils.isEmpty(hgsc004AList)){
List<Long> detailIds = hgsc004AList.stream().map(HGSC004A::getId).collect(Collectors.toList());
DaoUtils.update(HGSC004A.BATCH_DELETE, new HashMap<String,Object>(){{put("ids",detailIds);}});
}
DaoUtils.update(HGSC004.DELETE, hgsc004);
}else{
DaoUtils.update(HGSC004.UPDATE_DEL, hgsc004);
}
}
inInfo = this.query(inInfo); inInfo = this.query(inInfo);
inInfo.setStatus(EiConstant.STATUS_DEFAULT); inInfo.setStatus(EiConstant.STATUS_DEFAULT);
inInfo.setMsg("操作成功!本次对[" + resultRows.size() + "]条数据删除成功!"); inInfo.setMsg("操作成功!本次对[" + resultRows.size() + "]条数据删除成功!");
...@@ -68,21 +91,6 @@ public class ServiceHGSC004 extends ServiceBase { ...@@ -68,21 +91,6 @@ public class ServiceHGSC004 extends ServiceBase {
return inInfo; return inInfo;
} }
public EiInfo batchSubmit(EiInfo inInfo) {
try {
List<Map> resultRows = inInfo.getBlock(EiConstant.resultBlock).getRows();
// 蓝图ids
List<Long> ids = ObjectUtils.listKey(resultRows, "id");
DaoUtils.update(HGSC004.BATCH_SUBMIT, new HashMap<String,Object>(){{put("ids",ids);}});
inInfo = this.query(inInfo);
inInfo.setStatus(EiConstant.STATUS_DEFAULT);
inInfo.setMsg("操作成功!本次对[" + resultRows.size() + "]条数据停用成功!");
} catch (Exception e) {
LogUtils.setDetailMsg(inInfo, e, "操作失败");
}
return inInfo;
}
public EiInfo save(EiInfo inInfo){ public EiInfo save(EiInfo inInfo){
try { try {
Map resultMap = EiInfoUtils.getFirstRow(inInfo,EiConstant.resultBlock); Map resultMap = EiInfoUtils.getFirstRow(inInfo,EiConstant.resultBlock);
...@@ -93,10 +101,24 @@ public class ServiceHGSC004 extends ServiceBase { ...@@ -93,10 +101,24 @@ public class ServiceHGSC004 extends ServiceBase {
this.checkSaveData(hgsc004,hgsc003); this.checkSaveData(hgsc004,hgsc003);
if(Objects.nonNull(hgsc004.getId())&&hgsc004.getId()!=0){ if(Objects.nonNull(hgsc004.getId())&&hgsc004.getId()!=0){
DaoUtils.update(HGSC004.UPDATE, hgsc004); DaoUtils.update(HGSC004.UPDATE, hgsc004);
//变更清单里面的公司、项目信息
Map<String,Object> map = new HashMap<>();
map.put("materialId",hgsc004.getId());
List<HGSC004A> hgsc004AList = dao.query(HGSC004A.QUERY_ALL,map, 0, -999999);
hgsc004AList.forEach(o->{
o.setProjCode(hgsc004.getProjCode());
o.setProjName(hgsc004.getProjName());
o.setCompanyCode(hgsc004.getCompanyCode());
o.setCompanyName(hgsc004.getCompanyName());
});
DaoUtils.updateBatch(HGSC004A.UPDATE, hgsc004AList);
}else { }else {
hgsc004.setMaterialStatus(HGConstant.MaterialStatus.WTJ); hgsc004.setMaterialStatus(HGConstant.MaterialStatus.WTJ);
DaoUtils.insert(HGSC004.INSERT, hgsc004); DaoUtils.insert(HGSC004.INSERT, hgsc004);
this.insertTree(hgsc004);
} }
inInfo.setStatus(EiConstant.STATUS_DEFAULT); inInfo.setStatus(EiConstant.STATUS_DEFAULT);
inInfo.setMsg("保存成功!"); inInfo.setMsg("保存成功!");
} catch (Exception e) { } catch (Exception e) {
...@@ -112,6 +134,7 @@ public class ServiceHGSC004 extends ServiceBase { ...@@ -112,6 +134,7 @@ public class ServiceHGSC004 extends ServiceBase {
*/ */
private void checkSaveData(HGSC004 hgsc004,HGSC003 hgsc003) { private void checkSaveData(HGSC004 hgsc004,HGSC003 hgsc003) {
if(Objects.nonNull(hgsc004.getId())&&hgsc004.getId()>0){ if(Objects.nonNull(hgsc004.getId())&&hgsc004.getId()>0){
AssertUtils.isTrue(hgsc004.getMaterialStatus().compareTo(HGConstant.MaterialStatus.WTJ) > 0,"非未提交不可修改!");
AssertUtils.isTrue(hgsc003.getBlueprintStatus().compareTo(HGConstant.EnablingStatus.TY) == 0,"蓝图已停用不可修改!"); AssertUtils.isTrue(hgsc003.getBlueprintStatus().compareTo(HGConstant.EnablingStatus.TY) == 0,"蓝图已停用不可修改!");
} }
Map<String,Object> map = new HashMap<>(); Map<String,Object> map = new HashMap<>();
...@@ -134,6 +157,46 @@ public class ServiceHGSC004 extends ServiceBase { ...@@ -134,6 +157,46 @@ public class ServiceHGSC004 extends ServiceBase {
} }
/**
* 录入树结构
*
* @param hgsc004
*/
private void insertTree(HGSC004 hgsc004) {
//变更清单里面的公司、项目信息
Map<String,Object> map = new HashMap<>();
map.put("companyCode",hgsc004.getCompanyCode());
map.put("projCode",hgsc004.getProjCode());
List<HGSC004A> hgsc004AList = dao.query(HGSC004A.QUERY_ALL,map, 0, -999999);
if(CollectionUtils.isEmpty(hgsc004AList)){
//录入树结构,公司
HGSC004A rootHgsc004A = new HGSC004A();
BeanUtil.copyProperties(hgsc004,rootHgsc004A,"id");
//因为获取不到id,所以根据公司编号+项目编号得到树结构
rootHgsc004A.setMaterialId(hgsc004.getId());
rootHgsc004A.setParentProdCode("root");
rootHgsc004A.setParentProdName(hgsc004.getCompanyName());
rootHgsc004A.setLeaf(2);//有叶子节点
rootHgsc004A.setLv(1);
rootHgsc004A.setSort(1);
rootHgsc004A.setProductCode(hgsc004.getCompanyCode());
rootHgsc004A.setProductName(hgsc004.getCompanyName());
DaoUtils.insert(HGSC004A.INSERT, rootHgsc004A);
//录入2级目录,项目
HGSC004A projectHgsc004A = new HGSC004A();
BeanUtil.copyProperties(hgsc004,projectHgsc004A,"id");
projectHgsc004A.setMaterialId(hgsc004.getId());
projectHgsc004A.setParentProdCode(rootHgsc004A.getProductCode());
projectHgsc004A.setParentProdName(rootHgsc004A.getProductName());
projectHgsc004A.setLeaf(2);//有叶子节点
projectHgsc004A.setLv(2);
projectHgsc004A.setSort(1);
projectHgsc004A.setProductCode(hgsc004.getProjCode());
projectHgsc004A.setProductName(hgsc004.getProjName());
DaoUtils.insert(HGSC004A.INSERT, projectHgsc004A);
}
}
} }
...@@ -60,6 +60,12 @@ ...@@ -60,6 +60,12 @@
<isNotEmpty prepend=" AND " property="updatedTime"> <isNotEmpty prepend=" AND " property="updatedTime">
updated_time = #updatedTime# updated_time = #updatedTime#
</isNotEmpty> </isNotEmpty>
<isNotEmpty prepend=" AND " property="delStatus">
del_status = #delStatus#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="ids">
ID IN <iterate close=")" open="(" conjunction="," property="ids">#ids[]#</iterate>
</isNotEmpty>
</sql> </sql>
<select id="query" parameterClass="java.util.HashMap" <select id="query" parameterClass="java.util.HashMap"
...@@ -77,6 +83,7 @@ ...@@ -77,6 +83,7 @@
proj_name as "projName", <!-- 项目名称 --> proj_name as "projName", <!-- 项目名称 -->
material_status as "materialStatus", <!-- 物料状态 0:未提交,1:部分提交,2:全部提交 --> material_status as "materialStatus", <!-- 物料状态 0:未提交,1:部分提交,2:全部提交 -->
approval_status as "approvalStatus", <!-- 审批状态 0:待审;1:审核中;2:已审 --> approval_status as "approvalStatus", <!-- 审批状态 0:待审;1:审核中;2:已审 -->
del_status as "delStatus", <!-- 数据状态 0:保存,1:删除 -->
account_code as "accountCode", <!-- 帐套 --> account_code as "accountCode", <!-- 帐套 -->
created_by as "createdBy", <!-- 创建人 --> created_by as "createdBy", <!-- 创建人 -->
created_name as "createdName", <!-- 创建人名称 --> created_name as "createdName", <!-- 创建人名称 -->
...@@ -99,65 +106,6 @@ ...@@ -99,65 +106,6 @@
<include refid="condition" /> <include refid="condition" />
</select> </select>
<!--
<isNotEmpty prepend=" AND " property="id">
id = #id#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="blueprintId">
blueprint_id = #blueprintId#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="companyCode">
company_code = #companyCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="companyName">
company_name = #companyName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="depCode">
dep_code = #depCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="depName">
dep_name = #depName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="blueprintCode">
blueprint_code = #blueprintCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="blueprintName">
blueprint_name = #blueprintName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="projCode">
proj_code = #projCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="projName">
proj_name = #projName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="materialStatus">
material_status = #materialStatus#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="approvalStatus">
approval_status = #approvalStatus#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="accountCode">
account_code = #accountCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="createdBy">
created_by = #createdBy#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="createdName">
created_name = #createdName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="createdTime">
created_time = #createdTime#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="updatedBy">
updated_by = #updatedBy#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="updatedName">
updated_name = #updatedName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="updatedTime">
updated_time = #updatedTime#
</isNotEmpty>
-->
<insert id="insert"> <insert id="insert">
INSERT INTO ${hggpSchema}.HGSC004 (id, <!-- 主键 --> INSERT INTO ${hggpSchema}.HGSC004 (id, <!-- 主键 -->
...@@ -171,6 +119,7 @@ ...@@ -171,6 +119,7 @@
proj_code, <!-- 项目编码 --> proj_code, <!-- 项目编码 -->
proj_name, <!-- 项目名称 --> proj_name, <!-- 项目名称 -->
material_status, <!-- 物料状态 0:未提交,1:部分提交,2:全部提交 --> material_status, <!-- 物料状态 0:未提交,1:部分提交,2:全部提交 -->
del_status, <!-- 数据状态 0:保存,1:删除 -->
approval_status, <!-- 审批状态 0:待审;1:审核中;2:已审 --> approval_status, <!-- 审批状态 0:待审;1:审核中;2:已审 -->
account_code, <!-- 帐套 --> account_code, <!-- 帐套 -->
created_by, <!-- 创建人 --> created_by, <!-- 创建人 -->
...@@ -180,7 +129,7 @@ ...@@ -180,7 +129,7 @@
updated_name, <!-- 修改人名称 --> updated_name, <!-- 修改人名称 -->
updated_time <!-- 更新时间 --> updated_time <!-- 更新时间 -->
) )
VALUES (#id#, #blueprintId#, #companyCode#, #companyName#, #depCode#, #depName#, #blueprintCode#, #blueprintName#, #projCode#, #projName#, #materialStatus#, #approvalStatus#, #accountCode#, #createdBy#, #createdName#, #createdTime#, #updatedBy#, #updatedName#, #updatedTime#) VALUES (#id#, #blueprintId#, #companyCode#, #companyName#, #depCode#, #depName#, #blueprintCode#, #blueprintName#, #projCode#, #projName#, #materialStatus#, #delStatus#, #approvalStatus#, #accountCode#, #createdBy#, #createdName#, #createdTime#, #updatedBy#, #updatedName#, #updatedTime#)
</insert> </insert>
<delete id="delete"> <delete id="delete">
...@@ -200,6 +149,7 @@ ...@@ -200,6 +149,7 @@
proj_code = #projCode#, <!-- 项目编码 --> proj_code = #projCode#, <!-- 项目编码 -->
proj_name = #projName#, <!-- 项目名称 --> proj_name = #projName#, <!-- 项目名称 -->
material_status = #materialStatus#, <!-- 物料状态 0:未提交,1:部分提交,2:全部提交 --> material_status = #materialStatus#, <!-- 物料状态 0:未提交,1:部分提交,2:全部提交 -->
del_status = #delStatus#, <!-- 数据状态 0:保存,1:删除 -->
approval_status = #approvalStatus#, <!-- 审批状态 0:待审;1:审核中;2:已审 --> approval_status = #approvalStatus#, <!-- 审批状态 0:待审;1:审核中;2:已审 -->
account_code = #accountCode#, <!-- 帐套 --> account_code = #accountCode#, <!-- 帐套 -->
created_by = #createdBy#, <!-- 创建人 --> created_by = #createdBy#, <!-- 创建人 -->
...@@ -215,4 +165,26 @@ ...@@ -215,4 +165,26 @@
DELETE FROM ${hggpSchema}.HGSC004 WHERE DELETE FROM ${hggpSchema}.HGSC004 WHERE
id IN <iterate close=")" open="(" conjunction="," property="ids">#ids[]#</iterate> id IN <iterate close=")" open="(" conjunction="," property="ids">#ids[]#</iterate>
</delete> </delete>
<update id="updateDel">
UPDATE ${hggpSchema}.HGSC004
SET
UPDATED_BY = #updatedBy#, <!-- 更新人 -->
UPDATED_NAME = #updatedName#, <!-- 更新人名称 -->
UPDATED_TIME = #updatedTime#, <!-- 更新时间 -->
DEL_STATUS = 1 <!-- 数据状态 0:保存,1:删除 -->
WHERE
ID = #id#
</update>
<update id="updateMaterialStatus">
UPDATE ${hggpSchema}.HGSC004
SET
UPDATED_BY = #updatedBy#, <!-- 更新人 -->
UPDATED_NAME = #updatedName#, <!-- 更新人名称 -->
UPDATED_TIME = #updatedTime#, <!-- 更新时间 -->
MATERIAL_STATUS = #materialStatus#
WHERE
ID = #id#
</update>
</sqlMap> </sqlMap>
...@@ -33,7 +33,7 @@ $(function (){ ...@@ -33,7 +33,7 @@ $(function (){
let template = ''; let template = '';
if (item.id){ if (item.id){
template += '<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" ' template += '<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" '
+ 'onclick="showDetail(' + item.id +',\''+item.blueprintCode+'\',\''+item.blueprintName+'\',\''+item.companyName+'\')" >物料清单</a>'; + 'onclick="showDetail(' + item.id +',\''+item.companyCode+'\',\''+item.projCode+'\')" >物料清单</a>';
template += '<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" ' + template += '<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" ' +
'onclick="showUploadFile(' + item.id + ')" >附件</a>'; 'onclick="showUploadFile(' + item.id + ')" >附件</a>';
} }
...@@ -218,9 +218,9 @@ let save = function (btnNode) { ...@@ -218,9 +218,9 @@ let save = function (btnNode) {
/** /**
* 显示详情 * 显示详情
*/ */
function showDetail(id) { function showDetail(id,companyCode,projCode) {
JSColorbox.open({ JSColorbox.open({
href: "HGSC004A?methodName=initLoad&inqu_status-0-materialId=" + id, href: "HGSC004A?companyCode="+companyCode+"&projCode="+projCode+"&methodName=initLoad&inqu_status-0-materialId=" + id,
title: "<div style='text-align: center;'>蓝图清单详情</div>", title: "<div style='text-align: center;'>蓝图清单详情</div>",
width: "80%", width: "80%",
height: "80%", height: "80%",
......
...@@ -4,11 +4,11 @@ ...@@ -4,11 +4,11 @@
<%@ taglib prefix="EF" tagdir="/WEB-INF/tags/EF" %> <%@ taglib prefix="EF" tagdir="/WEB-INF/tags/EF" %>
<c:set var="ctx" value="${pageContext.request.contextPath}"/> <c:set var="ctx" value="${pageContext.request.contextPath}"/>
<head>
<%-- <link rel="stylesheet" href="${ctx}/css/simulatedOperation.css"/>--%>
</head>
<EF:EFPage title="物料清单详情"> <EF:EFPage title="物料清单详情">
<EF:EFRegion id="inqu" title="查询条件"> <EF:EFRegion id="inqu" title="查询条件">
<EF:EFInput ename="inqu_status-0-materialId" type="hidden"/>
<EF:EFInput ename="inqu_status-0-parentProdCode" type="hidden"/>
<div class="row"> <div class="row">
<EF:EFInput ename="inqu_status-0-productName" cname="产品名称" colWidth="3"/> <EF:EFInput ename="inqu_status-0-productName" cname="产品名称" colWidth="3"/>
<EF:EFSelect cname="变更类型" ename="inqu_status-0-changeType" colWidth="3" filter="contains"> <EF:EFSelect cname="变更类型" ename="inqu_status-0-changeType" colWidth="3" filter="contains">
...@@ -38,27 +38,23 @@ ...@@ -38,27 +38,23 @@
<EF:EFRegion id="result" title="明细信息"> <EF:EFRegion id="result" title="明细信息">
<EF:EFGrid blockId="result" autoDraw="no" checkMode="single"> <EF:EFGrid blockId="result" autoDraw="no" checkMode="single">
<EF:EFColumn ename="id" cname="主键" hidden="true"/> <EF:EFColumn ename="id" cname="主键" hidden="true"/>
<EF:EFColumn ename="level" cname="层级" hidden="true"/> <EF:EFColumn ename="lv" cname="层级" hidden="true"/>
<EF:EFColumn enable="false" ename="projCode" cname="项目编码"/> <EF:EFColumn enable="false" ename="parentProdCode" hidden="true" cname="上级产品编号"/>
<EF:EFColumn enable="false" ename="projName" cname="项目名称"/> <EF:EFColumn enable="false" ename="parentProdName" hidden="true" cname="上级产品名称"/>
<EF:EFComboColumn cname="产品类型" ename="prdtType" width="90" align="center" required="true"> <EF:EFColumn enable="false" ename="productId" hidden="true" cname="产品id"/>
<EF:EFCodeOption codeName="hpjx.hpkc.inventType" condition="ITEM_CODE IN ('3','4')"/> <EF:EFColumn enable="false" ename="productType" hidden="true" cname="产品类型"/>
<EF:EFColumn ename="operator" cname="操作" width="140" enable="false" readonly="false"/>
<EF:EFComboColumn cname="变更类型" ename="changeType" width="90" align="center" enable="false" required="false">
<EF:EFCodeOption codeName="hggp.sc.changeType" />
</EF:EFComboColumn> </EF:EFComboColumn>
<EF:EFColumn ename="inventRecordId" required="true" cname="产品名称"/> <EF:EFColumn ename="productCode" required="true" cname="产品编号" />
<EF:EFColumn ename="prdtCode" required="true" cname="产品编码" hidden="true"/> <EF:EFColumn ename="productName" cname="产品名称" width="120" align="center" enable="false"/>
<EF:EFColumn enable="false" ename="parentId" hidden="true" cname="上级产品名称"/> <EF:EFColumn ename="quantity" required="true" cname="数量"/>
<EF:EFColumn enable="false" ename="parentPrdtName" cname="上级产品名称"/> <EF:EFColumn ename="singleWeight" required="true" format="{0:N3}" cname="单重(kg)"/>
<EF:EFColumn ename="num" required="true" cname="数量"/> <EF:EFColumn enable="true" required="true" format="{0:N3}" ename="totalWeight" cname="总重(kg)"/>
<EF:EFColumn ename="unitWt" required="true" format="{0:N3}" cname="单重"/> <EF:EFComboColumn cname="提交状态" ename="productStatus" width="90" align="center" required="false">
<EF:EFColumn enable="false" format="{0:N3}" ename="totalWt" cname="总重"/> <EF:EFCodeOption codeName="hggp.sc.productStatus" />
<EF:EFComboColumn enable="false" ename="status" align="center"
columnTemplate="#=textField#" optionLabel=" "
itemTemplate="#=textField#" textField="textField"
valueField="valueField" cname="审核状态">
<EF:EFOption label="未审核" value="0"></EF:EFOption>
<EF:EFOption label="已审核" value="1"></EF:EFOption>
</EF:EFComboColumn> </EF:EFComboColumn>
<EF:EFColumn ename="operator" cname="操作" width="200" enable="false" readonly="false"/>
</EF:EFGrid> </EF:EFGrid>
</EF:EFRegion> </EF:EFRegion>
</div> </div>
...@@ -68,4 +64,4 @@ ...@@ -68,4 +64,4 @@
let ctx="${ctx}"; let ctx="${ctx}";
</script> </script>
<script src="${ctx}/HP/SC/HGSC004A.js"></script> <script src="${ctx}/HG/SC/HGSC004A.js"></script>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment