From 694d882c7a27bc276d37f1c06d0c67a03146e086 Mon Sep 17 00:00:00 2001
From: cuijian <cuijian@xalxzn.com>
Date: 星期四, 26 六月 2025 11:45:28 +0800
Subject: [PATCH] 基础数据,产线,班次,班组
---
src/views/base/FactoryManager.vue | 71 +++++++++++++++++------------------
1 files changed, 34 insertions(+), 37 deletions(-)
diff --git a/src/views/system/ProductionManager.vue b/src/views/base/FactoryManager.vue
similarity index 91%
rename from src/views/system/ProductionManager.vue
rename to src/views/base/FactoryManager.vue
index de94956..d0048aa 100644
--- a/src/views/system/ProductionManager.vue
+++ b/src/views/base/FactoryManager.vue
@@ -38,7 +38,7 @@
<!--@rightClick="rightHandle"-->
<!--:selectedKeys="selectedKeys"-->
<!--:checkedKeys="checkedKeys"-->
- <!--:treeData="departTree"-->
+ <!--:treeData="factoryTree"-->
<!--:checkStrictly="checkStrictly"-->
<!--:expandedKeys="iExpandedKeys"-->
<!--:autoExpandParent="autoExpandParent"-->
@@ -61,7 +61,7 @@
@rightClick="rightHandle"
:selectedKeys="selectedKeys"
:checkedKeys="checkedKeys"
- :treeData="departTree"
+ :treeData="factoryTree"
:checkStrictly="checkStrictly"
:expandedKeys="iExpandedKeys"
:autoExpandParent="autoExpandParent"
@@ -93,11 +93,11 @@
<a-tab-pane tab="鍩烘湰淇℃伅" key="1">
<a-card :bordered="false" v-if="selectedKeys.length>0">
<a-form-model ref="form" :model="model" :rules="validatorRules">
- <a-form-model-item :labelCol="labelCol" :wrapperCol="wrapperCol" prop="productionCode" label="杞﹂棿缂栧彿">
- <a-input placeholder="璇疯緭鍏ヤ骇绾�/杞﹂棿缂栧彿" v-model="model.productionCode"/>
+ <a-form-model-item :labelCol="labelCol" :wrapperCol="wrapperCol" prop="factoryCode" label="杞﹂棿缂栧彿">
+ <a-input placeholder="璇疯緭鍏ヤ骇绾�/杞﹂棿缂栧彿" v-model="model.factoryCode"/>
</a-form-model-item>
- <a-form-model-item :labelCol="labelCol" :wrapperCol="wrapperCol" prop="productionName" label="杞﹂棿鍚嶇О">
- <a-input placeholder="璇疯緭鍏ヤ骇绾�/杞﹂棿鍚嶇О" v-model="model.productionName"/>
+ <a-form-model-item :labelCol="labelCol" :wrapperCol="wrapperCol" prop="factoryName" label="杞﹂棿鍚嶇О">
+ <a-input placeholder="璇疯緭鍏ヤ骇绾�/杞﹂棿鍚嶇О" v-model="model.factoryName"/>
</a-form-model-item>
<a-form-model-item :labelCol="labelCol" :wrapperCol="wrapperCol" label="涓婄骇杞﹂棿">
<a-tree-select
@@ -110,10 +110,10 @@
</a-tree-select>
</a-form-model-item>
<a-form-model-item :labelCol="labelCol" :wrapperCol="wrapperCol" label="鎺掑簭">
- <a-input-number v-model="model.productionOrder"/>
+ <a-input-number v-model="model.sorter"/>
</a-form-model-item>
<a-form-model-item :labelCol="labelCol" :wrapperCol="wrapperCol" label="澶囨敞">
- <a-textarea placeholder="璇疯緭鍏ュ娉�" v-model="model.memo"/>
+ <a-textarea placeholder="璇疯緭鍏ュ娉�" v-model="model.remark"/>
</a-form-model-item>
</a-form-model>
<div class="anty-form-btn">
@@ -127,32 +127,29 @@
</a-empty>
</a-card>
</a-tab-pane>
- <!--<a-tab-pane tab="閮ㄩ棬鏉冮檺" key="2" forceRender>-->
- <!--<depart-auth-modal ref="departAuth"/>-->
- <!--</a-tab-pane>-->
- <a-tab-pane tab="璁惧鍒楄〃" key="2" forceRender>
- <!--<depart-auth-modal/>-->
- <production-equipment ref="departAuth"></production-equipment>
- </a-tab-pane>
+
+ <!-- <a-tab-pane tab="璁惧鍒楄〃" key="2" forceRender>
+ <factory-equipment ref="departAuth"></factory-equipment>
+ </a-tab-pane> -->
</a-tabs>
</a-col>
- <production-modal ref="departModal" @ok="loadTree"></production-modal>
+ <factory-modal ref="departModal" @ok="loadTree"></factory-modal>
</a-row>
</template>
<script>
- import ProductionEquipment from './modules/ProductionManager/ProductionEquipment'
- import { queryProductionTreeList, searchByKeywords, deleteByProduction } from '@/api/api'
+ import FactoryEquipment from './modules/FactoryManager/FactoryEquipment'
+ import { queryFactoryTreeList, searchByKeywords, deleteByFactory } from '@/api/api'
import { httpAction, deleteAction } from '@/api/manage'
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
- import ProductionModal from './modules/ProductionManager/ProductionModal'
+ import FactoryModal from './modules/FactoryManager/FactoryModal'
export default {
- name: 'ProductionManager',
+ name: 'FactoryManager',
mixins: [JeecgListMixin],
components: {
- ProductionEquipment,
- ProductionModal
+ FactoryEquipment,
+ FactoryModal
},
data() {
return {
@@ -164,7 +161,7 @@
disable: true,
treeData: [],
visible: false,
- departTree: [],
+ factoryTree: [],
rightClickSelectedKey: '',
rightClickSelectedOrgCode: '',
hiding: true,
@@ -191,14 +188,14 @@
edges: []
},
validatorRules: {
- productionName: [{ required: true, message: '璇疯緭鍏ヤ骇绾�/杞﹂棿鍚嶇О!' }]
+ factoryName: [{ required: true, message: '璇疯緭鍏ヤ骇绾�/杞﹂棿鍚嶇О!' }]
},
url: {
- delete: '/mdc/mdcProduction/delete',
- edit: '/mdc/mdcProduction/edit',
- deleteBatch: '/mdc/mdcProduction/deleteBatch',
- exportXlsUrl: '/mdc/mdcProduction/exportXls',
- importExcelUrl: '/mdc/mdcProduction/importExcel'
+ delete: '/base/factory/delete',
+ edit: '/base/factory/edit',
+ deleteBatch: '/base/factory/deleteBatch',
+ exportXlsUrl: '/base/factory/exportXls',
+ importExcelUrl: '/base/factory/importExcel'
},
orgCategoryDisabled: false,
isIncludesNotLeaf: false
@@ -216,15 +213,15 @@
loadTree() {
var that = this
that.treeData = []
- that.departTree = []
- queryProductionTreeList().then((res) => {
+ that.factoryTree = []
+ queryFactoryTreeList().then((res) => {
if (res.success) {
//閮ㄩ棬鍏ㄩ�夊悗锛屽啀娣诲姞閮ㄩ棬锛岄�変腑鏁伴噺澧炲
this.allTreeKeys = []
for (let i = 0; i < res.result.length; i++) {
let temp = res.result[i]
that.treeData.push(temp)
- that.departTree.push(temp)
+ that.factoryTree.push(temp)
that.setThisExpandedKeys(temp)
that.getAllKeys(temp)
// console.log(temp.id)
@@ -277,7 +274,7 @@
batchDel: function() {
console.log(this.checkedKeys)
this.isIncludesNotLeaf = false
- this.includesNotLeaf(this.departTree)
+ this.includesNotLeaf(this.factoryTree)
console.log('isIncludesNotLeaf', this.isIncludesNotLeaf)
// 涓簍rue鍒欒〃绀洪�変腑椤瑰寘鍚潪鍙跺瓙缁撶偣 false鍒欒〃绀洪�変腑椤瑰潎涓哄彾瀛愮粨鐐�
@@ -340,10 +337,10 @@
if (value) {
searchByKeywords({ keyWord: value }).then((res) => {
if (res.success) {
- that.departTree = []
+ that.factoryTree = []
for (let i = 0; i < res.result.length; i++) {
let temp = res.result[i]
- that.departTree.push(temp)
+ that.factoryTree.push(temp)
}
} else {
// that.$message.warning(res.message)
@@ -481,7 +478,7 @@
this.$refs.departModal.add(this.selectedKeys)
this.$refs.departModal.title = '鏂板'
} else {
- this.$refs.departModal.add(this.rightClickSelectedKey)
+ this.$refs.departModal.add(this.currSelected)
this.$refs.departModal.title = '鏂板'
}
},
@@ -492,7 +489,7 @@
title: '纭鍒犻櫎',
content: `纭畾瑕佸垹闄� ${that.currSelected.productionName} 鍚�?`,
onOk: function() {
- deleteByProduction({ id: that.currSelected.id }).then((resp) => {
+ deleteByFactory({ id: that.currSelected.id }).then((resp) => {
if (resp.success) {
//鍒犻櫎鎴愬姛鍚庯紝鍘婚櫎宸查�変腑涓殑鏁版嵁
// that.checkedKeys.splice(that.checkedKeys.findIndex(key => key === that.rightClickSelectedKey), 1)
--
Gitblit v1.9.3