2023-12-19
This commit is contained in:
@@ -97,17 +97,16 @@
|
||||
this.$router.push({
|
||||
path: '/index'
|
||||
})
|
||||
this.loading = false
|
||||
this.loading = true
|
||||
// this.getUserInfo(response.data.loginId)
|
||||
window.sessionStorage.setItem('tokenName', response.data.tokenName)
|
||||
window.sessionStorage.setItem('tokenValue', response.data.tokenValue)
|
||||
}
|
||||
|
||||
}).catch(() => {
|
||||
this.loading = false
|
||||
this.loading = true
|
||||
})
|
||||
|
||||
this.loading = true
|
||||
},
|
||||
getUserInfo(id) {
|
||||
getUserById(id).then((response) => {
|
||||
|
||||
@@ -245,8 +245,8 @@
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
const index = this.formobj.goods.filter((item) => item.sid === sid)
|
||||
|
||||
const index = this.formobj.goods.findIndex((item) => item.goodsSid === sid)
|
||||
console.log("index》》》》", index)
|
||||
this.formobj.goods.splice(index, 1)
|
||||
})
|
||||
},
|
||||
@@ -335,9 +335,11 @@
|
||||
|
||||
saveOrUpdate() {
|
||||
console.log('>>>>>>>>>saveOrUpdate', this.formobj)
|
||||
this.submitdisabled = true
|
||||
req.saveGiftBag(this.formobj)
|
||||
.then(resp => {
|
||||
if (resp.success) {
|
||||
this.submitdisabled = false
|
||||
this.$message({
|
||||
showClose: true,
|
||||
type: 'success',
|
||||
@@ -345,10 +347,13 @@
|
||||
})
|
||||
this.handleReturn('true')
|
||||
} else {
|
||||
this.submitdisabled = false
|
||||
// 根据resp.code进行异常情况处理
|
||||
}
|
||||
})
|
||||
.catch(() => {})
|
||||
.catch(() => {
|
||||
this.submitdisabled = false
|
||||
})
|
||||
},
|
||||
handleReturn(isreload) {
|
||||
if (isreload === 'true') this.$emit('reloadlist')
|
||||
|
||||
@@ -155,9 +155,11 @@
|
||||
|
||||
<div
|
||||
style="width: 100%;display: flex;flex-direction: row;justify-content: center;margin-top: 20px;">
|
||||
<span
|
||||
<!-- <span
|
||||
style="background: #018AD2; color: #fff;padding: 5px 15px;border-radius: 5px;font-size: 16px;"
|
||||
@click="saveOrUpdate">发行</span>
|
||||
@click="saveOrUpdate">发行</span> -->
|
||||
|
||||
<el-button type="primary" size="small" :disabled="submitdisabled" @click="saveOrUpdate">发行</el-button>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -265,6 +267,7 @@
|
||||
data() {
|
||||
return {
|
||||
viewState: 1,
|
||||
submitdisabled:false,
|
||||
page: {
|
||||
total: 0, // 默认数据总数
|
||||
current: 1, // 默认开始页面
|
||||
@@ -497,9 +500,11 @@
|
||||
},
|
||||
saveOrUpdate() {
|
||||
console.log('>>>>>>>>>saveOrUpdate', this.formobj)
|
||||
this.submitdisabled = true
|
||||
req.generateCard(this.formobj)
|
||||
.then(resp => {
|
||||
if (resp.success) {
|
||||
this.submitdisabled = false
|
||||
this.$message({
|
||||
showClose: true,
|
||||
type: 'success',
|
||||
@@ -507,10 +512,13 @@
|
||||
})
|
||||
this.handleReturn('true')
|
||||
} else {
|
||||
this.submitdisabled = false
|
||||
// 根据resp.code进行异常情况处理
|
||||
}
|
||||
})
|
||||
.catch(() => {})
|
||||
.catch(() => {
|
||||
this.submitdisabled = false
|
||||
})
|
||||
},
|
||||
handleReturn(isreload) {
|
||||
if (isreload === 'true') this.$emit('reloadlist')
|
||||
|
||||
Reference in New Issue
Block a user