bugfix 解决一部分0703反馈bug
This commit is contained in:
parent
f4be2d1efe
commit
9c3133aa29
@ -39,8 +39,9 @@
|
|||||||
<script>
|
<script>
|
||||||
// window.SITE_CONFIG['apiURL'] = 'http://192.168.1.103:8080/pms-am';
|
// window.SITE_CONFIG['apiURL'] = 'http://192.168.1.103:8080/pms-am';
|
||||||
// window.SITE_CONFIG['apiURL'] = 'http://192.168.1.49:8080/pms-am'; // tengyun
|
// window.SITE_CONFIG['apiURL'] = 'http://192.168.1.49:8080/pms-am'; // tengyun
|
||||||
|
window.SITE_CONFIG['apiURL'] = 'http://192.168.1.67:8080/pms-am'; // wenzhang
|
||||||
// window.SITE_CONFIG['apiURL'] = 'http://192.168.1.62:8080/pms-am'; // tao
|
// window.SITE_CONFIG['apiURL'] = 'http://192.168.1.62:8080/pms-am'; // tao
|
||||||
window.SITE_CONFIG['apiURL'] = 'http://192.168.1.21:8080/pms-am'; // xv
|
// window.SITE_CONFIG['apiURL'] = 'http://192.168.1.21:8080/pms-am'; // xv
|
||||||
// window.SITE_CONFIG['apiURL'] = 'http://localhost:3000/p//////ms-am'; // xv
|
// window.SITE_CONFIG['apiURL'] = 'http://localhost:3000/p//////ms-am'; // xv
|
||||||
</script>
|
</script>
|
||||||
<% } %>
|
<% } %>
|
||||||
|
@ -8,20 +8,40 @@
|
|||||||
:key="opt.prop"
|
:key="opt.prop"
|
||||||
:label="opt.label ? opt.label : null"
|
:label="opt.label ? opt.label : null"
|
||||||
:prop="opt.prop ?? '' + index"
|
:prop="opt.prop ?? '' + index"
|
||||||
:rules="opt.bind?.rules ? opt.bind.rules : undefined"
|
:rules="opt.bind?.rules ? opt.bind.rules : undefined">
|
||||||
>
|
<el-input
|
||||||
<el-input v-if="opt.input" v-model="dataForm[opt.prop]" v-bind="opt.bind" clearable size="small" />
|
v-if="opt.input"
|
||||||
<el-select v-if="opt.select" v-model="dataForm[opt.prop]" v-bind="opt.bind" clearable size="small">
|
v-model="dataForm[opt.prop]"
|
||||||
<el-option v-for="item in opt.select" :key="item.value + Math.random().toString()" :label="item.label" :value="item.value" />
|
v-bind="opt.bind"
|
||||||
|
clearable
|
||||||
|
size="small"
|
||||||
|
@keydown.enter.native.prevent="handleBtnClick('查询')" />
|
||||||
|
<el-select
|
||||||
|
v-if="opt.select"
|
||||||
|
v-model="dataForm[opt.prop]"
|
||||||
|
v-bind="opt.bind"
|
||||||
|
clearable
|
||||||
|
size="small"
|
||||||
|
@keydown.enter.native.prevent="handleBtnClick('查询')">
|
||||||
|
<el-option
|
||||||
|
v-for="item in opt.select"
|
||||||
|
:key="item.value + Math.random().toString()"
|
||||||
|
:label="item.label"
|
||||||
|
:value="item.value" />
|
||||||
</el-select>
|
</el-select>
|
||||||
<el-date-picker v-if="opt.timerange" v-model="dataForm[opt.prop]" v-bind="opt.bind" clearable size="small" />
|
<el-date-picker
|
||||||
|
v-if="opt.timerange"
|
||||||
|
v-model="dataForm[opt.prop]"
|
||||||
|
v-bind="opt.bind"
|
||||||
|
clearable
|
||||||
|
size="small"
|
||||||
|
@keydown.enter.native.prevent="handleBtnClick('查询')" />
|
||||||
<el-upload
|
<el-upload
|
||||||
v-if="opt.upload"
|
v-if="opt.upload"
|
||||||
size="small"
|
size="small"
|
||||||
:key="'upload_' + Math.random().toString()"
|
:key="'upload_' + Math.random().toString()"
|
||||||
class="inline-block pl-3"
|
class="inline-block pl-3"
|
||||||
action="https://jsonplaceholder.typicode.com/posts/"
|
action="https://jsonplaceholder.typicode.com/posts/">
|
||||||
>
|
|
||||||
<el-button type="primary">上传文件</el-button>
|
<el-button type="primary">上传文件</el-button>
|
||||||
</el-upload>
|
</el-upload>
|
||||||
<el-button
|
<el-button
|
||||||
@ -30,9 +50,9 @@
|
|||||||
size="small"
|
size="small"
|
||||||
:type="opt.button.type"
|
:type="opt.button.type"
|
||||||
v-bind="opt.bind"
|
v-bind="opt.bind"
|
||||||
@click="handleBtnClick(opt.button.name)"
|
@click="handleBtnClick(opt.button.name)">
|
||||||
>{{ opt.button.name }}</el-button
|
{{ opt.button.name }}
|
||||||
>
|
</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
</el-row>
|
</el-row>
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
:visible="dialogVisible"
|
:visible="dialogVisible"
|
||||||
:destroy-on-close="false"
|
:destroy-on-close="false"
|
||||||
@close="handleClose"
|
@close="handleClose"
|
||||||
:close-on-click-modal="configs.clickModalToClose ?? true">
|
:close-on-click-modal="configs.clickModalToClose ?? false">
|
||||||
<!-- title -->
|
<!-- title -->
|
||||||
<div slot="title" class="dialog-title">
|
<div slot="title" class="dialog-title">
|
||||||
<h1 class="">
|
<h1 class="">
|
||||||
@ -497,16 +497,18 @@ export default {
|
|||||||
setTimeout(
|
setTimeout(
|
||||||
() => {
|
() => {
|
||||||
Object.keys(this.dataForm).forEach((key) => {
|
Object.keys(this.dataForm).forEach((key) => {
|
||||||
|
console.log('reset form, key', key)
|
||||||
if (excludeId && key === "id") return;
|
if (excludeId && key === "id") return;
|
||||||
if ("files" in this.dataForm) this.dataForm.files = [];
|
if ("files" in this.dataForm) this.dataForm.files = [];
|
||||||
if ("fileIds" in this.dataForm) this.dataForm.fileIds = [];
|
else if ("fileIds" in this.dataForm) this.dataForm.fileIds = [];
|
||||||
else this.dataForm[key] = null;
|
else this.$set(this.dataForm, key, null)
|
||||||
if (Array.isArray(this.fileList)) {
|
if (Array.isArray(this.fileList)) {
|
||||||
this.fileList = [];
|
this.fileList = [];
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
this.activeMenu = this.configs.menu[0].name;
|
this.activeMenu = this.configs.menu[0].name;
|
||||||
this.$refs.dataForm[0].clearValidate();
|
this.$refs.dataForm[0].resetFields();
|
||||||
|
console.log("清除Form...", this.dataForm);
|
||||||
},
|
},
|
||||||
immediate ? 0 : 200
|
immediate ? 0 : 200
|
||||||
);
|
);
|
||||||
|
@ -103,18 +103,20 @@ export default {
|
|||||||
this.$refs.addOrUpdate.init(val.data.id);
|
this.$refs.addOrUpdate.init(val.data.id);
|
||||||
});
|
});
|
||||||
} else if (val.type === "delete") {
|
} else if (val.type === "delete") {
|
||||||
|
console.log('va', val)
|
||||||
this.deleteHandle(val.data.id, val.data.name)
|
this.deleteHandle(val.data.id, val.data.name)
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
// 删除
|
// 删除
|
||||||
deleteHandle(id, name) {
|
deleteHandle(id, name) {
|
||||||
this.$confirm(`确定对[名称=${name}]进行删除操作?`, "提示", {
|
this.$confirm(`确定对删除 ${name}?`, "提示", {
|
||||||
confirmButtonText: "确定",
|
confirmButtonText: "确定",
|
||||||
cancelButtonText: "取消",
|
cancelButtonText: "取消",
|
||||||
type: "warning",
|
type: "warning",
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
this.$http.delete(this.urlOptions.deleteURL, { data: [id] }).then(({ data }) => {
|
// this.$http.delete(this.urlOptions.deleteURL, { data: [id] }).then(({ data }) => {
|
||||||
|
this.$http.delete(this.urlOptions.deleteURL + `/${id}`).then(({ data }) => {
|
||||||
if (data && data.code === 0) {
|
if (data && data.code === 0) {
|
||||||
this.$message({
|
this.$message({
|
||||||
message: "操作成功",
|
message: "操作成功",
|
||||||
|
@ -74,7 +74,7 @@ export function addDynamicRoute(routeParams, router) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const router = new Router({
|
const router = new Router({
|
||||||
mode: 'history',
|
mode: 'hash',
|
||||||
scrollBehavior: () => ({ y: 0 }),
|
scrollBehavior: () => ({ y: 0 }),
|
||||||
routes: pageRoutes.concat(moduleRoutes)
|
routes: pageRoutes.concat(moduleRoutes)
|
||||||
})
|
})
|
||||||
|
@ -274,7 +274,6 @@ export default {
|
|||||||
}).then(({ data: res }) => {
|
}).then(({ data: res }) => {
|
||||||
if (res.code === 0) {
|
if (res.code === 0) {
|
||||||
this.$message.success("删除成功!");
|
this.$message.success("删除成功!");
|
||||||
|
|
||||||
this.page = 1;
|
this.page = 1;
|
||||||
this.size =
|
this.size =
|
||||||
"defaultPageSize" in this.tableConfig.column ? this.tableConfig.column.defaultPageSize : 20;
|
"defaultPageSize" in this.tableConfig.column ? this.tableConfig.column.defaultPageSize : 20;
|
||||||
|
@ -6,26 +6,45 @@
|
|||||||
|
|
||||||
<div class="actual-form">
|
<div class="actual-form">
|
||||||
<el-form :inline="true" :model="dataForm" :rules="headConfig.rules">
|
<el-form :inline="true" :model="dataForm" :rules="headConfig.rules">
|
||||||
<!-- <el-col :span="opt.span ? +opt.span : 4" v-for="opt in options" :key="opt.id"> -->
|
|
||||||
<el-form-item
|
<el-form-item
|
||||||
v-for="(opt, index) in headConfig.fields"
|
v-for="(opt, index) in headConfig.fields"
|
||||||
:key="opt.prop"
|
:key="opt.prop"
|
||||||
:label="opt.label ? opt.label : null"
|
:label="opt.label ? opt.label : null"
|
||||||
:prop="opt.prop ?? '' + index"
|
:prop="opt.prop ?? '' + index"
|
||||||
:rules="opt.bind?.rules ? opt.bind.rules : undefined"
|
:rules="opt.bind?.rules ? opt.bind.rules : undefined">
|
||||||
>
|
<el-input
|
||||||
<el-input v-if="opt.input" v-model="dataForm[opt.prop]" v-bind="opt.bind" clearable size="small" />
|
v-if="opt.input"
|
||||||
<el-select v-if="opt.select" v-model="dataForm[opt.prop]" v-bind="opt.bind" clearable size="small">
|
v-model="dataForm[opt.prop]"
|
||||||
<el-option v-for="item in opt.select" :key="item.value + Math.random().toString()" :label="item.label" :value="item.value" />
|
v-bind="opt.bind"
|
||||||
|
clearable
|
||||||
|
size="small"
|
||||||
|
@keydown.enter.native.prevent="handleBtnClick('查询')" />
|
||||||
|
<el-select
|
||||||
|
v-if="opt.select"
|
||||||
|
v-model="dataForm[opt.prop]"
|
||||||
|
v-bind="opt.bind"
|
||||||
|
clearable
|
||||||
|
size="small"
|
||||||
|
@keydown.enter.native.prevent="handleBtnClick('查询')">
|
||||||
|
<el-option
|
||||||
|
v-for="item in opt.select"
|
||||||
|
:key="item.value + Math.random().toString()"
|
||||||
|
:label="item.label"
|
||||||
|
:value="item.value" />
|
||||||
</el-select>
|
</el-select>
|
||||||
<el-date-picker v-if="opt.timerange" v-model="dataForm[opt.prop]" v-bind="opt.bind" clearable size="small" />
|
<el-date-picker
|
||||||
|
v-if="opt.timerange"
|
||||||
|
v-model="dataForm[opt.prop]"
|
||||||
|
v-bind="opt.bind"
|
||||||
|
clearable
|
||||||
|
size="small"
|
||||||
|
@keydown.enter.native.prevent="handleBtnClick('查询')" />
|
||||||
<el-upload
|
<el-upload
|
||||||
v-if="opt.upload"
|
v-if="opt.upload"
|
||||||
size="small"
|
size="small"
|
||||||
:key="'upload_' + Math.random().toString()"
|
:key="'upload_' + Math.random().toString()"
|
||||||
class="inline-block pl-3"
|
class="inline-block pl-3"
|
||||||
action="https://jsonplaceholder.typicode.com/posts/"
|
action="https://jsonplaceholder.typicode.com/posts/">
|
||||||
>
|
|
||||||
<el-button type="primary">上传文件</el-button>
|
<el-button type="primary">上传文件</el-button>
|
||||||
</el-upload>
|
</el-upload>
|
||||||
<el-button
|
<el-button
|
||||||
@ -34,9 +53,9 @@
|
|||||||
size="small"
|
size="small"
|
||||||
:type="opt.button.type"
|
:type="opt.button.type"
|
||||||
v-bind="opt.bind"
|
v-bind="opt.bind"
|
||||||
@click="handleBtnClick(opt.button.name)"
|
@click="handleBtnClick(opt.button.name)">
|
||||||
>{{ opt.button.name }}</el-button
|
{{ opt.button.name }}
|
||||||
>
|
</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
</div>
|
</div>
|
||||||
@ -61,21 +80,7 @@ export default {
|
|||||||
dataForm: {},
|
dataForm: {},
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
|
|
||||||
// 这个 watch 出现得没啥必要......
|
|
||||||
// watch: {
|
|
||||||
// dataForm: {
|
|
||||||
// handler: (val) => {
|
|
||||||
// console.log("[BaseSearchForm::watcher::dataForm]", val);
|
|
||||||
// },
|
|
||||||
// deep: true,
|
|
||||||
// },
|
|
||||||
// },
|
|
||||||
|
|
||||||
created() {},
|
|
||||||
mounted() {
|
mounted() {
|
||||||
// console.log("[BaseSearchForm] configs:", JSON.parse(JSON.stringify(this.headConfig)));
|
|
||||||
|
|
||||||
this.headConfig.fields.forEach((field, index) => {
|
this.headConfig.fields.forEach((field, index) => {
|
||||||
// 没有 field.prop ,则为按钮之类的
|
// 没有 field.prop ,则为按钮之类的
|
||||||
if (!field.prop) return;
|
if (!field.prop) return;
|
||||||
|
@ -410,7 +410,7 @@ export default {
|
|||||||
if (res.code === 0) {
|
if (res.code === 0) {
|
||||||
this.$message.success(method === "POST" ? "添加成功" : "更新成功");
|
this.$message.success(method === "POST" ? "添加成功" : "更新成功");
|
||||||
this.$emit("refreshDataList");
|
this.$emit("refreshDataList");
|
||||||
if (method === "POST") this.handleClose();
|
this.handleClose();
|
||||||
} else {
|
} else {
|
||||||
this.$message({
|
this.$message({
|
||||||
message: `${res.code}: ${res.msg}`,
|
message: `${res.code}: ${res.msg}`,
|
||||||
|
@ -35,7 +35,8 @@
|
|||||||
v-if="renderDialog"
|
v-if="renderDialog"
|
||||||
fullscreen
|
fullscreen
|
||||||
:configs="dialogConfig"
|
:configs="dialogConfig"
|
||||||
@destroy-dialog="renderDialog = false" />
|
@destroy-dialog="renderDialog = false"
|
||||||
|
@refreshDataList="getAList(Object.assign({}, listQuery, extraSearchConditions, params));" />
|
||||||
|
|
||||||
<DialogWithMenu
|
<DialogWithMenu
|
||||||
modal-append-to-body
|
modal-append-to-body
|
||||||
@ -43,7 +44,8 @@
|
|||||||
v-if="renderMenuDialog"
|
v-if="renderMenuDialog"
|
||||||
fullscreen
|
fullscreen
|
||||||
:configs="dialogConfig"
|
:configs="dialogConfig"
|
||||||
@destroy-dialog="renderMenuDialog = false" />
|
@destroy-dialog="renderMenuDialog = false"
|
||||||
|
@refreshDataList="getAList(Object.assign({}, listQuery, extraSearchConditions, params));" />
|
||||||
|
|
||||||
<DialogUpload
|
<DialogUpload
|
||||||
ref="uploadDialog"
|
ref="uploadDialog"
|
||||||
|
@ -1,13 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="main-container">
|
<div class="main-container">
|
||||||
<!-- <div class="inner-sidebar">
|
|
||||||
<a href="#ongoing" :class="{ active: activeTable === '#ongoing' }" @click.prevent="scrollTo('#ongoing')">进行中的订单</a>
|
|
||||||
<a href="#pending" :class="{ active: activeTable === '#pending' }" @click.prevent="scrollTo('#pending')">等待订单</a>
|
|
||||||
<a href="#finished" :class="{ active: activeTable === '#finished' }" @click.prevent="scrollTo('#finished')">完成订单</a>
|
|
||||||
</div> -->
|
|
||||||
|
|
||||||
<div class="list-view-with-head-list">
|
<div class="list-view-with-head-list">
|
||||||
<!-- <ListViewWithHead :table-configs="tableConfigs" :head-configs="headFormConfigs" :dialog-configs="dialogConfigs" /> -->
|
|
||||||
<ListSectionWithHead
|
<ListSectionWithHead
|
||||||
id="ongoing"
|
id="ongoing"
|
||||||
:refresh-key="keys.ongoing"
|
:refresh-key="keys.ongoing"
|
||||||
@ -40,29 +33,15 @@
|
|||||||
/> -->
|
/> -->
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!-- <div style="padding: 16px; background: #fff; border-radius: 8px">
|
|
||||||
<el-table :data="dataList">
|
|
||||||
<el-table-column key="id" prop="id" label="ID"></el-table-column>
|
|
||||||
<el-table-column key="name" prop="name" label="名字"></el-table-column>
|
|
||||||
<el-table-column key="age" prop="age" label="年龄"></el-table-column>
|
|
||||||
<el-table-column key="opt" label="操作">
|
|
||||||
<template slot-scope="scope">
|
|
||||||
<el-button @click.native.prevent="handleUp(scope)">up</el-button>
|
|
||||||
<el-button @click.native.prevent="handleDown(scope)">down</el-button>
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
</el-table>
|
|
||||||
</div> -->
|
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import initConfig from "./config";
|
import initConfig from "./config";
|
||||||
import ListViewWithHead from "./components/ListViewWithHead.vue";
|
// import ListViewWithHead from "./components/ListViewWithHead.vue";
|
||||||
import ListSectionWithHead from "./components/ListSectionWithHead.vue";
|
import ListSectionWithHead from "./components/ListSectionWithHead.vue";
|
||||||
export default {
|
export default {
|
||||||
name: "OrderView",
|
name: "OrderView",
|
||||||
components: { ListViewWithHead, ListSectionWithHead },
|
components: { ListSectionWithHead },
|
||||||
provide() {
|
provide() {
|
||||||
return {
|
return {
|
||||||
urls: this.allUrls,
|
urls: this.allUrls,
|
||||||
@ -82,16 +61,6 @@ export default {
|
|||||||
finished: Math.random().toString(),
|
finished: Math.random().toString(),
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
// return {
|
|
||||||
// dataList: [
|
|
||||||
// { id: 1, name: "张三", age: 12 },
|
|
||||||
// { id: 2, name: "李四", age: 13 },
|
|
||||||
// { id: 3, name: "王五", age: 14 },
|
|
||||||
// { id: 4, name: "陈鼻", age: 15 },
|
|
||||||
// { id: 5, name: "肖上唇", age: 16 },
|
|
||||||
// ],
|
|
||||||
// limit: 20
|
|
||||||
// };
|
|
||||||
},
|
},
|
||||||
created() {},
|
created() {},
|
||||||
mounted() {},
|
mounted() {},
|
||||||
@ -110,22 +79,7 @@ export default {
|
|||||||
behavior: 'smooth'
|
behavior: 'smooth'
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
// handleUp({ $index, row }) {
|
|
||||||
// console.log("row: ", $index, row);
|
|
||||||
// if ($index === 0) return;
|
|
||||||
// const [item] = this.dataList.splice($index, 1);
|
|
||||||
// console.log("item: ", item);
|
|
||||||
// this.dataList.splice($index - 1, 0, item);
|
|
||||||
// console.log("dataList: ", this.dataList);
|
|
||||||
// // this.dataList
|
|
||||||
// },
|
|
||||||
// handleDown({ $index, row }) {
|
|
||||||
// // const { id } = row;
|
|
||||||
// if ($index === this.limit) return;
|
|
||||||
// const [item] = this.dataList.splice($index, 1);
|
|
||||||
// this.dataList.splice($index + 1, 0, item);
|
|
||||||
// },
|
|
||||||
//
|
|
||||||
handleRefreshTable(tableNameList) {
|
handleRefreshTable(tableNameList) {
|
||||||
if (Array.isArray(tableNameList)) {
|
if (Array.isArray(tableNameList)) {
|
||||||
tableNameList.forEach(name => {
|
tableNameList.forEach(name => {
|
||||||
|
@ -186,11 +186,13 @@ export default {
|
|||||||
if (res.code !== 0) {
|
if (res.code !== 0) {
|
||||||
return this.$message.error(res.msg)
|
return this.$message.error(res.msg)
|
||||||
}
|
}
|
||||||
|
console.log('========= HERE ===========')
|
||||||
this.$message({
|
this.$message({
|
||||||
message: this.$t('prompt.success'),
|
message: this.$t('prompt.success'),
|
||||||
type: 'success',
|
type: 'success',
|
||||||
duration: 500,
|
duration: 500,
|
||||||
onClose: () => {
|
onClose: () => {
|
||||||
|
console.log('========= THERE ===========')
|
||||||
this.visible = false
|
this.visible = false
|
||||||
this.$emit('refreshDataList')
|
this.$emit('refreshDataList')
|
||||||
}
|
}
|
||||||
|
@ -2,35 +2,33 @@
|
|||||||
<el-card shadow="never" class="aui-card--fill">
|
<el-card shadow="never" class="aui-card--fill">
|
||||||
<div class="mod-sys__user">
|
<div class="mod-sys__user">
|
||||||
<search-bar :formConfigs="formConfig" ref="searchBarForm" @headBtnClick="buttonClick" />
|
<search-bar :formConfigs="formConfig" ref="searchBarForm" @headBtnClick="buttonClick" />
|
||||||
<base-table
|
<base-table :table-props="tableProps" :page="listQuery.page" :limit="listQuery.limit" :table-data="tableData">
|
||||||
:table-props="tableProps"
|
|
||||||
:page="listQuery.page"
|
|
||||||
:limit="listQuery.limit"
|
|
||||||
:table-data="tableData"
|
|
||||||
>
|
|
||||||
<method-btn
|
<method-btn
|
||||||
v-if="tableBtn.length"
|
v-if="tableBtn.length"
|
||||||
slot="handleBtn"
|
slot="handleBtn"
|
||||||
:width="100"
|
:width="100"
|
||||||
label="操作"
|
label="操作"
|
||||||
:method-list="tableBtn"
|
:method-list="tableBtn"
|
||||||
@clickBtn="handleClick"
|
@clickBtn="(payload) => handleClick({
|
||||||
/>
|
type: payload.type,
|
||||||
|
data: {
|
||||||
|
...payload.data,
|
||||||
|
name: payload.data.username
|
||||||
|
}
|
||||||
|
})" />
|
||||||
</base-table>
|
</base-table>
|
||||||
<pagination
|
<pagination
|
||||||
:limit.sync="listQuery.limit"
|
:limit.sync="listQuery.limit"
|
||||||
:page.sync="listQuery.page"
|
:page.sync="listQuery.page"
|
||||||
:total="listQuery.total"
|
:total="listQuery.total"
|
||||||
@pagination="getDataList"
|
@pagination="getDataList" />
|
||||||
/>
|
|
||||||
<!-- 弹窗, 新增 / 修改 -->
|
<!-- 弹窗, 新增 / 修改 -->
|
||||||
<base-dialog
|
<base-dialog
|
||||||
:dialogTitle="addOrEditTitle"
|
:dialogTitle="addOrEditTitle"
|
||||||
:dialogVisible="addOrUpdateVisible"
|
:dialogVisible="addOrUpdateVisible"
|
||||||
@cancel="handleCancel"
|
@cancel="handleCancel"
|
||||||
@confirm="handleConfirm"
|
@confirm="handleConfirm"
|
||||||
:before-close="handleCancel"
|
:before-close="handleCancel">
|
||||||
>
|
|
||||||
<add-or-update ref="addOrUpdate" @successSubmit="successSubmit"></add-or-update>
|
<add-or-update ref="addOrUpdate" @successSubmit="successSubmit"></add-or-update>
|
||||||
</base-dialog>
|
</base-dialog>
|
||||||
</div>
|
</div>
|
||||||
@ -41,7 +39,7 @@
|
|||||||
import basicPage from "@/mixins/basic-page";
|
import basicPage from "@/mixins/basic-page";
|
||||||
import AddOrUpdate from "./user-add-or-update";
|
import AddOrUpdate from "./user-add-or-update";
|
||||||
import i18n from "@/i18n";
|
import i18n from "@/i18n";
|
||||||
import sysFilter from '@/filters/sys-filter'
|
import sysFilter from "@/filters/sys-filter";
|
||||||
const tableProps = [
|
const tableProps = [
|
||||||
{
|
{
|
||||||
prop: "username",
|
prop: "username",
|
||||||
@ -62,12 +60,12 @@ const tableProps = [
|
|||||||
{
|
{
|
||||||
prop: "gender",
|
prop: "gender",
|
||||||
label: i18n.t("user.gender"),
|
label: i18n.t("user.gender"),
|
||||||
filter: sysFilter('sex'),
|
filter: sysFilter("sex"),
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
prop: "status",
|
prop: "status",
|
||||||
label: i18n.t("user.status"),
|
label: i18n.t("user.status"),
|
||||||
filter: sysFilter('userStatus'),
|
filter: sysFilter("userStatus"),
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
prop: "createDate",
|
prop: "createDate",
|
||||||
@ -131,14 +129,14 @@ export default {
|
|||||||
this.getDataList();
|
this.getDataList();
|
||||||
break;
|
break;
|
||||||
case "add":
|
case "add":
|
||||||
this.addOrEditTitle = '新增'
|
this.addOrEditTitle = "新增";
|
||||||
this.addOrUpdateVisible = true;
|
this.addOrUpdateVisible = true;
|
||||||
this.addOrUpdateHandle()
|
this.addOrUpdateHandle();
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
console.log(val)
|
console.log(val);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
}
|
},
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
Loading…
Reference in New Issue
Block a user