update 2023.4.23

This commit is contained in:
lb
2023-04-23 14:15:20 +08:00
parent aaa571d77b
commit dfbc7e08f9
10 changed files with 68 additions and 66 deletions

View File

@@ -6,7 +6,7 @@ import { timeFilter } from '@/utils/filters'
export default function () {
const tableProps = [
{ type: 'index', label: '序号' },
// { type: 'index', label: '序号' },
{ prop: "code", label: "窑车号" },
{ prop: "createTime", label: "添加时间", filter: timeFilter },
// { prop: "code", label: "编码" },

View File

@@ -20,7 +20,7 @@
@size-change="handleSizeChange"
@current-change="handlePageChange"
:current-page.sync="page"
:page-sizes="[1, 5, 10, 20, 50, 100]"
:page-sizes="[20, 50, 100]"
:page-size="size"
:total="totalPage"
layout="total, sizes, prev, pager, next, jumper"
@@ -118,7 +118,7 @@ export default {
if (val && val !== oldVal) {
// get list
this.page = 1;
this.size = 20;
this.size = 100;
this.getList();
}
},
@@ -133,7 +133,7 @@ export default {
topBtnConfig: null,
totalPage: 100,
page: 1,
size: 20, // 默认20
size: 100, // 默认20
dataList: [],
tableLoading: false,
refreshLayoutKey: null,
@@ -262,7 +262,7 @@ export default {
this.$message.success("删除成功!");
this.page = 1;
this.size = 10;
this.size = 100;
this.getList();
} else {
this.$message({

View File

@@ -5,7 +5,7 @@ import { timeFilter } from '@/utils/filters'
export default function () {
const tableProps = [
{ type: 'index', label: '序号' },
// { type: 'index', label: '序号' },
// { prop: "createTime", label: "添加时间", filter: timeFilter },
{ prop: "code", label: "窑车号" },
{ prop: "stateDictValue", label: "状态", subcomponent: StateSelect },

View File

@@ -6,7 +6,7 @@ import StateSelect from '@/components/StateSelect.vue';
export default function () {
const tableProps = [
{ type: "index", label: "序号" },
// { type: "index", label: "序号" },
// { prop: "createTime", label: "添加时间", filter: timeFilter },
{ prop: "code", label: "窑车号" },
{ prop: "stateDictValue", label: "状态", subcomponent: StateSelect },
@@ -29,6 +29,8 @@ export default function () {
],
},
];
// 设置页面默认的 page size 为 100 条数据
tableProps.defaultPageSize = 100;
const headFormFields = [
{

View File

@@ -5,7 +5,7 @@
**/
-->
<template>
<div class="list-view-with-head">
<div class="list-view-with-head" ref="cursor-loading-ref">
<!-- <head-form :form-config="headFormConfig" @headBtnClick="btnClick" /> -->
<BaseSearchForm :head-config="headConfig" @btn-click="handleBtnClick" />
@@ -326,6 +326,25 @@ export default {
case "导入":
this.openUploadDialog();
break;
case "同步":
this.$message({
message: '正在同步...',
type: 'success',
duration: 1000
})
this.$refs['cursor-loading-ref'].style.cursor = 'wait'
return this.$http.post(this.urls.syncUrl).then(({ data: res }) => {
this.$message({
message: res.msg,
type: res.code === 0 ? 'succes' : 'error',
duration: 1500
, onClose: () => {
this.getList()
this.$refs['cursor-loading-ref'].style.cursor = 'unset'
}
})
})
}
},

View File

@@ -69,6 +69,13 @@ export default function () {
plain: true,
},
},
{
button: {
type: "plain",
name: "同步",
permission: "",
}
},
];
/**
@@ -272,6 +279,7 @@ export default function () {
subpage: "/pms/materialArrt/page",
importUrl: "/pms/material/importExcel",
templateUrl: "/importTemplates/materialImport.xlsx",
syncUrl: "/pms/trans/matSync",
// more...
},
};

View File

@@ -20,7 +20,7 @@
@size-change="handleSizeChange"
@current-change="handlePageChange"
:current-page.sync="page"
:page-sizes="[1, 5, 10, 20, 50, 100]"
:page-sizes="[20, 50, 100]"
:page-size="size"
:total="totalPage"
layout="total, sizes, prev, pager, next, jumper"
@@ -125,7 +125,7 @@ export default {
if (val && val !== oldVal) {
// get list
this.page = 1;
this.size = 20;
this.size = 100;
this.getList();
}
},
@@ -141,7 +141,7 @@ export default {
topBtnConfig: null,
totalPage: 100,
page: 1,
size: 20, // 默认20
size: 100, // 默认100
dataList: [],
tableLoading: false,
refreshLayoutKey: null,
@@ -255,7 +255,7 @@ export default {
if (res.code === 0) {
this.$message.success("删除成功!");
this.page = 1;
this.size = 10;
this.size = 100;
this.getList();
} else {
this.$message({

View File

@@ -6,7 +6,7 @@ import { getDictDataList } from '@/utils'
export default function () {
const tableProps = [
{ type: 'index', label: '序号' },
// { type: 'index', label: '序号' },
// { prop: "createTime", label: "添加时间", filter: timeFilter },
{ prop: "code", label: "窑车号" },
{ prop: "stateDictValue", label: "状态", subcomponent: StateSelect },

View File

@@ -12,7 +12,7 @@ export default function () {
{ prop: "specifications", label: "规格" },
{ prop: "unitDictValue", label: "单位", filter: dictFilter("unit") },
{ prop: "weight", label: "重量", filter: (val) => (val ? val + " kg" : "-") },
{ prop: "processTime", label: "产线完成单位产品用时", width: 200, filter: (val) => val + " s" },
{ prop: "processTime", label: "产线完成单位产品用时", width: 200, filter: (val) => val + " (分钟)" },
{ prop: "remark", label: "备注" },
{
prop: "description",