Commit 07e31b43 by yukang

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

parents 504febc9 de3253e5
package com.baosight.hggp.common;
/**
* @author wwl
* @version 1.0 2024/5/21
*/
public enum CheckStatusEnum {
CHECKING(0,"质检中"),
CHECKED(1,"质检完成");
private Integer code;
private String value;
CheckStatusEnum(Integer code, String value) {
this.code = code;
this.value = value;
}
public static CheckStatusEnum getEnumByCode(Integer code){
for (CheckStatusEnum en : CheckStatusEnum.values()){
if(code.compareTo(en.code)==0){
return en;
}
}
return null;
}
public Integer getCode() {
return code;
}
public void setCode(Integer code) {
this.code = code;
}
public String getValue() {
return value;
}
public void setValue(String value) {
this.value = value;
}
}
......@@ -71,6 +71,10 @@ public class HGConstant {
public static final String HGSC006_ORDER_CODE = "HGSC006_ORDER_CODE";
//生产任务
public static final String HGSC007_TASK_CODE = "HGSC007_TASK_CODE";
//生产报工
public static final String HGSC008_WORK_CODE = "HGSC008_WORK_CODE";
//工序质检
public static final String HGZL002_CHECK_CODE = "HGZL002_CHECK_CODE";
//生产任务订单
public static final String PROD_TASK_NO = "PROD_TASK_NO";
//售后维修单号
......
......@@ -38,7 +38,7 @@ public class HGSC008 extends DaoEPBase {
public static final String FIELD_dep_name = "depName"; /* 部门名称*/
public static final String FIELD_proj_code = "projCode"; /* 项目编码*/
public static final String FIELD_proj_name = "projName"; /* 项目名称*/
public static final String FIELD_task_code = "taskCode"; /* 任务编码*/
public static final String FIELD_work_code = "workCode"; /* 报工编码*/
public static final String FIELD_product_type = "productType"; /* 产品类型*/
public static final String FIELD_product_code = "productCode"; /* 产品编号*/
public static final String FIELD_product_name = "productName"; /* 产品名称*/
......@@ -82,7 +82,7 @@ public class HGSC008 extends DaoEPBase {
public static final String COL_dep_name = "dep_name"; /* 部门名称*/
public static final String COL_proj_code = "proj_code"; /* 项目编码*/
public static final String COL_proj_name = "proj_name"; /* 项目名称*/
public static final String COL_task_code = "task_code"; /* 任务编码*/
public static final String COL_work_code = "work_code"; /* 报工编码*/
public static final String COL_product_type = "product_type"; /* 产品类型*/
public static final String COL_product_code = "product_code"; /* 产品编号*/
public static final String COL_product_name = "product_name"; /* 产品名称*/
......@@ -109,6 +109,8 @@ public class HGSC008 extends DaoEPBase {
public static final String INSERT = "HGSC008.insert";
public static final String UPDATE = "HGSC008.update";
public static final String DELETE = "HGSC008.delete";
public static final String BATCH_DELETE = "HGSC008.batch_delete";
private Long id = new Long(0);
private Long matId = new Long(0); /* 物料清单ID*/
......@@ -125,7 +127,7 @@ public class HGSC008 extends DaoEPBase {
private String depName = " "; /* 部门名称*/
private String projCode = " "; /* 项目编码*/
private String projName = " "; /* 项目名称*/
private String taskCode = " "; /* 任务编码*/
private String workCode = " "; /* 报工编码*/
private Integer productType = new Integer(0); /* 产品类型*/
private String productCode = " "; /* 产品编号*/
private String productName = " "; /* 产品名称*/
......@@ -271,8 +273,8 @@ public class HGSC008 extends DaoEPBase {
eiColumn.setDescName("项目名称");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_task_code);
eiColumn.setDescName("任务编码");
eiColumn = new EiColumn(FIELD_work_code);
eiColumn.setDescName("报工编码");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_product_type);
......@@ -649,20 +651,20 @@ public class HGSC008 extends DaoEPBase {
this.projName = projName;
}
/**
* get the taskCode - 任务编码.
* @return the taskCode
* get the workCode - 报工编码.
* @return the workCode
*/
public String getTaskCode() {
return this.taskCode;
public String getWorkCode() {
return this.workCode;
}
/**
* set the taskCode - 任务编码.
* set the workCode - 报工编码.
*
* @param taskCode - 任务编码
* @param workCode - 报工编码
*/
public void setTaskCode(String taskCode) {
this.taskCode = taskCode;
public void setWorkCode(String workCode) {
this.workCode = workCode;
}
/**
* get the productType - 产品类型.
......@@ -1007,7 +1009,7 @@ public class HGSC008 extends DaoEPBase {
setDepName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_dep_name)), depName));
setProjCode(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_proj_code)), projCode));
setProjName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_proj_name)), projName));
setTaskCode(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_task_code)), taskCode));
setWorkCode(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_work_code)), workCode));
setProductType(NumberUtils.toInteger(StringUtils.toString(map.get(FIELD_product_type)), productType));
setProductCode(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_product_code)), productCode));
setProductName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_product_name)), productName));
......@@ -1059,7 +1061,7 @@ public class HGSC008 extends DaoEPBase {
map.put(FIELD_dep_name, StringUtils.toString(depName, eiMetadata.getMeta(FIELD_dep_name)));
map.put(FIELD_proj_code, StringUtils.toString(projCode, eiMetadata.getMeta(FIELD_proj_code)));
map.put(FIELD_proj_name, StringUtils.toString(projName, eiMetadata.getMeta(FIELD_proj_name)));
map.put(FIELD_task_code, StringUtils.toString(taskCode, eiMetadata.getMeta(FIELD_task_code)));
map.put(FIELD_work_code, StringUtils.toString(workCode, eiMetadata.getMeta(FIELD_work_code)));
map.put(FIELD_product_type, StringUtils.toString(productType, eiMetadata.getMeta(FIELD_product_type)));
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)));
......
......@@ -115,7 +115,6 @@ public class ServiceHGSC006A extends ServiceBase {
hgsc007.setDepCode(null);
hgsc007.setDepName(null);
hgsc007.setId(null);
HGSC006A a = new HGSC006A();
}
}
......@@ -2,9 +2,13 @@ package com.baosight.hggp.hg.sc.service;
import com.baosight.hggp.aspect.annotation.OperationLogAnnotation;
import com.baosight.hggp.core.constant.CommonConstant;
import com.baosight.hggp.core.dao.DaoUtils;
import com.baosight.hggp.hg.constant.HGConstant;
import com.baosight.hggp.hg.sc.domain.HGSC006A;
import com.baosight.hggp.hg.sc.domain.HGSC007;
import com.baosight.hggp.hg.sc.domain.HGSC008;
import com.baosight.hggp.hg.sc.tools.HGSCTools;
import com.baosight.hggp.hg.zl.tools.HGZLTools;
import com.baosight.hggp.util.*;
import com.baosight.hggp.util.contants.ACConstants;
import com.baosight.iplat4j.core.ei.EiBlock;
......@@ -12,6 +16,8 @@ import com.baosight.iplat4j.core.ei.EiConstant;
import com.baosight.iplat4j.core.ei.EiInfo;
import com.baosight.iplat4j.core.exception.PlatException;
import com.baosight.iplat4j.core.service.impl.ServiceEPBase;
import com.baosight.iplat4j.core.util.NumberUtils;
import com.baosight.iplat4j.ed.util.SequenceGenerator;
import org.springframework.beans.BeanUtils;
import java.math.BigDecimal;
......@@ -24,7 +30,7 @@ import java.util.*;
*/
public class ServiceHGSC007A extends ServiceEPBase {
@OperationLogAnnotation(operModul = "生产任务", operType = "查询", operDesc = "初始化页面")
@OperationLogAnnotation(operModul = "生产报工", operType = "报工", operDesc = "初始化页面")
public EiInfo initLoad(EiInfo inInfo) {
try {
Map queryMap = EiInfoUtils.getFirstRow(inInfo);
......@@ -52,6 +58,17 @@ public class ServiceHGSC007A extends ServiceEPBase {
return inInfo;
}
@OperationLogAnnotation(operModul = "生产报工", operType = "报工", operDesc = "保存")
public EiInfo save(EiInfo inInfo) {
try{
HGSCTools.THGSC008.add(inInfo);
inInfo.setStatus(EiConstant.STATUS_DEFAULT);
inInfo.setMsg("保存成功!");
} catch (Exception e) {
LogUtils.setDetailMsg(inInfo, e, "保存失败");
}
return inInfo;
}
}
......
package com.baosight.hggp.hg.sc.service;
import com.baosight.hggp.aspect.annotation.OperationLogAnnotation;
import com.baosight.hggp.core.dao.DaoUtils;
import com.baosight.hggp.hg.sc.domain.HGSC002;
import com.baosight.hggp.hg.sc.domain.HGSC008;
import com.baosight.hggp.hg.sc.tools.HGSCTools;
import com.baosight.hggp.util.LogUtils;
import com.baosight.hggp.util.ObjectUtils;
import com.baosight.iplat4j.core.ei.EiConstant;
import com.baosight.iplat4j.core.ei.EiInfo;
import com.baosight.iplat4j.core.exception.PlatException;
import com.baosight.iplat4j.core.service.impl.ServiceEPBase;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
/**
* @author wwl
* @version 1.0 2024/5/24
*/
public class ServiceHGSC008 extends ServiceEPBase {
@OperationLogAnnotation(operModul = "生产报工单", operType = "查询", operDesc = "初始化页面")
public EiInfo initLoad(EiInfo inInfo) {
try {
inInfo = super.query(inInfo, HGSC008.QUERY, new HGSC008());
} catch (PlatException e) {
LogUtils.setDetailMsg(inInfo, e, "初始化失败");
}
return inInfo;
}
/*
* 查询*/
@OperationLogAnnotation(operModul = "生产报工单", operType = "查询", operDesc = "查询")
public EiInfo query(EiInfo inInfo) {
try {
inInfo = super.query(inInfo,HGSC008.QUERY,new HGSC008() );
} catch (PlatException e) {
LogUtils.setDetailMsg(inInfo, e, "查询失败");
}
return inInfo;
}
@Override
@OperationLogAnnotation(operModul = "生产报工单", operType = "删除", operDesc = "删除")
public EiInfo delete(EiInfo inInfo) {
try {
List<Map> resultRows = inInfo.getBlock(EiConstant.resultBlock).getRows();
// 销售单号
List<Long> ids = ObjectUtils.listKey(resultRows, HGSC002.FIELD_id);
HGSCTools.THGSC008.delete(ids);
inInfo = this.query(inInfo);
inInfo.setStatus(EiConstant.STATUS_DEFAULT);
inInfo.setMsg("操作成功!本次对[" + resultRows.size() + "]条数据删除成功!");
} catch (Exception e) {
LogUtils.setDetailMsg(inInfo, e, "删除失败");
}
return inInfo;
}
}
......@@ -171,7 +171,9 @@
<isNotEmpty prepend=" AND " property="updatedTime">
updated_time = #updatedTime#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="ids">
id IN <iterate close=")" open="(" conjunction="," property="ids">#ids[]#</iterate>
</isNotEmpty>
</sql>
<select id="query" parameterClass="java.util.HashMap"
......
......@@ -19,7 +19,7 @@
dep_name VARCHAR,
proj_code VARCHAR,
proj_name VARCHAR,
task_code VARCHAR,
work_code VARCHAR,
product_type TINYINT,
product_code VARCHAR,
product_name VARCHAR,
......@@ -75,7 +75,7 @@
company_code = #companyCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="companyName">
company_name = #companyName#
company_name like ('%$companyName$%')
</isNotEmpty>
<isNotEmpty prepend=" AND " property="depCode">
dep_code = #depCode#
......@@ -89,8 +89,8 @@
<isNotEmpty prepend=" AND " property="projName">
proj_name = #projName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="taskCode">
task_code = #taskCode#
<isNotEmpty prepend=" AND " property="workCode">
work_code like ('%$workCode$%')
</isNotEmpty>
<isNotEmpty prepend=" AND " property="productType">
product_type = #productType#
......@@ -117,7 +117,7 @@
group_code = #groupCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="groupName">
group_name = #groupName#
group_name like ('%$groupName$%')
</isNotEmpty>
<isNotEmpty prepend=" AND " property="registerDate">
register_date = #registerDate#
......@@ -172,7 +172,7 @@
dep_name as "depName", <!-- 部门名称 -->
proj_code as "projCode", <!-- 项目编码 -->
proj_name as "projName", <!-- 项目名称 -->
task_code as "taskCode", <!-- 任务编码 -->
work_code as "workCode", <!-- 报工编码 -->
product_type as "productType", <!-- 产品类型 -->
product_code as "productCode", <!-- 产品编号 -->
product_name as "productName", <!-- 产品名称 -->
......@@ -200,7 +200,7 @@
$orderBy$
</isNotEmpty>
<isEmpty property="orderBy">
id asc
register_date desc ,id desc
</isEmpty>
</dynamic>
......@@ -257,8 +257,8 @@
<isNotEmpty prepend=" AND " property="projName">
proj_name = #projName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="taskCode">
task_code = #taskCode#
<isNotEmpty prepend=" AND " property="workCode">
work_code = #workCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="productType">
product_type = #productType#
......@@ -338,7 +338,7 @@
dep_name, <!-- 部门名称 -->
proj_code, <!-- 项目编码 -->
proj_name, <!-- 项目名称 -->
task_code, <!-- 任务编码 -->
work_code, <!-- 报工编码 -->
product_type, <!-- 产品类型 -->
product_code, <!-- 产品编号 -->
product_name, <!-- 产品名称 -->
......@@ -360,7 +360,10 @@
updated_name, <!-- 修改人名称 -->
updated_time <!-- 更新时间 -->
)
VALUES (#id#, #matId#, #taskId#, #techFlowId#, #techFlowName#, #inventProcessId#, #processCode#, #processName#, #processOrder#, #companyCode#, #companyName#, #depCode#, #depName#, #projCode#, #projName#, #taskCode#, #productType#, #productCode#, #productName#, #planStartDate#, #planEndDate#, #factoryCode#, #factoryName#, #groupCode#, #groupName#, #registerDate#, #quantity#, #singleWeight#, #totalWeight#, #accountCode#, #createdBy#, #createdName#, #createdTime#, #updatedBy#, #updatedName#, #updatedTime#)
VALUES (#id#, #matId#, #taskId#, #techFlowId#, #techFlowName#, #inventProcessId#, #processCode#, #processName#, #processOrder#, #companyCode#, #companyName#, #depCode#, #depName#, #projCode#, #projName#, #workCode#, #productType#, #productCode#, #productName#, #planStartDate#, #planEndDate#, #factoryCode#, #factoryName#, #groupCode#, #groupName#, #registerDate#, #quantity#, #singleWeight#, #totalWeight#, #accountCode#, #createdBy#, #createdName#, #createdTime#, #updatedBy#, #updatedName#, #updatedTime#)
<selectKey resultClass="long" keyProperty="id">
SELECT MAX(ID) AS "id" FROM ${hggpSchema}.HGSC008
</selectKey>
</insert>
<delete id="delete">
......@@ -385,7 +388,7 @@
dep_name = #depName#, <!-- 部门名称 -->
proj_code = #projCode#, <!-- 项目编码 -->
proj_name = #projName#, <!-- 项目名称 -->
task_code = #taskCode#, <!-- 任务编码 -->
work_code = #workCode#, <!-- 报工编码 -->
product_type = #productType#, <!-- 产品类型 -->
product_code = #productCode#, <!-- 产品编号 -->
product_name = #productName#, <!-- 产品名称 -->
......@@ -410,4 +413,8 @@
id = #id#
</update>
<delete id="batch_delete">
DELETE FROM ${hggpSchema}.HGSC008 WHERE
id IN <iterate close=")" open="(" conjunction="," property="ids">#ids[]#</iterate>
</delete>
</sqlMap>
......@@ -2,6 +2,7 @@ package com.baosight.hggp.hg.sc.tools;
import cn.hutool.core.bean.BeanUtil;
import com.baosight.hggp.common.AssignStatusEnum;
import com.baosight.hggp.common.CheckStatusEnum;
import com.baosight.hggp.common.ComputeTypeEnum;
import com.baosight.hggp.common.ProductTypeEnum;
import com.baosight.hggp.core.constant.CommonConstant;
......@@ -16,10 +17,17 @@ import com.baosight.hggp.hg.pz.tools.HGPZTools;
import com.baosight.hggp.hg.sc.domain.*;
import com.baosight.hggp.hg.sj.domain.HGSJ001;
import com.baosight.hggp.hg.sj.tools.HGSJTools;
import com.baosight.hggp.hg.xs.domain.Org;
import com.baosight.hggp.hg.zl.domain.HGZL002;
import com.baosight.hggp.hg.zl.tools.HGZLTools;
import com.baosight.hggp.util.AssertUtils;
import com.baosight.hggp.util.BeanUtils;
import com.baosight.hggp.util.DateUtil;
import com.baosight.hggp.util.EiInfoUtils;
import com.baosight.iplat4j.core.ei.EiConstant;
import com.baosight.iplat4j.core.ei.EiInfo;
import com.baosight.iplat4j.core.exception.PlatException;
import com.baosight.iplat4j.core.util.NumberUtils;
import com.baosight.iplat4j.ed.util.SequenceGenerator;
import org.apache.commons.collections.CollectionUtils;
import org.apache.commons.collections.MapUtils;
......@@ -757,6 +765,56 @@ public class HGSCTools {
List<HGSC008> results = DaoBase.getInstance().query(HGSC008.QUERY, new HashMap<String,Object>(){{put(HGSC008.FIELD_task_id, taskId);}});
return CollectionUtils.isEmpty(results) ? null : results;
}
public static HGSC008 add(EiInfo info){
Map resultMap = EiInfoUtils.getFirstRow(info, EiConstant.resultBlock);
String taskId = com.baosight.hggp.util.MapUtils.getString(resultMap, HGSC008.FIELD_task_id);
HGSC007 hgsc007 = HGSCTools.THGSC007.getById(Long.valueOf(taskId));
HGSC008 hgsc008 = new HGSC008();
BeanUtils.copyProperties(hgsc007,hgsc008);
cleanBaseInfo(hgsc008);
hgsc008.setQuantity(NumberUtils.toInteger(resultMap.get(HGSC008.FIELD_quantity)));
hgsc008.setTotalWeight(hgsc007.getSingleWeight().multiply(new BigDecimal(hgsc008.getQuantity())));
checkAddDate(hgsc008);
hgsc008.setWorkCode(SequenceGenerator.getNextSequence(HGConstant.SequenceId.HGSC008_WORK_CODE));
DaoUtils.insert(HGSC008.INSERT,hgsc008);
HGZLTools.THGZL002.add(hgsc008);
return hgsc008;
}
private static void checkAddDate(HGSC008 hgsc008){
List<String> orgIdList = UserSessionUtils.getOrgId();
AssertUtils.isEmpty(hgsc008.getGroupCode(),"生产任务班组信息异常,请联系管理员!");
AssertUtils.isTrue(!orgIdList.contains(hgsc008.getGroupCode()),"非当前任务生产组用户,无法报工此任务!");
AssertUtils.isNull(hgsc008.getQuantity(),"报工数量不能为空!");
}
private static void cleanBaseInfo(HGSC008 hgsc008){
hgsc008.setCreatedBy(null);
hgsc008.setCreatedName(null);
hgsc008.setCreatedTime(null);
hgsc008.setUpdatedBy(null);
hgsc008.setUpdatedName(null);
hgsc008.setUpdatedTime(null);
hgsc008.setDepCode(null);
hgsc008.setDepName(null);
hgsc008.setId(null);
}
public static void delete(List<Long> ids) {
checkDeleteDate(ids);
DaoUtils.update(HGSC008.BATCH_DELETE, new HashMap<String,Object>(){{put("ids",ids);}});
}
private static void checkDeleteDate(List<Long> ids){
List<HGZL002> hgzl002s = HGZLTools.THGZL002.list(ids);
List<String> workCodes = hgzl002s.stream().filter(o -> o.getCheckStatus().compareTo(CheckStatusEnum.CHECKED.getCode())==0).map(HGZL002::getWorkCode).collect(Collectors.toList());
if(CollectionUtils.isNotEmpty(workCodes)){
AssertUtils.isNotEmpty(workCodes,String.format("生产报工单[%s]已经质检完成,无法删除!",String.join(",",workCodes)));
}
}
}
......
package com.baosight.hggp.hg.zl.domain;
import com.baosight.iplat4j.core.util.NumberUtils;
import java.math.BigDecimal;
import com.baosight.iplat4j.core.ei.EiColumn;
import com.baosight.iplat4j.core.data.DaoEPBase;
import java.util.HashMap;
import java.util.Map;
import com.baosight.iplat4j.core.util.StringUtils;
/**
* Project: <br>
* Title:HGZL002.java <br>
* Description: <br>
*
* Copyrigth:Baosight Software LTD.co Copyright (c) 2019. <br>
*
* @version 1.0
* @history 2024-05-29 14:01:26 create
*/
public class HGZL002 extends DaoEPBase {
private static final long serialVersionUID = 1L;
public static final String FIELD_id = "id";
public static final String FIELD_mat_id = "matId"; /* 物料清单ID*/
public static final String FIELD_work_id = "workId"; /* 报工单ID*/
public static final String FIELD_tech_flow_id = "techFlowId"; /* 工艺流程ID*/
public static final String FIELD_tech_flow_name = "techFlowName"; /* 工艺流程名称*/
public static final String FIELD_invent_process_id = "inventProcessId"; /* 存货工序ID,对应HGPZ005A.id*/
public static final String FIELD_process_code = "processCode"; /* 工序编码*/
public static final String FIELD_process_name = "processName"; /* 工序名称*/
public static final String FIELD_process_order = "processOrder"; /* 加工顺序*/
public static final String FIELD_company_code = "companyCode"; /* 公司编码*/
public static final String FIELD_company_name = "companyName"; /* 公司名称*/
public static final String FIELD_dep_code = "depCode"; /* 部门编码*/
public static final String FIELD_dep_name = "depName"; /* 部门名称*/
public static final String FIELD_proj_code = "projCode"; /* 项目编码*/
public static final String FIELD_proj_name = "projName"; /* 项目名称*/
public static final String FIELD_work_code = "workCode"; /* 报工单编码*/
public static final String FIELD_check_code = "checkCode"; /* 质检单编码*/
public static final String FIELD_product_type = "productType"; /* 产品类型*/
public static final String FIELD_product_code = "productCode"; /* 产品编号*/
public static final String FIELD_product_name = "productName"; /* 产品名称*/
public static final String FIELD_plan_start_date = "planStartDate"; /* 计划开始日期*/
public static final String FIELD_plan_end_date = "planEndDate"; /* 计划结束日期*/
public static final String FIELD_factory_code = "factoryCode"; /* 工厂编号*/
public static final String FIELD_factory_name = "factoryName"; /* 工厂名称*/
public static final String FIELD_group_code = "groupCode"; /* 工作组编号*/
public static final String FIELD_group_name = "groupName"; /* 工作组名称*/
public static final String FIELD_work_by = "workBy"; /* 生产人*/
public static final String FIELD_work_name = "workName"; /* 生产人名称*/
public static final String FIELD_quantity = "quantity"; /* 数量*/
public static final String FIELD_passQuantity = "passquantity"; /* 合格数量*/
public static final String FIELD_unpassQuantity = "unpassquantity"; /* 不合格数量*/
public static final String FIELD_single_weight = "singleWeight"; /* 单重*/
public static final String FIELD_total_weight = "totalWeight"; /* 总重*/
public static final String FIELD_check_by = "checkBy"; /* 质检人*/
public static final String FIELD_check_name = "checkName"; /* 质检人名称*/
public static final String FIELD_check_date = "checkDate"; /* 质检日期*/
public static final String FIELD_check_status = "checkStatus"; /* 提交状态 0:质检中;1:质检完成*/
public static final String FIELD_account_code = "accountCode"; /* 帐套*/
public static final String FIELD_created_by = "createdBy"; /* 创建人*/
public static final String FIELD_created_name = "createdName"; /* 创建人名称*/
public static final String FIELD_created_time = "createdTime"; /* 创建时间*/
public static final String FIELD_updated_by = "updatedBy"; /* 更新人*/
public static final String FIELD_updated_name = "updatedName"; /* 修改人名称*/
public static final String FIELD_updated_time = "updatedTime"; /* 更新时间*/
public static final String COL_id = "id";
public static final String COL_mat_id = "mat_id"; /* 物料清单ID*/
public static final String COL_work_id = "work_id"; /* 报工单ID*/
public static final String COL_tech_flow_id = "tech_flow_id"; /* 工艺流程ID*/
public static final String COL_tech_flow_name = "tech_flow_name"; /* 工艺流程名称*/
public static final String COL_invent_process_id = "invent_process_id"; /* 存货工序ID,对应HGPZ005A.id*/
public static final String COL_process_code = "process_code"; /* 工序编码*/
public static final String COL_process_name = "process_name"; /* 工序名称*/
public static final String COL_process_order = "process_order"; /* 加工顺序*/
public static final String COL_company_code = "company_code"; /* 公司编码*/
public static final String COL_company_name = "company_name"; /* 公司名称*/
public static final String COL_dep_code = "dep_code"; /* 部门编码*/
public static final String COL_dep_name = "dep_name"; /* 部门名称*/
public static final String COL_proj_code = "proj_code"; /* 项目编码*/
public static final String COL_proj_name = "proj_name"; /* 项目名称*/
public static final String COL_work_code = "work_code"; /* 报工单编码*/
public static final String COL_check_code = "check_code"; /* 质检单编码*/
public static final String COL_product_type = "product_type"; /* 产品类型*/
public static final String COL_product_code = "product_code"; /* 产品编号*/
public static final String COL_product_name = "product_name"; /* 产品名称*/
public static final String COL_plan_start_date = "plan_start_date"; /* 计划开始日期*/
public static final String COL_plan_end_date = "plan_end_date"; /* 计划结束日期*/
public static final String COL_factory_code = "factory_code"; /* 工厂编号*/
public static final String COL_factory_name = "factory_name"; /* 工厂名称*/
public static final String COL_group_code = "group_code"; /* 工作组编号*/
public static final String COL_group_name = "group_name"; /* 工作组名称*/
public static final String COL_work_by = "work_by"; /* 生产人*/
public static final String COL_work_name = "work_name"; /* 生产人名称*/
public static final String COL_quantity = "quantity"; /* 数量*/
public static final String COL_passQuantity = "passQuantity"; /* 合格数量*/
public static final String COL_unpassQuantity = "unpassQuantity"; /* 不合格数量*/
public static final String COL_single_weight = "single_weight"; /* 单重*/
public static final String COL_total_weight = "total_weight"; /* 总重*/
public static final String COL_check_by = "check_by"; /* 质检人*/
public static final String COL_check_name = "check_name"; /* 质检人名称*/
public static final String COL_check_date = "check_date"; /* 质检日期*/
public static final String COL_check_status = "check_status"; /* 提交状态 0:质检中;1:质检完成*/
public static final String COL_account_code = "account_code"; /* 帐套*/
public static final String COL_created_by = "created_by"; /* 创建人*/
public static final String COL_created_name = "created_name"; /* 创建人名称*/
public static final String COL_created_time = "created_time"; /* 创建时间*/
public static final String COL_updated_by = "updated_by"; /* 更新人*/
public static final String COL_updated_name = "updated_name"; /* 修改人名称*/
public static final String COL_updated_time = "updated_time"; /* 更新时间*/
public static final String QUERY = "HGZL002.query";
public static final String COUNT = "HGZL002.count";
public static final String INSERT = "HGZL002.insert";
public static final String UPDATE = "HGZL002.update";
public static final String DELETE = "HGZL002.delete";
private Long id = new Long(0);
private Long matId = new Long(0); /* 物料清单ID*/
private Long workId = new Long(0); /* 报工单ID*/
private Long techFlowId = new Long(0); /* 工艺流程ID*/
private Long techFlowName = new Long(0); /* 工艺流程名称*/
private Long inventProcessId = new Long(0); /* 存货工序ID,对应HGPZ005A.id*/
private String processCode = " "; /* 工序编码*/
private String processName = " "; /* 工序名称*/
private Long processOrder = new Long(0); /* 加工顺序*/
private String companyCode = " "; /* 公司编码*/
private String companyName = " "; /* 公司名称*/
private String depCode = " "; /* 部门编码*/
private String depName = " "; /* 部门名称*/
private String projCode = " "; /* 项目编码*/
private String projName = " "; /* 项目名称*/
private String workCode = " "; /* 报工单编码*/
private String checkCode = " "; /* 质检单编码*/
private Integer productType = new Integer(0); /* 产品类型*/
private String productCode = " "; /* 产品编号*/
private String productName = " "; /* 产品名称*/
private String planStartDate = " "; /* 计划开始日期*/
private String planEndDate = " "; /* 计划结束日期*/
private String factoryCode = " "; /* 工厂编号*/
private String factoryName = " "; /* 工厂名称*/
private String groupCode = " "; /* 工作组编号*/
private String groupName = " "; /* 工作组名称*/
private String workBy = " "; /* 生产人*/
private String workName = " "; /* 生产人名称*/
private Integer quantity = new Integer(0); /* 数量*/
private Integer passquantity = new Integer(0); /* 合格数量*/
private Integer unpassquantity = new Integer(0); /* 不合格数量*/
private BigDecimal singleWeight = new BigDecimal("0"); /* 单重*/
private BigDecimal totalWeight = new BigDecimal("0"); /* 总重*/
private String checkBy = " "; /* 质检人*/
private String checkName = " "; /* 质检人名称*/
private String checkDate = " "; /* 质检日期*/
private Integer checkStatus = new Integer(0); /* 提交状态 0:质检中;1:质检完成*/
private String accountCode = " "; /* 帐套*/
private String createdBy = " "; /* 创建人*/
private String createdName = " "; /* 创建人名称*/
private String createdTime = " "; /* 创建时间*/
private String updatedBy = " "; /* 更新人*/
private String updatedName = " "; /* 修改人名称*/
private String updatedTime = " "; /* 更新时间*/
/**
* initialize the metadata.
*/
public void initMetaData() {
EiColumn eiColumn;
eiColumn = new EiColumn(FIELD_id);
eiColumn.setPrimaryKey(true);
eiColumn.setDescName(" ");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_mat_id);
eiColumn.setDescName("物料清单ID");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_work_id);
eiColumn.setDescName("报工单ID");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_tech_flow_id);
eiColumn.setDescName("工艺流程ID");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_tech_flow_name);
eiColumn.setDescName("工艺流程名称");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_invent_process_id);
eiColumn.setDescName("存货工序ID,对应HGPZ005A.id");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_process_code);
eiColumn.setDescName("工序编码");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_process_name);
eiColumn.setDescName("工序名称");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_process_order);
eiColumn.setDescName("加工顺序");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_company_code);
eiColumn.setDescName("公司编码");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_company_name);
eiColumn.setDescName("公司名称");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_dep_code);
eiColumn.setDescName("部门编码");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_dep_name);
eiColumn.setDescName("部门名称");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_proj_code);
eiColumn.setDescName("项目编码");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_proj_name);
eiColumn.setDescName("项目名称");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_work_code);
eiColumn.setDescName("报工单编码");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_check_code);
eiColumn.setDescName("质检单编码");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_product_type);
eiColumn.setDescName("产品类型");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_product_code);
eiColumn.setDescName("产品编号");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_product_name);
eiColumn.setDescName("产品名称");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_plan_start_date);
eiColumn.setDescName("计划开始日期");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_plan_end_date);
eiColumn.setDescName("计划结束日期");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_factory_code);
eiColumn.setDescName("工厂编号");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_factory_name);
eiColumn.setDescName("工厂名称");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_group_code);
eiColumn.setDescName("工作组编号");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_group_name);
eiColumn.setDescName("工作组名称");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_work_by);
eiColumn.setDescName("生产人");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_work_name);
eiColumn.setDescName("生产人名称");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_quantity);
eiColumn.setDescName("数量");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_passQuantity);
eiColumn.setDescName("合格数量");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_unpassQuantity);
eiColumn.setDescName("不合格数量");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_single_weight);
eiColumn.setType("N");
eiColumn.setScaleLength(3);
eiColumn.setFieldLength(20);
eiColumn.setDescName("单重");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_total_weight);
eiColumn.setType("N");
eiColumn.setScaleLength(3);
eiColumn.setFieldLength(20);
eiColumn.setDescName("总重");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_check_by);
eiColumn.setDescName("质检人");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_check_name);
eiColumn.setDescName("质检人名称");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_check_date);
eiColumn.setDescName("质检日期");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_check_status);
eiColumn.setDescName("提交状态 0:质检中;1:质检完成");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_account_code);
eiColumn.setDescName("帐套");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_created_by);
eiColumn.setDescName("创建人");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_created_name);
eiColumn.setDescName("创建人名称");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_created_time);
eiColumn.setDescName("创建时间");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_updated_by);
eiColumn.setDescName("更新人");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_updated_name);
eiColumn.setDescName("修改人名称");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_updated_time);
eiColumn.setDescName("更新时间");
eiMetadata.addMeta(eiColumn);
}
/**
* the constructor.
*/
public HGZL002() {
initMetaData();
}
/**
* get the id .
* @return the id
*/
public Long getId() {
return this.id;
}
/**
* set the id .
*
* @param id
*/
public void setId(Long id) {
this.id = id;
}
/**
* get the matId - 物料清单ID.
* @return the matId
*/
public Long getMatId() {
return this.matId;
}
/**
* set the matId - 物料清单ID.
*
* @param matId - 物料清单ID
*/
public void setMatId(Long matId) {
this.matId = matId;
}
/**
* get the workId - 报工单ID.
* @return the workId
*/
public Long getWorkId() {
return this.workId;
}
/**
* set the workId - 报工单ID.
*
* @param workId - 报工单ID
*/
public void setWorkId(Long workId) {
this.workId = workId;
}
/**
* get the techFlowId - 工艺流程ID.
* @return the techFlowId
*/
public Long getTechFlowId() {
return this.techFlowId;
}
/**
* set the techFlowId - 工艺流程ID.
*
* @param techFlowId - 工艺流程ID
*/
public void setTechFlowId(Long techFlowId) {
this.techFlowId = techFlowId;
}
/**
* get the techFlowName - 工艺流程名称.
* @return the techFlowName
*/
public Long getTechFlowName() {
return this.techFlowName;
}
/**
* set the techFlowName - 工艺流程名称.
*
* @param techFlowName - 工艺流程名称
*/
public void setTechFlowName(Long techFlowName) {
this.techFlowName = techFlowName;
}
/**
* get the inventProcessId - 存货工序ID,对应HGPZ005A.id.
* @return the inventProcessId
*/
public Long getInventProcessId() {
return this.inventProcessId;
}
/**
* set the inventProcessId - 存货工序ID,对应HGPZ005A.id.
*
* @param inventProcessId - 存货工序ID,对应HGPZ005A.id
*/
public void setInventProcessId(Long inventProcessId) {
this.inventProcessId = inventProcessId;
}
/**
* get the processCode - 工序编码.
* @return the processCode
*/
public String getProcessCode() {
return this.processCode;
}
/**
* set the processCode - 工序编码.
*
* @param processCode - 工序编码
*/
public void setProcessCode(String processCode) {
this.processCode = processCode;
}
/**
* get the processName - 工序名称.
* @return the processName
*/
public String getProcessName() {
return this.processName;
}
/**
* set the processName - 工序名称.
*
* @param processName - 工序名称
*/
public void setProcessName(String processName) {
this.processName = processName;
}
/**
* get the processOrder - 加工顺序.
* @return the processOrder
*/
public Long getProcessOrder() {
return this.processOrder;
}
/**
* set the processOrder - 加工顺序.
*
* @param processOrder - 加工顺序
*/
public void setProcessOrder(Long processOrder) {
this.processOrder = processOrder;
}
/**
* get the companyCode - 公司编码.
* @return the companyCode
*/
public String getCompanyCode() {
return this.companyCode;
}
/**
* set the companyCode - 公司编码.
*
* @param companyCode - 公司编码
*/
public void setCompanyCode(String companyCode) {
this.companyCode = companyCode;
}
/**
* get the companyName - 公司名称.
* @return the companyName
*/
public String getCompanyName() {
return this.companyName;
}
/**
* set the companyName - 公司名称.
*
* @param companyName - 公司名称
*/
public void setCompanyName(String companyName) {
this.companyName = companyName;
}
/**
* get the depCode - 部门编码.
* @return the depCode
*/
public String getDepCode() {
return this.depCode;
}
/**
* set the depCode - 部门编码.
*
* @param depCode - 部门编码
*/
public void setDepCode(String depCode) {
this.depCode = depCode;
}
/**
* get the depName - 部门名称.
* @return the depName
*/
public String getDepName() {
return this.depName;
}
/**
* set the depName - 部门名称.
*
* @param depName - 部门名称
*/
public void setDepName(String depName) {
this.depName = depName;
}
/**
* get the projCode - 项目编码.
* @return the projCode
*/
public String getProjCode() {
return this.projCode;
}
/**
* set the projCode - 项目编码.
*
* @param projCode - 项目编码
*/
public void setProjCode(String projCode) {
this.projCode = projCode;
}
/**
* get the projName - 项目名称.
* @return the projName
*/
public String getProjName() {
return this.projName;
}
/**
* set the projName - 项目名称.
*
* @param projName - 项目名称
*/
public void setProjName(String projName) {
this.projName = projName;
}
/**
* get the workCode - 报工单编码.
* @return the workCode
*/
public String getWorkCode() {
return this.workCode;
}
/**
* set the workCode - 报工单编码.
*
* @param workCode - 报工单编码
*/
public void setWorkCode(String workCode) {
this.workCode = workCode;
}
/**
* get the checkCode - 质检单编码.
* @return the checkCode
*/
public String getCheckCode() {
return this.checkCode;
}
/**
* set the checkCode - 质检单编码.
*
* @param checkCode - 质检单编码
*/
public void setCheckCode(String checkCode) {
this.checkCode = checkCode;
}
/**
* get the productType - 产品类型.
* @return the productType
*/
public Integer getProductType() {
return this.productType;
}
/**
* set the productType - 产品类型.
*
* @param productType - 产品类型
*/
public void setProductType(Integer productType) {
this.productType = productType;
}
/**
* get the productCode - 产品编号.
* @return the productCode
*/
public String getProductCode() {
return this.productCode;
}
/**
* set the productCode - 产品编号.
*
* @param productCode - 产品编号
*/
public void setProductCode(String productCode) {
this.productCode = productCode;
}
/**
* get the productName - 产品名称.
* @return the productName
*/
public String getProductName() {
return this.productName;
}
/**
* set the productName - 产品名称.
*
* @param productName - 产品名称
*/
public void setProductName(String productName) {
this.productName = productName;
}
/**
* get the planStartDate - 计划开始日期.
* @return the planStartDate
*/
public String getPlanStartDate() {
return this.planStartDate;
}
/**
* set the planStartDate - 计划开始日期.
*
* @param planStartDate - 计划开始日期
*/
public void setPlanStartDate(String planStartDate) {
this.planStartDate = planStartDate;
}
/**
* get the planEndDate - 计划结束日期.
* @return the planEndDate
*/
public String getPlanEndDate() {
return this.planEndDate;
}
/**
* set the planEndDate - 计划结束日期.
*
* @param planEndDate - 计划结束日期
*/
public void setPlanEndDate(String planEndDate) {
this.planEndDate = planEndDate;
}
/**
* get the factoryCode - 工厂编号.
* @return the factoryCode
*/
public String getFactoryCode() {
return this.factoryCode;
}
/**
* set the factoryCode - 工厂编号.
*
* @param factoryCode - 工厂编号
*/
public void setFactoryCode(String factoryCode) {
this.factoryCode = factoryCode;
}
/**
* get the factoryName - 工厂名称.
* @return the factoryName
*/
public String getFactoryName() {
return this.factoryName;
}
/**
* set the factoryName - 工厂名称.
*
* @param factoryName - 工厂名称
*/
public void setFactoryName(String factoryName) {
this.factoryName = factoryName;
}
/**
* get the groupCode - 工作组编号.
* @return the groupCode
*/
public String getGroupCode() {
return this.groupCode;
}
/**
* set the groupCode - 工作组编号.
*
* @param groupCode - 工作组编号
*/
public void setGroupCode(String groupCode) {
this.groupCode = groupCode;
}
/**
* get the groupName - 工作组名称.
* @return the groupName
*/
public String getGroupName() {
return this.groupName;
}
/**
* set the groupName - 工作组名称.
*
* @param groupName - 工作组名称
*/
public void setGroupName(String groupName) {
this.groupName = groupName;
}
/**
* get the workBy - 生产人.
* @return the workBy
*/
public String getWorkBy() {
return this.workBy;
}
/**
* set the workBy - 生产人.
*
* @param workBy - 生产人
*/
public void setWorkBy(String workBy) {
this.workBy = workBy;
}
/**
* get the workName - 生产人名称.
* @return the workName
*/
public String getWorkName() {
return this.workName;
}
/**
* set the workName - 生产人名称.
*
* @param workName - 生产人名称
*/
public void setWorkName(String workName) {
this.workName = workName;
}
/**
* get the quantity - 数量.
* @return the quantity
*/
public Integer getQuantity() {
return this.quantity;
}
/**
* set the quantity - 数量.
*
* @param quantity - 数量
*/
public void setQuantity(Integer quantity) {
this.quantity = quantity;
}
/**
* get the passquantity - 合格数量.
* @return the passquantity
*/
public Integer getPassquantity() {
return this.passquantity;
}
/**
* set the passquantity - 合格数量.
*
* @param passquantity - 合格数量
*/
public void setPassquantity(Integer passquantity) {
this.passquantity = passquantity;
}
/**
* get the unpassquantity - 不合格数量.
* @return the unpassquantity
*/
public Integer getUnpassquantity() {
return this.unpassquantity;
}
/**
* set the unpassquantity - 不合格数量.
*
* @param unpassquantity - 不合格数量
*/
public void setUnpassquantity(Integer unpassquantity) {
this.unpassquantity = unpassquantity;
}
/**
* get the singleWeight - 单重.
* @return the singleWeight
*/
public BigDecimal getSingleWeight() {
return this.singleWeight;
}
/**
* set the singleWeight - 单重.
*
* @param singleWeight - 单重
*/
public void setSingleWeight(BigDecimal singleWeight) {
this.singleWeight = singleWeight;
}
/**
* get the totalWeight - 总重.
* @return the totalWeight
*/
public BigDecimal getTotalWeight() {
return this.totalWeight;
}
/**
* set the totalWeight - 总重.
*
* @param totalWeight - 总重
*/
public void setTotalWeight(BigDecimal totalWeight) {
this.totalWeight = totalWeight;
}
/**
* get the checkBy - 质检人.
* @return the checkBy
*/
public String getCheckBy() {
return this.checkBy;
}
/**
* set the checkBy - 质检人.
*
* @param checkBy - 质检人
*/
public void setCheckBy(String checkBy) {
this.checkBy = checkBy;
}
/**
* get the checkName - 质检人名称.
* @return the checkName
*/
public String getCheckName() {
return this.checkName;
}
/**
* set the checkName - 质检人名称.
*
* @param checkName - 质检人名称
*/
public void setCheckName(String checkName) {
this.checkName = checkName;
}
/**
* get the checkDate - 质检日期.
* @return the checkDate
*/
public String getCheckDate() {
return this.checkDate;
}
/**
* set the checkDate - 质检日期.
*
* @param checkDate - 质检日期
*/
public void setCheckDate(String checkDate) {
this.checkDate = checkDate;
}
/**
* get the checkStatus - 提交状态 0:质检中;1:质检完成.
* @return the checkStatus
*/
public Integer getCheckStatus() {
return this.checkStatus;
}
/**
* set the checkStatus - 提交状态 0:质检中;1:质检完成.
*
* @param checkStatus - 提交状态 0:质检中;1:质检完成
*/
public void setCheckStatus(Integer checkStatus) {
this.checkStatus = checkStatus;
}
/**
* get the accountCode - 帐套.
* @return the accountCode
*/
public String getAccountCode() {
return this.accountCode;
}
/**
* set the accountCode - 帐套.
*
* @param accountCode - 帐套
*/
public void setAccountCode(String accountCode) {
this.accountCode = accountCode;
}
/**
* get the createdBy - 创建人.
* @return the createdBy
*/
public String getCreatedBy() {
return this.createdBy;
}
/**
* set the createdBy - 创建人.
*
* @param createdBy - 创建人
*/
public void setCreatedBy(String createdBy) {
this.createdBy = createdBy;
}
/**
* get the createdName - 创建人名称.
* @return the createdName
*/
public String getCreatedName() {
return this.createdName;
}
/**
* set the createdName - 创建人名称.
*
* @param createdName - 创建人名称
*/
public void setCreatedName(String createdName) {
this.createdName = createdName;
}
/**
* get the createdTime - 创建时间.
* @return the createdTime
*/
public String getCreatedTime() {
return this.createdTime;
}
/**
* set the createdTime - 创建时间.
*
* @param createdTime - 创建时间
*/
public void setCreatedTime(String createdTime) {
this.createdTime = createdTime;
}
/**
* get the updatedBy - 更新人.
* @return the updatedBy
*/
public String getUpdatedBy() {
return this.updatedBy;
}
/**
* set the updatedBy - 更新人.
*
* @param updatedBy - 更新人
*/
public void setUpdatedBy(String updatedBy) {
this.updatedBy = updatedBy;
}
/**
* get the updatedName - 修改人名称.
* @return the updatedName
*/
public String getUpdatedName() {
return this.updatedName;
}
/**
* set the updatedName - 修改人名称.
*
* @param updatedName - 修改人名称
*/
public void setUpdatedName(String updatedName) {
this.updatedName = updatedName;
}
/**
* get the updatedTime - 更新时间.
* @return the updatedTime
*/
public String getUpdatedTime() {
return this.updatedTime;
}
/**
* set the updatedTime - 更新时间.
*
* @param updatedTime - 更新时间
*/
public void setUpdatedTime(String updatedTime) {
this.updatedTime = updatedTime;
}
/**
* get the value from Map.
*
* @param map - source data map
*/
@Override
public void fromMap(Map map) {
setId(NumberUtils.toLong(StringUtils.toString(map.get(FIELD_id)), id));
setMatId(NumberUtils.toLong(StringUtils.toString(map.get(FIELD_mat_id)), matId));
setWorkId(NumberUtils.toLong(StringUtils.toString(map.get(FIELD_work_id)), workId));
setTechFlowId(NumberUtils.toLong(StringUtils.toString(map.get(FIELD_tech_flow_id)), techFlowId));
setTechFlowName(NumberUtils.toLong(StringUtils.toString(map.get(FIELD_tech_flow_name)), techFlowName));
setInventProcessId(NumberUtils.toLong(StringUtils.toString(map.get(FIELD_invent_process_id)), inventProcessId));
setProcessCode(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_process_code)), processCode));
setProcessName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_process_name)), processName));
setProcessOrder(NumberUtils.toLong(StringUtils.toString(map.get(FIELD_process_order)), processOrder));
setCompanyCode(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_company_code)), companyCode));
setCompanyName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_company_name)), companyName));
setDepCode(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_dep_code)), depCode));
setDepName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_dep_name)), depName));
setProjCode(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_proj_code)), projCode));
setProjName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_proj_name)), projName));
setWorkCode(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_work_code)), workCode));
setCheckCode(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_check_code)), checkCode));
setProductType(NumberUtils.toInteger(StringUtils.toString(map.get(FIELD_product_type)), productType));
setProductCode(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_product_code)), productCode));
setProductName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_product_name)), productName));
setPlanStartDate(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_plan_start_date)), planStartDate));
setPlanEndDate(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_plan_end_date)), planEndDate));
setFactoryCode(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_factory_code)), factoryCode));
setFactoryName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_factory_name)), factoryName));
setGroupCode(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_group_code)), groupCode));
setGroupName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_group_name)), groupName));
setWorkBy(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_work_by)), workBy));
setWorkName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_work_name)), workName));
setQuantity(NumberUtils.toInteger(StringUtils.toString(map.get(FIELD_quantity)), quantity));
setPassquantity(NumberUtils.toInteger(StringUtils.toString(map.get(FIELD_passQuantity)), passquantity));
setUnpassquantity(NumberUtils.toInteger(StringUtils.toString(map.get(FIELD_unpassQuantity)), unpassquantity));
setSingleWeight(NumberUtils.toBigDecimal(StringUtils.toString(map.get(FIELD_single_weight)), singleWeight));
setTotalWeight(NumberUtils.toBigDecimal(StringUtils.toString(map.get(FIELD_total_weight)), totalWeight));
setCheckBy(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_check_by)), checkBy));
setCheckName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_check_name)), checkName));
setCheckDate(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_check_date)), checkDate));
setCheckStatus(NumberUtils.toInteger(StringUtils.toString(map.get(FIELD_check_status)), checkStatus));
setAccountCode(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_account_code)), accountCode));
setCreatedBy(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_created_by)), createdBy));
setCreatedName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_created_name)), createdName));
setCreatedTime(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_created_time)), createdTime));
setUpdatedBy(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_updated_by)), updatedBy));
setUpdatedName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_updated_name)), updatedName));
setUpdatedTime(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_updated_time)), updatedTime));
}
/**
* set the value to Map.
*/
@Override
public Map toMap() {
Map map = new HashMap();
map.put(FIELD_id, StringUtils.toString(id, eiMetadata.getMeta(FIELD_id)));
map.put(FIELD_mat_id, StringUtils.toString(matId, eiMetadata.getMeta(FIELD_mat_id)));
map.put(FIELD_work_id, StringUtils.toString(workId, eiMetadata.getMeta(FIELD_work_id)));
map.put(FIELD_tech_flow_id, StringUtils.toString(techFlowId, eiMetadata.getMeta(FIELD_tech_flow_id)));
map.put(FIELD_tech_flow_name, StringUtils.toString(techFlowName, eiMetadata.getMeta(FIELD_tech_flow_name)));
map.put(FIELD_invent_process_id, StringUtils.toString(inventProcessId, eiMetadata.getMeta(FIELD_invent_process_id)));
map.put(FIELD_process_code, StringUtils.toString(processCode, eiMetadata.getMeta(FIELD_process_code)));
map.put(FIELD_process_name, StringUtils.toString(processName, eiMetadata.getMeta(FIELD_process_name)));
map.put(FIELD_process_order, StringUtils.toString(processOrder, eiMetadata.getMeta(FIELD_process_order)));
map.put(FIELD_company_code, StringUtils.toString(companyCode, eiMetadata.getMeta(FIELD_company_code)));
map.put(FIELD_company_name, StringUtils.toString(companyName, eiMetadata.getMeta(FIELD_company_name)));
map.put(FIELD_dep_code, StringUtils.toString(depCode, eiMetadata.getMeta(FIELD_dep_code)));
map.put(FIELD_dep_name, StringUtils.toString(depName, eiMetadata.getMeta(FIELD_dep_name)));
map.put(FIELD_proj_code, StringUtils.toString(projCode, eiMetadata.getMeta(FIELD_proj_code)));
map.put(FIELD_proj_name, StringUtils.toString(projName, eiMetadata.getMeta(FIELD_proj_name)));
map.put(FIELD_work_code, StringUtils.toString(workCode, eiMetadata.getMeta(FIELD_work_code)));
map.put(FIELD_check_code, StringUtils.toString(checkCode, eiMetadata.getMeta(FIELD_check_code)));
map.put(FIELD_product_type, StringUtils.toString(productType, eiMetadata.getMeta(FIELD_product_type)));
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_plan_start_date, StringUtils.toString(planStartDate, eiMetadata.getMeta(FIELD_plan_start_date)));
map.put(FIELD_plan_end_date, StringUtils.toString(planEndDate, eiMetadata.getMeta(FIELD_plan_end_date)));
map.put(FIELD_factory_code, StringUtils.toString(factoryCode, eiMetadata.getMeta(FIELD_factory_code)));
map.put(FIELD_factory_name, StringUtils.toString(factoryName, eiMetadata.getMeta(FIELD_factory_name)));
map.put(FIELD_group_code, StringUtils.toString(groupCode, eiMetadata.getMeta(FIELD_group_code)));
map.put(FIELD_group_name, StringUtils.toString(groupName, eiMetadata.getMeta(FIELD_group_name)));
map.put(FIELD_work_by, StringUtils.toString(workBy, eiMetadata.getMeta(FIELD_work_by)));
map.put(FIELD_work_name, StringUtils.toString(workName, eiMetadata.getMeta(FIELD_work_name)));
map.put(FIELD_quantity, StringUtils.toString(quantity, eiMetadata.getMeta(FIELD_quantity)));
map.put(FIELD_passQuantity, StringUtils.toString(passquantity, eiMetadata.getMeta(FIELD_passQuantity)));
map.put(FIELD_unpassQuantity, StringUtils.toString(unpassquantity, eiMetadata.getMeta(FIELD_unpassQuantity)));
map.put(FIELD_single_weight, StringUtils.toString(singleWeight, eiMetadata.getMeta(FIELD_single_weight)));
map.put(FIELD_total_weight, StringUtils.toString(totalWeight, eiMetadata.getMeta(FIELD_total_weight)));
map.put(FIELD_check_by, StringUtils.toString(checkBy, eiMetadata.getMeta(FIELD_check_by)));
map.put(FIELD_check_name, StringUtils.toString(checkName, eiMetadata.getMeta(FIELD_check_name)));
map.put(FIELD_check_date, StringUtils.toString(checkDate, eiMetadata.getMeta(FIELD_check_date)));
map.put(FIELD_check_status, StringUtils.toString(checkStatus, eiMetadata.getMeta(FIELD_check_status)));
map.put(FIELD_account_code, StringUtils.toString(accountCode, eiMetadata.getMeta(FIELD_account_code)));
map.put(FIELD_created_by, StringUtils.toString(createdBy, eiMetadata.getMeta(FIELD_created_by)));
map.put(FIELD_created_name, StringUtils.toString(createdName, eiMetadata.getMeta(FIELD_created_name)));
map.put(FIELD_created_time, StringUtils.toString(createdTime, eiMetadata.getMeta(FIELD_created_time)));
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_time, StringUtils.toString(updatedTime, eiMetadata.getMeta(FIELD_updated_time)));
return map;
}
}
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE sqlMap PUBLIC "-//ibatis.apache.org//DTD SQL Map 2.0//EN" "http://ibatis.apache.org/dtd/sql-map-2.dtd"> <!-- table information
Generate time : 2024-05-29 14:33:20
Version : 1.0
schema : hggp
tableName : HGZL002
id BIGINT NOT NULL primarykey,
mat_id BIGINT NOT NULL,
work_id BIGINT NOT NULL,
tech_flow_id BIGINT,
tech_flow_name BIGINT,
invent_process_id BIGINT,
process_code VARCHAR,
process_name VARCHAR,
process_order BIGINT,
company_code VARCHAR NOT NULL,
company_name VARCHAR NOT NULL,
dep_code VARCHAR,
dep_name VARCHAR,
proj_code VARCHAR,
proj_name VARCHAR,
work_code VARCHAR,
check_code VARCHAR,
product_type TINYINT,
product_code VARCHAR,
product_name VARCHAR,
plan_start_date VARCHAR,
plan_end_date VARCHAR,
factory_code VARCHAR,
factory_name VARCHAR,
group_code VARCHAR,
group_name VARCHAR,
work_by VARCHAR,
work_name VARCHAR,
quantity TINYINT,
passQuantity TINYINT,
unpassQuantity TINYINT,
single_weight DECIMAL,
total_weight DECIMAL,
check_by VARCHAR,
check_name VARCHAR,
check_date VARCHAR,
check_status TINYINT,
account_code VARCHAR NOT NULL,
created_by VARCHAR,
created_name VARCHAR,
created_time VARCHAR,
updated_by VARCHAR,
updated_name VARCHAR,
updated_time VARCHAR
-->
<sqlMap namespace="HGZL002">
<sql id="condition">
<isNotEmpty prepend=" AND " property="id">
id = #id#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="matId">
mat_id = #matId#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="workId">
work_id = #workId#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="techFlowId">
tech_flow_id = #techFlowId#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="techFlowName">
tech_flow_name = #techFlowName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="inventProcessId">
invent_process_id = #inventProcessId#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="processCode">
process_code = #processCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="processName">
process_name = #processName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="processOrder">
process_order = #processOrder#
</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="projCode">
proj_code = #projCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="projName">
proj_name = #projName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="workCode">
work_code = #workCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="checkCode">
check_code = #checkCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="productType">
product_type = #productType#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="productCode">
product_code = #productCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="productName">
product_name = #productName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="planStartDate">
plan_start_date = #planStartDate#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="planEndDate">
plan_end_date = #planEndDate#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="factoryCode">
factory_code = #factoryCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="factoryName">
factory_name = #factoryName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="groupCode">
group_code = #groupCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="groupName">
group_name = #groupName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="workBy">
work_by = #workBy#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="workName">
work_name = #workName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="quantity">
quantity = #quantity#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="passquantity">
passQuantity = #passquantity#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="unpassquantity">
unpassQuantity = #unpassquantity#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="singleWeight">
single_weight = #singleWeight#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="totalWeight">
total_weight = #totalWeight#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="checkBy">
check_by = #checkBy#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="checkName">
check_name = #checkName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="checkDate">
check_date = #checkDate#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="checkStatus">
check_status = #checkStatus#
</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>
<isNotEmpty prepend=" AND " property="workIds">
work_id IN <iterate close=")" open="(" conjunction="," property="workIds">#workIds[]#</iterate>
</isNotEmpty>
</sql>
<select id="query" parameterClass="java.util.HashMap"
resultClass="com.baosight.hggp.hg.zl.domain.HGZL002">
SELECT
id as "id",
mat_id as "matId", <!-- 物料清单ID -->
work_id as "workId", <!-- 报工单ID -->
tech_flow_id as "techFlowId", <!-- 工艺流程ID -->
tech_flow_name as "techFlowName", <!-- 工艺流程名称 -->
invent_process_id as "inventProcessId", <!-- 存货工序ID,对应HGPZ005A.id -->
process_code as "processCode", <!-- 工序编码 -->
process_name as "processName", <!-- 工序名称 -->
process_order as "processOrder", <!-- 加工顺序 -->
company_code as "companyCode", <!-- 公司编码 -->
company_name as "companyName", <!-- 公司名称 -->
dep_code as "depCode", <!-- 部门编码 -->
dep_name as "depName", <!-- 部门名称 -->
proj_code as "projCode", <!-- 项目编码 -->
proj_name as "projName", <!-- 项目名称 -->
work_code as "workCode", <!-- 报工单编码 -->
check_code as "checkCode", <!-- 质检单编码 -->
product_type as "productType", <!-- 产品类型 -->
product_code as "productCode", <!-- 产品编号 -->
product_name as "productName", <!-- 产品名称 -->
plan_start_date as "planStartDate", <!-- 计划开始日期 -->
plan_end_date as "planEndDate", <!-- 计划结束日期 -->
factory_code as "factoryCode", <!-- 工厂编号 -->
factory_name as "factoryName", <!-- 工厂名称 -->
group_code as "groupCode", <!-- 工作组编号 -->
group_name as "groupName", <!-- 工作组名称 -->
work_by as "workBy", <!-- 生产人 -->
work_name as "workName", <!-- 生产人名称 -->
quantity as "quantity", <!-- 数量 -->
passQuantity as "passquantity", <!-- 合格数量 -->
unpassQuantity as "unpassquantity", <!-- 不合格数量 -->
single_weight as "singleWeight", <!-- 单重 -->
total_weight as "totalWeight", <!-- 总重 -->
check_by as "checkBy", <!-- 质检人 -->
check_name as "checkName", <!-- 质检人名称 -->
check_date as "checkDate", <!-- 质检日期 -->
check_status as "checkStatus", <!-- 提交状态 0:质检中;1:质检完成 -->
account_code as "accountCode", <!-- 帐套 -->
created_by as "createdBy", <!-- 创建人 -->
created_name as "createdName", <!-- 创建人名称 -->
created_time as "createdTime", <!-- 创建时间 -->
updated_by as "updatedBy", <!-- 更新人 -->
updated_name as "updatedName", <!-- 修改人名称 -->
updated_time as "updatedTime" <!-- 更新时间 -->
FROM ${hggpSchema}.HGZL002 WHERE 1=1
<include refid="condition" />
<dynamic prepend="ORDER BY">
<isNotEmpty property="orderBy">
$orderBy$
</isNotEmpty>
<isEmpty property="orderBy">
id asc
</isEmpty>
</dynamic>
</select>
<select id="count" resultClass="int">
SELECT COUNT(*) FROM ${hggpSchema}.HGZL002 WHERE 1=1
<include refid="condition" />
</select>
<!--
<isNotEmpty prepend=" AND " property="id">
id = #id#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="matId">
mat_id = #matId#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="workId">
work_id = #workId#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="techFlowId">
tech_flow_id = #techFlowId#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="techFlowName">
tech_flow_name = #techFlowName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="inventProcessId">
invent_process_id = #inventProcessId#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="processCode">
process_code = #processCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="processName">
process_name = #processName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="processOrder">
process_order = #processOrder#
</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="projCode">
proj_code = #projCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="projName">
proj_name = #projName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="workCode">
work_code = #workCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="checkCode">
check_code = #checkCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="productType">
product_type = #productType#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="productCode">
product_code = #productCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="productName">
product_name = #productName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="planStartDate">
plan_start_date = #planStartDate#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="planEndDate">
plan_end_date = #planEndDate#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="factoryCode">
factory_code = #factoryCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="factoryName">
factory_name = #factoryName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="groupCode">
group_code = #groupCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="groupName">
group_name = #groupName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="workBy">
work_by = #workBy#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="workName">
work_name = #workName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="quantity">
quantity = #quantity#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="passquantity">
passQuantity = #passquantity#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="unpassquantity">
unpassQuantity = #unpassquantity#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="singleWeight">
single_weight = #singleWeight#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="totalWeight">
total_weight = #totalWeight#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="checkBy">
check_by = #checkBy#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="checkName">
check_name = #checkName#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="checkDate">
check_date = #checkDate#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="checkStatus">
check_status = #checkStatus#
</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 INTO ${hggpSchema}.HGZL002 (id,
mat_id, <!-- 物料清单ID -->
work_id, <!-- 报工单ID -->
tech_flow_id, <!-- 工艺流程ID -->
tech_flow_name, <!-- 工艺流程名称 -->
invent_process_id, <!-- 存货工序ID,对应HGPZ005A.id -->
process_code, <!-- 工序编码 -->
process_name, <!-- 工序名称 -->
process_order, <!-- 加工顺序 -->
company_code, <!-- 公司编码 -->
company_name, <!-- 公司名称 -->
dep_code, <!-- 部门编码 -->
dep_name, <!-- 部门名称 -->
proj_code, <!-- 项目编码 -->
proj_name, <!-- 项目名称 -->
work_code, <!-- 报工单编码 -->
check_code, <!-- 质检单编码 -->
product_type, <!-- 产品类型 -->
product_code, <!-- 产品编号 -->
product_name, <!-- 产品名称 -->
plan_start_date, <!-- 计划开始日期 -->
plan_end_date, <!-- 计划结束日期 -->
factory_code, <!-- 工厂编号 -->
factory_name, <!-- 工厂名称 -->
group_code, <!-- 工作组编号 -->
group_name, <!-- 工作组名称 -->
work_by, <!-- 生产人 -->
work_name, <!-- 生产人名称 -->
quantity, <!-- 数量 -->
passQuantity, <!-- 合格数量 -->
unpassQuantity, <!-- 不合格数量 -->
single_weight, <!-- 单重 -->
total_weight, <!-- 总重 -->
check_by, <!-- 质检人 -->
check_name, <!-- 质检人名称 -->
check_date, <!-- 质检日期 -->
check_status, <!-- 提交状态 0:质检中;1:质检完成 -->
account_code, <!-- 帐套 -->
created_by, <!-- 创建人 -->
created_name, <!-- 创建人名称 -->
created_time, <!-- 创建时间 -->
updated_by, <!-- 更新人 -->
updated_name, <!-- 修改人名称 -->
updated_time <!-- 更新时间 -->
)
VALUES (#id#, #matId#, #workId#, #techFlowId#, #techFlowName#, #inventProcessId#, #processCode#, #processName#, #processOrder#, #companyCode#, #companyName#, #depCode#, #depName#, #projCode#, #projName#, #workCode#, #checkCode#, #productType#, #productCode#, #productName#, #planStartDate#, #planEndDate#, #factoryCode#, #factoryName#, #groupCode#, #groupName#, #workBy#, #workName#, #quantity#, #passquantity#, #unpassquantity#, #singleWeight#, #totalWeight#, #checkBy#, #checkName#, #checkDate#, #checkStatus#, #accountCode#, #createdBy#, #createdName#, #createdTime#, #updatedBy#, #updatedName#, #updatedTime#)
</insert>
<delete id="delete">
DELETE FROM ${hggpSchema}.HGZL002 WHERE
id = #id#
</delete>
<update id="update">
UPDATE ${hggpSchema}.HGZL002
SET
mat_id = #matId#, <!-- 物料清单ID -->
work_id = #workId#, <!-- 报工单ID -->
tech_flow_id = #techFlowId#, <!-- 工艺流程ID -->
tech_flow_name = #techFlowName#, <!-- 工艺流程名称 -->
invent_process_id = #inventProcessId#, <!-- 存货工序ID,对应HGPZ005A.id -->
process_code = #processCode#, <!-- 工序编码 -->
process_name = #processName#, <!-- 工序名称 -->
process_order = #processOrder#, <!-- 加工顺序 -->
company_code = #companyCode#, <!-- 公司编码 -->
company_name = #companyName#, <!-- 公司名称 -->
dep_code = #depCode#, <!-- 部门编码 -->
dep_name = #depName#, <!-- 部门名称 -->
proj_code = #projCode#, <!-- 项目编码 -->
proj_name = #projName#, <!-- 项目名称 -->
work_code = #workCode#, <!-- 报工单编码 -->
check_code = #checkCode#, <!-- 质检单编码 -->
product_type = #productType#, <!-- 产品类型 -->
product_code = #productCode#, <!-- 产品编号 -->
product_name = #productName#, <!-- 产品名称 -->
plan_start_date = #planStartDate#, <!-- 计划开始日期 -->
plan_end_date = #planEndDate#, <!-- 计划结束日期 -->
factory_code = #factoryCode#, <!-- 工厂编号 -->
factory_name = #factoryName#, <!-- 工厂名称 -->
group_code = #groupCode#, <!-- 工作组编号 -->
group_name = #groupName#, <!-- 工作组名称 -->
work_by = #workBy#, <!-- 生产人 -->
work_name = #workName#, <!-- 生产人名称 -->
quantity = #quantity#, <!-- 数量 -->
passQuantity = #passquantity#, <!-- 合格数量 -->
unpassQuantity = #unpassquantity#, <!-- 不合格数量 -->
single_weight = #singleWeight#, <!-- 单重 -->
total_weight = #totalWeight#, <!-- 总重 -->
check_by = #checkBy#, <!-- 质检人 -->
check_name = #checkName#, <!-- 质检人名称 -->
check_date = #checkDate#, <!-- 质检日期 -->
check_status = #checkStatus#, <!-- 提交状态 0:质检中;1:质检完成 -->
account_code = #accountCode#, <!-- 帐套 -->
created_by = #createdBy#, <!-- 创建人 -->
created_name = #createdName#, <!-- 创建人名称 -->
created_time = #createdTime#, <!-- 创建时间 -->
updated_by = #updatedBy#, <!-- 更新人 -->
updated_name = #updatedName#, <!-- 修改人名称 -->
updated_time = #updatedTime# <!-- 更新时间 -->
WHERE
id = #id#
</update>
</sqlMap>
package com.baosight.hggp.hg.zl.tools;
import com.baosight.hggp.common.CheckStatusEnum;
import com.baosight.hggp.core.dao.DaoBase;
import com.baosight.hggp.core.dao.DaoUtils;
import com.baosight.hggp.hg.constant.HGConstant;
import com.baosight.hggp.hg.constant.HGSqlConstant;
import com.baosight.hggp.hg.sc.domain.HGSC008;
import com.baosight.hggp.hg.zl.domain.HGZL001;
import com.baosight.hggp.hg.zl.domain.HGZL002;
import com.baosight.hggp.util.AssertUtils;
import com.baosight.iplat4j.ed.util.SequenceGenerator;
import org.apache.commons.collections.CollectionUtils;
import org.springframework.beans.BeanUtils;
import java.math.BigDecimal;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
......@@ -73,4 +81,41 @@ public class HGZLTools {
return results.stream().collect(Collectors.toMap(HGZL001::getCheckNo, item -> item));
}
}
public static class THGZL002 {
public static HGZL002 add(HGSC008 hgsc008){
HGZL002 hgzl002 = new HGZL002();
BeanUtils.copyProperties(hgsc008,hgzl002);
cleanBaseInfo(hgzl002);
hgzl002.setCheckStatus(CheckStatusEnum.CHECKING.getCode());
hgzl002.setWorkId(hgsc008.getId());
hgzl002.setWorkCode(hgsc008.getWorkCode());
hgzl002.setWorkBy(hgsc008.getCreatedBy());
hgzl002.setWorkName(hgsc008.getCreatedName());
hgzl002.setCheckCode(SequenceGenerator.getNextSequence(HGConstant.SequenceId.HGZL002_CHECK_CODE));
DaoUtils.insert(HGZL002.INSERT,hgzl002);
return hgzl002;
}
private static void cleanBaseInfo(HGZL002 hgzl002){
hgzl002.setCreatedBy(null);
hgzl002.setCreatedName(null);
hgzl002.setCreatedTime(null);
hgzl002.setUpdatedBy(null);
hgzl002.setUpdatedName(null);
hgzl002.setUpdatedTime(null);
hgzl002.setDepCode(null);
hgzl002.setDepName(null);
hgzl002.setId(null);
}
public static List<HGZL002> list(List<Long> workIds) {
if (CollectionUtils.isEmpty(workIds)) {
return null;
}
Map queryMap = new HashMap();
queryMap.put("workIds", workIds);
return DaoBase.getInstance().query(HGZL002.QUERY, queryMap);
}
}
}
\ No newline at end of file
......@@ -137,7 +137,7 @@ let initInvent = function () {
*/
let initSpec = function () {
let inInfo = new EiInfo();
inInfo.set("inqu_status-0-inventTypes", [1, 2]);
//inInfo.set("inqu_status-0-inventTypes", [1, 2]);
inInfo.set("inqu_status-0-isSplicingSymbol", false);
EiCommunicator.send("HGPZ005", "queryInventBoxAll", inInfo, {
onSuccess: function (ei) {
......@@ -182,12 +182,24 @@ let save = function () {
}
let flag = true;
$.each(rows, function(index, item) {
let whCode= item.get("whCode");
/* if(isBlank(whCode)){
message("选中的第"+(index+1)+"行\"仓库名称\",不能为空!");
let inventType= item.get("inventType");
let inventCode= item.get("inventCode");
let inventRecordId= item.get("inventRecordId");
if(isBlank(inventType)){
message("选中的第"+(index+1)+"行\"存货类型\",不能为空!");
flag = false;
return false;
}*/
}
if(isBlank(inventCode)){
message("选中的第"+(index+1)+"行\"存货名称\",不能为空!");
flag = false;
return false;
}
if(isBlank(inventRecordId)){
message("选中的第"+(index+1)+"行\"规格\",不能为空!");
flag = false;
return false;
}
});
if(flag) {
JSUtils.confirm("确定对勾选中的[" + rows.length + "]条数据做\"保存\"操作? ", {
......
......@@ -137,7 +137,7 @@ let initInvent = function () {
*/
let initSpec = function () {
let inInfo = new EiInfo();
inInfo.set("inqu_status-0-inventTypes", [1, 2]);
//inInfo.set("inqu_status-0-inventTypes", [1, 2]);
inInfo.set("inqu_status-0-isSplicingSymbol", false);
EiCommunicator.send("HGPZ005", "queryInventBoxAll", inInfo, {
onSuccess: function (ei) {
......@@ -184,12 +184,24 @@ let save = function () {
}
let flag = true;
$.each(rows, function(index, item) {
/* let whCode= item.get("whCode");
if(isBlank(whCode)){
message("选中的第"+(index+1)+"行\"仓库名称\",不能为空!");
let inventType= item.get("inventType");
let inventCode= item.get("inventCode");
let inventRecordId= item.get("inventRecordId");
if(isBlank(inventType)){
message("选中的第"+(index+1)+"行\"存货类型\",不能为空!");
flag = false;
return false;
}*/
}
if(isBlank(inventCode)){
message("选中的第"+(index+1)+"行\"存货名称\",不能为空!");
flag = false;
return false;
}
if(isBlank(inventRecordId)){
message("选中的第"+(index+1)+"行\"规格\",不能为空!");
flag = false;
return false;
}
});
if(flag) {
JSUtils.confirm("确定对勾选中的[" + rows.length + "]条数据做\"保存\"操作? ", {
......
......@@ -15,10 +15,8 @@ $(function () {
field: "operator",
template: function (item) {
let template = '';
if(item.unfinishQuantity>0){
template+='<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" '
+ 'onclick="registerWork(' + item.id + ')" >报工</a>';
}
template+='<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" '
+ 'onclick="showUploadFile(' + item.matId + ')" >附件清单</a>';
return template;
......
......@@ -37,7 +37,7 @@ $(function () {
}
JSUtils.confirm("确定对数据做\"保存\"操作? ", {
ok: function () {
JSUtils.submitGrid("detail", "HGSC001", "save", {isAlldata:true,onSuccessCallback:parent.windowCallback});
JSUtils.submitGrid("result", "HGSC007A", "save", {isAlldata:true,onSuccessCallback:parent.registerWorkCallback});
}
});
});
......
$(function () {
$("#QUERY").on("click", function () {
resultGrid.dataSource.page(1);
});
IPLATUI.EFGrid.result = {
pageable: {
pageSize: 20,
pageSizes: [10, 20, 50, 70, 100],
},
columns: [
],
loadComplete: function(grid) {
},
onSuccess: function (e) {
if(e.eiInfo.extAttr.methodName == 'save'||e.eiInfo.extAttr.methodName == 'delete' ){
query();
}
}
}
});
<%--
Created by IntelliJ IDEA.
User: 1
Date: 2024/5/10
Time: 15:29
To change this template use File | Settings | File Templates.
--%>
<!DOCTYPE html>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@ taglib prefix="EF" tagdir="/WEB-INF/tags/EF" %>
<%@ page import="com.baosight.iplat4j.core.web.threadlocal.UserSession" %>
<%
String loginName = UserSession.getLoginName();
%>
<c:set var="ctx" value="${pageContext.request.contextPath}"/>
<c:set var="loginName" value="<%=loginName%>" />
<EF:EFPage title="生产报工单">
<EF:EFRegion id="inqu" title="查询条件">
<div class="row">
<EF:EFInput blockId="inqu_status" row="0" ename="companyName" cname="公司名称" placeholder="模糊查询" colWidth="3"/>
<EF:EFInput blockId="inqu_status" row="0" ename="workCode" cname="报工单号" placeholder="模糊查询" colWidth="3"/>
<EF:EFInput blockId="inqu_status" row="0" ename="groupName" cname="生产组" placeholder="模糊查询" colWidth="3"/>
</div>
</EF:EFRegion>
<EF:EFRegion id="result" title="明细信息">
<EF:EFGrid blockId="result" autoDraw="override" isFloat="true">
<EF:EFColumn ename="id" primaryKey="true" cname="内码" hidden="true"/>
<EF:EFColumn ename="accountCode" cname="账套" hidden="true"/>
<EF:EFColumn ename="companyName" cname="公司名称" enable="true" width="120" align="center" readOnly="true"/>
<EF:EFColumn ename="projName" cname="项目名称" enable="true" width="120" align="center" readOnly="true"/>
<EF:EFColumn ename="workCode" cname="报工单号" width="100" enable="false" readonly="true" align="center"/>
<EF:EFColumn ename="productCode" cname="产品编码" width="100" enable="false" readonly="true" align="center"/>
<EF:EFColumn ename="productName" cname="产品名称" width="100" enable="false" readonly="true" align="center"/>
<EF:EFColumn ename="processName" cname="工序" width="100" enable="false" readonly="true" align="center"/>
<EF:EFColumn ename="groupName" cname="生产组" width="100" enable="false" readonly="true" align="center"/>
<EF:EFColumn ename="quantity" cname="数量" width="100" enable="false" readonly="true" align="center"/>
<EF:EFColumn ename="singleWeight" cname="单重" width="100" enable="false" readonly="true" align="center"/>
<EF:EFColumn ename="totalWeight" cname="任务总重" width="100" enable="false" readonly="true" align="center"/>
</EF:EFGrid>
</EF:EFRegion>
</EF:EFPage>
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