|
|
@@ -970,7 +970,7 @@ const handleNodeClick = async (node) => {
|
|
|
};
|
|
|
|
|
|
//全局调用工单编号
|
|
|
-const _Gd_gdbh = ref("Y2407037")
|
|
|
+const _Gd_gdbh = ref('')
|
|
|
//全局调用产品代号
|
|
|
const _Gd_cpdh = ref(null)
|
|
|
//全局调用产品名称
|
|
|
@@ -1035,7 +1035,7 @@ const _WorkList_page = async () => {
|
|
|
'审核日期':'2024/6/27'
|
|
|
},
|
|
|
];
|
|
|
- console.log("上方表格数据")
|
|
|
+ console.log("上方表格数据")
|
|
|
console.log(WorkListdata)
|
|
|
tableData.splice(0,tableData.length,...WorkListdata);//表格数据
|
|
|
total.value =WorkListdata.data.total;//共多少条
|
|
|
@@ -1392,6 +1392,7 @@ const add_gxcloseDialog = () => {
|
|
|
|
|
|
// =========== 订单打印 ===========
|
|
|
const cp_gdprintonClick = () => {
|
|
|
+ console.log(_Gd_gdbh.value)
|
|
|
// yunying/components/print页面
|
|
|
printPageRef.value.open(_Gd_gdbh.value)
|
|
|
}
|
|
|
@@ -1409,7 +1410,8 @@ const ddtableData = reactive([])
|
|
|
const jstableData = reactive([])
|
|
|
// 点击工单行按钮
|
|
|
const tableRowClick = async (row) => {
|
|
|
-
|
|
|
+ console.log(row.订单号)
|
|
|
+ _Gd_gdbh.value = row.订单号
|
|
|
if(row.订单号 === '2408001' ){
|
|
|
ystableData.length = 0
|
|
|
try {
|
|
|
@@ -1586,7 +1588,7 @@ const tableRowClick = async (row) => {
|
|
|
gytableData.splice(0,gyData.length,...gyData);//表格数据
|
|
|
ddtableData.splice(0,ddData.length,...ddData);//表格数据
|
|
|
jstableData.splice(0,jsData.length,...jsData);//表格数据
|
|
|
- console.log(ystableData)
|
|
|
+ // console.log(ystableData)
|
|
|
} catch (error) {
|
|
|
console.error(error);
|
|
|
}
|
|
|
@@ -3409,246 +3411,6 @@ const _U8Trial = async ()=>{
|
|
|
const oncloneclick = () => {tlsslist.value = false;};
|
|
|
|
|
|
|
|
|
-//===========工单状态设置按钮=======
|
|
|
-// const onstatuslist = ref(false);
|
|
|
-// const statusformData = reactive({gdbh: '',});
|
|
|
-// const status = ref('计划中'); // 默认选择
|
|
|
-// const onStatusClick = () => {
|
|
|
-// if(_Gd_gdbh.value === null || _Gd_gdbh.value === ''){
|
|
|
-// onstatuslist.value = false;
|
|
|
-// ElMessage({
|
|
|
-// type: 'warning',
|
|
|
-// message: '请选择树形后,再操作此功能'
|
|
|
-// })
|
|
|
-// }else{
|
|
|
-// statusformData['gdbh'] = _Gd_gdbh.value;
|
|
|
-// onstatuslist.value = true;
|
|
|
-// }
|
|
|
-// };
|
|
|
-//工单状态设置【放弃按钮】
|
|
|
-// const handleCancel = () => {
|
|
|
-// onstatuslist.value = false;
|
|
|
-// };
|
|
|
-// //工单状态设置【执行按钮】
|
|
|
-// const handleConfirm = async () => {
|
|
|
-// //工单编号
|
|
|
-// let workOrder = statusformData['gdbh'];
|
|
|
-// //状态
|
|
|
-// let statusCode;
|
|
|
-// if (status.value === '计划中') {
|
|
|
-// statusCode = "3-计划中";
|
|
|
-// } else if (status.value === '生产中') {
|
|
|
-// statusCode = "2-生产中";
|
|
|
-// }else if (status.value === '已完工') {
|
|
|
-// statusCode = "1-已完工";
|
|
|
-// }
|
|
|
-// const StatusEditdata = await StatusEdit({workOrder:workOrder,status:statusCode});
|
|
|
-// if (StatusEditdata.code === 0) {
|
|
|
-// ElMessage({type: 'success',message: '更新成功'})
|
|
|
-// } else {
|
|
|
-// ElMessage({type: 'error',message: '更新失败'})
|
|
|
-// }
|
|
|
-// onstatuslist.value = false;
|
|
|
-// };
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-// =========== 引用产品资料 ===========
|
|
|
-// const yycpzlformData = reactive({
|
|
|
-// gdbh: '',
|
|
|
-// khdh: '',
|
|
|
-// khmc: '',
|
|
|
-// cpdh: '',
|
|
|
-// cpmc: '',
|
|
|
-// yjzl:true,
|
|
|
-// gyap: true,
|
|
|
-// gyfa: '',
|
|
|
-// fangan: 'A',
|
|
|
-// });
|
|
|
-// const onyycpzllist = ref(false);
|
|
|
-// const fanganRef = ref();
|
|
|
-// const yyzltableData = ref([]);
|
|
|
-
|
|
|
-// //引用产品资料【按钮】
|
|
|
-// const onyycpzlclick = () => {
|
|
|
-// if(_Gd_gdbh.value == null){
|
|
|
-// onyycpzllist.value = false;
|
|
|
-// ElMessage({type: 'warning',message: '请选择具体的工单后,再操作此功能'})
|
|
|
-// }else{
|
|
|
-// yycpzlformData['gdbh'] = _Gd_gdbh.value;
|
|
|
-// // yycpzlformData['cpdh'] = _Gd_cpdh.value;
|
|
|
-// yyzltableData.value = [];
|
|
|
-// _WorkOrderDetailCopedata();
|
|
|
-// onyycpzllist.value = true;
|
|
|
-// }
|
|
|
-// };
|
|
|
-// //引用产品资料工单编号【回车】
|
|
|
-// const yycpzlProductValue = async (e) => {
|
|
|
-// if (e.code === 'Enter') {
|
|
|
-// if (yycpzlformData['gdbh'] == null || yycpzlformData['gdbh'] == '') {
|
|
|
-// ElMessage({ type: 'warning', message: '工单编号不能为空' })
|
|
|
-// return false;
|
|
|
-// }
|
|
|
-// await _DetailCope();
|
|
|
-// }
|
|
|
-// if (e.code === 'Tab') {
|
|
|
-// await _WorkOrderDetailCopedata()
|
|
|
-// fanganKeyDown()
|
|
|
-// }
|
|
|
-// };
|
|
|
-// // const fanganProductValue = async (e) => {
|
|
|
-// // if (e.code === 'Tab') {
|
|
|
-// // console.log(123)
|
|
|
-// // await _WorkOrderDetailCopedata()
|
|
|
-// // fanganRef.value.focus()
|
|
|
-// // }
|
|
|
-// // };
|
|
|
-
|
|
|
-// const WorkOrderDetailCopesFangan = ref([])
|
|
|
-// const defaultSelectionFangan = ref()
|
|
|
-// //引用产品资料->获取产品资料
|
|
|
-// const _WorkOrderDetailCopedata = async ()=>{
|
|
|
-// let search = yycpzlformData['gdbh'];
|
|
|
-// // 2403725 是带两个方案的
|
|
|
-// const WorkOrderDetailCopes = await ProductCopeDetail({workorder:search});
|
|
|
-// console.log(WorkOrderDetailCopes)
|
|
|
-// // fanganRef.value.focus()
|
|
|
-// if(WorkOrderDetailCopes.msg === '未找到工单信息'){
|
|
|
-// yycpzlformData['khdh'] = '';
|
|
|
-// yycpzlformData['khmc'] = '';
|
|
|
-// yycpzlformData['cpdh'] = '';
|
|
|
-// yycpzlformData['cpmc'] = '';
|
|
|
-// // ElMessage({type: 'warning',message: '未找到工单信息'})
|
|
|
-// return false;
|
|
|
-// }else{
|
|
|
-// yycpzlformData['gdbh'] = WorkOrderDetailCopes.data['工单编号'];
|
|
|
-// yycpzlformData['khdh'] = WorkOrderDetailCopes.data['客户编号'];
|
|
|
-// yycpzlformData['khmc'] = WorkOrderDetailCopes.data['客户名称'];
|
|
|
-// yycpzlformData['cpdh'] = WorkOrderDetailCopes.data['产品编号'];
|
|
|
-// yycpzlformData['cpmc'] = WorkOrderDetailCopes.data['产品名称'];
|
|
|
-// yycpzlformData['fangan'] = WorkOrderDetailCopes.data['方案'][0]['方案'];
|
|
|
-// defaultSelectionFangan.value = WorkOrderDetailCopes.data['方案'][0]['方案']
|
|
|
-// WorkOrderDetailCopesFangan.value = WorkOrderDetailCopes.data['方案']
|
|
|
-// }
|
|
|
-// }
|
|
|
-
|
|
|
-// // const yycppshuaxin_click = async ()=>{
|
|
|
-// // let search = yycpzlformData['gdbh'];
|
|
|
-// // console.log(search)
|
|
|
-// // const WorkOrderDetailCope_table = await WorkOrderDetailCope({search:search});
|
|
|
-// // console.log(WorkOrderDetailCope_table)
|
|
|
-// // yyzltableData.value = WorkOrderDetailCope_table.data
|
|
|
-// // }
|
|
|
-// const _DetailCope = async (row)=>{
|
|
|
-// let search = yycpzlformData['gdbh'];
|
|
|
-// console.log(search)
|
|
|
-// const WorkOrderDetailCope_table = await WorkOrderDetailCope({search:search});
|
|
|
-// console.log(WorkOrderDetailCope_table)
|
|
|
-// yyzltableData.value = WorkOrderDetailCope_table.data
|
|
|
-// }
|
|
|
-// const yyzltableRowClick = async (row)=>{
|
|
|
-// yycpzlformData['gdbh'] = row['工单编号'];
|
|
|
-// _WorkOrderDetailCopedata();
|
|
|
-// }
|
|
|
-
|
|
|
-// const setFangan = (node) => {
|
|
|
-// yycpzlformData['fangan'] = node['方案']
|
|
|
-// defaultSelectionFangan.value = node['方案']
|
|
|
-// document.removeEventListener('keydown', () => {})
|
|
|
-// openFangan.value = false
|
|
|
-// }
|
|
|
-
|
|
|
-// const openFangan = ref(false)
|
|
|
-// const fanganKeyDown = () => {
|
|
|
-// //2403725
|
|
|
-// if (WorkOrderDetailCopesFangan.value.length > 1) {
|
|
|
-// openFangan.value = true
|
|
|
-// document.addEventListener('keydown', (e) => {
|
|
|
-// let currentIndex
|
|
|
-// WorkOrderDetailCopesFangan.value.map( (item, index) => {
|
|
|
-// if (item['方案'] === defaultSelectionFangan.value[0]) {
|
|
|
-// currentIndex = index
|
|
|
-// }
|
|
|
-// })
|
|
|
-// if (e.code === 'ArrowDown') {
|
|
|
-// if (WorkOrderDetailCopesFangan.value[currentIndex + 1]) {
|
|
|
-// defaultSelectionFangan.value = WorkOrderDetailCopesFangan.value[currentIndex + 1]['方案']
|
|
|
-// } else {
|
|
|
-// defaultSelectionFangan.value = WorkOrderDetailCopesFangan.value[0]['方案']
|
|
|
-// }
|
|
|
-// }
|
|
|
-// if (e.code === 'ArrowUp') {
|
|
|
-// if (WorkOrderDetailCopesFangan.value[currentIndex - 1]) {
|
|
|
-// defaultSelectionFangan.value = WorkOrderDetailCopesFangan.value[currentIndex - 1]['方案']
|
|
|
-// } else {
|
|
|
-// defaultSelectionFangan.value = WorkOrderDetailCopesFangan.value[WorkOrderDetailCopesFangan.value.length - 1]['方案']
|
|
|
-// }
|
|
|
-// }
|
|
|
-// if (e.code === 'Enter') {
|
|
|
-// yycpzlformData['fangan'] = defaultSelectionFangan.value
|
|
|
-// console.log(12312312312312321321321321)
|
|
|
-// document.removeEventListener('keydown', (e) => {
|
|
|
-// console.log(e)
|
|
|
-// })
|
|
|
-// openFangan.value = false
|
|
|
-// }
|
|
|
-// })
|
|
|
-// }
|
|
|
-// }
|
|
|
-// //引用产品资料【执行】按钮
|
|
|
-// const yycpzlhandleConfirm = async () => {
|
|
|
-// _ProductInformationEdit();
|
|
|
-// };
|
|
|
-// //引用产品资料->获取产品资料
|
|
|
-// const _ProductInformationEdit = async ()=>{
|
|
|
-// console.log(yycpzlformData)
|
|
|
-// if(yycpzlformData['gdbh'] === null || yycpzlformData['gdbh'] === undefined){
|
|
|
-// ElMessage({type: 'warning', message: '工单编号为空'});
|
|
|
-// return false;
|
|
|
-// }
|
|
|
-// if(yycpzlformData['cpdh'] === null || yycpzlformData['cpdh'] === undefined){
|
|
|
-// ElMessage({type: 'warning', message: '产品代号为空'});
|
|
|
-// return false;
|
|
|
-// }
|
|
|
-// if(yycpzlformData['fangan'] === null || yycpzlformData['fangan'] === undefined){
|
|
|
-// ElMessage({type: 'warning', message: '工艺方案为空'});
|
|
|
-// return false;
|
|
|
-// }
|
|
|
-// let params = {}
|
|
|
-// params.workorder = _Gd_gdbh.value;
|
|
|
-// params.productCode = yycpzlformData['cpdh'];
|
|
|
-// params.option = yycpzlformData['fangan'];
|
|
|
-// console.log(params)
|
|
|
-// try {
|
|
|
-// const ProductInformationEditdata = await WorkOrderDetailListCope(params);
|
|
|
-// if (ProductInformationEditdata.code === 0) {
|
|
|
-// const workOrderListDetail_data = await workOrderListDetail({Gd_gdbh:_Gd_gdbh.value});
|
|
|
-// yjtableData.value = workOrderListDetail_data.data.printList;
|
|
|
-// ElMessage({type: 'success', message: '更新成功'})
|
|
|
-// onyycpzllist.value = false;
|
|
|
-// }
|
|
|
-// // else {
|
|
|
-// // ElMessage({type: 'error',message: '更新失败'})
|
|
|
-// // }
|
|
|
-// } catch (error) {
|
|
|
-// console.error(error);
|
|
|
-// }
|
|
|
-// }
|
|
|
-// //引用产品资料【放弃】
|
|
|
-// const yycpzlhandleCancel = () => {onyycpzllist.value = false;};
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
// 行为控制标记(弹窗内部需要增还是改)
|
|
|
const type = ref('')
|
|
|
|