From 9c5fbe6c60922d4e1cb3b86603fa6ec3a5a3f979 Mon Sep 17 00:00:00 2001
From: guoyuji <guoyujie@ng.com>
Date: 星期三, 27 十二月 2023 10:23:18 +0800
Subject: [PATCH] 修改表头样式和分批查询多数据结果集
---
north-glass-erp/northglass-erp/src/router/index.js | 2
north-glass-erp/src/main/java/com/example/erp/service/sd/ProductService.java | 5
north-glass-erp/northglass-erp/src/views/sd/product/Product.vue | 13
north-glass-erp/northglass-erp/src/components/basic/BasicTable.vue | 18
north-glass-erp/northglass-erp/src/views/sd/customer/CreateCustomer.vue | 1
north-glass-erp/src/main/resources/mapper/sd/Product.xml | 1
north-glass-erp/northglass-erp/src/views/sd/delivery/Delivery.vue | 14
north-glass-erp/northglass-erp/src/stores/sd/product/prduct.js | 15
north-glass-erp/northglass-erp/src/views/sd/customer/Customer.vue | 12
north-glass-erp/northglass-erp/src/views/mm/purchaseOrder/Create.vue | 508 +++++----------------
north-glass-erp/northglass-erp/src/views/mm/purchaseOrder/PurchaseOrder.vue | 22
north-glass-erp/northglass-erp/src/views/sd/order/Order.vue | 13
north-glass-erp/src/main/java/com/example/erp/controller/sd/ProductController.java | 11
north-glass-erp/northglass-erp/src/components/basic/product/GlassType.vue | 2
north-glass-erp/northglass-erp/src/hook/index.js | 12
north-glass-erp/northglass-erp/src/views/sd/returns/Returns.vue | 15
north-glass-erp/northglass-erp/src/views/mm/stockReport/StockReport.vue | 6
north-glass-erp/northglass-erp/src/views/mm/purchaseOrder/Select.vue | 427 +++++++-----------
north-glass-erp/src/main/java/com/example/erp/mapper/sd/ProductMapper.java | 3
north-glass-erp/src/main/resources/application.yml | 4
north-glass-erp/northglass-erp/src/views/sd/product/SelectProduct.vue | 240 +++++++--
north-glass-erp/src/main/java/com/example/erp/common/interceptor/JwtInterceptor.java | 4
north-glass-erp/target/classes/mapper/sd/Product.xml | 1
north-glass-erp/target/classes/application.yml | 4
north-glass-erp/northglass-erp/src/components/sd/product/GlassType.vue | 2
north-glass-erp/src/main/java/com/example/erp/common/Result.java | 2
north-glass-erp/northglass-erp/src/stores/sd/product/productGlassType.js | 0
27 files changed, 583 insertions(+), 774 deletions(-)
diff --git a/north-glass-erp/northglass-erp/src/components/basic/BasicTable.vue b/north-glass-erp/northglass-erp/src/components/basic/BasicTable.vue
index 9fdcc29..c626c51 100644
--- a/north-glass-erp/northglass-erp/src/components/basic/BasicTable.vue
+++ b/north-glass-erp/northglass-erp/src/components/basic/BasicTable.vue
@@ -1,20 +1,10 @@
<template>
- <div style="width: 100%;height: 100%;">
+ <div style="width: 100%;height: 100%;" >
<!-- 姝e父鍖哄煙鐨勬 -->
<div class="vxe-table--cell-area" ref="cellarea">
<span class="vxe-table--cell-main-area"></span>
<span class="vxe-table--cell-active-area"></span>
</div>
- <!-- 宸︿晶fixed鍖哄煙鐨勬 -->
-<!-- <div class="vxe-table--cell-area" ref="leftfixedcellarea">-->
-<!-- <span class="vxe-table--cell-main-area"></span>-->
-<!-- <span class="vxe-table--cell-active-area"></span>-->
-<!-- </div>-->
- <!-- 鍙充晶fixed鍖哄煙鐨勬 -->
-<!-- <div class="vxe-table--cell-area" ref="rightfixedcellarea">-->
-<!-- <span class="vxe-table--cell-main-area"></span>-->
-<!-- <span class="vxe-table--cell-active-area"></span>-->
-<!-- </div>-->
<vxe-grid
max-height="100%"
@filter-change="filterChanged"
@@ -22,6 +12,7 @@
ref="xGrid"
v-bind="gridOptions"
v-on="gridEvents"
+ @scroll ="scrollEvnt"
>
<!-- @toolbar-button-click="toolbarButtonClickEvent"-->
@@ -57,11 +48,14 @@
<script lang="ts" setup>
import {ref, reactive, defineEmits, onMounted, nextTick, toRef, watch} from 'vue'
import {VxeGridProps, VXETable} from 'vxe-table'
+import scrollEvnt from '@/hook/index'
import request from "@/utils/request"
import deepClone from "@/utils/deepClone";
import {ElMessage} from "element-plus";
import router from "@/router";
//prop鎺ユ敹鐖剁粍浠跺嚱鏁�
+
+
let props = defineProps({
tableProp:{
@@ -111,7 +105,7 @@
printConfig: {},
importConfig: {},
exportConfig: {},
- scrollY:{ enabled: true },//寮�鍚櫄鎷熸粴鍔�
+ scrollY:{ enabled: true , gt: 40},//寮�鍚櫄鎷熸粴鍔�
showOverflow:true,
columnConfig: {
resizable: true,
diff --git a/north-glass-erp/northglass-erp/src/components/basic/product/GlassType.vue b/north-glass-erp/northglass-erp/src/components/basic/product/GlassType.vue
index 874b797..df6819f 100644
--- a/north-glass-erp/northglass-erp/src/components/basic/product/GlassType.vue
+++ b/north-glass-erp/northglass-erp/src/components/basic/product/GlassType.vue
@@ -2,7 +2,7 @@
import request from "@/utils/request";
import deepClone from "@/utils/deepClone";
import {ElMessage} from "element-plus";
-import useProductGlassTypeStore from "@/stores/productGlassType"
+import useProductGlassTypeStore from "@/stores/sd/product/productGlassType"
let productGlassTypeStore = useProductGlassTypeStore()
let options=$ref([])
diff --git a/north-glass-erp/northglass-erp/src/components/sd/product/GlassType.vue b/north-glass-erp/northglass-erp/src/components/sd/product/GlassType.vue
index a3c7882..7545d94 100644
--- a/north-glass-erp/northglass-erp/src/components/sd/product/GlassType.vue
+++ b/north-glass-erp/northglass-erp/src/components/sd/product/GlassType.vue
@@ -2,7 +2,7 @@
import request from "@/utils/request";
import deepClone from "@/utils/deepClone";
import {ElMessage} from "element-plus";
-import useProductGlassTypeStore from "@/stores/productGlassType"
+import useProductGlassTypeStore from "@/stores/sd/product/productGlassType"
let productGlassTypeStore = useProductGlassTypeStore()
let options=$ref([])
diff --git a/north-glass-erp/northglass-erp/src/hook/index.js b/north-glass-erp/northglass-erp/src/hook/index.js
index e69de29..bc74eef 100644
--- a/north-glass-erp/northglass-erp/src/hook/index.js
+++ b/north-glass-erp/northglass-erp/src/hook/index.js
@@ -0,0 +1,12 @@
+import useProductStore from "@/stores/sd/product/prduct"
+let productStore = useProductStore()
+export default function scrollEvnt(row){
+ // 鍐呭楂樺害
+ var scrollHeight = row.$event.target.scrollHeight
+ var clientHeight = row.$event.target.clientHeight
+ var scrollTop = row.$event.target.scrollTop
+ //婊氬姩鍒板簳閮�
+ if ((Math.round(scrollTop + clientHeight) >= scrollHeight ) ) {
+ productStore.flag=true
+ }
+}
\ No newline at end of file
diff --git a/north-glass-erp/northglass-erp/src/router/index.js b/north-glass-erp/northglass-erp/src/router/index.js
index 818aa6e..e392f87 100644
--- a/north-glass-erp/northglass-erp/src/router/index.js
+++ b/north-glass-erp/northglass-erp/src/router/index.js
@@ -781,7 +781,7 @@
},
{
path: '',
- redirect:'/main/Product'
+ redirect:'/main/order'
}
]
},
diff --git a/north-glass-erp/northglass-erp/src/stores/sd/product/prduct.js b/north-glass-erp/northglass-erp/src/stores/sd/product/prduct.js
new file mode 100644
index 0000000..4b117d6
--- /dev/null
+++ b/north-glass-erp/northglass-erp/src/stores/sd/product/prduct.js
@@ -0,0 +1,15 @@
+import {defineStore} from 'pinia'
+import {ref} from "vue";
+
+export default defineStore("product",{
+ state: () =>{
+ let pageNum=$ref(1)
+ let pageSize=$ref(100)
+ let flag=$ref(false)
+ return {
+ pageNum,
+ pageSize,
+ flag
+ }
+ }
+})
\ No newline at end of file
diff --git a/north-glass-erp/northglass-erp/src/stores/productGlassType.js b/north-glass-erp/northglass-erp/src/stores/sd/product/productGlassType.js
similarity index 100%
rename from north-glass-erp/northglass-erp/src/stores/productGlassType.js
rename to north-glass-erp/northglass-erp/src/stores/sd/product/productGlassType.js
diff --git a/north-glass-erp/northglass-erp/src/views/mm/purchaseOrder/Create.vue b/north-glass-erp/northglass-erp/src/views/mm/purchaseOrder/Create.vue
index b0ebf88..1f71ced 100644
--- a/north-glass-erp/northglass-erp/src/views/mm/purchaseOrder/Create.vue
+++ b/north-glass-erp/northglass-erp/src/views/mm/purchaseOrder/Create.vue
@@ -1,377 +1,130 @@
+
+
<template>
- <el-header height="auto">
- <el-form label-width="100px" :inline="true" :model="formInline" class="demo-form-inline">
+<div>
+ <el-form label-width="100px" :inline="true" :model="formInline" class="demo-form-inline">
+ <el-form-item label="閲囪喘绫诲瀷" class="item-style" >
+ <el-select v-model="form.buyType" class="m-2" placeholder="閫夋嫨閲囪喘绫诲瀷" clearable >
+ <el-option
+ v-for="item in CGTypeOptions"
+ :key="item.value"
+ :label="item.label"
+ :value="item.value"
+ />
+ </el-select>
+ </el-form-item>
+
+ <el-form-item label="閲囪喘閮ㄩ棬" class="item-style" >
+ <el-select v-model="cgBuMen" class="m-2" placeholder="閫夋嫨閲囪喘閮ㄩ棬" clearable >
+ <el-option
+ v-for="item in CGBuMenOptions"
+ :key="item.value"
+ :label="item.label"
+ :value="item.value"
+ />
+ </el-select>
+ </el-form-item>
+
+ <el-form-item label="渚涘簲鍟�" class="item-style" >
+ <el-cascader
+ placeholder="閫夋嫨渚涘簲鍟�"
+ :options="buyerOptions"
+ filterable
+ clearable
+ empty-text="empty-text"
+ :v-model="form.supplier"
+ >
+ </el-cascader>
+ </el-form-item>
+
+
+ <el-form-item label="閲囪喘鍛�" class="item-style" >
+ <el-select v-model="form.buyer" class="m-2" placeholder="閫夋嫨閲囪喘閮ㄩ棬" clearable >
+ <el-option
+ v-for="item in BuyerOptions"
+ :key="item.value"
+ :label="item.label"
+ :value="item.value"
+ />
+ </el-select>
+ </el-form-item>
+
+ <el-form-item label="閲囪喘缁勭粐" class="item-style" >
+ <el-input v-model="form.buyItem" placeholder="閲囪喘缁勭粐" clearable ></el-input>
+ </el-form-item>
+
+ <el-form-item label="鍒惰〃鏃ユ湡" class="item-style" >
+
+ <el-date-picker
+ v-model="form.date"
+ type="date"
+ placeholder="閫夋嫨鍒惰〃鏃ユ湡"
+ style="width: 100%"
+ />
+
+ </el-form-item>
+ <el-form-item class="item-style" >
<el-row :gutter="10">
- <el-col :span="6">
- <el-form-item label="閲囪喘绫诲瀷" class="item-style">
- <el-select v-model="form.buyType" class="m-2" placeholder="閫夋嫨閲囪喘绫诲瀷" clearable>
- <el-option
- v-for="item in CGTypeOptions"
- :key="item.value"
- :label="item.label"
- :value="item.value"
- />
- </el-select>
- </el-form-item>
+
+ <el-col :span="6" :offset="6">
+ <el-button type="primary" @click="onSubmit">淇濆瓨</el-button>
</el-col>
- <el-col :span="6">
- <el-form-item label="閲囪喘閮ㄩ棬" class="item-style">
- <el-select v-model="cgBuMen" class="m-2" placeholder="閫夋嫨閲囪喘閮ㄩ棬" clearable>
- <el-option
- v-for="item in CGBuMenOptions"
- :key="item.value"
- :label="item.label"
- :value="item.value"
- />
- </el-select>
- </el-form-item>
+ <el-col :span="6" :offset="6">
+ <el-button>鍙栨秷</el-button>
</el-col>
- <el-col :span="6">
- <el-form-item label="渚涘簲鍟�" class="item-style">
- <el-cascader
- placeholder="閫夋嫨渚涘簲鍟�"
- :options="buyerOptions"
- filterable
- clearable
- empty-text="empty-text"
- :v-model="form.supplier"
- >
- </el-cascader>
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="閲囪喘鍛�" class="item-style">
- <el-select v-model="form.buyer" class="m-2" placeholder="閫夋嫨閲囪喘閮ㄩ棬" clearable>
- <el-option
- v-for="item in BuyerOptions"
- :key="item.value"
- :label="item.label"
- :value="item.value"
- />
- </el-select>
- </el-form-item>
- </el-col>
+
+
+
</el-row>
- <el-row :gutter="10">
- <el-col :span="6">
- <el-form-item label="閲囪喘缁勭粐" class="item-style">
- <el-input v-model="form.buyItem" placeholder="閲囪喘缁勭粐" clearable></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="鍒惰〃鏃ユ湡" class="item-style">
+ </el-form-item>
+ </el-form>
- <el-date-picker
- v-model="form.date"
- type="date"
- placeholder="閫夋嫨鍒惰〃鏃ユ湡"
- style="width: 100%"
- />
-
- </el-form-item>
- </el-col>
- <el-col :span="6"></el-col>
-
- </el-row>
-
-
- </el-form>
-
- </el-header>
-
- <el-main style="padding-top: 5px;height:100%">
-<!-- <el-button class="mt-4" style="width: 10%" @click="onAddItem"
- >娣诲姞
- </el-button>-->
-
- <vxe-grid
-
- max-height="500"
- @filter-change="filterChanged"
- class="mytable-scrollbar"
- ref="xGrid"
- v-bind="gridOptions"
- v-on="gridEvents"
- >
-
- <!-- @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>
+<div>
+ <el-button class="mt-4" style="width: 10%" @click="onAddItem"
+ >娣诲姞</el-button>
+ <el-table :data="tableData" style="width: 98%" max-height="500" border show-summary
+ sum-text=" ">
+ <el-table-column fixed="left" label="鎿嶄綔" width="60">
+ <template #default="scope">
+ <el-button
+ link
+ type="primary"
+ size="small"
+ @click.prevent="deleteRow(scope.$index)"
+ >
+ 鍒犻櫎
+ </el-button>
</template>
+ </el-table-column>
+ <el-table-column fixed prop="wlcode" label="鐗╂枡缂栫爜" width="150" />
+ <el-table-column prop="wlname" label="鐗╂枡鍚嶇О" width="180" />
+ <el-table-column prop="cd" label="浜у湴" width="100" />
+ <el-table-column prop="kd" label="瀹藉害" width="70" />
+ <el-table-column prop="gd" label="楂樺害" width="70" />
+ <el-table-column prop="hd" label="鍘氬害" width="60" />
+ <el-table-column prop="xh" label="鍨嬪彿" width="80" />
+ <el-table-column prop="hd" label="鍗曚綅鏁伴噺" width="100" />
+ <el-table-column prop="hd" label="鍗曚綅" width="60" />
+ <el-table-column prop="hd" label="绠辨暟" width="60" />
+ <el-table-column prop="hd" label="鍗曠墖闈㈢Н" width="100" />
+ <el-table-column prop="hd" label="鍗曚环" width="60" />
+ <el-table-column prop="hd" label="鎬绘暟閲�" width="80" />
+ <el-table-column prop="hd" label="鎬婚潰绉�" width="80" />
+ <el-table-column prop="hd" label="鎬婚噾棰�" width="80" />
+ <el-table-column prop="hd" label="澶囨敞" width="120" />
- <!--宸﹁竟鍥哄畾鏄剧ず鐨勬彃妲�-->
- <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>-->
- <!-- <el-button @click="cellClickEvent" link type="primary" size="small">璇︽儏</el-button>-->
- </template>
+ </el-table>
- <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>
- </vxe-grid>
-
- </el-main>
-
+</div>
+</div>
</template>
<script setup>
-import {ref, reactive} from 'vue'
-let router = useRouter()
+import { ref,reactive } from 'vue'
-//缁勪欢鎺ユ敹鍙傛暟
-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
- },
- filterConfig: { //绛涢�夐厤缃」
- remote: true
- },
- customConfig: {
- storage: true
- },
- editConfig: {
- trigger: 'click',
- mode: 'row',
- showStatus: true
- },
- columns: [
- //{title: '鎿嶄綔', width: '8%', slots: {default: 'button_slot'}, fixed: "left"},
- {type: 'seq', fixed: "left", title: ' ', width: 50},
- {type: 'checkbox',fixed:"left", title: '', width: 50 },
- {type: 'expand', title:'璇︽儏', fixed: "left", slots: {content: 'content'}, width: 50},
- {field: 'cgdh', width: '10%', title: '鐗╂枡缂栫爜', filters: [{data: ''}], slots: {filter: 'num1_filter'}, editRender: { name: 'input', attrs: { placeholder: '' } },sortable: true},
- {field: 'cgzt', width: '10%', title: '鐗╂枡鍚嶇О', filters: [{data: ''}], slots: {filter: 'num1_filter'},editRender: { name: 'input', attrs: { placeholder: '' } }, sortable: true},
- {field: 'gys', width: '10%',title: '浜у湴', filters: [{data: ''}], slots: {filter: 'num1_filter'}, editRender: { name: 'input', attrs: { placeholder: '' } },sortable: true},
- {field: 'w', width: '8%',title: '瀹藉害', /*filters: [{data: ''}], slots: {filter: 'num1_filter'},*/ editRender: { name: 'input', attrs: { placeholder: '' } }, sortable: true},
- {field: 'g', width: '8%',title: '楂樺害', /*filters: [{data: ''}], slots: {filter: 'num1_filter'},*/ editRender: { name: 'input', attrs: { placeholder: '' } },sortable: true},
- {field: 'h', width: '8%',title: '鍘氬害', /*filters: [{data: ''}], slots: {filter: 'num1_filter'},*/ editRender: { name: 'input', attrs: { placeholder: '' } },sortable: true},
- {field: 'xh', width: '8%',title: '鍨嬪彿',/*filters: [{data: ''}], slots: {filter: 'num1_filter'},*/ editRender: { name: 'input', attrs: { placeholder: '' } },sortable: true},
- {field: 'dw', width: '8%',title: '鍗曚綅', /*filters: [{data: ''}], slots: {filter: 'num1_filter'},*/ editRender: { name: 'input', attrs: { placeholder: '' } },sortable: true},
- {field: 'sl', width: '8%',title: '鏁伴噺', /*filters: [{data: ''}], slots: {filter: 'num1_filter'},*/ editRender: { name: 'input', attrs: { placeholder: '' } },sortable: true},
- {field: 'sl', width: '8%',title: '鎿嶄綔鏁伴噺', /*filters: [{data: ''}], slots: {filter: 'num1_filter'},*/ editRender: { name: 'input', attrs: { placeholder: '' } }},
- {field: 'sl', width: '12%',title: '绠辨暟', /*filters: [{data: ''}], slots: {filter: 'num1_filter'},*/ editRender: { name: 'input', attrs: { placeholder: '' } },sortable: true},
- {field: 'je', width: '8%',title: '鍗曠墖闈㈢Н', /*filters: [{data: ''}], slots: {filter: 'num1_filter'},*/ editRender: { name: 'input', attrs: { placeholder: '' } },sortable: true},
- {field: 'je', width: '12%',title: '鍗曚环', /*filters: [{data: ''}], slots: {filter: 'num1_filter'},*/ editRender: { name: 'input', attrs: { placeholder: '' } },sortable: true},
- {field: '6', width: '8%',title: '鎬绘暟閲�', /*filters: [{data: ''}], slots: {filter: 'num1_filter'},*/ editRender: { name: 'input', attrs: { placeholder: '' } },sortable: true},
- {field: 'sl', width: '8%',title: '鎬婚潰绉�', /*filters: [{data: ''}], slots: {filter: 'num1_filter'},*/ editRender: { name: 'input', attrs: { placeholder: '' } },sortable: true},
- {field: 'yl', width: '10%',title: '鎬婚噾棰�',/*filters: [{data: ''}], slots: {filter: 'num1_filter'},*/ editRender: { name: 'input', attrs: { placeholder: '' } },sortable: true},
- {field: 'yl', width: '10%',title: '澶囨敞', /*filters: [{data: ''}], slots: {filter: 'num1_filter'},*/ editRender: { name: 'input', attrs: { placeholder: '' } }, sortable: true}
- ],//琛ㄥご鍙傛暟
- toolbarConfig: {
- buttons: [
- {type:'text'},
- {
- 'name': '鏂板',
-
- 'code':'Add',
- },
- {
- 'name': '绉婚櫎',
-
- 'code':'Remove'
- },
- {
- 'name': '淇濆瓨璁㈠崟',
- status:'primary',
- 'code':'Save'
- },{
- 'name': '鍏ュ簱',
- status:'primary',
- 'code':'Storage'
- },
- {
- 'name': '閫�璐�',
- status:'primary',
- 'code':'Return'
- }/*,
- {
- 'name': '杩斿洖鏌ヨ',
-
- 'code':'GoSelect'
- }*/],
- import: false,
- export: true,
- print: true,
- zoom: true,
- custom: true,
- tools: [
-
- ],
-
- },//琛ㄥご鎸夐挳
- /*data: [{},{},{},{},{},{}],//table body瀹為檯鏁版嵁*/
- data: [{},{},{}],//table body瀹為檯鏁版嵁
- mergeFooterItems: [
- {row: 0, col: 0, rowspan: 1, colspan: 4}
- ],//鍚堝苟鑴�
- 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 ''
- })
- ]
- },
-
-})
-
-const xGrid = ref()
-const gridEvents = {
- toolbarButtonClick({code}) {
- const $grid = xGrid.value
- if ($grid) {
- switch (code) {
- case 'Add': {//鏂板
- const record = {
- checked: false
- }
- $grid.insertAt(record, 0).then(({row}) => {
- $grid.setEditRow(row)
- })
- break
- }
- case 'Remove': {//绉婚櫎
- if ($grid.getCheckboxRecords().length === 0) {
- openAlert({type: 'message', content: '璇烽�夋嫨鑷冲皯涓�鏉℃暟鎹�', status: 'warning'})
- //VXETable.modal.message( '璇烽�夋嫨涓�鏉℃暟鎹紒')
- return
- } else {
- const type = VXETable.modal.confirm('鎮ㄧЩ闄や簡' + $grid.getCheckboxRecords().length + '鏉℃暟鎹紒');
- //openAlert({type:'alert', content: '鎴愬姛鍏ュ簱'+$grid.getCheckboxRecords().length+'鏉℃暟鎹紒', status: 'success' })
- //VXETable.modal.message( '璇烽�夋嫨涓�鏉℃暟鎹紒')
- return
- }
- break
- }
- case 'Save': {//淇濆瓨
-
-
- if(form.buyItem === null || form.buyItem === ''){
- openAlert({type: 'message', content: '閲囪喘缁勭粐涓嶅彲涓虹┖', status: 'warning'})
- }
-
-return
-
- if(buyerOptions.values() <= 0){
-
- }
-
- const type = VXETable.modal.confirm('鏄惁纭畾淇濆瓨褰撳墠璁㈠崟淇℃伅锛�');
- openAlert({type: 'message', content: $grid.rows.number+'', status: 'warning'})
- return
-
- break
- }
- case 'GoSelect':{
-
- router.push({path: '/main/purchaseOrder/SelectPurchaseOrder'})
- break
- }
-
- case 'Storage': {//鍏ュ簱
- if ($grid.getCheckboxRecords().length === 0) {
- openAlert({type: 'message', content: '璇烽�夋嫨鑷冲皯涓�鏉℃暟鎹�', status: 'warning'})
- //VXETable.modal.message( '璇烽�夋嫨涓�鏉℃暟鎹紒')
- return
- } else {
- const type = VXETable.modal.confirm('鎮ㄩ�夋嫨浜�' + $grid.getCheckboxRecords().length + '鏉℃暟鎹紒,鏄惁纭鍏ュ簱锛�');
- //openAlert({type:'alert', content: '鎴愬姛鍏ュ簱'+$grid.getCheckboxRecords().length+'鏉℃暟鎹紒', status: 'success' })
- //VXETable.modal.message( '璇烽�夋嫨涓�鏉℃暟鎹紒')
- return
- }
- break
- }
- case 'Return': {//閫�搴�
- if ($grid.getCheckboxRecords().length === 0) {
- openAlert({type: 'message', content: '璇烽�夋嫨鑷冲皯涓�鏉℃暟鎹�', status: 'warning'})
- //VXETable.modal.message( '璇烽�夋嫨涓�鏉℃暟鎹紒')
- return
- } else {
- /* async ()=>{
- const type = await.VXETable.modal.confirm('鎮ㄩ�夋嫨浜�'+$grid.getCheckboxRecords().length+'鏉℃暟鎹紒,鏄惁纭閫�搴擄紵');
- }*/
- const type = VXETable.modal.confirm('鎮ㄩ�夋嫨浜�' + $grid.getCheckboxRecords().length + '鏉℃暟鎹紒,鏄惁纭閫�搴擄紵');
-
-
- /* if(VXETable.modal.confirm('鎮ㄩ�夋嫨浜�'+$grid.getCheckboxRecords().length+'鏉℃暟鎹紒,鏄惁纭閫�搴擄紵' )){
- //openAlert({type:'message', content: '鎴愬姛閫�搴�'+$grid.getCheckboxRecords().length+'鏉℃暟鎹紒', status: 'success',lockView: false, mask: false })
-
-
- }*/
-
- /* if(type==='confirm'){
- openAlert({type:'message', content: '鎴愬姛閫�搴�'+$grid.getCheckboxRecords().length+'鏉℃暟鎹紒', status: 'success' })
- }
-
-*/
- //openAlert({type:'alert', content: '鎴愬姛閫�搴�'+$grid.getCheckboxRecords().length+'鏉℃暟鎹紒', status: 'success' })
- //VXETable.modal.message( '璇烽�夋嫨涓�鏉℃暟鎹紒')
- return
- }
- break
- }
-
- }
- }
- },
- toolbarToolClick({code}) {
- const $grid = xGrid.value
- if ($grid) {
- switch (code) {
- case 'myPrint': {
- $grid.print()
- break
- }
- }
- }
- },
-}
-
-
-const openAlert = (options) => {
- if(options.type==='message'){
- VXETable.modal.message(options)
- }else{
- VXETable.modal.alert(options)
- }
-
-}
-
-
-
-
-
+// do not use same name with ref
const form = reactive({
name: '',
region: '',
@@ -380,18 +133,16 @@
type: [],
resource: '',
desc: '',
- supplier: '',
- buyer: '',
- buyItem: '',
- buyType: ''
+ supplier:'',
+ buyer:'',
+ buyItem:'',
+ buyType:''
})
const onSubmit = () => {
console.log('submit!')
}
-
-//渚涘簲鍟�
const buyerOptions = [
{value: '0', label: '渚涘簲鍟�1'},
{value: '1', label: '渚涘簲鍟�2'},
@@ -402,10 +153,10 @@
]
+
const value = ref('')
const cgBuMen = ref('')
-//閲囪喘绫诲瀷
const CGTypeOptions = [
{
value: '1',
@@ -422,8 +173,8 @@
]
-//閲囪喘閮ㄩ棬
-const CGBuMenOptions = [
+
+const CGBuMenOptions=[
{
value: '0',
label: '閲囪喘鍗庡寳閮�',
@@ -447,8 +198,7 @@
]
-//閲囪喘浜�
-const BuyerOptions = [
+const BuyerOptions=[
{
value: '0',
label: '閲囪喘鍛�1',
@@ -473,8 +223,6 @@
]
import dayjs from 'dayjs'
-import {VXETable} from "vxe-table";
-import {useRouter} from "vue-router";
const now = new Date()
@@ -486,7 +234,7 @@
hd: '8',
gd: '2440',
kd: '3660',
- xh: 'CN10P'
+ xh:'CN10P'
},
{
wlcode: '202312305101',
@@ -495,7 +243,7 @@
gd: '2440',
kd: '3660',
hd: '5',
- xh: 'CN10P'
+ xh:'CN10P'
},
{
wlcode: '202312405101',
@@ -504,19 +252,20 @@
hd: '12',
gd: '2440',
kd: '3660',
- xh: 'CN10P'
+ xh:'CN10P'
},
])
+
const onAddItem = () => {
now.setDate(now.getDate() + 1)
tableData.value.push({
- wlcode: dayjs(now).format('YYYYMMDDss') + '01',
+ wlcode: dayjs(now).format('YYYYMMDDss')+'01',
wlname: '杩欐槸涓�涓墿鏂欏悕绉�',
cd: '浜у湴1',
hd: '6',
- xh: 'CN10P',
+ xh:'CN10P',
gd: '2440',
kd: '3660',
})
@@ -536,8 +285,7 @@
height: unset;
}
}
-
-.item-style {
- width: 300px;
+.item-style{
+ width:300px;
}
</style>
\ No newline at end of file
diff --git a/north-glass-erp/northglass-erp/src/views/mm/purchaseOrder/PurchaseOrder.vue b/north-glass-erp/northglass-erp/src/views/mm/purchaseOrder/PurchaseOrder.vue
index 470db4c..7d68473 100644
--- a/north-glass-erp/northglass-erp/src/views/mm/purchaseOrder/PurchaseOrder.vue
+++ b/north-glass-erp/northglass-erp/src/views/mm/purchaseOrder/PurchaseOrder.vue
@@ -1,33 +1,27 @@
<template>
<div class="common-layout">
- <el-container>
+ <el-container>
<el-header style="height: 30px">
<el-breadcrumb :separator-icon="ArrowRight" >
-<!-- <el-breadcrumb-item>閲囪喘涓庣墿璧�</el-breadcrumb-item>
+ <el-breadcrumb-item>閲囪喘涓庣墿璧�</el-breadcrumb-item>
<el-breadcrumb-item>閲囪喘璁㈠崟
- </el-breadcrumb-item>-->
- <el-breadcrumb-item :to="{path:'/main/purchaseOrder/SelectPurchaseOrder'}">鏌ヨ閲囪喘璁㈠崟
</el-breadcrumb-item>
- <el-breadcrumb-item :to="{path:'/main/purchaseOrder/CreatePurchaseOrder'}">鍒涘缓閲囪喘璁㈠崟
+ <el-breadcrumb-item :to="{path:'/main/purchaseOrder/SelectPurchaseOrder'}">鏌ヨ
</el-breadcrumb-item>
- <el-breadcrumb-item :to="{path:'/main/purchaseOrder/StoragePurchaseOrder'}">閲囪喘鍏ュ簱
+ <el-breadcrumb-item :to="{path:'/main/purchaseOrder/CreatePurchaseOrder'}">鍒涘缓
</el-breadcrumb-item>
- <el-breadcrumb-item :to="{path:'/main/purchaseOrder/ReturnPurchaseOrder'}">閲囪喘閫�璐�
+ <el-breadcrumb-item :to="{path:'/main/purchaseOrder/PaymentPurchaseOrder'}">搴斾粯
</el-breadcrumb-item>
- <el-breadcrumb-item :to="{path:'/main/purchaseOrder/PaymentPurchaseOrder'}">搴斾粯閲囪喘璁㈠崟
+ <el-breadcrumb-item >
</el-breadcrumb-item>
- <el-breadcrumb-item style="display: none"></el-breadcrumb-item>
</el-breadcrumb>
</el-header>
<el-main style="padding: 0">
-<router-view/>
+ <router-view/>
</el-main>
-<!-- <el-footer>Footer</el-footer>-->
+ <!-- <el-footer>Footer</el-footer>-->
</el-container>
-
-
</div>
-
</template>
diff --git a/north-glass-erp/northglass-erp/src/views/mm/purchaseOrder/Select.vue b/north-glass-erp/northglass-erp/src/views/mm/purchaseOrder/Select.vue
index 11161c1..fe28c9d 100644
--- a/north-glass-erp/northglass-erp/src/views/mm/purchaseOrder/Select.vue
+++ b/north-glass-erp/northglass-erp/src/views/mm/purchaseOrder/Select.vue
@@ -23,306 +23,189 @@
id="select"
type="primary"
:icon="Search"
- @click="BtnSearchPurchaseOrder">鏌ヨ
+ @click="autoAddRow">鏌ヨ
</el-button>
</el-col>
</el-row>
+
</el-header>
- <el-main style="padding-top: 5px;height:100%">
- <vxe-grid
+ <el-main style="padding-top: 5px">
+ <div @scroll="handleTableScroll">
- max-height="600"
- @filter-change="filterChanged"
- class="mytable-scrollbar"
- ref="xGrid"
- v-bind="gridOptions"
- v-on="gridEvents"
- >
+ <el-table :data="tableData" empty-text="鏆傛棤鏁版嵁" style="width: 100%" max-height="550px" border
+ show-summary
+ sum-text=" ">
+ <el-table-column fixed="left" prop="rIndex" label="" width="50" align="center"></el-table-column>
- <!-- @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>
-
- <!--宸﹁竟鍥哄畾鏄剧ず鐨勬彃妲�-->
- <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>-->
-<!-- <el-button @click="cellClickEvent" link type="primary" size="small">璇︽儏</el-button>-->
- </template>
+ <el-table-column fixed="left" label="鎿嶄綔" width="120">
+ <template #default="scope">
+ <el-button
+ link
+ type="primary"
+ size="small"
+ @click.prevent="editRow(scope.$index)"
+ >
+ 缂栬緫
+ </el-button>
+ <el-button
+ link
+ type="primary"
+ size="small"
+ @click.prevent="deleteRow(scope.$index)"
+ >
+ 鍒犻櫎
+ </el-button>
+ </template>
+ </el-table-column>
- <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>
- </vxe-grid>
+ <el-table-column prop="ordernumber" label="閲囪喘鍗曞彿" width="150"/>
+ <el-table-column prop="name" label="渚涘簲鍟�" width="120"/>
+ <el-table-column prop="strockNumber" label="鐗╂枡缂栧彿" width="200"/>
+ <el-table-column prop="city" label="鐗╂枡鍚嶇О" width="120"/>
+ <el-table-column prop="width" sortable label="瀹藉害" width="120"/>
+ <el-table-column prop="height" sortable label="楂樺害" width="120"/>
+ <el-table-column prop="thick" sortable label="鍘氬害" width="120"/>
+ <el-table-column prop="zip" label="鍨嬪彿" width="120"/>
+ <el-table-column prop="number" label="鍗曚綅" width="120"/>
+ <el-table-column prop="number" sortable label="涓嶅惈绋庡崟浠�" width="120"/>
+ <el-table-column prop="number" label="鏁伴噺" width="120" show-summary="ture"/>
+ <el-table-column prop="number" label="宸查噰璐暟閲�" width="120"/>
+ <el-table-column prop="zip" sortable label="閲戦" width="120"/>
+ <el-table-column prop="zip" label="涓嶅惈绋庨噾棰�" width="120"/>
+ <el-table-column prop="date" label="绋庣巼" width="120"/>
+ <el-table-column prop="date" label="搴撳瓨" width="120"/>
+ <el-table-column prop="zip" label="鍛ㄧ敤閲�" width="120"/>
+ <el-table-column prop="zip" label="鏈堢敤閲�" width="120"/>
+ <el-table-column prop="state" label="鍗曟嵁鐘舵��" width="120"/>
+ <el-table-column prop="ordernumber" label="閿�鍞崟鍙�" width="200"/>
+ <el-table-column prop="date" label="鍒跺崟鏃ユ湡" width="120"/>
+ <el-table-column prop="zip" label="鍒跺崟浜�" width="120"/>
+ <el-table-column prop="zip" label="閲囪喘閮ㄩ棬" width="120"/>
+ <el-table-column prop="zip" label="閲囪喘缁勭粐" width="120"/>
+ <el-table-column prop="zip" label="澶囨敞" width="200"/>
- <vxe-modal v-model="showDetails" title="鏌ョ湅璇︽儏" width="600" height="400" :mask="false" :lock-view="false" resize>
- <template #default>
- <vxe-table
- border="inner"
- auto-resize
- show-overflow
- height="auto"
- :row-config="{isHover: true}"
- :show-header="false"
- :sync-resize="showDetails"
- :data="detailData">
- <vxe-column field="label" width="40%"></vxe-column>
- <vxe-column field="value"></vxe-column>
- </vxe-table>
- </template>
- </vxe-modal>
+ </el-table>
+ </div>
</el-main>
</el-container>
</template>
<script setup>
-import {ref} from "vue";
-import {reactive} from "vue";
-import {useRouter} from 'vue-router'
-import {Search} from "@element-plus/icons-vue";
-import dayjs from "dayjs";
-import {VXETable} from "vxe-table";
+import {ref} from 'vue'
+import {Plus, Search} from "@element-plus/icons-vue";
-let router = useRouter()
-const getTableRow = (row, type) => {
- switch (type) {
- case 'edit' : {
- //alert('鎴戞帴鏀跺埌瀛愮粍浠朵紶閫佺殑缂栬緫淇℃伅')
- router.push({path: '/main/purchaseOrder/CreatePurchaseOrder', query: {id: row.id}})
- break
- }
- case 'delete': {
+const s_wuliaomingcheng = ref('')
+const s_buyOrderNumber = ref('')
+const s_width = ref('')
+const s_height = ref('')
+const s_thick = ref('')
-
- alert('鎴戞帴鏀跺埌瀛愮粍浠朵紶閫佺殑鍒犻櫎淇℃伅'+row.id)
- break
- }
- }
-}
-
-const xGrid = ref()
-const gridEvents = {
- toolbarButtonClick({code}) {
- const $grid = xGrid.value
- if ($grid) {
- switch (code) {
- case 'Add': {//鏂板
- router.push({path: '/main/purchaseOrder/CreatePurchaseOrder'})
- break
- }
- case 'AddNo': {//鏃犲崟鏂板
- openAlert({type: 'alert', content: '鐐瑰嚮浜嗘棤鍗曟柊澧�', status: 'success'})
- break
- }
-
- }
- }
+const options = [
+ {
+ value: '0',
+ label: '鍏ㄩ儴'
},
- toolbarToolClick({code}) {
- const $grid = xGrid.value
- if ($grid) {
- switch (code) {
- case 'myPrint': {
- $grid.print()
- break
- }
- }
- }
+ {
+ value: '1',
+ label: '鍘熺墖'
},
-}
-
-const openAlert = (options) => {
- if(options.type==='message'){
- VXETable.modal.message(options)
- }else{
- VXETable.modal.alert(options)
- }
-
-}
-const closeAlert = (id) => {
- VXETable.modal.close(id)
-}
-
-const confirmEvent = async () => {
- const type = await VXETable.modal.confirm('鎮ㄧ‘瀹氳鍒犻櫎鍚楋紵')
- VXETable.modal.message({ content: `鐐瑰嚮浜� ${type}` })
-}
-
-const BtnSearchPurchaseOrder =()=>{
- for (let i = 1; i < 6; i++) {
- const randomInt = Math.floor(Math.random() * 999) + 1000;//4浣嶆暟闅忔満鏁�
- const randomSumInt = Math.floor(Math.random() * 99) + 10;//2浣嶆暟闅忔満鏁�
- const randomOrderInt = Math.floor(Math.random() * 99) + 100;//3浣嶆暟闅忔満鏁�
- const t = i % 2 === 0 ? 5 : 6;
- const s = i % 2 === 0 ? '鍏ュ簱':i % 3 === 0 ? '寰呭鏍�' : i % 5 === 0 ? '宸查噰璐�' :'閫�搴�';
- const CGNo = 'NGCG231200' + randomOrderInt;//閲囪喘缂栧彿
- const wlNo = 'NGWL1000' + randomInt;
- const xh = 'NGXH' + randomSumInt;
- const wlmc = 'WLMC' + randomInt;
- const gys = '渚涘簲鍟�' + randomSumInt;
- const xhdh='NG231200'+randomOrderInt;
- const w = i % 2 === 0 ? '3300' : i % 3 === 0 ? '3660' : i % 4 === 0 ? '2250' : '2580';
- const h = i % 2 === 0 ? '2440' : i % 3 === 0 ? '2440' : i % 4 === 0 ? '2000' : '2300';
- const dw = i % 2 === 0 ? '鐗�' : i % 3 === 0 ? '骞崇背' : i % 4 === 0 ? '鍖�' : '鍚�';
- now.setDate(now.getDate() + 1);
- gridOptions.data.push({
- cgdh: CGNo,
- h: t,
- xh: xh,
- wlbh: wlNo,
- wlmc: wlmc,
- gys: gys,
- w: w,
- g: h,
- dw: dw,
- cgzt:s,
- rq:dayjs(now).format('YYYY-MM-DD'),
- yl:randomSumInt,
- sl:randomOrderInt,
- xsdh:xhdh,
- je:randomInt,
- 6: '139xxxxxxxx',
-
- })
- }
-
-}
-
-
-
-//缁勪欢鎺ユ敹鍙傛暟
-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
+ {
+ value: '2',
+ label: '鍖栧鍝�'
},
- filterConfig: { //绛涢�夐厤缃」
- remote: true
+ {
+ value: '3',
+ label: '宸ュ叿'
},
- customConfig: {
- storage: true
+ {
+ value: '4',
+ label: '鏈ㄧ'
},
- editConfig: {
- trigger: 'click',
- mode: 'row',
- showStatus: true
+ {
+ value: '5',
+ label: '鐧界幓'
},
- columns: [
- {title: '鎿嶄綔', width: '8%', slots: {default: 'button_slot'}, fixed: "left"},
- {type: 'seq', fixed: "left", title: ' ', width: 50},
- { type: 'checkbox',fixed:"left", title: '', width: 50 },
- {type: 'expand', title:'璇︽儏', fixed: "left", slots: {content: 'content'}, width: 50},
- {field: 'cgdh', width: '10%', title: '閲囪喘鍗曞彿', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true},
- {field: 'cgzt', width: '10%', title: '鐘舵��', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true},
- {field: 'gys', width: '10%',title: '渚涘簲鍟�', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true},
- {field: 'wlbh', width: '10%',title: '鐗╂枡缂栧彿', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true},
- {field: 'wlmc', width: '10%', title: '鐗╂枡鍚嶇О', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true},
- {field: 'w', width: '8%',title: '瀹藉害', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true},
- {field: 'g', width: '8%',title: '楂樺害', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true},
- {field: 'h', width: '8%',title: '鍘氬害', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true},
- {field: 'xh', width: '8%',title: '鍨嬪彿', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true},
- {field: 'dw', width: '8%',title: '鍗曚綅', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true},
- {field: '6', width: '12%',title: '涓嶅惈绋庡崟浠�', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true},
- {field: 'sl', width: '8%',title: '鏁伴噺', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true},
- {field: 'sl', width: '12%',title: '宸查噰璐暟閲�', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true},
- {field: 'je', width: '8%',title: '閲戦', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true},
- {field: 'je', width: '12%',title: '涓嶅惈绋庨噾棰�', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true},
- {field: '6', width: '8%',title: '绋庣巼', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true},
- {field: 'sl', width: '8%',title: '搴撳瓨', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true},
- {field: 'yl', width: '10%',title: '鍛ㄧ敤閲�', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true},
- {field: 'yl', width: '10%',title: '鏈堢敤閲�', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true},
- {field: 'cgzt', width: '10%',title: '鍗曟嵁鐘舵��', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true},
- {field: 'xsdh', width: '10%',title: '閿�鍞崟鍙�', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true},
- {field: 'rq', width: '10%',title: '鍒跺崟鏃ユ湡', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true},
- {field: '6', width: '10%', title: '鍒跺崟浜�', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true},
- {field: '6', width: '10%',title: '閲囪喘閮ㄩ棬', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true},
- {field: '6', width: '10%',title: '閲囪喘缁勭粐', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true},
- {field: '6', width: '10%',title: '澶囨敞', filters: [{data: ''}], slots: {filter: 'num1_filter'}, sortable: true}
- ],//琛ㄥご鍙傛暟
- toolbarConfig: {
- buttons: [/*{type:'text'},
- {
- 'name': '鍒涘缓璁㈠崟',
+]
- 'code':'Add',
- },
-
- {
- 'name': '鏃犲崟鏂板',
-
- 'code':'AddNo'
- }*/
- ],
- import: false,
- export: true,
- print: true,
- zoom: true,
- custom: true,
- style: 'paddling-left:10px'
- },//琛ㄥご鎸夐挳
- data: [],//table body瀹為檯鏁版嵁
- mergeFooterItems: [
- {row: 0, col: 0, rowspan: 1, colspan: 4}
- ],//鍚堝苟鑴�
- 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 ''
- })
- ]
+const buyerOptions = [
+ {
+ value: '0',
+ label: '鍏ㄩ儴'
},
+ {
+ value: '1',
+ label: '閲囪喘鐢�'
+ },
+ {
+ value: '2',
+ label: '閲囪喘涔�'
+ },
+]
-})
+const stateOptions = [
+ {
+ value: '0',
+ label: '寰呭鏍�'
+ },
+ {
+ value: '1',
+ label: '寰呴噰璐�'
+ },
+ {
+ value: '2',
+ label: '宸查噰璐�'
+ },
+]
-/*const showDetails = ref(false)
-const detailData = ref([])
-const cellClickEvent = ({ row }) => {
- detailData.value = ['閲囪喘鍗曞彿', 'wlbh', 'wlmc', 'gys', 'h', 'k', 'g'].map(field => {
- return { label: field, value: row[field] }
- })
- showDetails.value = true
-}*/
-
+import dayjs from 'dayjs'
+import 'dayjs/locale/zh-cn'
const now = new Date()
-//鏃堕棿蹇嵎閫夋嫨
+const tableData = ref([])
+
+const autoAddRow = () => {
+ for (let i = 0; i < 10; i++) {
+ now.setDate(now.getDate() + 1)
+ const randomInt = Math.floor(Math.random() * 999) + 1000;
+ const randomOrderInt = Math.floor(Math.random() * 99) + 100;
+ const randomSumInt = Math.floor(Math.random() * 99) + 10;
+ var t = i % 2 === 0 ? 5 : 6;
+ var s = i % 3 === 0 ? '' : i % 4 === 0 ? '宸查噰璐�' : '寰呭鏍�';
+ var oNo = 'NGNO100000' + randomOrderInt;//璁㈠崟缂栧彿
+ var wlNo = 'NGWL100000' + randomInt
+ tableData.value.push({
+
+ date: dayjs(now).format('YYYY-MM-DD'),
+ name: '渚涘簲鍟�' + randomSumInt,
+ state: s,
+ city: 'Los Angeles',
+ address: 'No. 189, Grove St, Los Angeles',
+ zip: 'CA 90036',
+ number: randomInt,
+ width: '3660',
+ height: '2440',
+ rIndex: tableData.value.length + 1,
+ ordernumber: oNo,
+ strockNumber: wlNo,
+ thick: t
+ })
+ }
+}
+
+const CreatePurchaseOrder = () => {
+
+
+}
+
const datevalue = ref('')
+
const shortcuts = [
{
text: '杩戜竴鍛�',
@@ -357,5 +240,19 @@
<style scoped>
+.el-row {
+ margin-bottom: 20px;
+}
+.el-row:last-child {
+ margin-bottom: 0;
+}
+
+.el-col {
+ border-radius: 4px;
+}
+
+.m-header {
+ height: 32px;
+}
</style>
\ No newline at end of file
diff --git a/north-glass-erp/northglass-erp/src/views/mm/stockReport/StockReport.vue b/north-glass-erp/northglass-erp/src/views/mm/stockReport/StockReport.vue
index 631737d..65ca331 100644
--- a/north-glass-erp/northglass-erp/src/views/mm/stockReport/StockReport.vue
+++ b/north-glass-erp/northglass-erp/src/views/mm/stockReport/StockReport.vue
@@ -3,9 +3,9 @@
<el-container>
<el-header style="height: 30px">
<el-breadcrumb :separator-icon="ArrowRight">
-<!-- <el-breadcrumb-item>閲囪喘涓庣墿璧�</el-breadcrumb-item>
+ <el-breadcrumb-item>閲囪喘涓庣墿璧�</el-breadcrumb-item>
<el-breadcrumb-item>浠撳偍鎶ヨ〃
- </el-breadcrumb-item>-->
+ </el-breadcrumb-item>
<el-breadcrumb-item :to="{path:'/main/stockReport/WarehouseReport'}">鍘熸潗鏂欐姤琛�
</el-breadcrumb-item>
<el-breadcrumb-item :to="{path:'/main/stockReport/StockWarehouseReport'}">鎴愬搧鎶ヨ〃
@@ -15,7 +15,7 @@
<el-breadcrumb-item :to="{path:'/main/stockReport/SubsidiaryMonthReport'}">
杈呮枡鏈堢粨
</el-breadcrumb-item>
- <el-breadcrumb-item style="display: none"></el-breadcrumb-item>
+ <el-breadcrumb-item></el-breadcrumb-item>
</el-breadcrumb>
</el-header>
<el-main style="padding: 0;width: 99%;height: 100%;">
diff --git a/north-glass-erp/northglass-erp/src/views/sd/customer/CreateCustomer.vue b/north-glass-erp/northglass-erp/src/views/sd/customer/CreateCustomer.vue
index 458c395..424bd72 100644
--- a/north-glass-erp/northglass-erp/src/views/sd/customer/CreateCustomer.vue
+++ b/north-glass-erp/northglass-erp/src/views/sd/customer/CreateCustomer.vue
@@ -126,7 +126,6 @@
}
.div-form{
- margin-left: 30%;
height:70%;
width: 40%;
}
diff --git a/north-glass-erp/northglass-erp/src/views/sd/customer/Customer.vue b/north-glass-erp/northglass-erp/src/views/sd/customer/Customer.vue
index d69b78d..bb247e9 100644
--- a/north-glass-erp/northglass-erp/src/views/sd/customer/Customer.vue
+++ b/north-glass-erp/northglass-erp/src/views/sd/customer/Customer.vue
@@ -1,6 +1,10 @@
<script setup>
import {ArrowLeftBold, ArrowRight, Search} from "@element-plus/icons-vue"
import {useRouter} from "vue-router";
+let indexFlag=$ref(1)
+function changeRouter(index){
+ indexFlag=index
+}
</script>
@@ -8,8 +12,9 @@
<div id="main-div">
<div id="div-title">
<el-breadcrumb :separator-icon="ArrowRight">
- <el-breadcrumb-item :to="{ path: '/main/customer/selectCustomer' }">瀹㈡埛棣栭〉</el-breadcrumb-item>
- <el-breadcrumb-item :to="{ path: '/main/customer/CreateCustomer' }">鏂板</el-breadcrumb-item>
+ <el-breadcrumb-item @click="changeRouter(1)" :class="indexFlag===1?'indexTag':''" :to="{ path: '/main/customer/selectCustomer' }">瀹㈡埛棣栭〉</el-breadcrumb-item>
+ <el-breadcrumb-item @click="changeRouter(2)" :class="indexFlag===2?'indexTag':''" :to="{ path: '/main/customer/CreateCustomer' }">鏂板</el-breadcrumb-item>
+ <el-breadcrumb-item v-show="false" :to="{ path: '/main/product/test1' }">娴嬭瘯</el-breadcrumb-item>
</el-breadcrumb>
</div>
@@ -44,4 +49,7 @@
#select{
margin-left:0.5rem;
}
+:deep(.indexTag .el-breadcrumb__inner){
+ color: #5CADFE !important;
+}
</style>
\ No newline at end of file
diff --git a/north-glass-erp/northglass-erp/src/views/sd/delivery/Delivery.vue b/north-glass-erp/northglass-erp/src/views/sd/delivery/Delivery.vue
index 1e4b5ef..21d677e 100644
--- a/north-glass-erp/northglass-erp/src/views/sd/delivery/Delivery.vue
+++ b/north-glass-erp/northglass-erp/src/views/sd/delivery/Delivery.vue
@@ -1,16 +1,19 @@
<script setup>
import {ArrowLeftBold, ArrowRight, Search} from "@element-plus/icons-vue"
import {useRouter} from "vue-router";
-
+let indexFlag=$ref(1)
+function changeRouter(index){
+ indexFlag=index
+}
</script>
<template>
<div id="main-div">
<div id="div-title">
<el-breadcrumb :separator-icon="ArrowRight">
- <el-breadcrumb-item :to="{ path: '/main/delivery/selectDelivery' }">鍙戣揣棣栭〉</el-breadcrumb-item>
- <el-breadcrumb-item :to="{ path: '/main/delivery/selectOrderList' }">璁㈠崟鍙戣揣</el-breadcrumb-item>
- <el-breadcrumb-item :to="{ path: '/main/delivery/deliveryReport' }">鎶ヨ〃</el-breadcrumb-item>
+ <el-breadcrumb-item @click="changeRouter(1)" :class="indexFlag===1?'indexTag':''" :to="{ path: '/main/delivery/selectDelivery' }">鍙戣揣棣栭〉</el-breadcrumb-item>
+ <el-breadcrumb-item @click="changeRouter(2)" :class="indexFlag===2?'indexTag':''" :to="{ path: '/main/delivery/selectOrderList' }">璁㈠崟鍙戣揣</el-breadcrumb-item>
+ <el-breadcrumb-item @click="changeRouter(3)" :class="indexFlag===3?'indexTag':''" :to="{ path: '/main/delivery/deliveryReport' }">鎶ヨ〃</el-breadcrumb-item>
<el-breadcrumb-item v-show="false" :to="{ path: '/main/delivery/deliveryReport' }">鎶ヨ〃</el-breadcrumb-item>
</el-breadcrumb>
</div>
@@ -46,4 +49,7 @@
#select{
margin-left:0.5rem;
}
+:deep(.indexTag .el-breadcrumb__inner){
+ color: #5CADFE !important;
+}
</style>
\ No newline at end of file
diff --git a/north-glass-erp/northglass-erp/src/views/sd/order/Order.vue b/north-glass-erp/northglass-erp/src/views/sd/order/Order.vue
index b1addba..78000a9 100644
--- a/north-glass-erp/northglass-erp/src/views/sd/order/Order.vue
+++ b/north-glass-erp/northglass-erp/src/views/sd/order/Order.vue
@@ -3,15 +3,19 @@
import {useRouter} from "vue-router";
const router = useRouter()
+let indexFlag=$ref(1)
+function changeRouter(index){
+ indexFlag=index
+}
</script>
<template>
<div id="main-div">
<div id="div-title">
<el-breadcrumb :separator-icon="ArrowRight">
- <el-breadcrumb-item :to="{ path: '/main/order/selectOrder' }">璁㈠崟棣栭〉</el-breadcrumb-item>
- <el-breadcrumb-item :to="{ path: '/main/order/createOrder' }">鍒涘缓</el-breadcrumb-item>
- <el-breadcrumb-item :to="{ path: '/main/order/orderReport' }">鎶ヨ〃</el-breadcrumb-item>
+ <el-breadcrumb-item @click="changeRouter(1)" :class="indexFlag===1?'indexTag':''" :to="{ path: '/main/order/selectOrder' }">璁㈠崟棣栭〉</el-breadcrumb-item>
+ <el-breadcrumb-item @click="changeRouter(2)" :class="indexFlag===2?'indexTag':''" :to="{ path: '/main/order/createOrder' }">鍒涘缓</el-breadcrumb-item>
+ <el-breadcrumb-item @click="changeRouter(3)" :class="indexFlag===3?'indexTag':''" :to="{ path: '/main/order/orderReport' }">鎶ヨ〃</el-breadcrumb-item>
<el-breadcrumb-item v-show="false" :to="{ path: '/main/order/orderReport' }">鎶ヨ〃</el-breadcrumb-item>
</el-breadcrumb>
</div>
@@ -47,4 +51,7 @@
#select{
margin-left:0.5rem;
}
+:deep(.indexTag .el-breadcrumb__inner){
+ color: #5CADFE !important;
+}
</style>
\ No newline at end of file
diff --git a/north-glass-erp/northglass-erp/src/views/sd/product/Product.vue b/north-glass-erp/northglass-erp/src/views/sd/product/Product.vue
index fd31b46..94a4787 100644
--- a/north-glass-erp/northglass-erp/src/views/sd/product/Product.vue
+++ b/north-glass-erp/northglass-erp/src/views/sd/product/Product.vue
@@ -6,9 +6,11 @@
import {ElMessage} from "element-plus";
import {useRouter} from "vue-router";
import GlassType from '@/components/sd/product/GlassType.vue'
-
-
const router = useRouter()
+let indexFlag=$ref(1)
+function changeRouter(index){
+ indexFlag=index
+}
</script>
@@ -16,8 +18,8 @@
<div id="main">
<div id="div-title">
<el-breadcrumb :separator-icon="ArrowRight">
- <el-breadcrumb-item :to="{ path: '/main/product/selectProduct' }">浜у搧棣栭〉</el-breadcrumb-item>
- <el-breadcrumb-item :to="{ path: '/main/product/createProduct' }">鍒涘缓</el-breadcrumb-item>
+ <el-breadcrumb-item @click="changeRouter(1)" :class="indexFlag===1?'indexTag':''" :to="{ path: '/main/product/selectProduct' }">浜у搧棣栭〉</el-breadcrumb-item>
+ <el-breadcrumb-item @click="changeRouter(2)" :class="indexFlag===2?'indexTag':''" :to="{ path: '/main/product/createProduct' }">鍒涘缓</el-breadcrumb-item>
<!-- <el-breadcrumb-item :to="{ path: '/main/product/test' }">娴嬭瘯</el-breadcrumb-item>-->
<!-- <el-breadcrumb-item :to="{ path: '/main/product/test1' }">娴嬭瘯</el-breadcrumb-item>-->
<el-breadcrumb-item v-show="false" :to="{ path: '/main/product/test1' }">娴嬭瘯</el-breadcrumb-item>
@@ -56,4 +58,7 @@
#select{
margin-left:0.5rem;
}
+:deep(.indexTag .el-breadcrumb__inner){
+ color: #5CADFE !important;
+}
</style>
\ No newline at end of file
diff --git a/north-glass-erp/northglass-erp/src/views/sd/product/SelectProduct.vue b/north-glass-erp/northglass-erp/src/views/sd/product/SelectProduct.vue
index f0b1d2c..47be59c 100644
--- a/north-glass-erp/northglass-erp/src/views/sd/product/SelectProduct.vue
+++ b/north-glass-erp/northglass-erp/src/views/sd/product/SelectProduct.vue
@@ -2,25 +2,57 @@
import request from "@/utils/request"
import deepClone from "@/utils/deepClone"
import {ElDatePicker, ElMessage} from "element-plus"
-import useProductGlassTypeStore from "@/stores/productGlassType"
-import {watch} from "vue"
+import useProductGlassTypeStore from "@/stores/sd/product/productGlassType"
+import useProductStore from "@/stores/sd/product/prduct"
+import {onMounted, reactive, ref, watch} from "vue"
import {Search} from "@element-plus/icons-vue"
import GlassType from "@/components/sd/product/GlassType.vue"
import {useRouter} from 'vue-router'
import BasicTable from '@/components/basic/BasicTable.vue'
+import scrollEvnt from "@/hook";
let productGlassTypeStore = useProductGlassTypeStore()
+let productStore = useProductStore()
let router=useRouter()
+//鐩戝惉鐜荤拑绫诲瀷鏀瑰彉
watch(productGlassTypeStore,(newVal,oldVal) => {
let list = productList.filter( product=>{
return product.glassType==newVal.GlassType
})
})
-//let productList=$ref([])
+let pageNum=$ref(1)
+watch(productStore,(newVal,oldVal) => {
+ if(newVal.flag===true){
+ pageNum=pageNum+1
+ //鍚庣鑾峰彇鏈夊灏戦〉锛岃秴杩囧灏戦〉涓嶅啀璇锋眰
+ /*if(pageNum>5){
+ console.log(newVal.pageNum)
+ return
+ }*/
+ request.get(`/product/${pageNum}/100`).then((res) => {
+ gridOptions.loading=true
+ try{
+ if(res.code==200){
+ gridOptions.data= gridOptions.data.concat(res.data)
+ newVal.flag=false
+ setTimeout(()=>{
+ gridOptions.loading=false
+ },1000)
+ }else{
+ ElMessage.warning(res.msg)
+ }
+ }finally {
+
+ }
+ })
+ }
+
+})
+
let flag = $ref(false)
-request.get("/product").then((res) => {
+request.get("/product/1/100").then((res) => {
if(res.code==200){
- tableProp.datas= deepClone(res.data)
+ gridOptions.data= deepClone(res.data)
flag = true
}else{
ElMessage.warning(res.msg)
@@ -30,18 +62,6 @@
//瀛愮粍浠舵帴鏀跺弬鏁�
let tableProp = $ref({
- title:[
- {type:'expand',fixed:"left",slots: { content:'content' },width: 50},
- {type: 'seq',fixed:"left", title: '鑷簭', width: 80 },
- {title: '鎿嶄綔', width: 110, slots: { default: 'button_slot' },fixed:"left"},
- {field: 'prodID', title: '缂栧彿',filters:[{ data: '' }],slots: { filter: 'num1_filter' }, sortable: true},
- {field: 'product', title: '鍚嶇О',filters:[{ data: '' }],slots: { filter: 'num1_filter' }, sortable: true},
- {field: 'typeName', title: '鎵�灞炵被鍒�',filters:[{ data: '' }],slots: { filter: 'num1_filter' }, sortable: true},
- {field: 'query', title: '蹇�熸煡璇�',filters:[{ data: '' }],slots: { filter: 'num1_filter' }, sortable: true},
- {field: 'remarks', title: '澶囨敞',filters:[{ data: '' }],slots: { filter: 'num1_filter' }, sortable: true},
- {field: 'creator', title: '鍒涘缓浜�',filters:[{ data: '' }],slots: { filter: 'num1_filter' }, sortable: true},
- {field: 'createTime', title: '鍒涘缓鏃堕棿',filters:[{ data: '' }],slots: { filter: 'num1_filter' }, sortable: true}
- ],
datas:null,
footList:[],
//绛涢�夋潯浠跺垪
@@ -51,7 +71,7 @@
-const getChildren = (row,type) =>{
+const getTableRow = (row,type) =>{
switch (type) {
case 'edit' : {
router.push({path: '/main/product/createProduct', query: { id: row.id }})
@@ -64,10 +84,80 @@
}
}
-const getCheckList = (row) =>{
- alert('鎴戞帴鏀跺埌瀛愮粍浠朵紶閫佺殑纭澶嶉�夋淇℃伅鍙湪鎺у埗鍙版煡鐪�')
- console.log(row)
-}
+// const getCheckList = (row) =>{
+// alert('鎴戞帴鏀跺埌瀛愮粍浠朵紶閫佺殑纭澶嶉�夋淇℃伅鍙湪鎺у埗鍙版煡鐪�')
+// }
+
+
+const xGrid = ref()
+const gridOptions = reactive({
+ loading: false,
+ border: "full",//琛ㄦ牸鍔犺竟妗�
+ keepSource: true,//淇濇寔婧愭暟鎹�
+ align: 'center',//鏂囧瓧灞呬腑
+ stripe:true,//鏂戦┈绾�
+ rowConfig: {isCurrent: true, isHover: true,height: 50},//榧犳爣绉诲姩鎴栭�夋嫨楂樹寒
+ id: 'demo_1',
+ showFooter: true,//鏄剧ず鑴�
+ printConfig: {},
+ importConfig: {},
+ exportConfig: {},
+ scrollY:{ enabled: true ,gt:100},//寮�鍚櫄鎷熸粴鍔�
+ showOverflow:true,
+ columnConfig: {
+ resizable: true,
+ useKey: true
+ },
+ filterConfig: { //绛涢�夐厤缃」
+ remote: true
+ },
+ customConfig: {
+ storage: true
+ },
+ editConfig: {
+ trigger: 'click',
+ mode: 'row',
+ showStatus: true
+ },
+ columns:[
+ {type:'expand',fixed:"left",slots: { content:'content' },width: 50},
+ {type: 'seq',fixed:"left", title: '鑷簭', width: 80 },
+ {title: '鎿嶄綔', width: 110, slots: { default: 'button_slot' },fixed:"left"},
+ {field: 'prodID', title: '缂栧彿',filters:[{ data: '' }],slots: { filter: 'num1_filter' }, sortable: true},
+ {field: 'product', title: '鍚嶇О',filters:[{ data: '' }],slots: { filter: 'num1_filter' }, sortable: true},
+ {field: 'typeName', title: '鎵�灞炵被鍒�',filters:[{ data: '' }],slots: { filter: 'num1_filter' }, sortable: true},
+ {field: 'query', title: '蹇�熸煡璇�',filters:[{ data: '' }],slots: { filter: 'num1_filter' }, sortable: true},
+ {field: 'remarks', title: '澶囨敞',filters:[{ data: '' }],slots: { filter: 'num1_filter' }, sortable: true},
+ {field: 'creator', title: '鍒涘缓浜�',filters:[{ data: '' }],slots: { filter: 'num1_filter' }, sortable: true},
+ {field: 'createTime', title: '鍒涘缓鏃堕棿',filters:[{ data: '' }],slots: { filter: 'num1_filter' }, sortable: true}
+ ],//琛ㄥご鍙傛暟
+ toolbarConfig: {
+ buttons: [],
+ import: false,
+ export: true,
+ print: true,
+ zoom: true,
+ custom: true
+ },
+ data: null,//table body瀹為檯鏁版嵁
+ footerMethod ({ columns, data }) {//椤佃剼鍑芥暟
+ return[
+ columns.map((column, columnIndex) => {
+ if (columnIndex === 0) {
+ return '鍚堣:'
+ }
+ return ''
+ })
+ ]
+ }
+
+})
+
+
+
+
+
+
</script>
@@ -80,53 +170,79 @@
type="primary" :icon="Search">鏌ヨ</el-button>
- <basic-table style="height: 97%" v-if="flag"
- :tableProp="tableProp"
- @getCheckList="getCheckList"
- @getChildren="getChildren"
- ></basic-table>
+ <vxe-grid
+ max-height="100%"
+ class="mytable-scrollbar"
+ ref="xGrid"
+ v-bind="gridOptions"
+ v-on="gridEvents"
+ @scroll ="scrollEvnt"
+ >
+ <!-- @toolbar-button-click="toolbarButtonClickEvent"-->
+ <!-- 涓嬫媺鏄剧ず鎵�鏈変俊鎭彃妲�-->
+ <template #content="{ row }">
+ <ul class="expand-wrapper">
+ <li v-for="(item,key) in row">
+ <span style="font-weight: bold">{{key+': '}}</span>
+ <span>{{ item }}</span>
+ </li>
+ </ul>
+ </template>
-<!-- <el-table
- v-loading="loading"
- :data="productList"
- :header-cell-style="{ 'text-align': 'center' }"
- :cell-style="{ 'text-align': 'center' }"
- lazy
- border
- style="width: 100%;"
- max-height="80vh">
+ <!--宸﹁竟鍥哄畾鏄剧ず鐨勬彃妲�-->
+ <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-table-column type="expand" fixed>
- <template #default="props">
- <div m="4">
- <p m="t-0 b-2">缂栧彿: {{ props.row.prodID }}</p>
- <p m="t-0 b-2">鍚嶇О: {{ props.row.product }}</p>
- <p m="t-0 b-2">鎵�灞炵被鍒�: {{ props.row.glassType }}</p>
- <p m="t-0 b-2">蹇�熸煡璇�: {{ props.row.query }}</p>
- <p m="t-0 b-2">澶囨敞: {{ props.row.remarks }}</p>
- <p m="t-0 b-2">鍒涘缓浜�: {{ props.row.creator }}</p>
- <p m="t-0 b-2">鍒涘缓鏃堕棿: {{ props.row.createTime }}</p>
+ <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>
- </template>
- </el-table-column>
- <el-table-column label="鎿嶄綔" width="110" fixed >
- <el-button link type="primary" size="small">缂栬緫</el-button>
- <el-button link type="primary" size="small">鍒犻櫎</el-button>
- </el-table-column>
- <el-table-column sortable prop="prodID" label="缂栧彿" width="110" />
- <el-table-column prop="product" label="鍚嶇О" :show-overflow-tooltip='true' />
- <el-table-column prop="typeName" label="鎵�灞炵被鍒�" width="175" />
- <el-table-column prop="query" label="蹇�熸煡璇�" width="150" />
- <el-table-column prop="remarks" label="澶囨敞" :show-overflow-tooltip='true' width="100" />
- <el-table-column prop="creator" label="鍒涘缓浜�" width="75" />
- <el-table-column prop="createTime" label="鍒涘缓鏃堕棿" width="100" />
- </el-table>-->
+ </div>
+ </template>
+
+
+ </vxe-grid>
+
+
+<!-- <basic-table-->
+<!-- style="height: 97%" v-if="flag"-->
+<!-- :tableProp="tableProp"-->
+<!-- @getCheckList="getCheckList"-->
+<!-- @getChildren="getChildren"-->
+<!-- ></basic-table>-->
</div>
</template>
<style scoped>
-
+/*婊氬姩鏉℃暣浣撻儴鍒�*/
+.mytable-scrollbar ::-webkit-scrollbar {
+ width: 10px;
+ height: 10px;
+}
+/*婊氬姩鏉$殑杞ㄩ亾*/
+.mytable-scrollbar ::-webkit-scrollbar-track {
+ background-color: #FFFFFF;
+}
+/*婊氬姩鏉¢噷闈㈢殑灏忔柟鍧楋紝鑳藉悜涓婂悜涓嬬Щ鍔�*/
+.mytable-scrollbar ::-webkit-scrollbar-thumb {
+ background-color: transparent;
+ border-radius: 5px;
+ border: 1px solid #F1F1F1;
+ box-shadow: inset 0 0 6px rgba(0,0,0,.3);
+}
+.mytable-scrollbar ::-webkit-scrollbar-thumb:hover {
+ background-color: #ffffff;
+}
+.mytable-scrollbar ::-webkit-scrollbar-thumb:active {
+ background-color: white;
+}
+/*杈硅锛屽嵆涓や釜婊氬姩鏉$殑浜ゆ眹澶�*/
+.mytable-scrollbar ::-webkit-scrollbar-corner {
+ background-color: #FFFFFF;
+}
</style>
\ No newline at end of file
diff --git a/north-glass-erp/northglass-erp/src/views/sd/returns/Returns.vue b/north-glass-erp/northglass-erp/src/views/sd/returns/Returns.vue
index 9a4d48b..cfa6d0c 100644
--- a/north-glass-erp/northglass-erp/src/views/sd/returns/Returns.vue
+++ b/north-glass-erp/northglass-erp/src/views/sd/returns/Returns.vue
@@ -1,16 +1,20 @@
<script setup>
import {ArrowLeftBold, ArrowRight, Search} from "@element-plus/icons-vue"
import {useRouter} from "vue-router";
-
+let indexFlag=$ref(1)
+function changeRouter(index){
+ indexFlag=index
+}
</script>
<template>
<div id="main-div">
<div id="div-title">
<el-breadcrumb :separator-icon="ArrowRight">
- <el-breadcrumb-item :to="{ path: '/main/returns/selectReturns' }">閫�璐ч椤�</el-breadcrumb-item>
- <el-breadcrumb-item :to="{ path: '/main/returns/selectDeliveryList' }">鍙戣揣閫�璐�</el-breadcrumb-item>
- <el-breadcrumb-item :to="{ path: '/main/returns/returnsReport' }">鎶ヨ〃</el-breadcrumb-item>
+ <el-breadcrumb-item @click="changeRouter(1)" :class="indexFlag===1?'indexTag':''" :to="{ path: '/main/returns/selectReturns' }">閫�璐ч椤�</el-breadcrumb-item>
+ <el-breadcrumb-item @click="changeRouter(2)" :class="indexFlag===2?'indexTag':''" :to="{ path: '/main/returns/selectDeliveryList' }">鍙戣揣閫�璐�</el-breadcrumb-item>
+ <el-breadcrumb-item @click="changeRouter(3)" :class="indexFlag===3?'indexTag':''" :to="{ path: '/main/returns/returnsReport' }">鎶ヨ〃</el-breadcrumb-item>
+ <el-breadcrumb-item v-show="false" :to="{ path: '/main/product/test1' }">娴嬭瘯</el-breadcrumb-item>
</el-breadcrumb>
</div>
@@ -45,4 +49,7 @@
#select{
margin-left:0.5rem;
}
+:deep(.indexTag .el-breadcrumb__inner){
+ color: #5CADFE !important;
+}
</style>
\ No newline at end of file
diff --git a/north-glass-erp/src/main/java/com/example/erp/common/Result.java b/north-glass-erp/src/main/java/com/example/erp/common/Result.java
index d7c89e5..7ace997 100644
--- a/north-glass-erp/src/main/java/com/example/erp/common/Result.java
+++ b/north-glass-erp/src/main/java/com/example/erp/common/Result.java
@@ -23,7 +23,7 @@
return new Result(code,msg,null);
}
public static Result error(){
- return new Result(Constants.Code_500,"绯荤粺鍙戠敓閿欒",null);
+ return new Result(Constants.Code_500,"鏈嶅姟鍣ㄥ彂鐢熷紓甯�",null);
}
}
diff --git a/north-glass-erp/src/main/java/com/example/erp/common/interceptor/JwtInterceptor.java b/north-glass-erp/src/main/java/com/example/erp/common/interceptor/JwtInterceptor.java
index 28b42e7..60ed717 100644
--- a/north-glass-erp/src/main/java/com/example/erp/common/interceptor/JwtInterceptor.java
+++ b/north-glass-erp/src/main/java/com/example/erp/common/interceptor/JwtInterceptor.java
@@ -29,7 +29,7 @@
@Override
public boolean preHandle(HttpServletRequest request, HttpServletResponse response, Object handler) throws Exception {
//return HandlerInterceptor.super.preHandle(request, response, handler);
- String token=request.getHeader("token");
+ /*String token=request.getHeader("token");
if(!(handler instanceof HandlerMethod)){
return true;
}
@@ -58,7 +58,7 @@
jwtVerifier.verify(token);
} catch (JWTVerificationException e) {
throw new ServiceException(Constants.Code_401,"token楠岃瘉澶辫触,璇烽噸鏂扮櫥闄�");
- }
+ }*/
return true;
}
diff --git a/north-glass-erp/src/main/java/com/example/erp/controller/sd/ProductController.java b/north-glass-erp/src/main/java/com/example/erp/controller/sd/ProductController.java
index f24f2bb..d948a09 100644
--- a/north-glass-erp/src/main/java/com/example/erp/controller/sd/ProductController.java
+++ b/north-glass-erp/src/main/java/com/example/erp/controller/sd/ProductController.java
@@ -3,9 +3,7 @@
import com.example.erp.common.Result;
import com.example.erp.service.sd.ProductService;
import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.web.bind.annotation.GetMapping;
-import org.springframework.web.bind.annotation.RequestMapping;
-import org.springframework.web.bind.annotation.RestController;
+import org.springframework.web.bind.annotation.*;
@RestController
@RequestMapping("/product")
@@ -13,9 +11,8 @@
@Autowired
ProductService productService;
- @GetMapping
- public Result defaultDateProduct(){
- //璋冪敤productService鐨刣efaultDateProduct鏂规硶锛岃繑鍥炵粨鏋�
- return Result.seccess(productService.defaultDateProduct());
+ @GetMapping("/{pageNum}/{pageSize}")
+ public Result defaultDateProduct(@PathVariable Integer pageNum, @PathVariable Integer pageSize){
+ return Result.seccess(productService.defaultDateProduct(pageNum,pageSize));
}
}
diff --git a/north-glass-erp/src/main/java/com/example/erp/mapper/sd/ProductMapper.java b/north-glass-erp/src/main/java/com/example/erp/mapper/sd/ProductMapper.java
index 6bc2b6a..912f2d9 100644
--- a/north-glass-erp/src/main/java/com/example/erp/mapper/sd/ProductMapper.java
+++ b/north-glass-erp/src/main/java/com/example/erp/mapper/sd/ProductMapper.java
@@ -2,10 +2,11 @@
import com.example.erp.entity.sd.Product;
import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Param;
import java.util.List;
@Mapper
public interface ProductMapper {
- List<Product> defaultProduct();
+ List<Product> defaultProduct(@Param("offset") Integer offset, @Param("pageSize") Integer pageSize);
}
diff --git a/north-glass-erp/src/main/java/com/example/erp/service/sd/ProductService.java b/north-glass-erp/src/main/java/com/example/erp/service/sd/ProductService.java
index aff3714..dcb9cad 100644
--- a/north-glass-erp/src/main/java/com/example/erp/service/sd/ProductService.java
+++ b/north-glass-erp/src/main/java/com/example/erp/service/sd/ProductService.java
@@ -13,7 +13,8 @@
public class ProductService {
@Autowired
ProductMapper productMapper;
- public List<Product> defaultDateProduct() {
- return productMapper.defaultProduct();
+ public List<Product> defaultDateProduct(Integer pageNum,Integer pageSize) {
+ Integer offset = (pageNum-1)*pageSize;
+ return productMapper.defaultProduct(offset,pageSize);
}
}
diff --git a/north-glass-erp/src/main/resources/application.yml b/north-glass-erp/src/main/resources/application.yml
index ea893b0..80f43a2 100644
--- a/north-glass-erp/src/main/resources/application.yml
+++ b/north-glass-erp/src/main/resources/application.yml
@@ -10,12 +10,12 @@
strict: false #璁剧疆涓ユ牸妯″紡,榛樿false涓嶅惎鍔�. 鍚姩鍚庡湪鏈尮閰嶅埌鎸囧畾鏁版嵁婧愭椂鍊欏洖鎶涘嚭寮傚父,涓嶅惎鍔ㄤ細浣跨敤榛樿鏁版嵁婧�.
datasource:
user_info:
- url: jdbc:mysql://10.153.19.12:3306/erp_user_info?serverTimezone=GMT%2b8
+ url: jdbc:mysql://10.153.19.150:3306/erp_user_info?serverTimezone=GMT%2b8
username: root
password: beibo.123/
driver-class-name: com.mysql.cj.jdbc.Driver
erp_sd:
- url: jdbc:mysql://10.153.19.12:3306/erp_sd?serverTimezone=GMT%2b8
+ url: jdbc:mysql://10.153.19.150:3306/erp_sd?serverTimezone=GMT%2b8
username: root
password: beibo.123/
driver-class-name: com.mysql.cj.jdbc.Driver
diff --git a/north-glass-erp/src/main/resources/mapper/sd/Product.xml b/north-glass-erp/src/main/resources/mapper/sd/Product.xml
index acda317..1778fba 100644
--- a/north-glass-erp/src/main/resources/mapper/sd/Product.xml
+++ b/north-glass-erp/src/main/resources/mapper/sd/Product.xml
@@ -23,6 +23,7 @@
left join basic_glass_type bgt on bgt.typeID = a.glassType
order by id desc
+ limit #{offset},#{pageSize}
;
</select>
</mapper>
\ No newline at end of file
diff --git a/north-glass-erp/target/classes/application.yml b/north-glass-erp/target/classes/application.yml
index ea893b0..80f43a2 100644
--- a/north-glass-erp/target/classes/application.yml
+++ b/north-glass-erp/target/classes/application.yml
@@ -10,12 +10,12 @@
strict: false #璁剧疆涓ユ牸妯″紡,榛樿false涓嶅惎鍔�. 鍚姩鍚庡湪鏈尮閰嶅埌鎸囧畾鏁版嵁婧愭椂鍊欏洖鎶涘嚭寮傚父,涓嶅惎鍔ㄤ細浣跨敤榛樿鏁版嵁婧�.
datasource:
user_info:
- url: jdbc:mysql://10.153.19.12:3306/erp_user_info?serverTimezone=GMT%2b8
+ url: jdbc:mysql://10.153.19.150:3306/erp_user_info?serverTimezone=GMT%2b8
username: root
password: beibo.123/
driver-class-name: com.mysql.cj.jdbc.Driver
erp_sd:
- url: jdbc:mysql://10.153.19.12:3306/erp_sd?serverTimezone=GMT%2b8
+ url: jdbc:mysql://10.153.19.150:3306/erp_sd?serverTimezone=GMT%2b8
username: root
password: beibo.123/
driver-class-name: com.mysql.cj.jdbc.Driver
diff --git a/north-glass-erp/target/classes/mapper/sd/Product.xml b/north-glass-erp/target/classes/mapper/sd/Product.xml
index acda317..1778fba 100644
--- a/north-glass-erp/target/classes/mapper/sd/Product.xml
+++ b/north-glass-erp/target/classes/mapper/sd/Product.xml
@@ -23,6 +23,7 @@
left join basic_glass_type bgt on bgt.typeID = a.glassType
order by id desc
+ limit #{offset},#{pageSize}
;
</select>
</mapper>
\ No newline at end of file
--
Gitblit v1.8.0