v1.2 版本发布,代码同步后端v1.2版本

This commit is contained in:
郑杰
2018-12-28 18:11:30 +08:00
parent c6484593df
commit 7f2e4ed3f9
41 changed files with 797 additions and 58 deletions

View File

@@ -15,7 +15,7 @@
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="text" @click="cancel">取消</el-button>
<el-button type="primary" @click="doSubmit">确认</el-button>
<el-button :loading="loading" type="primary" @click="doSubmit">确认</el-button>
</div>
</el-dialog>
</div>
@@ -42,7 +42,7 @@ export default {
},
data() {
return {
dialog: false, title: '编辑权限',
loading: false, dialog: false, title: '编辑权限',
form: { id: '', name: '', alias: '', pid: 0 },
rules: {
name: [
@@ -65,6 +65,7 @@ export default {
doSubmit() {
this.$refs['form'].validate((valid) => {
if (valid) {
this.loading = true
const _this = this
edit(this.form).then(res => {
this.resetForm()
@@ -73,8 +74,14 @@ export default {
type: 'success',
duration: 2500
})
_this.sup_this.init()
_this.sup_this.getPermissions()
this.loading = false
setTimeout(() => {
_this.sup_this.init()
_this.sup_this.getPermissions()
}, 200)
}).catch(err => {
this.loading = false
console.log(err.response.data.message)
})
} else {
return false