Commit 3b2b7168 by yukang

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

# Conflicts:
#	src/main/java/com/baosight/hpjx/hp/pz/tools/HPPZTools.java
#	src/main/java/com/baosight/hpjx/hp/sc/sql/HPSC003.xml
#	src/main/java/com/baosight/hpjx/hp/sc/sql/HPSC004.xml
#	src/main/webapp/HP/SC/HPSC002.jsp
#	src/main/webapp/HP/SC/HPSC003.jsp
#	src/main/webapp/HP/SC/HPSC005.jsp
parents 92ad500e 99131737
package com.baosight.hpjx.common;
import com.baosight.iplat4j.core.ei.EiBlock;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
/**
* @Author jhs
* @Date 2024/1/22 18:23
*/
public enum ApprovalStatusEnum {
SAVED(1,"保存"),
SUBMIT(2,"已提交"),
APPROVED(3,"审批通过"),
REJECTION(4,"审批拒绝");
private Integer code;
private String value;
ApprovalStatusEnum(Integer code, String value) {
this.code = code;
this.value = value;
}
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;
}
public static EiBlock generatorEiBlock(){
EiBlock block = new EiBlock("approval_status_block_id");
List<Map<String,Object>> rows = new ArrayList<Map<String,Object>>(){{
add(new HashMap<String,Object>(){{
put(HPConstants.TEXT_FIELD,SAVED.code);
put(HPConstants.VALUE_FIELD,SAVED.value);
}});
add(new HashMap<String,Object>(){{
put(HPConstants.TEXT_FIELD,SUBMIT.code);
put(HPConstants.VALUE_FIELD,SUBMIT.value);
}});
add(new HashMap<String,Object>(){{
put(HPConstants.TEXT_FIELD,APPROVED.code);
put(HPConstants.VALUE_FIELD,APPROVED.value);
}});
add(new HashMap<String,Object>(){{
put(HPConstants.TEXT_FIELD,REJECTION.code);
put(HPConstants.VALUE_FIELD,REJECTION.value);
}});
}};
block.setRows(rows);
return block;
}
}
......@@ -58,8 +58,8 @@ public enum DdynamicEnum {
INVENT_ALL_BLOCK_ID("invent_all_block_id", "id", "spec", "material", "unit", "HPPZ006.queryComboBoxAll"),
/**
* 模块:存货档案产品名称
* 用途:存货档案产品名称下拉框
* 模块:存货档案部件名称
* 用途:存货档案部件名称下拉框
* 编写:wwl
*/
INVENT_PRDT_NAME_BLOCK_ID("invent_prdt_name_block_id","id","inventCode","inventName","HPPZ006.queryPrdtComboBoxAll"),
......
......@@ -7,7 +7,7 @@ package com.baosight.hpjx.common;
public class HPConstants {
/** 多字段拼接符号 XTC */
public static final String BLOCK_DETIL = "detail";
public static final String BLOCK_DETAIL = "detail";
//公司編碼
public static final String SQL_FIELD_COMPANYCODE = "companyCode";
......
......@@ -2,20 +2,17 @@ package com.baosight.hpjx.common;
import com.baosight.iplat4j.core.ei.EiBlock;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.*;
/**
* @Author wwl
* @Date 2024/1/10 14:29
*/
public enum InventTypeEnun {
public enum InventTypeEnum {
MATERIAL(1,"原材料"),
CONSUMABLE(2,"耗材"),
SEMI_FINISHED_PRODUCT(3,"半成品"),
FINISHED_PRODUCT(4,"产成品"),
SEMI_FINISHED_PRODUCT(3,"零部件"),
FINISHED_PRODUCT(4,"部件"),
WASTE(5,"废料"),
OTHER(6,"其他");
......@@ -23,31 +20,27 @@ public enum InventTypeEnun {
private String value;
InventTypeEnun(Integer code, String value) {
InventTypeEnum(Integer code, String value) {
this.code = code;
this.value = value;
}
public static String getNameByCode(String code){
String returnName = "";
switch (code){
case "1":
returnName = MATERIAL.value;
break;
case "2":
returnName = CONSUMABLE.value;
break;
case "3":
returnName = SEMI_FINISHED_PRODUCT.value;
break;
case "4":
returnName = FINISHED_PRODUCT.value;
break;
default:
break;
public static InventTypeEnum getEnumByCode(Integer code){
for (InventTypeEnum en : InventTypeEnum.values()){
if(code.compareTo(en.code)==0){
return en;
}
}
return null;
}
public static String getNameByCode(Integer code){
InventTypeEnum en = getEnumByCode(code);
if(Objects.nonNull(en)){
return en.getValue();
}
return null;
}
return returnName;
};
public Integer getCode() {
return code;
......
......@@ -40,7 +40,7 @@ public class HPKC005 extends DaoEPBase {
public static final String FIELD_DIFF_AMOUNT = "diffAmount"; /* 差异数量*/
public static final String FIELD_DIFF_WEIGHT = "diffWeight"; /* 差异重量*/
public static final String FIELD_KC_ID = "kcId"; /* 库存ID*/
public static final String FIELD_STATUS = "status"; /* 单据状态 0待审核 1已审核*/
public static final String FIELD_STATUS = "status"; /* 单据状态 0待提交 1已提交*/
public static final String FIELD_REMARK = "remark"; /* 备注*/
public static final String FIELD_OLD_CHECK_NO = "oldCheckNo"; /* 原盘点单号*/
public static final String FIELD_CREATED_BY = "createdBy"; /* 创建人*/
......@@ -69,7 +69,7 @@ public class HPKC005 extends DaoEPBase {
public static final String COL_DIFF_AMOUNT = "DIFF_AMOUNT"; /* 差异数量*/
public static final String COL_DIFF_WEIGHT = "DIFF_WEIGHT"; /* 差异重量*/
public static final String COL_KC_ID = "KC_ID"; /* 库存ID*/
public static final String COL_STATUS = "STATUS"; /* 单据状态 0待审核 1已审核*/
public static final String COL_STATUS = "STATUS"; /* 单据状态 0待提交 1已提交*/
public static final String COL_REMARK = "REMARK"; /* 备注*/
public static final String COL_OLD_CHECK_NO = "OLD_CHECK_NO"; /* 原盘点单号*/
public static final String COL_CREATED_BY = "CREATED_BY"; /* 创建人*/
......@@ -104,7 +104,7 @@ public class HPKC005 extends DaoEPBase {
private BigDecimal diffAmount = new BigDecimal(0.00); /* 差异数量*/
private BigDecimal diffWeight = new BigDecimal(0.00); /* 差异重量*/
private Long kcId = null; /* 库存ID*/
private Integer status = new Integer(0); /* 单据状态 0待审核 1已审核*/
private Integer status = new Integer(0); /* 单据状态 0待提交 1已提交*/
private String remark = " "; /* 备注*/
private String oldCheckNo = " "; /* 原盘点单号*/
private String createdBy = " "; /* 创建人*/
......@@ -213,7 +213,7 @@ public class HPKC005 extends DaoEPBase {
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_STATUS);
eiColumn.setDescName("单据状态 0待审核 1已审核");
eiColumn.setDescName("单据状态 0待提交 1已提交");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_REMARK);
......@@ -551,7 +551,7 @@ public class HPKC005 extends DaoEPBase {
this.kcId = kcId;
}
/**
* get the status - 单据状态 0待审核 1已审核.
* get the status - 单据状态 0待提交 1已提交.
* @return the status
*/
public Integer getStatus() {
......@@ -559,9 +559,9 @@ public class HPKC005 extends DaoEPBase {
}
/**
* set the status - 单据状态 0待审核 1已审核.
* set the status - 单据状态 0待提交 1已提交.
*
* @param status - 单据状态 0待审核 1已审核
* @param status - 单据状态 0待提交 1已提交
*/
public void setStatus(Integer status) {
this.status = status;
......
......@@ -35,7 +35,7 @@ public class HPKC006 extends DaoEPBase {
public static final String FIELD_INVENT_RECORD_ID = "inventRecordId"; /* 规格*/
public static final String FIELD_AMOUNT = "amount"; /* 数量*/
public static final String FIELD_WEIGHT = "weight"; /* 重量*/
public static final String FIELD_STATUS = "status"; /* 状态 0审核 1保存*/
public static final String FIELD_STATUS = "status"; /* 状态 0提交 1保存*/
public static final String FIELD_REMARK = "remark"; /* 备注*/
public static final String FIELD_OLD_ENTER_NO = "oldEnterNo"; /* 原入库单号*/
public static final String FIELD_CREATED_BY = "createdBy"; /* 创建人*/
......@@ -59,7 +59,7 @@ public class HPKC006 extends DaoEPBase {
public static final String COL_INVENT_RECORD_ID = "INVENT_RECORD_ID"; /* 规格*/
public static final String COL_AMOUNT = "AMOUNT"; /* 数量*/
public static final String COL_WEIGHT = "WEIGHT"; /* 重量*/
public static final String COL_STATUS = "STATUS"; /* 状态 0审核 1保存*/
public static final String COL_STATUS = "STATUS"; /* 状态 0提交 1保存*/
public static final String COL_REMARK = "REMARK"; /* 备注*/
public static final String COL_OLD_ENTER_NO = "OLD_ENTER_NO"; /* 原入库单号*/
public static final String COL_CREATED_BY = "CREATED_BY"; /* 创建人*/
......@@ -89,7 +89,7 @@ public class HPKC006 extends DaoEPBase {
private Long inventRecordId = null; /* 规格*/
private BigDecimal amount = new BigDecimal(0.00); /* 数量*/
private BigDecimal weight = new BigDecimal(0.00); /* 重量*/
private Integer status = new Integer(0); /* 状态 0审核 1保存*/
private Integer status = new Integer(0); /* 状态 0提交 1保存*/
private String remark = " "; /* 备注*/
private String oldEnterNo = " "; /* 原入库单号*/
private String createdBy = " "; /* 创建人*/
......@@ -166,7 +166,7 @@ public class HPKC006 extends DaoEPBase {
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_STATUS);
eiColumn.setDescName("状态 0审核 1保存");
eiColumn.setDescName("状态 0提交 1保存");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_REMARK);
......@@ -424,7 +424,7 @@ public class HPKC006 extends DaoEPBase {
this.weight = weight;
}
/**
* get the status - 状态 0审核 1保存.
* get the status - 状态 0提交 1保存.
* @return the status
*/
public Integer getStatus() {
......@@ -432,9 +432,9 @@ public class HPKC006 extends DaoEPBase {
}
/**
* set the status - 状态 0审核 1保存.
* set the status - 状态 0提交 1保存.
*
* @param status - 状态 0审核 1保存
* @param status - 状态 0提交 1保存
*/
public void setStatus(Integer status) {
this.status = status;
......
......@@ -35,7 +35,7 @@ public class HPKC007 extends DaoEPBase {
public static final String FIELD_INVENT_RECORD_ID = "inventRecordId"; /* 规格ID*/
public static final String FIELD_AMOUNT = "amount"; /* 数量*/
public static final String FIELD_WEIGHT = "weight"; /* 重量*/
public static final String FIELD_STATUS = "status"; /* 状态 0审核 1保存*/
public static final String FIELD_STATUS = "status"; /* 状态 0提交 1保存*/
public static final String FIELD_KC_ID = "kcId"; /* 库存ID*/
public static final String FIELD_REMARK = "remark"; /* 备注*/
public static final String FIELD_OLD_OUTER_NO = "oldOuterNo"; /* 原出库单号*/
......@@ -60,7 +60,7 @@ public class HPKC007 extends DaoEPBase {
public static final String COL_INVENT_RECORD_ID = "INVENT_RECORD_ID"; /* 规格ID*/
public static final String COL_AMOUNT = "AMOUNT"; /* 数量*/
public static final String COL_WEIGHT = "WEIGHT"; /* 重量*/
public static final String COL_STATUS = "STATUS"; /* 状态 0审核 1保存*/
public static final String COL_STATUS = "STATUS"; /* 状态 0提交 1保存*/
public static final String COL_KC_ID = "KC_ID"; /* 库存ID*/
public static final String COL_REMARK = "REMARK"; /* 备注*/
public static final String COL_OLD_OUTER_NO = "OLD_OUTER_NO"; /* 原出库单号*/
......@@ -91,7 +91,7 @@ public class HPKC007 extends DaoEPBase {
private Long inventRecordId = null; /* 规格ID*/
private BigDecimal amount = new BigDecimal(0.00); /* 数量*/
private BigDecimal weight = new BigDecimal(0.00); /* 重量*/
private Integer status = 0; /* 状态 0审核 1保存*/
private Integer status = 0; /* 状态 0提交 1保存*/
private Long kcId = null; /* 库存ID*/
private String remark = " "; /* 备注*/
private String oldOuterNo = " "; /* 原出库单号*/
......@@ -169,7 +169,7 @@ public class HPKC007 extends DaoEPBase {
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_STATUS);
eiColumn.setDescName("状态 0审核 1保存");
eiColumn.setDescName("状态 0提交 1保存");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_KC_ID);
......@@ -431,7 +431,7 @@ public class HPKC007 extends DaoEPBase {
this.weight = weight;
}
/**
* get the status - 状态 0审核 1保存.
* get the status - 状态 0提交 1保存.
* @return the status
*/
public Integer getStatus() {
......@@ -439,9 +439,9 @@ public class HPKC007 extends DaoEPBase {
}
/**
* set the status - 状态 0审核 1保存.
* set the status - 状态 0提交 1保存.
*
* @param status - 状态 0审核 1保存
* @param status - 状态 0提交 1保存
*/
public void setStatus(Integer status) {
this.status = status;
......
package com.baosight.hpjx.hp.kc.service;
import com.baosight.hpjx.common.DdynamicEnum;
import com.baosight.hpjx.common.InventTypeEnun;
import com.baosight.hpjx.common.InventTypeEnum;
import com.baosight.hpjx.core.constant.CommonConstant;
import com.baosight.hpjx.core.dao.DaoUtils;
import com.baosight.hpjx.hp.constant.HPConstant;
......@@ -36,8 +36,8 @@ public class ServiceHPKC001 extends ServiceBase {
// 指定存货类型
private static final Integer[] DEFAULT_INVENT_CODE = {InventTypeEnun.MATERIAL.getCode(),
InventTypeEnun.CONSUMABLE.getCode()};
private static final Integer[] DEFAULT_INVENT_CODE = {InventTypeEnum.MATERIAL.getCode(),
InventTypeEnum.CONSUMABLE.getCode()};
/**
* 画面初始化
......
package com.baosight.hpjx.hp.kc.service;
import com.baosight.hpjx.common.DdynamicEnum;
import com.baosight.hpjx.common.InventTypeEnun;
import com.baosight.hpjx.common.InventTypeEnum;
import com.baosight.hpjx.core.constant.CommonConstant;
import com.baosight.hpjx.core.dao.DaoUtils;
import com.baosight.hpjx.hp.constant.HPConstant;
......@@ -32,8 +32,8 @@ import java.util.Map;
public class ServiceHPKC002 extends ServiceBase {
// 指定存货类型
private static final Integer[] DEFAULT_INVENT_CODE = {InventTypeEnun.MATERIAL.getCode(),
InventTypeEnun.CONSUMABLE.getCode()};
private static final Integer[] DEFAULT_INVENT_CODE = {InventTypeEnum.MATERIAL.getCode(),
InventTypeEnum.CONSUMABLE.getCode()};
/**
* 画面初始化.
......@@ -48,7 +48,7 @@ public class ServiceHPKC002 extends ServiceBase {
CommonMethod.initBlock(inInfo, Arrays.asList(DdynamicEnum.INVENT_SPEC_BLOCK_ID), queryMap, false);
CommonMethod.initBlock(inInfo, Arrays.asList(DdynamicEnum.SPEC_NAME_BLOCK_ID), queryMap, false);
inInfo.addBlock(EiConstant.resultBlock).addBlockMeta(new HPKC002().eiMetadata);
inInfo.setBlock(InventTypeEnun.generatorEiBlock());
inInfo.setBlock(InventTypeEnum.generatorEiBlock());
} catch (PlatException e) {
LogUtils.setDetailMsg(inInfo, e, "初始化失败");
}
......
package com.baosight.hpjx.hp.kc.service;
import com.baosight.hpjx.common.DdynamicEnum;
import com.baosight.hpjx.common.InventTypeEnun;
import com.baosight.hpjx.common.InventTypeEnum;
import com.baosight.hpjx.core.constant.CommonConstant;
import com.baosight.hpjx.core.dao.DaoUtils;
import com.baosight.hpjx.hp.constant.HPConstant;
......@@ -36,8 +36,8 @@ import java.util.Map;
public class ServiceHPKC002A extends ServiceEPBase {
// 指定存货类型
private static final Integer[] DEFAULT_INVENT_CODE = {InventTypeEnun.MATERIAL.getCode(),
InventTypeEnun.CONSUMABLE.getCode()};
private static final Integer[] DEFAULT_INVENT_CODE = {InventTypeEnum.MATERIAL.getCode(),
InventTypeEnum.CONSUMABLE.getCode()};
/**
* 初始化
......
package com.baosight.hpjx.hp.kc.service;
import com.baosight.hpjx.common.DdynamicEnum;
import com.baosight.hpjx.common.InventTypeEnun;
import com.baosight.hpjx.common.InventTypeEnum;
import com.baosight.hpjx.core.constant.CommonConstant;
import com.baosight.hpjx.core.dao.DaoUtils;
import com.baosight.hpjx.hp.constant.HPConstant;
......@@ -31,9 +31,9 @@ import java.util.Map;
public class ServiceHPKC004 extends ServiceBase {
// 指定存货类型
private static final Integer[] DEFAULT_INVENT_CODE = {InventTypeEnun.MATERIAL.getCode(),
InventTypeEnun.CONSUMABLE.getCode(), InventTypeEnun.SEMI_FINISHED_PRODUCT.getCode(),
InventTypeEnun.FINISHED_PRODUCT.getCode()};
private static final Integer[] DEFAULT_INVENT_CODE = {InventTypeEnum.MATERIAL.getCode(),
InventTypeEnum.CONSUMABLE.getCode(), InventTypeEnum.SEMI_FINISHED_PRODUCT.getCode(),
InventTypeEnum.FINISHED_PRODUCT.getCode()};
/**
* 画面初始化
......
package com.baosight.hpjx.hp.kc.service;
import com.baosight.hpjx.common.DdynamicEnum;
import com.baosight.hpjx.common.InventTypeEnun;
import com.baosight.hpjx.common.InventTypeEnum;
import com.baosight.hpjx.core.constant.CommonConstant;
import com.baosight.hpjx.core.dao.DaoUtils;
import com.baosight.hpjx.hp.constant.HPConstant;
......@@ -36,9 +36,9 @@ import java.util.Map;
public class ServiceHPKC004A extends ServiceEPBase {
// 指定存货类型
private static final Integer[] DEFAULT_INVENT_CODE = {InventTypeEnun.MATERIAL.getCode(),
InventTypeEnun.CONSUMABLE.getCode(), InventTypeEnun.SEMI_FINISHED_PRODUCT.getCode(),
InventTypeEnun.FINISHED_PRODUCT.getCode()};
private static final Integer[] DEFAULT_INVENT_CODE = {InventTypeEnum.MATERIAL.getCode(),
InventTypeEnum.CONSUMABLE.getCode(), InventTypeEnum.SEMI_FINISHED_PRODUCT.getCode(),
InventTypeEnum.FINISHED_PRODUCT.getCode()};
/**
* 初始化
......
package com.baosight.hpjx.hp.kc.service;
import com.baosight.hpjx.common.DdynamicEnum;
import com.baosight.hpjx.common.InventTypeEnun;
import com.baosight.hpjx.common.InventTypeEnum;
import com.baosight.hpjx.core.constant.CommonConstant;
import com.baosight.hpjx.core.dao.DaoUtils;
import com.baosight.hpjx.hp.constant.HPConstant;
......@@ -38,8 +38,8 @@ import java.util.Map;
public class ServiceHPKC006 extends ServiceBase {
// 指定存货类型
private static final Integer[] DEFAULT_INVENT_CODE = {InventTypeEnun.MATERIAL.getCode(),
InventTypeEnun.CONSUMABLE.getCode(), InventTypeEnun.WASTE.getCode()};
private static final Integer[] DEFAULT_INVENT_CODE = {InventTypeEnum.MATERIAL.getCode(),
InventTypeEnum.CONSUMABLE.getCode(), InventTypeEnum.WASTE.getCode()};
/**
* 画面初始化
......
package com.baosight.hpjx.hp.kc.service;
import com.baosight.hpjx.common.DdynamicEnum;
import com.baosight.hpjx.common.InventTypeEnun;
import com.baosight.hpjx.common.InventTypeEnum;
import com.baosight.hpjx.core.constant.CommonConstant;
import com.baosight.hpjx.core.dao.DaoUtils;
import com.baosight.hpjx.hp.constant.HPConstant;
......@@ -38,8 +38,8 @@ import java.util.Map;
public class ServiceHPKC007 extends ServiceBase {
// 指定存货类型
private static final Integer[] DEFAULT_INVENT_CODE = {InventTypeEnun.MATERIAL.getCode(),
InventTypeEnun.CONSUMABLE.getCode(), InventTypeEnun.WASTE.getCode()};
private static final Integer[] DEFAULT_INVENT_CODE = {InventTypeEnum.MATERIAL.getCode(),
InventTypeEnum.CONSUMABLE.getCode(), InventTypeEnum.WASTE.getCode()};
/**
* 画面初始化
......
package com.baosight.hpjx.hp.kc.service;
import com.baosight.hpjx.common.DdynamicEnum;
import com.baosight.hpjx.common.InventTypeEnun;
import com.baosight.hpjx.common.InventTypeEnum;
import com.baosight.hpjx.core.dao.DaoUtils;
import com.baosight.hpjx.hp.constant.HPConstant;
import com.baosight.hpjx.hp.kc.domain.HPKC007;
......@@ -35,8 +35,8 @@ import java.util.Map;
public class ServiceHPKC007A extends ServiceEPBase {
// 指定存货类型
private static final Integer[] DEFAULT_INVENT_CODE = {InventTypeEnun.MATERIAL.getCode(),
InventTypeEnun.CONSUMABLE.getCode(), InventTypeEnun.WASTE.getCode()};
private static final Integer[] DEFAULT_INVENT_CODE = {InventTypeEnum.MATERIAL.getCode(),
InventTypeEnum.CONSUMABLE.getCode(), InventTypeEnum.WASTE.getCode()};
/**
* 初始化
......
package com.baosight.hpjx.hp.kc.service;
import com.baosight.hpjx.common.DdynamicEnum;
import com.baosight.hpjx.common.InventTypeEnun;
import com.baosight.hpjx.common.InventTypeEnum;
import com.baosight.hpjx.core.dao.DaoUtils;
import com.baosight.hpjx.hp.constant.HPConstant;
import com.baosight.hpjx.hp.constant.HPSqlConstant;
......@@ -29,7 +29,7 @@ import java.util.Map;
public class ServiceHPKC008 extends ServiceBase {
// 指定存货类型
private static final Integer[] DEFAULT_INVENT_CODE = {InventTypeEnun.OTHER.getCode()};
private static final Integer[] DEFAULT_INVENT_CODE = {InventTypeEnum.OTHER.getCode()};
/**
......
......@@ -21,7 +21,7 @@
DIFF_AMOUNT as "diffAmount", <!-- 差异数量 -->
DIFF_WEIGHT as "diffWeight", <!-- 差异重量 -->
KC_ID as "kcId", <!-- 库存ID -->
STATUS as "status", <!-- 单据状态 0待审核 1已审核 -->
STATUS as "status", <!-- 单据状态 0待提交 1已提交 -->
REMARK as "remark", <!-- 备注 -->
OLD_CHECK_NO as "oldCheckNo", <!-- 原盘点单号 -->
CREATED_BY as "createdBy", <!-- 创建人 -->
......
......@@ -16,7 +16,7 @@
INVENT_RECORD_ID as "inventRecordId", <!-- 规格 -->
AMOUNT as "amount", <!-- 数量 -->
WEIGHT as "weight", <!-- 重量 -->
STATUS as "status", <!-- 状态 0审核 1保存 -->
STATUS as "status", <!-- 状态 0提交 1保存 -->
REMARK as "remark", <!-- 备注 -->
OLD_ENTER_NO as "oldEnterNo", <!-- 原入库单号 -->
CREATED_BY as "createdBy", <!-- 创建人 -->
......
......@@ -16,7 +16,7 @@
INVENT_RECORD_ID as "inventRecordId", <!-- 规格 -->
AMOUNT as "amount", <!-- 数量 -->
WEIGHT as "weight", <!-- 重量 -->
STATUS as "status", <!-- 状态 0审核 1保存 -->
STATUS as "status", <!-- 状态 0提交 1保存 -->
KC_ID as "kcId", <!-- 库存ID -->
REMARK as "remark", <!-- 备注 -->
OLD_OUTER_NO as "oldOuterNo", <!-- 原出库单号 -->
......
......@@ -2,6 +2,7 @@ package com.baosight.hpjx.hp.pz.service;
import com.baosight.hpjx.common.DdynamicEnum;
import com.baosight.hpjx.common.InitiateModeEnum;
import com.baosight.hpjx.core.constant.CommonConstant;
import com.baosight.hpjx.core.dao.DaoUtils;
import com.baosight.hpjx.hp.constant.HPConstant;
import com.baosight.hpjx.hp.pz.domain.HPPZ003;
......@@ -15,7 +16,9 @@ import com.baosight.iplat4j.core.ei.EiInfo;
import com.baosight.iplat4j.core.exception.PlatException;
import com.baosight.iplat4j.core.service.impl.ServiceBase;
import com.baosight.iplat4j.ed.util.SequenceGenerator;
import org.apache.commons.collections.CollectionUtils;
import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
......@@ -73,7 +76,7 @@ public class ServiceHPPZ004 extends ServiceBase {
for (int i = 0; i < resultRows.size(); i++) {
HPPZ004 fPz004 = new HPPZ004();
fPz004.fromMap(resultRows.get(i));
// 生成客户编码
// 生成编码
fPz004.setInventCode(SequenceGenerator.getNextSequence(HPConstant.SequenceId.INVENT_CODE));
DaoUtils.insert(HPPZ004.INSERT, fPz004);
}
......@@ -110,6 +113,34 @@ public class ServiceHPPZ004 extends ServiceBase {
}
/**
* 判断存货名称是否存在,如果存在返回编码,否则新增并返回编码
* @param inInfo
* @return
*/
public EiInfo checkAndSave(EiInfo inInfo){
String inventType = inInfo.getString("inventType");
String inventName = inInfo.getString("inventName");
List<Map> list = dao.query("HPPZ004.queryByCondition",new HashMap<String,Object>(){{
put("inventType",inventType);
put("inventName",inventName);
}});
HPPZ004 hppz004 = new HPPZ004();
if(CollectionUtils.isEmpty(list)){
hppz004.fromMap(list.get(0));
}else{
// 生成编码
hppz004.setInventCode(SequenceGenerator.getNextSequence(HPConstant.SequenceId.INVENT_CODE));
hppz004.setInventType(Integer.parseInt(inventType));
hppz004.setInventName(inventName);
hppz004.setStatus(CommonConstant.YesNo.YES_1.intValue());
DaoUtils.insert(HPPZ004.INSERT, hppz004);
}
inInfo.setAttr(new HashMap(){{put("inventCode",hppz004.getInventCode());}});
inInfo.setStatus(EiConstant.STATUS_SUCCESS);
return inInfo;
}
/**
* 删除操作
*
* @param inInfo
......
......@@ -2,7 +2,10 @@ package com.baosight.hpjx.hp.pz.service;
import com.baosight.hpjx.common.DdynamicEnum;
import com.baosight.hpjx.common.InitiateModeEnum;
import com.baosight.hpjx.core.constant.CommonConstant;
import com.baosight.hpjx.core.dao.DaoUtils;
import com.baosight.hpjx.hp.constant.HPConstant;
import com.baosight.hpjx.hp.pz.domain.HPPZ004;
import com.baosight.hpjx.hp.pz.domain.HPPZ006;
import com.baosight.hpjx.hp.pz.tools.HPPZTools;
import com.baosight.hpjx.util.AssertUtils;
......@@ -14,13 +17,12 @@ 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.ServiceBase;
import com.baosight.iplat4j.ed.util.SequenceGenerator;
import org.apache.commons.collections.CollectionUtils;
import org.apache.commons.lang.StringUtils;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.math.BigDecimal;
import java.util.*;
/**
* @author:songx
......@@ -156,6 +158,62 @@ public class ServiceHPPZ006 extends ServiceBase {
return inInfo;
}
/**
* 判断存货档案是否存在,如果存在返回ID,否则新增并返回ID
* @param inInfo
* @return
*/
public EiInfo checkAndSave(EiInfo inInfo){
String inventType = inInfo.getString("inventType");
String inventCode = inInfo.getString("inventCode");
String inventName = inInfo.getString("inventName");
String length = inInfo.getString("length");
String width = inInfo.getString("width");
String thick = inInfo.getString("thick");
String material = inInfo.getString("material");
String coefficient = inInfo.getString("coefficient");
String unit = inInfo.getString("unit");
List<Map> list = dao.query("HPPZ006.queryByCondition",new HashMap<String,Object>(){{
put("inventType",inventType);
put("inventCode",inventCode);
put("inventName",inventName);
put("length", Objects.nonNull(length)?length:"");
put("width",Objects.nonNull(width)?width:"");
put("thick",Objects.nonNull(thick)?thick:"");
put("material",Objects.nonNull(material)?material:"");
put("coefficient",Objects.nonNull(coefficient)?coefficient:"");
put("unit",Objects.nonNull(unit)?unit:"");
}});
HPPZ006 hppz006 = new HPPZ006();
if(CollectionUtils.isEmpty(list)){
hppz006.fromMap(list.get(0));
}else{
// 生成编码
hppz006.setInventType(Integer.parseInt(inventType));
hppz006.setInventCode(SequenceGenerator.getNextSequence(HPConstant.SequenceId.INVENT_CODE));
hppz006.setInventName(inventName);
hppz006.setLength(new BigDecimal(length));
hppz006.setWidth(new BigDecimal(width));
hppz006.setThick(new BigDecimal(thick));
hppz006.setMaterial(material);
hppz006.setCoefficient(new BigDecimal(coefficient));
hppz006.setUnit(unit);
hppz006.setStatus(CommonConstant.YesNo.YES_1.intValue());
StringBuffer sepbuf = new StringBuffer();
if(Objects.nonNull(length)){sepbuf.append(length).append("*");}
if(Objects.nonNull(width)){sepbuf.append(width).append("*");}
if(Objects.nonNull(thick)){sepbuf.append(thick);}
if(StringUtils.isNotEmpty(sepbuf.toString())){
hppz006.setSpec(sepbuf.toString());
}
DaoUtils.insert(HPPZ006.INSERT, hppz006);
}
inInfo.setAttr(new HashMap(){{put("obj",hppz006);}});
inInfo.setStatus(EiConstant.STATUS_SUCCESS);
return inInfo;
}
/**
* 规格下拉框
*
......
......@@ -72,6 +72,24 @@
<include refid="order"/>
</select>
<select id="queryByCondition" resultClass="java.util.HashMap">
SELECT
<include refid="column"/>
FROM hpjx.t_hppz004 WHERE 1=1
<isNotEmpty prepend=" AND " property="companyCode">
COMPANY_CODE = #companyCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="inventType">
INVENT_TYPE = #inventType#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="inventCode">
INVENT_CODE = #inventCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="inventName">
INVENT_NAME = #inventName#
</isNotEmpty>
</select>
<select id="count" resultClass="int">
SELECT COUNT(*) FROM hpjx.t_hppz004 WHERE 1=1
<include refid="condition"/>
......
......@@ -79,6 +79,45 @@
<include refid="order"/>
</select>
<select id="queryByCondition" resultClass="java.util.HashMap">
SELECT
<include refid="column"/>
FROM hpjx.t_hppz006 WHERE 1=1
<isNotEmpty prepend=" AND " property="companyCode">
COMPANY_CODE = #companyCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="inventType">
INVENT_TYPE = #inventType#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="inventCode">
INVENT_CODE = #inventCode#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="inventName">
INVENT_NAME = #inventName#
</isNotEmpty>
<isNotNull prepend=" AND " property="length">
IFNULL(LENGTH,'') = #length#
</isNotNull>
<isNotNull prepend=" AND " property="width">
IFNULL(WIDTH,'') = #width#
</isNotNull>
<isNotNull prepend=" AND " property="thick">
IFNULL(THICK,'') = #thick#
</isNotNull>
<isNotNull prepend=" AND " property="material">
IFNULL(MATERIAL,'') = #material#
</isNotNull>
<isNotNull prepend=" AND " property="coefficient">
IFNULL(COEFFICIENT,'') = #coefficient#
</isNotNull>
<isNotNull prepend=" AND " property="unit">
IFNULL(UNIT,'') = #unit#
</isNotNull>
<isNotEmpty prepend=" AND " property="status">
STATUS = #status#
</isNotEmpty>
</select>
<select id="count" resultClass="int">
SELECT COUNT(*) FROM hpjx.t_hppz006 WHERE 1=1
<include refid="condition"/>
......@@ -209,7 +248,7 @@
ORDER BY ID
</select>
<!-- 存货档案产品下拉框 -->
<!-- 存货档案部件下拉框 -->
<select id="queryPrdtComboBoxAll" parameterClass="java.util.HashMap" resultClass="java.util.HashMap">
SELECT DISTINCT
ID AS "id",
......
package com.baosight.hpjx.hp.pz.tools;
import com.baosight.hpjx.common.InventTypeEnum;
import com.baosight.hpjx.core.constant.CommonConstant;
import com.baosight.hpjx.core.dao.DaoBase;
import com.baosight.hpjx.hp.pz.domain.HPPZ006;
import com.baosight.hpjx.hp.pz.domain.HPPZ007;
import com.baosight.hpjx.hp.pz.domain.HPPZ009;
import com.baosight.hpjx.hp.pz.domain.HPPZ004;
import com.baosight.hpjx.util.AssertUtils;
import com.baosight.iplat4j.core.util.StringUtils;
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.soa.XLocalManager;
import org.apache.commons.lang.StringUtils;
import org.springframework.util.CollectionUtils;
import java.math.BigDecimal;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.Objects;
import java.util.stream.Collectors;
/**
......@@ -160,4 +168,67 @@ public class HPPZTools {
return sb.toString();
}
/**
* 判断存货名称是否存在,如果存在返回编码,否则新增并返回编码
* @param inventType 存货类型
* @param inventName 存货名称
*/
public static String checkAndSavePZ04(Integer inventType, String inventName) {
if(Objects.isNull(inventType)){
throw new PlatException("存货类型不能为空!");
}
if(Objects.isNull(InventTypeEnum.getEnumByCode(inventType))){
throw new PlatException("存货类型异常!");
}
if(StringUtils.isBlank(inventName)){
throw new PlatException("存货名称不能为空!");
}
EiInfo inInfo = new EiInfo();
inInfo.set("inventType", inventType);
inInfo.set("inventName", inventName);
inInfo.set(EiConstant.serviceName, "HPPZ004");
inInfo.set(EiConstant.methodName, "checkAndSave");
EiInfo outInfo = XLocalManager.call(inInfo);
return outInfo.getAttr().get("inventCode").toString();
}
/**
* 判断存货档案是否存在,如果存在返回存货档案,否则新增并返回存货档案
* @param inventType 存货类型
* @param inventName 存货名称
* @param length 长
* @param width 宽
* @param thick 厚
* @param coefficient 系数
* @param material 材质
* @param unit 单位
*/
public static HPPZ006 checkAndSavePZ06(Integer inventType, String inventName
, BigDecimal length, BigDecimal width, BigDecimal thick, BigDecimal coefficient, String material, String unit) {
if(Objects.isNull(inventType)){
throw new PlatException("存货类型不能为空!");
}
if(Objects.isNull(InventTypeEnum.getEnumByCode(inventType))){
throw new PlatException("存货类型异常!");
}
if(StringUtils.isBlank(inventName)){
throw new PlatException("存货名称不能为空!");
}
EiInfo inInfo = new EiInfo();
inInfo.set("inventType", inventType);
inInfo.set("inventCode", checkAndSavePZ04(inventType,inventName));
inInfo.set("inventName", inventName);
inInfo.set("length", length);
inInfo.set("width", width);
inInfo.set("thick", thick);
inInfo.set("material", material);
inInfo.set("coefficient", coefficient);
inInfo.set("unit", unit);
inInfo.set(EiConstant.serviceName, "HPPZ006");
inInfo.set(EiConstant.methodName, "checkAndSave");
EiInfo outInfo = XLocalManager.call(inInfo);
return (HPPZ006) outInfo.getAttr().get("obj");
}
}
......@@ -17,7 +17,7 @@ public class HPSC001 extends DaoEPBase {
private String projName = " "; /* 项目名称*/
private String princ1 = " "; /* 本公司项目负责人*/
private String princ2 = " "; /* 客户项目负责人*/
private Integer status = 0; /* 状态 0-未审核,1-已审核*/
private Integer status = 0; /* 状态 0-未提交,1-已提交*/
private String createdBy = " "; /* 创建人*/
private String createdName = " "; /* 创建人名称*/
private String createdTime ; /* 创建时间*/
......@@ -27,7 +27,7 @@ public class HPSC001 extends DaoEPBase {
private String depCode = " "; /* 部门编码*/
private String remark = " "; /* 备注*/
private Integer materialStatus = 0; /* 物料审核状态0-未审核,1部分审核,2全部审核*/
private Integer materialStatus = 0; /* 物料提交状态0-未提交,1部分提交,2全部提交*/
/**
* initialize the metadata
*/
......@@ -64,7 +64,7 @@ public class HPSC001 extends DaoEPBase {
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn("status");
eiColumn.setDescName("状态 0-未审核,1-已审核");
eiColumn.setDescName("状态 0-未提交,1-已提交");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn("createdBy");
......@@ -100,7 +100,7 @@ public class HPSC001 extends DaoEPBase {
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn("materialStatus");
eiColumn.setDescName("物料审核状态0-未审核,1部分审核,2全部审核");
eiColumn.setDescName("物料提交状态0-未提交,1部分提交,2全部提交");
eiMetadata.addMeta(eiColumn);
}
/**
......@@ -209,7 +209,7 @@ public class HPSC001 extends DaoEPBase {
this.princ2 = princ2;
}
/**
* get the status - 状态 0-未审核,1-已审核
* get the status - 状态 0-未提交,1-已提交
* @return the status
*/
public Integer getStatus() {
......@@ -217,7 +217,7 @@ public class HPSC001 extends DaoEPBase {
}
/**
* set the status - 状态 0-未审核,1-已审核
* set the status - 状态 0-未提交,1-已提交
*/
public void setStatus(Integer status) {
this.status = status;
......@@ -325,13 +325,13 @@ public class HPSC001 extends DaoEPBase {
this.remark = remark;
}
/**
* set the materialStatus - 物料审核状态0-未审核,1部分审核,2全部审核
* set the materialStatus - 物料提交状态0-未提交,1部分提交,2全部提交
*/
public void setMaterialStatus(Integer materialStatus) {
this.materialStatus = materialStatus;
}
/**
* get the materialStatus - 物料审核状态0-未审核,1部分审核,2全部审核
* get the materialStatus - 物料提交状态0-未提交,1部分提交,2全部提交
* @return the materialStatus
*/
public Integer getMaterialStatus() {
......
......@@ -27,15 +27,15 @@ public class HPSC002 extends DaoEPBase {
private String deptCode = " "; /* 部门编码 预留*/
private String projCode = " "; /* 项目编码*/
private String projName = " "; /* 项目名称*/
private String parentId = ""; /* 父节点-产品编码*/
private String parentPrdtName = " "; /* 父节点-产品名称*/
private String parentId = ""; /* 父节点-部件编码*/
private String parentPrdtName = " "; /* 父节点-部件名称*/
private String type = " "; /* 类别*/
private String leaf = "1"; /* 是否有叶子节点*/
private String sort = " "; /* 排序字段*/
private String icon = " "; /* 图片地址*/
private Integer prdtType = 0; /*产品类型*/
private String prdtCode = " "; /* 产品编码*/
private String prdtName = " "; /* 产品名称*/
private Integer prdtType = 0; /*部件类型*/
private String prdtCode = " "; /* 部件编码*/
private String prdtName = " "; /* 部件名称*/
private Long inventRecordId = new Long(0); /* 存货档案ID*/
private BigDecimal num = new BigDecimal(0.000); /* 数量*/
private BigDecimal unitWt = new BigDecimal(0.000); /* 单重*/
......@@ -45,7 +45,7 @@ public class HPSC002 extends DaoEPBase {
private String filePath3 = " "; /* 文件地址3*/
private String filePath4 = " "; /* 文件地址4*/
private String filePath5 = " "; /* 文件地址5*/
private Integer status = 0; /* 状态 0-未审核,1-已审核*/
private Integer status = 0; /* 状态 0-未提交,1-已提交*/
private Integer delStatus = 0; /* 状态 1未删除,0已删除*/
private String createdBy = " "; /* 创建人*/
private String createdTime; /* 创建时间*/
......@@ -89,11 +89,11 @@ public class HPSC002 extends DaoEPBase {
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn("parentId");
eiColumn.setDescName("父节点-产品编码");
eiColumn.setDescName("父节点-部件编码");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn("parentPrdtName");
eiColumn.setDescName("父节点-产品名称");
eiColumn.setDescName("父节点-部件名称");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn("type");
......@@ -113,15 +113,15 @@ public class HPSC002 extends DaoEPBase {
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn("prdtType");
eiColumn.setDescName("产品类型");
eiColumn.setDescName("部件类型");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn("prdtCode");
eiColumn.setDescName("产品编码");
eiColumn.setDescName("部件编码");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn("prdtName");
eiColumn.setDescName("产品名称");
eiColumn.setDescName("部件名称");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn("inventRecordId");
......@@ -167,7 +167,7 @@ public class HPSC002 extends DaoEPBase {
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn("status");
eiColumn.setDescName("状态 0-未审核,1-已审核");
eiColumn.setDescName("状态 0-未提交,1-已提交");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn("delStatus");
......@@ -308,7 +308,7 @@ public class HPSC002 extends DaoEPBase {
}
/**
* get the parentId - 父节点-产品编码
* get the parentId - 父节点-部件编码
* @return the parentId
*/
public String getParentId() {
......@@ -316,14 +316,14 @@ public class HPSC002 extends DaoEPBase {
}
/**
* set the parentId - 父节点-产品编码
* set the parentId - 父节点-部件编码
*/
public void setParentId(String parentId) {
this.parentId = parentId;
}
/**
* get the parentPrdtName - 父节点-产品名称
* get the parentPrdtName - 父节点-部件名称
* @return the parentPrdtName
*/
public String getParentPrdtName() {
......@@ -331,7 +331,7 @@ public class HPSC002 extends DaoEPBase {
}
/**
* set the parentPrdtName - 父节点-产品名称
* set the parentPrdtName - 父节点-部件名称
*/
public void setParentPrdtName(String parentPrdtName) {
this.parentPrdtName = parentPrdtName;
......@@ -398,7 +398,7 @@ public class HPSC002 extends DaoEPBase {
}
/**
* get the prdtType - 产品类型
* get the prdtType - 部件类型
* @return the prdtType
*/
public Integer getPrdtType() {
......@@ -406,14 +406,14 @@ public class HPSC002 extends DaoEPBase {
}
/**
* set the prdtType - 产品类型
* set the prdtType - 部件类型
*/
public void setPrdtType(Integer prdtType) {
this.prdtType = prdtType;
}
/**
* get the prdtCode - 产品编码
* get the prdtCode - 部件编码
* @return the prdtCode
*/
public String getPrdtCode() {
......@@ -421,14 +421,14 @@ public class HPSC002 extends DaoEPBase {
}
/**
* set the prdtCode - 产品编码
* set the prdtCode - 部件编码
*/
public void setPrdtCode(String prdtCode) {
this.prdtCode = prdtCode;
}
/**
* get the prdtName - 产品名称
* get the prdtName - 部件名称
* @return the prdtName
*/
public String getPrdtName() {
......@@ -436,7 +436,7 @@ public class HPSC002 extends DaoEPBase {
}
/**
* set the prdtName - 产品名称
* set the prdtName - 部件名称
*/
public void setPrdtName(String prdtName) {
this.prdtName = prdtName;
......@@ -578,7 +578,7 @@ public class HPSC002 extends DaoEPBase {
}
/**
* get the status - 状态 0-未审核,1-已审核
* get the status - 状态 0-未提交,1-已提交
* @return the status
*/
public Integer getStatus() {
......@@ -586,7 +586,7 @@ public class HPSC002 extends DaoEPBase {
}
/**
* set the status - 状态 0-未审核,1-已审核
* set the status - 状态 0-未提交,1-已提交
*/
public void setStatus(Integer status) {
this.status = status;
......
......@@ -29,9 +29,9 @@ public class HPSC003 extends DaoEPBase {
public static final String FIELD_PROJ_CODE = "projCode"; /* 项目编码*/
public static final String FIELD_PROJ_NAME = "projName"; /* 项目名称*/
public static final String FIELD_PLAN_INFO_NO = "planInfoNo"; /* 生产计划单号*/
public static final String FIELD_PRDT_TYPE = "prdtType"; /* 产品编码*/
public static final String FIELD_PRDT_CODE = "prdtCode"; /* 产品编码*/
public static final String FIELD_PRDT_NAME = "prdtName"; /* 产品名称*/
public static final String FIELD_PRDT_TYPE = "prdtType"; /* 部件编码*/
public static final String FIELD_PRDT_CODE = "prdtCode"; /* 部件编码*/
public static final String FIELD_PRDT_NAME = "prdtName"; /* 部件名称*/
public static final String FIELD_PLAN_COMPLETION_DATE = "planCompletionDate"; /* 计划完成日期*/
public static final String FIELD_STATUS = "status"; /* 状态 0-计划中,1-生产中*/
public static final String FIELD_CREATED_BY = "createdBy"; /* 创建人*/
......@@ -52,8 +52,8 @@ public class HPSC003 extends DaoEPBase {
public static final String COL_PROJ_NAME = "PROJ_NAME"; /* 项目编码*/
public static final String COL_PLAN_INFO_NO = "PLAN_INFO_NO"; /* 生产计划单号*/
public static final String COL_PRDT_TYPE = "PROJ_TYPE"; /* 项目类型*/
public static final String COL_PRDT_CODE = "PRDT_CODE"; /* 产品编码*/
public static final String COL_PRDT_NAME = "PRDT_NAME"; /* 产品名称*/
public static final String COL_PRDT_CODE = "PRDT_CODE"; /* 部件编码*/
public static final String COL_PRDT_NAME = "PRDT_NAME"; /* 部件名称*/
public static final String COL_PLAN_COMPLETION_DATE = "PLAN_COMPLETION_DATE"; /* 计划完成日期*/
public static final String COL_STATUS = "STATUS"; /* 状态 0-计划中,1-生产中*/
public static final String COL_CREATED_BY = "CREATED_BY"; /* 创建人*/
......@@ -76,9 +76,9 @@ public class HPSC003 extends DaoEPBase {
private String projCode = " "; /* 项目编码*/
private String projName = " "; /* 项目名称*/
private String planInfoNo = " "; /* 生产计划单号*/
private Integer prdtType = 0; /*产品类型*/
private String prdtCode = " "; /* 产品编码*/
private String prdtName = " "; /* 产品名称*/
private Integer prdtType = 0; /*部件类型*/
private String prdtCode = " "; /* 部件编码*/
private String prdtName = " "; /* 部件名称*/
private String planCompletionDate = " "; /* 计划完成日期*/
private Integer status = new Integer(0); /* 状态 0-计划中,1-生产中*/
private String createdBy = " "; /* 创建人*/
......@@ -131,15 +131,15 @@ public class HPSC003 extends DaoEPBase {
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_PRDT_TYPE);
eiColumn.setDescName("产品类型");
eiColumn.setDescName("部件类型");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_PRDT_CODE);
eiColumn.setDescName("产品编码");
eiColumn.setDescName("部件编码");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_PRDT_NAME);
eiColumn.setDescName("产品名称");
eiColumn.setDescName("部件名称");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_PLAN_COMPLETION_DATE);
......@@ -315,15 +315,15 @@ public class HPSC003 extends DaoEPBase {
}
/**
* set the prdtCode - 产品编码.
* set the prdtCode - 部件编码.
*
* @param prdtCode - 产品编码
* @param prdtCode - 部件编码
*/
public void setPrdtType(Integer prdtType) {
this.prdtType = prdtType;
}
/**
* get the prdtCode - 产品编码.
* get the prdtCode - 部件编码.
* @return the prdtCode
*/
public String getPrdtCode() {
......@@ -331,15 +331,15 @@ public class HPSC003 extends DaoEPBase {
}
/**
* set the prdtCode - 产品编码.
* set the prdtCode - 部件编码.
*
* @param prdtCode - 产品编码
* @param prdtCode - 部件编码
*/
public void setPrdtCode(String prdtCode) {
this.prdtCode = prdtCode;
}
/**
* get the prdtName - 产品名称.
* get the prdtName - 部件名称.
* @return the prdtName
*/
public String getPrdtName() {
......@@ -347,9 +347,9 @@ public class HPSC003 extends DaoEPBase {
}
/**
* set the prdtName - 产品名称.
* set the prdtName - 部件名称.
*
* @param prdtName - 产品名称
* @param prdtName - 部件名称
*/
public void setPrdtName(String prdtName) {
this.prdtName = prdtName;
......
......@@ -27,9 +27,9 @@ public class HPSC005 extends DaoEPBase {
public static final String FIELD_PROJ_CODE = "projCode"; /* 项目编码*/
public static final String FIELD_PROJ_NAME = "projName"; /* 项目名称*/
public static final String FIELD_PRODUCTION_ORDER_NO = "productionOrderNo"; /* 生产订单号*/
public static final String FIELD_PRDT_TYPE = "prdtType"; /* 产品类型*/
public static final String FIELD_PRDT_CODE = "prdtCode"; /* 产品编码*/
public static final String FIELD_PRDT_NAME = "prdtName"; /* 产品名称*/
public static final String FIELD_PRDT_TYPE = "prdtType"; /* 部件类型*/
public static final String FIELD_PRDT_CODE = "prdtCode"; /* 部件编码*/
public static final String FIELD_PRDT_NAME = "prdtName"; /* 部件名称*/
public static final String FIELD_PLAN_COMPLETION_DATE = "planCompletionDate"; /* 计划完成日期*/
public static final String FIELD_NUM = "num"; /* 计划数量*/
public static final String FIELD_TOTAL_WT = "totalWt"; /* 计划重量*/
......@@ -54,9 +54,9 @@ public class HPSC005 extends DaoEPBase {
public static final String COL_PROJ_CODE = "PROJ_CODE"; /* 项目编码*/
public static final String COL_PROJ_NAME = "PROJ_NAME"; /* 项目名称*/
public static final String COL_PRODUCTION_ORDER_NO = "PRODUCTION_ORDER_NO"; /* 生产订单号*/
public static final String COL_PRDT_TYPE = "PRDT_TYPE"; /* 产品类型*/
public static final String COL_PRDT_CODE = "PRDT_CODE"; /* 产品编码*/
public static final String COL_PRDT_NAME = "PRDT_NAME"; /* 产品名称*/
public static final String COL_PRDT_TYPE = "PRDT_TYPE"; /* 部件类型*/
public static final String COL_PRDT_CODE = "PRDT_CODE"; /* 部件编码*/
public static final String COL_PRDT_NAME = "PRDT_NAME"; /* 部件名称*/
public static final String COL_PLAN_COMPLETION_DATE = "PLAN_COMPLETION_DATE"; /* 计划完成日期*/
public static final String COL_NUM = "NUM"; /* 计划数量*/
public static final String COL_TOTAL_WT = "TOTAL_WT"; /* 计划重量*/
......@@ -87,9 +87,9 @@ public class HPSC005 extends DaoEPBase {
private String projCode = " "; /* 项目编码*/
private String projName = " "; /* 项目名称*/
private String productionOrderNo = " "; /* 生产订单号*/
private Integer prdtType = 0; /*产品类型*/
private String prdtCode = " "; /* 产品编码*/
private String prdtName = " "; /* 产品名称*/
private Integer prdtType = 0; /*部件类型*/
private String prdtCode = " "; /* 部件编码*/
private String prdtName = " "; /* 部件名称*/
private String planCompletionDate = " "; /* 计划完成日期*/
private BigDecimal num = new BigDecimal(0.000); /* 计划数量*/
private BigDecimal totalWt = new BigDecimal(0.000); /* 计划重量*/
......@@ -151,15 +151,15 @@ public class HPSC005 extends DaoEPBase {
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_PRDT_TYPE);
eiColumn.setDescName("产品类型");
eiColumn.setDescName("部件类型");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_PRDT_CODE);
eiColumn.setDescName("产品编码");
eiColumn.setDescName("部件编码");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_PRDT_NAME);
eiColumn.setDescName("产品名称");
eiColumn.setDescName("部件名称");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_PLAN_COMPLETION_DATE);
......@@ -428,7 +428,7 @@ public class HPSC005 extends DaoEPBase {
this.productionOrderNo = productionOrderNo;
}
/**
* get the prdtCode - 产品编码.
* get the prdtCode - 部件编码.
* @return the prdtCode
*/
public Integer getPrdtType() {
......@@ -436,15 +436,15 @@ public class HPSC005 extends DaoEPBase {
}
/**
* set the prdtCode - 产品编码.
* set the prdtCode - 部件编码.
*
* @param prdtCode - 产品编码
* @param prdtCode - 部件编码
*/
public void setPrdtType(Integer prdtType) {
this.prdtType = prdtType;
}
/**
* get the prdtCode - 产品编码.
* get the prdtCode - 部件编码.
* @return the prdtCode
*/
public String getPrdtCode() {
......@@ -452,15 +452,15 @@ public class HPSC005 extends DaoEPBase {
}
/**
* set the prdtCode - 产品编码.
* set the prdtCode - 部件编码.
*
* @param prdtCode - 产品编码
* @param prdtCode - 部件编码
*/
public void setPrdtCode(String prdtCode) {
this.prdtCode = prdtCode;
}
/**
* get the prdtName - 产品名称.
* get the prdtName - 部件名称.
* @return the prdtName
*/
public String getPrdtName() {
......@@ -468,9 +468,9 @@ public class HPSC005 extends DaoEPBase {
}
/**
* set the prdtName - 产品名称.
* set the prdtName - 部件名称.
*
* @param prdtName - 产品名称
* @param prdtName - 部件名称
*/
public void setPrdtName(String prdtName) {
this.prdtName = prdtName;
......
......@@ -134,7 +134,7 @@ public class ServiceHPSC001 extends ServiceBase {
/**
* 审核 反审.
* 提交 撤回.
*/
public EiInfo check(EiInfo eiInfo) {
HPSC001 hpsc001 = new HPSC001();
......
......@@ -241,7 +241,7 @@ public class ServiceHPSC002 extends ServiceBase {
/**
* 审核 反审.
* 提交 撤回.
*/
public EiInfo check(EiInfo eiInfo) {
HPSC002 hppz002 = new HPSC002();
......@@ -250,18 +250,18 @@ public class ServiceHPSC002 extends ServiceBase {
for (int i = 0; i < eiBlock.getRowCount(); i++) {
Map<?, ?> map = eiBlock.getRow(i);
hppz002.fromMap(map);
//限制一下,如果二级已经审核通过,这个时候不允许进行反审
//限制一下,如果二级已经提交通过,这个时候不允许进行撤回
if(map.get("status").equals("0")) {
//找到二级是否已经审核
//找到二级是否已经提交
HPSC002 THPSC002 = (HPSC002) dao.get("HPSC002.query","id",hppz002.getId());
if (THPSC002.getStatus() == 1) {
// 二级如果已经审核了则需要去看看计划是否已经更新
// 二级如果已经提交了则需要去看看计划是否已经更新
}
}
DaoUtils.update("HPSC002.check", hppz002.toMap());
}
// 处理三级审核之后判断是否都审核完成,如果都审核完成则二级直接审核通过
// 处理三级提交之后判断是否都提交完成,如果都提交完成则二级直接提交通过
for (int i = 0; i < eiBlock.getRowCount(); i++) {
Map<?, ?> map = eiBlock.getRow(i);
hppz002.fromMap(map);
......@@ -288,19 +288,19 @@ public class ServiceHPSC002 extends ServiceBase {
map3.put("projCode",THPSC002.getProjCode());
List list1 = dao.query("HPSC002.checkExamineNum1", map3);
List list2 = dao.query("HPSC002.checkExamineNum1Count", map3);
//未审核数量
//未提交数量
int num1 = NumberUtils.toint(list1.get(0));
//总量
int num2 = NumberUtils.toint(list2.get(0));
if (num1 == 0) {
//都已经审核
//都已经提交
Map map4 = new HashMap();
map4.put("projCode",THPSC002.getProjCode());
map4.put("materialStatus",2);
DaoUtils.update("HPSC001.checkByProjCode",map4);
} else if (num1 > 0 && num1 < num2) {
// 部分审批
// 部分提交
Map map4 = new HashMap();
map4.put("projCode",THPSC002.getProjCode());
map4.put("materialStatus",1);
......@@ -310,13 +310,13 @@ public class ServiceHPSC002 extends ServiceBase {
}
} catch (PlatException e) {
eiInfo.setStatus(EiConstant.STATUS_FAILURE);
eiInfo.setMsg("审核失败,原因参见详细错误描述!");
eiInfo.setMsg("提交失败,原因参见详细错误描述!");
eiInfo.setDetailMsg(e.getMessage());
logError("审核失败!", e.getMessage());
logError("提交失败!", e.getMessage());
return eiInfo;
}
eiInfo.setStatus(EiConstant.STATUS_SUCCESS);
eiInfo.setMsg("审核成功!");
eiInfo.setMsg("提交成功!");
return eiInfo;
}
......
......@@ -38,7 +38,7 @@ public class ServiceHPSC002A extends ServiceEPBase {
*/
public EiInfo initLoad(EiInfo inInfo) {
try {
// 查询物料ID所对应的项目名称和产品名称
// 查询物料ID所对应的项目名称和部件名称
Map queryMap = EiInfoUtils.getFirstRow(inInfo);
List<HPSC002> dbSc002s = dao.query("HPSC002.query", queryMap);
if (CollectionUtils.isNotEmpty(dbSc002s)) {
......
......@@ -29,7 +29,7 @@ public class ServiceHPSC002B extends ServiceEPBase {
*/
public EiInfo initLoad(EiInfo inInfo) {
try {
// 查询物料ID所对应的项目名称和产品名称
// 查询物料ID所对应的项目名称和部件名称
Map queryMap = EiInfoUtils.getFirstRow(inInfo);
List<HPSC002> dbSc002s = dao.query("HPSC002.query", queryMap);
if (CollectionUtils.isNotEmpty(dbSc002s)) {
......
......@@ -11,6 +11,7 @@ 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.ServiceBase;
import com.baosight.iplat4j.core.service.soa.XLocalManager;
import com.baosight.iplat4j.core.util.DateUtil;
import com.baosight.iplat4j.core.web.threadlocal.UserSession;
import com.baosight.iplat4j.ed.util.SequenceGenerator;
......@@ -43,9 +44,8 @@ public class ServiceHPSC003 extends ServiceBase {
HPSC003 HPSC003 = new HPSC003();
/* 调用EI查询方法.*/
EiInfo outInfo = super.query(inInfo, "HPSC003.query", new HPSC003());
EiBlock blcok = outInfo.addBlock(HPConstants.BLOCK_DETIL);
blcok.setBlockMeta(HPSC003.eiMetadata);
blcok.addRow(HPSC003);
EiBlock blcok = outInfo.addBlock(HPConstants.BLOCK_DETAIL);
blcok.setBlockMeta(new HPSC004().eiMetadata);
return outInfo;
}
......@@ -119,6 +119,12 @@ public class ServiceHPSC003 extends ServiceBase {
}
inInfo.setStatus(EiConstant.STATUS_SUCCESS);
inInfo.setMsg("修改成功!");
inInfo.set("parentId", HPSC004.getParentId());
inInfo.set(EiConstant.serviceName, "HPSC004");
inInfo.set(EiConstant.methodName, "queryDetail");
EiInfo detailInfo = XLocalManager.call(inInfo);
inInfo.getBlock("detail").setRows(detailInfo.getBlock("detail").getRows());
inInfo.getBlock(EiConstant.resultBlock).setRows(query(inInfo).getBlock(EiConstant.resultBlock).getRows());
} catch (PlatException e) {
inInfo.setStatus(EiConstant.STATUS_FAILURE);
inInfo.setMsg("操作失败!原因参见详细错误描述!");
......@@ -126,7 +132,8 @@ public class ServiceHPSC003 extends ServiceBase {
logError("修改失败", e.getMessage());
return inInfo;
}
return query(inInfo);
return inInfo;
}
/**
......@@ -170,7 +177,7 @@ public class ServiceHPSC003 extends ServiceBase {
}
/**
* 审核生产计划
* 提交生产计划
* @param eiInfo
* @return
*/
......@@ -222,13 +229,13 @@ public class ServiceHPSC003 extends ServiceBase {
}
} catch (PlatException e) {
eiInfo.setStatus(EiConstant.STATUS_FAILURE);
eiInfo.setMsg("审核失败,原因参见详细错误描述!");
eiInfo.setMsg("提交失败,原因参见详细错误描述!");
eiInfo.setDetailMsg(e.getMessage());
logError("审核失败!", e.getMessage());
logError("提交失败!", e.getMessage());
return eiInfo;
}
eiInfo.setStatus(EiConstant.STATUS_SUCCESS);
eiInfo.setMsg("审核成功!");
eiInfo.setMsg("提交成功!");
return eiInfo;
}
......
......@@ -132,7 +132,7 @@ public class ServiceHPSC004 extends ServiceBase {
}
/**
* 计划审核验证
* 计划提交验证
* @param eiInfo
* @return
*/
......
......@@ -30,7 +30,7 @@
PROJ_NAME as "projName", <!-- 项目名称 -->
PRINC1 as "princ1", <!-- 本公司项目负责人 -->
PRINC2 as "princ2", <!-- 客户项目负责人 -->
STATUS as "status", <!-- 状态 0-未审核,1-已审核 -->
STATUS as "status", <!-- 状态 0-未提交,1-已提交 -->
CREATED_BY as "createdBy", <!-- 创建人 -->
CREATED_TIME as "createdTime", <!-- 创建时间 -->
UPDATED_BY as "updatedBy", <!-- 更新人 -->
......@@ -152,7 +152,7 @@
PROJ_NAME, <!-- 项目名称 -->
PRINC1, <!-- 本公司项目负责人 -->
PRINC2, <!-- 客户项目负责人 -->
STATUS, <!-- 状态 0-未审核,1-已审核 -->
STATUS, <!-- 状态 0-未提交,1-已提交 -->
MATERIAL_STATUS,
CREATED_BY, <!-- 创建人 -->
CREATED_TIME, <!-- 创建时间 -->
......@@ -177,7 +177,7 @@
PROJ_NAME = #projName#, <!-- 项目名称 -->
PRINC1 = #princ1#, <!-- 本公司项目负责人 -->
PRINC2 = #princ2#, <!-- 客户项目负责人 -->
STATUS = #status#, <!-- 状态 0-未审核,1-已审核 -->
STATUS = #status#, <!-- 状态 0-未提交,1-已提交 -->
MATERIAL_STATUS = #materialStatus#,
CREATED_BY = #createdBy#, <!-- 创建人 -->
CREATED_TIME = #createdTime#, <!-- 创建时间 -->
......@@ -222,7 +222,7 @@
PROJ_NAME as "projName", <!-- 项目名称 -->
PRINC1 as "princ1", <!-- 本公司项目负责人 -->
PRINC2 as "princ2", <!-- 客户项目负责人 -->
STATUS as "status", <!-- 状态 0-未审核,1-已审核 -->
STATUS as "status", <!-- 状态 0-未提交,1-已提交 -->
CREATED_BY as "createdBy", <!-- 创建人 -->
CREATED_TIME as "createdTime", <!-- 创建时间 -->
UPDATED_BY as "updatedBy", <!-- 更新人 -->
......
......@@ -43,15 +43,15 @@
DEPT_CODE as "deptCode", <!-- 部门编码 预留 -->
PROJ_CODE as "projCode", <!-- 项目编码 -->
PROJ_NAME as "projName", <!-- 项目名称 -->
PARENT_ID as "parentId", <!-- 父节点-产品编码 -->
PARENT_PRDT_NAME as "parentPrdtName", <!-- 父节点-产品名称 -->
PARENT_ID as "parentId", <!-- 父节点-部件编码 -->
PARENT_PRDT_NAME as "parentPrdtName", <!-- 父节点-部件名称 -->
TYPE as "type", <!-- 类别 -->
LEAF as "leaf", <!-- 是否有叶子节点 -->
SORT as "sort", <!-- 排序字段 -->
ICON as "icon", <!-- 图片地址 -->
PRDT_TYPE as "prdtType",
PRDT_CODE as "prdtCode", <!-- 产品编码 -->
PRDT_NAME as "prdtName", <!-- 产品名称 -->
PRDT_CODE as "prdtCode", <!-- 部件编码 -->
PRDT_NAME as "prdtName", <!-- 部件名称 -->
INVENT_RECORD_ID as "inventRecordId", <!-- 存货档案ID -->
NUM as "num", <!-- 数量 -->
UNIT_WT as "unitWt", <!-- 单重 -->
......@@ -61,7 +61,7 @@
FILE_PATH3 as "filePath3", <!-- 文件地址3 -->
FILE_PATH4 as "filePath4", <!-- 文件地址4 -->
FILE_PATH5 as "filePath5", <!-- 文件地址5 -->
STATUS as "status", <!-- 状态 0-未审核,1-已审核 -->
STATUS as "status", <!-- 状态 0-未提交,1-已提交 -->
DEL_STATUS as "delStatus", <!-- 状态 1未删除,0已删除 -->
CREATED_BY as "createdBy", <!-- 创建人 -->
CREATED_TIME as "createdTime", <!-- 创建时间 -->
......@@ -239,15 +239,15 @@
DEPT_CODE, <!-- 部门编码 预留 -->
PROJ_CODE, <!-- 项目编码 -->
PROJ_NAME, <!-- 项目名称 -->
PARENT_ID, <!-- 父节点-产品编码 -->
PARENT_PRDT_NAME, <!-- 父节点-产品名称 -->
PARENT_ID, <!-- 父节点-部件编码 -->
PARENT_PRDT_NAME, <!-- 父节点-部件名称 -->
TYPE, <!-- 类别 -->
LEAF, <!-- 是否有叶子节点 -->
SORT, <!-- 排序字段 -->
ICON, <!-- 图片地址 -->
PRDT_TYPE,
PRDT_CODE, <!-- 产品编码 -->
PRDT_NAME, <!-- 产品名称 -->
PRDT_CODE, <!-- 部件编码 -->
PRDT_NAME, <!-- 部件名称 -->
INVENT_RECORD_ID, <!-- 存货档案ID -->
NUM, <!-- 数量 -->
UNIT_WT, <!-- 单重 -->
......@@ -257,7 +257,7 @@
FILE_PATH3, <!-- 文件地址3 -->
FILE_PATH4, <!-- 文件地址4 -->
FILE_PATH5, <!-- 文件地址5 -->
STATUS, <!-- 状态 0-未审核,1-已审核 -->
STATUS, <!-- 状态 0-未提交,1-已提交 -->
DEL_STATUS, <!-- 状态 1未删除,0已删除 -->
CREATED_BY, <!-- 创建人 -->
CREATED_TIME, <!-- 创建时间 -->
......@@ -289,15 +289,15 @@
DEPT_CODE = #deptCode#, <!-- 部门编码 预留 -->
PROJ_CODE = #projCode#, <!-- 项目编码 -->
PROJ_NAME = #projName#, <!-- 项目名称 -->
PARENT_ID = #parentId#, <!-- 父节点-产品编码 -->
PARENT_PRDT_NAME = #parentPrdtName#, <!-- 父节点-产品名称 -->
PARENT_ID = #parentId#, <!-- 父节点-部件编码 -->
PARENT_PRDT_NAME = #parentPrdtName#, <!-- 父节点-部件名称 -->
TYPE = #type#, <!-- 类别 -->
LEAF = #leaf#, <!-- 是否有叶子节点 -->
SORT = #sort#, <!-- 排序字段 -->
ICON = #icon#, <!-- 图片地址 -->
PRDT_CODE = #prdtCode#, <!-- 产品编码 -->
PRDT_CODE = #prdtCode#, <!-- 部件编码 -->
PRDT_TYPE = #prdtType#,
PRDT_NAME = #prdtName#, <!-- 产品名称 -->
PRDT_NAME = #prdtName#, <!-- 部件名称 -->
INVENT_RECORD_ID = #inventRecordId#, <!-- 存货档案ID -->
NUM = #num#, <!-- 数量 -->
UNIT_WT = #unitWt#, <!-- 单重 -->
......@@ -307,7 +307,7 @@
FILE_PATH3 = #filePath3#, <!-- 文件地址3 -->
FILE_PATH4 = #filePath4#, <!-- 文件地址4 -->
FILE_PATH5 = #filePath5#, <!-- 文件地址5 -->
STATUS = #status#, <!-- 状态 0-未审核,1-已审核 -->
STATUS = #status#, <!-- 状态 0-未提交,1-已提交 -->
DEL_STATUS = #delStatus#, <!-- 状态 1未删除,0已删除 -->
CREATED_BY = #createdBy#, <!-- 创建人 -->
CREATED_TIME = #createdTime#, <!-- 创建时间 -->
......@@ -331,8 +331,8 @@
PROJ_CODE as "projCode", <!-- 项目编码 -->
PRDT_name as "prdtName", <!-- 项目编码 -->
PROJ_NAME as "projName",<!-- 项目名称 -->
ID as "label", <!-- 名产品编码-->
PRDT_NAME as "text", <!-- 产品名称 -->
ID as "label", <!-- 名部件编码-->
PRDT_NAME as "text", <!-- 部件名称 -->
INVENT_RECORD_ID as "inventRecordId", <!-- 存货档案ID -->
PARENT_ID as "pId", <!-- 父节点编码 -->
TYPE as "type", <!-- 类别 -->
......@@ -361,15 +361,15 @@
DEPT_CODE as "deptCode", <!-- 部门编码 预留 -->
PROJ_CODE as "projCode", <!-- 项目编码 -->
PROJ_NAME as "projName", <!-- 项目名称 -->
PARENT_ID as "parentId", <!-- 父节点-产品编码 -->
PARENT_PRDT_NAME as "parentPrdtName", <!-- 父节点-产品名称 -->
PARENT_ID as "parentId", <!-- 父节点-部件编码 -->
PARENT_PRDT_NAME as "parentPrdtName", <!-- 父节点-部件名称 -->
TYPE as "type", <!-- 类别 -->
LEAF as "leaf", <!-- 是否有叶子节点 -->
SORT as "sort", <!-- 排序字段 -->
ICON as "icon", <!-- 图片地址 -->
PRDT_TYPE as "prdtType",
PRDT_CODE as "prdtCode", <!-- 产品编码 -->
PRDT_NAME as "prdtName", <!-- 产品名称 -->
PRDT_CODE as "prdtCode", <!-- 部件编码 -->
PRDT_NAME as "prdtName", <!-- 部件名称 -->
INVENT_RECORD_ID as "inventRecordId", <!-- 存货档案ID -->
NUM as "num", <!-- 数量 -->
UNIT_WT as "unitWt", <!-- 单重 -->
......@@ -379,7 +379,7 @@
FILE_PATH3 as "filePath3", <!-- 文件地址3 -->
FILE_PATH4 as "filePath4", <!-- 文件地址4 -->
FILE_PATH5 as "filePath5", <!-- 文件地址5 -->
STATUS as "status", <!-- 状态 0-未审核,1-已审核 -->
STATUS as "status", <!-- 状态 0-未提交,1-已提交 -->
DEL_STATUS as "delStatus", <!-- 状态 1未删除,0已删除 -->
CREATED_BY as "createdBy", <!-- 创建人 -->
CREATED_TIME as "createdTime", <!-- 创建时间 -->
......@@ -410,15 +410,15 @@
DEPT_CODE as "deptCode", <!-- 部门编码 预留 -->
PROJ_CODE as "projCode", <!-- 项目编码 -->
PROJ_NAME as "projName", <!-- 项目名称 -->
PARENT_ID as "parentId", <!-- 父节点-产品编码 -->
PARENT_PRDT_NAME as "parentPrdtName", <!-- 父节点-产品名称 -->
PARENT_ID as "parentId", <!-- 父节点-部件编码 -->
PARENT_PRDT_NAME as "parentPrdtName", <!-- 父节点-部件名称 -->
TYPE as "type", <!-- 类别 -->
LEAF as "leaf", <!-- 是否有叶子节点 -->
SORT as "sort", <!-- 排序字段 -->
ICON as "icon", <!-- 图片地址 -->
PRDT_TYPE as "prdtType",
PRDT_CODE as "prdtCode", <!-- 产品编码 -->
PRDT_NAME as "prdtName", <!-- 产品名称 -->
PRDT_CODE as "prdtCode", <!-- 部件编码 -->
PRDT_NAME as "prdtName", <!-- 部件名称 -->
INVENT_RECORD_ID as "inventRecordId", <!-- 存货档案ID -->
NUM as "num", <!-- 数量 -->
UNIT_WT as "unitWt", <!-- 单重 -->
......@@ -428,7 +428,7 @@
FILE_PATH3 as "filePath3", <!-- 文件地址3 -->
FILE_PATH4 as "filePath4", <!-- 文件地址4 -->
FILE_PATH5 as "filePath5", <!-- 文件地址5 -->
STATUS as "status", <!-- 状态 0-未审核,1-已审核 -->
STATUS as "status", <!-- 状态 0-未提交,1-已提交 -->
DEL_STATUS as "delStatus", <!-- 状态 1未删除,0已删除 -->
CREATED_BY as "createdBy", <!-- 创建人 -->
CREATED_TIME as "createdTime", <!-- 创建时间 -->
......
......@@ -119,8 +119,8 @@
PRODUCTION_ORDER_NO as "productionOrderNo", <!-- 生产订单号 -->
INVENT_RECORD_ID as "inventRecordId",
PRDT_TYPE as "prdtType",
PRDT_CODE as "prdtCode", <!-- 产品编码 -->
PRDT_NAME as "prdtName", <!-- 产品名称 -->
PRDT_CODE as "prdtCode", <!-- 部件编码 -->
PRDT_NAME as "prdtName", <!-- 部件名称 -->
PLAN_COMPLETION_DATE as "planCompletionDate", <!-- 计划完成日期 -->
NUM as "num", <!-- 计划数量 -->
TOTAL_WT as "totalWt", <!-- 计划重量 -->
......@@ -236,8 +236,8 @@
PRODUCTION_ORDER_NO, <!-- 生产订单号 -->
INVENT_RECORD_ID,
PRDT_TYPE,
PRDT_CODE, <!-- 产品编码 -->
PRDT_NAME, <!-- 产品名称 -->
PRDT_CODE, <!-- 部件编码 -->
PRDT_NAME, <!-- 部件名称 -->
PLAN_COMPLETION_DATE, <!-- 计划完成日期 -->
NUM, <!-- 计划数量 -->
TOTAL_WT, <!-- 计划重量 -->
......@@ -288,8 +288,8 @@
PROJ_NAME = #projName#, <!-- 项目名称 -->
PRODUCTION_ORDER_NO = #productionOrderNo#, <!-- 生产订单号 -->
PRDT_TYPE = #prdtType#,
PRDT_CODE = #prdtCode#, <!-- 产品编码 -->
PRDT_NAME = #prdtName#, <!-- 产品名称 -->
PRDT_CODE = #prdtCode#, <!-- 部件编码 -->
PRDT_NAME = #prdtName#, <!-- 部件名称 -->
PLAN_COMPLETION_DATE = #planCompletionDate#, <!-- 计划完成日期 -->
NUM = #num#, <!-- 计划数量 -->
TOTAL_WT = #totalWt#, <!-- 计划重量 -->
......
......@@ -30,7 +30,7 @@
PROJ_NAME as "projName", <!-- 项目名称 -->
PRINC1 as "princ1", <!-- 本公司项目负责人 -->
PRINC2 as "princ2", <!-- 客户项目负责人 -->
STATUS as "status", <!-- 状态 0-未审核,1-已审核 -->
STATUS as "status", <!-- 状态 0-未提交,1-已提交 -->
CREATED_BY as "createdBy", <!-- 创建人 -->
CREATED_TIME as "createdTime", <!-- 创建时间 -->
UPDATED_BY as "updatedBy", <!-- 更新人 -->
......@@ -149,7 +149,7 @@
PROJ_NAME, <!-- 项目名称 -->
PRINC1, <!-- 本公司项目负责人 -->
PRINC2, <!-- 客户项目负责人 -->
STATUS, <!-- 状态 0-未审核,1-已审核 -->
STATUS, <!-- 状态 0-未提交,1-已提交 -->
CREATED_BY, <!-- 创建人 -->
CREATED_TIME, <!-- 创建时间 -->
UPDATED_BY, <!-- 更新人 -->
......@@ -173,7 +173,7 @@
PROJ_NAME = #projName#, <!-- 项目名称 -->
PRINC1 = #princ1#, <!-- 本公司项目负责人 -->
PRINC2 = #princ2#, <!-- 客户项目负责人 -->
STATUS = #status#, <!-- 状态 0-未审核,1-已审核 -->
STATUS = #status#, <!-- 状态 0-未提交,1-已提交 -->
CREATED_BY = #createdBy#, <!-- 创建人 -->
CREATED_TIME = #createdTime#, <!-- 创建时间 -->
UPDATED_BY = #updatedBy#, <!-- 更新人 -->
......
......@@ -25,7 +25,7 @@ public class HPZL001 extends DaoEPBase {
private String unit = " "; /* 生产组*/
private String notes = " "; /* 质量问题描述*/
private String princ = " "; /* 检查人*/
private int status; /* 单据状态 0待审核 1已审核*/
private int status; /* 单据状态 0待提交 1已提交*/
private String affix = " "; /* 附件*/
private String createdBy = " "; /* 创建人*/
private String createdTime = " "; /* 创建时间*/
......@@ -76,7 +76,7 @@ EiColumn eiColumn;
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn("status");
eiColumn.setDescName("单据状态 0待审核 1已审核");
eiColumn.setDescName("单据状态 0待提交 1已提交");
eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn("affix");
......@@ -239,7 +239,7 @@ initMetaData();
this.princ = princ;
}
/**
* get the status - 单据状态 0待审核 1已审核
* get the status - 单据状态 0待提交 1已提交
* @return the status
*/
public int getStatus() {
......@@ -247,7 +247,7 @@ initMetaData();
}
/**
* set the status - 单据状态 0待审核 1已审核
* set the status - 单据状态 0待提交 1已提交
*/
public void setStatus(int status) {
this.status = status;
......
......@@ -140,7 +140,7 @@ public class ServiceHPZL001 extends ServiceBase {
}
/**
* 审核操作
* 提交操作
*
* @param inInfo
* @return
......@@ -156,15 +156,15 @@ public class ServiceHPZL001 extends ServiceBase {
}
inInfo = this.query(inInfo);
inInfo.setStatus(EiConstant.STATUS_DEFAULT);
inInfo.setMsg("操作成功!本次对[" + resultRows.size() + "]条数据审核成功!");
inInfo.setMsg("操作成功!本次对[" + resultRows.size() + "]条数据提交成功!");
} catch (Exception e) {
LogUtils.setDetailMsg(inInfo, e, "审核失败");
LogUtils.setDetailMsg(inInfo, e, "提交失败");
}
return inInfo;
}
/**
* 反审操作
* 撤回操作
*
* @param inInfo
* @return
......@@ -180,9 +180,9 @@ public class ServiceHPZL001 extends ServiceBase {
}
inInfo = this.query(inInfo);
inInfo.setStatus(EiConstant.STATUS_DEFAULT);
inInfo.setMsg("操作成功!本次对[" + resultRows.size() + "]条数据反审成功!");
inInfo.setMsg("操作成功!本次对[" + resultRows.size() + "]条数据撤回成功!");
} catch (Exception e) {
LogUtils.setDetailMsg(inInfo, e, "审核失败");
LogUtils.setDetailMsg(inInfo, e, "提交失败");
}
return inInfo;
}
......
......@@ -13,7 +13,7 @@
UNIT as "unit", <!-- 生产组 -->
NOTES as "notes", <!-- 质量问题描述 -->
PRINC as "princ", <!-- 检查人 -->
STATUS as "status", <!-- 单据状态 0待审核 1已审核 -->
STATUS as "status", <!-- 单据状态 0待提交 1已提交 -->
AFFIX as "affix", <!-- 附件 -->
CREATED_BY as "createdBy", <!-- 创建人 -->
CREATED_TIME as "createdTime", <!-- 创建时间 -->
......@@ -63,7 +63,7 @@
UNIT, <!-- 生产组 -->
NOTES, <!-- 质量问题描述 -->
PRINC, <!-- 检查人 -->
STATUS, <!-- 单据状态 0待审核 1已审核 -->
STATUS, <!-- 单据状态 0待提交 1已提交 -->
AFFIX, <!-- 附件 -->
CREATED_BY, <!-- 创建人 -->
CREATED_TIME <!-- 创建时间 -->
......@@ -87,18 +87,18 @@
UNIT = #unit#, <!-- 生产组 -->
NOTES = #notes#, <!-- 质量问题描述 -->
PRINC = #princ#, <!-- 检查人 -->
STATUS = #status#, <!-- 单据状态 0待审核 1已审核 -->
STATUS = #status#, <!-- 单据状态 0待提交 1已提交 -->
AFFIX = #affix#, <!-- 附件 -->
UPDATED_BY = #updatedBy#, <!-- 更新人 -->
UPDATED_TIME = #updatedTime# <!-- 更新时间 -->
WHERE ID = #id#
</update>
<!-- 审核操作 -->
<!-- 提交操作 -->
<update id="operator">
UPDATE hpjx.t_hpzl001
SET
STATUS = #status#, <!-- 单据状态 0待审核 1已审核 -->
STATUS = #status#, <!-- 单据状态 0待提交 1已提交 -->
UPDATED_BY = #updatedBy#, <!-- 更新人 -->
UPDATED_TIME = #updatedTime# <!-- 更新时间 -->
WHERE ID = #id#
......
......@@ -19,11 +19,11 @@ $(function () {
let template = '';
if (auditStatus == 0) {
template += '<a style="cursor: pointer;display: inline-flex;justify-content: center;" ' +
'onclick="check(' + item.id + ',1)" >审核</a>';
'onclick="check(' + item.id + ',1)" >提交</a>';
}
// else if (auditStatus == 1) {
// template += '<a style="cursor: pointer;display: inline-flex;justify-content: center;" ' +
// 'onclick="check(' + item.id + ',0)" >反审</a>';
// 'onclick="check(' + item.id + ',0)" >撤回</a>';
// }
return template;
}
......
......@@ -20,8 +20,8 @@
<EF:EFInput ename="inqu_status-0-projCode" cname="项目编码" colWidth="3"/>
<EF:EFInput ename="inqu_status-0-projName" cname="项目名称" colWidth="3"/>
<EF:EFSelect cname="单据状态" optionLabel="全部" ename="inqu_status-0-status" colWidth="3">
<EF:EFOption label="未审核" value="0"/>
<EF:EFOption label="已审核" value="1"/>
<EF:EFOption label="未提交" value="0"/>
<EF:EFOption label="已提交" value="1"/>
</EF:EFSelect>
<EF:EFSelect cname="项目负责人" ename="inqu_status-0-princ1" colWidth="3" filter="contains" defultValue="">
<EF:EFOption label="全部" value=""/>
......@@ -55,8 +55,8 @@
filter="contains">
</EF:EFComboColumn>
<EF:EFComboColumn enable="false" align="center" ename="status" cname="状态" readonly="true">
<EF:EFOption label="未审核" value="0"/>
<EF:EFOption label="已审核" value="1"/>
<EF:EFOption label="未提交" value="0"/>
<EF:EFOption label="已提交" value="1"/>
</EF:EFComboColumn>
<EF:EFColumn ename="remark" cname="备注" readonly="true"/>
<EF:EFColumn ename="operator" cname="操作" width="100" enable="false" readonly="false"/>
......
......@@ -40,6 +40,17 @@ $(function () {
*/
select: function (e) {
var nodeData = this.dataItem(e.node);
let eiInfo = new EiInfo();
eiInfo.set("inqu_status-0-inventTypes", [3, 4]);
var dataSource;
EiCommunicator.send("HPPZ006", "queryPrdtComboBox", eiInfo, {
onSuccess: function (ei) {
dataSource = ei.getBlock("invent_prdt_name_block_id").getMappedRows();
inventNameGlobalData = dataSource;
},
onFail: function (ei) {
}
}, {async: false});
IPLATUI.EFTree.materialTree.selectTreeNode.nodeId = nodeData.nodeId;
IPLATUI.EFTree.materialTree.selectTreeNode.prdtCode = nodeData.prdtCode;
IPLATUI.EFTree.materialTree.selectTreeNode.projCode = nodeData.projCode;
......@@ -199,10 +210,10 @@ $(function () {
if (lv === '3') {
if (auditStatus == 0) {
template += '<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" ' +
'onclick="check(' + item.id + ',1)" >审核</a>';
'onclick="check(' + item.id + ',1)" >提交</a>';
} else {
template += '<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" ' +
'onclick="check(' + item.id + ',0)" >反审</a>';
'onclick="check(' + item.id + ',0)" >撤回</a>';
}
}
return template;
......@@ -215,6 +226,14 @@ $(function () {
eiInfo.set("inqu_status-0-inventType", options.model["prdtType"]);
return eiInfo;
}
}, {
field: "parentPrdtName",
template: function (dataItem) {
if(dataItem.lv > 2){
return dataItem['parentPrdtName'];
}
return "";
}
}
// {
// field: "inventRecordId",
......@@ -303,7 +322,7 @@ $(function () {
}
};
//产品类型下拉联动
//部件类型下拉联动
$('input[name="inqu_status-0-prdtType"]').change(function () {
var inInfo=new EiInfo();
var prdtType=$("#inqu_status-0-prdtType").val();
......
......@@ -10,18 +10,18 @@
<EF:EFPage title="物料清单">
<EF:EFRegion id="inqu" title="查询条件">
<div class="row">
<EF:EFSelect ename="inqu_status-0-prdtType" cname="产品类型" colWidth="3" filter="contains"
<EF:EFSelect ename="inqu_status-0-prdtType" cname="部件类型" colWidth="3" filter="contains"
template="#=textField#" valueTemplate="#=textField#">
<EF:EFOption label="全部" value=""/>
<EF:EFCodeOption codeName="hpjx.hpkc.inventType" condition="ITEM_CODE IN ('3','4')"/>
</EF:EFSelect>
<EF:EFSelect cname="产品名称" ename="inqu_status-0-prdtCode" filter="contains" defultValue="">
<EF:EFSelect cname="部件名称" ename="inqu_status-0-prdtCode" filter="contains" defultValue="">
<EF:EFOption label="全部" value=""/>
<EF:EFOptions blockId="invent_name_block_id" textField="textField" valueField="valueField"/>
</EF:EFSelect>
<EF:EFSelect cname="状态" optionLabel="全部" ename="inqu_status-0-status" colWidth="3">
<EF:EFOption label="未审核" value="0"/>
<EF:EFOption label="已审核" value="1"/>
<EF:EFOption label="未提交" value="0"/>
<EF:EFOption label="已提交" value="1"/>
</EF:EFSelect>
</div>
<%-- <EF:EFButton ename="QUERY" cname="查询" row="1" class="btn-align-right"></EF:EFButton>--%>
......@@ -46,32 +46,32 @@
<EF:EFColumn ename="level" cname="层级" hidden="true"/>
<EF:EFColumn enable="false" ename="projCode" cname="项目编码"/>
<EF:EFColumn enable="false" ename="projName" cname="项目名称"/>
<EF:EFComboColumn cname="产品类型" ename="prdtType" width="90" align="center" required="true">
<EF:EFComboColumn cname="部件类型" ename="prdtType" width="90" align="center" required="true">
<EF:EFCodeOption codeName="hpjx.hpkc.inventType" condition="ITEM_CODE IN ('3','4')"/>
</EF:EFComboColumn>
<EF:EFPopupColumn ename="prdtName" cname="产品名称" width="200" popupType="ServiceGrid"
popupTitle="产品信息" serviceName="HPPZ006" methodName="queryPrdtComboBox" resultId="invent_prdt_name_block_id"
<EF:EFPopupColumn ename="prdtName" cname="部件名称" width="200" popupType="ServiceGrid"
popupTitle="部件信息" serviceName="HPPZ006" methodName="queryPrdtComboBox" resultId="invent_prdt_name_block_id"
columnEnames="param1Field,textField"
columnCnames="产品名称,产品编码"
columnCnames="部件名称,部件编码"
backFillColumnIds="param1Field,textField"
backFillFieldIds="prdtName,prdtCode"
valueField="param1Field" textField="param1Field"/>
<EF:EFColumn ename="prdtCode" cname="产品编码"/>
<EF:EFColumn ename="prdtCode" cname="部件编码"/>
<EF:EFColumn ename="length" cname="长" format="{0:N3}"/>
<EF:EFColumn ename="width" cname="宽" format="{0:N3}"/>
<EF:EFColumn ename="thick" cname="厚" format="{0:N3}"/>
<EF:EFColumn ename="remark" cname="备注" />
<EF:EFColumn enable="false" ename="parentId" hidden="true" cname="上级产品名称"/>
<EF:EFColumn enable="false" ename="parentPrdtName" cname="上级产品名称"/>
<EF:EFColumn ename="num" cname="数量"/>
<EF:EFColumn ename="unitWt" format="{0:N3}" cname="单重"/>
<EF:EFColumn enable="false" ename="parentId" hidden="true" cname="上级部件名称"/>
<EF:EFColumn enable="false" ename="parentPrdtName" cname="上级部件名称"/>
<EF:EFColumn ename="num" required="true" cname="数量"/>
<EF:EFColumn ename="unitWt" required="true" format="{0:N3}" cname="单重"/>
<EF:EFColumn enable="false" format="{0:N3}" ename="totalWt" cname="总重"/>
<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>
valueField="valueField" cname="提交状态">
<EF:EFOption label="未提交" value="0"></EF:EFOption>
<EF:EFOption label="已提交" value="1"></EF:EFOption>
</EF:EFComboColumn>
<EF:EFColumn ename="operator" cname="操作" width="200" enable="false" readonly="false"/>
</EF:EFGrid>
......
......@@ -10,7 +10,7 @@
<EF:EFInput cname="物料ID" ename="matId" blockId="inqu_status" row="0" type="hidden"/>
<div class="row">
<EF:EFInput cname="项目名称" ename="projName" blockId="inqu_status" row="0" colWidth="3" readonly="true"/>
<EF:EFInput cname="产品名称" ename="prdtName" blockId="inqu_status" row="0" colWidth="3" readonly="true"/>
<EF:EFInput cname="部件名称" ename="prdtName" blockId="inqu_status" row="0" colWidth="3" readonly="true"/>
<EF:EFDateSpan startCname="创建日期(从)" endCname="至" blockId="inqu_status"
startName="createdDateFrom" endName="createdDateTo" row="0" role="date"
format="yyyy-MM-dd" ratio="3:3" satrtRatio="4:8" endRatio="4:8" readonly="true">
......
......@@ -10,7 +10,7 @@
<EF:EFInput cname="物料ID" ename="matId" blockId="inqu_status" row="0" type="hidden"/>
<div class="row">
<EF:EFInput cname="项目名称" ename="projName" blockId="inqu_status" row="0" colWidth="3" readonly="true"/>
<EF:EFInput cname="产品名称" ename="prdtName" blockId="inqu_status" row="0" colWidth="3" readonly="true"/>
<EF:EFInput cname="部件名称" ename="prdtName" blockId="inqu_status" row="0" colWidth="3" readonly="true"/>
<EF:EFInput cname="文件名称" ename="docName" blockId="inqu_status" row="0" colWidth="3" readonly="true"/>
<EF:EFDateSpan startCname="创建日期(从)" endCname="至" blockId="inqu_status"
startName="createdDateFrom" endName="createdDateTo" row="0" role="date"
......
......@@ -21,11 +21,11 @@ $(function () {
let template = '';
if (auditStatus == 0) {
template += '<a style="cursor: pointer;display: inline-flex;justify-content: center;" ' +
'onclick="check(' + item.id + ',1)" >审核</a>';
'onclick="check(' + item.id + ',1)" >提交</a>';
}
else {
template += '<a hidden="hidden" style="cursor: pointer;display: inline-flex;justify-content: center;" ' +
'onclick="check(' + item.id + ',0)" >反审</a>';
'onclick="check(' + item.id + ',0)" >撤回</a>';
}
return template;
}
......@@ -84,7 +84,6 @@ $(function () {
var btnNode = $(this);
//禁用按钮
btnNode.attr("disabled", true);
IPLAT.submitNode($("#HPSC003"), "HPSC003", "updateHPSC0004", {
onSuccess: function (ei) {
if (ei["status"] == -1) {
......@@ -128,7 +127,7 @@ $(function () {
}
//产品类型下拉联动
//部件类型下拉联动
$('input[name="inqu_status-0-prdtType"]').change(function () {
var inInfo=new EiInfo();
var prdtType=$("#inqu_status-0-prdtType").val();
......@@ -167,11 +166,11 @@ function check(id, auditStatus) {
onSuccess(ei) {
var model=ei.get("model");
if(!model.planCompletionDate) {
NotificationUtil("审核失败!原因:基本信息中计划完成日期未填写", "error");
NotificationUtil("提交失败!原因:基本信息中计划完成日期未填写", "error");
return;
} else {
//审核
//审核前先判断明细信息中的计划开始和计划结束时间是否都已经填写,只有填写了之后才能进行审核
//提交
//提交前先判断明细信息中的计划开始和计划结束时间是否都已经填写,只有填写了之后才能进行提交
if (auditStatus == 1) {
EiCommunicator.send('HPSC004', 'inspectDetail', inEiInfo, {
onSuccess(ei) {
......@@ -179,7 +178,7 @@ function check(id, auditStatus) {
if(list) {
var count = list[0];
if (count > 0) {
NotificationUtil("审核失败!原因:明细信息中有未填写的计划开始时间或计划结束时间", "error");
NotificationUtil("提交失败!原因:明细信息中有未填写的计划开始时间或计划结束时间", "error");
} else {
EiCommunicator.send('HPSC004','queryDetail',inEiInfo,{
onSuccess(ei){
......@@ -189,7 +188,7 @@ function check(id, auditStatus) {
NotificationUtil("计划结束时间应该大于计划开始时间!", "error");
}
else {
// 审核通过,生成
// 提交通过,生成
EiCommunicator.send('HPSC003', 'checkHPSC0003', inEiInfo, {
onSuccess(response) {
NotificationUtil(response.msg);
......@@ -211,7 +210,7 @@ function check(id, auditStatus) {
}
} else {
NotificationUtil("审核失败!未找到明细信息", "error");
NotificationUtil("提交失败!未找到明细信息", "error");
}
},
onFail(errorMessage, status, e) {
......@@ -223,7 +222,7 @@ function check(id, auditStatus) {
}
);
} else {
// 反审
// 撤回
}
}
......
......@@ -14,12 +14,12 @@
<div class="row" > <%-- blockId="inqu_status" --%>
<EF:EFInput blockId="inqu_status" ename="projCode" colWidth="3" cname="项目编号:" />
<EF:EFInput blockId="inqu_status" ename="projName" colWidth="3" cname="项目名称:" />
<EF:EFSelect ename="inqu_status-0-prdtType" cname="产品类型" colWidth="3" filter="contains"
<EF:EFSelect ename="inqu_status-0-prdtType" cname="部件类型" colWidth="3" filter="contains"
template="#=textField#" valueTemplate="#=textField#">
<EF:EFOption label="全部" value=""/>
<EF:EFCodeOption codeName="hpjx.hpkc.inventType" condition="ITEM_CODE IN ('3','4')"/>
</EF:EFSelect>
<EF:EFSelect ename="inqu_status-0-prdtCode" cname="产品名称" filter="contains" required="false" colWidth="3"
<EF:EFSelect ename="inqu_status-0-prdtCode" cname="部件名称" filter="contains" required="false" colWidth="3"
template="#=textField#" valueTemplate="#=valueField#" defaultValue="请选择">
<EF:EFOption label="请选择" value=""/>
<EF:EFOptions blockId="invent_name_block_id" textField="textField" valueField="valueField"/>
......@@ -28,8 +28,8 @@
<EF:EFDatePicker blockId="inqu_status" ename="planCompletionDate" colWidth="3" cname="计划完成日期:"
format="yyyy-MM-dd"/>
<EF:EFSelect cname="状态:" optionLabel="全部" blockId="inqu_status" colWidth="3" ename="status" >
<EF:EFOption label="未审核" value="0"/>
<EF:EFOption label="已审核" value="1"/>
<EF:EFOption label="未提交" value="0"/>
<EF:EFOption label="已提交" value="1"/>
</EF:EFSelect>
</div>
<%-- <EF:EFButton ename="QUERY" cname="查询" row="1" class="btn-align-right"></EF:EFButton>--%>
......@@ -52,8 +52,8 @@
required='true' readonly="true"/>
<EF:EFColumn enable="false" ename="schedule" cname="生产完工进度" format="{0:N2}" readonly="true"/>
<EF:EFComboColumn enable="false" ename="status" cname="状态">
<EF:EFOption label="未审核" value="0"/>
<EF:EFOption label="已审核" value="1"/>
<EF:EFOption label="未提交" value="0"/>
<EF:EFOption label="已提交" value="1"/>
</EF:EFComboColumn>
<EF:EFColumn ename="operator" cname="操作" width="100" enable="false" readonly="false"/>
</EF:EFGrid>
......@@ -63,6 +63,8 @@
<EF:EFRegion id="detail" title="明细信息">
<EF:EFGrid blockId="detail" autoDraw="no">
<EF:EFColumn ename="id" cname="主键" hidden="true"/>
<EF:EFColumn ename="parentId" cname="父ID" hidden="true"/>
<EF:EFComboColumn ename="prdtType" cname="零部件类型" width="90" align="center" readonly="true">
<EF:EFComboColumn ename="prdtType" cname="零件类型" width="90" align="center" readonly="true">
<EF:EFCodeOption codeName="hpjx.hpkc.inventType" />
</EF:EFComboColumn>
......
......@@ -11,7 +11,7 @@
<head>
<%-- <link rel="stylesheet" href="${ctx}/css/simulatedOperation.css"/>--%>
</head>
<EF:EFPage title="生产订单">
<EF:EFPage title="生产任务">
<EF:EFRegion id="inqu" title="查询条件"><%-- type="query" efRegionShowClear="true" efRegionSave="true"--%>
......
......@@ -23,10 +23,10 @@
</EF:EFSelect>
<EF:EFInput ename="inqu_status-0-projCode" cname="项目编码" colWidth="3"/>
<EF:EFInput ename="inqu_status-0-projName" cname="项目名称" colWidth="3"/>
<EF:EFSelect cname="物料审核状态" optionLabel="全部" ename="inqu_status-0-materialStatus" colWidth="3">
<EF:EFOption label="未审核" value="0"/>
<EF:EFOption label="部分审核" value="1"/>
<EF:EFOption label="全部审核" value="2"/>
<EF:EFSelect cname="物料提交状态" optionLabel="全部" ename="inqu_status-0-materialStatus" colWidth="3">
<EF:EFOption label="未提交" value="0"/>
<EF:EFOption label="部分提交" value="1"/>
<EF:EFOption label="全部提交" value="2"/>
</EF:EFSelect>
<EF:EFSelect cname="项目负责人" ename="inqu_status-0-princ1" colWidth="3" filter="contains" defultValue="">
<EF:EFOption label="全部" value=""/>
......@@ -59,10 +59,10 @@
columnTemplate="#=textField#" itemTemplate="#=textField#" readonly="true"
filter="contains">
</EF:EFComboColumn>
<EF:EFComboColumn required="true" align="center" ename="materialStatus" cname="物料审核状态" defaultValue="0">
<EF:EFOption label="未审核" value="0"/>
<EF:EFOption label="部分审核" value="1"/>
<EF:EFOption label="全部审核" value="2"/>
<EF:EFComboColumn required="true" align="center" ename="materialStatus" cname="物料提交状态" defaultValue="0">
<EF:EFOption label="未提交" value="0"/>
<EF:EFOption label="部分提交" value="1"/>
<EF:EFOption label="全部提交" value="2"/>
</EF:EFComboColumn>
<EF:EFColumn enable="false" ename="remark" cname="备注"/>
......
......@@ -33,10 +33,10 @@ $(function() {
let auditStatus = item.status;
if (auditStatus == 0) {
return '<a style="cursor: pointer;display: flex;justify-content: center;" ' +
'onclick="audit(' + item.id + ',\'' + chkBillno + '\')" >审核</a>';
'onclick="audit(' + item.id + ',\'' + chkBillno + '\')" >提交</a>';
} else {
return '<a style="cursor: pointer;display: flex;justify-content: center;" ' +
'onclick="unAudit(' + item.id + ',\'' + chkBillno + '\')" >反审</a>';
'onclick="unAudit(' + item.id + ',\'' + chkBillno + '\')" >撤回</a>';
}
}
}]
......@@ -76,14 +76,14 @@ function openUploadFile(id) {
}
/**
* 审核操作
* 提交操作
*
* @param id
* @param chkBillno
* @param auditStatus
*/
function audit(id, chkBillNo) {
let message = "确认对单号[" + chkBillNo + "]进行审核操作吗? ";
let message = "确认对单号[" + chkBillNo + "]进行提交操作吗? ";
JSUtils.confirm(message, {
ok: function () {
JSUtils.submitGridsData("result", "HPZL001", "audit", true);
......@@ -92,14 +92,14 @@ function audit(id, chkBillNo) {
}
/**
* 反审操作
* 撤回操作
*
* @param id
* @param chkBillno
* @param auditStatus
*/
function unAudit(id, chkBillNo) {
let message = "确认对单号[" + chkBillNo + "]进行反审操作吗? ";
let message = "确认对单号[" + chkBillNo + "]进行撤回操作吗? ";
JSUtils.confirm(message, {
ok: function () {
JSUtils.submitGridsData("result", "HPZL001", "unAudit", true);
......
......@@ -20,8 +20,8 @@
<EF:EFInput ename="inqu_status-0-princ" cname="检查人" colWidth="3" readonly="false"/>
<EF:EFSelect ename="inqu_status-0-status" cname="处理状态" colWidth="3">
<EF:EFOption label="--请选择--" value=""/>
<EF:EFOption label="审核" value="1"></EF:EFOption>
<EF:EFOption label="待审核" value="0"></EF:EFOption>
<EF:EFOption label="提交" value="1"></EF:EFOption>
<EF:EFOption label="待提交" value="0"></EF:EFOption>
</EF:EFSelect>
</div>
</EF:EFRegion>
......@@ -43,8 +43,8 @@
<EF:EFComboColumn ename="status" cname="状态" enable="false" align="center" textField="textField"
valueField="valueField" width="100" optionLabel=" ">
<EF:EFOption label="--请选择--" value=""></EF:EFOption>
<EF:EFOption label="审核" value="1"></EF:EFOption>
<EF:EFOption label="未审核" value="0"></EF:EFOption>
<EF:EFOption label="提交" value="1"></EF:EFOption>
<EF:EFOption label="未提交" value="0"></EF:EFOption>
</EF:EFComboColumn>
<EF:EFColumn ename="affix" cname="附件" enable="false" width="100" align="center"/>
<EF:EFColumn ename="operator" cname="操作" enable="false" width="100" readonly="false"/>
......
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