复制抢单账号

This commit is contained in:
zhonghua.li
2026-06-01 13:53:28 +08:00
parent 276cb7a2ad
commit 1cdea9052c
2 changed files with 42 additions and 2 deletions

View File

@@ -77,9 +77,10 @@
{{ formatDateTime(scope.row.updateTime) }} {{ formatDateTime(scope.row.updateTime) }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作" fixed="right" width="220"> <el-table-column label="操作" fixed="right" width="270">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button type="text" @click="handleEdit(scope.row)">编辑</el-button> <el-button type="text" @click="handleEdit(scope.row)">编辑</el-button>
<el-button type="text" @click="handleCopy(scope.row)">复制</el-button>
<el-button type="text" @click="handleCredential(scope.row)">凭证</el-button> <el-button type="text" @click="handleCredential(scope.row)">凭证</el-button>
<el-button type="text" style="color:#F56C6C;" @click="handleDelete(scope.row)">删除</el-button> <el-button type="text" style="color:#F56C6C;" @click="handleDelete(scope.row)">删除</el-button>
</template> </template>
@@ -536,6 +537,30 @@ export default {
this.$refs.dataForm && this.$refs.dataForm.clearValidate() this.$refs.dataForm && this.$refs.dataForm.clearValidate()
}) })
}, },
handleCopy(row) {
this.dialogTitle = '复制第三方集成配置'
this.isEdit = false
this.activeTab = 'basic'
this.form = {
...DEFAULT_FORM(),
...this.pickFormFields(row),
id: '',
tenantId: '',
adminBaseUrl: '',
webBaseUrl: '',
goodsApiToken: ''
}
this.originalCredential = {
cookie: '',
phpsid: '',
goodsApiToken: '',
goodsApiAppStr: ''
}
this.dialogVisible = true
this.$nextTick(() => {
this.$refs.dataForm && this.$refs.dataForm.clearValidate()
})
},
loadFormCredentials(tenantId) { loadFormCredentials(tenantId) {
if (!tenantId) return if (!tenantId) return
this.formCredentialLoading = true this.formCredentialLoading = true

View File

@@ -112,9 +112,10 @@
{{ formatDateTime(scope.row.updateTime) }} {{ formatDateTime(scope.row.updateTime) }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作" fixed="right" width="140"> <el-table-column label="操作" fixed="right" width="180">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button type="text" @click="handleEdit(scope.row)">编辑</el-button> <el-button type="text" @click="handleEdit(scope.row)">编辑</el-button>
<el-button type="text" @click="handleCopy(scope.row)">复制</el-button>
<el-button type="text" style="color:#F56C6C;" @click="handleDelete(scope.row)">删除</el-button> <el-button type="text" style="color:#F56C6C;" @click="handleDelete(scope.row)">删除</el-button>
</template> </template>
</el-table-column> </el-table-column>
@@ -528,6 +529,20 @@ export default {
this.$refs.dataForm && this.$refs.dataForm.clearValidate() this.$refs.dataForm && this.$refs.dataForm.clearValidate()
}) })
}, },
handleCopy(row) {
this.dialogTitle = '复制抢单账号'
this.isEdit = false
this.form = {
...DEFAULT_FORM(),
...this.pickFormFields(row),
id: '',
loginPassword: ''
}
this.dialogVisible = true
this.$nextTick(() => {
this.$refs.dataForm && this.$refs.dataForm.clearValidate()
})
},
pickFormFields(row) { pickFormFields(row) {
const fields = DEFAULT_FORM() const fields = DEFAULT_FORM()
Object.keys(fields).forEach((key) => { Object.keys(fields).forEach((key) => {