From ce675ff0428ad7d0d27c11e4fce1e0d7af7608aa Mon Sep 17 00:00:00 2001
From: zhc077 <565291854>
Date: Wed, 7 Dec 2022 12:02:06 +0800
Subject: [PATCH] =?UTF-8?q?=E8=BD=A6=E9=97=B4=E5=B7=A5=E4=BD=8D=E7=AE=A1?=
=?UTF-8?q?=E7=90=86=E4=BF=AE=E6=94=B9=2012.7?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../src/views/team/StationList.vue | 16 +-
.../src/views/team/StationToolList.vue | 112 +++++++++--
.../views/team/modules/StationToolModal.vue | 181 ++++++++++--------
3 files changed, 200 insertions(+), 109 deletions(-)
diff --git a/ant-design-vue-jeecg/src/views/team/StationList.vue b/ant-design-vue-jeecg/src/views/team/StationList.vue
index 9c456935..55124f8d 100644
--- a/ant-design-vue-jeecg/src/views/team/StationList.vue
+++ b/ant-design-vue-jeecg/src/views/team/StationList.vue
@@ -188,19 +188,19 @@ export default {
jumpPage1(record) {
this.$router.push({
path: '/team/stationMachineList',
- // query: { // 路由携带参数
- // 'id': record.id,
- // // 'styleNames': record.styleNames,
- // },
+ query: { // 路由携带参数
+ 'id': record.id,
+ 'stationName': record.stationName,
+ },
});
},
jumpPage2(record) {
this.$router.push({
path: '/team/StationToolList',
- // query: { // 路由携带参数
- // 'id': record.stationId,
- // // 'styleNames': record.styleNames,
- // },
+ query: { // 路由携带参数
+ 'stationId': record.id,
+ 'stationName': record.stationName,
+ },
});
},
}
diff --git a/ant-design-vue-jeecg/src/views/team/StationToolList.vue b/ant-design-vue-jeecg/src/views/team/StationToolList.vue
index 0c687e67..482cb7ec 100644
--- a/ant-design-vue-jeecg/src/views/team/StationToolList.vue
+++ b/ant-design-vue-jeecg/src/views/team/StationToolList.vue
@@ -31,7 +31,8 @@
-
新增
+
新增
+
导出
@@ -49,7 +50,6 @@
返回
-
@@ -78,17 +78,17 @@
handleDelete(record.id)">
删除
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
@@ -96,7 +96,7 @@
-
+
@@ -105,6 +105,8 @@ import '@/assets/less/TableExpand.less'
import {mixinDevice} from '@/utils/mixin'
import StationToolModal from './modules/StationToolModal'
import {JeecgListMixin} from '@/mixins/JeecgListMixin'
+import {getAction} from "@api/manage";
+import {filterObj} from "@/utils/util";
export default {
name: "StationToolList",
@@ -132,6 +134,11 @@ export default {
align: "center",
dataIndex: 'stationId'
},
+ {
+ title: '工位名称',
+ align: "center",
+ dataIndex: 'stationName',
+ },
{
title: '工具ID',
align: "center",
@@ -151,8 +158,17 @@ export default {
exportXlsUrl: "/stationTool/exportXls",
importExcelUrl: "/stationTool/importExcel",
},
+ //参数
+ loadRouteType: false,
+ stationId: "",
+ stationName: "",
+ dictOptions: {},
+ superFieldList: [],
}
},
+ created() {
+ this.loadParameter();
+ },
computed: {
importExcelUrl: function () {
return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`;
@@ -161,14 +177,70 @@ export default {
methods: {
fanHui() {
this.$router.push({
- path: '/team/StationList',
- // query: { // 路由携带参数
- // 'id': record.id,
- // 'typeId': record.typeId,
- // }
- // });
+ path: '/src/views/team/StationList',
+ // path: '/src/views/zyclothsstyle/ZyClothsStyleList',
});
},
+ // initDictConfig() {
+ // },
+ valueChange(value) {
+ if (value) this.loadData()
+ },
+ //加载传递参数
+ loadParameter() {
+ if (this.loadRouteType === false) {
+ this.stationId = this.$route.query.stationId;
+ this.stationName = this.$route.query.stationName;
+ // this.biaoTi = this.$route.query.styleNames+"款式面料管理";
+ // console.log("*******传递的stationId:" + this.stationId)
+ this.loadRouteType = true;
+ }
+ },
+ loadData(arg) {
+ if (!this.url.list) {
+ this.$message.error("请设置url.list属性!")
+ return
+ }
+ //加载数据 若传入参数1则加载第一页的内容
+ if (arg === 1) {
+ this.ipagination.current = 1;
+ }
+ this.loadParameter();
+ var params = this.getQueryParams();//查询条件
+ this.loading = true;
+ console.log("----------------the params:", params);
+ getAction(this.url.list, params).then((res) => {
+ if (res.success) {
+ this.dataSource = res.result.records || res.result;
+ if (res.result.total) {
+ this.ipagination.total = res.result.total;
+ } else {
+ this.ipagination.total = 0;
+ }
+ } else {
+ this.$message.warning(res.message)
+ }
+ }).finally(() => {
+ this.dataSource.forEach(item => {
+ item['stationName'] = this.stationName;
+ })
+ this.loading = false
+ })
+ },
+ getQueryParams() {
+ //获取查询条件
+ let sqp = {}
+ if (this.superQueryParams) {
+ sqp['superQueryParams'] = encodeURI(this.superQueryParams)
+ sqp['superQueryMatchType'] = this.superQueryMatchType
+ }
+ var param = Object.assign(sqp, this.queryParam, this.isorter, this.filters);
+ param.field = this.getQueryField();
+ param.pageNo = this.ipagination.current;
+ param.pageSize = this.ipagination.pageSize;
+ param.stationId = this.stationId;
+ return filterObj(param);
+ },
}
}
diff --git a/ant-design-vue-jeecg/src/views/team/modules/StationToolModal.vue b/ant-design-vue-jeecg/src/views/team/modules/StationToolModal.vue
index 908250c7..c519fe47 100644
--- a/ant-design-vue-jeecg/src/views/team/modules/StationToolModal.vue
+++ b/ant-design-vue-jeecg/src/views/team/modules/StationToolModal.vue
@@ -11,15 +11,19 @@
-
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
+
@@ -28,88 +32,103 @@