From 25cc86fd8a2fb3b2bb6b385cba0adaf89ff3dcdc Mon Sep 17 00:00:00 2001
From: chenlu <1320612696@qq.com>
Date: 星期四, 18 十二月 2025 16:39:32 +0800
Subject: [PATCH] 流程卡进度打印部分代码
---
north-glass-erp/northglass-erp/src/views/pp/processCard/ProductionScheduling.vue | 135 ++++++++++++++++++++++----------------------
1 files changed, 68 insertions(+), 67 deletions(-)
diff --git a/north-glass-erp/northglass-erp/src/views/pp/processCard/ProductionScheduling.vue b/north-glass-erp/northglass-erp/src/views/pp/processCard/ProductionScheduling.vue
index a0ea302..443bbc8 100644
--- a/north-glass-erp/northglass-erp/src/views/pp/processCard/ProductionScheduling.vue
+++ b/north-glass-erp/northglass-erp/src/views/pp/processCard/ProductionScheduling.vue
@@ -38,7 +38,7 @@
//宸ュ簭
-const processVal = ref('鍒囧壊')
+const processVal = ref(t('machine.cutting'))
//鎺掍骇鐘舵��
@@ -98,7 +98,7 @@
.toISOString()
.replace('T', ' ')
.slice(0, 10) //榛樿寮�濮嬫椂闂�3澶╁墠
- const end = new Date(new Date().getTime() + 3600 * 1000 * 24)
+ const end = new Date(new Date().getTime())
.toISOString()
.replace('T', ' ')
.slice(0, 10)//榛樿缁撴潫鏃堕棿褰撳墠鏃堕棿
@@ -431,7 +431,7 @@
if ($table) {
const selectRecords = $table.getCheckboxRecords()
if (selectRecords.length == 0) {
- ElMessage.warning("璇峰嬀閫夋帓浜ф暟鎹�")
+ ElMessage.warning(t('processCard.checkProductionScheduling'))
return;
}
for (let i = 0; i < selectRecords.length; i++) {
@@ -440,13 +440,13 @@
let number = selectRecords[i].schedulingQuantity
//璁″垝寮�濮嬨�佺粨鏉熸椂闂达紝鎺掍骇鏁伴噺涓嶈兘涓虹┖
if (start == null || end == null || number == null) {
- ElMessage.warning("璇峰~鍏ュ搴旂殑鍊煎啀杩涜淇濆瓨")
+ ElMessage.warning(t('processCard.saveCorrespondingValues'))
return;
}
}
let selectProcesses = processVal.value
if (selectProcesses == null || selectProcesses == "") {
- ElMessage.warning("璇烽�夋嫨鎺掍骇宸ュ簭")
+ ElMessage.warning(t('processCard.selectProductionSchedulingProcess'))
return;
}
@@ -460,7 +460,7 @@
//淇濆瓨鎺掍骇鏁版嵁
request.post("/productionScheduling/addScheduling", schedulingData.value).then((res) => {
if (res.code == 200) {
- ElMessage.success("淇濆瓨鎴愬姛")
+ ElMessage.success(t('basicData.msg.saveSuccess'))
// 鍚敤淇濆瓨
gridOptions.toolbarConfig.buttons[2].disabled = false
router.push({
@@ -485,11 +485,11 @@
const selectRecords = $table.getCheckboxRecords()
if ($table) {
if (selectRecords.length == 0) {
- ElMessage.warning("璇峰嬀閫夋帓浜ф暟鎹�")
+ ElMessage.warning(t('processCard.checkProductionScheduling'))
return;
}
- const type = await VXETable.modal.confirm('鎮ㄧ‘瀹氳鍒犻櫎璇ユ暟鎹�?')
+ const type = await VXETable.modal.confirm(t('processCard.deleteThisData'))
if (type === 'confirm') {
let schedulingData = ref({
scheduling: selectRecords,
@@ -497,7 +497,7 @@
request.post("/productionScheduling/deleteScheduling", schedulingData.value).then((res) => {
if (res.code == 200) {
- ElMessage.success("鍒犻櫎鎴愬姛")
+ ElMessage.success(t('basicData.msg.deleteSuccess'))
location.reload();
} else {
ElMessage.warning(res.msg)
@@ -517,7 +517,7 @@
let inputVal = form.orderId
if ($table) {
if (selectRecords.length == 0) {
- ElMessage.warning("璇峰嬀閫夋帓浜ф暟鎹�")
+ ElMessage.warning(t('processCard.checkProductionScheduling'))
return;
}
let schedulingData = ref({
@@ -526,7 +526,7 @@
})
request.post("/productionScheduling/examineScheduling", schedulingData.value).then((res) => {
if (res.code == 200) {
- ElMessage.success("瀹℃牳鎴愬姛")
+ ElMessage.success(t('basicData.msg.ReviewSuccess'))
router.push({
path: '/main/processCard/ProductionScheduling',
query: {random: Math.random()}
@@ -545,7 +545,7 @@
const selectRecords = $table.getCheckboxRecords()
if ($table) {
if (selectRecords.length == 0) {
- ElMessage.warning("璇峰嬀閫夋帓浜ф暟鎹�")
+ ElMessage.warning(t('processCard.checkProductionScheduling'))
return;
}
let schedulingData = ref({
@@ -554,7 +554,7 @@
})
request.post("/productionScheduling/cancelReviewScheduling", schedulingData.value).then((res) => {
if (res.code == 200) {
- ElMessage.success("鍙嶅鎴愬姛")
+ ElMessage.success(t('basicData.msg.cancelReviewSuccess'))
location.reload();
} else {
ElMessage.warning(res.msg)
@@ -629,7 +629,7 @@
let selectState = stateValue.value
selectRecords.forEach((selectRecords) => {
if (selectRecords.schedulingQuantity > selectRecords.pendingProductionQuantity) {
- ElMessage.warning("鎺掍骇鏁伴噺涓嶈兘澶т簬寰呮帓浜ф暟閲�")
+ ElMessage.warning(ElMessage.warning(t('processCard.schedulingQuantityNoQuantityScheduled')))
//绂佺敤淇濆瓨鎸夐挳
//gridOptions.toolbarConfig.buttons[2].disabled = true
}
@@ -651,15 +651,14 @@
</script>
<template>
- <div class="main-div-customer">
- <div id="selectForm">
- <el-row :gutter="0">
+ <div style="width: 100%;height: 100%">
+ <div class="head">
<el-date-picker
v-model="orderInfo.workOrderDate"
:default-time="defaultTime"
- end-placeholder="缁撴潫鏃堕棿"
+ :start-placeholder="$t('basicData.startDate')"
+ :end-placeholder="$t('basicData.endDate')"
format="YYYY/MM/DD"
- start-placeholder="寮�濮嬫椂闂�"
type="daterange"
value-format="YYYY-MM-DD"
@@ -676,7 +675,7 @@
/>
</el-select>
- <el-select v-model="stateValue" class="m-2" placeholder="鏄惁鎺掍骇" style="width: 120px">
+ <el-select v-model="stateValue" class="m-2" :placeholder="$t('processCard.whetherToScheduleProduction')" style="width: 120px">
<el-option
v-for="item in stateOptions"
:key="item.value"
@@ -690,67 +689,69 @@
:icon="Search"
type="primary" @click="getWorkOrder">{{ $t('basicData.search') }}
</el-button>
- </el-row>
</div>
- <vxe-grid
- ref="xGrid"
- class="mytable-scrollbar"
- height="95%"
- v-bind="gridOptions"
- v-on="gridEvents"
- @filter-change="filterChanged"
+ <div class="main-table">
+ <vxe-grid
+ ref="xGrid"
+ class="mytable-scrollbar"
+ height="100%"
+ v-bind="gridOptions"
+ v-on="gridEvents"
+ @filter-change="filterChanged"
- >
- <!-- :checkbox-config="checkBoxConfig" @checkbox-change="determineNum"-->
- <!-- 涓嬫媺鏄剧ず鎵�鏈変俊鎭彃妲�-->
- <template #content="{ row }">
- <ul class="expand-wrapper">
- <li v-for="(item,index) in gridOptions.columns" v-show="item.field!=undefined ">
- <span style="font-weight: bold">{{ item.title + ': ' }}</span>
- <span v-if="hasDecimal(item.field)">{{ row[item.field.split('.')[0]][item.field.split('.')[1]] }}</span>
- <span v-else>{{ row[item.field] }}</span>
+ >
+ <!-- :checkbox-config="checkBoxConfig" @checkbox-change="determineNum"-->
+ <!-- 涓嬫媺鏄剧ず鎵�鏈変俊鎭彃妲�-->
+ <template #content="{ row }">
+ <ul class="expand-wrapper">
+ <li v-for="(item,index) in gridOptions.columns" v-show="item.field!=undefined ">
+ <span style="font-weight: bold">{{ item.title + ': ' }}</span>
+ <span v-if="hasDecimal(item.field)">{{ row[item.field.split('.')[0]][item.field.split('.')[1]] }}</span>
+ <span v-else>{{ row[item.field] }}</span>
- </li>
- </ul>
- </template>
- <template #num1_filter="{ column, $panel }">
- <div>
- <div v-for="(option, index) in column.filters" :key="index">
- <input v-model="option.data" type="type" @input="changeFilterEvent($event, option, $panel)"/>
+ </li>
+ </ul>
+ </template>
+ <template #num1_filter="{ column, $panel }">
+ <div>
+ <div v-for="(option, index) in column.filters" :key="index">
+ <input v-model="option.data" type="type"
+ @keyup.enter.native="$panel.confirmFilter()"
+ @input="changeFilterEvent($event, option, $panel)"/>
+ </div>
</div>
- </div>
- </template>
- <template #pager>
- <!--浣跨敤 pager 鎻掓Ы-->
- <!-- 'PrevJump','NextJump', -->
- <vxe-pager
- v-model:current-page="pageNum"
- v-model:page-size="total.pageSize"
- v-model:pager-count="total.pageTotal"
- :layouts="[ 'PrevPage', 'Jump','PageCount', 'NextPage', 'Total']"
- :total="total.dataTotal"
- @page-change="handlePageChange"
- >
- </vxe-pager>
- </template>
+ </template>
+ <template #pager>
+ <!--浣跨敤 pager 鎻掓Ы-->
+ <!-- 'PrevJump','NextJump', -->
+ <vxe-pager
+ v-model:current-page="pageNum"
+ v-model:page-size="total.pageSize"
+ v-model:pager-count="total.pageTotal"
+ :layouts="[ 'PrevPage', 'Jump','PageCount', 'NextPage', 'Total']"
+ :total="total.dataTotal"
+ @page-change="handlePageChange"
+ >
+ </vxe-pager>
+ </template>
- </vxe-grid>
+ </vxe-grid>
+ </div>
</div>
</template>
<style scoped>
-.main-div-customer {
- width: 99%;
- height: 100%;
+.head{
+ width: 100%;
+ height: 35px;
}
-#selectForm {
- width: 70%;
- height: 6%;
- text-align: center;
+.main-table{
+ width: 100%;
+ height: calc(100% - 35px);
}
.vxe-grid {
--
Gitblit v1.8.0