优化页面

This commit is contained in:
pengxiaolong
2025-06-09 19:18:38 +08:00
parent d30589fd05
commit c5042d08c3
811 changed files with 2799 additions and 503 deletions

View File

@@ -8,15 +8,31 @@ const _sfc_main = {
return {
customData: {},
SenderData: {},
ReceiverData: {}
ReceiverData: {},
PkIDInfodata: {}
};
},
onLoad(options) {
this.customData = JSON.parse(options.customData);
this.getPkyourInfo();
this.getPkmineInfo();
this.getPkIDInfo();
},
methods: {
//根据当前消息ID查询pk信息
async getPkIDInfo() {
await components_request.request({
url: "pk/singleRecord",
method: "POST",
data: {
id: this.customData.id
},
userInfo: true
}).then((res) => {
this.PkIDInfodata = res.data;
common_vendor.index.__f__("log", "at pages/PKMessageprocessing/PKMessageprocessing.vue:177", this.PkIDInfodata);
});
},
//发布者
async getPkyourInfo() {
await components_request.request({
@@ -25,10 +41,10 @@ const _sfc_main = {
data: {
id: this.customData.pkIdA
},
userInfo: false
userInfo: true
}).then((res) => {
this.SenderData = res.data;
common_vendor.index.__f__("log", "at pages/PKMessageprocessing/PKMessageprocessing.vue:173", this.SenderData);
common_vendor.index.__f__("log", "at pages/PKMessageprocessing/PKMessageprocessing.vue:191", this.SenderData);
});
},
//被邀请者
@@ -39,10 +55,10 @@ const _sfc_main = {
data: {
id: this.customData.pkIdB
},
userInfo: false
userInfo: true
}).then((res) => {
this.ReceiverData = res.data;
common_vendor.index.__f__("log", "at pages/PKMessageprocessing/PKMessageprocessing.vue:187", this.ReceiverData);
common_vendor.index.__f__("log", "at pages/PKMessageprocessing/PKMessageprocessing.vue:205", this.ReceiverData);
});
},
goBack() {
@@ -52,25 +68,21 @@ const _sfc_main = {
},
formatDate: components_formatDate.formatDate,
async operation(status) {
common_vendor.index.__f__("log", "at pages/PKMessageprocessing/PKMessageprocessing.vue:198", "``````", this.customData);
common_vendor.index.__f__("log", "at pages/PKMessageprocessing/PKMessageprocessing.vue:199", status);
common_vendor.index.__f__("log", "at pages/PKMessageprocessing/PKMessageprocessing.vue:216", "``````", this.customData);
common_vendor.index.__f__("log", "at pages/PKMessageprocessing/PKMessageprocessing.vue:217", status);
await components_request.request({
url: "pk/updatePkStatus",
method: "POST",
data: {
pkIdA: this.customData.pkIdA,
pkIdB: this.customData.pkIdB,
userIdA: this.customData.userIdA,
userIdB: this.customData.userIdB,
pkTime: this.customData.pkTime,
pkNumber: this.customData.pkNumber,
id: this.customData.id,
pkStatus: status
},
userInfo: false
userInfo: true
}).then((res) => {
common_vendor.index.__f__("log", "at pages/PKMessageprocessing/PKMessageprocessing.vue:215", res.data);
common_vendor.index.__f__("log", "at pages/PKMessageprocessing/PKMessageprocessing.vue:228", res.data);
const Hinttext = status === 1 ? "接受邀请成功" : "拒绝邀请成功";
if (res.code === 200) {
this.getPkIDInfo();
common_vendor.wx$1.showToast({
title: Hinttext,
icon: "success",
@@ -127,9 +139,15 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
B: common_vendor.t($data.ReceiverData.coin),
C: common_assets._imports_5$2,
D: common_vendor.t($data.ReceiverData.pkNumber),
E: common_vendor.o$1(($event) => $options.operation(1)),
F: common_vendor.o$1(($event) => $options.operation(2))
});
E: $data.PkIDInfodata.pkStatus === 0
}, $data.PkIDInfodata.pkStatus === 0 ? {
F: common_vendor.o$1(($event) => $options.operation(1)),
G: common_vendor.o$1(($event) => $options.operation(2))
} : {}, {
H: $data.PkIDInfodata.pkStatus === 1
}, $data.PkIDInfodata.pkStatus === 1 ? {} : {}, {
I: $data.PkIDInfodata.pkStatus === 2
}, $data.PkIDInfodata.pkStatus === 2 ? {} : {});
}
const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-cadadfe7"]]);
wx.createPage(MiniProgramPage);