|
|
@@ -2428,6 +2428,7 @@ const FacilityProduction = async (addr) => {
|
|
|
formData.value.工序号 = response.data.工序名称.substring(0,2);
|
|
|
formData.value.工序名称 = response.data.工序名称;
|
|
|
formData.value.产品名称 = response.data.产品名称;
|
|
|
+ formData.value.产品代号 = response.data.产品代号;
|
|
|
formData.value.班组Id=response.data.班组Id
|
|
|
formData.value.machine=JTMC
|
|
|
formData.value.状态=response.data.状态
|
|
|
@@ -3161,10 +3162,24 @@ const yinbanNodeClick = (node, check, nodeData) => {
|
|
|
}
|
|
|
};
|
|
|
const onyinban = async() => {
|
|
|
- console.log(formData)
|
|
|
- const res = await facilityPrintGetTab({productCode:formData.value.工单编号})
|
|
|
+ console.log(formData.value)
|
|
|
+ if(formData.value.产品代号==''){
|
|
|
+ ElMessage({
|
|
|
+ type: 'warning',
|
|
|
+ message: '该工单没有产品编号'
|
|
|
+ })
|
|
|
+ return false
|
|
|
+ }
|
|
|
+ const res = await facilityPrintGetTab({productCode:formData.value.产品代号})
|
|
|
// const res = await facilityPrintGetTab({productCode:'104601001'})
|
|
|
- if(res.code===0){
|
|
|
+ if(res.code===0){
|
|
|
+ if(res.data==null){
|
|
|
+ ElMessage({
|
|
|
+ type: 'warning',
|
|
|
+ message: '该产品没有印版资料'
|
|
|
+ })
|
|
|
+ return false
|
|
|
+ }
|
|
|
yinbantreeData.value=[{
|
|
|
label:'产品印版库',
|
|
|
children:res.data.map(item=>({
|