From 67a2e68fbd740189de38827806b8daf6753b536e Mon Sep 17 00:00:00 2001
From: guoyuji <guoyujie@ng.com>
Date: 星期一, 25 十二月 2023 14:01:31 +0800
Subject: [PATCH] Merge branch 'master' of http://10.153.19.25:10101/r/ERP_override
---
north-glass-erp/northglass-erp/src/views/mm/mainIngredientStock/SelectIngredientsStock.vue | 471 ++++++++++++++++++++++++++--------------------------------
1 files changed, 209 insertions(+), 262 deletions(-)
diff --git a/north-glass-erp/northglass-erp/src/views/mm/mainIngredientStock/SelectIngredientsStock.vue b/north-glass-erp/northglass-erp/src/views/mm/mainIngredientStock/SelectIngredientsStock.vue
index 203d782..c56a4e2 100644
--- a/north-glass-erp/northglass-erp/src/views/mm/mainIngredientStock/SelectIngredientsStock.vue
+++ b/north-glass-erp/northglass-erp/src/views/mm/mainIngredientStock/SelectIngredientsStock.vue
@@ -1,277 +1,224 @@
-<!-- 鐗╂枡搴撳瓨 -->
-<script lang="ts" setup>
-import { ref } from 'vue';
-const name = ref('')
-const productName = ref('')
-const salId = ref('')
-let tableData = ref([
- {
- "搴撳瓨缁勭粐":'浜哄伐搴�',
- "鐗╂枡缂栫爜":'700900000000122',
- "鐗╂枡鍚嶇О":'澶忚 鍝佺',
- "浜у湴":'',
- "搴撳瓨缂栧彿":'KC2006891',
- "瀹藉害":'0.00',
- "楂樺害":'0.00',
- "鍘氬害":'0.00',
- "涓诲崟浣�":'浠�',
- "瀹夊叏搴撳瓨":'0.00',
- "搴撳瓨鏁�":'20.00',
- "鍙敤搴撳瓨":'',
- "鏈鍙栨暟閲�":'',
- "鎬婚潰绉�":'0.0000',
- "鐢熶骇鏃ユ湡":'2016-10-17',
- "淇濊川鏈�":'',
- "搴撲綅缂栧彿":'',
- "搴撳尯":'',
- "搴撲綅":'',
- "绉帇搴撳瓨":'40',
- "澶囨敞":'',
+<script setup>
+import {reactive} from "vue";
+import {useRouter} from 'vue-router'
+let router=useRouter()
+const getTableRow = (row,type) =>{
+ switch (type) {
+ case 'edit' :{
+ //alert('鎴戞帴鏀跺埌瀛愮粍浠朵紶閫佺殑缂栬緫淇℃伅')
+ router.push({path: '/main/trader/CreateTrader', query: { id: row.id }})
+ break
+ }
+ case 'delete':{
+ alert('鎴戞帴鏀跺埌瀛愮粍浠朵紶閫佺殑鍒犻櫎淇℃伅')
+ break
+ }
+ }
+}
+
+
+
+//瀛愮粍浠舵帴鏀跺弬鏁�
+
+const gridOptions = reactive({
+ border: "full",//琛ㄦ牸鍔犺竟妗�
+ keepSource: true,//淇濇寔婧愭暟鎹�
+ align: 'center',//鏂囧瓧灞呬腑
+ stripe:true,//鏂戦┈绾�
+ rowConfig: {isCurrent: true, isHover: true,height: 50},//榧犳爣绉诲姩鎴栭�夋嫨楂樹寒
+ id: 'CustomerList',
+ showFooter: true,//鏄剧ず鑴�
+ printConfig: {},
+ importConfig: {},
+ exportConfig: {},
+ scrollY:{ enabled: true },//寮�鍚櫄鎷熸粴鍔�
+ showOverflow:true,
+ columnConfig: {
+ resizable: true,
+ useKey: true
},
- {
- "搴撳瓨缁勭粐":'浜哄伐搴�',
- "鐗╂枡缂栫爜":'700900000000121',
- "鐗╂枡鍚嶇О":'澶忚 娴呰摑',
- "浜у湴":'',
- "搴撳瓨缂栧彿":'KC2006891',
- "瀹藉害":'0.00',
- "楂樺害":'0.00',
- "鍘氬害":'0.00',
- "涓诲崟浣�":'浠�',
- "瀹夊叏搴撳瓨":'0.00',
- "搴撳瓨鏁�":'20.00',
- "鍙敤搴撳瓨":'',
- "鏈鍙栨暟閲�":'',
- "鎬婚潰绉�":'0.0000',
- "鐢熶骇鏃ユ湡":'2016-10-17',
- "淇濊川鏈�":'',
- "搴撲綅缂栧彿":'',
- "搴撳尯":'',
- "搴撲綅":'',
- "绉帇搴撳瓨":'40',
- "澶囨敞":'',
-
+ filterConfig: { //绛涢�夐厤缃」
+ remote: true
},
- {
- "搴撳瓨缁勭粐":'浜哄伐搴�',
- "鐗╂枡缂栫爜":'700900000000120',
- "鐗╂枡鍚嶇О":'澶忚 娣辫摑',
- "浜у湴":'',
- "搴撳瓨缂栧彿":'KC2006891',
- "瀹藉害":'0.00',
- "楂樺害":'0.00',
- "鍘氬害":'0.00',
- "涓诲崟浣�":'浠�',
- "瀹夊叏搴撳瓨":'0.00',
- "搴撳瓨鏁�":'20.00',
- "鍙敤搴撳瓨":'',
- "鏈鍙栨暟閲�":'',
- "鎬婚潰绉�":'0.0000',
- "鐢熶骇鏃ユ湡":'2016-10-17',
- "淇濊川鏈�":'',
- "搴撲綅缂栧彿":'',
- "搴撳尯":'',
- "搴撲綅":'',
- "绉帇搴撳瓨":'40',
- "澶囨敞":'',
-
- },{
- "搴撳瓨缁勭粐":'浜哄伐搴�',
- "鐗╂枡缂栫爜":'700900000000119',
- "鐗╂枡鍚嶇О":'鍐 鍝佺',
- "浜у湴":'',
- "搴撳瓨缂栧彿":'KC2006891',
- "瀹藉害":'0.00',
- "楂樺害":'0.00',
- "鍘氬害":'0.00',
- "涓诲崟浣�":'浠�',
- "瀹夊叏搴撳瓨":'0.00',
- "搴撳瓨鏁�":'20.00',
- "鍙敤搴撳瓨":'',
- "鏈鍙栨暟閲�":'',
- "鎬婚潰绉�":'0.0000',
- "鐢熶骇鏃ユ湡":'2016-10-17',
- "淇濊川鏈�":'',
- "搴撲綅缂栧彿":'',
- "搴撳尯":'',
- "搴撲綅":'',
- "绉帇搴撳瓨":'40',
- "澶囨敞":'',
-
- },{
- "搴撳瓨缁勭粐":'浜哄伐搴�',
- "鐗╂枡缂栫爜":'700900000000118',
- "鐗╂枡鍚嶇О":'鍐 娣辫摑',
- "浜у湴":'',
- "搴撳瓨缂栧彿":'KC2006891',
- "瀹藉害":'0.00',
- "楂樺害":'0.00',
- "鍘氬害":'0.00',
- "涓诲崟浣�":'浠�',
- "瀹夊叏搴撳瓨":'0.00',
- "搴撳瓨鏁�":'20.00',
- "鍙敤搴撳瓨":'',
- "鏈鍙栨暟閲�":'',
- "鎬婚潰绉�":'0.0000',
- "鐢熶骇鏃ユ湡":'2016-10-17',
- "淇濊川鏈�":'',
- "搴撲綅缂栧彿":'',
- "搴撳尯":'',
- "搴撲綅":'',
- "绉帇搴撳瓨":'40',
- "澶囨敞":'',
-
- },{
- "搴撳瓨缁勭粐":'浜哄伐搴�',
- "鐗╂枡缂栫爜":'700900000000117',
- "鐗╂枡鍚嶇О":'鑸悐瀹氭湡淇濆吇鍗�',
- "浜у湴":'',
- "搴撳瓨缂栧彿":'KC2006891',
- "瀹藉害":'0.00',
- "楂樺害":'0.00',
- "鍘氬害":'0.00',
- "涓诲崟浣�":'浠�',
- "瀹夊叏搴撳瓨":'0.00',
- "搴撳瓨鏁�":'20.00',
- "鍙敤搴撳瓨":'',
- "鏈鍙栨暟閲�":'',
- "鎬婚潰绉�":'0.0000',
- "鐢熶骇鏃ユ湡":'2016-10-17',
- "淇濊川鏈�":'',
- "搴撲綅缂栧彿":'',
- "搴撳尯":'',
- "搴撲綅":'',
- "绉帇搴撳瓨":'40',
- "澶囨敞":'',
-
- },{
- "搴撳瓨缁勭粐":'浜哄伐搴�',
- "鐗╂枡缂栫爜":'700900000000116',
- "鐗╂枡鍚嶇О":'鍐165',
- "浜у湴":'',
- "搴撳瓨缂栧彿":'KC2006891',
- "瀹藉害":'0.00',
- "楂樺害":'0.00',
- "鍘氬害":'0.00',
- "涓诲崟浣�":'浠�',
- "瀹夊叏搴撳瓨":'0.00',
- "搴撳瓨鏁�":'20.00',
- "鍙敤搴撳瓨":'',
- "鏈鍙栨暟閲�":'',
- "鎬婚潰绉�":'0.0000',
- "鐢熶骇鏃ユ湡":'2016-10-17',
- "淇濊川鏈�":'',
- "搴撲綅缂栧彿":'',
- "搴撳尯":'',
- "搴撲綅":'',
- "绉帇搴撳瓨":'40',
- "澶囨敞":'',
-
- },{
- "搴撳瓨缁勭粐":'浜哄伐搴�',
- "鐗╂枡缂栫爜":'700900000000115',
- "鐗╂枡鍚嶇О":'鍐170',
- "浜у湴":'',
- "搴撳瓨缂栧彿":'KC2006891',
- "瀹藉害":'0.00',
- "楂樺害":'0.00',
- "鍘氬害":'0.00',
- "涓诲崟浣�":'浠�',
- "瀹夊叏搴撳瓨":'0.00',
- "搴撳瓨鏁�":'20.00',
- "鍙敤搴撳瓨":'',
- "鏈鍙栨暟閲�":'',
- "鎬婚潰绉�":'0.0000',
- "鐢熶骇鏃ユ湡":'2016-10-17',
- "淇濊川鏈�":'',
- "搴撲綅缂栧彿":'',
- "搴撳尯":'',
- "搴撲綅":'',
- "绉帇搴撳瓨":'40',
- "澶囨敞":'',
-
+ customConfig: {
+ storage: true
},
-])
+ editConfig: {
+ trigger: 'click',
+ mode: 'row',
+ showStatus: true
+ },//琛ㄥご鍙傛暟
+ columns:[
+ {type:'expand',fixed:"left",slots: { content:'content' },width: '50'},
+ // { type: 'checkbox',fixed:"left", title: '閫夋嫨', width: '80' },
+ { type: 'seq',fixed:"left", title: '鑷簭', width: '80' },
+ // {title: '鎿嶄綔', width: '110', slots: { default: 'button_slot' },fixed:"left"},
+ {field: 'InventoryOrganization', width:'150', title: '搴撳瓨缁勭粐', sortable: true,editRender: { name: 'input', attrs: { placeholder: '' } } },
+ {field: 'MaterialCode', width: '150',title: '鐗╂枡缂栫爜', sortable: true,showOverflow:"ellipsis" ,filters:[{ data: '' }],slots: { filter: 'num1_filter' }},
+ {field: 'MaterialName', width: '120',title: '鐗╂枡鍚嶇О', sortable: true,filters:[{ data: '' }],slots: { filter: 'num1_filter' }},
+ {field: 'Origin', width: '100',title: '浜у湴', sortable: true},
+ {field: 'InventoryNumber',width: '100', title: '搴撳瓨缂栧彿', sortable: true,showOverflow:"ellipsis"},
+ {field: 'Width', width: '80',title: '瀹藉害', sortable: true},
+ {field: 'Height',width: '100', title: '楂樺害', sortable: true},
+ {field: 'Thickness', width: '100',title: '鍘氬害', sortable: true},
+ {field: 'MainUnit',width: '100', title: '涓诲崟浣�', sortable: true},
+ {field: 'SafetyStock', width: '100',title: '瀹夊叏搴撳瓨', sortable: true},
+ {field: 'InventoryCount',width: '100', title: '搴撳瓨鏁伴噺', sortable: true},
+ {field: 'AvailableInventory', width: '100',title: '鍙敤搴撳瓨', sortable: true},
+ {field: 'UnclaimedQuantity',width: '140', title: '鏈鍙栨暟閲�', sortable: true},
+ {field: 'TotalArea',width: '100', title: '鎬婚潰绉�', sortable: true},
+ {field: 'ProductionDate',width: '100', title: '鐢熶骇鏃ユ湡', sortable: true},
+ {field: 'ShelfLife',width: '100', title: '淇濊川鏈�', sortable: true},
+ {field: 'LocationNumber',width: '100', title: '搴撲綅缂栧彿', sortable: true},
+ {field: 'StorageArea',width: '100', title: '瀛樺偍鍖哄煙', sortable: true},
+ {field: 'Location',width: '100', title: '搴撲綅', sortable: true},
+ {field: 'BacklogInventory',width: '100', title: '绉帇搴撳瓨', sortable: true},
+ {field: 'remark',width: '80', title: '澶囨敞', sortable: true},
+ ],//琛ㄥご鎸夐挳
+ toolbarConfig: {
+ // buttons: [{
+ // 'name': '鏂板'
+ // }],
+ import: false,
+ export: true,
+ print: true,
+ zoom: true,
+ custom: true
+ },
+ data: [
+ {
+ "InventoryOrganization": "浜哄伐搴�",
+ "MaterialCode": "700900000000115",
+ "MaterialName": "鍐170",
+ "Origin": "China",
+ "InventoryNumber": "KC2006891",
+ "Width": '',
+ "Height": "",
+ "Thickness": "",
+ "MainUnit": "浠�",
+ "SafetyStock": "5",
+ "InventoryCount": "20",
+ "AvailableInventory": "9",
+ "UnclaimedQuantity": "2",
+ "TotalArea": "0",
+ "ProductionDate": "2016-10-17",
+ "ShelfLife": "0",
+ "LocationNumber": "0",
+ "StorageArea": "0",
+ "Location": "0",
+ "BacklogInventory": "40",
+ "remark": "娴嬭瘯",
+ },
+ {
+ "InventoryOrganization": "浜哄伐搴�",
+ "MaterialCode": "700900000000115",
+ "MaterialName": "鍐175",
+ "Origin": "China",
+ "InventoryNumber": "KC2006891",
+ "Width": '',
+ "Height": "",
+ "Thickness": "",
+ "MainUnit": "浠�",
+ "SafetyStock": "5",
+ "InventoryCount": "20",
+ "AvailableInventory": "9",
+ "UnclaimedQuantity": "2",
+ "TotalArea": "0",
+ "ProductionDate": "2016-10-17",
+ "ShelfLife": "0",
+ "LocationNumber": "0",
+ "StorageArea": "0",
+ "Location": "0",
+ "BacklogInventory": "40",
+ "remark": "娴嬭瘯",
+ },{
+ "InventoryOrganization": "浜哄伐搴�",
+ "MaterialCode": "700900000000115",
+ "MaterialName": "鍐180",
+ "Origin": "China",
+ "InventoryNumber": "KC2006891",
+ "Width": '',
+ "Height": "",
+ "Thickness": "",
+ "MainUnit": "浠�",
+ "SafetyStock": "2",
+ "InventoryCount": "23",
+ "AvailableInventory": "4",
+ "UnclaimedQuantity": "3",
+ "TotalArea": "0",
+ "ProductionDate": "2016-10-17",
+ "ShelfLife": "0",
+ "LocationNumber": "0",
+ "StorageArea": "0",
+ "Location": "0",
+ "BacklogInventory": "40",
+ "remark": "娴嬭瘯",
+ },
+ ],//table body瀹為檯鏁版嵁
+ footerMethod ({ columns, data }) {//椤佃剼鍑芥暟
+ return[
+ columns.map((column, columnIndex) => {
+ if (columnIndex === 0) {
+ return '鍚堣:'
+ }
+ // if (props.tableProp.footList.includes(column.field)) {
+ // return sumNum(data, column.field)
+ // }
+ return ''
+ })
+ ]
+ }
+
+})
+
+
+
</script>
+
<template>
- <div>
- <div>
- <el-form size="medium" >
+ <div class="main-div-customer">
+ <vxe-grid
+ max-height="100%"
+ @filter-change="filterChanged"
+ class="mytable-scrollbar"
+ ref="xGrid"
+ v-bind="gridOptions"
-<!-- <el-row gutter="5">-->
-<!-- <el-col :span="4">-->
-<!-- <el-input v-model="name" placeholder="璇疯緭鍏ョ墿鏂欑紪鐮�" style="width: 200px; height: 30px;" />-->
-<!-- </el-col>-->
-<!-- <el-col :span="4">-->
-<!-- <el-input v-model="productName" placeholder="璇疯緭鍏ュ" style="width: 200px; height: 30px;" />-->
-<!-- </el-col>-->
-<!-- <el-col :span="4">-->
-<!-- <el-input v-model="salId" placeholder="璇疯緭鍏ラ珮" style="width: 200px; height: 30px;" />-->
-<!-- </el-col>-->
-<!-- <el-col :span="4">-->
-<!-- <el-input v-model="name" placeholder="璇疯緭鍏ョ墿鏂欏悕绉�" style="width: 200px; height: 30px;" />-->
-<!-- </el-col>-->
-<!-- <el-col span="4">-->
-<!-- <el-button id="searchWarehousing" type="primary" :icon="Search1">绾胯竟浠撳偍鏌ヨ</el-button>-->
-<!-- </el-col>-->
-<!-- <el-col span="4">-->
-<!-- <el-button id="searchButton" type="primary" :icon="Search">鏌ヨ</el-button>-->
-<!-- </el-col>-->
+ >
+ <!-- @toolbar-button-click="toolbarButtonClickEvent"-->
+ <!-- 涓嬫媺鏄剧ず鎵�鏈変俊鎭彃妲�-->
+ <template #content="{ row}">
+ <ul class="expand-wrapper">
+ <li v-for="(item,key,index) in row">
+ <span style="font-weight: bold">{{key+': '}}</span>
+ <span>{{ item }}</span>
+ </li>
+ </ul>
+ </template>
-<!-- </el-row>-->
+ <!--宸﹁竟鍥哄畾鏄剧ず鐨勬彃妲�-->
+ <template #button_slot="{ row }">
+ <el-button @click="getTableRow(row,'edit')" link type="primary" size="small">缂栬緫</el-button>
+ <el-button @click="getTableRow(row,'delete')" link type="primary" size="small">鍒犻櫎</el-button>
+ </template>
- <!-- <el-form-item size="large">
- <el-button type="primary" @click="submitForm">鏌ヨ</el-button>
- <el-button @click="resetForm">閲嶇疆</el-button>
- </el-form-item>-->
- <el-row gutter="5">
+ <template #num1_filter="{ column, $panel }">
+ <div>
+ <div v-for="(option, index) in column.filters" :key="index">
+ <input type="type" v-model="option.data" @input="changeFilterEvent($event, option, $panel)"/>
+ </div>
+ </div>
+ </template>
- <el-col :span="4">
- </el-col>
-
- </el-row>
- </el-form>
- </div>
-
- <!-- 琛ㄦ牸寮�濮� -->
- <div>
- <el-table :data="tableData" border style="width: 100%">
- <el-table-column prop="搴撳瓨缁勭粐" label="搴撳瓨缁勭粐" width="180" />
- <el-table-column prop="鐗╂枡缂栫爜" label="鐗╂枡缂栫爜" width="180" />
- <el-table-column prop="鐗╂枡鍚嶇О" label="鐗╂枡鍚嶇О" width="180"/>
- <el-table-column prop="浜у湴" label="浜у湴" width="180"/>
- <el-table-column prop="瀹藉害" label="瀹藉害" width="180"/>
- <el-table-column prop="楂樺害" label="楂樺害" width="180"/>
- <el-table-column prop="鍘氬害" label="鍘氬害" width="180"/>
- <el-table-column prop="涓诲崟浣�" label="涓诲崟浣�" width="180"/>
- <el-table-column prop="瀹夊叏搴撳瓨" label="瀹夊叏搴撳瓨" width="180"/>
- <el-table-column prop="搴撳瓨鏁�" label="搴撳瓨鏁�" width="180"/>
- <el-table-column prop="鍙敤搴撳瓨" label="鍙敤搴撳瓨" width="180"/>
- <el-table-column prop="鏈鍙栨暟閲�" label="鏈鍙栨暟閲�" width="180"/>
- <el-table-column prop="鎬婚潰绉�" label="鎬婚潰绉�" width="180"/>
- <el-table-column prop="鐢熶骇鏃ユ湡" label="鐢熶骇鏃ユ湡" width="180"/>
- <el-table-column prop="淇濊川鏈�" label="淇濊川鏈�" width="180"/>
- <el-table-column prop="搴撲綅缂栧彿" label="搴撲綅缂栧彿" width="180"/>
- <el-table-column prop="搴撳尯" label="搴撳尯" width="180"/>
- <el-table-column prop="搴撲綅" label="搴撲綅" width="180"/>
- <el-table-column prop="绉帇搴撳瓨" label="绉帇搴撳瓨" width="180"/>
- <el-table-column prop="澶囨敞" label="澶囨敞" width="180"/>
- <el-table-column fixed="left" label="鎿嶄綔" width="120">
- <template #default>
- <el-button link type="primary" size="small" @click="handleClick"
- >淇敼</el-button
- >
- <el-button link type="primary" size="small">瀹℃牳</el-button>
- </template>
- </el-table-column>
-
- </el-table>
- </div>
- <!-- 琛ㄦ牸缁撴潫 -->
+ </vxe-grid>
</div>
</template>
-<style>
+<style scoped>
+.main-div-customer{
+ width: 99%;
+ height: 100%;
+}
</style>
\ No newline at end of file
--
Gitblit v1.8.0