Commit bc3abb9a authored by 李驰骋's avatar 李驰骋

BUG修复

parent cbb026de
...@@ -5,6 +5,7 @@ import com.topsunit.scanservice.ximai.security.TokenAudience; ...@@ -5,6 +5,7 @@ import com.topsunit.scanservice.ximai.security.TokenAudience;
import com.topsunit.scanservice.ximai.security.TokenManger; import com.topsunit.scanservice.ximai.security.TokenManger;
import com.topsunit.scanservice.ximai.security.TokenService; import com.topsunit.scanservice.ximai.security.TokenService;
import com.topsunit.scanservice.ximai.security.impl.TokenMangerImpl; import com.topsunit.scanservice.ximai.security.impl.TokenMangerImpl;
import org.apache.commons.lang.StringUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component; import org.springframework.stereotype.Component;
import org.springframework.web.servlet.LocaleResolver; import org.springframework.web.servlet.LocaleResolver;
...@@ -24,7 +25,9 @@ public class XimaiLocaleResolver implements LocaleResolver { ...@@ -24,7 +25,9 @@ public class XimaiLocaleResolver implements LocaleResolver {
@Override @Override
public Locale resolveLocale(HttpServletRequest request) { public Locale resolveLocale(HttpServletRequest request) {
TokenAudience tokenAudience = tokenManger.getTokenAudience(request.getHeader("Authorization")); String token = request.getHeader("Authorization");
if(StringUtils.isNotEmpty(token) && !token.startsWith("Basic")){
TokenAudience tokenAudience = tokenManger.getTokenAudience(token);
if(StringUtil.isNullOrEmpty(tokenAudience.getLocal())){ if(StringUtil.isNullOrEmpty(tokenAudience.getLocal())){
return Locale.getDefault(); return Locale.getDefault();
}else{ }else{
...@@ -37,5 +40,7 @@ public class XimaiLocaleResolver implements LocaleResolver { ...@@ -37,5 +40,7 @@ public class XimaiLocaleResolver implements LocaleResolver {
} }
} }
} }
return Locale.getDefault();
}
} }
...@@ -21,6 +21,8 @@ public class MoctcCreateParams { ...@@ -21,6 +21,8 @@ public class MoctcCreateParams {
/*领退料单别 5401 厂内领料 5501 委外领料*/ /*领退料单别 5401 厂内领料 5501 委外领料*/
@ApiModelProperty("领退料单别 5401 厂内领料 5501 委外领料") @ApiModelProperty("领退料单别 5401 厂内领料 5501 委外领料")
private String tc001; private String tc001;
@ApiModelProperty("仓库")
private String warehouse;
@ApiModelProperty("明细") @ApiModelProperty("明细")
private List<MocteCreateParams> moctes; private List<MocteCreateParams> moctes;
} }
...@@ -25,7 +25,9 @@ public class MocteCreateParams { ...@@ -25,7 +25,9 @@ public class MocteCreateParams {
/*批号 扫描,判断启用批号管理,使用INVML表判断是否存在 如果是批管理,默认带出最早入库的一个批号*/ /*批号 扫描,判断启用批号管理,使用INVML表判断是否存在 如果是批管理,默认带出最早入库的一个批号*/
@ApiModelProperty("批号 扫描") @ApiModelProperty("批号 扫描")
private String te010; private String te010;
@ApiModelProperty("库位") @ApiModelProperty("仓库")
private String te008;
/*库位 默认库位,带出可修改*/ /*库位 默认库位,带出可修改*/
@ApiModelProperty("库位")
private String te025; private String te025;
} }
...@@ -23,9 +23,6 @@ import javax.persistence.*; ...@@ -23,9 +23,6 @@ import javax.persistence.*;
public class EntityChangeListener implements ApplicationContextAware { public class EntityChangeListener implements ApplicationContextAware {
private static final Logger log = LoggerFactory.getLogger(EntityChangeListener.class); private static final Logger log = LoggerFactory.getLogger(EntityChangeListener.class);
private ApplicationContext applicationContext; private ApplicationContext applicationContext;
private Cmsmv getCurrentActor(){
return applicationContext.getBean(CurrentActorSetter.class).getActor();
}
private String getCurrentActorStr(){ private String getCurrentActorStr(){
return applicationContext.getBean(CurrentActorSetter.class).getActorStr(); return applicationContext.getBean(CurrentActorSetter.class).getActorStr();
} }
...@@ -37,13 +34,9 @@ public class EntityChangeListener implements ApplicationContextAware { ...@@ -37,13 +34,9 @@ public class EntityChangeListener implements ApplicationContextAware {
public void prePersist(Object object) { public void prePersist(Object object) {
if(object instanceof EntityBase){ if(object instanceof EntityBase){
EntityBase entity = (EntityBase) object; EntityBase entity = (EntityBase) object;
Cmsmv currentActor = getCurrentActor();
String company = getCompany(); String company = getCompany();
entity.setCompany(company); entity.setCompany(company);
entity.setCreator(getCurrentActorStr()); entity.setCreator(getCurrentActorStr());
if(currentActor!=null) {
entity.setUsr_group(currentActor.getUsr_group());
}
entity.setCreateDate(DateUtil.currentDateTimeString()); entity.setCreateDate(DateUtil.currentDateTimeString());
entity.setFlag(1); entity.setFlag(1);
} }
...@@ -58,10 +51,7 @@ public class EntityChangeListener implements ApplicationContextAware { ...@@ -58,10 +51,7 @@ public class EntityChangeListener implements ApplicationContextAware {
public void preUpdate(Object object) { public void preUpdate(Object object) {
if (object instanceof EntityBase) { if (object instanceof EntityBase) {
EntityBase entity = (EntityBase) object; EntityBase entity = (EntityBase) object;
Cmsmv currentActor = getCurrentActor(); entity.setModifier(getCurrentActorStr());
if(currentActor!=null){
entity.setModifier(currentActor.getMv001());
}
entity.setModiDate(DateUtil.currentDateTimeString()); entity.setModiDate(DateUtil.currentDateTimeString());
if (entity.getFlag() == null) { if (entity.getFlag() == null) {
entity.setFlag(1); entity.setFlag(1);
......
...@@ -11,6 +11,6 @@ import com.topsunit.scanservice.ximai.entity.Cmsmv; ...@@ -11,6 +11,6 @@ import com.topsunit.scanservice.ximai.entity.Cmsmv;
* @date 2021/10/26 * @date 2021/10/26
*/ */
public interface CurrentActor { public interface CurrentActor {
Cmsmv getActor(); String getActorStr();
String getCompany(); String getCompany();
} }
...@@ -29,11 +29,6 @@ public class CurrentActorManager implements CurrentActorSetter { ...@@ -29,11 +29,6 @@ public class CurrentActorManager implements CurrentActorSetter {
this.admmfDao = admmfDao; this.admmfDao = admmfDao;
} }
@Override
public Cmsmv getActor() {
return cmsmv;
}
@Override @Override
public void setActor(String id) { public void setActor(String id) {
this.actor = id; this.actor = id;
......
...@@ -12,7 +12,6 @@ import com.topsunit.scanservice.ximai.entity.Cmsmv; ...@@ -12,7 +12,6 @@ import com.topsunit.scanservice.ximai.entity.Cmsmv;
*/ */
public interface CurrentActorSetter { public interface CurrentActorSetter {
void setActor(String id); void setActor(String id);
Cmsmv getActor();
String getActorStr(); String getActorStr();
void setCompany(String company); void setCompany(String company);
......
...@@ -24,8 +24,8 @@ public class CurrentActorImpl implements CurrentActor { ...@@ -24,8 +24,8 @@ public class CurrentActorImpl implements CurrentActor {
} }
@Override @Override
public Cmsmv getActor() { public String getActorStr() {
return applicationContext.getBean(CurrentActorSetter.class).getActor(); return applicationContext.getBean(CurrentActorSetter.class).getActorStr();
} }
@Override @Override
......
...@@ -107,7 +107,7 @@ public class CmsmvService { ...@@ -107,7 +107,7 @@ public class CmsmvService {
@Transactional @Transactional
public void changePassword(ChangePasswordParams params) { public void changePassword(ChangePasswordParams params) {
Cmsmv cmsmv = cmsmvDao.findById(currentActor.getActor().getMv001()).orElseThrow(() -> new TopsunitException(MessageUtils.getMessage("用户不存在"))); Cmsmv cmsmv = cmsmvDao.findById(currentActor.getActorStr()).orElseThrow(() -> new TopsunitException(MessageUtils.getMessage("用户不存在")));
if (StringUtil.isNullOrEmpty(cmsmv.getUdf01())) { if (StringUtil.isNullOrEmpty(cmsmv.getUdf01())) {
if (!params.getOldPassWord().equals(appConfig.getDefaultPassword())) { if (!params.getOldPassWord().equals(appConfig.getDefaultPassword())) {
throw new TopsunitException(MessageUtils.getMessage("原密码输入有误")); throw new TopsunitException(MessageUtils.getMessage("原密码输入有误"));
......
package com.topsunit.scanservice.ximai.service; package com.topsunit.scanservice.ximai.service;
import com.topsunit.scanservice.ximai.common.DateUtil; import com.topsunit.scanservice.ximai.common.DateUtil;
import com.topsunit.scanservice.ximai.common.StringUtil;
import com.topsunit.scanservice.ximai.common.TopsunitException; import com.topsunit.scanservice.ximai.common.TopsunitException;
import com.topsunit.scanservice.ximai.dao.*; import com.topsunit.scanservice.ximai.dao.*;
import com.topsunit.scanservice.ximai.dto.*; import com.topsunit.scanservice.ximai.dto.*;
...@@ -9,6 +10,7 @@ import com.topsunit.scanservice.ximai.entity.*; ...@@ -9,6 +10,7 @@ import com.topsunit.scanservice.ximai.entity.*;
import com.topsunit.scanservice.ximai.security.CurrentActor; import com.topsunit.scanservice.ximai.security.CurrentActor;
import com.topsunit.scanservice.ximai.security.CurrentActorSetter; import com.topsunit.scanservice.ximai.security.CurrentActorSetter;
import com.topsunit.scanservice.ximai.utils.MessageUtils; import com.topsunit.scanservice.ximai.utils.MessageUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.ApplicationContext; import org.springframework.context.ApplicationContext;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
...@@ -190,12 +192,8 @@ public class MoctcService { ...@@ -190,12 +192,8 @@ public class MoctcService {
moctc.setTc014(DateUtil.currentDateString()); moctc.setTc014(DateUtil.currentDateString());
CurrentActorSetter currentActorSetter = applicationContext.getBean(CurrentActorSetter.class); CurrentActorSetter currentActorSetter = applicationContext.getBean(CurrentActorSetter.class);
if(currentActorSetter.getActor()==null){ moctc.setTc015(currentActorSetter.getActorStr());
throw new TopsunitException(MessageUtils.getMessage("未找到用户:{0}", currentActorSetter.getActorStr())); moctc.setTc028(currentActorSetter.getActorStr());
}
moctc.setTc015(currentActor.getActor().getMv001());
moctc.setTc021(currentActor.getActor().getMv004());
moctc.setTc028(currentActor.getActor().getMv001());
//需合计tc29,tc30 //需合计tc29,tc30
moctc.setTc031(mocta.getTa083()); moctc.setTc031(mocta.getTa083());
return moctc; return moctc;
...@@ -254,7 +252,7 @@ public class MoctcService { ...@@ -254,7 +252,7 @@ public class MoctcService {
// throw new TopsunitException(MessageUtils.getMessage("批管理品号{0}必须录入批号。", mocteCreateParams.getTb003())); // throw new TopsunitException(MessageUtils.getMessage("批管理品号{0}必须录入批号。", mocteCreateParams.getTb003()));
// } // }
// }); // });
invmlDao.findFirstByMl001AndMl002AndMl003(mocteCreateParams.getTb003(), moctb.get().getTb009(), mocteCreateParams.getTe025()) invmlDao.findFirstByMl001AndMl002AndMl003(mocteCreateParams.getTb003(), mocteCreateParams.getTe008(), mocteCreateParams.getTe025())
.filter(i -> i.getMl005().compareTo(mocteCreateParams.getQuantity()) >= 0) .filter(i -> i.getMl005().compareTo(mocteCreateParams.getQuantity()) >= 0)
.orElseThrow(() -> new TopsunitException(MessageUtils.getMessage("品号{0}库存不足。", mocteCreateParams.getTb003().trim()))); .orElseThrow(() -> new TopsunitException(MessageUtils.getMessage("品号{0}库存不足。", mocteCreateParams.getTb003().trim())));
...@@ -265,7 +263,7 @@ public class MoctcService { ...@@ -265,7 +263,7 @@ public class MoctcService {
mocte.setTe004(mocteCreateParams.getTb003()); mocte.setTe004(mocteCreateParams.getTb003());
mocte.setTe005(mocteCreateParams.getQuantity()); mocte.setTe005(mocteCreateParams.getQuantity());
mocte.setTe006(moctb.get().getTb007()); mocte.setTe006(moctb.get().getTb007());
mocte.setTe008(mocta.getTa020()); mocte.setTe008(mocteCreateParams.getTe008());
mocte.setTe009(mocteCreateParams.getTb006()); mocte.setTe009(mocteCreateParams.getTb006());
mocte.setTe010(mocteCreateParams.getTe010()); mocte.setTe010(mocteCreateParams.getTe010());
mocte.setTe011(mocta.getTa001()); mocte.setTe011(mocta.getTa001());
......
...@@ -14,6 +14,7 @@ import org.springframework.transaction.annotation.Transactional; ...@@ -14,6 +14,7 @@ import org.springframework.transaction.annotation.Transactional;
import java.math.BigDecimal; import java.math.BigDecimal;
import java.util.Calendar; import java.util.Calendar;
import java.util.concurrent.atomic.AtomicReference;
/** /**
* <p>Title: PurtaService</p> * <p>Title: PurtaService</p>
...@@ -38,7 +39,7 @@ public class PurtaService { ...@@ -38,7 +39,7 @@ public class PurtaService {
@Transactional @Transactional
public void create(PurtaCreateParams create){ public void create(PurtaCreateParams create){
Mocta mocta = moctaDao.findById(new MoctaId(create.getWorkorderType(), create.getWorkorderCode())) Mocta mocta = moctaDao.findById(new MoctaId(create.getWorkorderType(), create.getWorkorderCode()))
.orElseThrow(()->new TopsunitException(MessageUtils.getMessage("未找到工单:{0},{1}",create.getWorkorderType(), create.getWorkorderCode()))); .orElseThrow(()->new TopsunitException(MessageUtils.getMessage("未找到工单:{0},{1}", create.getWorkorderType(), create.getWorkorderCode())));
Calendar curr = Calendar.getInstance(); Calendar curr = Calendar.getInstance();
String currStr = DateUtil.format(curr.getTime(), "yyyyMMdd"); String currStr = DateUtil.format(curr.getTime(), "yyyyMMdd");
Purta purta = BeanUtil.toBeanIgnoreError(create, Purta.class); Purta purta = BeanUtil.toBeanIgnoreError(create, Purta.class);
...@@ -46,7 +47,8 @@ public class PurtaService { ...@@ -46,7 +47,8 @@ public class PurtaService {
purta.setUdf03(mocta.getTa027()); purta.setUdf03(mocta.getTa027());
purta.setTa003(currStr); purta.setTa003(currStr);
purta.setTa013(currStr); purta.setTa013(currStr);
purtaDao.save(purta); StringBuffer note = new StringBuffer();
AtomicReference<BigDecimal> sum = new AtomicReference<>(BigDecimal.ZERO);
create.getDetails().forEach(s->{ create.getDetails().forEach(s->{
Purtb purtb = BeanUtil.toBeanIgnoreError(s, Purtb.class); Purtb purtb = BeanUtil.toBeanIgnoreError(s, Purtb.class);
purtb.setTb001(create.getTa001()); purtb.setTb001(create.getTa001());
...@@ -58,6 +60,7 @@ public class PurtaService { ...@@ -58,6 +60,7 @@ public class PurtaService {
purtb.setTb029(mocta.getTa026()); purtb.setTb029(mocta.getTa026());
purtb.setTb030(mocta.getTa027()); purtb.setTb030(mocta.getTa027());
purtb.setTb031(mocta.getTa028()); purtb.setTb031(mocta.getTa028());
purtb.setTb009(new BigDecimal(s.getUdf11()));
purtbDao.save(purtb); purtbDao.save(purtb);
Purtr purtr = BeanUtil.toBeanIgnoreError(new PurtrCreateParams(), Purtr.class); Purtr purtr = BeanUtil.toBeanIgnoreError(new PurtrCreateParams(), Purtr.class);
purtr.setTr002(purtb.getTb002()); purtr.setTr002(purtb.getTb002());
...@@ -65,7 +68,12 @@ public class PurtaService { ...@@ -65,7 +68,12 @@ public class PurtaService {
purtr.setTr013(purtb.getTb011()); purtr.setTr013(purtb.getTb011());
purtr.setTr015(mocta.getTa044()); purtr.setTr015(mocta.getTa044());
purtrDao.save(purtr); purtrDao.save(purtr);
sum.set(sum.get().add(purtb.getTb009()));
note.append(purtb.getTb004()).append(" ").append(mocta.getUdf08()).append(" ").append(purtb.getTb005());
}); });
purta.setTa011(sum.get());
purta.setTa006(note.toString());
purtaDao.save(purta);
} }
} }
...@@ -178,10 +178,6 @@ public class PurtgService { ...@@ -178,10 +178,6 @@ public class PurtgService {
// tg047 // tg047
// tg048 // tg048
CurrentActorSetter currentActorSetter = applicationContext.getBean(CurrentActorSetter.class); CurrentActorSetter currentActorSetter = applicationContext.getBean(CurrentActorSetter.class);
if(currentActorSetter.getActor()==null){
throw new TopsunitException(MessageUtils.getMessage("未找到用户:{0}", currentActorSetter.getActorStr()));
}
purtg.setTg049(currentActor.getActor().getMv004());
purtg.setTg050("N"); purtg.setTg050("N");
// tg051 // tg051
// tg052 // tg052
...@@ -221,7 +217,7 @@ public class PurtgService { ...@@ -221,7 +217,7 @@ public class PurtgService {
purth.setTh007(localPurcd.getCd018()); // 进货数量 purth.setTh007(localPurcd.getCd018()); // 进货数量
purth.setTh008(localPurcd.getCd007()); // 单位 purth.setTh008(localPurcd.getCd007()); // 单位
purth.setTh009(purthCreateParams.getTh009()); // 仓库 purth.setTh009(purthCreateParams.getTh009()); // 仓库
purth.setTh010(purthCreateParams.getTh010()); // 批号 purth.setTh010("********************"); // 批号
purth.setTh011(localPurcd.getCd010()); // 采购单别 purth.setTh011(localPurcd.getCd010()); // 采购单别
purth.setTh012(localPurcd.getCd011()); // 采购单号 purth.setTh012(localPurcd.getCd011()); // 采购单号
purth.setTh013(localPurcd.getCd012()); // 采购序号 purth.setTh013(localPurcd.getCd012()); // 采购序号
......
...@@ -176,7 +176,7 @@ public class SfctbService { ...@@ -176,7 +176,7 @@ public class SfctbService {
// tc061 // tc061
// tc062 // tc062
// tc063 // tc063
sfctc.setTcd01(currentActor.getActor().getMv001()); // 员工编号 sfctc.setTcd01(currentActor.getActorStr()); // 员工编号
// tcd02 // tcd02
sfctc.setTc064(mocta.getTa083()); // 项目编号 sfctc.setTc064(mocta.getTa083()); // 项目编号
...@@ -197,9 +197,6 @@ public class SfctbService { ...@@ -197,9 +197,6 @@ public class SfctbService {
Invmb invmb = invmbDao.findById(mocta.getTa006()) Invmb invmb = invmbDao.findById(mocta.getTa006())
//.filter(i->i.getCompany().trim().equals(currentActor.getCompany().trim())) //.filter(i->i.getCompany().trim().equals(currentActor.getCompany().trim()))
.orElseThrow(() -> new TopsunitException(MessageUtils.getMessage("未找到品号"))); .orElseThrow(() -> new TopsunitException(MessageUtils.getMessage("未找到品号")));
Sfcta outSfcta = sfctaDao.findById(new SfctaId(params.getTc004(), params.getTc005(), params.getTc006(), params.getTb005()))
//.filter(i->i.getCompany().trim().equals(currentActor.getCompany().trim()))
.orElseThrow(() -> new TopsunitException(MessageUtils.getMessage("未找到移出工艺")));
Cmsmc cmsmc = cmsmcDao.findById(params.getTb008()) Cmsmc cmsmc = cmsmcDao.findById(params.getTb008())
//.filter(i->i.getCompany().trim().equals(currentActor.getCompany().trim())) //.filter(i->i.getCompany().trim().equals(currentActor.getCompany().trim()))
.orElseThrow(() -> new TopsunitException(MessageUtils.getMessage("仓库不存在"))); .orElseThrow(() -> new TopsunitException(MessageUtils.getMessage("仓库不存在")));
...@@ -209,19 +206,23 @@ public class SfctbService { ...@@ -209,19 +206,23 @@ public class SfctbService {
Cmsma cmsma = cmsmaDao.findAll().stream() Cmsma cmsma = cmsmaDao.findAll().stream()
.findFirst().orElseThrow(() -> new TopsunitException(MessageUtils.getMessage("未设置共享参数设置挡"))); .findFirst().orElseThrow(() -> new TopsunitException(MessageUtils.getMessage("未设置共享参数设置挡")));
Optional<Cmsmg> cmsmg = cmsmgDao.findFirstByMg001OrderByMg002Desc("RMB"); Optional<Cmsmg> cmsmg = cmsmgDao.findFirstByMg001OrderByMg002Desc("RMB");
BigDecimal inProcessQuantity = getInProcessQuantity(outSfcta); // Sfcta outSfcta = sfctaDao.findById(new SfctaId(params.getTc004(), params.getTc005(), params.getTc006(), params.getTb005()))
if (params.getTc036().compareTo(inProcessQuantity) > 0) { // //.filter(i->i.getCompany().trim().equals(currentActor.getCompany().trim()))
throw new TopsunitException(MessageUtils.getMessage("转移数量不能超过在制量")); // .orElseThrow(() -> new TopsunitException(MessageUtils.getMessage("未找到移出工艺")));
} // BigDecimal inProcessQuantity = getInProcessQuantity(outSfcta);
String tc039 = outSfcta.getTa033().trim().equals("0") ? "0" : "1"; // if (params.getTc036().compareTo(inProcessQuantity) > 0) {
// throw new TopsunitException(MessageUtils.getMessage("转移数量不能超过在制量"));
// }
Sfctb sfctb = new Sfctb(); Sfctb sfctb = new Sfctb();
sfctb.setTb001(params.getTb001()); // 转移单别 sfctb.setTb001(params.getTb001()); // 转移单别
sfctb.setTb002(getNewTG002()); // 转移单号 sfctb.setTb002(getNewTG002()); // 转移单号
sfctb.setTb003(currentDate); // 转移日期 sfctb.setTb003(currentDate); // 转移日期
sfctb.setTb004(outSfcta.getTa005().trim()); // 移出类别 // String tc039 = outSfcta.getTa033().trim().equals("0") ? "0" : "1";
sfctb.setTb005(outSfcta.getTa006()); // 移出地 // sfctb.setTb004(outSfcta.getTa005().trim()); // 移出类别
sfctb.setTb006(outSfcta.getTa007()); // 移出地名称 // sfctb.setTb005(outSfcta.getTa006()); // 移出地
// sfctb.setTb006(outSfcta.getTa007()); // 移出地名称
// sfctb.setTb023(outSfcta.getTa051()); // 移出部门
sfctb.setTb007("3"); // 移入类别 sfctb.setTb007("3"); // 移入类别
sfctb.setTb008(cmsmc.getMc001()); // 移入地 sfctb.setTb008(cmsmc.getMc001()); // 移入地
sfctb.setTb009(cmsmc.getMc002()); // 移入地名称 sfctb.setTb009(cmsmc.getMc002()); // 移入地名称
...@@ -238,7 +239,6 @@ public class SfctbService { ...@@ -238,7 +239,6 @@ public class SfctbService {
sfctb.setTb020(cmsma.getMa004()); // 税率 sfctb.setTb020(cmsma.getMa004()); // 税率
sfctb.setTb021("RMB"); // 币种 sfctb.setTb021("RMB"); // 币种
sfctb.setTb022(cmsmg.map(Cmsmg::getMg003).orElse(BigDecimal.ONE)); // 汇率 sfctb.setTb022(cmsmg.map(Cmsmg::getMg003).orElse(BigDecimal.ONE)); // 汇率
sfctb.setTb023(outSfcta.getTa051()); // 移出部门
sfctb.setTb024(""); // 移入部门 sfctb.setTb024(""); // 移入部门
// tb025 // tb025
// tb026 // tb026
...@@ -253,24 +253,25 @@ public class SfctbService { ...@@ -253,24 +253,25 @@ public class SfctbService {
sfctc.setTc003("0001"); // 序号 sfctc.setTc003("0001"); // 序号
sfctc.setTc004(mocta.getTa001()); // 工单单别 sfctc.setTc004(mocta.getTa001()); // 工单单别
sfctc.setTc005(mocta.getTa002()); // 工单单号 sfctc.setTc005(mocta.getTa002()); // 工单单号
sfctc.setTc006(outSfcta.getTa003()); // 移出加工顺序 // sfctc.setTc006(outSfcta.getTa003()); // 移出加工顺序
sfctc.setTc007(outSfcta.getTa004()); // 移出工艺 // sfctc.setTc007(outSfcta.getTa004()); // 移出工艺
// sfctc.setTc012(outSfcta.getTa020()); // 计价单位
// sfctc.setTc017(outSfcta.getTa021()); // 委外单价
// sfctc.setTc023(outSfcta.getTa006()); // 移出地
// sfctc.setTc014(tc039.equals("0") ? params.getTc036() : BigDecimal.ZERO);
// sfctc.setTc039(tc039); // 检验状态
sfctc.setTc008(""); // 移入加工顺序 sfctc.setTc008(""); // 移入加工顺序
sfctc.setTc009(""); // 移入工艺 sfctc.setTc009(""); // 移入工艺
sfctc.setTc010(invmb.getMb004()); // 单位 sfctc.setTc010(invmb.getMb004()); // 单位
// tc011 // tc011
sfctc.setTc012(outSfcta.getTa020()); // 计价单位
sfctc.setTc013(params.getTc013()); // 类型 sfctc.setTc013(params.getTc013()); // 类型
sfctc.setTc014(tc039.equals("0") ? params.getTc036() : BigDecimal.ZERO);
sfctc.setTc015(sfctc.getTc014()); sfctc.setTc015(sfctc.getTc014());
// tc016 // tc016
sfctc.setTc017(outSfcta.getTa021()); // 委外单价
sfctc.setTc018(sfctb.getTb004().trim().equals("2")? sfctc.getTc015().multiply(sfctc.getTc017()) : BigDecimal.ZERO); // 加工金额 sfctc.setTc018(sfctb.getTb004().trim().equals("2")? sfctc.getTc015().multiply(sfctc.getTc017()) : BigDecimal.ZERO); // 加工金额
// tc019 // tc019
sfctc.setTc020(params.getTc020()); // 使用人时 sfctc.setTc020(params.getTc020()); // 使用人时
sfctc.setTc021(params.getTc021()); // 使用机时 sfctc.setTc021(params.getTc021()); // 使用机时
sfctc.setTc022("N"); // 审核码 sfctc.setTc022("N"); // 审核码
sfctc.setTc023(outSfcta.getTa006()); // 移出地
sfctc.setTc024(currentDate); // 预交货日期 sfctc.setTc024(currentDate); // 预交货日期
// tc025 // tc025
sfctc.setTc026("N"); // 结束 sfctc.setTc026("N"); // 结束
...@@ -286,7 +287,6 @@ public class SfctbService { ...@@ -286,7 +287,6 @@ public class SfctbService {
sfctc.setTc036(params.getTc036()); // 转移数量 sfctc.setTc036(params.getTc036()); // 转移数量
// tc037 // tc037
sfctc.setTc038(currentDate); // 验收日期 sfctc.setTc038(currentDate); // 验收日期
sfctc.setTc039(tc039); // 检验状态
// tc040 // tc040
sfctc.setTc041(cmsmc.getMc001()); // 移入地 sfctc.setTc041(cmsmc.getMc001()); // 移入地
// tc042 // tc042
...@@ -310,7 +310,7 @@ public class SfctbService { ...@@ -310,7 +310,7 @@ public class SfctbService {
// tc061 // tc061
// tc062 // tc062
// tc063 // tc063
sfctc.setTcd01(currentActor.getActor().getMv001()); // 员工编号 sfctc.setTcd01(currentActor.getActorStr()); // 员工编号
// tcd02 // tcd02
sfctc.setTc064(mocta.getTa083()); // 项目编号 sfctc.setTc064(mocta.getTa083()); // 项目编号
......
...@@ -28,7 +28,7 @@ ...@@ -28,7 +28,7 @@
未找到对应工单:{0},{1}=未找到对应工单:{0},{1} 未找到对应工单:{0},{1}=未找到对应工单:{0},{1}
未找到对应物料:{0}=未找到对应物料:{0} 未找到对应物料:{0}=未找到对应物料:{0}
未找到对应物料默认库:{0},{1}=未找到对应物料默认库:{0},{1} 未找到对应物料默认库:{0},{1}=未找到对应物料默认库:{0},{1}
未找到出货通知单明细:{0},{1}=未找到出货通知单明细:{0},{1} 未找到出货通知单明细\:{0},{1}=未找到出货通知单明细\:{0},{1}
找不到材料品号{0},工艺{1}的工单单身。=找不到材料品号{0},工艺{1}的工单单身。 找不到材料品号{0},工艺{1}的工单单身。=找不到材料品号{0},工艺{1}的工单单身。
材料品号{0},工艺{1}的领料数量超过可领数量。=材料品号{0},工艺{1}的领料数量超过可领数量。 材料品号{0},工艺{1}的领料数量超过可领数量。=材料品号{0},工艺{1}的领料数量超过可领数量。
仓库{0}库位{1}不存在。=仓库{0}库位{1}不存在。 仓库{0}库位{1}不存在。=仓库{0}库位{1}不存在。
...@@ -36,11 +36,11 @@ ...@@ -36,11 +36,11 @@
品号{0}批号{1}库存不足。=品号{0}批号{1}库存不足。 品号{0}批号{1}库存不足。=品号{0}批号{1}库存不足。
未找到采购订单{0},{1}=未找到采购订单{0},{1} 未找到采购订单{0},{1}=未找到采购订单{0},{1}
未找到采购订单{0},{1},{2}=未找到采购订单{0},{1},{2} 未找到采购订单{0},{1},{2}=未找到采购订单{0},{1},{2}
未找到工单:{0},{1}=未找到工单:{0},{1} 未找到工单\:{0},{1}=未找到工单\:{0},{1}
请维护账套数据库编码=请维护账套数据库编码 请维护账套数据库编码=请维护账套数据库编码
通知单{0}已全部出库=通知单{0}已全部出库 通知单{0}已全部出库=通知单{0}已全部出库
未找到销售订单:{0},{1}=未找到销售订单:{0},{1} 未找到销售订单\:{0},{1}=未找到销售订单\:{0},{1}
未找到销售订单:{0},{1},{2}=未找到销售订单:{0},{1},{2} 未找到销售订单\:{0},{1},{2}=未找到销售订单\:{0},{1},{2}
未找到客户:{0}=未找到客户:{0} 未找到客户:{0}=未找到客户:{0}
未找到用户:{0}=未找到用户:{0} 未找到用户:{0}=未找到用户:{0}
品号{0}库存不足。=品号{0}库存不足。 品号{0}库存不足。=品号{0}库存不足。
\ No newline at end of file
...@@ -13,7 +13,7 @@ ...@@ -13,7 +13,7 @@
未找到登录账套=login sob not found. 未找到登录账套=login sob not found.
用户不存在=user does not exist 用户不存在=user does not exist
原密码输入有误=the original password was entered incorrectly. 原密码输入有误=the original password was entered incorrectly.
未找到出货通知单:=shipment notice not found: 未找到出货通知单:=shipment notice not found\:
调拨库位与当前一致=the transfer location is consistent with the current one. 调拨库位与当前一致=the transfer location is consistent with the current one.
工单已领料完成。=the work order has been picked. 工单已领料完成。=the work order has been picked.
没有任何领料数量。=there is no picking quantity. 没有任何领料数量。=there is no picking quantity.
...@@ -22,13 +22,13 @@ ...@@ -22,13 +22,13 @@
委外进货单不存在或已审核=subcontract purchase order does not exist or has been approved. 委外进货单不存在或已审核=subcontract purchase order does not exist or has been approved.
超出进货数量。=exceeding the purchase quantity. 超出进货数量。=exceeding the purchase quantity.
到货单不存在或已检验。=the arrival document does not exist or has been inspected. 到货单不存在或已检验。=the arrival document does not exist or has been inspected.
未找到物料:=item not found: 未找到物料:=item not found\:
到货单不存在或未检验=the arrival document does not exist or has not been inspected. 到货单不存在或未检验=the arrival document does not exist or has not been inspected.
超出到货单验收数量=exceeding the acceptance quantity of arrival document 超出到货单验收数量=exceeding the acceptance quantity of arrival document
未找到对应工单:{0},{1}=no corresponding job found: {0},{1} 未找到对应工单:{0},{1}=no corresponding job found\: {0},{1}
未找到对应物料:{0}=no corresponding material found: {0} 未找到对应物料:{0}=no corresponding material found\: {0}
未找到对应物料默认库:{0},{1}=default library of corresponding material not found: {0},{1} 未找到对应物料默认库:{0},{1}=default library of corresponding material not found\: {0},{1}
未找到出货通知单明细:{0},{1}=shipment note details not found: {0},{1} 未找到出货通知单明细\:{0},{1}=shipment note details not found\: {0},{1}
找不到材料品号{0},工艺{1}的工单单身。=the material item number {0} cannot be found, and the work order of process {1} is single. 找不到材料品号{0},工艺{1}的工单单身。=the material item number {0} cannot be found, and the work order of process {1} is single.
材料品号{0},工艺{1}的领料数量超过可领数量。=material item number {0} and process {1} have more picking quantity than available quantity. 材料品号{0},工艺{1}的领料数量超过可领数量。=material item number {0} and process {1} have more picking quantity than available quantity.
仓库{0}库位{1}不存在。=warehouse {0} location {1} does not exist. 仓库{0}库位{1}不存在。=warehouse {0} location {1} does not exist.
...@@ -36,11 +36,11 @@ ...@@ -36,11 +36,11 @@
品号{0}批号{1}库存不足。=item {0} lot {1} is out of stock. 品号{0}批号{1}库存不足。=item {0} lot {1} is out of stock.
未找到采购订单{0},{1}=purchase order {0} not found, {1} 未找到采购订单{0},{1}=purchase order {0} not found, {1}
未找到采购订单{0},{1},{2}=purchase orders {0},{1},{2} not found. 未找到采购订单{0},{1},{2}=purchase orders {0},{1},{2} not found.
未找到工单:{0},{1}=job not found: {0},{1} 未找到工单\:{0},{1}=job not found\: {0},{1}
请维护账套数据库编码=please maintain the sob database code. 请维护账套数据库编码=please maintain the sob database code.
通知单{0}已全部出库=notice {0} has all been issued. 通知单{0}已全部出库=notice {0} has all been issued.
未找到销售订单:{0},{1}=sales order not found: {0},{1} 未找到销售订单\:{0},{1}=sales order not found\: {0},{1}
未找到销售订单:{0},{1},{2}=sales order not found: {0},{1},{2} 未找到销售订单\:{0},{1},{2}=sales order not found\: {0},{1},{2}
未找到客户:{0}=customer not found: {0} 未找到客户:{0}=customer not found\: {0}
未找到用户:{0}=user not found: {0} 未找到用户:{0}=user not found\: {0}
品号{0}库存不足。=item {0} is out of stock. 品号{0}库存不足。=item {0} is out of stock.
\ No newline at end of file
...@@ -13,7 +13,7 @@ ...@@ -13,7 +13,7 @@
未找到登录账套=ไม่พบกระเป๋าคุมข้อมูลเข้าระบบ 未找到登录账套=ไม่พบกระเป๋าคุมข้อมูลเข้าระบบ
用户不存在=ผู้ใช้ไม่มีอยู่ 用户不存在=ผู้ใช้ไม่มีอยู่
原密码输入有误=ป้อนรหัสผ่านเดิมไม่ถูกต้อง 原密码输入有误=ป้อนรหัสผ่านเดิมไม่ถูกต้อง
未找到出货通知单:=ไม่พบใบแจ้งเตือนการจัดส่ง: 未找到出货通知单:=ไม่พบใบแจ้งเตือนการจัดส่ง\:
调拨库位与当前一致=การโอนตําแหน่งห้องสมุดสอดคล้องกับปัจจุบัน 调拨库位与当前一致=การโอนตําแหน่งห้องสมุดสอดคล้องกับปัจจุบัน
工单已领料完成。=ตารางงานเสร็จสมบูรณ์แล้ว 工单已领料完成。=ตารางงานเสร็จสมบูรณ์แล้ว
没有任何领料数量。=ไม่มีปริมาณอาหาร 没有任何领料数量。=ไม่มีปริมาณอาหาร
...@@ -22,13 +22,13 @@ ...@@ -22,13 +22,13 @@
委外进货单不存在或已审核=ใบเสร็จรับเงินจากภายนอกไม่มีอยู่หรือได้รับการตรวจสอบแล้ว 委外进货单不存在或已审核=ใบเสร็จรับเงินจากภายนอกไม่มีอยู่หรือได้รับการตรวจสอบแล้ว
超出进货数量。=เกินจํานวนที่เข้ามา 超出进货数量。=เกินจํานวนที่เข้ามา
到货单不存在或已检验。=ใบเสร็จรับเงินไม่มีอยู่หรือได้รับการตรวจสอบแล้ว 到货单不存在或已检验。=ใบเสร็จรับเงินไม่มีอยู่หรือได้รับการตรวจสอบแล้ว
未找到物料:=ไม่พบวัสดุ: 未找到物料:=ไม่พบวัสดุ\:
到货单不存在或未检验=ใบเสร็จรับเงินไม่มีอยู่หรือไม่ได้รับการตรวจสอบ 到货单不存在或未检验=ใบเสร็จรับเงินไม่มีอยู่หรือไม่ได้รับการตรวจสอบ
超出到货单验收数量=เกินจํานวนการยอมรับใบเสร็จรับเงิน 超出到货单验收数量=เกินจํานวนการยอมรับใบเสร็จรับเงิน
未找到对应工单:{0},{1}=ไม่พบรายการงานที่สอดคล้องกัน:{0},{1} 未找到对应工单:{0},{1}=ไม่พบรายการงานที่สอดคล้องกัน\:{0},{1}
未找到对应物料:{0}=ไม่พบวัสดุที่สอดคล้องกัน:{0} 未找到对应物料:{0}=ไม่พบวัสดุที่สอดคล้องกัน\:{0}
未找到对应物料默认库:{0},{1}=ไม่พบไลบรารีปริยายของวัสดุที่สอดคล้องกัน:{0},{1} 未找到对应物料默认库:{0},{1}=ไม่พบไลบรารีปริยายของวัสดุที่สอดคล้องกัน\:{0},{1}
未找到出货通知单明细:{0},{1}=ไม่พบรายละเอียดใบแจ้งเตือนการจัดส่ง:{0},{1} 未找到出货通知单明细\:{0},{1}=ไม่พบรายละเอียดใบแจ้งเตือนการจัดส่ง\:{0},{1}
找不到材料品号{0},工艺{1}的工单单身。=ไม่พบวัสดุหมายเลข{0},งานฉบับเดียวสําหรับกระบวนการ{1} 找不到材料品号{0},工艺{1}的工单单身。=ไม่พบวัสดุหมายเลข{0},งานฉบับเดียวสําหรับกระบวนการ{1}
材料品号{0},工艺{1}的领料数量超过可领数量。=หมายเลขวัสดุ{0},จํานวนของกระบวนการ{1}เกินจํานวนที่สามารถรับได้ 材料品号{0},工艺{1}的领料数量超过可领数量。=หมายเลขวัสดุ{0},จํานวนของกระบวนการ{1}เกินจํานวนที่สามารถรับได้
仓库{0}库位{1}不存在。=คลังสินค้า{0}ที่เก็บ{1}ไม่มีอยู่ 仓库{0}库位{1}不存在。=คลังสินค้า{0}ที่เก็บ{1}ไม่มีอยู่
...@@ -36,11 +36,11 @@ ...@@ -36,11 +36,11 @@
品号{0}批号{1}库存不足。=หมายเลข{0}หมายเลขชุด{1}ไม่เพียงพอ 品号{0}批号{1}库存不足。=หมายเลข{0}หมายเลขชุด{1}ไม่เพียงพอ
未找到采购订单{0},{1}=ไม่พบใบสั่งซื้อ{0},{1} 未找到采购订单{0},{1}=ไม่พบใบสั่งซื้อ{0},{1}
未找到采购订单{0},{1},{2}=ไม่พบใบสั่งซื้อ{0},{1},{2} 未找到采购订单{0},{1},{2}=ไม่พบใบสั่งซื้อ{0},{1},{2}
未找到工单:{0},{1}=ไม่พบใบสั่งงาน:{0},{1} 未找到工单\:{0},{1}=ไม่พบใบสั่งงาน\:{0},{1}
请维护账套数据库编码=โปรดรักษาการเข้ารหัสฐานข้อมูลหนังสือ 请维护账套数据库编码=โปรดรักษาการเข้ารหัสฐานข้อมูลหนังสือ
通知单{0}已全部出库=บันทึกการแจ้งเตือน{0}ออกจากระบบหมดแล้ว 通知单{0}已全部出库=บันทึกการแจ้งเตือน{0}ออกจากระบบหมดแล้ว
未找到销售订单:{0},{1}=ไม พบใบสั่งซื้อขาย:{0},{1} 未找到销售订单\:{0},{1}=ไม พบใบสั่งซื้อขาย\:{0},{1}
未找到销售订单:{0},{1},{2}=ไม พบใบสั่งซื้อขาย:{0},{1},{2} 未找到销售订单\:{0},{1},{2}=ไม พบใบสั่งซื้อขาย\:{0},{1},{2}
未找到客户:{0}=ไม พบลูกค้า:{0} 未找到客户:{0}=ไม พบลูกค้า\:{0}
未找到用户:{0}=ไม พบผู ใช ้:{0} 未找到用户:{0}=ไม พบผู ใช \:{0}
品号{0}库存不足。=หมายเลข{0}ไม่เพียงพอในสต็อก 品号{0}库存不足。=หมายเลข{0}ไม่เพียงพอในสต็อก
\ No newline at end of file
...@@ -28,7 +28,7 @@ ...@@ -28,7 +28,7 @@
未找到对应工单:{0},{1}=未找到对应工单:{0},{1} 未找到对应工单:{0},{1}=未找到对应工单:{0},{1}
未找到对应物料:{0}=未找到对应物料:{0} 未找到对应物料:{0}=未找到对应物料:{0}
未找到对应物料默认库:{0},{1}=未找到对应物料默认库:{0},{1} 未找到对应物料默认库:{0},{1}=未找到对应物料默认库:{0},{1}
未找到出货通知单明细:{0},{1}=未找到出货通知单明细:{0},{1} 未找到出货通知单明细\:{0},{1}=未找到出货通知单明细\:{0},{1}
找不到材料品号{0},工艺{1}的工单单身。=找不到材料品号{0},工艺{1}的工单单身。 找不到材料品号{0},工艺{1}的工单单身。=找不到材料品号{0},工艺{1}的工单单身。
材料品号{0},工艺{1}的领料数量超过可领数量。=材料品号{0},工艺{1}的领料数量超过可领数量。 材料品号{0},工艺{1}的领料数量超过可领数量。=材料品号{0},工艺{1}的领料数量超过可领数量。
仓库{0}库位{1}不存在。=仓库{0}库位{1}不存在。 仓库{0}库位{1}不存在。=仓库{0}库位{1}不存在。
...@@ -36,11 +36,11 @@ ...@@ -36,11 +36,11 @@
品号{0}批号{1}库存不足。=品号{0}批号{1}库存不足。 品号{0}批号{1}库存不足。=品号{0}批号{1}库存不足。
未找到采购订单{0},{1}=未找到采购订单{0},{1} 未找到采购订单{0},{1}=未找到采购订单{0},{1}
未找到采购订单{0},{1},{2}=未找到采购订单{0},{1},{2} 未找到采购订单{0},{1},{2}=未找到采购订单{0},{1},{2}
未找到工单:{0},{1}=未找到工单:{0},{1} 未找到工单\:{0},{1}=未找到工单\:{0},{1}
请维护账套数据库编码=请维护账套数据库编码 请维护账套数据库编码=请维护账套数据库编码
通知单{0}已全部出库=通知单{0}已全部出库 通知单{0}已全部出库=通知单{0}已全部出库
未找到销售订单:{0},{1}=未找到销售订单:{0},{1} 未找到销售订单\:{0},{1}=未找到销售订单\:{0},{1}
未找到销售订单:{0},{1},{2}=未找到销售订单:{0},{1},{2} 未找到销售订单\:{0},{1},{2}=未找到销售订单\:{0},{1},{2}
未找到客户:{0}=未找到客户:{0} 未找到客户:{0}=未找到客户:{0}
未找到用户:{0}=未找到用户:{0} 未找到用户:{0}=未找到用户:{0}
品号{0}库存不足。=品号{0}库存不足。 品号{0}库存不足。=品号{0}库存不足。
\ No newline at end of file
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