Commit 067be312 by liuyang

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

parents bbf613bb 8d26570c
......@@ -49,11 +49,6 @@ public class ServiceHPMT001 extends ServiceBase {
try {
String queryMonth = inInfo.getString("queryMonth");
String companyCode = UserSessionUtils.getCompanyCode();
if (StrUtil.isEmpty(companyCode)) {
resultMap.put("status", 403);
resultMap.put("message","票据过期或请求不合法,请重新登录或获取合法权限!");
return resultMap;
}
Map sqlMap = new HashMap();
sqlMap.put("queryMonth", queryMonth);
sqlMap.put("companyCode", companyCode);
......@@ -156,11 +151,6 @@ public class ServiceHPMT001 extends ServiceBase {
try {
String queryMonth = inInfo.getString("queryMonth");
String companyCode = UserSessionUtils.getCompanyCode();
if (StrUtil.isEmpty(companyCode)) {
resultMap.put("status", 403);
resultMap.put("message","票据过期或请求不合法,请重新登录或获取合法权限!");
return resultMap;
}
Map sqlMap = new HashMap();
sqlMap.put("queryMonth", queryMonth);
sqlMap.put("companyCode", companyCode);
......
......@@ -13,6 +13,7 @@ import com.baosight.hpjx.hp.constant.HPSqlConstant;
import com.baosight.hpjx.hp.mt.untils.Base64ToMultipartFile;
import com.baosight.hpjx.hp.mt.untils.Base64Utils;
import com.baosight.hpjx.hp.mt.untils.UploadUtils;
import com.baosight.hpjx.hp.mt.untils.UploadUtils2;
import com.baosight.hpjx.hp.sc.domain.HPSC002A;
import com.baosight.hpjx.hp.sc.domain.HPSC005;
import com.baosight.hpjx.hp.xs.domain.User;
......@@ -72,11 +73,6 @@ public class ServiceHPMT002 extends ServiceBase {
int offset = inInfo.getInt("offset");//当前页
int pageSize = inInfo.getInt("pageSize");//每页条数
String companyCode = UserSessionUtils.getCompanyCode();
if (StrUtil.isEmpty(companyCode)) {
resultMap.put("status", 403);
resultMap.put("message","票据过期或请求不合法,请重新登录或获取合法权限!");
return resultMap;
}
Map sqlMap = new HashMap();
sqlMap.put("companyCode", companyCode);
sqlMap.put("projName", projName);
......@@ -114,11 +110,6 @@ public class ServiceHPMT002 extends ServiceBase {
try {
String projName = inInfo.getString("projName");
String companyCode = UserSessionUtils.getCompanyCode();
if (StrUtil.isEmpty(companyCode)) {
resultMap.put("status", 403);
resultMap.put("message","票据过期或请求不合法,请重新登录或获取合法权限!");
return resultMap;
}
Map sqlMap = new HashMap();
sqlMap.put("companyCode", companyCode);
sqlMap.put("projName", projName);
......@@ -145,11 +136,6 @@ public class ServiceHPMT002 extends ServiceBase {
try {
String queryMonth = inInfo.getString("queryMonth");
String companyCode = UserSessionUtils.getCompanyCode();
if (StrUtil.isEmpty(companyCode)) {
resultMap.put("status", 403);
resultMap.put("message","票据过期或请求不合法,请重新登录或获取合法权限!");
return resultMap;
}
Map sqlMap = new HashMap();
sqlMap.put("companyCode", companyCode);
sqlMap.put("queryMonth", queryMonth);
......@@ -179,11 +165,6 @@ public class ServiceHPMT002 extends ServiceBase {
int offset = inInfo.getInt("offset");//当前页
int pageSize = inInfo.getInt("pageSize");//每页条数
String companyCode = UserSessionUtils.getCompanyCode();
if (StrUtil.isEmpty(companyCode)) {
resultMap.put("status", 403);
resultMap.put("message","票据过期或请求不合法,请重新登录或获取合法权限!");
return resultMap;
}
Map sqlMap = new HashMap();
sqlMap.put("companyCode", companyCode);
sqlMap.put("projName", projName);
......@@ -217,11 +198,6 @@ public class ServiceHPMT002 extends ServiceBase {
try {
String id = inInfo.getString("id");
String companyCode = UserSessionUtils.getCompanyCode();
if (StrUtil.isEmpty(companyCode)) {
resultMap.put("status", 403);
resultMap.put("message","票据过期或请求不合法,请重新登录或获取合法权限!");
return resultMap;
}
String ROOT_PATH= "";
Map hashMap = new HashMap();
hashMap.put("fkey","docRootDir");
......@@ -296,11 +272,6 @@ public class ServiceHPMT002 extends ServiceBase {
String inventCode = inInfo.getString("inventCode");//部件id
String subInventCode = inInfo.getString("subInventCode");//零件id
String companyCode = UserSessionUtils.getCompanyCode();
if (StrUtil.isEmpty(companyCode)) {
resultMap.put("status", 403);
resultMap.put("message","票据过期或请求不合法,请重新登录或获取合法权限!");
return resultMap;
}
Map sqlMap = new HashMap();
sqlMap.put("companyCode", companyCode);
sqlMap.put("factoryCode", factoryId);
......@@ -317,7 +288,7 @@ public class ServiceHPMT002 extends ServiceBase {
List<Map> queryPartCode = this.dao.query("HPMT002.queryPartCode", sqlMap);
List<Map> queryTedcm01 = this.dao.query("HPXSOrg.queryTedcm01",tedcm01);
if(subInventCode!=null&&!subInventCode.equals("")){
List<Map> queryProdTaskNo = this.dao.query("HPMT002.queryProdTaskNo");
List<Map> queryProdTaskNo = this.dao.query("HPMT002.queryProdTaskNo",sqlMap);
resultMap.put("ProdTaskNo",queryProdTaskNo);
}
resultMap.put("Factory",queryFactory);
......@@ -347,11 +318,6 @@ public class ServiceHPMT002 extends ServiceBase {
try {
String docId = inInfo.getString("docId");
String companyCode = UserSessionUtils.getCompanyCode();
if (StrUtil.isEmpty(companyCode)) {
resultMap.put("status", 403);
resultMap.put("message", "票据过期或请求不合法,请重新登录或获取合法权限!");
return resultMap;
}
HPZL001 fZl001 = new HPZL001();
Map attr = inInfo.getAttr();
fZl001.fromMap(attr);
......@@ -411,11 +377,6 @@ public class ServiceHPMT002 extends ServiceBase {
try {
String docId = inInfo.getString("docId");
String companyCode = UserSessionUtils.getCompanyCode();
if (StrUtil.isEmpty(companyCode)) {
resultMap.put("status", 403);
resultMap.put("message", "票据过期或请求不合法,请重新登录或获取合法权限!");
return resultMap;
}
HPZL001 fZl001 = new HPZL001();
Map attr = inInfo.getAttr();
fZl001.fromMap(attr);
......@@ -464,15 +425,9 @@ public class ServiceHPMT002 extends ServiceBase {
Map resultMap = new HashMap();
try {
String files = inInfo.getString("files");
String companyCode = UserSessionUtils.getCompanyCode();
if (StrUtil.isEmpty(companyCode)) {
resultMap.put("status", 403);
resultMap.put("message", "票据过期或请求不合法,请重新登录或获取合法权限!");
return resultMap;
}
CommonsMultipartFile multipartFile = Base64ToMultipartFile.base64toMultipartFile(files);
System.out.println("--------------------------------转换Base64成功");
JSONObject upload = UploadUtils.upload(multipartFile);
JSONObject upload = UploadUtils2.upload(multipartFile);
resultMap.put("id",upload.getString("docId"));
resultMap.put("status", EiConstant.STATUS_SUCCESS);
resultMap.put("message", "SUCCESS");
......
......@@ -139,7 +139,7 @@ public class ServiceHPSC002 extends ServiceBase {
BigDecimal num = hpsc002.getNum();
BigDecimal unitWt = hpsc002.getUnitWt();
DecimalFormat decimalFormat = new DecimalFormat("#.000");
BigDecimal totalWt = new BigDecimal(decimalFormat.format(Math.round(num.multiply(unitWt).floatValue())));
BigDecimal totalWt = new BigDecimal(decimalFormat.format(num.multiply(unitWt).floatValue()));
hpsc002.setDelStatus(CommonConstant.YesNo.NO_0.intValue());
hpsc002.setTotalWt(totalWt);
......@@ -293,7 +293,7 @@ public class ServiceHPSC002 extends ServiceBase {
BigDecimal num = hppz002.getNum();
BigDecimal unitWt = hppz002.getUnitWt();
DecimalFormat decimalFormat = new DecimalFormat("#.000");
BigDecimal totalWt = new BigDecimal(decimalFormat.format(Math.round(num.multiply(unitWt).floatValue())));
BigDecimal totalWt = new BigDecimal(decimalFormat.format(num.multiply(unitWt).floatValue()));
hppz002.setDelStatus(CommonConstant.YesNo.NO_0.intValue());
hppz002.setTotalWt(totalWt);
......@@ -443,7 +443,7 @@ public class ServiceHPSC002 extends ServiceBase {
BigDecimal num = hppz002.getNum();
BigDecimal unitWt = hppz002.getUnitWt();
DecimalFormat decimalFormat = new DecimalFormat("#.000");
BigDecimal totalWt = new BigDecimal(decimalFormat.format(Math.round(num.multiply(unitWt).floatValue())));
BigDecimal totalWt = new BigDecimal(decimalFormat.format(num.multiply(unitWt).floatValue()));
hppz002.setDelStatus(CommonConstant.YesNo.NO_0.intValue());
hppz002.setTotalWt(totalWt);
hppz002.setSpec(HPPZTools.HpPz006.jointSpec(hppz002.getLength(),hppz002.getWidth(),hppz002.getThick()));
......
......@@ -126,7 +126,7 @@ public class ServiceHPSC006 extends ServiceBase {
BigDecimal num = HPSC006.getNum();
BigDecimal unitWt = HPSC006.getUnitWt();
DecimalFormat decimalFormat = new DecimalFormat("#.000");
BigDecimal totalWt = new BigDecimal(decimalFormat.format(Math.round(num.multiply(unitWt).floatValue())));
BigDecimal totalWt = new BigDecimal(decimalFormat.format(num.multiply(unitWt).floatValue()));
HPSC006.setInventSpec(HPPZTools.HpPz006.jointSpec(HPSC006.getInventLength(),HPSC006.getInventWidth(),HPSC006.getInventThick()));
HPSC006.setProjCode(projCode);
HPSC006.setProjName(projName);
......@@ -183,7 +183,7 @@ public class ServiceHPSC006 extends ServiceBase {
BigDecimal num = HPSC006.getNum();
BigDecimal unitWt = HPSC006.getUnitWt();
DecimalFormat decimalFormat = new DecimalFormat("#.000");
BigDecimal totalWt = new BigDecimal(decimalFormat.format(Math.round(num.multiply(unitWt).floatValue())));
BigDecimal totalWt = new BigDecimal(decimalFormat.format(num.multiply(unitWt).floatValue()));
HPSC006.setInventSpec(HPPZTools.HpPz006.jointSpec(HPSC006.getInventLength(),HPSC006.getInventWidth(),HPSC006.getInventThick()));
HPSC006.setProjCode(projCode);
HPSC006.setProjName(projName);
......
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