连点限制
This commit is contained in:
@@ -71,11 +71,6 @@
|
||||
</a-table>
|
||||
</div>
|
||||
</a-spin>
|
||||
|
||||
<template slot="footer">
|
||||
<a-button @click="handleCancel">关闭</a-button>
|
||||
<a-button @click="handleOk" type="primary" v-preventclick>确定</a-button>
|
||||
</template>
|
||||
</j-modal>
|
||||
</template>
|
||||
|
||||
@@ -197,8 +192,13 @@ export default {
|
||||
},
|
||||
methods: {
|
||||
handleOk() {
|
||||
if (this.confirmLoading) {
|
||||
return
|
||||
}
|
||||
this.confirmLoading = true
|
||||
if (this.selectedRowKeys.length === 0) {
|
||||
this.$message.warn('请至少选择一个项目')
|
||||
this.confirmLoading = false
|
||||
return
|
||||
}
|
||||
let projectIds = this.selectedRowKeys.join(',')
|
||||
@@ -214,6 +214,10 @@ export default {
|
||||
} else {
|
||||
this.$message.warn(res.message)
|
||||
}
|
||||
}).finally(() => {
|
||||
setTimeout(() => {
|
||||
this.confirmLoading = false
|
||||
}, 1000)
|
||||
})
|
||||
},
|
||||
handleCancel() {
|
||||
|
||||
Reference in New Issue
Block a user