1.优化各个磅点前端接口调用时的界面加载。

2.磅点后端添加校验程序。
3.登录后自动跳转出入厂磅界面。
4.调整过磅申请插入时的唯一性校验
This commit is contained in:
xiaosuonian 2025-07-22 11:43:50 +08:00
parent 3597325d7d
commit 65b050a25a
14 changed files with 184 additions and 292 deletions

View File

@ -14,6 +14,7 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.ruoyi.basedata.domain.Empwgtdata;
import com.ruoyi.basedata.service.impl.EmpwgtdataServiceImpl;
import com.ruoyi.bill.domain.Poundappli;
import com.ruoyi.bill.domain.Poundmst;
import com.ruoyi.bill.service.impl.oareturn.IOaReturnService;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.utils.SecurityUtils;
@ -42,6 +43,9 @@ public class PoundBillServiceImpl extends ServiceImpl<PoundBillMapper, PoundBill
@Autowired
private PoundappliServiceImpl poundappliService;
@Autowired
private PoundmstServiceImpl poundmstService;
@Autowired
private ISysConfigService configService;
@ -315,9 +319,9 @@ public class PoundBillServiceImpl extends ServiceImpl<PoundBillMapper, PoundBill
{
//判断主榜单是否为新增状态
String appliid = poundBill.getAppliid();
Poundappli appli = poundappliService.getById(appliid);
if (!"1".equals(appli.getBllstate())) {
throw new RuntimeException("主磅单:" + appli.getUsrcode() + "状态不正确:");
Poundmst poundmst = poundmstService.getById(appliid);
if (!"1".equals(poundmst.getBllstt())) {
throw new RuntimeException("主磅单:" + poundmst.getUsrcode() + "状态不正确:");
}
poundBill.initAddFields(poundBill);
poundBill.setBillstate("1");
@ -368,9 +372,9 @@ public class PoundBillServiceImpl extends ServiceImpl<PoundBillMapper, PoundBill
{
//判断主榜单是否为新增状态
String appliid = poundBill.getAppliid();
Poundappli appli = poundappliService.getById(appliid);
if (!"1".equals(appli.getBllstate())) {
throw new RuntimeException("主磅单:" + appli.getUsrcode() + "状态不正确:");
Poundmst poundmst = poundmstService.getById(appliid);
if (!"1".equals(poundmst.getBllstt())) {
throw new RuntimeException("主磅单:" + poundmst.getUsrcode() + "状态不正确:");
}
poundBill.initAddFields(poundBill);
poundBill.setBillstate("1");
@ -405,6 +409,12 @@ public class PoundBillServiceImpl extends ServiceImpl<PoundBillMapper, PoundBill
@Transactional(rollbackFor = Exception.class)
public int insertSteelPoundBill(PoundBill poundBill)
{
//判断主榜单是否为新增状态
String appliid = poundBill.getAppliid();
Poundmst poundmst = poundmstService.getById(appliid);
if (!"1".equals(poundmst.getBllstt())) {
throw new RuntimeException("主磅单:" + poundmst.getUsrcode() + "状态不正确:");
}
poundBill.initAddFields(poundBill);
poundBill.setBillstate("2");
//设置星空单据类型为简单生产入库
@ -442,7 +452,13 @@ public class PoundBillServiceImpl extends ServiceImpl<PoundBillMapper, PoundBill
@Override
public int updatePoundBill(PoundBill poundBill)
{
return poundBillMapper.updatePoundBill(poundBill);
poundBill.initUpdateFields(poundBill);
boolean b = updateById(poundBill);
if(b){
return 1;
}else {
return 0;
}
}
@Override
@ -452,9 +468,11 @@ public class PoundBillServiceImpl extends ServiceImpl<PoundBillMapper, PoundBill
String id = poundBill.getId();
//获取原磅单信息
PoundBill byId = getById(id);
//判断装填是否为新增
if (!"1".equals(byId.getBillstate())){
throw new RuntimeException("过磅申请:" + byId.getUsrcode() + "状态不正确:");
//还原过磅申请
Poundappli appli = poundappliService.getById(byId.getAppliid());
//判断当前过磅申请状态是否为完成状态
if (!"2".equals(appli.getBllstate())) {
throw new RuntimeException("过磅申请:" + appli.getUsrcode() + "状态不正确:");
}
Empwgtdata empwgtdata = new Empwgtdata();
empwgtdata.setCarno(poundBill.getCarno());
@ -486,7 +504,7 @@ public class PoundBillServiceImpl extends ServiceImpl<PoundBillMapper, PoundBill
if ("ing".equals(agnstatus)) {
byId.setAgnstatus("completed");
}
boolean b = updateById(byId);
int b = updatePoundBill(byId);
//推送榜单信息到星空系统
//调用磅单回调接口
try {
@ -494,11 +512,7 @@ public class PoundBillServiceImpl extends ServiceImpl<PoundBillMapper, PoundBill
} catch (IOException e) {
throw new RuntimeException("磅单:" + poundBill.getUsrcode() + "推送星空时,出现异常:"+e.getMessage());
}
if(b){
return 1;
}else{
return 0;
}
return b;
}
@Override
@ -512,6 +526,11 @@ public class PoundBillServiceImpl extends ServiceImpl<PoundBillMapper, PoundBill
if(!"1".equals(byId.getBillstate())){
throw new RuntimeException("当前磅单:" + byId.getUsrcode() + "状态不正确:");
}
//判断当前磅单数据是否存在毛重数据
BigDecimal wghmqty = byId.getWghmqty();
if (BigDecimal.ZERO.compareTo(wghmqty) == 0) {
throw new RuntimeException("当前磅单:" + byId.getUsrcode() + "无毛重数据,请先称毛重!");
}
Empwgtdata empwgtdata = new Empwgtdata();
empwgtdata.setCarno(poundBill.getCarno());
empwgtdata.setEmptycarqty(poundBill.getEmpmqty());
@ -538,7 +557,7 @@ public class PoundBillServiceImpl extends ServiceImpl<PoundBillMapper, PoundBill
//设置复磅状态为复磅完成
poundBill.setAgnstatus("completed");
}
boolean b = updateById(byId);
int b = updatePoundBill(byId);
//推送榜单信息到星空系统
//调用磅单回调接口
try {
@ -546,11 +565,7 @@ public class PoundBillServiceImpl extends ServiceImpl<PoundBillMapper, PoundBill
} catch (IOException e) {
throw new RuntimeException("磅单:" + poundBill.getUsrcode() + "推送星空时,出现异常:"+e.getMessage());
}
if(b){
return 1;
}else{
return 0;
}
return b;
}
@Override
@ -577,6 +592,8 @@ public class PoundBillServiceImpl extends ServiceImpl<PoundBillMapper, PoundBill
//Do nothing
}
byId.setWghdtoprname(currentUser);
//设置毛重
byId.setWghmqty(poundBill.getWghmqty());
//先判断是否存在皮重数据如果不存在则只能将当前单据设置为保存状态
BigDecimal empmqty = poundBill.getEmpmqty();
if (empmqty != null && empmqty.compareTo(BigDecimal.ZERO) > 0){
@ -591,7 +608,7 @@ public class PoundBillServiceImpl extends ServiceImpl<PoundBillMapper, PoundBill
//设置复磅状态为复磅完成
byId.setAgnstatus("completed");
}
boolean save = updateById(byId);
int save = updatePoundBill(byId);
if (empmqty != null && empmqty.compareTo(BigDecimal.ZERO) > 0){
try {
apiPostBack.makePoundBillFormData(byId.getId());
@ -599,18 +616,31 @@ public class PoundBillServiceImpl extends ServiceImpl<PoundBillMapper, PoundBill
throw new RuntimeException("磅单:" + byId.getUsrcode() + "推送星空时,出现异常:"+e.getMessage());
}
}
//调用磅单回调接口
if(save){
return 1;
}
return 0;
return save;
}
@Override
@Transactional(rollbackFor = Exception.class)
public int updateMoltenironPoundBill(PoundBill poundBill)
{
//获取原单据数据
String id = poundBill.getId();
PoundBill byId = getById(id);
//判断当前磅单是否存在毛重数据
BigDecimal wghmqty = byId.getWghmqty();
if (BigDecimal.ZERO.compareTo(wghmqty) > 0){
throw new RuntimeException("当前磅单:" + byId.getUsrcode() + "无毛重数据,请先称毛重");
}
//判断主榜单是否为新增状态
String appliid = poundBill.getAppliid();
Poundmst poundmst = poundmstService.getById(appliid);
if (!"1".equals(poundmst.getBllstt())) {
throw new RuntimeException("主磅单:" + poundmst.getUsrcode() + "状态不正确:");
}
//判断当前单据状态是否为新增
if(!"1".equals(byId.getBillstate())){
throw new RuntimeException("当前磅单:" + byId.getUsrcode() + "状态不正确:");
}
Empwgtdata empwgtdata = new Empwgtdata();
empwgtdata.setCarno(poundBill.getCarno());
empwgtdata.setEmptycarqty(poundBill.getEmpmqty());
@ -624,7 +654,6 @@ public class PoundBillServiceImpl extends ServiceImpl<PoundBillMapper, PoundBill
String empDataId = empwgtdata.getId();
String empUsrcode = empwgtdata.getUsrcode();
//开始对磅单信息进行赋值
PoundBill byId = getById(id);
byId.setEmpsysid(empDataId);
byId.setEmpusrcode(empUsrcode);
byId.setEmpmqty(poundBill.getEmpmqty());
@ -637,12 +666,7 @@ public class PoundBillServiceImpl extends ServiceImpl<PoundBillMapper, PoundBill
if ("ing".equals(agnstatus)) {
poundBill.setAgnstatus("completed");
}
boolean b = updateById(byId);
if(b){
return 1;
}else{
return 0;
}
return updatePoundBill(byId);
}
@ -651,9 +675,9 @@ public class PoundBillServiceImpl extends ServiceImpl<PoundBillMapper, PoundBill
public int updateMolReWeightPoundBill(PoundBill poundBill) {
//判断主榜单是否为新增状态
String appliid = poundBill.getAppliid();
Poundappli appli = poundappliService.getById(appliid);
if (!"1".equals(appli.getBllstate())) {
throw new RuntimeException("主磅单:" + appli.getUsrcode() + "状态不正确:");
Poundmst poundmst = poundmstService.getById(appliid);
if (!"1".equals(poundmst.getBllstt())) {
throw new RuntimeException("主磅单:" + poundmst.getUsrcode() + "状态不正确:");
}
//获取原单据数据
String id = poundBill.getId();
@ -675,22 +699,35 @@ public class PoundBillServiceImpl extends ServiceImpl<PoundBillMapper, PoundBill
}
byId.setWghdtoprname(currentUser);
byId.setWghmqty(poundBill.getWghmqty());
boolean save = updateById(byId);
//调用磅单回调接口
if(save){
return 1;
}
return 0;
return updatePoundBill(byId);
}
@Override
public int updateSteelPoundBill(PoundBill poundBill) {
//判断主榜单是否为新增状态
String appliid = poundBill.getAppliid();
Poundmst poundmst = poundmstService.getById(appliid);
if (!"1".equals(poundmst.getBllstt())) {
throw new RuntimeException("主磅单:" + poundmst.getUsrcode() + "状态不正确:");
}
//获取原单据数据
String id = poundBill.getId();
PoundBill byId = getById(id);
//判断当前单据状态是否为新增
if(!"1".equals(byId.getBillstate())){
throw new RuntimeException("当前磅单:" + byId.getUsrcode() + "状态不正确:");
}
//判断当前单据是否为复磅中
if (!"ing".equals(byId.getAgnstatus())) {
throw new RuntimeException("当前磅单:" + byId.getUsrcode() + "复磅状态不正确:");
}
//设置状态为完成
poundBill.setBillstate("2");
byId.setBillstate("2");
byId.setNetmqty(poundBill.getNetmqty());
//设置复磅状态为复磅完成
poundBill.setAgnstatus("completed");
byId.setAgnstatus("completed");
//设置当前时间为过毛重时间
poundBill.setWghdt(new Date());
byId.setWghdt(new Date());
//设置当前登录人为毛重司磅员
String currentUser = "admin";
try {
@ -698,13 +735,8 @@ public class PoundBillServiceImpl extends ServiceImpl<PoundBillMapper, PoundBill
}catch (Exception e){
//Do nothing
}
poundBill.setWghdtoprname(currentUser);
boolean save = updateById(poundBill);
//
if(save){
return 1;
}
return 0;
byId.setWghdtoprname(currentUser);
return updatePoundBill(byId);
}
/**
@ -716,6 +748,20 @@ public class PoundBillServiceImpl extends ServiceImpl<PoundBillMapper, PoundBill
@Override
public int deletePoundBillByIds(String[] ids)
{
//根据磅单id还原磅单数据
String firstId;
Poundmst poundmst;
if (ids != null && ids.length > 0) {
firstId = ids[0];
PoundBill byId = getById(firstId);
poundmst = poundmstService.getById(byId.getAppliid());
if (poundmst != null) {
//判断当前主榜单是否是新增状态
if (!"1".equals(poundmst.getBllstt())) {
throw new RuntimeException("主榜单:" + poundmst.getUsrcode() + "状态不正确:");
}
}
}
return poundBillMapper.deletePoundBillByIds(ids);
}

View File

@ -42,7 +42,7 @@ public class OaPurReturnService implements IOaReturnService{
throw new RuntimeException(e);
}
//设置榜单相关信息
util.setBillData(poundBill);
util.setBillDataWithoutIds(poundBill);
//设置过磅申请相关数据
String appliid = poundBill.getAppliid();
Poundappli poundappli = poundappliService.getById(appliid);

View File

@ -43,7 +43,7 @@ public class OaSalReturnService implements IOaReturnService {
throw new RuntimeException(e);
}
//设置榜单相关信息
util.setBillData(poundBill);
util.setBillDataWithoutIds(poundBill);
//设置过磅申请相关数据
String appliid = poundBill.getAppliid();
Poundappli poundappli = poundappliService.getById(appliid);

View File

@ -56,9 +56,7 @@ public class OaSpReturnService implements IOaReturnService{
throw new RuntimeException(e);
}
//设置榜单信息的数据
util.setBillData(poundBill);
poundBill.setFid("0");
poundBill.setFentity_fentryid("0");
util.setBillDataWithIds(poundBill);
//清空该主榜单下的所有明细的OAID
poundBillService.clearOaIDbyMst(appliid);
//设置主榜单为未完成

View File

@ -48,9 +48,7 @@ public class OaStkReturnService implements IOaReturnService{
}
//设置榜单信息的数据
util.setBillData(poundBill);
poundBill.setFid("0");
poundBill.setFentity_fentryid("0");
util.setBillDataWithIds(poundBill);
//设置主榜单为未完成
poundmstService.unCompleteBillMst(appliid);

View File

@ -21,6 +21,41 @@ public class Util {
poundBill.setWghmqty(BigDecimal.ZERO);
poundBill.setEmpmqty(BigDecimal.ZERO);
poundBill.setNetmqty(BigDecimal.ZERO);
poundBill.setFid("0");
poundBill.setFentity_fentryid("0");
poundBillService.updateById(poundBill);
}
// 保留设置fid和fentity_fentryid为"0"的方法
public void setBillDataWithIds(PoundBill poundBill) {
setCommonBillData(poundBill);
// 设置fid和fentity_fentryid为"0"
poundBill.setFid("0");
poundBill.setFentity_fentryid("0");
poundBillService.updateById(poundBill);
}
// 不设置fid和fentity_fentryid保持原有值或清空的方法
public void setBillDataWithoutIds(PoundBill poundBill) {
setCommonBillData(poundBill);
// 这里可以根据需求选择是否清空如需清空可以写成
// poundBill.setFid(null);
// poundBill.setFentity_fentryid(null);
poundBillService.updateById(poundBill);
}
// 提取公共逻辑到私有方法避免代码重复
private void setCommonBillData(PoundBill poundBill) {
poundBill.setAgngrossmqty(poundBill.getWghmqty());
poundBill.setAgntaremqty(poundBill.getEmpmqty());
poundBill.setAgnnetmqty(poundBill.getNetmqty());
poundBill.setAgnstatus("ing");
poundBill.setBillstate("1");
poundBill.setWghmqty(BigDecimal.ZERO);
poundBill.setEmpmqty(BigDecimal.ZERO);
poundBill.setNetmqty(BigDecimal.ZERO);
}
}

View File

@ -181,8 +181,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</trim>
FROM DUAL
WHERE NOT EXISTS (
SELECT 1 FROM t_data_poundappli
WHERE (fentity_fentryid = #{fentity_fentryid} OR (fentity_fentryid IS NULL AND #{fentity_fentryid} IS NULL)) )
SELECT 1 FROM t_data_poundappli
WHERE
-- 核心修改判断srcbilltype和fid是否同时相同
(srcbilltype = #{srcbilltype} OR (srcbilltype IS NULL AND #{srcbilltype} IS NULL))
AND
(fid = #{fid} OR (fid IS NULL AND #{fid} IS NULL))
)
</insert>

View File

@ -61,18 +61,23 @@ export const constantRoutes = [
component: () => import('@/views/error/401'),
hidden: true
},
// {
// path: '',
// component: Layout,
// redirect: 'index',
// children: [
// {
// path: 'index',
// component: () => import('@/views/index.vue'),
// name: 'Index',
// meta: { title: '首页', icon: 'dashboard', affix: true }
// }
// ]
// },
{
path: '',
component: Layout,
redirect: 'index',
children: [
{
path: 'index',
component: () => import('@/views/index.vue'),
name: 'Index',
meta: { title: '首页', icon: 'dashboard', affix: true }
}
]
redirect: '/measurement/operation/outinpound',
},
{
path: '/user',

View File

@ -144,7 +144,8 @@ export default {
Cookies.remove('rememberMe')
}
this.$store.dispatch("Login", this.loginForm).then(() => {
this.$router.push({ path: this.redirect || "/" }).catch(()=>{})
// this.$router.push({ path: this.redirect || "/" }).catch(()=>{})
this.$router.push({ path: "/" }).catch(()=>{})
}).catch(() => {
this.loading = false
if (this.captchaEnabled) {

View File

@ -110,7 +110,7 @@
@row-click="handleRowClick"
>
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="id" align="center" prop="id" />
<!-- <el-table-column label="id" align="center" prop="id" />-->
<el-table-column label="过磅状态" align="center" prop="bllstate">
<template slot-scope="scope">
<dict-tag :options="dict.type.pound_status" :value="scope.row.bllstate"/>

View File

@ -33,14 +33,6 @@
placeholder="请选择业务日期">
</el-date-picker>
</el-form-item>
<el-form-item label="业务类型" prop="bsnid">
<el-input
v-model="queryParams.bsnid"
placeholder="请输入业务类型"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="单据状态" prop="bllstt">
<el-select v-model="queryParams.bllstt" placeholder="请选择单据状态" clearable>
<el-option
@ -51,42 +43,10 @@
/>
</el-select>
</el-form-item>
<el-form-item label="物料id" prop="itmno">
<el-input
v-model="queryParams.itmno"
placeholder="请输入物料id"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="物料代码" prop="itmcode">
<el-form-item label="物料" prop="itmcode">
<el-input
v-model="queryParams.itmcode"
placeholder="请输入物料代码"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="物料名称" prop="itmname">
<el-input
v-model="queryParams.itmname"
placeholder="请输入物料名称"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="规格" prop="specification">
<el-input
v-model="queryParams.specification"
placeholder="请输入规格"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="计量单位" prop="msrunit">
<el-input
v-model="queryParams.msrunit"
placeholder="请输入计量单位"
placeholder="请输入物料"
clearable
@keyup.enter.native="handleQuery"
/>
@ -99,30 +59,6 @@
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="承运单位名称" prop="trnunitname">
<el-input
v-model="queryParams.trnunitname"
placeholder="请输入承运单位名称"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="业务单位" prop="bsunitid">
<el-input
v-model="queryParams.bsunitid"
placeholder="请输入业务单位"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="业务单位名称" prop="bsunitname">
<el-input
v-model="queryParams.bsunitname"
placeholder="请输入业务单位名称"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="发货单位" prop="sendunitid">
<el-input
v-model="queryParams.sendunitid"
@ -131,14 +67,6 @@
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="发货单位名称" prop="sendunitname">
<el-input
v-model="queryParams.sendunitname"
placeholder="请输入发货单位名称"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="收货单位" prop="recunitid">
<el-input
v-model="queryParams.recunitid"
@ -147,98 +75,10 @@
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="收货单位名称" prop="recunitname">
<el-input
v-model="queryParams.recunitname"
placeholder="请输入收货单位名称"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="业务磅点id" prop="poundid">
<el-form-item label="业务磅点" prop="poundid">
<el-input
v-model="queryParams.poundid"
placeholder="请输入业务磅点id"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="业务榜点名称" prop="poundname">
<el-input
v-model="queryParams.poundname"
placeholder="请输入业务榜点名称"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="炉号" prop="boilerno">
<el-input
v-model="queryParams.boilerno"
placeholder="请输入炉号"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="钢号" prop="steeno">
<el-input
v-model="queryParams.steeno"
placeholder="请输入钢号"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="长度" prop="unitlen">
<el-input
v-model="queryParams.unitlen"
placeholder="请输入长度"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="支数和" prop="carnoSum">
<el-input
v-model="queryParams.carnoSum"
placeholder="请输入支数和"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="重量和" prop="carmqtySum">
<el-input
v-model="queryParams.carmqtySum"
placeholder="请输入重量和"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="序号" prop="indexid">
<el-input
v-model="queryParams.indexid"
placeholder="请输入序号"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="连铸" prop="lzno">
<el-input
v-model="queryParams.lzno"
placeholder="请输入连铸"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="班别" prop="bbno">
<el-input
v-model="queryParams.bbno"
placeholder="请输入班别"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="登记部门" prop="crtorgid">
<el-input
v-model="queryParams.crtorgid"
placeholder="请输入登记部门"
placeholder="请输入业务磅点"
clearable
@keyup.enter.native="handleQuery"
/>
@ -251,54 +91,6 @@
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="创建时间" prop="crtdt">
<el-date-picker clearable
v-model="queryParams.crtdt"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择创建时间">
</el-date-picker>
</el-form-item>
<el-form-item label="创建人" prop="crtopr">
<el-input
v-model="queryParams.crtopr"
placeholder="请输入创建人"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="最后修改时间" prop="lstedtdt">
<el-date-picker clearable
v-model="queryParams.lstedtdt"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择最后修改时间">
</el-date-picker>
</el-form-item>
<el-form-item label="最后修改人" prop="lstedtopr">
<el-input
v-model="queryParams.lstedtopr"
placeholder="请输入最后修改人"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="回传星空ID" prop="fid">
<el-input
v-model="queryParams.fid"
placeholder="请输入回传星空ID"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="回传星空分录ID" prop="fentity_fentryid">
<el-input
v-model="queryParams.fentity_fentryid"
placeholder="请输入回传星空分录ID"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="星空单据类型" prop="oabilltype">
<el-select v-model="queryParams.oabilltype" placeholder="请选择星空单据类型" clearable>
<el-option

View File

@ -1188,6 +1188,12 @@ export default {
getPoundbill(this.poundBillDetailFormData.selectedIds[0]).then(response => {
this.poundBillDetailFormData.poundBillDetailForm = response.data;
const form = this.poundBillDetailFormData.poundBillDetailForm;
//0
if (form.wghmqty == null || form.wghmqty === 0) {
this.$message.error("当前明细没有毛重数据,请先称毛重!");
//
return;
}
//
form.empmqty = this.queryParams.weight;
//

View File

@ -1455,6 +1455,12 @@ watch: {
getPoundbill(this.poundBillDetailFormData.selectedIds[0]).then(response => {
this.poundBillDetailFormData.poundBillDetailForm = response.data;
const form = this.poundBillDetailFormData.poundBillDetailForm;
//0
if (form.wghmqty == null || form.wghmqty === 0) {
this.$message.error("当前明细没有毛重数据,请先称毛重!");
//
return;
}
//
form.empmqty = this.queryParams.weight;
//

View File

@ -919,11 +919,11 @@ export default {
this.$message.error("新增明细失败,请稍后重试!");
}
},
//
//
async updateWgtPoundBillDetail() {
//
if (this.poundBillDetailFormData.selectedIds.length === 0) {
this.$message.error("请选择过磅明细!");
if (this.poundBillDetailFormData.selectedIds.length !== 1) {
this.$message.error("请选择一条过磅明细!");
return;
}
console.log(this.poundBillDetailFormData.reWeighingStatus[0]);
@ -1232,8 +1232,8 @@ export default {
//
deletePoundBill() {
//
if (this.poundBillDetailFormData.selectedIds.length === 0) {
this.$message.error("请选择过磅明细!");
if (this.poundBillDetailFormData.selectedIds.length !== 1) {
this.$message.error("请选择一条过磅明细!");
return;
}
//