| | |
| | | };
|
| | | },
|
| | | created() {
|
| | | const tableId = this.$route.params && this.$route.params.tableId;
|
| | | const tableId = this.$route.query && this.$route.query.tableId;
|
| | | if (tableId) {
|
| | | // 获取表详细信息
|
| | | getGenTable(tableId).then(res => {
|
| | |
| | | parentMenuId: genTable.parentMenuId
|
| | | };
|
| | | updateGenTable(genTable).then(res => {
|
| | | this.msgSuccess(res.msg);
|
| | | this.$modal.msgSuccess(res.msg);
|
| | | if (res.code === 200) {
|
| | | this.close();
|
| | | }
|
| | | });
|
| | | } else {
|
| | | this.msgError("表单校验未通过,请重新检查提交内容");
|
| | | this.$modal.msgError("表单校验未通过,请重新检查提交内容");
|
| | | }
|
| | | });
|
| | | },
|
| | |
| | | /** 关闭按钮 */
|
| | | close() {
|
| | | this.$store.dispatch("tagsView/delView", this.$route);
|
| | | this.$router.push({ path: "/tool/gen", query: { t: Date.now()}})
|
| | | this.$router.push({ path: "/tool/gen", query: { t: Date.now(), pageNum: this.$route.query.pageNum } })
|
| | | }
|
| | | },
|
| | | mounted() {
|