Merge branch 'master' of https://gitee.com/y_project/RuoYi-Vue into dev
Conflicts:
ruoyi-generator/src/main/resources/vm/vue/index-tree.vue.vm
ruoyi-generator/src/main/resources/vm/vue/index.vue.vm
ruoyi-ui/src/layout/components/Settings/index.vue
ruoyi-ui/src/main.js
ruoyi-ui/src/views/monitor/job/index.vue
ruoyi-ui/src/views/monitor/job/log.vue
ruoyi-ui/src/views/monitor/logininfor/index.vue
ruoyi-ui/src/views/monitor/online/index.vue
ruoyi-ui/src/views/monitor/operlog/index.vue
ruoyi-ui/src/views/monitor/server/index.vue
ruoyi-ui/src/views/system/config/index.vue
ruoyi-ui/src/views/system/dict/data.vue
ruoyi-ui/src/views/system/dict/index.vue
ruoyi-ui/src/views/system/post/index.vue
ruoyi-ui/src/views/system/role/index.vue
ruoyi-ui/src/views/system/user/authRole.vue
ruoyi-ui/src/views/system/user/index.vue
ruoyi-ui/src/views/system/user/profile/resetPwd.vue
ruoyi-ui/src/views/system/user/profile/userAvatar.vue
ruoyi-ui/src/views/system/user/profile/userInfo.vue
ruoyi-ui/src/views/tool/gen/importTable.vue
| | |
| | | #end |
| | | if (this.form.${pkColumn.javaField} != null) { |
| | | update${BusinessName}(this.form).then(response => { |
| | | this.msgSuccess("ä¿®æ¹æå"); |
| | | this.#[[$modal]]#.msgSuccess("ä¿®æ¹æå"); |
| | | this.open = false; |
| | | this.getList(); |
| | | }).finally(() => { |
| | |
| | | }); |
| | | } else { |
| | | add${BusinessName}(this.form).then(response => { |
| | | this.msgSuccess("æ°å¢æå"); |
| | | this.#[[$modal]]#.msgSuccess("æ°å¢æå"); |
| | | this.open = false; |
| | | this.getList(); |
| | | }).finally(() => { |
| | |
| | | }, |
| | | /** å é¤æé®æä½ */ |
| | | handleDelete(row) { |
| | | this.$confirm('æ¯å¦ç¡®è®¤å é¤${functionName}ç¼å·ä¸º"' + row.${pkColumn.javaField} + '"çæ°æ®é¡¹?', "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(() => { |
| | | this.loading = true; |
| | | return del${BusinessName}(row.${pkColumn.javaField}); |
| | | }).then(() => { |
| | | this.loading = false; |
| | | this.getList(); |
| | | this.msgSuccess("å 餿å"); |
| | | this.#[[$modal]]#.confirm('æ¯å¦ç¡®è®¤å é¤${functionName}ç¼å·ä¸º"' + row.${pkColumn.javaField} + '"çæ°æ®é¡¹ï¼').then(() => { |
| | | this.loading = true; |
| | | return del${BusinessName}(row.${pkColumn.javaField}); |
| | | }).then(() => { |
| | | this.loading = false; |
| | | this.getList(); |
| | | this.#[[$modal]]#.msgSuccess("å 餿å"); |
| | | }).finally(() => { |
| | | this.loading = false; |
| | | this.loading = false; |
| | | }); |
| | | } |
| | | } |
| | |
| | | #end |
| | | if (this.form.${pkColumn.javaField} != null) { |
| | | update${BusinessName}(this.form).then(response => { |
| | | this.msgSuccess("ä¿®æ¹æå"); |
| | | this.#[[$modal]]#.msgSuccess("ä¿®æ¹æå"); |
| | | this.open = false; |
| | | this.getList(); |
| | | }).finally(() => { |
| | |
| | | }); |
| | | } else { |
| | | add${BusinessName}(this.form).then(response => { |
| | | this.msgSuccess("æ°å¢æå"); |
| | | this.#[[$modal]]#.msgSuccess("æ°å¢æå"); |
| | | this.open = false; |
| | | this.getList(); |
| | | }).finally(() => { |
| | |
| | | /** å é¤æé®æä½ */ |
| | | handleDelete(row) { |
| | | const ${pkColumn.javaField}s = row.${pkColumn.javaField} || this.ids; |
| | | this.$confirm('æ¯å¦ç¡®è®¤å é¤${functionName}ç¼å·ä¸º"' + ${pkColumn.javaField}s + '"çæ°æ®é¡¹?', "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(() => { |
| | | this.loading = true; |
| | | return del${BusinessName}(${pkColumn.javaField}s); |
| | | }).then(() => { |
| | | this.loading = false; |
| | | this.getList(); |
| | | this.msgSuccess("å 餿å"); |
| | | this.#[[$modal]]#.confirm('æ¯å¦ç¡®è®¤å é¤${functionName}ç¼å·ä¸º"' + ${pkColumn.javaField}s + '"çæ°æ®é¡¹ï¼').then(() => { |
| | | this.loading = true; |
| | | return del${BusinessName}(${pkColumn.javaField}s); |
| | | }).then(() => { |
| | | this.loading = false; |
| | | this.getList(); |
| | | this.#[[$modal]]#.msgSuccess("å 餿å"); |
| | | }).finally(() => { |
| | | this.loading = false; |
| | | this.loading = false; |
| | | }); |
| | | }, |
| | | #if($table.sub) |
| | |
| | | <el-divider/> |
| | | |
| | | <h3 class="drawer-title">ç³»ç»å¸å±é
ç½®</h3> |
| | | |
| | | |
| | | <div class="drawer-item"> |
| | | <span>å¼å¯ TopNav</span> |
| | | <el-switch v-model="topNav" class="drawer-switch" /> |
| | |
| | | this.sideTheme = val; |
| | | }, |
| | | saveSetting() { |
| | | const loading = this.$loading({ |
| | | lock: true, |
| | | fullscreen: false, |
| | | text: "æ£å¨ä¿åå°æ¬å°ï¼è¯·ç¨å...", |
| | | spinner: "el-icon-loading", |
| | | background: "rgba(0, 0, 0, 0.7)" |
| | | }); |
| | | localStorage.setItem( |
| | | this.$modal.loading("æ£å¨ä¿åå°æ¬å°ï¼è¯·ç¨å..."); |
| | | this.$cache.local.set( |
| | | "layout-setting", |
| | | `{ |
| | | "topNav":${this.topNav}, |
| | |
| | | "theme":"${this.theme}" |
| | | }` |
| | | ); |
| | | setTimeout(loading.close(), 1000) |
| | | setTimeout(this.$modal.closeLoading(), 1000) |
| | | }, |
| | | resetSetting() { |
| | | this.$loading({ |
| | | lock: true, |
| | | fullscreen: false, |
| | | text: "æ£å¨æ¸
é¤è®¾ç½®ç¼åå¹¶å·æ°ï¼è¯·ç¨å...", |
| | | spinner: "el-icon-loading", |
| | | background: "rgba(0, 0, 0, 0.7)" |
| | | }); |
| | | localStorage.removeItem("layout-setting") |
| | | this.$modal.loading("æ£å¨æ¸
é¤è®¾ç½®ç¼åå¹¶å·æ°ï¼è¯·ç¨å..."); |
| | | this.$cache.local.remove("layout-setting") |
| | | setTimeout("window.location.reload()", 1000) |
| | | } |
| | | } |
| | |
| | | import store from './store' |
| | | import router from './router' |
| | | import directive from './directive' //directive |
| | | import plugins from './plugins' // plugins |
| | | |
| | | import './assets/icons' // icon |
| | | import './permission' // permission control |
| | |
| | | import { getConfigKey } from "@/api/system/config"; |
| | | import { downLoadExcel } from "@/utils/download"; |
| | | import { parseTime, resetForm, addDateRange, selectDictLabel, selectDictLabels, handleTree } from "@/utils/ruoyi"; |
| | | // å页ç»ä»¶ |
| | | import Pagination from "@/components/Pagination"; |
| | | // èªå®ä¹è¡¨æ ¼å·¥å
·ç»ä»¶ |
| | | import RightToolbar from "@/components/RightToolbar" |
| | |
| | | Vue.prototype.addDateRange = addDateRange |
| | | Vue.prototype.selectDictLabel = selectDictLabel |
| | | Vue.prototype.selectDictLabels = selectDictLabels |
| | | Vue.prototype.handleTree = handleTree |
| | | Vue.prototype.downLoadExcel = downLoadExcel |
| | | |
| | | Vue.prototype.msgSuccess = function (msg) { |
| | | this.$message({ showClose: true, message: msg, type: "success" }); |
| | | } |
| | | |
| | | Vue.prototype.msgError = function (msg) { |
| | | this.$message({ showClose: true, message: msg, type: "error" }); |
| | | } |
| | | |
| | | Vue.prototype.msgInfo = function (msg) { |
| | | this.$message.info(msg); |
| | | } |
| | | Vue.prototype.handleTree = handleTree |
| | | |
| | | // å
¨å±ç»ä»¶æè½½ |
| | | Vue.component('DictTag', DictTag) |
| | |
| | | Vue.component('ImageUpload', ImageUpload) |
| | | |
| | | Vue.use(directive) |
| | | Vue.use(plugins) |
| | | Vue.use(VueMeta) |
| | | DictData.install() |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | const sessionCache = {
|
| | | set (key, value) {
|
| | | if (!sessionStorage) {
|
| | | return
|
| | | }
|
| | | if (key != null && value != null) {
|
| | | sessionStorage.setItem(key, value)
|
| | | }
|
| | | },
|
| | | get (key) {
|
| | | if (!sessionStorage) {
|
| | | return null
|
| | | }
|
| | | if (key == null) {
|
| | | return null
|
| | | }
|
| | | return sessionStorage.getItem(key)
|
| | | },
|
| | | setJSON (key, jsonValue) {
|
| | | if (jsonValue != null) {
|
| | | this.set(key, JSON.stringify(jsonValue))
|
| | | }
|
| | | },
|
| | | getJSON (key) {
|
| | | const value = this.get(key)
|
| | | if (value != null) {
|
| | | return JSON.parse(value)
|
| | | }
|
| | | },
|
| | | remove (key) {
|
| | | sessionStorage.removeItem(key);
|
| | | }
|
| | | }
|
| | | const localCache = {
|
| | | set (key, value) {
|
| | | if (!localStorage) {
|
| | | return
|
| | | }
|
| | | if (key != null && value != null) {
|
| | | localStorage.setItem(key, value)
|
| | | }
|
| | | },
|
| | | get (key) {
|
| | | if (!localStorage) {
|
| | | return null
|
| | | }
|
| | | if (key == null) {
|
| | | return null
|
| | | }
|
| | | return localStorage.getItem(key)
|
| | | },
|
| | | setJSON (key, jsonValue) {
|
| | | if (jsonValue != null) {
|
| | | this.set(key, JSON.stringify(jsonValue))
|
| | | }
|
| | | },
|
| | | getJSON (key) {
|
| | | const value = this.get(key)
|
| | | if (value != null) {
|
| | | return JSON.parse(value)
|
| | | }
|
| | | },
|
| | | remove (key) {
|
| | | localStorage.removeItem(key);
|
| | | }
|
| | | }
|
| | |
|
| | | export default {
|
| | | /**
|
| | | * ä¼è¯çº§ç¼å
|
| | | */
|
| | | session: sessionCache,
|
| | | /**
|
| | | * æ¬å°ç¼å
|
| | | */
|
| | | local: localCache
|
| | | }
|
¶Ô±ÈÐÂÎļþ |
| | |
| | | import cache from './cache'
|
| | | import modal from './modal'
|
| | |
|
| | | export default {
|
| | | install(Vue) {
|
| | | // ç¼å对象
|
| | | Vue.prototype.$cache = cache
|
| | | // æ¨¡ææ¡å¯¹è±¡
|
| | | Vue.prototype.$modal = modal
|
| | | }
|
| | | }
|
¶Ô±ÈÐÂÎļþ |
| | |
| | | import { Message, MessageBox, Notification, Loading } from 'element-ui'
|
| | |
|
| | | let loadingInstance;
|
| | |
|
| | | export default {
|
| | | // æ¶æ¯æç¤º
|
| | | msg(content) {
|
| | | Message.info(content)
|
| | | },
|
| | | // éè¯¯æ¶æ¯
|
| | | msgError(content) {
|
| | | Message.error(content)
|
| | | },
|
| | | // æåæ¶æ¯
|
| | | msgSuccess(content) {
|
| | | Message.success(content)
|
| | | },
|
| | | // è¦åæ¶æ¯
|
| | | msgWarning(content) {
|
| | | Message.warning(content)
|
| | | },
|
| | | // å¼¹åºæç¤º
|
| | | alert(content) {
|
| | | MessageBox.alert(content, "ç³»ç»æç¤º")
|
| | | },
|
| | | // é误æç¤º
|
| | | alertError(content) {
|
| | | MessageBox.alert(content, "ç³»ç»æç¤º", { type: 'error' })
|
| | | },
|
| | | // æåæç¤º
|
| | | alertSuccess(content) {
|
| | | MessageBox.alert(content, "ç³»ç»æç¤º", { type: 'success' })
|
| | | },
|
| | | // è¦åæç¤º
|
| | | alertWarning(content) {
|
| | | MessageBox.alert(content, "ç³»ç»æç¤º", { type: 'warning' })
|
| | | },
|
| | | // éç¥æç¤º
|
| | | notify(content) {
|
| | | Notification.info(content)
|
| | | },
|
| | | // é误éç¥
|
| | | notifyError(content) {
|
| | | Notification.error(content);
|
| | | },
|
| | | // æåéç¥
|
| | | notifySuccess(content) {
|
| | | Notification.success(content)
|
| | | },
|
| | | // è¦åéç¥
|
| | | notifyWarning(content) {
|
| | | Notification.warning(content)
|
| | | },
|
| | | // 确认çªä½
|
| | | confirm(content) {
|
| | | return MessageBox.confirm(content, "ç³»ç»æç¤º", {
|
| | | confirmButtonText: 'ç¡®å®',
|
| | | cancelButtonText: 'åæ¶',
|
| | | type: "warning",
|
| | | })
|
| | | },
|
| | | // æå¼é®ç½©å±
|
| | | loading(content) {
|
| | | loadingInstance = Loading.service({
|
| | | lock: true,
|
| | | text: content,
|
| | | spinner: "el-icon-loading",
|
| | | background: "rgba(0, 0, 0, 0.7)",
|
| | | })
|
| | | },
|
| | | // å
³éé®ç½©å±
|
| | | closeLoading() {
|
| | | loadingInstance.close();
|
| | | }
|
| | | }
|
| | |
| | | name: "Server",
|
| | | data() {
|
| | | return {
|
| | | // å è½½å±ä¿¡æ¯
|
| | | loading: [],
|
| | | // ç»è®¡å½ä»¤ä¿¡æ¯
|
| | | commandstats: null,
|
| | | // 使ç¨å
å
|
| | |
| | | getList() {
|
| | | getCache().then((response) => {
|
| | | this.cache = response.data;
|
| | | this.loading.close();
|
| | | this.$modal.closeLoading();
|
| | |
|
| | | this.commandstats = echarts.init(this.$refs.commandstats, "macarons");
|
| | | this.commandstats.setOption({
|
| | |
| | | },
|
| | | // æå¼å è½½å±
|
| | | openLoading() {
|
| | | this.loading = this.$loading({
|
| | | lock: true,
|
| | | text: "æ¼å½è¯»åä¸",
|
| | | spinner: "el-icon-loading",
|
| | | background: "rgba(0, 0, 0, 0.7)",
|
| | | });
|
| | | this.$modal.loading("æ£å¨å è½½ç¼åçæ§æ°æ®ï¼è¯·ç¨åï¼");
|
| | | },
|
| | | },
|
| | | };
|
| | |
| | | </div> |
| | | </el-dialog> |
| | | |
| | | <el-dialog title="Cron表达å¼çæå¨" :visible.sync="openCron" append-to-body class="scrollbar" destroy-on-close > |
| | | <el-dialog title="Cron表达å¼çæå¨" :visible.sync="openCron" append-to-body destroy-on-close class="scrollbar"> |
| | | <crontab @hide="openCron=false" @fill="crontabFill" :expression="expression"></crontab> |
| | | </el-dialog> |
| | | |
| | |
| | | // ä»»å¡ç¶æä¿®æ¹ |
| | | handleStatusChange(row) { |
| | | let text = row.status === "0" ? "å¯ç¨" : "åç¨"; |
| | | this.$confirm('确认è¦"' + text + '""' + row.jobName + '"ä»»å¡å?', "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(function() { |
| | | return changeJobStatus(row.jobId, row.status); |
| | | }).then(() => { |
| | | this.msgSuccess(text + "æå"); |
| | | }).catch(function() { |
| | | row.status = row.status === "0" ? "1" : "0"; |
| | | }); |
| | | this.$modal.confirm('确认è¦"' + text + '""' + row.jobName + '"ä»»å¡åï¼').then(function() { |
| | | return changeJobStatus(row.jobId, row.status); |
| | | }).then(() => { |
| | | this.$modal.msgSuccess(text + "æå"); |
| | | }).catch(function() { |
| | | row.status = row.status === "0" ? "1" : "0"; |
| | | }); |
| | | }, |
| | | /* ç«å³æ§è¡ä¸æ¬¡ */ |
| | | handleRun(row) { |
| | | this.$confirm('确认è¦ç«å³æ§è¡ä¸æ¬¡"' + row.jobName + '"ä»»å¡å?', "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(function() { |
| | | return runJob(row.jobId, row.jobGroup); |
| | | }).then(() => { |
| | | this.msgSuccess("æ§è¡æå"); |
| | | }).catch(() => {}); |
| | | this.$modal.confirm('确认è¦ç«å³æ§è¡ä¸æ¬¡"' + row.jobName + '"ä»»å¡åï¼').then(function() { |
| | | return runJob(row.jobId, row.jobGroup); |
| | | }).then(() => { |
| | | this.$modal.msgSuccess("æ§è¡æå"); |
| | | }).catch(() => {}); |
| | | }, |
| | | /** ä»»å¡è¯¦ç»ä¿¡æ¯ */ |
| | | handleView(row) { |
| | |
| | | if (valid) { |
| | | if (this.form.jobId != undefined) { |
| | | updateJob(this.form).then(response => { |
| | | this.msgSuccess("ä¿®æ¹æå"); |
| | | this.$modal.msgSuccess("ä¿®æ¹æå"); |
| | | this.open = false; |
| | | this.getList(); |
| | | }); |
| | | } else { |
| | | addJob(this.form).then(response => { |
| | | this.msgSuccess("æ°å¢æå"); |
| | | this.$modal.msgSuccess("æ°å¢æå"); |
| | | this.open = false; |
| | | this.getList(); |
| | | }); |
| | |
| | | /** å é¤æé®æä½ */ |
| | | handleDelete(row) { |
| | | const jobIds = row.jobId || this.ids; |
| | | this.$confirm('æ¯å¦ç¡®è®¤å é¤å®æ¶ä»»å¡ç¼å·ä¸º"' + jobIds + '"çæ°æ®é¡¹?', "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(function() { |
| | | return delJob(jobIds); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | this.$modal.confirm('æ¯å¦ç¡®è®¤å é¤å®æ¶ä»»å¡ç¼å·ä¸º"' + jobIds + '"çæ°æ®é¡¹ï¼').then(function() { |
| | | return delJob(jobIds); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.$modal.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | }, |
| | | /** å¯¼åºæé®æä½ */ |
| | | handleExport() { |
| | |
| | | /** å é¤æé®æä½ */ |
| | | handleDelete(row) { |
| | | const jobLogIds = this.ids; |
| | | this.$confirm('æ¯å¦ç¡®è®¤å é¤è°åº¦æ¥å¿ç¼å·ä¸º"' + jobLogIds + '"çæ°æ®é¡¹?', "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(function() { |
| | | return delJobLog(jobLogIds); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | this.$modal.confirm('æ¯å¦ç¡®è®¤å é¤è°åº¦æ¥å¿ç¼å·ä¸º"' + jobLogIds + '"çæ°æ®é¡¹ï¼').then(function() { |
| | | return delJobLog(jobLogIds); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.$modal.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | }, |
| | | /** æ¸
空æé®æä½ */ |
| | | handleClean() { |
| | | this.$confirm("æ¯å¦ç¡®è®¤æ¸
空ææè°åº¦æ¥å¿æ°æ®é¡¹?", "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(function() { |
| | | return cleanJobLog(); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.msgSuccess("æ¸
空æå"); |
| | | }).catch(() => {}); |
| | | this.$modal.confirm('æ¯å¦ç¡®è®¤æ¸
空ææè°åº¦æ¥å¿æ°æ®é¡¹ï¼').then(function() { |
| | | return cleanJobLog(); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.$modal.msgSuccess("æ¸
空æå"); |
| | | }).catch(() => {}); |
| | | }, |
| | | /** å¯¼åºæé®æä½ */ |
| | | handleExport() { |
| | |
| | | /** å é¤æé®æä½ */ |
| | | handleDelete(row) { |
| | | const infoIds = row.infoId || this.ids; |
| | | this.$confirm('æ¯å¦ç¡®è®¤å é¤è®¿é®ç¼å·ä¸º"' + infoIds + '"çæ°æ®é¡¹?', "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(function() { |
| | | return delLogininfor(infoIds); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | this.$modal.confirm('æ¯å¦ç¡®è®¤å é¤è®¿é®ç¼å·ä¸º"' + infoIds + '"çæ°æ®é¡¹ï¼').then(function() { |
| | | return delLogininfor(infoIds); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.$modal.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | }, |
| | | /** æ¸
空æé®æä½ */ |
| | | handleClean() { |
| | | this.$confirm('æ¯å¦ç¡®è®¤æ¸
空ææç»å½æ¥å¿æ°æ®é¡¹?', "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(function() { |
| | | return cleanLogininfor(); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.msgSuccess("æ¸
空æå"); |
| | | }).catch(() => {}); |
| | | this.$modal.confirm('æ¯å¦ç¡®è®¤æ¸
空ææç»å½æ¥å¿æ°æ®é¡¹ï¼').then(function() { |
| | | return cleanLogininfor(); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.$modal.msgSuccess("æ¸
空æå"); |
| | | }).catch(() => {}); |
| | | }, |
| | | /** å¯¼åºæé®æä½ */ |
| | | handleExport() { |
| | |
| | | }, |
| | | /** 强éæé®æä½ */ |
| | | handleForceLogout(row) { |
| | | this.$confirm('æ¯å¦ç¡®è®¤å¼ºéå称为"' + row.userName + '"çæ°æ®é¡¹?', "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(function() { |
| | | return forceLogout(row.tokenId); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.msgSuccess("强éæå"); |
| | | }).catch(() => {}); |
| | | this.$modal.confirm('æ¯å¦ç¡®è®¤å¼ºéå称为"' + row.userName + '"çæ°æ®é¡¹ï¼').then(function() { |
| | | return forceLogout(row.tokenId); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.$modal.msgSuccess("强éæå"); |
| | | }).catch(() => {}); |
| | | } |
| | | } |
| | | }; |
| | |
| | | /** å é¤æé®æä½ */ |
| | | handleDelete(row) { |
| | | const operIds = row.operId || this.ids; |
| | | this.$confirm('æ¯å¦ç¡®è®¤å 餿¥å¿ç¼å·ä¸º"' + operIds + '"çæ°æ®é¡¹?', "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(function() { |
| | | return delOperlog(operIds); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | this.$modal.confirm('æ¯å¦ç¡®è®¤å 餿¥å¿ç¼å·ä¸º"' + operIds + '"çæ°æ®é¡¹ï¼').then(function() { |
| | | return delOperlog(operIds); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.$modal.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | }, |
| | | /** æ¸
空æé®æä½ */ |
| | | handleClean() { |
| | | this.$confirm('æ¯å¦ç¡®è®¤æ¸
ç©ºæææä½æ¥å¿æ°æ®é¡¹?', "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(function() { |
| | | return cleanOperlog(); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.msgSuccess("æ¸
空æå"); |
| | | }).catch(() => {}); |
| | | this.$modal.confirm('æ¯å¦ç¡®è®¤æ¸
ç©ºæææä½æ¥å¿æ°æ®é¡¹ï¼').then(function() { |
| | | return cleanOperlog(); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.$modal.msgSuccess("æ¸
空æå"); |
| | | }).catch(() => {}); |
| | | }, |
| | | /** å¯¼åºæé®æä½ */ |
| | | handleExport() { |
| | |
| | | if (valid) { |
| | | if (this.form.configId != undefined) { |
| | | updateConfig(this.form).then(response => { |
| | | this.msgSuccess("ä¿®æ¹æå"); |
| | | this.$modal.msgSuccess("ä¿®æ¹æå"); |
| | | this.open = false; |
| | | this.getList(); |
| | | }); |
| | | } else { |
| | | addConfig(this.form).then(response => { |
| | | this.msgSuccess("æ°å¢æå"); |
| | | this.$modal.msgSuccess("æ°å¢æå"); |
| | | this.open = false; |
| | | this.getList(); |
| | | }); |
| | |
| | | /** å é¤æé®æä½ */ |
| | | handleDelete(row) { |
| | | const configIds = row.configId || this.ids; |
| | | this.$confirm('æ¯å¦ç¡®è®¤å é¤åæ°ç¼å·ä¸º"' + configIds + '"çæ°æ®é¡¹?', "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(function() { |
| | | this.$modal.confirm('æ¯å¦ç¡®è®¤å é¤åæ°ç¼å·ä¸º"' + configIds + '"çæ°æ®é¡¹ï¼').then(function() { |
| | | return delConfig(configIds); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.msgSuccess("å 餿å"); |
| | | this.$modal.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | }, |
| | | /** å¯¼åºæé®æä½ */ |
| | |
| | | /** å·æ°ç¼åæé®æä½ */ |
| | | handleRefreshCache() { |
| | | refreshCache().then(() => { |
| | | this.msgSuccess("å·æ°æå"); |
| | | this.$modal.msgSuccess("å·æ°æå"); |
| | | }); |
| | | } |
| | | } |
| | |
| | | if (valid) { |
| | | if (this.form.deptId != undefined) { |
| | | updateDept(this.form).then(response => { |
| | | this.msgSuccess("ä¿®æ¹æå"); |
| | | this.$modal.msgSuccess("ä¿®æ¹æå"); |
| | | this.open = false; |
| | | this.getList(); |
| | | }); |
| | | } else { |
| | | addDept(this.form).then(response => { |
| | | this.msgSuccess("æ°å¢æå"); |
| | | this.$modal.msgSuccess("æ°å¢æå"); |
| | | this.open = false; |
| | | this.getList(); |
| | | }); |
| | |
| | | }, |
| | | /** å é¤æé®æä½ */ |
| | | handleDelete(row) { |
| | | this.$confirm('æ¯å¦ç¡®è®¤å é¤å称为"' + row.deptName + '"çæ°æ®é¡¹?', "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(function() { |
| | | return delDept(row.deptId); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | this.$modal.confirm('æ¯å¦ç¡®è®¤å é¤å称为"' + row.deptName + '"çæ°æ®é¡¹ï¼').then(function() { |
| | | return delDept(row.deptId); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.$modal.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | } |
| | | } |
| | | }; |
| | |
| | | if (valid) { |
| | | if (this.form.dictCode != undefined) { |
| | | updateData(this.form).then(response => { |
| | | this.msgSuccess("ä¿®æ¹æå"); |
| | | this.$modal.msgSuccess("ä¿®æ¹æå"); |
| | | this.open = false; |
| | | this.getList(); |
| | | }); |
| | | } else { |
| | | addData(this.form).then(response => { |
| | | this.msgSuccess("æ°å¢æå"); |
| | | this.$modal.msgSuccess("æ°å¢æå"); |
| | | this.open = false; |
| | | this.getList(); |
| | | }); |
| | |
| | | /** å é¤æé®æä½ */ |
| | | handleDelete(row) { |
| | | const dictCodes = row.dictCode || this.ids; |
| | | this.$confirm('æ¯å¦ç¡®è®¤å é¤åå
¸ç¼ç 为"' + dictCodes + '"çæ°æ®é¡¹?', "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(function() { |
| | | return delData(dictCodes); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | this.$modal.confirm('æ¯å¦ç¡®è®¤å é¤åå
¸ç¼ç 为"' + dictCodes + '"çæ°æ®é¡¹ï¼').then(function() { |
| | | return delData(dictCodes); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.$modal.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | }, |
| | | /** å¯¼åºæé®æä½ */ |
| | | handleExport() { |
| | |
| | | if (valid) { |
| | | if (this.form.dictId != undefined) { |
| | | updateType(this.form).then(response => { |
| | | this.msgSuccess("ä¿®æ¹æå"); |
| | | this.$modal.msgSuccess("ä¿®æ¹æå"); |
| | | this.open = false; |
| | | this.getList(); |
| | | }); |
| | | } else { |
| | | addType(this.form).then(response => { |
| | | this.msgSuccess("æ°å¢æå"); |
| | | this.$modal.msgSuccess("æ°å¢æå"); |
| | | this.open = false; |
| | | this.getList(); |
| | | }); |
| | |
| | | /** å é¤æé®æä½ */ |
| | | handleDelete(row) { |
| | | const dictIds = row.dictId || this.ids; |
| | | this.$confirm('æ¯å¦ç¡®è®¤å é¤åå
¸ç¼å·ä¸º"' + dictIds + '"çæ°æ®é¡¹?', "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(function() { |
| | | return delType(dictIds); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | this.$modal.confirm('æ¯å¦ç¡®è®¤å é¤åå
¸ç¼å·ä¸º"' + dictIds + '"çæ°æ®é¡¹ï¼').then(function() { |
| | | return delType(dictIds); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.$modal.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | }, |
| | | /** å¯¼åºæé®æä½ */ |
| | | handleExport() { |
| | |
| | | /** å·æ°ç¼åæé®æä½ */ |
| | | handleRefreshCache() { |
| | | refreshCache().then(() => { |
| | | this.msgSuccess("å·æ°æå"); |
| | | this.$modal.msgSuccess("å·æ°æå"); |
| | | }); |
| | | } |
| | | } |
| | |
| | | if (valid) { |
| | | if (this.form.menuId != undefined) { |
| | | updateMenu(this.form).then(response => { |
| | | this.msgSuccess("ä¿®æ¹æå"); |
| | | this.$modal.msgSuccess("ä¿®æ¹æå"); |
| | | this.open = false; |
| | | this.getList(); |
| | | }); |
| | | } else { |
| | | addMenu(this.form).then(response => { |
| | | this.msgSuccess("æ°å¢æå"); |
| | | this.$modal.msgSuccess("æ°å¢æå"); |
| | | this.open = false; |
| | | this.getList(); |
| | | }); |
| | |
| | | }, |
| | | /** å é¤æé®æä½ */ |
| | | handleDelete(row) { |
| | | this.$confirm('æ¯å¦ç¡®è®¤å é¤å称为"' + row.menuName + '"çæ°æ®é¡¹?', "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(function() { |
| | | return delMenu(row.menuId); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | this.$modal.confirm('æ¯å¦ç¡®è®¤å é¤å称为"' + row.menuName + '"çæ°æ®é¡¹ï¼').then(function() { |
| | | return delMenu(row.menuId); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.$modal.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | } |
| | | } |
| | | }; |
| | |
| | | if (valid) { |
| | | if (this.form.noticeId != undefined) { |
| | | updateNotice(this.form).then(response => { |
| | | this.msgSuccess("ä¿®æ¹æå"); |
| | | this.$modal.msgSuccess("ä¿®æ¹æå"); |
| | | this.open = false; |
| | | this.getList(); |
| | | }); |
| | | } else { |
| | | addNotice(this.form).then(response => { |
| | | this.msgSuccess("æ°å¢æå"); |
| | | this.$modal.msgSuccess("æ°å¢æå"); |
| | | this.open = false; |
| | | this.getList(); |
| | | }); |
| | |
| | | /** å é¤æé®æä½ */ |
| | | handleDelete(row) { |
| | | const noticeIds = row.noticeId || this.ids |
| | | this.$confirm('æ¯å¦ç¡®è®¤å é¤å
¬åç¼å·ä¸º"' + noticeIds + '"çæ°æ®é¡¹?', "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(function() { |
| | | return delNotice(noticeIds); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | this.$modal.confirm('æ¯å¦ç¡®è®¤å é¤å
¬åç¼å·ä¸º"' + noticeIds + '"çæ°æ®é¡¹ï¼').then(function() { |
| | | return delNotice(noticeIds); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.$modal.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | } |
| | | } |
| | | }; |
| | |
| | | if (valid) { |
| | | if (this.form.postId != undefined) { |
| | | updatePost(this.form).then(response => { |
| | | this.msgSuccess("ä¿®æ¹æå"); |
| | | this.$modal.msgSuccess("ä¿®æ¹æå"); |
| | | this.open = false; |
| | | this.getList(); |
| | | }); |
| | | } else { |
| | | addPost(this.form).then(response => { |
| | | this.msgSuccess("æ°å¢æå"); |
| | | this.$modal.msgSuccess("æ°å¢æå"); |
| | | this.open = false; |
| | | this.getList(); |
| | | }); |
| | |
| | | /** å é¤æé®æä½ */ |
| | | handleDelete(row) { |
| | | const postIds = row.postId || this.ids; |
| | | this.$confirm('æ¯å¦ç¡®è®¤å é¤å²ä½ç¼å·ä¸º"' + postIds + '"çæ°æ®é¡¹?', "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(function() { |
| | | return delPost(postIds); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | this.$modal.confirm('æ¯å¦ç¡®è®¤å é¤å²ä½ç¼å·ä¸º"' + postIds + '"çæ°æ®é¡¹ï¼').then(function() { |
| | | return delPost(postIds); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.$modal.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | }, |
| | | /** å¯¼åºæé®æä½ */ |
| | | handleExport() { |
| | |
| | | /** åæ¶æææé®æä½ */
|
| | | cancelAuthUser(row) {
|
| | | const roleId = this.queryParams.roleId;
|
| | | this.$confirm('确认è¦åæ¶è¯¥ç¨æ·"' + row.userName + '"è§è²åï¼', "è¦å", {
|
| | | confirmButtonText: "ç¡®å®",
|
| | | cancelButtonText: "åæ¶",
|
| | | type: "warning"
|
| | | }).then(function() {
|
| | | this.$modal.confirm('确认è¦åæ¶è¯¥ç¨æ·"' + row.userName + '"è§è²åï¼').then(function() {
|
| | | return authUserCancel({ userId: row.userId, roleId: roleId });
|
| | | }).then(() => {
|
| | | this.getList();
|
| | | this.msgSuccess("åæ¶æææå");
|
| | | this.$modal.msgSuccess("åæ¶æææå");
|
| | | }).catch(() => {});
|
| | | },
|
| | | /** æ¹éåæ¶æææé®æä½ */
|
| | | cancelAuthUserAll(row) {
|
| | | const roleId = this.queryParams.roleId;
|
| | | const userIds = this.userIds.join(",");
|
| | | this.$confirm('æ¯å¦åæ¶éä¸ç¨æ·æææ°æ®é¡¹?', "è¦å", {
|
| | | confirmButtonText: "ç¡®å®",
|
| | | cancelButtonText: "åæ¶",
|
| | | type: "warning"
|
| | | }).then(() => {
|
| | | return authUserCancelAll({ roleId: roleId, userIds: userIds });
|
| | | this.$modal.confirm('æ¯å¦åæ¶éä¸ç¨æ·æææ°æ®é¡¹ï¼').then(function() {
|
| | | return authUserCancelAll({ roleId: roleId, userIds: userIds });
|
| | | }).then(() => {
|
| | | this.getList();
|
| | | this.msgSuccess("åæ¶æææå");
|
| | | this.$modal.msgSuccess("åæ¶æææå");
|
| | | }).catch(() => {});
|
| | | }
|
| | | }
|
| | |
| | | // è§è²ç¶æä¿®æ¹ |
| | | handleStatusChange(row) { |
| | | let text = row.status === "0" ? "å¯ç¨" : "åç¨"; |
| | | this.$confirm('确认è¦"' + text + '""' + row.roleName + '"è§è²å?', "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(function() { |
| | | return changeRoleStatus(row.roleId, row.status); |
| | | }).then(() => { |
| | | this.msgSuccess(text + "æå"); |
| | | }).catch(function() { |
| | | row.status = row.status === "0" ? "1" : "0"; |
| | | }); |
| | | this.$modal.confirm('确认è¦"' + text + '""' + row.roleName + '"è§è²åï¼').then(function() { |
| | | return changeRoleStatus(row.roleId, row.status); |
| | | }).then(() => { |
| | | this.$modal.msgSuccess(text + "æå"); |
| | | }).catch(function() { |
| | | row.status = row.status === "0" ? "1" : "0"; |
| | | }); |
| | | }, |
| | | // åæ¶æé® |
| | | cancel() { |
| | |
| | | if (this.form.roleId != undefined) { |
| | | this.form.menuIds = this.getMenuAllCheckedKeys(); |
| | | updateRole(this.form).then(response => { |
| | | this.msgSuccess("ä¿®æ¹æå"); |
| | | this.$modal.msgSuccess("ä¿®æ¹æå"); |
| | | this.open = false; |
| | | this.getList(); |
| | | }); |
| | | } else { |
| | | this.form.menuIds = this.getMenuAllCheckedKeys(); |
| | | addRole(this.form).then(response => { |
| | | this.msgSuccess("æ°å¢æå"); |
| | | this.$modal.msgSuccess("æ°å¢æå"); |
| | | this.open = false; |
| | | this.getList(); |
| | | }); |
| | |
| | | if (this.form.roleId != undefined) { |
| | | this.form.deptIds = this.getDeptAllCheckedKeys(); |
| | | dataScope(this.form).then(response => { |
| | | this.msgSuccess("ä¿®æ¹æå"); |
| | | this.$modal.msgSuccess("ä¿®æ¹æå"); |
| | | this.openDataScope = false; |
| | | this.getList(); |
| | | }); |
| | |
| | | /** å é¤æé®æä½ */ |
| | | handleDelete(row) { |
| | | const roleIds = row.roleId || this.ids; |
| | | this.$confirm('æ¯å¦ç¡®è®¤å é¤è§è²ç¼å·ä¸º"' + roleIds + '"çæ°æ®é¡¹?', "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(function() { |
| | | return delRole(roleIds); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | this.$modal.confirm('æ¯å¦ç¡®è®¤å é¤è§è²ç¼å·ä¸º"' + roleIds + '"çæ°æ®é¡¹ï¼').then(function() { |
| | | return delRole(roleIds); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.$modal.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | }, |
| | | /** å¯¼åºæé®æä½ */ |
| | | handleExport() { |
| | |
| | | const roleId = this.queryParams.roleId;
|
| | | const userIds = this.userIds.join(",");
|
| | | authUserSelectAll({ roleId: roleId, userIds: userIds }).then(res => {
|
| | | this.msgSuccess(res.msg);
|
| | | this.$modal.msgSuccess(res.msg);
|
| | | if (res.code === 200) {
|
| | | this.visible = false;
|
| | | this.$emit("ok");
|
| | |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | |
| | | |
| | | <pagination v-show="total>0" :total="total" :page.sync="pageNum" :limit.sync="pageSize" /> |
| | | |
| | | <el-form label-width="100px"> |
| | |
| | | const userId = this.form.userId; |
| | | const roleIds = this.roleIds.join(","); |
| | | updateAuthRole({ userId: userId, roleIds: roleIds }).then((response) => { |
| | | this.msgSuccess("æææå"); |
| | | this.$modal.msgSuccess("æææå"); |
| | | this.close(); |
| | | }); |
| | | }, |
| | |
| | | }, |
| | | }, |
| | | }; |
| | | </script> |
| | | </script> |
| | |
| | | // ç¨æ·ç¶æä¿®æ¹ |
| | | handleStatusChange(row) { |
| | | let text = row.status === "0" ? "å¯ç¨" : "åç¨"; |
| | | this.$confirm('确认è¦"' + text + '""' + row.userName + '"ç¨æ·å?', "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(function() { |
| | | return changeUserStatus(row.userId, row.status); |
| | | }).then(() => { |
| | | this.msgSuccess(text + "æå"); |
| | | }).catch(function() { |
| | | row.status = row.status === "0" ? "1" : "0"; |
| | | }); |
| | | this.$modal.confirm('确认è¦"' + text + '""' + row.userName + '"ç¨æ·åï¼').then(function() { |
| | | return changeUserStatus(row.userId, row.status); |
| | | }).then(() => { |
| | | this.$modal.msgSuccess(text + "æå"); |
| | | }).catch(function() { |
| | | row.status = row.status === "0" ? "1" : "0"; |
| | | }); |
| | | }, |
| | | // åæ¶æé® |
| | | cancel() { |
| | |
| | | inputErrorMessage: "ç¨æ·å¯ç é¿åº¦å¿
é¡»ä»äº 5 å 20 ä¹é´", |
| | | }).then(({ value }) => { |
| | | resetUserPwd(row.userId, value).then(response => { |
| | | this.msgSuccess("ä¿®æ¹æåï¼æ°å¯ç æ¯ï¼" + value); |
| | | this.$modal.msgSuccess("ä¿®æ¹æåï¼æ°å¯ç æ¯ï¼" + value); |
| | | }); |
| | | }).catch(() => {}); |
| | | }, |
| | |
| | | if (valid) { |
| | | if (this.form.userId != undefined) { |
| | | updateUser(this.form).then(response => { |
| | | this.msgSuccess("ä¿®æ¹æå"); |
| | | this.$modal.msgSuccess("ä¿®æ¹æå"); |
| | | this.open = false; |
| | | this.getList(); |
| | | }); |
| | | } else { |
| | | addUser(this.form).then(response => { |
| | | this.msgSuccess("æ°å¢æå"); |
| | | this.$modal.msgSuccess("æ°å¢æå"); |
| | | this.open = false; |
| | | this.getList(); |
| | | }); |
| | |
| | | /** å é¤æé®æä½ */ |
| | | handleDelete(row) { |
| | | const userIds = row.userId || this.ids; |
| | | this.$confirm('æ¯å¦ç¡®è®¤å é¤ç¨æ·ç¼å·ä¸º"' + userIds + '"çæ°æ®é¡¹?', "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(function() { |
| | | return delUser(userIds); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | this.$modal.confirm('æ¯å¦ç¡®è®¤å é¤ç¨æ·ç¼å·ä¸º"' + userIds + '"çæ°æ®é¡¹ï¼').then(function() { |
| | | return delUser(userIds); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.$modal.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | }, |
| | | /** å¯¼åºæé®æä½ */ |
| | | handleExport() { |
| | |
| | | if (valid) { |
| | | updateUserPwd(this.user.oldPassword, this.user.newPassword).then( |
| | | response => { |
| | | this.msgSuccess("ä¿®æ¹æå"); |
| | | this.$modal.msgSuccess("ä¿®æ¹æå"); |
| | | } |
| | | ); |
| | | } |
| | |
| | | // ä¸ä¼ é¢å¤ç |
| | | beforeUpload(file) { |
| | | if (file.type.indexOf("image/") == -1) { |
| | | this.msgError("æä»¶æ ¼å¼é误ï¼è¯·ä¸ä¼ å¾çç±»å,å¦ï¼JPGï¼PNGåç¼çæä»¶ã"); |
| | | this.$modal.msgError("æä»¶æ ¼å¼é误ï¼è¯·ä¸ä¼ å¾çç±»å,å¦ï¼JPGï¼PNGåç¼çæä»¶ã"); |
| | | } else { |
| | | const reader = new FileReader(); |
| | | reader.readAsDataURL(file); |
| | |
| | | this.open = false; |
| | | this.options.img = response.data.imgUrl; |
| | | store.commit('SET_AVATAR', this.options.img); |
| | | this.msgSuccess("ä¿®æ¹æå"); |
| | | this.$modal.msgSuccess("ä¿®æ¹æå"); |
| | | this.visible = false; |
| | | }); |
| | | }); |
| | |
| | | line-height: 110px; |
| | | border-radius: 50%; |
| | | } |
| | | </style> |
| | | </style> |
| | |
| | | <el-form ref="form" :model="user" :rules="rules" label-width="80px"> |
| | | <el-form-item label="ç¨æ·æµç§°" prop="nickName"> |
| | | <el-input v-model="user.nickName" maxlength="30" /> |
| | | </el-form-item> |
| | | </el-form-item> |
| | | <el-form-item label="ææºå·ç " prop="phonenumber"> |
| | | <el-input v-model="user.phonenumber" maxlength="11" /> |
| | | </el-form-item> |
| | |
| | | this.$refs["form"].validate(valid => { |
| | | if (valid) { |
| | | updateUserProfile(this.user).then(response => { |
| | | this.msgSuccess("ä¿®æ¹æå"); |
| | | this.$modal.msgSuccess("ä¿®æ¹æå"); |
| | | }); |
| | | } |
| | | }); |
| | |
| | | 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("è¡¨åæ ¡éªæªéè¿ï¼è¯·éæ°æ£æ¥æäº¤å
容"); |
| | | } |
| | | }); |
| | | }, |
| | |
| | | }, |
| | | /** 导å
¥æé®æä½ */ |
| | | handleImportTable() { |
| | | importTable({ tables: this.tables.join(",") }).then(res => { |
| | | this.msgSuccess(res.msg); |
| | | const tableNames = this.tables.join(","); |
| | | if (tableNames == "") { |
| | | this.$modal.msgError("è¯·éæ©è¦å¯¼å
¥ç表"); |
| | | return; |
| | | } |
| | | importTable({ tables: tableNames }).then(res => { |
| | | this.$modal.msgSuccess(res.msg); |
| | | if (res.code === 200) { |
| | | this.visible = false; |
| | | this.$emit("ok"); |
| | |
| | | handleGenTable(row) { |
| | | const tableNames = row.tableName || this.tableNames; |
| | | if (tableNames == "") { |
| | | this.msgError("è¯·éæ©è¦çæçæ°æ®"); |
| | | this.$modal.msgError("è¯·éæ©è¦çæçæ°æ®"); |
| | | return; |
| | | } |
| | | if(row.genType === "1") { |
| | | genCode(row.tableName).then(response => { |
| | | this.msgSuccess("æåçæå°èªå®ä¹è·¯å¾ï¼" + row.genPath); |
| | | this.$modal.msgSuccess("æåçæå°èªå®ä¹è·¯å¾ï¼" + row.genPath); |
| | | }); |
| | | } else { |
| | | downLoadZip("/tool/gen/batchGenCode?tables=" + tableNames, "ruoyi"); |
| | |
| | | /** åæ¥æ°æ®åºæä½ */ |
| | | handleSynchDb(row) { |
| | | const tableName = row.tableName; |
| | | this.$confirm('确认è¦å¼ºå¶åæ¥"' + tableName + '"è¡¨ç»æåï¼', "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(function() { |
| | | return synchDb(tableName); |
| | | this.$modal.confirm('确认è¦å¼ºå¶åæ¥"' + tableName + '"è¡¨ç»æåï¼').then(function() { |
| | | return synchDb(tableName); |
| | | }).then(() => { |
| | | this.msgSuccess("忥æå"); |
| | | this.$modal.msgSuccess("忥æå"); |
| | | }).catch(() => {}); |
| | | }, |
| | | /** æå¼å¯¼å
¥è¡¨å¼¹çª */ |
| | |
| | | /** å é¤æé®æä½ */ |
| | | handleDelete(row) { |
| | | const tableIds = row.tableId || this.ids; |
| | | this.$confirm('æ¯å¦ç¡®è®¤å é¤è¡¨ç¼å·ä¸º"' + tableIds + '"çæ°æ®é¡¹?', "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(function() { |
| | | return delTable(tableIds); |
| | | this.$modal.confirm('æ¯å¦ç¡®è®¤å é¤è¡¨ç¼å·ä¸º"' + tableIds + '"çæ°æ®é¡¹ï¼').then(function() { |
| | | return delTable(tableIds); |
| | | }).then(() => { |
| | | this.getList(); |
| | | this.msgSuccess("å 餿å"); |
| | | this.getList(); |
| | | this.$modal.msgSuccess("å 餿å"); |
| | | }).catch(() => {}); |
| | | } |
| | | } |