diff --git a/src/components/GuipRadio.vue b/src/components/GuipRadio.vue
index 5249497..07702ec 100644
--- a/src/components/GuipRadio.vue
+++ b/src/components/GuipRadio.vue
@@ -138,10 +138,16 @@ export default {
// 当前选项是否选中
const isSelected = this.getValue(option) === this.selectedValue;
- // 选中状态下优先返回selectedLabel,其次返回labelKey指定的属性
- return isSelected && option[this.selectedLabelKey]
- ? option[this.selectedLabelKey]
- : option[this.labelKey] || option;
+ // 选中状态下优先返回 selectedLabel
+ if (isSelected && option[this.selectedLabelKey]) {
+ return option[this.selectedLabelKey];
+ }
+
+ // 明确检查 labelKey 是否存在
+ if (typeof option === 'object' && this.labelKey in option) {
+ return option[this.labelKey];
+ }
+ return option;
},
getValue(option) {
// 处理对象格式的选项
@@ -149,7 +155,11 @@ export default {
return option.key;
}
- return option[this.valueKey] || option;
+ // 明确检查 valueKey 是否存在
+ if (typeof option === 'object' && this.valueKey in option) {
+ return option[this.valueKey];
+ }
+ return option;
},
// 判断选项是否禁用
isDisabled(key) {
diff --git a/src/components/pay/addPay.vue b/src/components/pay/addPay.vue
index 2dca743..23a9e8d 100644
--- a/src/components/pay/addPay.vue
+++ b/src/components/pay/addPay.vue
@@ -287,7 +287,7 @@ export default {
}).then(response => {
this.$nextTick(() => {
if (response.status) {
- this.init();
+ this.init(response.data);
this.$Message.success(response.info);
} else {
@@ -308,13 +308,12 @@ export default {
}).then(response => {
this.$nextTick(() => {
if (response.status) {
+ this.init(response.data.payid);
if (this.isPayPublic == 1) {
- this.init();
this.$Message.success(response.info);
} else {
- window.open(response.data.authurl, '_blank');
+ window.open(response.data.authurl, '_blank');
}
-
} else {
this.$Message.error(response.info);
}
@@ -328,7 +327,7 @@ export default {
}).then(response => {
this.$nextTick(() => {
if (response.status) {
- this.init();
+ this.init(response.data);
this.$Message.success(response.info);
} else {
this.$Message.error(response.info);
@@ -356,10 +355,24 @@ export default {
handleClick(tab, event) {
console.log(tab, event);
},
- init() {
+ init(payid) {
this.addPayDialogVisible = false;
this.$emit('update:visible', false);
this.resetForm(); // 重置表单
+
+ if(payid){
+ this.$http('POST', '/agentnew/ajax_get_payinfo', {
+ payid: payid,
+ }).then(response => {
+ this.$nextTick(() => {
+ if (response.status) {
+ this.$emit('update:data', response.data);
+ }
+ })
+ }).catch(error => {
+ console.error(error, 'error')
+ })
+ }
},
},watch: {
visible(newVal) {
diff --git a/src/components/site/addSiteStep/step2.vue b/src/components/site/addSiteStep/step2.vue
index 5aad894..bba2d9d 100644
--- a/src/components/site/addSiteStep/step2.vue
+++ b/src/components/site/addSiteStep/step2.vue
@@ -270,7 +270,7 @@
-