Commit 75526473 by liuyang

Merge branch 'dev' of http://git.pseer.com:8800/platform/hg-smart into dev-ly

parents b76223c9 43c680d9
package com.baosight.hggp.aspect.annotation; package com.baosight.hggp.aspect.annotation;
import com.baosight.hggp.aspect.domain.TCPReceive; import com.baosight.hggp.aspect.domain.TCPReceive;
import com.baosight.hggp.controller.DocController;
import com.baosight.iplat4j.core.web.controller.WebDispatchController; import com.baosight.iplat4j.core.web.controller.WebDispatchController;
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
......
package com.baosight.hggp.aspect.annotation; package com.baosight.hggp.controller;
import com.alibaba.fastjson.JSONObject;
import com.baosight.hggp.core.enums.DocRouteEnum;
import com.baosight.hggp.util.DocExcelUtils; import com.baosight.hggp.util.DocExcelUtils;
import com.baosight.hggp.util.LogUtils; import com.baosight.hggp.util.LogUtils;
import com.baosight.hggp.util.MapUtils;
import com.baosight.iplat4j.core.ei.EiConstant; import com.baosight.iplat4j.core.ei.EiConstant;
import com.baosight.iplat4j.core.ei.EiInfo; import com.baosight.iplat4j.core.ei.EiInfo;
import com.baosight.iplat4j.core.exception.PlatException;
import com.baosight.iplat4j.core.service.soa.XLocalManager; import com.baosight.iplat4j.core.service.soa.XLocalManager;
import com.baosight.iplat4j.core.web.controller.WebDispatchController; import com.baosight.iplat4j.core.web.controller.WebDispatchController;
import org.apache.commons.collections.CollectionUtils; import org.apache.commons.collections.CollectionUtils;
import org.apache.commons.lang.math.NumberUtils; import org.apache.commons.collections.MapUtils;
import org.apache.commons.lang.StringUtils;
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
import org.springframework.web.bind.annotation.CrossOrigin; import org.springframework.web.bind.annotation.CrossOrigin;
...@@ -20,10 +21,11 @@ import org.springframework.web.bind.annotation.RestController; ...@@ -20,10 +21,11 @@ import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.multipart.MultipartFile; import org.springframework.web.multipart.MultipartFile;
import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletRequest;
import java.net.URLDecoder;
import java.util.HashMap; import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
import com.baosight.hggp.common.DocRouteEnum;
/** /**
* DOC 接口类 * DOC 接口类
* *
...@@ -35,7 +37,7 @@ import com.baosight.hggp.common.DocRouteEnum; ...@@ -35,7 +37,7 @@ import com.baosight.hggp.common.DocRouteEnum;
@RequestMapping("/doc") @RequestMapping("/doc")
public class DocController extends WebDispatchController { public class DocController extends WebDispatchController {
private final static Logger logger = LoggerFactory.getLogger(DocController.class); private final static Logger log = LoggerFactory.getLogger(DocController.class);
/** /**
* 批量导入 * 批量导入
...@@ -53,29 +55,28 @@ public class DocController extends WebDispatchController { ...@@ -53,29 +55,28 @@ public class DocController extends WebDispatchController {
outInfo.setMsg("导入文件不能为空"); outInfo.setMsg("导入文件不能为空");
return outInfo; return outInfo;
} }
Map<String, String> params = this.convertParam(paramMaps); Map<String, Object> params = this.convertParam(paramMaps);
String id = request.getParameter("id"); String id = request.getParameter("id");
DocRouteEnum docRouteEnum = DocRouteEnum.getById(id); DocRouteEnum docRouteEnum = DocRouteEnum.getById(id);
if (params.get("fileName").contains("HGSC004A")){ if (MapUtils.getString(params, "fileName").contains("HGSC004A")) {
docRouteEnum = DocRouteEnum.getById("route_001"); docRouteEnum = DocRouteEnum.getById("route_001");
}else if (params.get("fileName").contains("HGSC009A")){ } else if (params.get("fileName").toString().contains("HGSC009A")) {
docRouteEnum = DocRouteEnum.getById("route_002"); docRouteEnum = DocRouteEnum.getById("route_002");
}else if (params.get("fileName").contains("HGPZ005")){ } else if (params.get("fileName").toString().contains("HGPZ005")) {
docRouteEnum = DocRouteEnum.getById("route_003"); docRouteEnum = DocRouteEnum.getById("route_003");
} }
if (docRouteEnum == null) { if (docRouteEnum == null) {
outInfo.setMsg("导入标识ID不存在"); outInfo.setMsg("导入标识ID不存在");
return outInfo; return outInfo;
} }
String startRow = request.getParameter("startRow"); List dataList = DocExcelUtils.readExcel(file, docRouteEnum.getStartRow(), docRouteEnum.getClazz());
List dataList = DocExcelUtils.readExcel(file, NumberUtils.createInteger(startRow), docRouteEnum.getClazz());
if (CollectionUtils.isEmpty(dataList)) { if (CollectionUtils.isEmpty(dataList)) {
outInfo.setMsg("未读取到数据"); outInfo.setMsg("未读取到数据");
return outInfo; return outInfo;
} }
outInfo.set(EiConstant.serviceName, docRouteEnum.getServiceNme()); outInfo.set(EiConstant.serviceName, docRouteEnum.getServiceNme());
outInfo.set(EiConstant.methodName, docRouteEnum.getMethodName()); outInfo.set(EiConstant.methodName, docRouteEnum.getMethodName());
outInfo.set("params", this.convertParam(paramMaps)); outInfo.set("params", params);
outInfo.set("dataList", dataList); outInfo.set("dataList", dataList);
outInfo = XLocalManager.call(outInfo); outInfo = XLocalManager.call(outInfo);
} catch (Exception e) { } catch (Exception e) {
...@@ -90,15 +91,42 @@ public class DocController extends WebDispatchController { ...@@ -90,15 +91,42 @@ public class DocController extends WebDispatchController {
* @param paramMaps * @param paramMaps
* @return * @return
*/ */
private Map<String, String> convertParam(Map<String, String[]> paramMaps) { private Map<String, Object> convertParam(Map<String, String[]> paramMaps) {
if (MapUtils.isEmpty(paramMaps)) { if (MapUtils.isEmpty(paramMaps)) {
return new HashMap<>(); return new HashMap<>();
} }
Map<String, String> paramMap = new HashMap<>(); Map<String, Object> paramMap = new HashMap<>();
for (Map.Entry<String, String[]> entry : paramMaps.entrySet()) { for (Map.Entry<String, String[]> entry : paramMaps.entrySet()) {
paramMap.put(entry.getKey(), entry.getValue()[0]); String key = entry.getKey();
String value = entry.getValue()[0];
if ("parameter".equals(key)) {
paramMap.put(key, encodeParam(value));
} else {
paramMap.put(key, value);
}
} }
return paramMap; return paramMap;
} }
/**
* 解码参数
*
* @param parameter
* @return
*/
private Map<String, Object> encodeParam(String parameter) {
try {
if (StringUtils.isBlank(parameter)) {
return null;
}
// 帆软传递进来的参数进行了两次编码,因此需要进行两次解码
String paramsText = URLDecoder.decode(parameter, "UTF-8");
paramsText = URLDecoder.decode(paramsText, "UTF-8");
return JSONObject.parseObject(paramsText).getInnerMap();
} catch (Exception e) {
log.error("字符串解码:{}", e.getMessage(), e);
throw new PlatException("参数格式错误,解码失败");
}
}
} }
package com.baosight.hggp.controller;
import com.baosight.hggp.core.utils.Iplat4jUtils;
import com.baosight.hggp.util.LogUtils;
import com.baosight.iplat4j.core.ei.EiConstant;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;
import java.io.IOException;
import java.util.HashMap;
import java.util.Map;
/**
* @author:songx
* @date:2024/3/14,14:26
*/
@CrossOrigin
@RestController
@RequestMapping({"/file"})
public class FileController {
/**
* 删除文件
*
* @param docId
* @throws IOException
*/
@RequestMapping(value = "/delete/{docId}", method = RequestMethod.GET)
public Map delete(@PathVariable String docId) throws IOException {
Map resultMap = new HashMap();
try {
Iplat4jUtils.deleteFileByDocId(docId);
resultMap.put("id", docId);
resultMap.put("status", EiConstant.STATUS_SUCCESS);
resultMap.put("message", "SUCCESS");
} catch (Exception e) {
resultMap.put("status", 500);
resultMap.put("message", LogUtils.getMsg(e));
}
return resultMap;
}
}
package com.baosight.hggp.core.constant;
import com.baosight.iplat4j.core.ioc.spring.PlatApplicationContext;
import lombok.Data;
/**
* @author:songx
* @date:2023/8/28,10:05
*/
@Data
public class S3Constant {
/**
* s3、local
*/
public static String FILE_LOCATION = PlatApplicationContext.getProperty("iplat4j.admin.upload.fileLocation");
/**
* endpoint
*/
public static String ENDPOINT = PlatApplicationContext.getProperty("iplat4j.admin.objectStorage.s3.endpoint");
/**
* bucket名称
*/
public static String BUCKET_NAME = PlatApplicationContext.getProperty("iplat4j.admin.objectStorage.s3.bucket");
/**
* AK
*/
public static String ACCESS_KEY = PlatApplicationContext.getProperty("iplat4j.admin.objectStorage.s3.accessKey");
/**
* SK
*/
public static String SECRET_KEY = PlatApplicationContext.getProperty("iplat4j.admin.objectStorage.s3.secretKey");
}
package com.baosight.hggp.common; package com.baosight.hggp.core.enums;
import com.baosight.hggp.hg.cw.domain.HGCW003; import com.baosight.hggp.hg.cw.domain.HGCW003;
import com.baosight.hggp.hg.pz.domain.HGPZ005; import com.baosight.hggp.hg.pz.domain.HGPZ005;
import com.baosight.hggp.hg.sc.domain.HGSC004A; import com.baosight.hggp.hg.sc.domain.HGSC004A;
import com.baosight.hggp.hg.sc.domain.HGSC009;
import com.baosight.hggp.hg.sc.domain.HGSC009A; import com.baosight.hggp.hg.sc.domain.HGSC009A;
import com.baosight.hggp.hg.sj.domain.HGSJ003; import com.baosight.hggp.hg.sj.domain.HGSJ003;
...@@ -14,19 +12,49 @@ import com.baosight.hggp.hg.sj.domain.HGSJ003; ...@@ -14,19 +12,49 @@ import com.baosight.hggp.hg.sj.domain.HGSJ003;
*/ */
public enum DocRouteEnum { public enum DocRouteEnum {
HGSC004A("route_001", "HGSC004A", "importData", HGSC004A.class), HGSC004A("route_001", "", 1, "HGSC004A", "importData", HGSC004A.class),
HGSC009A("route_002", "HGSC009", "importData", HGSC009A.class), HGSC009A("route_002", "", 1, "HGSC009", "importData", HGSC009A.class),
HGPZ005("route_003", "HGPZ005", "importData", HGPZ005.class), HGPZ005("route_003", "", 1, "HGPZ005", "importData", HGPZ005.class),
HGCW003("route_004", "HGCW003", "importData", HGCW003.class), HGCW003("route_004", "", 1, "HGCW003", "importData", HGCW003.class),
HGSJ003("route_005", "HGSJ003", "importData", HGSJ003.class), HGSJ003("route_005", "", 1, "HGSJ003", "importData", HGSJ003.class),
; ;
/**
* 唯一标识
*/
private String id; private String id;
/**
* 模版文件的地址,模版文件路径必须在META-INF.resources下面
*/
private String templateUrl;
/**
* 数据从excel的第几行开始,起始0
*/
private int startRow;
/**
* 业务处理类
*/
private String serviceNme; private String serviceNme;
/**
* 业务处理方法
*/
private String methodName; private String methodName;
/**
* 数据转换后的实体类
*/
private Class clazz; private Class clazz;
<T> DocRouteEnum(String id, String serviceNme, String methodName, Class<T> clazz) { <T> DocRouteEnum(String id, String templateUrl, int startRow, String serviceNme, String methodName,
Class<T> clazz) {
this.id = id; this.id = id;
this.templateUrl = templateUrl;
this.startRow = startRow;
this.serviceNme = serviceNme; this.serviceNme = serviceNme;
this.methodName = methodName; this.methodName = methodName;
this.clazz = clazz; this.clazz = clazz;
...@@ -51,6 +79,14 @@ public enum DocRouteEnum { ...@@ -51,6 +79,14 @@ public enum DocRouteEnum {
return id; return id;
} }
public String getTemplateUrl() {
return templateUrl;
}
public int getStartRow() {
return startRow;
}
public String getServiceNme() { public String getServiceNme() {
return serviceNme; return serviceNme;
} }
......
...@@ -3,6 +3,7 @@ package com.baosight.hggp.core.tools; ...@@ -3,6 +3,7 @@ package com.baosight.hggp.core.tools;
import com.baosight.hggp.core.dao.DaoBase; import com.baosight.hggp.core.dao.DaoBase;
import com.baosight.hggp.util.AssertUtils; import com.baosight.hggp.util.AssertUtils;
import com.baosight.iplat4j.common.ed.domain.TEDFA00; import com.baosight.iplat4j.common.ed.domain.TEDFA00;
import com.baosight.iplat4j.common.eu.domain.Teudm05;
import com.baosight.iplat4j.core.exception.PlatException; import com.baosight.iplat4j.core.exception.PlatException;
import org.apache.commons.collections.CollectionUtils; import org.apache.commons.collections.CollectionUtils;
...@@ -16,7 +17,7 @@ import java.util.Map; ...@@ -16,7 +17,7 @@ import java.util.Map;
* @author:songx * @author:songx
* @date:2022/8/10,13:55 * @date:2022/8/10,13:55
*/ */
public class EDTools { public class Iplat4jTools {
/** /**
* 页面工具类 * 页面工具类
...@@ -33,7 +34,7 @@ public class EDTools { ...@@ -33,7 +34,7 @@ public class EDTools {
* @return * @return
*/ */
public static TEDFA00 query(String ename) { public static TEDFA00 query(String ename) {
AssertUtils.isNull(ename, "页面英文名称不能为空!"); AssertUtils.isEmpty(ename, "页面英文名称不能为空!");
Map<String, String> paramMap = new HashMap(); Map<String, String> paramMap = new HashMap();
paramMap.put("form_ename", ename); paramMap.put("form_ename", ename);
List<TEDFA00> results = DaoBase.getInstance().query("tedfa00.query", paramMap); List<TEDFA00> results = DaoBase.getInstance().query("tedfa00.query", paramMap);
...@@ -56,7 +57,7 @@ public class EDTools { ...@@ -56,7 +57,7 @@ public class EDTools {
* @return * @return
*/ */
public static List<Map<String, Object>> list(String codeSetCode) { public static List<Map<String, Object>> list(String codeSetCode) {
AssertUtils.isNull(codeSetCode, "代码分类编码不能为空!"); AssertUtils.isEmpty(codeSetCode, "代码分类编码不能为空!");
Map<String, String> paramMap = new HashMap(); Map<String, String> paramMap = new HashMap();
paramMap.put("codesetCode", codeSetCode); paramMap.put("codesetCode", codeSetCode);
List<Map<String, Object>> results = DaoBase.getInstance().query("EDCM01.queryDetail", paramMap); List<Map<String, Object>> results = DaoBase.getInstance().query("EDCM01.queryDetail", paramMap);
...@@ -68,4 +69,26 @@ public class EDTools { ...@@ -68,4 +69,26 @@ public class EDTools {
} }
/**
* 上传的文件
*
* @author:songx
* @date:2024/8/8,16:47
*/
public static class EuDm05 {
/**
* 查询页面信息
*
* @param docId
* @return
*/
public static Teudm05 getDocByDocId(String docId) {
AssertUtils.isEmpty(docId, "文件ID不能为空!");
Map<String, String> paramMap = new HashMap();
paramMap.put("resId", docId);
List<Teudm05> results = DaoBase.getInstance().query("EUDM05.getDocByDocId", paramMap);
return CollectionUtils.isEmpty(results) ? null : results.get(0);
}
}
} }
package com.baosight.hggp.core.utils;
import com.baosight.hggp.core.constant.S3Constant;
import com.baosight.hggp.core.tools.Iplat4jTools;
import com.baosight.hggp.util.FileUtils;
import com.baosight.hggp.util.StringUtils;
import com.baosight.iplat4j.common.eu.domain.Teudm05;
import com.baosight.iplat4j.core.exception.PlatException;
import com.baosight.iplat4j.core.ioc.spring.PlatApplicationContext;
import com.baosight.iplat4j.eu.dm.util.PlatFileUploader;
import java.util.Map;
/**
* @author:songx
* @date:2024/8/8,17:00
*/
public class Iplat4jUtils {
static PlatFileUploader platFileUploader = PlatApplicationContext.getApplicationContext()
.getBean("platFileUploader", PlatFileUploader.class);
/**
* 删除文件
*
* @param docId
* @return
*/
public static boolean deleteFileByDocId(String docId) {
// 判断文件上传的地址
String fileLocation = S3Constant.FILE_LOCATION;
if ("s3".equalsIgnoreCase(fileLocation)) {
Teudm05 dbDm05 = Iplat4jTools.EuDm05.getDocByDocId(docId);
if (dbDm05 == null) {
throw new PlatException("文件在服务器中不存在");
}
String url = dbDm05.getUrl();
if (StringUtils.isBlank(url)) {
return false;
}
// 删除本地记录
// platFileUploader.deleteDocById(docId);
// 删除S3文件,从文件路径中截取key,不包含域名
String key = url.replace(S3Constant.ENDPOINT + "/", "");
return S3Utils.deleteFile(key);
} else {
Map document = platFileUploader.getDocument(docId);
String chgName = document.get("chgName").toString();
String docPath = document.get("realPath").toString();
String filePath = docPath + chgName;
// if (platFileUploader.deleteDocById(docId) > 0) {
return FileUtils.deleteFile(filePath);
// }
// return false;
}
}
}
package com.baosight.hggp.core.utils;
import com.amazonaws.ClientConfiguration;
import com.amazonaws.auth.AWSStaticCredentialsProvider;
import com.amazonaws.auth.BasicAWSCredentials;
import com.amazonaws.client.builder.AwsClientBuilder;
import com.amazonaws.services.s3.AmazonS3;
import com.amazonaws.services.s3.AmazonS3ClientBuilder;
import com.baosight.hggp.core.constant.S3Constant;
import lombok.extern.slf4j.Slf4j;
/**
* OSS凭证
*
* @author:songx
* @date:2023/8/28,11:26
*/
@Slf4j
public class S3ClientUtils {
private S3ClientUtils() {
}
/**
* 初始化配置信息(纯粹就打印日志而已,因为会加载该类的全局变量)
*/
public static void init() {
AmazonS3 s3Client = Instance.s3Client;
log.info("初始化OSS客户端完成:isReady -> {}", s3Client != null);
}
/**
* 获取S3客户端
*
* @return
*/
public static AmazonS3 getS3Client() {
return Instance.s3Client;
}
/**
* 刷新客户端
*/
public static void refresh() {
Instance.refresh();
}
/**
* 初始化Instance
*
* @author:songx
* @date:2022/4/2,9:58
*/
private static class Instance {
/**
* 客户端实例
*/
private static AmazonS3 s3Client = buildAmazonS3();
/**
* 刷新S3客户端
*/
private static void refresh() {
s3Client = buildAmazonS3();
log.info("刷新OSS客户端完成:isReady->{}", s3Client != null);
}
/**
* 获取AmazonS3Client实例
*
* @return
*/
private static synchronized AmazonS3 buildAmazonS3() {
if (!"s3".equalsIgnoreCase(S3Constant.FILE_LOCATION)) {
return null;
}
// 判断上传类型是否S3
AmazonS3ClientBuilder client = AmazonS3ClientBuilder.standard();
ClientConfiguration config = new ClientConfiguration();
config.setProtocol(com.amazonaws.Protocol.HTTPS);
config.setConnectionTimeout(10001);
config.setSignerOverride("S3SignerType");
client.setClientConfiguration(config);
client.setCredentials(new AWSStaticCredentialsProvider(
new BasicAWSCredentials(S3Constant.ACCESS_KEY, S3Constant.SECRET_KEY)));
// 去掉地址中的bucket前缀
String endpoint = S3Constant.ENDPOINT.replace(S3Constant.BUCKET_NAME + ".", "");
client.setEndpointConfiguration(new AwsClientBuilder.EndpointConfiguration(endpoint, null));
return client.build();
}
}
}
package com.baosight.hggp.core.utils;
import com.amazonaws.services.s3.AmazonS3;
import com.baosight.hggp.core.constant.S3Constant;
import com.baosight.hggp.util.AssertUtils;
import java.io.File;
/**
* OSS工具类
*
* @author:songx
* @date:2023/8/28,11:25
*/
public class S3Utils {
/**
* 上传文件
*
* @param key 默认不指定key的情况下,以文件内容的hash值作为文件名
* @param file
*/
public static boolean uploadFile(String key, File file) {
AmazonS3 client = S3ClientUtils.getS3Client();
AssertUtils.isNull(client, "上传失败,OSS客户端未初始化,请检查");
client.putObject(S3Constant.BUCKET_NAME, key, file);
return true;
}
/**
* 删除文件
*
* @param key
*/
public static boolean deleteFile(String key) {
AmazonS3 client = S3ClientUtils.getS3Client();
AssertUtils.isNull(client, "删除失败,OSS客户端未初始化,请检查");
client.deleteObject(S3Constant.BUCKET_NAME, key);
return true;
}
}
...@@ -170,9 +170,6 @@ public class ServiceHGCG002A extends ServiceBase { ...@@ -170,9 +170,6 @@ public class ServiceHGCG002A extends ServiceBase {
cg002B.setPlanDetailId(dbCg001A.getId()); cg002B.setPlanDetailId(dbCg001A.getId());
cg002BList.add(cg002B); cg002BList.add(cg002B);
DaoUtils.insertBatch(HGCG002B.INSERT,cg002BList); DaoUtils.insertBatch(HGCG002B.INSERT,cg002BList);
//修改主表信息
HGCGTools.HgCg002.updateCg002Pur(newCg002);
} }
/** /**
......
...@@ -128,7 +128,8 @@ public class ServiceHGCG003A extends ServiceBase { ...@@ -128,7 +128,8 @@ public class ServiceHGCG003A extends ServiceBase {
*/ */
private void confirmData(List<HGCG002B> fCg002Bs, Map<Long, HGCG002B> dbCg002BMap, HGCG002 cg002) { private void confirmData(List<HGCG002B> fCg002Bs, Map<Long, HGCG002B> dbCg002BMap, HGCG002 cg002) {
HGCG002B hgcg002B = fCg002Bs.get(0); HGCG002B hgcg002B = fCg002Bs.get(0);
HGCG003 newCg003 = BeanUtils.copy(hgcg002B, HGCG003.class); HGCG003 newCg003 = new HGCG003();
BeanUtils.copyProperties(hgcg002B, newCg003,"id","createdBy","createdName","createdTime","updatedBy","updatedName","updatedTime");
newCg003.setReceiveDate(DateUtils.shortDate()); newCg003.setReceiveDate(DateUtils.shortDate());
newCg003.setReceiveNo(SequenceGenerator.getNextSequence(HGConstant.SequenceId.CG_RECEIVE_NO)); newCg003.setReceiveNo(SequenceGenerator.getNextSequence(HGConstant.SequenceId.CG_RECEIVE_NO));
BigDecimal bcReceiveQtySum = fCg002Bs.stream().map(HGCG002B::getBcReceiveQty).reduce(BigDecimal.ZERO,BigDecimal::add); BigDecimal bcReceiveQtySum = fCg002Bs.stream().map(HGCG002B::getBcReceiveQty).reduce(BigDecimal.ZERO,BigDecimal::add);
...@@ -164,6 +165,10 @@ public class ServiceHGCG003A extends ServiceBase { ...@@ -164,6 +165,10 @@ public class ServiceHGCG003A extends ServiceBase {
cg003B.setContractDetailId(dbCg002B.getId()); cg003B.setContractDetailId(dbCg002B.getId());
DaoUtils.insert(HGCG003B.INSERT,cg003B); DaoUtils.insert(HGCG003B.INSERT,cg003B);
BigDecimal diffQty = cg003B.getReceiveQty().subtract(dbCg002B.getReceiveQty());
Integer status = diffQty.compareTo(BigDecimal.ZERO) == 0 ? HGConstant.CgContractStatus.S_5
: HGConstant.CgContractStatus.S_4;
dbCg002B.setStatus(status);
// 更新合同状态 // 更新合同状态
HGCGTools.HgCg002B.updateReceive(dbCg002B, cg003B.getReceiveQty()); HGCGTools.HgCg002B.updateReceive(dbCg002B, cg003B.getReceiveQty());
} }
......
...@@ -126,6 +126,9 @@ ...@@ -126,6 +126,9 @@
<isNotEmpty prepend=" AND " property="id"> <isNotEmpty prepend=" AND " property="id">
ID = #id# ID = #id#
</isNotEmpty> </isNotEmpty>
<isNotEmpty prepend=" AND " property="ids">
ID IN <iterate open="(" close=")" conjunction="," property="ids">#ids[]#</iterate>
</isNotEmpty>
<isNotEmpty prepend=" AND " property="contractNo"> <isNotEmpty prepend=" AND " property="contractNo">
CONTRACT_NO = #contractNo# CONTRACT_NO = #contractNo#
</isNotEmpty> </isNotEmpty>
...@@ -252,6 +255,8 @@ ...@@ -252,6 +255,8 @@
AMOUNT = #amount#, <!-- 金额(不含税金额) --> AMOUNT = #amount#, <!-- 金额(不含税金额) -->
TAX_INCLUDE_AMOUNT = #taxIncludeAmount#, <!-- 含税金额 --> TAX_INCLUDE_AMOUNT = #taxIncludeAmount#, <!-- 含税金额 -->
TAX_AMOUNT = #taxAmount#, <!-- 税额 --> TAX_AMOUNT = #taxAmount#, <!-- 税额 -->
PUR_QTY = #purQty#,
PUR_WEIGHT = #purWeight#,
<include refid="updateRevise"/> <include refid="updateRevise"/>
WHERE CONTRACT_NO = #contractNo# WHERE CONTRACT_NO = #contractNo#
</update> </update>
...@@ -293,4 +298,15 @@ ...@@ -293,4 +298,15 @@
SELECT MAX(ID) AS "id" FROM ${hggpSchema}.HGCG002 SELECT MAX(ID) AS "id" FROM ${hggpSchema}.HGCG002
</select> </select>
<!-- 入库质检修改收货 -->
<update id="updateCheck">
UPDATE ${hggpSchema}.HGCG002
SET
RECEIVE_QTY = #receiveQty#,
RECEIVE_WEIGHT = #receiveWeight#,
STATUS = #status#,
<include refid="updateRevise"/>
WHERE ID = #id#
</update>
</sqlMap> </sqlMap>
...@@ -379,10 +379,10 @@ ...@@ -379,10 +379,10 @@
b.PUR_USER_NAME = #purUserName# b.PUR_USER_NAME = #purUserName#
</isNotEmpty> </isNotEmpty>
<isNotEmpty prepend=" AND " property="statuses"> <isNotEmpty prepend=" AND " property="statuses">
b.STATUS IN <iterate open="(" close=")" conjunction="," property="statuses">#statuses[]#</iterate> a.STATUS IN <iterate open="(" close=")" conjunction="," property="statuses">#statuses[]#</iterate>
</isNotEmpty> </isNotEmpty>
<isNotEmpty prepend=" AND " property="status"> <isNotEmpty prepend=" AND " property="status">
b.STATUS = #status# a.STATUS = #status#
</isNotEmpty> </isNotEmpty>
<include refid="idCondition"/> <include refid="idCondition"/>
<dynamic prepend="ORDER BY"> <dynamic prepend="ORDER BY">
...@@ -401,8 +401,21 @@ ...@@ -401,8 +401,21 @@
SET SET
RECEIVE_QTY = #receiveQty#, RECEIVE_QTY = #receiveQty#,
RECEIVE_WEIGHT = #receiveWeight#, RECEIVE_WEIGHT = #receiveWeight#,
STATUS = #status#,
<include refid="updateRevise"/> <include refid="updateRevise"/>
WHERE ID = #id# WHERE ID = #id#
</update> </update>
<!-- 入库质检修改收货 -->
<update id="updateCheck">
UPDATE ${hggpSchema}.HGCG002A
SET
RECEIVE_QTY = #receiveQty#,
RECEIVE_WEIGHT = #receiveWeight#,
STATUS = #status#,
<include refid="updateRevise"/>
WHERE ID = #id#
</update>
</sqlMap> </sqlMap>
...@@ -249,6 +249,23 @@ ...@@ -249,6 +249,23 @@
WHERE RECEIVE_NO = #receiveNo# WHERE RECEIVE_NO = #receiveNo#
</update> </update>
<update id="update">
UPDATE ${hggpSchema}.HGCG003
SET
ID = #id#,
SUP_CODE = #supCode#, <!-- 供应商编码 -->
SUP_NAME = #supName#, <!-- 供应商名称 -->
PUR_USER_ID = #purUserId#, <!-- 采购员 -->
PUR_USER_NAME = #purUserName#, <!-- 采购员名称 -->
RECEIVE_QTY = #receiveQty#, <!-- 收货数量 -->
RECEIVE_WEIGHT = #receiveWeight#, <!-- 收货重量 -->
AMOUNT = #amount#, <!-- 金额 -->
RECEIVE_DATE = REPLACE(#receiveDate#, '-', ''), <!-- 收货日期 -->
<include refid="updateRevise"/>
WHERE
ID = #id#
</update>
<!-- 修改数量 --> <!-- 修改数量 -->
<update id="updateQty"> <update id="updateQty">
UPDATE ${hggpSchema}.HGCG003 UPDATE ${hggpSchema}.HGCG003
......
...@@ -15,6 +15,7 @@ import java.math.BigDecimal; ...@@ -15,6 +15,7 @@ import java.math.BigDecimal;
import java.util.HashMap; import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
import java.util.Objects;
import java.util.stream.Collectors; import java.util.stream.Collectors;
/** /**
...@@ -311,6 +312,19 @@ public class HGCGTools { ...@@ -311,6 +312,19 @@ public class HGCGTools {
/** /**
* 查询 * 查询
* *
* @param ids
* @return
*/
public static List<HGCG002> listByIds(List<Long> ids) {
AssertUtils.isEmpty(ids, "合同号不能为空");
Map<String, Object> paramMap = new HashMap();
paramMap.put("ids", ids);
return DaoBase.getInstance().query(HGCG002.QUERY, paramMap);
}
/**
* 查询
*
* @param contractNos * @param contractNos
* @return * @return
*/ */
...@@ -319,10 +333,10 @@ public class HGCGTools { ...@@ -319,10 +333,10 @@ public class HGCGTools {
return results.stream().collect(Collectors.toMap(HGCG002A::getContractNo, item -> item)); return results.stream().collect(Collectors.toMap(HGCG002A::getContractNo, item -> item));
} }
public static void updateContractPrimary(List<HGCG002> hgcg002AList) { public static void updateContractPrimary(List<HGCG002> hgcg002List) {
List<Long> primaryIds = hgcg002AList.stream().map(o->o.getId()).collect(Collectors.toList()); List<Long> primaryIds = hgcg002List.stream().map(o->o.getId()).collect(Collectors.toList());
List<HGCG002B> queryHgcg002BList = HGCGTools.HgCg002B.listByPrimaryIds(primaryIds); List<HGCG002B> queryHgcg002BList = HGCGTools.HgCg002B.listByPrimaryIds(primaryIds);
hgcg002AList.forEach(cg002 ->{ hgcg002List.forEach(cg002 ->{
List<HGCG002B> hgcg002BList = queryHgcg002BList.stream().filter(o->o.getPrimaryId().compareTo(cg002.getId()) == 0).collect(Collectors.toList()); List<HGCG002B> hgcg002BList = queryHgcg002BList.stream().filter(o->o.getPrimaryId().compareTo(cg002.getId()) == 0).collect(Collectors.toList());
//修改主表信息 //修改主表信息
//采购数量 //采购数量
...@@ -389,6 +403,55 @@ public class HGCGTools { ...@@ -389,6 +403,55 @@ public class HGCGTools {
DaoUtils.update(HGSqlConstant.HgCg002.UPDATE_PUR, cg002); DaoUtils.update(HGSqlConstant.HgCg002.UPDATE_PUR, cg002);
} }
public static void updateChecks(List<HGZL001> fZl001s) {
//获取收货明细数据
List<Long> receiveDetailIds = fZl001s.stream().map(HGZL001::getReceiveDetailId).collect(Collectors.toList());
List<HGCG003B> hgcg003BList = HGCGTools.HgCg003B.list(receiveDetailIds);
//获取合同明细
List<Long> contractDetailIds = hgcg003BList.stream().map(HGCG003B::getContractDetailId).collect(Collectors.toList());
List<HGCG002B> hgcg002BList = HGCGTools.HgCg002B.list(contractDetailIds);
//合同主表信息
List<Long> contractIds = hgcg002BList.stream().map(o->o.getPrimaryId()).collect(Collectors.toList());
List<HGCG002> queryHgcg002List = HGCGTools.HgCg002.listByIds(contractIds);
fZl001s.forEach(hgzl001 ->{
//关联获取到收货明细
HGCG003B hgcg003B = hgcg003BList.stream().filter(o -> o.getId().compareTo(hgzl001.getReceiveDetailId()) == 0).findAny().orElse(null);
if(Objects.nonNull(hgcg003B)){
//关联获取到合同明细
HGCG002B hgcg002B = hgcg002BList.stream().filter(o->o.getId().compareTo(hgcg003B.getContractDetailId()) == 0).findAny().orElse(null);
if(Objects.nonNull(hgcg002B)){
BigDecimal unqualifyQty = hgzl001.getUnqualifyQty();
Integer status = unqualifyQty.compareTo(BigDecimal.ZERO) == 0 ? HGConstant.CgContractStatus.S_5
: HGConstant.CgContractStatus.S_4;
hgcg002B.setStatus(status);
HGCGTools.HgCg002B.updateCheck(hgcg002B,unqualifyQty.negate());
//修改主表信息
HGCG002 hgcg002 = queryHgcg002List.stream().filter(o->o.getId().compareTo(hgcg002B.getPrimaryId()) == 0).findAny().orElse(null);
hgcg002.setStatus(status);
HGCGTools.HgCg002.updateCheck(hgcg002,unqualifyQty.negate());
}
}
});
}
/**
* 修改状态
*
* @param dbCg002
* @param checkQty
*/
public static void updateCheck(HGCG002 dbCg002, BigDecimal checkQty) {
AssertUtils.isNull(dbCg002, "合同不能为空!");
BigDecimal newReceiveQty = checkQty.add(dbCg002.getReceiveQty());
Map<String, Object> paramMap = new HashMap<>();
paramMap.put(HGCG002.FIELD_ID, dbCg002.getId());
paramMap.put(HGCG002.FIELD_RECEIVE_QTY, newReceiveQty);
paramMap.put(HGCG002.FIELD_RECEIVE_WEIGHT, newReceiveQty.multiply(dbCg002.getPurUnitWeight()));
paramMap.put(HGCG002.FIELD_STATUS, dbCg002.getStatus());
DaoUtils.update(HGSqlConstant.HgCg002.UPDATE_CHECK, paramMap);
}
} }
/** /**
...@@ -493,9 +556,28 @@ public class HGCGTools { ...@@ -493,9 +556,28 @@ public class HGCGTools {
paramMap.put(HGCG002.FIELD_ID, dbCg002B.getId()); paramMap.put(HGCG002.FIELD_ID, dbCg002B.getId());
paramMap.put(HGCG002.FIELD_RECEIVE_QTY, newReceiveQty); paramMap.put(HGCG002.FIELD_RECEIVE_QTY, newReceiveQty);
paramMap.put(HGCG002.FIELD_RECEIVE_WEIGHT, newReceiveQty.multiply(dbCg002B.getPurUnitWeight())); paramMap.put(HGCG002.FIELD_RECEIVE_WEIGHT, newReceiveQty.multiply(dbCg002B.getPurUnitWeight()));
paramMap.put(HGCG002.FIELD_STATUS, dbCg002B.getStatus());
DaoUtils.update(HGSqlConstant.HgCg002B.UPDATE_RECEIVE, paramMap); DaoUtils.update(HGSqlConstant.HgCg002B.UPDATE_RECEIVE, paramMap);
} }
/**
* 修改状态
*
* @param dbCg002B
* @param receiveQty
*/
public static void updateCheck(HGCG002B dbCg002B, BigDecimal receiveQty) {
AssertUtils.isNull(dbCg002B, "合同明细不能为空!");
AssertUtils.isNull(receiveQty, "收货数量不能为空!");
BigDecimal newReceiveQty = receiveQty.add(dbCg002B.getReceiveQty());
Map<String, Object> paramMap = new HashMap<>();
paramMap.put(HGCG002.FIELD_ID, dbCg002B.getId());
paramMap.put(HGCG002.FIELD_RECEIVE_QTY, newReceiveQty);
paramMap.put(HGCG002.FIELD_RECEIVE_WEIGHT, newReceiveQty.multiply(dbCg002B.getPurUnitWeight()));
paramMap.put(HGCG002.FIELD_STATUS, dbCg002B.getStatus());
DaoUtils.update(HGSqlConstant.HgCg002B.UPDATE_CHECK, paramMap);
}
} }
/** /**
......
...@@ -390,4 +390,18 @@ public class HGConstant { ...@@ -390,4 +390,18 @@ public class HGConstant {
// 销售计划 // 销售计划
public static final Integer S_1 = 1; public static final Integer S_1 = 1;
} }
/**
* 物料清单
*
* @author:songx
* @date:2024/2/22,13:57
*/
public static class WlApprovalStatu {
// 待审核
public static final Integer S_0 = 0;
// 已审核
public static final Integer S_1 = 2;
}
} }
...@@ -65,6 +65,8 @@ public class HGSqlConstant { ...@@ -65,6 +65,8 @@ public class HGSqlConstant {
public static final String UPDATE_STATUS = MODULE_NAME + "updateStatus"; public static final String UPDATE_STATUS = MODULE_NAME + "updateStatus";
// 修改收货数量 // 修改收货数量
public static final String UPDATE_RECEIVE = MODULE_NAME + "updateReceive"; public static final String UPDATE_RECEIVE = MODULE_NAME + "updateReceive";
// 入库质检修改收货数量
public static final String UPDATE_CHECK = MODULE_NAME + "updateCheck";
} }
/** /**
...@@ -81,6 +83,8 @@ public class HGSqlConstant { ...@@ -81,6 +83,8 @@ public class HGSqlConstant {
public static final String LOCK = MODULE_NAME + "lock"; public static final String LOCK = MODULE_NAME + "lock";
// 修改收货数量 // 修改收货数量
public static final String UPDATE_RECEIVE = MODULE_NAME + "updateReceive"; public static final String UPDATE_RECEIVE = MODULE_NAME + "updateReceive";
// 入库质检修改收货数量
public static final String UPDATE_CHECK = MODULE_NAME + "updateCheck";
} }
/** /**
......
package com.baosight.hggp.hg.dm.service;
import com.baosight.hggp.core.enums.DocRouteEnum;
import com.baosight.hggp.util.EiInfoUtils;
import com.baosight.hggp.util.LogUtils;
import com.baosight.iplat4j.core.ei.EiInfo;
import com.baosight.iplat4j.core.service.impl.ServiceEPBase;
import org.apache.commons.collections.MapUtils;
import org.apache.commons.lang.StringUtils;
import java.util.Map;
/**
* 文件导入
*
* @author:songx
* @date:2024/4/7,17:02
*/
public class ServiceHGDM91 extends ServiceEPBase {
/**
* 初始化
*
* @param inInfo
* @return
*/
@Override
public EiInfo initLoad(EiInfo inInfo) {
try {
Map queryRow = EiInfoUtils.getFirstRow(inInfo);
setTemplateUrl(queryRow);
} catch (Exception e) {
LogUtils.setMsg(inInfo, e, "初始化失败");
}
return inInfo;
}
/**
* 根据路由获取模版地址
*
* @param queryRow
* @return
*/
private void setTemplateUrl(Map queryRow) {
String templateUrl = "";
String id = MapUtils.getString(queryRow, "id");
if (StringUtils.isNotBlank(id)) {
DocRouteEnum docRouteEnum = DocRouteEnum.getById(id);
templateUrl = docRouteEnum == null ? "" : docRouteEnum.getTemplateUrl();
}
queryRow.put("templateUrl", templateUrl);
}
}
...@@ -129,7 +129,8 @@ public class ServiceHGKC001A extends ServiceBase { ...@@ -129,7 +129,8 @@ public class ServiceHGKC001A extends ServiceBase {
for (HGCG003A fCg003A : fCg003As) { for (HGCG003A fCg003A : fCg003As) {
String receiveNo = fCg003A.getReceiveNo(); String receiveNo = fCg003A.getReceiveNo();
HGCG003 dbCg003 = dbCg003Map.get(receiveNo); HGCG003 dbCg003 = dbCg003Map.get(receiveNo);
HGKC001 newKc001 = BeanUtils.copy(dbCg003, HGKC001.class); HGKC001 newKc001 = new HGKC001();
BeanUtils.copyProperties(dbCg003, newKc001,"id","createdBy","createdName","createdTime","updatedBy","updatedName","updatedTime");
newKc001.setWhCode(fCg003A.getWhCode()); newKc001.setWhCode(fCg003A.getWhCode());
newKc001.setWhName(fCg003A.getWhName()); newKc001.setWhName(fCg003A.getWhName());
newKc001.setDepositDate(DateUtils.shortDate()); newKc001.setDepositDate(DateUtils.shortDate());
......
...@@ -124,7 +124,9 @@ public class ServiceHGKC002 extends ServiceBase { ...@@ -124,7 +124,9 @@ public class ServiceHGKC002 extends ServiceBase {
DaoUtils.update(HGKC002.DELETE, fKc002); DaoUtils.update(HGKC002.DELETE, fKc002);
// 生成红冲记录 // 生成红冲记录
HGKC002 dbKc002 = dbKc002Map.get(fKc002.getReqNo()); HGKC002 dbKc002 = dbKc002Map.get(fKc002.getReqNo());
HGKC002 newKc002 = BeanUtils.copy(dbKc002, HGKC002.class); HGKC002 newKc002 = new HGKC002();
BeanUtils.copyProperties(dbKc002, newKc002,"id","createdBy","createdName","createdTime","updatedBy","updatedName","updatedTime");
newKc002.setReqNo(SequenceGenerator.getNextSequence(HGConstant.SequenceId.PROD_REQ_NO)); newKc002.setReqNo(SequenceGenerator.getNextSequence(HGConstant.SequenceId.PROD_REQ_NO));
newKc002.setApplyQty(dbKc002.getApplyQty().negate()); newKc002.setApplyQty(dbKc002.getApplyQty().negate());
newKc002.setApplyWeight(dbKc002.getApplyWeight().negate()); newKc002.setApplyWeight(dbKc002.getApplyWeight().negate());
......
...@@ -126,7 +126,8 @@ public class ServiceHGKC002A extends ServiceEPBase { ...@@ -126,7 +126,8 @@ public class ServiceHGKC002A extends ServiceEPBase {
BigDecimal applyQty = fKc010a.getApplyQty(); BigDecimal applyQty = fKc010a.getApplyQty();
Long invId = fKc010a.getId(); Long invId = fKc010a.getId();
HGKC010A dbKc010 = dbKc010Map.get(invId); HGKC010A dbKc010 = dbKc010Map.get(invId);
HGKC002 newKc002 = BeanUtils.copy(dbKc010, HGKC002.class); HGKC002 newKc002 = new HGKC002();
BeanUtils.copyProperties(dbKc010, newKc002,"id","createdBy","createdName","createdTime","updatedBy","updatedName","updatedTime");
newKc002.setReqNo(SequenceGenerator.getNextSequence(HGConstant.SequenceId.PROD_REQ_NO)); newKc002.setReqNo(SequenceGenerator.getNextSequence(HGConstant.SequenceId.PROD_REQ_NO));
newKc002.setReceiptDate(DateUtils.shortDate()); newKc002.setReceiptDate(DateUtils.shortDate());
newKc002.setApplyQty(applyQty); newKc002.setApplyQty(applyQty);
......
...@@ -238,7 +238,8 @@ public class ServiceHGKC003 extends ServiceBase { ...@@ -238,7 +238,8 @@ public class ServiceHGKC003 extends ServiceBase {
*/ */
private void sendBackOption(HGKC003 fKc003) { private void sendBackOption(HGKC003 fKc003) {
// 生产一条负数量和产量的红冲记录 // 生产一条负数量和产量的红冲记录
HGKC003 newKc003 = BeanUtils.copy(fKc003, HGKC003.class); HGKC003 newKc003 = new HGKC003();
BeanUtils.copyProperties(fKc003,newKc003,"id","createdBy","createdName","createdTime","updatedBy","updatedName","updatedTime");
newKc003.setInvQty(fKc003.getInvQty().negate()); newKc003.setInvQty(fKc003.getInvQty().negate());
newKc003.setInvWeight(fKc003.getInvWeight().negate()); newKc003.setInvWeight(fKc003.getInvWeight().negate());
newKc003.setDepositNoOld(fKc003.getDepositNo()); newKc003.setDepositNoOld(fKc003.getDepositNo());
......
...@@ -207,7 +207,8 @@ public class ServiceHGKC009 extends ServiceBase { ...@@ -207,7 +207,8 @@ public class ServiceHGKC009 extends ServiceBase {
for (Map.Entry<String, HGKC010> entry : endKcs.entrySet()) { for (Map.Entry<String, HGKC010> entry : endKcs.entrySet()) {
String key = entry.getKey(); String key = entry.getKey();
HGKC010 endKc = entry.getValue(); HGKC010 endKc = entry.getValue();
HGKC009 kc009 = BeanUtils.copy(endKc, HGKC009.class); HGKC009 kc009 = new HGKC009();
BeanUtils.copyProperties(endKc, kc009,"id","createdBy","createdName","createdTime","updatedBy","updatedName","updatedTime");
kc009.setInventRecordId(endKc.getSpecId()); kc009.setInventRecordId(endKc.getSpecId());
kc009.setDateType(queryMap.get("dateType").toString()); kc009.setDateType(queryMap.get("dateType").toString());
kc009.setDateProc(queryMap.get("yesterDate").toString()); kc009.setDateProc(queryMap.get("yesterDate").toString());
......
...@@ -12,7 +12,10 @@ import com.baosight.hggp.hg.cg.utils.HGCGUtils; ...@@ -12,7 +12,10 @@ import com.baosight.hggp.hg.cg.utils.HGCGUtils;
import com.baosight.hggp.hg.constant.HGConstant; import com.baosight.hggp.hg.constant.HGConstant;
import com.baosight.hggp.hg.constant.HGSqlConstant; import com.baosight.hggp.hg.constant.HGSqlConstant;
import com.baosight.hggp.hg.kc.domain.*; import com.baosight.hggp.hg.kc.domain.*;
import com.baosight.hggp.hg.kc.utils.HGKCUtils;
import com.baosight.hggp.hg.pz.domain.HGPZ005; import com.baosight.hggp.hg.pz.domain.HGPZ005;
import com.baosight.hggp.hg.pz.domain.HGPZ005A;
import com.baosight.hggp.hg.pz.domain.HGPZ007;
import com.baosight.hggp.hg.pz.tools.HGPZTools; import com.baosight.hggp.hg.pz.tools.HGPZTools;
import com.baosight.hggp.hg.sc.domain.HGSC008; import com.baosight.hggp.hg.sc.domain.HGSC008;
import com.baosight.hggp.hg.sc.tools.HGSCTools; import com.baosight.hggp.hg.sc.tools.HGSCTools;
...@@ -111,7 +114,8 @@ public class HGKCTools { ...@@ -111,7 +114,8 @@ public class HGKCTools {
// db数据 // db数据
Map<Long, HGCG003B> dbCg003BMap = HGCGUtils.HgCg003B.lockGetData(receiveIDsList); Map<Long, HGCG003B> dbCg003BMap = HGCGUtils.HgCg003B.lockGetData(receiveIDsList);
HGCG003B dbCg003B = dbCg003BMap.get(receiveId); HGCG003B dbCg003B = dbCg003BMap.get(receiveId);
HGKC001 newKc001 = BeanUtils.copy(dbCg003B, HGKC001.class); HGKC001 newKc001 = new HGKC001();
BeanUtils.copyProperties(dbCg003B, newKc001,"id","createdBy","createdName","createdTime","updatedBy","updatedName","updatedTime");
newKc001.setDepositDate(DateUtils.shortDate()); newKc001.setDepositDate(DateUtils.shortDate());
newKc001.setDepositNo(SequenceGenerator.getNextSequence(HGConstant.SequenceId.CG_DEPOSIT_NO)); newKc001.setDepositNo(SequenceGenerator.getNextSequence(HGConstant.SequenceId.CG_DEPOSIT_NO));
newKc001.setDepositQty(dbCg003B.getDepositQty()); newKc001.setDepositQty(dbCg003B.getDepositQty());
...@@ -259,6 +263,24 @@ public class HGKCTools { ...@@ -259,6 +263,24 @@ public class HGKCTools {
putInStorageCheckData(hgzl002List); putInStorageCheckData(hgzl002List);
setHgkc003Data(hgzl002List,hgkc003List, null, null); setHgkc003Data(hgzl002List,hgkc003List, null, null);
DaoUtils.insertBatch(HGKC003.INSERT,hgkc003List); DaoUtils.insertBatch(HGKC003.INSERT,hgkc003List);
//可能全部不合格
if(!CollectionUtils.isEmpty(hgkc003List)){
List<String> inventCodes = hgkc003List.stream().map(HGKC003::getPrdtCode).collect(Collectors.toList());
List<HGPZ005A> hgpz005AList = HGPZTools.HgPz005A.queryByInventCodes(inventCodes);
hgkc003List.forEach(hgkc003->{
//修改计划生产任务完工数量
HGSCTools.complete(hgkc003.getQualityId(),hgkc003.getInvQty().intValue(),hgkc003.getRectificationId(),HGConstant.StorageType.RK);
//查询当前工序
HGPZ005A hgpz005A = hgpz005AList.stream().filter(o -> o.getInventCode().equals(hgkc003.getPrdtCode())).findAny().orElse(null);
//查询比当前工序靠后的工序是否存在,不存在说明是最后工序,修改实时库存
List<HGPZ005A> nextHgpz005AList = hgpz005AList.stream().filter(o->o.getProcessOrder().compareTo(hgpz005A.getProcessOrder()) == 1).collect(Collectors.toList());
if(CollectionUtils.isEmpty(nextHgpz005AList)){
// 修改库存
HGKCUtils.HgKc010.updateInv(hgkc003.getCompanyCode(), hgkc003.getWhCode(), hgkc003.getPrdtCode(),
hgkc003.getInvQty(), hgkc003.getInvWeight());
}
});
}
} }
/** /**
* 对象赋值(工序质检单) * 对象赋值(工序质检单)
...@@ -269,7 +291,7 @@ public class HGKCTools { ...@@ -269,7 +291,7 @@ public class HGKCTools {
private static void setHgkc003Data(List<HGZL002> hgzl002List, List<HGKC003> hgkc003List, Integer code, List<HGZL004> hgzl004List) { private static void setHgkc003Data(List<HGZL002> hgzl002List, List<HGKC003> hgkc003List, Integer code, List<HGZL004> hgzl004List) {
List<String> inventCodes = hgzl002List.stream().map(HGZL002::getProductCode).collect(Collectors.toList()); List<String> inventCodes = hgzl002List.stream().map(HGZL002::getProductCode).collect(Collectors.toList());
List<HGPZ005> hgpz005List = HGPZTools.HgPz005.listByInventCodes(inventCodes); List<HGPZ005> hgpz005List = HGPZTools.HgPz005.listByInventCodes(inventCodes);
List<HGPZ007> hgpz007List = HGPZTools.HgPz007.allList();
hgzl002List.forEach(o->{ hgzl002List.forEach(o->{
HGPZ005 hgpz005 = hgpz005List.stream().filter(h->h.getInventCode().equals(o.getProductCode())).findAny().orElse(null); HGPZ005 hgpz005 = hgpz005List.stream().filter(h->h.getInventCode().equals(o.getProductCode())).findAny().orElse(null);
HGSC008 hgsc008 = HGSCTools.THGSC008.getById(o.getWorkId()); HGSC008 hgsc008 = HGSCTools.THGSC008.getById(o.getWorkId());
...@@ -278,7 +300,6 @@ public class HGKCTools { ...@@ -278,7 +300,6 @@ public class HGKCTools {
BeanUtil.copyProperties(o,hgkc003,"id"); BeanUtil.copyProperties(o,hgkc003,"id");
hgkc003.setDepositNo(SequenceGenerator.getNextSequence(HGConstant.SequenceId.PROD_DEPOSIT_NO)); hgkc003.setDepositNo(SequenceGenerator.getNextSequence(HGConstant.SequenceId.PROD_DEPOSIT_NO));
hgkc003.setQualityId(o.getId()); hgkc003.setQualityId(o.getId());
hgkc003.setSubmitStatus(HGConstant.ProductStatus.WTJ);
if(Objects.nonNull(code)){ if(Objects.nonNull(code)){
HGZL004 hgzl004 = hgzl004List.stream().filter(h->h.getCheckId().equals(o.getId())).findAny().orElse(null); HGZL004 hgzl004 = hgzl004List.stream().filter(h->h.getCheckId().equals(o.getId())).findAny().orElse(null);
//整改通知单 //整改通知单
...@@ -306,10 +327,20 @@ public class HGKCTools { ...@@ -306,10 +327,20 @@ public class HGKCTools {
hgkc003.setPrdtWidth(hgpz005.getWidth()); hgkc003.setPrdtWidth(hgpz005.getWidth());
hgkc003.setPrdtThick(hgpz005.getThick()); hgkc003.setPrdtThick(hgpz005.getThick());
hgkc003.setInventTypeDetail(hgpz005.getInventTypeDetail()); hgkc003.setInventTypeDetail(hgpz005.getInventTypeDetail());
//获取仓库信息
HGPZ007 hgpz007 = hgpz007List.stream().filter(wh->wh.getInventTypeDetail() != null && wh.getInventTypeDetail().intValue() == hgpz005.getInventTypeDetail()).findAny().orElse(null);
if(Objects.nonNull(hgpz007)){
hgkc003.setWhCode(hgpz007.getWhCode());
hgkc003.setWhName(hgpz007.getWhName());
}else{
AssertUtils.isNull(hgpz007.getId(), "仓库信息未获取到,请检查仓库档案是否维护存货大类!");
}
hgkc003.setDepositDate(DateUtils.shortDate()); hgkc003.setDepositDate(DateUtils.shortDate());
hgkc003.setStorageType(HGConstant.StorageType.RK); hgkc003.setStorageType(HGConstant.StorageType.RK);
hgkc003.setIsReturn(CommonConstant.YesNo.NO_0); hgkc003.setIsReturn(CommonConstant.YesNo.NO_0);
hgkc003.setDeleteFlag(DeleteFlagEnum.UN_REMOVE.getCode()); hgkc003.setDeleteFlag(DeleteFlagEnum.UN_REMOVE.getCode());
//默认已提交
hgkc003.setSubmitStatus(HGConstant.ProductStatus.YTJ);
hgkc003List.add(hgkc003); hgkc003List.add(hgkc003);
} }
}); });
...@@ -334,6 +365,22 @@ public class HGKCTools { ...@@ -334,6 +365,22 @@ public class HGKCTools {
//赋值 //赋值
setHgkc003Data(hgzl002List,hgkc003List,CheckTypeEnum.PROCESS_CHECK.getCode(),hgzl004List); setHgkc003Data(hgzl002List,hgkc003List,CheckTypeEnum.PROCESS_CHECK.getCode(),hgzl004List);
DaoUtils.insertBatch(HGKC003.INSERT,hgkc003List); DaoUtils.insertBatch(HGKC003.INSERT,hgkc003List);
//查看是否为最后工序,如果最后工序则不需要再进行提交
List<String> inventCodes = hgkc003List.stream().map(HGKC003::getPrdtCode).collect(Collectors.toList());
List<HGPZ005A> hgpz005AList = HGPZTools.HgPz005A.queryByInventCodes(inventCodes);
hgkc003List.forEach(hgkc003->{
//修改计划生产任务完工数量
HGSCTools.complete(hgkc003.getQualityId(),hgkc003.getInvQty().intValue(),hgkc003.getRectificationId(),HGConstant.StorageType.RK);
//查询当前工序
HGPZ005A hgpz005A = hgpz005AList.stream().filter(o -> o.getInventCode().equals(hgkc003.getPrdtCode())).findAny().orElse(null);
//查询比当前工序靠后的工序是否存在,不存在说明是最后工序,修改实时库存
List<HGPZ005A> nextHgpz005AList = hgpz005AList.stream().filter(o->o.getProcessOrder().compareTo(hgpz005A.getProcessOrder()) == 1).collect(Collectors.toList());
if(CollectionUtils.isEmpty(nextHgpz005AList)){
// 修改库存
HGKCUtils.HgKc010.updateInv(hgkc003.getCompanyCode(), hgkc003.getWhCode(), hgkc003.getPrdtCode(),
hgkc003.getInvQty(), hgkc003.getInvWeight());
}
});
} }
} }
......
...@@ -36,6 +36,7 @@ public class HGPZ007 extends DaoEPBase { ...@@ -36,6 +36,7 @@ public class HGPZ007 extends DaoEPBase {
public static final String FIELD_UPDATED_NAME = "updatedName"; /* 修改人名称*/ public static final String FIELD_UPDATED_NAME = "updatedName"; /* 修改人名称*/
public static final String FIELD_UPDATED_TIME = "updatedTime"; /* 修改时间*/ public static final String FIELD_UPDATED_TIME = "updatedTime"; /* 修改时间*/
public static final String FIELD_DELETE_FLAG = "deleteFlag"; /* 是否删除0.否1.是*/ public static final String FIELD_DELETE_FLAG = "deleteFlag"; /* 是否删除0.否1.是*/
public static final String FIELD_INVENT_TYPE_DETAIL = "inventTypeDetail"; /*存货类型明细*/
public static final String COL_ID = "ID"; /* 主键ID*/ public static final String COL_ID = "ID"; /* 主键ID*/
public static final String COL_ACCOUNT_CODE = "ACCOUNT_CODE"; /* 帐套编码*/ public static final String COL_ACCOUNT_CODE = "ACCOUNT_CODE"; /* 帐套编码*/
...@@ -76,6 +77,7 @@ public class HGPZ007 extends DaoEPBase { ...@@ -76,6 +77,7 @@ public class HGPZ007 extends DaoEPBase {
private String updatedName = " "; /* 修改人名称*/ private String updatedName = " "; /* 修改人名称*/
private String updatedTime = " "; /* 修改时间*/ private String updatedTime = " "; /* 修改时间*/
private Integer deleteFlag = 0; /* 是否删除0.否1.是*/ private Integer deleteFlag = 0; /* 是否删除0.否1.是*/
private Integer inventTypeDetail; /*存货类型明细*/
/** /**
* initialize the metadata. * initialize the metadata.
...@@ -144,7 +146,9 @@ public class HGPZ007 extends DaoEPBase { ...@@ -144,7 +146,9 @@ public class HGPZ007 extends DaoEPBase {
eiColumn.setDescName("是否删除0.否1.是"); eiColumn.setDescName("是否删除0.否1.是");
eiMetadata.addMeta(eiColumn); eiMetadata.addMeta(eiColumn);
eiColumn = new EiColumn(FIELD_INVENT_TYPE_DETAIL);
eiColumn.setDescName("存货类型明细");
eiMetadata.addMeta(eiColumn);
} }
/** /**
...@@ -394,6 +398,15 @@ public class HGPZ007 extends DaoEPBase { ...@@ -394,6 +398,15 @@ public class HGPZ007 extends DaoEPBase {
public void setDeleteFlag(Integer deleteFlag) { public void setDeleteFlag(Integer deleteFlag) {
this.deleteFlag = deleteFlag; this.deleteFlag = deleteFlag;
} }
public Integer getInventTypeDetail() {
return inventTypeDetail;
}
public void setInventTypeDetail(Integer inventTypeDetail) {
this.inventTypeDetail = inventTypeDetail;
}
/** /**
* get the value from Map. * get the value from Map.
* *
...@@ -417,6 +430,7 @@ public class HGPZ007 extends DaoEPBase { ...@@ -417,6 +430,7 @@ public class HGPZ007 extends DaoEPBase {
setUpdatedName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_UPDATED_NAME)), updatedName)); setUpdatedName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_UPDATED_NAME)), updatedName));
setUpdatedTime(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_UPDATED_TIME)), updatedTime)); setUpdatedTime(StringUtils.defaultIfEmpty(StringUtils.toString(map.get(FIELD_UPDATED_TIME)), updatedTime));
setDeleteFlag(NumberUtils.toInteger(StringUtils.toString(map.get(FIELD_DELETE_FLAG)), deleteFlag)); setDeleteFlag(NumberUtils.toInteger(StringUtils.toString(map.get(FIELD_DELETE_FLAG)), deleteFlag));
setInventTypeDetail(NumberUtils.toInteger(StringUtils.toString(map.get(FIELD_INVENT_TYPE_DETAIL)), inventTypeDetail));
} }
/** /**
...@@ -441,7 +455,7 @@ public class HGPZ007 extends DaoEPBase { ...@@ -441,7 +455,7 @@ public class HGPZ007 extends DaoEPBase {
map.put(FIELD_UPDATED_NAME, StringUtils.toString(updatedName, eiMetadata.getMeta(FIELD_UPDATED_NAME))); map.put(FIELD_UPDATED_NAME, StringUtils.toString(updatedName, eiMetadata.getMeta(FIELD_UPDATED_NAME)));
map.put(FIELD_UPDATED_TIME, StringUtils.toString(updatedTime, eiMetadata.getMeta(FIELD_UPDATED_TIME))); map.put(FIELD_UPDATED_TIME, StringUtils.toString(updatedTime, eiMetadata.getMeta(FIELD_UPDATED_TIME)));
map.put(FIELD_DELETE_FLAG, StringUtils.toString(deleteFlag, eiMetadata.getMeta(FIELD_DELETE_FLAG))); map.put(FIELD_DELETE_FLAG, StringUtils.toString(deleteFlag, eiMetadata.getMeta(FIELD_DELETE_FLAG)));
map.put(FIELD_INVENT_TYPE_DETAIL,StringUtils.toString(inventTypeDetail, eiMetadata.getMeta(FIELD_INVENT_TYPE_DETAIL)));
return map; return map;
} }
} }
...@@ -68,6 +68,12 @@ ...@@ -68,6 +68,12 @@
<isNotEmpty prepend=" AND " property="deleteFlag"> <isNotEmpty prepend=" AND " property="deleteFlag">
DELETE_FLAG = #deleteFlag# DELETE_FLAG = #deleteFlag#
</isNotEmpty> </isNotEmpty>
<isNotEmpty prepend=" AND " property="inventTypeDetail">
INVENT_TYPE_DETAIL = #inventTypeDetail#
</isNotEmpty>
<isNotEmpty prepend=" AND " property="inventTypeDetails">
INVENT_TYPE_DETAIL IN <iterate close=")" open="(" conjunction="," property="inventTypeDetails">#inventTypeDetails[]#</iterate>
</isNotEmpty>
</sql> </sql>
<!--<sql id="authCondition"> <!--<sql id="authCondition">
...@@ -107,6 +113,7 @@ ...@@ -107,6 +113,7 @@
UPDATED_BY as "updatedBy", <!-- 修改人 --> UPDATED_BY as "updatedBy", <!-- 修改人 -->
UPDATED_NAME as "updatedName", <!-- 修改人名称 --> UPDATED_NAME as "updatedName", <!-- 修改人名称 -->
UPDATED_TIME as "updatedTime", <!-- 修改时间 --> UPDATED_TIME as "updatedTime", <!-- 修改时间 -->
INVENT_TYPE_DETAIL as "inventTypeDetail",
DELETE_FLAG as "deleteFlag" <!-- 是否删除0.否1.是 --> DELETE_FLAG as "deleteFlag" <!-- 是否删除0.否1.是 -->
FROM ${hggpSchema}.HGPZ007 WHERE 1=1 AND DELETE_FLAG = 0 FROM ${hggpSchema}.HGPZ007 WHERE 1=1 AND DELETE_FLAG = 0
<include refid="condition" /> <include refid="condition" />
...@@ -143,6 +150,7 @@ ...@@ -143,6 +150,7 @@
UPDATED_BY as "updatedBy", <!-- 修改人 --> UPDATED_BY as "updatedBy", <!-- 修改人 -->
UPDATED_NAME as "updatedName", <!-- 修改人名称 --> UPDATED_NAME as "updatedName", <!-- 修改人名称 -->
UPDATED_TIME as "updatedTime", <!-- 修改时间 --> UPDATED_TIME as "updatedTime", <!-- 修改时间 -->
INVENT_TYPE_DETAIL as "inventTypeDetail",
DELETE_FLAG as "deleteFlag" <!-- 是否删除0.否1.是 --> DELETE_FLAG as "deleteFlag" <!-- 是否删除0.否1.是 -->
FROM ${hggpSchema}.HGPZ007 WHERE 1=1 AND DELETE_FLAG = 0 FROM ${hggpSchema}.HGPZ007 WHERE 1=1 AND DELETE_FLAG = 0
<include refid="condition" /> <include refid="condition" />
...@@ -220,9 +228,10 @@ ...@@ -220,9 +228,10 @@
UPDATED_BY, <!-- 修改人 --> UPDATED_BY, <!-- 修改人 -->
UPDATED_NAME, <!-- 修改人名称 --> UPDATED_NAME, <!-- 修改人名称 -->
UPDATED_TIME, <!-- 修改时间 --> UPDATED_TIME, <!-- 修改时间 -->
DELETE_FLAG <!-- 是否删除0.否1.是 --> DELETE_FLAG, <!-- 是否删除0.否1.是 -->
INVENT_TYPE_DETAIL
) )
VALUES (#id#, #accountCode#, #depCode#, #whType#, #whCode#, #whName#, #princ#, #status#, #createdBy#, #createdName#, #createdTime#, #updatedBy#, #updatedName#, #updatedTime#, #deleteFlag#) VALUES (#id#, #accountCode#, #depCode#, #whType#, #whCode#, #whName#, #princ#, #status#, #createdBy#, #createdName#, #createdTime#, #updatedBy#, #updatedName#, #updatedTime#, #deleteFlag#, #inventTypeDetail#)
</insert> </insert>
<delete id="delete"> <delete id="delete">
...@@ -245,6 +254,7 @@ ...@@ -245,6 +254,7 @@
UPDATED_BY = #updatedBy#, <!-- 修改人 --> UPDATED_BY = #updatedBy#, <!-- 修改人 -->
UPDATED_NAME = #updatedName#, <!-- 修改人名称 --> UPDATED_NAME = #updatedName#, <!-- 修改人名称 -->
UPDATED_TIME = #updatedTime#, <!-- 修改时间 --> UPDATED_TIME = #updatedTime#, <!-- 修改时间 -->
INVENT_TYPE_DETAIL = #inventTypeDetail#,
DELETE_FLAG = #deleteFlag# <!-- 是否删除0.否1.是 --> DELETE_FLAG = #deleteFlag# <!-- 是否删除0.否1.是 -->
WHERE WHERE
ID = #id# ID = #id#
......
...@@ -178,6 +178,15 @@ public class HGPZTools { ...@@ -178,6 +178,15 @@ public class HGPZTools {
/** /**
* 查询仓库信息 * 查询仓库信息
* *
* @return
*/
public static List<HGPZ007> allList() {
Map queryMap = new HashMap();
return DaoBase.getInstance().query("HGPZ007.query", queryMap);
}
/**
* 查询仓库信息
*
* @param whCodes * @param whCodes
* @return * @return
*/ */
......
...@@ -2,11 +2,9 @@ package com.baosight.hggp.hg.sc.service; ...@@ -2,11 +2,9 @@ package com.baosight.hggp.hg.sc.service;
import com.baosight.hggp.core.constant.CommonConstant; import com.baosight.hggp.core.constant.CommonConstant;
import com.baosight.hggp.core.dao.DaoUtils; import com.baosight.hggp.core.dao.DaoUtils;
import com.baosight.hggp.core.tools.EDTools; import com.baosight.hggp.core.tools.Iplat4jTools;
import com.baosight.hggp.hg.ds.domain.HGDS002;
import com.baosight.hggp.hg.sc.domain.HGSC099; import com.baosight.hggp.hg.sc.domain.HGSC099;
import com.baosight.hggp.hg.sc.tools.HGSCTools; import com.baosight.hggp.hg.sc.tools.HGSCTools;
import com.baosight.hggp.util.FileUtils;
import com.baosight.hggp.util.LogUtils; import com.baosight.hggp.util.LogUtils;
import com.baosight.hggp.util.contants.ACConstants; import com.baosight.hggp.util.contants.ACConstants;
import com.baosight.iplat4j.core.ProjectInfo; import com.baosight.iplat4j.core.ProjectInfo;
...@@ -14,11 +12,9 @@ import com.baosight.iplat4j.core.ei.EiConstant; ...@@ -14,11 +12,9 @@ import com.baosight.iplat4j.core.ei.EiConstant;
import com.baosight.iplat4j.core.ei.EiInfo; import com.baosight.iplat4j.core.ei.EiInfo;
import com.baosight.iplat4j.core.exception.PlatException; import com.baosight.iplat4j.core.exception.PlatException;
import com.baosight.iplat4j.core.service.impl.ServiceEPBase; import com.baosight.iplat4j.core.service.impl.ServiceEPBase;
import com.baosight.iplat4j.core.service.soa.XServiceManager;
import org.springframework.util.CollectionUtils; import org.springframework.util.CollectionUtils;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
...@@ -54,7 +50,7 @@ public class ServiceHGSC003B extends ServiceEPBase { ...@@ -54,7 +50,7 @@ public class ServiceHGSC003B extends ServiceEPBase {
try { try {
// 项目环境 // 项目环境
String projectEnv = ProjectInfo.getProjectEnv(); String projectEnv = ProjectInfo.getProjectEnv();
List<Map<String, Object>> EDCM01List = EDTools.EdCm01.list("hggp.sc.drawingBizType"); List<Map<String, Object>> EDCM01List = Iplat4jTools.EdCm01.list("hggp.sc.drawingBizType");
if(!CollectionUtils.isEmpty(EDCM01List)){ if(!CollectionUtils.isEmpty(EDCM01List)){
List<String> bizTypes = new ArrayList<>(); List<String> bizTypes = new ArrayList<>();
for(Map<String, Object> map : EDCM01List){ for(Map<String, Object> map : EDCM01List){
......
...@@ -447,6 +447,8 @@ public class ServiceHGSC004A extends ServiceBase { ...@@ -447,6 +447,8 @@ public class ServiceHGSC004A extends ServiceBase {
Long id = hgsc004a.getId(); Long id = hgsc004a.getId();
hgsc004a = allHgsc004AList.stream().filter(o -> o.getId().intValue() == id).findAny().orElse(null); hgsc004a = allHgsc004AList.stream().filter(o -> o.getId().intValue() == id).findAny().orElse(null);
submitEntityList.add(hgsc004a); submitEntityList.add(hgsc004a);
//提交校验
checkSubmit(hgsc004a);
} }
if(!CollectionUtils.isEmpty(submitEntityList)){ if(!CollectionUtils.isEmpty(submitEntityList)){
if(Objects.nonNull(hgsc004)){ if(Objects.nonNull(hgsc004)){
...@@ -520,6 +522,76 @@ public class ServiceHGSC004A extends ServiceBase { ...@@ -520,6 +522,76 @@ public class ServiceHGSC004A extends ServiceBase {
return inInfo; return inInfo;
} }
/**
* 修改审核状态
* @param inInfo
* @return
*/
public EiInfo batchApproval(EiInfo inInfo){
int i = 0;
try {
EiBlock eiBlock = inInfo.getBlock(EiConstant.resultBlock);
String materialId = eiBlock.getCellStr(ACConstants.ROW_CODE_0, HGSC004A.FIELD_material_id);
Map<String,Object> queryEntityMap = new HashMap<>();
queryEntityMap.put("materialId",materialId);
List<HGSC004A> allHgsc004AList = dao.query(HGSC004A.QUERY,queryEntityMap, 0, -999999);
for (i = 0; i < eiBlock.getRowCount(); i++) {
Map<?, ?> map = eiBlock.getRow(i);
HGSC004A hgsc004a = new HGSC004A();
//前端传参不完全,但是肯定有id
hgsc004a.fromMap(map);
Long id = hgsc004a.getId();
hgsc004a = allHgsc004AList.stream().filter(o -> o.getId().intValue() == id.intValue()).findAny().orElse(null);
checkApproval(hgsc004a);
hgsc004a.setApprovalStatus(HGConstant.WlApprovalStatu.S_1);
DaoUtils.update(HGSC004A.UPDATE,hgsc004a);
}
inInfo.setStatus(EiConstant.STATUS_SUCCESS);
inInfo.setMsgByKey("ep.1000", new String[]{String.valueOf(i), I18nMessages.getText("label.update", "修改")});
} catch (PlatException e) {
e.printStackTrace();
inInfo.setStatus(EiConstant.STATUS_FAILURE);
ErrorCodeUtils.handleUpdateException(inInfo,i,e);
logError("修改失败", e.getMessage());
return inInfo;
}
return inInfo;
}
/**
* 校验保存的数据
*
* @param hgsc004a
*/
private void checkSubmit(HGSC004A hgsc004a) {
//为构件的需要验证是否已经存在了,不能重复添加
AssertUtils.isEmpty(UserSessionUtils.getAccountCode(), "当前用户未绑定公司,无法操作数据,请联系管理员!");
AssertUtils.isEmpty(UserSessionUtils.getOrgId(), "当前用户未绑定部门,无法操作数据,请联系管理员!");
AssertUtils.isEmpty(hgsc004a.getCompanyCode(), "请选择公司!");
AssertUtils.isEmpty(hgsc004a.getProjCode(), "请填写项目编号!");
AssertUtils.isEmpty(hgsc004a.getProjName(), "请填写项目名称!");
AssertUtils.isTrue(hgsc004a.getSingleWeight().compareTo(BigDecimal.ZERO) <= 0, "单重不能小于等于0!");
AssertUtils.isTrue(hgsc004a.getProductStatus().intValue() == HGConstant.ProductStatus.YTJ, hgsc004a.getProductCode()+"已提交,不能重复!");
AssertUtils.isTrue(hgsc004a.getApprovalStatus().intValue() == HGConstant.WlApprovalStatu.S_0, hgsc004a.getProductCode()+"未审批通过,不能提交!");
}
/**
* 校验保存的数据
*
* @param hgsc004a
*/
private void checkApproval(HGSC004A hgsc004a) {
//为构件的需要验证是否已经存在了,不能重复添加
AssertUtils.isEmpty(UserSessionUtils.getAccountCode(), "当前用户未绑定公司,无法操作数据,请联系管理员!");
AssertUtils.isEmpty(UserSessionUtils.getOrgId(), "当前用户未绑定部门,无法操作数据,请联系管理员!");
AssertUtils.isEmpty(hgsc004a.getCompanyCode(), "请选择公司!");
AssertUtils.isEmpty(hgsc004a.getProjCode(), "请填写项目编号!");
AssertUtils.isEmpty(hgsc004a.getProjName(), "请填写项目名称!");
AssertUtils.isTrue(hgsc004a.getSingleWeight().compareTo(BigDecimal.ZERO) <= 0, "单重不能小于等于0!");
AssertUtils.isTrue(hgsc004a.getProductStatus().intValue() == HGConstant.ProductStatus.YTJ, hgsc004a.getProductCode()+"已提交,不能审核!");
AssertUtils.isTrue(hgsc004a.getApprovalStatus().intValue() == HGConstant.WlApprovalStatu.S_1, hgsc004a.getProductCode()+"已审核,不能重复审核!");
}
private void saveTHGSC005(HGSC004 hgsc004,HGSC004A hgsc004a) { private void saveTHGSC005(HGSC004 hgsc004,HGSC004A hgsc004a) {
//主表 //主表
......
package com.baosight.hggp.hg.sc.service; package com.baosight.hggp.hg.sc.service;
import com.baosight.hggp.common.DdynamicEnum;
import com.baosight.hggp.core.constant.CommonConstant; import com.baosight.hggp.core.constant.CommonConstant;
import com.baosight.hggp.core.dao.DaoUtils; import com.baosight.hggp.core.dao.DaoUtils;
import com.baosight.hggp.core.tools.EDTools; import com.baosight.hggp.core.tools.Iplat4jTools;
import com.baosight.hggp.hg.ds.domain.HGDS002;
import com.baosight.hggp.hg.sc.domain.HGSC099; import com.baosight.hggp.hg.sc.domain.HGSC099;
import com.baosight.hggp.hg.sc.tools.HGSCTools; import com.baosight.hggp.hg.sc.tools.HGSCTools;
import com.baosight.hggp.hg.sj.domain.HGSJ003;
import com.baosight.hggp.util.FileUtils;
import com.baosight.hggp.util.LogUtils; import com.baosight.hggp.util.LogUtils;
import com.baosight.hggp.util.contants.ACConstants; import com.baosight.hggp.util.contants.ACConstants;
import com.baosight.iplat4j.core.ProjectInfo; import com.baosight.iplat4j.core.ProjectInfo;
...@@ -16,11 +12,9 @@ import com.baosight.iplat4j.core.ei.EiConstant; ...@@ -16,11 +12,9 @@ import com.baosight.iplat4j.core.ei.EiConstant;
import com.baosight.iplat4j.core.ei.EiInfo; import com.baosight.iplat4j.core.ei.EiInfo;
import com.baosight.iplat4j.core.exception.PlatException; import com.baosight.iplat4j.core.exception.PlatException;
import com.baosight.iplat4j.core.service.impl.ServiceEPBase; import com.baosight.iplat4j.core.service.impl.ServiceEPBase;
import com.baosight.iplat4j.core.service.soa.XServiceManager;
import org.springframework.util.CollectionUtils; import org.springframework.util.CollectionUtils;
import java.util.*; import java.util.*;
import java.util.stream.Collectors;
/** /**
* @Author wwl * @Author wwl
...@@ -54,7 +48,7 @@ public class ServiceHGSC004B extends ServiceEPBase { ...@@ -54,7 +48,7 @@ public class ServiceHGSC004B extends ServiceEPBase {
try { try {
// 项目环境 // 项目环境
String projectEnv = ProjectInfo.getProjectEnv(); String projectEnv = ProjectInfo.getProjectEnv();
List<Map<String, Object>> EDCM01List = EDTools.EdCm01.list("hggp.sc.bizType"); List<Map<String, Object>> EDCM01List = Iplat4jTools.EdCm01.list("hggp.sc.bizType");
if(!CollectionUtils.isEmpty(EDCM01List)){ if(!CollectionUtils.isEmpty(EDCM01List)){
List<String> bizTypes = new ArrayList<>(); List<String> bizTypes = new ArrayList<>();
for(Map<String, Object> map : EDCM01List){ for(Map<String, Object> map : EDCM01List){
......
package com.baosight.hggp.hg.sc.service; package com.baosight.hggp.hg.sc.service;
import com.baosight.hggp.core.constant.CommonConstant; import com.baosight.hggp.core.constant.CommonConstant;
import com.baosight.hggp.core.dao.DaoUtils; import com.baosight.hggp.core.tools.Iplat4jTools;
import com.baosight.hggp.core.tools.EDTools;
import com.baosight.hggp.hg.ds.domain.HGDS002;
import com.baosight.hggp.hg.sc.domain.HGSC099; import com.baosight.hggp.hg.sc.domain.HGSC099;
import com.baosight.hggp.util.FileUtils;
import com.baosight.hggp.util.LogUtils; import com.baosight.hggp.util.LogUtils;
import com.baosight.hggp.util.contants.ACConstants; import com.baosight.hggp.util.contants.ACConstants;
import com.baosight.iplat4j.core.ProjectInfo; import com.baosight.iplat4j.core.ProjectInfo;
...@@ -13,11 +10,9 @@ import com.baosight.iplat4j.core.ei.EiConstant; ...@@ -13,11 +10,9 @@ import com.baosight.iplat4j.core.ei.EiConstant;
import com.baosight.iplat4j.core.ei.EiInfo; import com.baosight.iplat4j.core.ei.EiInfo;
import com.baosight.iplat4j.core.exception.PlatException; import com.baosight.iplat4j.core.exception.PlatException;
import com.baosight.iplat4j.core.service.impl.ServiceEPBase; import com.baosight.iplat4j.core.service.impl.ServiceEPBase;
import com.baosight.iplat4j.core.service.soa.XServiceManager;
import org.springframework.util.CollectionUtils; import org.springframework.util.CollectionUtils;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
...@@ -53,7 +48,7 @@ public class ServiceHGSC004D extends ServiceEPBase { ...@@ -53,7 +48,7 @@ public class ServiceHGSC004D extends ServiceEPBase {
try { try {
// 项目环境 // 项目环境
String projectEnv = ProjectInfo.getProjectEnv(); String projectEnv = ProjectInfo.getProjectEnv();
List<Map<String, Object>> EDCM01List = EDTools.EdCm01.list("hggp.sc.bizType"); List<Map<String, Object>> EDCM01List = Iplat4jTools.EdCm01.list("hggp.sc.bizType");
if(!CollectionUtils.isEmpty(EDCM01List)){ if(!CollectionUtils.isEmpty(EDCM01List)){
List<String> bizTypes = new ArrayList<>(); List<String> bizTypes = new ArrayList<>();
for(Map<String, Object> map : EDCM01List){ for(Map<String, Object> map : EDCM01List){
......
...@@ -126,7 +126,8 @@ public class ServiceHGSC009A extends ServiceBase { ...@@ -126,7 +126,8 @@ public class ServiceHGSC009A extends ServiceBase {
for (int i = 0; i < resultRows.size(); i++) { for (int i = 0; i < resultRows.size(); i++) {
HGSC009A hgsc009A = new HGSC009A(); HGSC009A hgsc009A = new HGSC009A();
hgsc009A.fromMap(resultRows.get(i)); hgsc009A.fromMap(resultRows.get(i));
//AssertUtils.isNull(hgsc009A.s(), "是否启用不能为空"); AssertUtils.isTrue(hgsc009A.getGrossAmount().compareTo(BigDecimal.ZERO) <= 0, "重量不能小于等于0");
AssertUtils.isTrue(hgsc009A.getQuantity().compareTo(BigDecimal.ZERO) <= 0, "数量不能小于等于0");
} }
} }
...@@ -230,7 +231,7 @@ public class ServiceHGSC009A extends ServiceBase { ...@@ -230,7 +231,7 @@ public class ServiceHGSC009A extends ServiceBase {
} }
} }
// 数据校验 // 数据校验
this.checkInsertcgData(hgsc009AList); this.checkInsertcgData(hgsc009List);
Map<String,List<HGSC009A>> sc009Map = hgsc009AList.stream().collect(Collectors.groupingBy(HGSC009A::getPlanMaterialCode)); Map<String,List<HGSC009A>> sc009Map = hgsc009AList.stream().collect(Collectors.groupingBy(HGSC009A::getPlanMaterialCode));
Map<String, HGPZ005> finalPz005Map = pz005Map; Map<String, HGPZ005> finalPz005Map = pz005Map;
Optional.ofNullable(sc009Map).orElse(new HashMap<>()).forEach((k, v)->{ Optional.ofNullable(sc009Map).orElse(new HashMap<>()).forEach((k, v)->{
...@@ -277,10 +278,10 @@ public class ServiceHGSC009A extends ServiceBase { ...@@ -277,10 +278,10 @@ public class ServiceHGSC009A extends ServiceBase {
return inInfo; return inInfo;
} }
private void checkInsertcgData(List<HGSC009A> hgsc009AList) { private void checkInsertcgData(List<HGSC009> hgsc009List) {
List<Long> materialPlanIds = hgsc009AList.stream().map(HGSC009A::getId).collect(Collectors.toList()); List<Long> materialPlanIds = hgsc009List.stream().map(HGSC009::getId).collect(Collectors.toList());
List<HGCG001> hgcg001List = HGCGTools.HgCg001.listByMaterialPlanIds(materialPlanIds); List<HGCG001> hgcg001List = HGCGTools.HgCg001.listByMaterialPlanIds(materialPlanIds);
hgsc009AList.forEach(o->{ hgsc009List.forEach(o->{
HGCG001 hgcg001 = hgcg001List.stream().filter(c -> c.getMaterialPlanId().intValue() == o.getId()).findAny().orElse(null); HGCG001 hgcg001 = hgcg001List.stream().filter(c -> c.getMaterialPlanId().intValue() == o.getId()).findAny().orElse(null);
AssertUtils.isTrue(Objects.nonNull(hgcg001), String.format("材料计划[%s]已生成采购计划", o.getPlanMaterialCode())); AssertUtils.isTrue(Objects.nonNull(hgcg001), String.format("材料计划[%s]已生成采购计划", o.getPlanMaterialCode()));
}); });
......
...@@ -443,6 +443,7 @@ public class HGSCTools { ...@@ -443,6 +443,7 @@ public class HGSCTools {
AssertUtils.isEmpty(hgsc004a.getProjName(), "请填写项目名称!"); AssertUtils.isEmpty(hgsc004a.getProjName(), "请填写项目名称!");
AssertUtils.isTrue(hgsc004a.getSingleWeight().compareTo(BigDecimal.ZERO) <= 0, "单重不能小于等于0!"); AssertUtils.isTrue(hgsc004a.getSingleWeight().compareTo(BigDecimal.ZERO) <= 0, "单重不能小于等于0!");
} }
} }
public static class THGSC004B{ public static class THGSC004B{
public static void save(HGSC004A oldHGSC004A,HGSC004A newHGSC004A) { public static void save(HGSC004A oldHGSC004A,HGSC004A newHGSC004A) {
......
...@@ -247,6 +247,9 @@ public class ServiceHGZL001 extends ServiceBase { ...@@ -247,6 +247,9 @@ public class ServiceHGZL001 extends ServiceBase {
} }
// 更新收货单状态 // 更新收货单状态
HGCGTools.HgCg003.updateChecks(fZl001s); HGCGTools.HgCg003.updateChecks(fZl001s);
// 质检修改合同状态
HGCGTools.HgCg002.updateChecks(fZl001s);
} }
} }
...@@ -124,7 +124,8 @@ public class ServiceHGZL001B extends ServiceEPBase { ...@@ -124,7 +124,8 @@ public class ServiceHGZL001B extends ServiceEPBase {
for (HGCG003B fCg003B : fCg003Bs) { for (HGCG003B fCg003B : fCg003Bs) {
// 生成新数据 // 生成新数据
HGCG003B dbCg003B = dbCg003BMap.get(fCg003B.getId()); HGCG003B dbCg003B = dbCg003BMap.get(fCg003B.getId());
HGZL001 newZl001 = BeanUtils.copy(dbCg003B, HGZL001.class); HGZL001 newZl001 = new HGZL001();
BeanUtils.copyProperties(dbCg003B, newZl001,"id","createdBy","createdName","createdTime","updatedBy","updatedName","updatedTime");
newZl001.setCheckNo(SequenceGenerator.getNextSequence(HGConstant.SequenceId.HPZL001_NUMBER)); newZl001.setCheckNo(SequenceGenerator.getNextSequence(HGConstant.SequenceId.HPZL001_NUMBER));
newZl001.setReceiptDate(DateUtils.shortDate()); newZl001.setReceiptDate(DateUtils.shortDate());
newZl001.setStatus(CommonConstant.YesNo.NO_0); newZl001.setStatus(CommonConstant.YesNo.NO_0);
......
...@@ -2,6 +2,7 @@ ...@@ -2,6 +2,7 @@
<!DOCTYPE sqlMap PUBLIC "-//iBATIS.com//DTD SQL Map 2.0//EN" "http://www.ibatis.com/dtd/sql-map-2.dtd"> <!DOCTYPE sqlMap PUBLIC "-//iBATIS.com//DTD SQL Map 2.0//EN" "http://www.ibatis.com/dtd/sql-map-2.dtd">
<sqlMap namespace="XS0702"> <sqlMap namespace="XS0702">
<select id="query" resultClass="java.util.HashMap"> <select id="query" resultClass="java.util.HashMap">
SELECT SELECT
tree_ename as "parent", tree_ename as "parent",
...@@ -21,11 +22,9 @@ ...@@ -21,11 +22,9 @@
node_ename not in <iterate close=")" open="(" conjunction="," property="notNodeEnames">#notNodeEnames[]#</iterate> node_ename not in <iterate close=")" open="(" conjunction="," property="notNodeEnames">#notNodeEnames[]#</iterate>
</isNotEmpty> </isNotEmpty>
<!-- 非管理员非root节点仅显示有权限的菜单 added by songx at 20240126 --> <!-- 非管理员非root节点仅显示有权限的菜单 added by songx at 20240126 -->
<isNotEqual property="node" compareValue="root">
<isEqual prepend=" AND " property="isUserAdmin" compareValue="0"> <isEqual prepend=" AND " property="isUserAdmin" compareValue="0">
exists ( exists (
select select c.object_id, d.resource_ename
c. object_id, d.resource_ename
from ${platSchema}.xs_user a, from ${platSchema}.xs_user a,
${platSchema}.xs_user_group_member b, ${platSchema}.xs_user_group_member b,
${platSchema}.xs_authorization c, ${platSchema}.xs_authorization c,
...@@ -35,10 +34,9 @@ ...@@ -35,10 +34,9 @@
and c.object_id = d.id and c.object_id = d.id
and a.login_name = #loginName# and a.login_name = #loginName#
and d.type = 'PAGE' and d.type = 'PAGE'
and m.node_ename = d.resource_ename and find_in_set(d.resource_ename, (select queryMenuPageInfo(m.node_ename)))
) )
</isEqual> </isEqual>
</isNotEqual>
</dynamic> </dynamic>
UNION UNION
SELECT SELECT
......
...@@ -66,7 +66,7 @@ ...@@ -66,7 +66,7 @@
filter="contains"> filter="contains">
</EF:EFComboColumn>--%> </EF:EFComboColumn>--%>
<EF:EFColumn ename="inventRecordId" cname="规格ID" width="80" enable="true" readonly="false" hidden="true" align="center"/> <EF:EFColumn ename="inventRecordId" cname="规格ID" width="80" enable="true" readonly="false" hidden="true" align="center"/>
<EF:EFColumn ename="initQuantity" cname="期初数量" width="100" enable="true" format="{0:N0}" editType="text" <EF:EFColumn ename="initQuantity" cname="期初数量" width="100" enable="true" format="{0:N3}" editType="text"
displayType="0" sort="true" align="right" maxLength="15" required="false" defaultValue="0" displayType="0" sort="true" align="right" maxLength="15" required="false" defaultValue="0"
data-regex="/^-?[0-9]{1,15}?$/" data-regex="/^-?[0-9]{1,15}?$/"
data-errorprompt="请输入数字,该值最大可设置15位整数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数!"/>
...@@ -74,7 +74,7 @@ ...@@ -74,7 +74,7 @@
displayType="0.000" sort="true" align="right" maxLength="15" required="false" defaultValue="0" displayType="0.000" sort="true" align="right" maxLength="15" required="false" defaultValue="0"
data-regex="/^-?[0-9]{1,15}([.][0-9]{1,3})?$/" data-regex="/^-?[0-9]{1,15}([.][0-9]{1,3})?$/"
data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/>
<EF:EFColumn ename="enterQuantity" cname="入库数量" width="100" enable="true" format="{0:N0}" editType="text" <EF:EFColumn ename="enterQuantity" cname="入库数量" width="100" enable="true" format="{0:N3}" editType="text"
displayType="0.000" sort="true" align="right" maxLength="15" required="false" defaultValue="0" displayType="0.000" sort="true" align="right" maxLength="15" required="false" defaultValue="0"
data-regex="/^-?[0-9]{1,15}?$/" data-regex="/^-?[0-9]{1,15}?$/"
data-errorprompt="请输入数字,该值最大可设置15位整数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数!"/>
...@@ -82,7 +82,7 @@ ...@@ -82,7 +82,7 @@
displayType="0.000" sort="true" align="right" maxLength="15" required="false" defaultValue="0" displayType="0.000" sort="true" align="right" maxLength="15" required="false" defaultValue="0"
data-regex="/^-?[0-9]{1,15}([.][0-9]{1,3})?$/" data-regex="/^-?[0-9]{1,15}([.][0-9]{1,3})?$/"
data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/>
<EF:EFColumn ename="outerQuantity" cname="出库数量" width="100" enable="true" format="{0:N0}" editType="text" <EF:EFColumn ename="outerQuantity" cname="出库数量" width="100" enable="true" format="{0:N3}" editType="text"
displayType="0.000" sort="true" align="right" maxLength="15" required="false" defaultValue="0" displayType="0.000" sort="true" align="right" maxLength="15" required="false" defaultValue="0"
data-regex="/^-?[0-9]{1,15}?$/" data-regex="/^-?[0-9]{1,15}?$/"
data-errorprompt="请输入数字,该值最大可设置15位整数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数!"/>
...@@ -90,7 +90,7 @@ ...@@ -90,7 +90,7 @@
displayType="0.000" sort="true" align="right" maxLength="17" required="false" defaultValue="0" displayType="0.000" sort="true" align="right" maxLength="17" required="false" defaultValue="0"
data-regex="/^-?[0-9]{1,15}([.][0-9]{1,3})?$/" data-regex="/^-?[0-9]{1,15}([.][0-9]{1,3})?$/"
data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/>
<EF:EFColumn ename="endQuantity" cname="期末数量" width="100" enable="true" format="{0:N0}" editType="text" <EF:EFColumn ename="endQuantity" cname="期末数量" width="100" enable="true" format="{0:N3}" editType="text"
displayType="0.000" sort="true" align="right" maxLength="15" required="false" defaultValue="0" displayType="0.000" sort="true" align="right" maxLength="15" required="false" defaultValue="0"
data-regex="/^-?[0-9]{1,15}?$/" data-regex="/^-?[0-9]{1,15}?$/"
data-errorprompt="请输入数字,该值最大可设置15位整数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数!"/>
......
...@@ -40,7 +40,7 @@ ...@@ -40,7 +40,7 @@
<EF:EFComboColumn ename="status" cname="状态" enable="false" width="80" align="center"> <EF:EFComboColumn ename="status" cname="状态" enable="false" width="80" align="center">
<EF:EFCodeOption codeName="hggp.hgcg.planStatus"/> <EF:EFCodeOption codeName="hggp.hgcg.planStatus"/>
</EF:EFComboColumn> </EF:EFComboColumn>
<EF:EFColumn ename="purQty" cname="采购数量" enable="false" width="120" align="right" format="{0:N0}" /> <EF:EFColumn ename="purQty" cname="采购数量" enable="false" width="120" align="right" format="{0:N3}" />
<EF:EFColumn ename="purWeight" cname="采购重量" enable="false" width="120" align="right" format="{0:N3}" /> <EF:EFColumn ename="purWeight" cname="采购重量" enable="false" width="120" align="right" format="{0:N3}" />
<EF:EFColumn ename="planWeight" cname="计划重量" enable="false" width="120" align="right" format="{0:N3}"/> <EF:EFColumn ename="planWeight" cname="计划重量" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="createdName" cname="创建人" enable="false" width="100" align="center"/> <EF:EFColumn ename="createdName" cname="创建人" enable="false" width="100" align="center"/>
......
...@@ -33,7 +33,7 @@ ...@@ -33,7 +33,7 @@
<EF:EFColumn ename="inventCode" cname="存货编码" enable="false" width="100" align="center"/> <EF:EFColumn ename="inventCode" cname="存货编码" enable="false" width="100" align="center"/>
<EF:EFColumn ename="inventName" cname="存货名称" enable="false" width="100" align="center"/> <EF:EFColumn ename="inventName" cname="存货名称" enable="false" width="100" align="center"/>
<EF:EFColumn ename="spec" cname="规格" enable="false" width="120" align="center"/> <EF:EFColumn ename="spec" cname="规格" enable="false" width="120" align="center"/>
<EF:EFColumn ename="purQty" cname="采购数量" width="120" align="right" format="{0:N0}" required="true"/> <EF:EFColumn ename="purQty" cname="采购数量" width="120" align="right" format="{0:N3}" required="true"/>
<EF:EFColumn ename="purWeight" cname="采购重量" width="120" align="right" format="{0:N3}" required="true"/> <EF:EFColumn ename="purWeight" cname="采购重量" width="120" align="right" format="{0:N3}" required="true"/>
<EF:EFColumn ename="planWeight" cname="计划重量" enable="false" width="120" align="right" format="{0:N3}"/> <EF:EFColumn ename="planWeight" cname="计划重量" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="material" cname="材质" enable="false" width="80" align="center"/> <EF:EFColumn ename="material" cname="材质" enable="false" width="80" align="center"/>
......
...@@ -52,9 +52,9 @@ ...@@ -52,9 +52,9 @@
</EF:EFComboColumn> </EF:EFComboColumn>
<EF:EFColumn ename="supName" cname="供应商名称" enable="false" width="120" align="center" hidden="true"/> <EF:EFColumn ename="supName" cname="供应商名称" enable="false" width="120" align="center" hidden="true"/>
<EF:EFColumn ename="purUserName" cname="采购员" width="120" align="center" required="true"/> <EF:EFColumn ename="purUserName" cname="采购员" width="120" align="center" required="true"/>
<EF:EFColumn ename="purQty" cname="采购数量" width="120" align="right" format="{0:N0}" enable="false"/> <EF:EFColumn ename="purQty" cname="采购数量" width="120" align="right" format="{0:N3}" enable="false"/>
<EF:EFColumn ename="purWeight" cname="采购重量" width="120" align="right" format="{0:N3}" enable="false"/> <EF:EFColumn ename="purWeight" cname="采购重量" width="120" align="right" format="{0:N3}" enable="false"/>
<EF:EFColumn ename="receiveQty" cname="已收货数量" enable="false" width="120" align="right" format="{0:N0}"/> <EF:EFColumn ename="receiveQty" cname="已收货数量" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="amount" cname="不含税金额" enable="false" width="80" align="right" format="{0:N3}"/> <EF:EFColumn ename="amount" cname="不含税金额" enable="false" width="80" align="right" format="{0:N3}"/>
<EF:EFColumn ename="taxAmount" cname="税额" enable="false" width="80" align="right" format="{0:N3}"/> <EF:EFColumn ename="taxAmount" cname="税额" enable="false" width="80" align="right" format="{0:N3}"/>
<EF:EFColumn ename="taxIncludeAmount" cname="含税金额" enable="false" width="80" align="right" format="{0:N3}"/> <EF:EFColumn ename="taxIncludeAmount" cname="含税金额" enable="false" width="80" align="right" format="{0:N3}"/>
......
...@@ -33,7 +33,7 @@ ...@@ -33,7 +33,7 @@
<EF:EFColumn ename="inventCode" cname="存货编码" enable="false" width="100" align="center"/> <EF:EFColumn ename="inventCode" cname="存货编码" enable="false" width="100" align="center"/>
<EF:EFColumn ename="inventName" cname="存货名称" enable="false" width="100" align="center"/> <EF:EFColumn ename="inventName" cname="存货名称" enable="false" width="100" align="center"/>
<EF:EFColumn ename="spec" cname="规格" enable="false" width="120" align="center"/> <EF:EFColumn ename="spec" cname="规格" enable="false" width="120" align="center"/>
<EF:EFColumn ename="purQty" cname="采购数量" width="120" align="right" format="{0:N0}" enable="false"/> <EF:EFColumn ename="purQty" cname="采购数量" width="120" align="right" format="{0:N3}" enable="false"/>
<EF:EFColumn ename="purWeight" cname="采购重量" width="120" align="right" format="{0:N3}" enable="false"/> <EF:EFColumn ename="purWeight" cname="采购重量" width="120" align="right" format="{0:N3}" enable="false"/>
<EF:EFColumn ename="price" cname="单价" width="80" align="right" format="{0:N3}" required="true"/> <EF:EFColumn ename="price" cname="单价" width="80" align="right" format="{0:N3}" required="true"/>
<EF:EFComboColumn ename="taxRate" cname="税率(%)" enable="true" width="80" align="center" required="true"> <EF:EFComboColumn ename="taxRate" cname="税率(%)" enable="true" width="80" align="center" required="true">
......
...@@ -23,9 +23,9 @@ ...@@ -23,9 +23,9 @@
<EF:EFColumn ename="inventCode" cname="存货编码" enable="false" width="100" align="center"/> <EF:EFColumn ename="inventCode" cname="存货编码" enable="false" width="100" align="center"/>
<EF:EFColumn ename="inventName" cname="存货名称" enable="false" width="100" align="center"/> <EF:EFColumn ename="inventName" cname="存货名称" enable="false" width="100" align="center"/>
<EF:EFColumn ename="spec" cname="规格" enable="false" width="120" align="center"/> <EF:EFColumn ename="spec" cname="规格" enable="false" width="120" align="center"/>
<EF:EFColumn ename="purQty" cname="采购数量" width="120" align="right" format="{0:N0}" enable="false"/> <EF:EFColumn ename="purQty" cname="采购数量" width="120" align="right" format="{0:N3}" enable="false"/>
<EF:EFColumn ename="purWeight" cname="采购重量" width="120" align="right" format="{0:N3}" enable="false"/> <EF:EFColumn ename="purWeight" cname="采购重量" width="120" align="right" format="{0:N3}" enable="false"/>
<EF:EFColumn ename="receiveQty" cname="已收货数量" enable="false" width="120" align="right" format="{0:N0}"/> <EF:EFColumn ename="receiveQty" cname="已收货数量" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="price" cname="单价" width="80" align="right" format="{0:N3}" required="true"/> <EF:EFColumn ename="price" cname="单价" width="80" align="right" format="{0:N3}" required="true"/>
<EF:EFComboColumn ename="taxRate" cname="税率(%)" enable="true" width="80" align="center" required="true"> <EF:EFComboColumn ename="taxRate" cname="税率(%)" enable="true" width="80" align="center" required="true">
<EF:EFCodeOption codeName="hggp.cw.taxPoints" /> <EF:EFCodeOption codeName="hggp.cw.taxPoints" />
......
...@@ -82,7 +82,22 @@ $(function () { ...@@ -82,7 +82,22 @@ $(function () {
let item = e.model; let item = e.model;
//只有合同生成的不能编辑 //只有合同生成的不能编辑
if(item.source === '0'){ if(item.source === '0'){
e.preventDefault(); //选择收货的指定列可以修改
for (let i = 0; i < e.sender.columns.length; i++) {
//指定的列不让修改
if (e.sender.columns[i]["name"] === "companyCode") {
e.sender.columns[i]["enable"] = false;
e.sender.columns[i]["readonly"] = true;
}
if (e.sender.columns[i]["name"] === "supCode") {
e.sender.columns[i]["enable"] = false;
e.sender.columns[i]["readonly"] = true;
}
if (e.sender.columns[i]["name"] === "purUserName") {
e.sender.columns[i]["enable"] = false;
e.sender.columns[i]["readonly"] = true;
}
}
} }
}, },
loadComplete: function (grid) { loadComplete: function (grid) {
......
...@@ -67,9 +67,9 @@ ...@@ -67,9 +67,9 @@
</EF:EFComboColumn> </EF:EFComboColumn>
<EF:EFColumn ename="supName" cname="供应商名称" enable="false" width="120" align="center" hidden="true"/> <EF:EFColumn ename="supName" cname="供应商名称" enable="false" width="120" align="center" hidden="true"/>
<EF:EFColumn ename="purUserName" cname="采购员" width="120" align="center" required="true"/> <EF:EFColumn ename="purUserName" cname="采购员" width="120" align="center" required="true"/>
<EF:EFColumn ename="receiveQty" cname="收货数量" enable="false" width="120" align="right" format="{0:N0}"/> <EF:EFColumn ename="receiveQty" cname="收货数量" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="deliverQty" cname="退货数量" enable="false" width="120" align="right" format="{0:N0}"/> <EF:EFColumn ename="deliverQty" cname="退货数量" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="depositQty" cname="入库数量" enable="false" width="120" align="right" format="{0:N0}"/> <EF:EFColumn ename="depositQty" cname="入库数量" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="receiveWeight" cname="收货重量" enable="false" width="120" align="right" format="{0:N3}"/> <EF:EFColumn ename="receiveWeight" cname="收货重量" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="amount" cname="金额" enable="false" width="80" align="right" format="{0:N3}"/> <EF:EFColumn ename="amount" cname="金额" enable="false" width="80" align="right" format="{0:N3}"/>
<EF:EFColumn ename="createdName" cname="创建人" enable="false" width="100" align="center"/> <EF:EFColumn ename="createdName" cname="创建人" enable="false" width="100" align="center"/>
......
...@@ -55,12 +55,12 @@ ...@@ -55,12 +55,12 @@
<EF:EFColumn ename="inventName" cname="存货名称" enable="false" width="100" align="center"/> <EF:EFColumn ename="inventName" cname="存货名称" enable="false" width="100" align="center"/>
<EF:EFColumn ename="inventRecordId" cname="规格ID" enable="false" width="100" align="center" hidden="true"/> <EF:EFColumn ename="inventRecordId" cname="规格ID" enable="false" width="100" align="center" hidden="true"/>
<EF:EFColumn ename="spec" cname="规格" enable="false" width="120" align="center"/> <EF:EFColumn ename="spec" cname="规格" enable="false" width="120" align="center"/>
<EF:EFColumn ename="bcReceiveQty" cname="本次</br>收货数量" width="100" align="right" format="{0:N0}" <EF:EFColumn ename="bcReceiveQty" cname="本次</br>收货数量" width="100" align="right" format="{0:N3}"
required="true"/> required="true"/>
<EF:EFColumn ename="bcMaxReceiveQty" cname="本次最大</br>收货数量" enable="false" width="100" align="right" <EF:EFColumn ename="bcMaxReceiveQty" cname="本次最大</br>收货数量" enable="false" width="100" align="right"
format="{0:N0}"/> format="{0:N3}"/>
<EF:EFColumn ename="receiveQty" cname="已收货数量" enable="false" width="100" align="right" format="{0:N0}"/> <EF:EFColumn ename="receiveQty" cname="已收货数量" enable="false" width="100" align="right" format="{0:N3}"/>
<EF:EFColumn ename="purQty" cname="采购数量" enable="false" width="100" align="right" format="{0:N0}"/> <EF:EFColumn ename="purQty" cname="采购数量" enable="false" width="100" align="right" format="{0:N3}"/>
<EF:EFColumn ename="purWeight" cname="采购重量" enable="false" width="100" align="right" format="{0:N3}"/> <EF:EFColumn ename="purWeight" cname="采购重量" enable="false" width="100" align="right" format="{0:N3}"/>
<EF:EFComboColumn ename="supCode" cname="供应商名称" enable="false" width="120" align="left" defaultValue="" <EF:EFComboColumn ename="supCode" cname="供应商名称" enable="false" width="120" align="left" defaultValue=""
filter="contains"> filter="contains">
......
...@@ -26,9 +26,9 @@ ...@@ -26,9 +26,9 @@
<EF:EFColumn ename="inventTypeDetail" cname="存货类型大类" hidden="true"/> <EF:EFColumn ename="inventTypeDetail" cname="存货类型大类" hidden="true"/>
<EF:EFColumn ename="specId" cname="规格ID" enable="false" width="100" align="center" hidden="true"/> <EF:EFColumn ename="specId" cname="规格ID" enable="false" width="100" align="center" hidden="true"/>
<EF:EFColumn ename="spec" cname="规格" enable="false" width="120" align="center"/> <EF:EFColumn ename="spec" cname="规格" enable="false" width="120" align="center"/>
<EF:EFColumn ename="receiveQty" cname="收货数量" width="120" align="right" format="{0:N0}" required="true"/> <EF:EFColumn ename="receiveQty" cname="收货数量" width="120" align="right" format="{0:N3}" required="true"/>
<EF:EFColumn ename="deliverQty" cname="退货数量" enable="false" width="120" align="right" format="{0:N0}"/> <EF:EFColumn ename="deliverQty" cname="退货数量" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="depositQty" cname="入库数量" enable="false" width="120" align="right" format="{0:N0}"/> <EF:EFColumn ename="depositQty" cname="入库数量" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="receiveWeight" cname="收货重量" enable="false" width="120" align="right" format="{0:N3}"/> <EF:EFColumn ename="receiveWeight" cname="收货重量" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="receiveUnitWeight" cname="收货单重" enable="false" width="120" align="right" format="{0:N3}" hidden="true"/> <EF:EFColumn ename="receiveUnitWeight" cname="收货单重" enable="false" width="120" align="right" format="{0:N3}" hidden="true"/>
<EF:EFColumn ename="price" cname="单价" width="80" align="right" format="{0:N3}" required="true"/> <EF:EFColumn ename="price" cname="单价" width="80" align="right" format="{0:N3}" required="true"/>
......
$(function () {
// 提交
$("#SUBMIT").on("click", submit);
});
/**
* 页面加载时执行
*/
$(window).load(function () {
// 显示下载模版按钮
let templateUrl = $("#inqu_status-0-templateUrl").val();
if (!isBlank(templateUrl)) {
$("#templateUrl").attr('href', IPLATUI.CONTEXT_PATH + templateUrl);
$("#templateDiv").show();
}
});
/**
* 提交
*/
let submit = function () {
let file = $("#inqu_status-0-file")[0].files[0];
if (isBlank(file)) {
message("请选择文件");
return;
}
var suffix = file.name.substr(file.name.lastIndexOf("."));
if (".xls" != suffix && ".xlsx" != suffix) {
message("请选择Excel格式的文件导入");
return false;
}
let _IPLAT = IPLAT;
_IPLAT.progress($("body"), true);
let formData = new FormData();
formData.append("id", $("#inqu_status-0-id").val());
formData.append("parameter", $("#inqu_status-0-parameter").val());
formData.append("file", file);
$.ajax({
url: IPLATUI.CONTEXT_PATH + '/doc/import/api',
type: 'POST',
data: formData,
async: true,
cache: false,
contentType: false,
processData: false,
success: function (res) {
_IPLAT.progress($("body"), false);
message(res.msg);
if (res.status != -1) {
parent.JSColorbox.setValueCallback(res);
}
},
error: function (res) {
_IPLAT.progress($("body"), false);
message(res.msg);
}
});
}
/**
* 判断是否为null
*
* @param value
* @returns {boolean}
*/
function isBlank(data) {
return data == null || data === undefined || data === 'null' || $.trim(data) === '' ||
data === 'undefined' || data === 'unknown';
}
/**
* 消息提示
*
* @param msg
*/
function message(msg) {
WindowUtil({
title: "提示:",
content: "<div class='kendo-del-message'>" + msg + "</div>"
});
};
<!DOCTYPE html>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="EF" tagdir="/WEB-INF/tags/EF" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<c:set var="ctx" value="${pageContext.request.contextPath}"/>
<EF:EFPage title="导入">
<EF:EFRegion id="inqu" title="文件区域">
<div class="row">
<EF:EFInput cname="参数" blockId="inqu_status" ename="parameter" row="0" colWidth="12" type="hidden"/>
<EF:EFInput cname="路由ID" blockId="inqu_status" ename="id" row="0" colWidth="12" type="hidden"/>
<EF:EFInput cname="模版地址" blockId="inqu_status" ename="templateUrl" row="0" colWidth="12" type="hidden"/>
<EF:EFInput cname="导入文件" blockId="inqu_status" ename="file" row="0" colWidth="12" ratio="2:10" type="file"/>
</div>
<div id="templateDiv" class="row" style="display: none;text-align: right;padding-right: 25px;">
<a id="templateUrl" href="">下载模版</a>
</div>
</EF:EFRegion>
<EF:EFRegion title="提示">
<span style='color: red;font-size: 12px;'>
1.请选择xls或xlsx格式的excel文件
</span>
</EF:EFRegion>
</EF:EFPage>
...@@ -62,7 +62,7 @@ ...@@ -62,7 +62,7 @@
<EF:EFColumn ename="inventName" cname="存货名称" enable="false" width="100" align="center"/> <EF:EFColumn ename="inventName" cname="存货名称" enable="false" width="100" align="center"/>
<EF:EFColumn ename="specId" cname="规格ID" enable="false" width="100" align="center" hidden="true"/> <EF:EFColumn ename="specId" cname="规格ID" enable="false" width="100" align="center" hidden="true"/>
<EF:EFColumn ename="spec" cname="规格" enable="false" width="120" align="center"/> <EF:EFColumn ename="spec" cname="规格" enable="false" width="120" align="center"/>
<EF:EFColumn ename="depositQty" cname="入库数量" enable="false" width="120" align="right" format="{0:N0}"/> <EF:EFColumn ename="depositQty" cname="入库数量" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="depositWeight" cname="入库重量" enable="false" width="120" align="right" format="{0:N3}"/> <EF:EFColumn ename="depositWeight" cname="入库重量" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="material" cname="材质" enable="false" width="80" align="center"/> <EF:EFColumn ename="material" cname="材质" enable="false" width="80" align="center"/>
<EF:EFColumn ename="unit" cname="单位" enable="false" width="80" align="center"/> <EF:EFColumn ename="unit" cname="单位" enable="false" width="80" align="center"/>
......
...@@ -59,9 +59,9 @@ ...@@ -59,9 +59,9 @@
<EF:EFColumn ename="inventName" cname="存货名称" enable="false" width="100" align="center"/> <EF:EFColumn ename="inventName" cname="存货名称" enable="false" width="100" align="center"/>
<EF:EFColumn ename="specId" cname="规格ID" enable="false" width="100" align="center" hidden="true"/> <EF:EFColumn ename="specId" cname="规格ID" enable="false" width="100" align="center" hidden="true"/>
<EF:EFColumn ename="spec" cname="规格" enable="false" width="120" align="center"/> <EF:EFColumn ename="spec" cname="规格" enable="false" width="120" align="center"/>
<EF:EFColumn ename="receiveQty" cname="收货数量" enable="false" width="120" align="right" format="{0:N0}"/> <EF:EFColumn ename="receiveQty" cname="收货数量" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="deliverQty" cname="退货数量" enable="false" width="120" align="right" format="{0:N0}"/> <EF:EFColumn ename="deliverQty" cname="退货数量" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="depositQty" cname="入库数量" enable="false" width="120" align="right" format="{0:N0}"/> <EF:EFColumn ename="depositQty" cname="入库数量" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="receiveWeight" cname="收货重量" enable="false" width="120" align="right" format="{0:N3}"/> <EF:EFColumn ename="receiveWeight" cname="收货重量" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="material" cname="材质" enable="false" width="80" align="center"/> <EF:EFColumn ename="material" cname="材质" enable="false" width="80" align="center"/>
<EF:EFColumn ename="unit" cname="单位" enable="false" width="80" align="center"/> <EF:EFColumn ename="unit" cname="单位" enable="false" width="80" align="center"/>
......
...@@ -64,7 +64,7 @@ ...@@ -64,7 +64,7 @@
<EF:EFComboColumn ename="specId" cname="规格" enable="false" width="120" align="center" <EF:EFComboColumn ename="specId" cname="规格" enable="false" width="120" align="center"
blockName="spec_record_block_id" textField="textField" valueField="valueField"> blockName="spec_record_block_id" textField="textField" valueField="valueField">
</EF:EFComboColumn> </EF:EFComboColumn>
<EF:EFColumn ename="applyQty" cname="数量" enable="false" width="100" align="right" format="{0:N0}"/> <EF:EFColumn ename="applyQty" cname="数量" enable="false" width="100" align="right" format="{0:N3}"/>
<EF:EFColumn ename="unitWeight" cname="单重(KG)" enable="false" width="100" align="right" format="{0:N3}"/> <EF:EFColumn ename="unitWeight" cname="单重(KG)" enable="false" width="100" align="right" format="{0:N3}"/>
<EF:EFColumn ename="applyWeight" cname="总重(KG)" enable="false" width="100" align="right" format="{0:N3}"/> <EF:EFColumn ename="applyWeight" cname="总重(KG)" enable="false" width="100" align="right" format="{0:N3}"/>
<EF:EFColumn ename="remark" cname="备注" enable="false" width="100" align="center"/> <EF:EFColumn ename="remark" cname="备注" enable="false" width="100" align="center"/>
......
...@@ -48,9 +48,9 @@ ...@@ -48,9 +48,9 @@
<EF:EFComboColumn ename="specId" cname="规格" enable="false" width="150" align="center" <EF:EFComboColumn ename="specId" cname="规格" enable="false" width="150" align="center"
blockName="spec_record_block_id" textField="textField" valueField="valueField"> blockName="spec_record_block_id" textField="textField" valueField="valueField">
</EF:EFComboColumn> </EF:EFComboColumn>
<EF:EFColumn ename="applyQty" cname="申请数量" width="120" align="right" format="{0:N0}" required="true"/> <EF:EFColumn ename="applyQty" cname="申请数量" width="120" align="right" format="{0:N3}" required="true"/>
<EF:EFColumn ename="applyRemark" cname="申请说明" width="200" editType="textarea" copy="true"/> <EF:EFColumn ename="applyRemark" cname="申请说明" width="200" editType="textarea" copy="true"/>
<EF:EFColumn ename="invQty" cname="库存数量" enable="false" width="120" align="right" format="{0:N0}" <EF:EFColumn ename="invQty" cname="库存数量" enable="false" width="120" align="right" format="{0:N3}"
sumType="all"/> sumType="all"/>
<EF:EFColumn ename="invUnitWeight" cname="单量(KG)" enable="false" width="120" align="right" format="{0:N3}"/> <EF:EFColumn ename="invUnitWeight" cname="单量(KG)" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="invWeight" cname="库存重量(KG)" enable="false" width="120" align="right" format="{0:N3}" <EF:EFColumn ename="invWeight" cname="库存重量(KG)" enable="false" width="120" align="right" format="{0:N3}"
......
...@@ -50,7 +50,7 @@ ...@@ -50,7 +50,7 @@
<EF:EFColumn ename="prdtWidth" cname="宽(MM)" enable="false" width="80" align="right" format="{0:N3}"/> <EF:EFColumn ename="prdtWidth" cname="宽(MM)" enable="false" width="80" align="right" format="{0:N3}"/>
<EF:EFColumn ename="prdtThick" cname="厚(MM)" enable="false" width="80" align="right" format="{0:N3}"/> <EF:EFColumn ename="prdtThick" cname="厚(MM)" enable="false" width="80" align="right" format="{0:N3}"/>
<EF:EFColumn ename="prdtCoefficient" cname="系数" enable="false" width="80" align="right" format="{0:N3}"/> <EF:EFColumn ename="prdtCoefficient" cname="系数" enable="false" width="80" align="right" format="{0:N3}"/>
<EF:EFColumn ename="invQty" cname="数量" width="120" align="right" format="{0:N0}" <EF:EFColumn ename="invQty" cname="数量" width="120" align="right" format="{0:N3}"
defaultValue="0" defaultValue="0"
data-regex="/^-?[0-9]{1,17}([.][0-9]{1,3})?$/" data-regex="/^-?[0-9]{1,17}([.][0-9]{1,3})?$/"
data-errorprompt="请输入数字,该值最大可设置17位整数和3位小数!" data-errorprompt="请输入数字,该值最大可设置17位整数和3位小数!"
......
...@@ -32,12 +32,12 @@ ...@@ -32,12 +32,12 @@
<EF:EFColumn ename="prdtName" cname="物料名称" enable="false" width="120" align="center"/> <EF:EFColumn ename="prdtName" cname="物料名称" enable="false" width="120" align="center"/>
<EF:EFColumn ename="prdtSpec" cname="物料规格" enable="false" width="150" align="center"/> <EF:EFColumn ename="prdtSpec" cname="物料规格" enable="false" width="150" align="center"/>
<EF:EFColumn ename="whCode" cname="仓库名称" width="120" align="center" required="true"/> <EF:EFColumn ename="whCode" cname="仓库名称" width="120" align="center" required="true"/>
<EF:EFColumn ename="applyNum" cname="入库数量" width="120" align="right" format="{0:N0}" required="true"/> <EF:EFColumn ename="applyNum" cname="入库数量" width="120" align="right" format="{0:N3}" required="true"/>
<EF:EFColumn ename="remark1" cname="入库说明" width="150"/> <EF:EFColumn ename="remark1" cname="入库说明" width="150"/>
<EF:EFColumn ename="completeNum" cname="已入库数量" enable="false" width="120" align="right" format="{0:N0}" <EF:EFColumn ename="completeNum" cname="已入库数量" enable="false" width="120" align="right" format="{0:N3}"
hidden="true"/> hidden="true"/>
<EF:EFColumn ename="unCompleteNum" cname="待入库数量" enable="false" width="120" align="right" format="{0:N0}"/> <EF:EFColumn ename="unCompleteNum" cname="待入库数量" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="num" cname="任务数量" enable="false" width="120" align="right" format="{0:N0}"/> <EF:EFColumn ename="num" cname="任务数量" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="totalWt" cname="任务重量(KG)" enable="false" width="120" align="right" format="{0:N3}"/> <EF:EFColumn ename="totalWt" cname="任务重量(KG)" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="factoryName" cname="工厂" enable="false" width="150" align="center"/> <EF:EFColumn ename="factoryName" cname="工厂" enable="false" width="150" align="center"/>
<EF:EFColumn ename="orgName" cname="生产组名称" enable="false" width="150" align="center"/> <EF:EFColumn ename="orgName" cname="生产组名称" enable="false" width="150" align="center"/>
......
...@@ -25,10 +25,10 @@ ...@@ -25,10 +25,10 @@
<EF:EFCodeOption codeName="hggp.sc.storageType" /> <EF:EFCodeOption codeName="hggp.sc.storageType" />
</EF:EFComboColumn> </EF:EFComboColumn>
<EF:EFColumn ename="prdtSpec" cname="规格" enable="false" width="140" align="center"/> <EF:EFColumn ename="prdtSpec" cname="规格" enable="false" width="140" align="center"/>
<EF:EFColumn ename="prdtLength" cname="长度(MM)" enable="false" width="120" align="right" format="{0:N0}"/> <EF:EFColumn ename="prdtLength" cname="长度(MM)" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="prdtWidth" cname="宽度(MM)" enable="false" width="120" align="right" format="{0:N0}"/> <EF:EFColumn ename="prdtWidth" cname="宽度(MM)" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="prdtThick" cname="厚度(MM)" enable="false" width="120" align="right" format="{0:N0}"/> <EF:EFColumn ename="prdtThick" cname="厚度(MM)" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="invQty" cname="数量" enable="false" width="120" align="right" format="{0:N0}"/> <EF:EFColumn ename="invQty" cname="数量" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="invUnitWeight" cname="单重(KG)" enable="false" width="120" align="right" format="{0:N3}"/> <EF:EFColumn ename="invUnitWeight" cname="单重(KG)" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="invWeight" cname="总重(KG)" enable="false" width="120" align="right" format="{0:N3}"/> <EF:EFColumn ename="invWeight" cname="总重(KG)" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="price" cname="单价" enable="false" width="120" align="right" format="{0:N3}"/> <EF:EFColumn ename="price" cname="单价" enable="false" width="120" align="right" format="{0:N3}"/>
......
...@@ -49,7 +49,7 @@ ...@@ -49,7 +49,7 @@
<EF:EFColumn ename="length" cname="长度(MM)" enable="true" readonly="true" width="100" align="right" format="{0:N2}" maxLength="10"/> <EF:EFColumn ename="length" cname="长度(MM)" enable="true" readonly="true" width="100" align="right" format="{0:N2}" maxLength="10"/>
<EF:EFColumn ename="width" cname="宽度(MM)" enable="true" readonly="true" width="100" align="right" format="{0:N2}" maxLength="10"/> <EF:EFColumn ename="width" cname="宽度(MM)" enable="true" readonly="true" width="100" align="right" format="{0:N2}" maxLength="10"/>
<EF:EFColumn ename="thick" cname="厚度(MM)" enable="true" readonly="true" width="100" align="right" format="{0:N2}" maxLength="10"/> <EF:EFColumn ename="thick" cname="厚度(MM)" enable="true" readonly="true" width="100" align="right" format="{0:N2}" maxLength="10"/>
<EF:EFColumn ename="quantity" cname="数量" enable="true" readonly="true" width="100" format="{0:N0}" editType="text" <EF:EFColumn ename="quantity" cname="数量" enable="true" readonly="true" width="100" format="{0:N3}" editType="text"
displayType="0.000" sort="true" align="right" maxLength="17" required="false" defaultValue="0" displayType="0.000" sort="true" align="right" maxLength="17" required="false" defaultValue="0"
data-regex="/^-?[0-9]{1,17}([.][0-9]{1,3})?$/" data-regex="/^-?[0-9]{1,17}([.][0-9]{1,3})?$/"
data-errorprompt="请输入数字,该值最大可设置17位整数和3位小数!"/> data-errorprompt="请输入数字,该值最大可设置17位整数和3位小数!"/>
......
...@@ -72,17 +72,17 @@ ...@@ -72,17 +72,17 @@
<EF:EFColumn ename="inventCode" cname="存货编码" enable="false" width="100" align="center"/> <EF:EFColumn ename="inventCode" cname="存货编码" enable="false" width="100" align="center"/>
<EF:EFColumn ename="inventName" cname="存货名称" enable="false" width="100" align="center"/> <EF:EFColumn ename="inventName" cname="存货名称" enable="false" width="100" align="center"/>
<EF:EFColumn ename="spec" cname="规格" enable="false" width="100" align="center"/> <EF:EFColumn ename="spec" cname="规格" enable="false" width="100" align="center"/>
<EF:EFColumn ename="bookAmount" cname="账面数量" format="{0:N0}" maxLength="20" width="120" align="right" <EF:EFColumn ename="bookAmount" cname="账面数量" format="{0:N3}" maxLength="20" width="120" align="right"
sumType="all" required="false" enable="false"/> sumType="all" required="false" enable="false"/>
<EF:EFColumn ename="bookWeight" cname="账面重量(KG)" enable="false" format="{0:N3}" maxLength="20" width="120" <EF:EFColumn ename="bookWeight" cname="账面重量(KG)" enable="false" format="{0:N3}" maxLength="20" width="120"
align="right" sumType="all" /> align="right" sumType="all" />
<EF:EFColumn ename="bookUnitWeight" cname="单重(KG)" enable="false" format="{0:N3}" maxLength="20" width="120" <EF:EFColumn ename="bookUnitWeight" cname="单重(KG)" enable="false" format="{0:N3}" maxLength="20" width="120"
align="right" /> align="right" />
<EF:EFColumn ename="entityAmount" cname="实物数量" format="{0:N0}" maxLength="20" width="120" align="right" <EF:EFColumn ename="entityAmount" cname="实物数量" format="{0:N3}" maxLength="20" width="120" align="right"
sumType="all" enable="true" required="true" /> sumType="all" enable="true" required="true" />
<EF:EFColumn ename="entityWeight" cname="实物重量(KG)" enable="false" format="{0:N3}" maxLength="20" width="120" <EF:EFColumn ename="entityWeight" cname="实物重量(KG)" enable="false" format="{0:N3}" maxLength="20" width="120"
align="right" sumType="all" required="false"/> align="right" sumType="all" required="false"/>
<EF:EFColumn ename="diffAmount" cname="差异数量" enable="false" format="{0:N0}" maxLength="20" width="120" <EF:EFColumn ename="diffAmount" cname="差异数量" enable="false" format="{0:N3}" maxLength="20" width="120"
align="right" sumType="all" readonly="true"/> align="right" sumType="all" readonly="true"/>
<EF:EFColumn ename="diffWeight" cname="差异重量(KG)" enable="false" format="{0:N3}" maxLength="20" width="120" <EF:EFColumn ename="diffWeight" cname="差异重量(KG)" enable="false" format="{0:N3}" maxLength="20" width="120"
align="right" sumType="all" readonly="true"/> align="right" sumType="all" readonly="true"/>
......
...@@ -51,9 +51,9 @@ ...@@ -51,9 +51,9 @@
blockName="spec_record_block_id" textField="textField" valueField="valueField" blockName="spec_record_block_id" textField="textField" valueField="valueField"
columnTemplate="#=textField#" itemTemplate="#=textField#"> columnTemplate="#=textField#" itemTemplate="#=textField#">
</EF:EFComboColumn> </EF:EFComboColumn>
<EF:EFColumn ename="entityAmount" cname="实物数量" width="120" align="right" format="{0:N0}" hidden="true" defaultValue="0"/> <EF:EFColumn ename="entityAmount" cname="实物数量" width="120" align="right" format="{0:N3}" hidden="true" defaultValue="0"/>
<EF:EFColumn ename="entityRemark" cname="盘点说明" width="150" editType="textarea" copy="true"/> <EF:EFColumn ename="entityRemark" cname="盘点说明" width="150" editType="textarea" copy="true"/>
<EF:EFColumn ename="invQty" cname="库存数量" enable="false" width="120" align="right" format="{0:N0}" <EF:EFColumn ename="invQty" cname="库存数量" enable="false" width="120" align="right" format="{0:N3}"
sumType="all"/> sumType="all"/>
<EF:EFColumn ename="invUnitWeight" cname="库存单重(KG)" enable="false" width="120" align="right" format="{0:N3}"/> <EF:EFColumn ename="invUnitWeight" cname="库存单重(KG)" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="invWeight" cname="库存重量(KG)" enable="false" width="120" align="right" format="{0:N3}" <EF:EFColumn ename="invWeight" cname="库存重量(KG)" enable="false" width="120" align="right" format="{0:N3}"
......
...@@ -52,7 +52,7 @@ ...@@ -52,7 +52,7 @@
<EF:EFColumn ename="prdtWidth" cname="宽(MM)" enable="false" width="80" align="right" format="{0:N3}"/> <EF:EFColumn ename="prdtWidth" cname="宽(MM)" enable="false" width="80" align="right" format="{0:N3}"/>
<EF:EFColumn ename="prdtThick" cname="厚(MM)" enable="false" width="80" align="right" format="{0:N3}"/> <EF:EFColumn ename="prdtThick" cname="厚(MM)" enable="false" width="80" align="right" format="{0:N3}"/>
<EF:EFColumn ename="prdtCoefficient" cname="系数" enable="false" width="80" align="right" format="{0:N3}" hidden="true"/> <EF:EFColumn ename="prdtCoefficient" cname="系数" enable="false" width="80" align="right" format="{0:N3}" hidden="true"/>
<EF:EFColumn ename="invQty" cname="数量" width="120" align="right" format="{0:N0}" <EF:EFColumn ename="invQty" cname="数量" width="120" align="right" format="{0:N3}"
defaultValue="0" defaultValue="0"
data-regex="/^-?[0-9]{1,17}([.][0-9]{1,3})?$/" data-regex="/^-?[0-9]{1,17}([.][0-9]{1,3})?$/"
data-errorprompt="请输入数字,该值最大可设置17位整数和3位小数!" data-errorprompt="请输入数字,该值最大可设置17位整数和3位小数!"
......
...@@ -43,7 +43,7 @@ ...@@ -43,7 +43,7 @@
<EF:EFColumn ename="prdtLength" cname="长(MM)" enable="false" width="80" align="right" format="{0:N3}"/> <EF:EFColumn ename="prdtLength" cname="长(MM)" enable="false" width="80" align="right" format="{0:N3}"/>
<EF:EFColumn ename="prdtWidth" cname="宽(MM)" enable="false" width="80" align="right" format="{0:N3}"/> <EF:EFColumn ename="prdtWidth" cname="宽(MM)" enable="false" width="80" align="right" format="{0:N3}"/>
<EF:EFColumn ename="prdtThick" cname="厚(MM)" enable="false" width="80" align="right" format="{0:N3}"/> <EF:EFColumn ename="prdtThick" cname="厚(MM)" enable="false" width="80" align="right" format="{0:N3}"/>
<EF:EFColumn ename="invQty" cname="数量" width="120" align="right" format="{0:N0}" <EF:EFColumn ename="invQty" cname="数量" width="120" align="right" format="{0:N3}"
defaultValue="0" defaultValue="0"
data-regex="/^-?[0-9]{1,17}([.][0-9]{1,3})?$/" data-regex="/^-?[0-9]{1,17}([.][0-9]{1,3})?$/"
data-errorprompt="请输入数字,该值最大可设置17位整数和3位小数!" data-errorprompt="请输入数字,该值最大可设置17位整数和3位小数!"
......
...@@ -44,7 +44,7 @@ ...@@ -44,7 +44,7 @@
<EF:EFColumn ename="invLength" cname="长度(MM)" width="120" align="center" enable="false"/> <EF:EFColumn ename="invLength" cname="长度(MM)" width="120" align="center" enable="false"/>
<EF:EFColumn ename="invWidth" cname="宽度(MM)" width="120" align="center" enable="false"/> <EF:EFColumn ename="invWidth" cname="宽度(MM)" width="120" align="center" enable="false"/>
<EF:EFColumn ename="invThick" cname="厚度(MM)" width="120" align="center" enable="false"/> <EF:EFColumn ename="invThick" cname="厚度(MM)" width="120" align="center" enable="false"/>
<EF:EFColumn ename="invQty" cname="数量" width="120" align="right" format="{0:N0}" enable="true" required="true" /> <EF:EFColumn ename="invQty" cname="数量" width="120" align="right" format="{0:N3}" enable="true" required="true" />
<EF:EFColumn ename="invUnitWeight" cname="单重(KG)" width="100" enable="false" readonly="true" format="{0:N3}" editType="text" <EF:EFColumn ename="invUnitWeight" cname="单重(KG)" width="100" enable="false" readonly="true" format="{0:N3}" editType="text"
displayType="0.000" sort="true" align="right" maxLength="17" required="false" defaultValue="0" displayType="0.000" sort="true" align="right" maxLength="17" required="false" defaultValue="0"
data-regex="/^-?[0-9]{1,17}([.][0-9]{1,3})?$/" data-regex="/^-?[0-9]{1,17}([.][0-9]{1,3})?$/"
......
...@@ -51,39 +51,39 @@ ...@@ -51,39 +51,39 @@
blockName="spec_record_block_id" textField="textField" valueField="valueField" blockName="spec_record_block_id" textField="textField" valueField="valueField"
columnTemplate="#=textField#" itemTemplate="#=textField#"> columnTemplate="#=textField#" itemTemplate="#=textField#">
</EF:EFComboColumn> </EF:EFComboColumn>
<EF:EFColumn ename="initAmount" cname="期初数量" enable="false" width="100" align="right" format="{0:N0}" <EF:EFColumn ename="initAmount" cname="期初数量" enable="false" width="100" align="right" format="{0:N3}"
sumType="all"/> sumType="all"/>
<EF:EFColumn ename="initWeight" cname="期初重量(KG)" enable="false" width="100" align="right" format="{0:N3}" <EF:EFColumn ename="initWeight" cname="期初重量(KG)" enable="false" width="100" align="right" format="{0:N3}"
sumType="all"/> sumType="all"/>
<EF:EFColumn ename="cgEnterAmount" cname="采购入库数量" enable="false" width="100" align="right" format="{0:N0}" <EF:EFColumn ename="cgEnterAmount" cname="采购入库数量" enable="false" width="100" align="right" format="{0:N3}"
sumType="all"/> sumType="all"/>
<EF:EFColumn ename="cgEnterWeight" cname="采购入库重量(KG)" enable="false" width="100" align="right" format="{0:N3}" <EF:EFColumn ename="cgEnterWeight" cname="采购入库重量(KG)" enable="false" width="100" align="right" format="{0:N3}"
sumType="all"/> sumType="all"/>
<EF:EFColumn ename="qtEnterAmount" cname="其它入库数量" enable="false" width="90" align="right" format="{0:N0}" <EF:EFColumn ename="qtEnterAmount" cname="其它入库数量" enable="false" width="90" align="right" format="{0:N3}"
sumType="all"/> sumType="all"/>
<EF:EFColumn ename="qtEnterWeight" cname="其它入库重量(KG)" enable="false" width="90" align="right" format="{0:N3}" <EF:EFColumn ename="qtEnterWeight" cname="其它入库重量(KG)" enable="false" width="90" align="right" format="{0:N3}"
sumType="all"/> sumType="all"/>
<EF:EFColumn ename="enterAmount" cname="入库数量" enable="false" width="90" align="right" format="{0:N0}" <EF:EFColumn ename="enterAmount" cname="入库数量" enable="false" width="90" align="right" format="{0:N3}"
sumType="all"/> sumType="all"/>
<EF:EFColumn ename="enterWeight" cname="入库重量(KG)" enable="false" width="90" align="right" format="{0:N3}" <EF:EFColumn ename="enterWeight" cname="入库重量(KG)" enable="false" width="90" align="right" format="{0:N3}"
sumType="all"/> sumType="all"/>
<EF:EFColumn ename="scOuterAmount" cname="生产领料数量" enable="false" width="90" align="right" format="{0:N0}" <EF:EFColumn ename="scOuterAmount" cname="生产领料数量" enable="false" width="90" align="right" format="{0:N3}"
sumType="all"/> sumType="all"/>
<EF:EFColumn ename="scOuterWeight" cname="生产领料重量(KG)" enable="false" width="90" align="right" format="{0:N3}" <EF:EFColumn ename="scOuterWeight" cname="生产领料重量(KG)" enable="false" width="90" align="right" format="{0:N3}"
sumType="all"/> sumType="all"/>
<EF:EFColumn ename="qtOuterAmount" cname="其它出库数量" enable="false" width="90" align="right" format="{0:N0}" <EF:EFColumn ename="qtOuterAmount" cname="其它出库数量" enable="false" width="90" align="right" format="{0:N3}"
sumType="all"/> sumType="all"/>
<EF:EFColumn ename="qtOuterWeight" cname="其它出库重量(KG)" enable="false" width="90" align="right" format="{0:N3}" <EF:EFColumn ename="qtOuterWeight" cname="其它出库重量(KG)" enable="false" width="90" align="right" format="{0:N3}"
sumType="all"/> sumType="all"/>
<EF:EFColumn ename="outerAmount" cname="出库数量" enable="false" width="90" align="right" format="{0:N0}" <EF:EFColumn ename="outerAmount" cname="出库数量" enable="false" width="90" align="right" format="{0:N3}"
sumType="all"/> sumType="all"/>
<EF:EFColumn ename="outerWeight" cname="出库重量(KG)" enable="false" width="90" align="right" format="{0:N3}" <EF:EFColumn ename="outerWeight" cname="出库重量(KG)" enable="false" width="90" align="right" format="{0:N3}"
sumType="all"/> sumType="all"/>
<EF:EFColumn ename="pdDiffAmount" cname="盘点差异数量" enable="false" width="90" align="right" format="{0:N0}" <EF:EFColumn ename="pdDiffAmount" cname="盘点差异数量" enable="false" width="90" align="right" format="{0:N3}"
sumType="all"/> sumType="all"/>
<EF:EFColumn ename="pdDiffWeight" cname="盘点差异重量(KG)" enable="false" width="90" align="right" format="{0:N3}" <EF:EFColumn ename="pdDiffWeight" cname="盘点差异重量(KG)" enable="false" width="90" align="right" format="{0:N3}"
sumType="all"/> sumType="all"/>
<EF:EFColumn ename="endAmount" cname="期末数量" enable="false" width="90" align="right" format="{0:N0}" <EF:EFColumn ename="endAmount" cname="期末数量" enable="false" width="90" align="right" format="{0:N3}"
sumType="all"/> sumType="all"/>
<EF:EFColumn ename="endWeight" cname="期末重量(KG)" enable="false" width="90" align="right" format="{0:N3}" <EF:EFColumn ename="endWeight" cname="期末重量(KG)" enable="false" width="90" align="right" format="{0:N3}"
sumType="all"/> sumType="all"/>
......
...@@ -48,7 +48,7 @@ ...@@ -48,7 +48,7 @@
<EF:EFColumn ename="inventName" cname="存货名称" enable="false" width="100" align="center"/> <EF:EFColumn ename="inventName" cname="存货名称" enable="false" width="100" align="center"/>
<EF:EFColumn ename="specId" cname="规格ID" enable="false" width="100" align="center" hidden="true"/> <EF:EFColumn ename="specId" cname="规格ID" enable="false" width="100" align="center" hidden="true"/>
<EF:EFColumn ename="spec" cname="规格" enable="false" width="120" align="center"/> <EF:EFColumn ename="spec" cname="规格" enable="false" width="120" align="center"/>
<EF:EFColumn ename="invQty" cname="库存数量" enable="false" width="120" align="right" format="{0:N0}"/> <EF:EFColumn ename="invQty" cname="库存数量" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="invUnitWeight" cname="单重(KG)" enable="false" width="120" align="right" format="{0:N3}"/> <EF:EFColumn ename="invUnitWeight" cname="单重(KG)" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="invWeight" cname="库存总重(KG)" enable="false" width="120" align="right" format="{0:N3}"/> <EF:EFColumn ename="invWeight" cname="库存总重(KG)" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="material" cname="材质" enable="false" width="80" align="center"/> <EF:EFColumn ename="material" cname="材质" enable="false" width="80" align="center"/>
......
...@@ -42,7 +42,7 @@ ...@@ -42,7 +42,7 @@
<EF:EFColumn ename="inventName" cname="部件名称" enable="false" width="120" align="center"/> <EF:EFColumn ename="inventName" cname="部件名称" enable="false" width="120" align="center"/>
<EF:EFColumn ename="subInventName" cname="零件名称" enable="false" width="120" align="center"/> <EF:EFColumn ename="subInventName" cname="零件名称" enable="false" width="120" align="center"/>
<EF:EFColumn ename="spec" cname="规格" enable="false" width="150" align="center"/> <EF:EFColumn ename="spec" cname="规格" enable="false" width="150" align="center"/>
<EF:EFColumn ename="invQty" cname="数量" enable="false" width="100" align="right" format="{0:N0}"/> <EF:EFColumn ename="invQty" cname="数量" enable="false" width="100" align="right" format="{0:N3}"/>
<EF:EFColumn ename="unitWeight" cname="单重(KG)" enable="false" width="90" align="right" format="{0:N3}"/> <EF:EFColumn ename="unitWeight" cname="单重(KG)" enable="false" width="90" align="right" format="{0:N3}"/>
<EF:EFColumn ename="invWeight" cname="总重(KG)" enable="false" width="90" align="right" format="{0:N3}"/> <EF:EFColumn ename="invWeight" cname="总重(KG)" enable="false" width="90" align="right" format="{0:N3}"/>
<EF:EFColumn ename="createdBy" cname="创建人" enable="false" width="100" align="center"/> <EF:EFColumn ename="createdBy" cname="创建人" enable="false" width="100" align="center"/>
......
...@@ -62,8 +62,8 @@ ...@@ -62,8 +62,8 @@
<EF:EFColumn ename="spec" cname="规格" enable="false" width="120" align="center"/> <EF:EFColumn ename="spec" cname="规格" enable="false" width="120" align="center"/>
<EF:EFColumn ename="material" cname="材质" enable="false" width="120" align="center"/> <EF:EFColumn ename="material" cname="材质" enable="false" width="120" align="center"/>
<EF:EFColumn ename="unit" cname="单位" enable="false" width="120" align="center"/> <EF:EFColumn ename="unit" cname="单位" enable="false" width="120" align="center"/>
<EF:EFColumn ename="warnNum" cname="预警值" enable="false" width="90" align="right" format="{0:N0}"/> <EF:EFColumn ename="warnNum" cname="预警值" enable="false" width="90" align="right" format="{0:N3}"/>
<EF:EFColumn ename="invQty" cname="库存数量" enable="false" width="90" align="right" format="{0:N0}"/> <EF:EFColumn ename="invQty" cname="库存数量" enable="false" width="90" align="right" format="{0:N3}"/>
<EF:EFColumn ename="invWeight" cname="库存重量(KG)" enable="false" width="90" align="right" format="{0:N3}"/> <EF:EFColumn ename="invWeight" cname="库存重量(KG)" enable="false" width="90" align="right" format="{0:N3}"/>
<%--<EF:EFComboColumn ename="princ" cname="仓库负责人" width="120" align="center" enable="false" <%--<EF:EFComboColumn ename="princ" cname="仓库负责人" width="120" align="center" enable="false"
blockName="user_block_id" textField="textField" valueField="valueField" blockName="user_block_id" textField="textField" valueField="valueField"
......
...@@ -50,7 +50,7 @@ ...@@ -50,7 +50,7 @@
<EF:EFColumn ename="length" cname="长度(MM)" enable="true" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/> <EF:EFColumn ename="length" cname="长度(MM)" enable="true" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="width" cname="宽度(MM)" enable="true" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/> <EF:EFColumn ename="width" cname="宽度(MM)" enable="true" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="thick" cname="厚度(MM)" enable="true" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/> <EF:EFColumn ename="thick" cname="厚度(MM)" enable="true" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="quantity" cname="数量" width="120" enable="true" format="{0:N0}" editType="text" <EF:EFColumn ename="quantity" cname="数量" width="120" enable="true" format="{0:N3}" editType="text"
displayType="0.000" sort="true" align="right" displayType="0.000" sort="true" align="right"
data-regex="/^-?[0-9]{1,20}([.][0-9]{1,3})?$/" maxLength="20" required="true" data-regex="/^-?[0-9]{1,20}([.][0-9]{1,3})?$/" maxLength="20" required="true"
data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/>
......
...@@ -30,7 +30,7 @@ ...@@ -30,7 +30,7 @@
<EF:EFGrid blockId="result" autoDraw="override" isFloat="true"> <EF:EFGrid blockId="result" autoDraw="override" isFloat="true">
<EF:EFColumn ename="id" primaryKey="true" cname="内码" hidden="true"/> <EF:EFColumn ename="id" primaryKey="true" cname="内码" hidden="true"/>
<EF:EFColumn ename="companyCode" cname="企业编码" hidden="true"/> <EF:EFColumn ename="companyCode" cname="企业编码" hidden="true"/>
<EF:EFColumn ename="processOrder" cname="加工顺序" width="120" enable="false" format="{0:N0}" editType="text" <EF:EFColumn ename="processOrder" cname="加工顺序" width="120" enable="false" format="{0:N3}" editType="text"
displayType="0" sort="true" align="center" displayType="0" sort="true" align="center"
data-regex="/^-?[0-9]{1,10}?$/" maxLength="10" required="true" data-regex="/^-?[0-9]{1,10}?$/" maxLength="10" required="true"
data-errorprompt="请输入数字,该值最大可设置10位整数!"/> data-errorprompt="请输入数字,该值最大可设置10位整数!"/>
......
...@@ -30,6 +30,9 @@ ...@@ -30,6 +30,9 @@
<EF:EFCodeOption codeName="hggp.hgpz.inventTypeDetail"/> <EF:EFCodeOption codeName="hggp.hgpz.inventTypeDetail"/>
</EF:EFComboColumn> </EF:EFComboColumn>
<EF:EFColumn cname="仓库名称" ename="whName" width="120" align="center" readonly="true" required="true"/> <EF:EFColumn cname="仓库名称" ename="whName" width="120" align="center" readonly="true" required="true"/>
<EF:EFComboColumn ename="inventTypeDetail" cname="存货类型明细" width="80" align="center" readonly="false">
<EF:EFCodeOption codeName="hggp.hgpz.inventTypeDetail"/>
</EF:EFComboColumn>
<EF:EFColumn cname="负责人" ename="princ" align="center" width="120" readonly="true" required="true" /> <EF:EFColumn cname="负责人" ename="princ" align="center" width="120" readonly="true" required="true" />
<EF:EFComboColumn cname="状态" ename="status" width="90" align="center" required="true" defaultValue="1"> <EF:EFComboColumn cname="状态" ename="status" width="90" align="center" required="true" defaultValue="1">
<EF:EFCodeOption codeName="hpjx.hpjx.status"/> <EF:EFCodeOption codeName="hpjx.hpjx.status"/>
......
...@@ -73,7 +73,7 @@ ...@@ -73,7 +73,7 @@
<EF:EFColumn ename="deviceModel" cname="设备型号" width="120" enable="true" readonly="false" align="center" required="true"/> <EF:EFColumn ename="deviceModel" cname="设备型号" width="120" enable="true" readonly="false" align="center" required="true"/>
<EF:EFColumn ename="purchaseDate" cname="购置日期" width="120" enable="true" readonly="false" align="center" editType="date" <EF:EFColumn ename="purchaseDate" cname="购置日期" width="120" enable="true" readonly="false" align="center" editType="date"
dateFormat="yyyy-MM-dd" parseFormats="['yyyyMMdd']" required="true"/> dateFormat="yyyy-MM-dd" parseFormats="['yyyyMMdd']" required="true"/>
<EF:EFColumn ename="periodDays" cname="保养周期天数" width="120" enable="true" format="{0:N0}" editType="text" <EF:EFColumn ename="periodDays" cname="保养周期天数" width="120" enable="true" format="{0:N3}" editType="text"
displayType="0" sort="true" align="right" maxLength="15" required="true" displayType="0" sort="true" align="right" maxLength="15" required="true"
data-regex="/^-?[0-9]{1,15}?$/" data-regex="/^-?[0-9]{1,15}?$/"
data-errorprompt="请输入数字,该值最大可设置15位整数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数!"/>
......
...@@ -13,6 +13,9 @@ $(function () { ...@@ -13,6 +13,9 @@ $(function () {
// 批量提交 // 批量提交
$("#BATCH_SUBMIT").on("click", batchSubmit); $("#BATCH_SUBMIT").on("click", batchSubmit);
// 批量审核
$("#BATCH_APPROVAL").on("click", batchApproval);
let inventNameGlobalData = []; let inventNameGlobalData = [];
let parentId = ''; let parentId = '';
var strs; var strs;
...@@ -867,6 +870,39 @@ let batchSubmit = function () { ...@@ -867,6 +870,39 @@ let batchSubmit = function () {
}); });
} }
/**
* 审核操作
*
* @param id
* @param checkNo
*/
let batchApproval = function () {
let rows = resultGrid.getCheckedRows();
if (rows.length < 1) {
message("请选择数据")
return;
}
for (let i = 0; i < rows.length; i++) {
let singleWeight = rows[i]['singleWeight'];
let quantity = rows[i]['quantity'];
if (!isNumber(singleWeight) || !isNumber(quantity)) {
message("第" + (i + 1) + "行单重和数量必须是大于等于0的数字");
return;
}
}
JSUtils.confirm("确定对勾选中的[" + rows.length + "]条数据做审核操作吗? ", {
ok: function () {
JSUtils.submitGridsData("result", "HGSC004A", "batchApproval", true, function (e) {
var status = e.getStatus();
if (status !== -1) {
query();
}
});
}
});
}
function loadChange(grid,e,field) { function loadChange(grid,e,field) {
var cell_label = field,that = grid; var cell_label = field,that = grid;
......
...@@ -69,7 +69,9 @@ ...@@ -69,7 +69,9 @@
data-regex="/^-?[0-9]{1,17}([.][0-9]{1,3})?$/" data-regex="/^-?[0-9]{1,17}([.][0-9]{1,3})?$/"
data-errorprompt="请输入数字,该值最大可设置17位整数和3位小数!"/> data-errorprompt="请输入数字,该值最大可设置17位整数和3位小数!"/>
<EF:EFComboColumn cname="审核状态" ename="approvalStatus" width="90" align="center" required="false" enable="false">
<EF:EFCodeOption codeName="hggp.hgyx.status" />
</EF:EFComboColumn>
<EF:EFComboColumn cname="提交状态" ename="productStatus" width="90" align="center" required="false" enable="false"> <EF:EFComboColumn cname="提交状态" ename="productStatus" width="90" align="center" required="false" enable="false">
<EF:EFCodeOption codeName="hggp.sc.productStatus" /> <EF:EFCodeOption codeName="hggp.sc.productStatus" />
</EF:EFComboColumn> </EF:EFComboColumn>
......
...@@ -60,7 +60,7 @@ ...@@ -60,7 +60,7 @@
<EF:EFColumn ename="groupName" cname="生产组名称" enable="false" align="center" hidden="true"/> <EF:EFColumn ename="groupName" cname="生产组名称" enable="false" align="center" hidden="true"/>
<EF:EFColumn ename="createdTime" cname="派工时间" enable="false" width="100" align="center" <EF:EFColumn ename="createdTime" cname="派工时间" enable="false" width="100" align="center"
editType="date" dateFormat="yyyy-MM-dd" parseFormats="['yyyyMMdd']" required="true"/> editType="date" dateFormat="yyyy-MM-dd" parseFormats="['yyyyMMdd']" required="true"/>
<EF:EFColumn ename="quantity" cname="分派数量" format="{0:N0}" required="true"/> <EF:EFColumn ename="quantity" cname="分派数量" format="{0:N3}" required="true"/>
</EF:EFGrid> </EF:EFGrid>
<br/> <br/>
<span style='color: red;font-size: 13px;'>说明:厂区和生产组仅新增的时候可以编辑</span> <span style='color: red;font-size: 13px;'>说明:厂区和生产组仅新增的时候可以编辑</span>
......
...@@ -63,17 +63,24 @@ $(function () { ...@@ -63,17 +63,24 @@ $(function () {
grid.dataSource.bind("change", function (e) { grid.dataSource.bind("change", function (e) {
//数量发生变化进行计算 //数量发生变化进行计算
if(e.field === "quantity"){ if(e.field === "quantity"){
if(e.items[0].singleWeight != null){ if(e.items[0].grossAmount != null){
let grossAmount = e.items[0].quantity * e.items[0].singleWeight; let singleWeight = e.items[0].grossAmount/e.items[0].quantity;
resultGrid.setCellValue(e.items[0], 'grossAmount', grossAmount); resultGrid.setCellValue(e.items[0], 'singleWeight', singleWeight);
} }
} }
if(e.field === "singleWeight"){ //数量总重发生变化
if(e.field === "grossAmount"){
if(e.items[0].quantity != null){ if(e.items[0].quantity != null){
let grossAmount = e.items[0].quantity * e.items[0].singleWeight; let singleWeight = e.items[0].grossAmount/e.items[0].quantity;
resultGrid.setCellValue(e.items[0], 'grossAmount', grossAmount); resultGrid.setCellValue(e.items[0], 'singleWeight', singleWeight);
} }
} }
// if(e.field === "singleWeight"){
// if(e.items[0].quantity != null){
// let grossAmount = e.items[0].quantity * e.items[0].singleWeight;
// resultGrid.setCellValue(e.items[0], 'grossAmount', grossAmount);
// }
// }
if (e.field === "inventCode") { if (e.field === "inventCode") {
for (let i = 0; i < inventRecordBoxBlockId.length; i++) { for (let i = 0; i < inventRecordBoxBlockId.length; i++) {
if (inventRecordBoxBlockId[i]['valueField'] === e.items[0].inventCode) { if (inventRecordBoxBlockId[i]['valueField'] === e.items[0].inventCode) {
......
...@@ -52,7 +52,7 @@ ...@@ -52,7 +52,7 @@
<EF:EFColumn ename="length" cname="长(MM)" enable="false" width="80" align="right" format="{0:N3}"/> <EF:EFColumn ename="length" cname="长(MM)" enable="false" width="80" align="right" format="{0:N3}"/>
<EF:EFColumn ename="width" cname="宽(MM)" enable="false" width="80" align="right" format="{0:N3}"/> <EF:EFColumn ename="width" cname="宽(MM)" enable="false" width="80" align="right" format="{0:N3}"/>
<EF:EFColumn ename="thick" cname="厚(MM)" enable="false" width="80" align="right" format="{0:N3}"/> <EF:EFColumn ename="thick" cname="厚(MM)" enable="false" width="80" align="right" format="{0:N3}"/>
<EF:EFColumn ename="quantity" cname="数量" width="120" align="right" format="{0:N0}" <EF:EFColumn ename="quantity" cname="数量" width="120" align="right" format="{0:N3}"
defaultValue="0" defaultValue="0"
data-regex="/^-?[0-9]{1,17}([.][0-9]{1,3})?$/" data-regex="/^-?[0-9]{1,17}([.][0-9]{1,3})?$/"
data-errorprompt="请输入数字,该值最大可设置17位整数和3位小数!"/> data-errorprompt="请输入数字,该值最大可设置17位整数和3位小数!"/>
...@@ -60,7 +60,7 @@ ...@@ -60,7 +60,7 @@
defaultValue="0" defaultValue="0"
data-regex="/^-?[0-9]{1,17}([.][0-9]{1,3})?$/" data-regex="/^-?[0-9]{1,17}([.][0-9]{1,3})?$/"
data-errorprompt="请输入数字,该值最大可设置17位整数和3位小数!" enable="false"/> data-errorprompt="请输入数字,该值最大可设置17位整数和3位小数!" enable="false"/>
<EF:EFColumn ename="grossAmount" cname="总重(KG)" width="120" align="right" enable="false" format="{0:N3}"/> <EF:EFColumn ename="grossAmount" cname="总重(KG)" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="prdtCode" cname="部件编码" enable="false" width="120" align="center" hidden="true"/> <EF:EFColumn ename="prdtCode" cname="部件编码" enable="false" width="120" align="center" hidden="true"/>
<EF:EFColumn ename="partCode" cname="零件编码" enable="false" width="120" align="center" hidden="true"/> <EF:EFColumn ename="partCode" cname="零件编码" enable="false" width="120" align="center" hidden="true"/>
......
...@@ -50,15 +50,15 @@ ...@@ -50,15 +50,15 @@
<EF:EFColumn ename="processCode" cname="工序编码" enable="false" width="100" align="center"/> <EF:EFColumn ename="processCode" cname="工序编码" enable="false" width="100" align="center"/>
<EF:EFColumn ename="processName" cname="工序名称" width="120" enable="true" readonly="true" align="center" required="true"/> <EF:EFColumn ename="processName" cname="工序名称" width="120" enable="true" readonly="true" align="center" required="true"/>
<EF:EFColumn ename="unit" cname="单位" width="80" enable="true" readonly="false" align="center"/> <EF:EFColumn ename="unit" cname="单位" width="80" enable="true" readonly="false" align="center"/>
<EF:EFColumn ename="standardJob" cname="标准作业" width="100" enable="true" format="{0:N0}" editType="number" <EF:EFColumn ename="standardJob" cname="标准作业" width="100" enable="true" format="{0:N3}" editType="number"
displayType="0" sort="true" align="right" required="true" displayType="0" sort="true" align="right" required="true"
data-regex="/^-?[0-9]{1,15}?$/" maxLength="15" data-regex="/^-?[0-9]{1,15}?$/" maxLength="15"
data-errorprompt="请输入数字,该值最大可设置15位整数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数!"/>
<EF:EFColumn ename="standardDays" cname="标准人天" width="100" enable="true" format="{0:N0}" editType="number" <EF:EFColumn ename="standardDays" cname="标准人天" width="100" enable="true" format="{0:N3}" editType="number"
displayType="0" sort="true" align="right" displayType="0" sort="true" align="right"
data-regex="/^-?[0-9]{1,15}?$/" maxLength="20" required="true" data-regex="/^-?[0-9]{1,15}?$/" maxLength="20" required="true"
data-errorprompt="请输入数字,该值最大可设置15位整数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数!"/>
<EF:EFColumn ename="standardNum" cname="标准工序人数" width="100" enable="true" format="{0:N0}" editType="number" <EF:EFColumn ename="standardNum" cname="标准工序人数" width="100" enable="true" format="{0:N3}" editType="number"
displayType="0" sort="true" align="right" displayType="0" sort="true" align="right"
data-regex="/^-?[0-9]{1,15}?$/" maxLength="20" required="true" data-regex="/^-?[0-9]{1,15}?$/" maxLength="20" required="true"
data-errorprompt="请输入数字,该值最大可设置15位整数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数!"/>
......
...@@ -44,7 +44,7 @@ ...@@ -44,7 +44,7 @@
</EF:EFComboColumn> </EF:EFComboColumn>
<EF:EFColumn ename="flowCode" cname="流程编码" enable="false" width="100" align="center"/> <EF:EFColumn ename="flowCode" cname="流程编码" enable="false" width="100" align="center"/>
<EF:EFColumn ename="flowName" cname="流程名称" width="120" enable="true" readonly="false" align="center" required="true"/>--%> <EF:EFColumn ename="flowName" cname="流程名称" width="120" enable="true" readonly="false" align="center" required="true"/>--%>
<EF:EFColumn ename="processOrder" cname="加工顺序" width="120" enable="true" format="{0:N0}" editType="number" <EF:EFColumn ename="processOrder" cname="加工顺序" width="120" enable="true" format="{0:N3}" editType="number"
displayType="0" sort="true" align="center" required="true" displayType="0" sort="true" align="center" required="true"
data-regex="/^-?[0-9]{1,15}?$/" maxLength="15" data-regex="/^-?[0-9]{1,15}?$/" maxLength="15"
data-errorprompt="请输入数字,该值最大可设置15位整数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数!"/>
......
...@@ -74,7 +74,7 @@ ...@@ -74,7 +74,7 @@
columnTemplate="#=textField#" itemTemplate="#=textField#"> columnTemplate="#=textField#" itemTemplate="#=textField#">
</EF:EFComboColumn> </EF:EFComboColumn>
<EF:EFColumn ename="consAddr" cname="发货地址" hidden="true" width="120" align="center"/> <EF:EFColumn ename="consAddr" cname="发货地址" hidden="true" width="120" align="center"/>
<EF:EFColumn ename="consQuantity" cname="发货数量" enable="true" readonly="true" width="120" align="center" format="{0:N0}" data-rules="number"/> <EF:EFColumn ename="consQuantity" cname="发货数量" enable="true" readonly="true" width="120" align="center" format="{0:N3}" data-rules="number"/>
<EF:EFColumn ename="consWeight" cname="发货重量" width="120" align="center" format="{0:N3}" data-rules="number"/> <EF:EFColumn ename="consWeight" cname="发货重量" width="120" align="center" format="{0:N3}" data-rules="number"/>
<EF:EFComboColumn ename="status" cname="审核状态" width="80" align="center" enable="false" defaultValue="0" required="true"> <EF:EFComboColumn ename="status" cname="审核状态" width="80" align="center" enable="false" defaultValue="0" required="true">
<EF:EFCodeOption codeName="hggp.hgyx.status" condition="ITEM_CODE IN ('0','1')"/> <EF:EFCodeOption codeName="hggp.hgyx.status" condition="ITEM_CODE IN ('0','1')"/>
......
...@@ -57,7 +57,7 @@ ...@@ -57,7 +57,7 @@
<EF:EFInput blockId="inqu_status" row="0" ename="numPlate" cname="车牌号" placeholder="请输入车牌号" colWidth="3"/> <EF:EFInput blockId="inqu_status" row="0" ename="numPlate" cname="车牌号" placeholder="请输入车牌号" colWidth="3"/>
</div> </div>
<div class="row"> <div class="row">
<EF:EFInput blockId="inqu_status" row="0" ename="consQuantity" cname="发货数量" format="{0:N0}" <EF:EFInput blockId="inqu_status" row="0" ename="consQuantity" cname="发货数量" format="{0:N3}"
required="true" colWidth="3" disabled="true" required="true" colWidth="3" disabled="true"
data-regex="/^-?[0-9]{1,15}?$/" data-regex="/^-?[0-9]{1,15}?$/"
data-errorprompt="请输入数字,该值最大可设置15位整数"/> data-errorprompt="请输入数字,该值最大可设置15位整数"/>
...@@ -92,7 +92,7 @@ ...@@ -92,7 +92,7 @@
<EF:EFColumn ename="length" cname="长度(MM)" enable="false" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/> <EF:EFColumn ename="length" cname="长度(MM)" enable="false" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="width" cname="宽度(MM)" enable="false" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/> <EF:EFColumn ename="width" cname="宽度(MM)" enable="false" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="thick" cname="厚度(MM)" enable="false" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/> <EF:EFColumn ename="thick" cname="厚度(MM)" enable="false" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="quantity" cname="数量" width="120" enable="true" format="{0:N0}" editType="text" <EF:EFColumn ename="quantity" cname="数量" width="120" enable="true" format="{0:N3}" editType="text"
displayType="0.000" sort="true" align="right" displayType="0.000" sort="true" align="right"
data-regex="/^-?[0-9]{1,15}$/" maxLength="20" required="true" data-regex="/^-?[0-9]{1,15}$/" maxLength="20" required="true"
data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/>
......
...@@ -57,7 +57,7 @@ ...@@ -57,7 +57,7 @@
<EF:EFInput blockId="inqu_status" row="0" ename="numPlate" cname="车牌号" disabled="true" placeholder="请输入车牌号" colWidth="3"/> <EF:EFInput blockId="inqu_status" row="0" ename="numPlate" cname="车牌号" disabled="true" placeholder="请输入车牌号" colWidth="3"/>
</div> </div>
<div class="row"> <div class="row">
<EF:EFInput blockId="inqu_status" row="0" ename="consQuantity" cname="发货数量" format="{0:N0}" <EF:EFInput blockId="inqu_status" row="0" ename="consQuantity" cname="发货数量" format="{0:N3}"
required="true" colWidth="3" disabled="true" required="true" colWidth="3" disabled="true"
data-regex="/^-?[0-9]{1,15}?$/" data-regex="/^-?[0-9]{1,15}?$/"
data-errorprompt="请输入数字,该值最大可设置15位整数"/> data-errorprompt="请输入数字,该值最大可设置15位整数"/>
...@@ -90,7 +90,7 @@ ...@@ -90,7 +90,7 @@
<EF:EFColumn ename="length" cname="长度(MM)" enable="true" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/> <EF:EFColumn ename="length" cname="长度(MM)" enable="true" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="width" cname="宽度(MM)" enable="true" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/> <EF:EFColumn ename="width" cname="宽度(MM)" enable="true" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="thick" cname="厚度(MM)" enable="true" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/> <EF:EFColumn ename="thick" cname="厚度(MM)" enable="true" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="quantity" cname="数量" width="120" enable="true" format="{0:N0}" editType="text" <EF:EFColumn ename="quantity" cname="数量" width="120" enable="true" format="{0:N3}" editType="text"
displayType="0.000" sort="true" align="right" displayType="0.000" sort="true" align="right"
data-regex="/^-?[0-9]{1,15}$/" maxLength="20" required="true" data-regex="/^-?[0-9]{1,15}$/" maxLength="20" required="true"
data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/>
......
...@@ -47,11 +47,11 @@ ...@@ -47,11 +47,11 @@
<EF:EFColumn ename="length" cname="长度(MM)" enable="true" readonly="true" width="100" align="right" format="{0:N3}" maxLength="10"/> <EF:EFColumn ename="length" cname="长度(MM)" enable="true" readonly="true" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="width" cname="宽度(MM)" enable="true" readonly="true" width="100" align="right" format="{0:N3}" maxLength="10"/> <EF:EFColumn ename="width" cname="宽度(MM)" enable="true" readonly="true" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="thick" cname="厚度(MM)" enable="true" readonly="true" width="100" align="right" format="{0:N3}" maxLength="10"/> <EF:EFColumn ename="thick" cname="厚度(MM)" enable="true" readonly="true" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="consQuantity" cname="数量" width="120" enable="true" format="{0:N0}" editType="text" <EF:EFColumn ename="consQuantity" cname="数量" width="120" enable="true" format="{0:N3}" editType="text"
displayType="0.000" sort="true" align="right" readonly="true" displayType="0.000" sort="true" align="right" readonly="true"
data-regex="/^-?[0-9]{1,20}([.][0-9]{1,3})?$/" maxLength="20" required="true" data-regex="/^-?[0-9]{1,20}([.][0-9]{1,3})?$/" maxLength="20" required="true"
data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/>
<EF:EFColumn ename="consUnitWeight" cname="单重(KG)" width="120" enable="true" format="{0:N0}" editType="text" <EF:EFColumn ename="consUnitWeight" cname="单重(KG)" width="120" enable="true" format="{0:N3}" editType="text"
displayType="0.000" sort="true" align="right" readonly="true" displayType="0.000" sort="true" align="right" readonly="true"
data-regex="/^-?[0-9]{1,20}([.][0-9]{1,3})?$/" maxLength="20" required="true" data-regex="/^-?[0-9]{1,20}([.][0-9]{1,3})?$/" maxLength="20" required="true"
data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/>
......
...@@ -51,7 +51,7 @@ ...@@ -51,7 +51,7 @@
filter="contains" readonly="true" required="true"> filter="contains" readonly="true" required="true">
<EF:EFOptions blockId="companyBox_block_id" valueField="valueField" textField="textField"/> <EF:EFOptions blockId="companyBox_block_id" valueField="valueField" textField="textField"/>
</EF:EFComboColumn> </EF:EFComboColumn>
<EF:EFColumn ename="returnQuantity" cname="退货数量" width="120" readonly="true" align="center" format="{0:N0}" data-rules="number"/> <EF:EFColumn ename="returnQuantity" cname="退货数量" width="120" readonly="true" align="center" format="{0:N3}" data-rules="number"/>
<EF:EFColumn ename="returnWeight" cname="退货重量" width="120" readonly="true" align="center" format="{0:N3}" data-rules="number"/> <EF:EFColumn ename="returnWeight" cname="退货重量" width="120" readonly="true" align="center" format="{0:N3}" data-rules="number"/>
<EF:EFComboColumn ename="status" cname="审核状态" width="80" align="center" enable="false" defaultValue="0" required="true"> <EF:EFComboColumn ename="status" cname="审核状态" width="80" align="center" enable="false" defaultValue="0" required="true">
<EF:EFCodeOption codeName="hggp.hgyx.status" condition="ITEM_CODE IN ('0','1')"/> <EF:EFCodeOption codeName="hggp.hgyx.status" condition="ITEM_CODE IN ('0','1')"/>
......
...@@ -52,7 +52,7 @@ ...@@ -52,7 +52,7 @@
</EF:EFSelect> </EF:EFSelect>
</div> </div>
<div class="row"> <div class="row">
<EF:EFInput blockId="inqu_status" row="0" ename="returnQuantity" cname="退货数量" format="{0:N0}" <EF:EFInput blockId="inqu_status" row="0" ename="returnQuantity" cname="退货数量" format="{0:N3}"
required="true" colWidth="3" disabled="true" required="true" colWidth="3" disabled="true"
data-regex="/^-?[0-9]{1,15}?$/" data-regex="/^-?[0-9]{1,15}?$/"
data-errorprompt="请输入数字,该值最大可设置15位整数"/> data-errorprompt="请输入数字,该值最大可设置15位整数"/>
...@@ -89,7 +89,7 @@ ...@@ -89,7 +89,7 @@
<EF:EFColumn ename="length" cname="长度(MM)" enable="false" readonly="true" width="100" align="right" format="{0:N3}" maxLength="10"/> <EF:EFColumn ename="length" cname="长度(MM)" enable="false" readonly="true" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="width" cname="宽度(MM)" enable="false" readonly="true" width="100" align="right" format="{0:N3}" maxLength="10"/> <EF:EFColumn ename="width" cname="宽度(MM)" enable="false" readonly="true" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="thick" cname="厚度(MM)" enable="false" readonly="true" width="100" align="right" format="{0:N3}" maxLength="10"/> <EF:EFColumn ename="thick" cname="厚度(MM)" enable="false" readonly="true" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="quantity" cname="发货数量" width="120" enable="false" format="{0:N0}" editType="text" <EF:EFColumn ename="quantity" cname="发货数量" width="120" enable="false" format="{0:N3}" editType="text"
displayType="0.000" sort="true" align="right" displayType="0.000" sort="true" align="right"
data-regex="/^-?[0-9]{1,15}$/" maxLength="20" required="true" data-regex="/^-?[0-9]{1,15}$/" maxLength="20" required="true"
data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/>
...@@ -101,7 +101,7 @@ ...@@ -101,7 +101,7 @@
displayType="0.000" sort="true" align="right" displayType="0.000" sort="true" align="right"
data-regex="/^-?[0-9]{1,15}([.][0-9]{1,3})?$/" maxLength="15" required="true" data-regex="/^-?[0-9]{1,15}([.][0-9]{1,3})?$/" maxLength="15" required="true"
data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/>
<EF:EFColumn ename="returnQuantity" cname="退货数量" width="120" enable="true" format="{0:N0}" editType="number" <EF:EFColumn ename="returnQuantity" cname="退货数量" width="120" enable="true" format="{0:N3}" editType="number"
displayType="0.000" sort="true" align="right" defaultValue="0" displayType="0.000" sort="true" align="right" defaultValue="0"
data-regex="/^-?[0-9]{1,15}$/" maxLength="20" required="true" data-regex="/^-?[0-9]{1,15}$/" maxLength="20" required="true"
data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/>
......
...@@ -43,7 +43,7 @@ ...@@ -43,7 +43,7 @@
</EF:EFSelect> </EF:EFSelect>
</div> </div>
<div class="row"> <div class="row">
<EF:EFInput blockId="inqu_status" row="0" ename="returnQuantity" cname="退货数量" format="{0:N0}" <EF:EFInput blockId="inqu_status" row="0" ename="returnQuantity" cname="退货数量" format="{0:N3}"
required="true" colWidth="3" disabled="true" required="true" colWidth="3" disabled="true"
data-regex="/^-?[0-9]{1,15}?$/" data-regex="/^-?[0-9]{1,15}?$/"
data-errorprompt="请输入数字,该值最大可设置15位整数"/> data-errorprompt="请输入数字,该值最大可设置15位整数"/>
...@@ -79,7 +79,7 @@ ...@@ -79,7 +79,7 @@
<EF:EFColumn ename="length" cname="长度(MM)" enable="true" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/> <EF:EFColumn ename="length" cname="长度(MM)" enable="true" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="width" cname="宽度(MM)" enable="true" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/> <EF:EFColumn ename="width" cname="宽度(MM)" enable="true" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="thick" cname="厚度(MM)" enable="true" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/> <EF:EFColumn ename="thick" cname="厚度(MM)" enable="true" readonly="false" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="quantity" cname="数量" width="120" enable="true" format="{0:N0}" editType="text" <EF:EFColumn ename="quantity" cname="数量" width="120" enable="true" format="{0:N3}" editType="text"
displayType="0.000" sort="true" align="right" displayType="0.000" sort="true" align="right"
data-regex="/^-?[0-9]{1,15}$/" maxLength="20" required="true" data-regex="/^-?[0-9]{1,15}$/" maxLength="20" required="true"
data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/>
...@@ -91,7 +91,7 @@ ...@@ -91,7 +91,7 @@
displayType="0.000" sort="true" align="right" displayType="0.000" sort="true" align="right"
data-regex="/^-?[0-9]{1,15}([.][0-9]{1,3})?$/" maxLength="15" required="true" data-regex="/^-?[0-9]{1,15}([.][0-9]{1,3})?$/" maxLength="15" required="true"
data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/>
<EF:EFColumn ename="returnQuantity" cname="退货数量" width="120" enable="true" format="{0:N0}" editType="text" <EF:EFColumn ename="returnQuantity" cname="退货数量" width="120" enable="true" format="{0:N3}" editType="text"
displayType="0.000" sort="true" align="right" displayType="0.000" sort="true" align="right"
data-regex="/^-?[0-9]{1,15}$/" maxLength="20" required="true" data-regex="/^-?[0-9]{1,15}$/" maxLength="20" required="true"
data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/>
......
...@@ -48,11 +48,11 @@ ...@@ -48,11 +48,11 @@
<EF:EFColumn ename="length" cname="长度(MM)" enable="true" readonly="true" width="100" align="right" format="{0:N3}" maxLength="10"/> <EF:EFColumn ename="length" cname="长度(MM)" enable="true" readonly="true" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="width" cname="宽度(MM)" enable="true" readonly="true" width="100" align="right" format="{0:N3}" maxLength="10"/> <EF:EFColumn ename="width" cname="宽度(MM)" enable="true" readonly="true" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="thick" cname="厚度(MM)" enable="true" readonly="true" width="100" align="right" format="{0:N3}" maxLength="10"/> <EF:EFColumn ename="thick" cname="厚度(MM)" enable="true" readonly="true" width="100" align="right" format="{0:N3}" maxLength="10"/>
<EF:EFColumn ename="quantity" cname="数量" width="120" enable="true" readonly="true" format="{0:N0}" editType="text" <EF:EFColumn ename="quantity" cname="数量" width="120" enable="true" readonly="true" format="{0:N3}" editType="text"
displayType="0.000" sort="true" align="right" displayType="0.000" sort="true" align="right"
data-regex="/^-?[0-9]{1,20}([.][0-9]{1,3})?$/" maxLength="20" required="true" data-regex="/^-?[0-9]{1,20}([.][0-9]{1,3})?$/" maxLength="20" required="true"
data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/>
<EF:EFColumn ename="unitWeight" cname="单重(KG)" width="120" enable="true" readonly="true" format="{0:N0}" editType="text" <EF:EFColumn ename="unitWeight" cname="单重(KG)" width="120" enable="true" readonly="true" format="{0:N3}" editType="text"
displayType="0.000" sort="true" align="right" displayType="0.000" sort="true" align="right"
data-regex="/^-?[0-9]{1,20}([.][0-9]{1,3})?$/" maxLength="20" required="true" data-regex="/^-?[0-9]{1,20}([.][0-9]{1,3})?$/" maxLength="20" required="true"
data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/>
...@@ -60,7 +60,7 @@ ...@@ -60,7 +60,7 @@
displayType="0.000" sort="true" align="right" displayType="0.000" sort="true" align="right"
data-regex="/^-?[0-9]{1,15}([.][0-9]{1,3})?$/" maxLength="15" required="true" data-regex="/^-?[0-9]{1,15}([.][0-9]{1,3})?$/" maxLength="15" required="true"
data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/>
<EF:EFColumn ename="returnQuantity" cname="退货数量" width="120" enable="true" hidden="true" format="{0:N0}" editType="number" <EF:EFColumn ename="returnQuantity" cname="退货数量" width="120" enable="true" hidden="true" format="{0:N3}" editType="number"
displayType="0.000" sort="true" align="right" displayType="0.000" sort="true" align="right"
data-regex="/^-?[0-9]{1,15}$/" maxLength="20" required="true" data-regex="/^-?[0-9]{1,15}$/" maxLength="20" required="true"
data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/> data-errorprompt="请输入数字,该值最大可设置15位整数和3位小数!"/>
......
...@@ -53,9 +53,9 @@ ...@@ -53,9 +53,9 @@
<EF:EFColumn ename="inventName" cname="存货名称" enable="false" width="100" align="center"/> <EF:EFColumn ename="inventName" cname="存货名称" enable="false" width="100" align="center"/>
<EF:EFColumn ename="specId" cname="规格ID" enable="false" width="100" align="center" hidden="true"/> <EF:EFColumn ename="specId" cname="规格ID" enable="false" width="100" align="center" hidden="true"/>
<EF:EFColumn ename="spec" cname="规格" enable="false" width="120" align="center"/> <EF:EFColumn ename="spec" cname="规格" enable="false" width="120" align="center"/>
<EF:EFColumn ename="qualifyQty" cname="合格数量" width="120" align="right" format="{0:N0}" required="true"/> <EF:EFColumn ename="qualifyQty" cname="合格数量" width="120" align="right" format="{0:N3}" required="true"/>
<EF:EFColumn ename="unqualifyQty" cname="不合格数量" width="120" align="right" format="{0:N0}" required="true"/> <EF:EFColumn ename="unqualifyQty" cname="不合格数量" width="120" align="right" format="{0:N3}" required="true"/>
<EF:EFColumn ename="receiveQty" cname="收货数量" enable="false" width="120" align="right" format="{0:N0}"/> <EF:EFColumn ename="receiveQty" cname="收货数量" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="receiveWeight" cname="收货重量" enable="false" width="120" align="right" format="{0:N3}"/> <EF:EFColumn ename="receiveWeight" cname="收货重量" enable="false" width="120" align="right" format="{0:N3}"/>
<%-- <EF:EFComboColumn ename="poorType" cname="不良品类" enable="false" width="100" align="center">--%> <%-- <EF:EFComboColumn ename="poorType" cname="不良品类" enable="false" width="100" align="center">--%>
<%-- <EF:EFCodeOption codeName="hpjx.hpjx.poorType"/>--%> <%-- <EF:EFCodeOption codeName="hpjx.hpjx.poorType"/>--%>
......
...@@ -54,7 +54,7 @@ ...@@ -54,7 +54,7 @@
<%-- <EF:EFCodeOption codeName="hggp.hgzl.poorType"/>--%> <%-- <EF:EFCodeOption codeName="hggp.hgzl.poorType"/>--%>
<%-- </EF:EFComboColumn>--%> <%-- </EF:EFComboColumn>--%>
<%-- <EF:EFColumn ename="problemDesc" cname="质量问题描述" width="140" required="true"/>--%> <%-- <EF:EFColumn ename="problemDesc" cname="质量问题描述" width="140" required="true"/>--%>
<EF:EFColumn ename="receiveQty" cname="收货数量" enable="false" width="120" align="right" format="{0:N0}"/> <EF:EFColumn ename="receiveQty" cname="收货数量" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="receiveWeight" cname="收货重量" enable="false" width="120" align="right" format="{0:N3}"/> <EF:EFColumn ename="receiveWeight" cname="收货重量" enable="false" width="120" align="right" format="{0:N3}"/>
<EF:EFColumn ename="material" cname="材质" enable="false" width="80" align="center"/> <EF:EFColumn ename="material" cname="材质" enable="false" width="80" align="center"/>
<EF:EFColumn ename="unit" cname="单位" enable="false" width="80" align="center"/> <EF:EFColumn ename="unit" cname="单位" enable="false" width="80" align="center"/>
......
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