hldy_xcx/unpackage/dist/dev/mp-weixin/pages/login/workjoin.js

85 lines
3.1 KiB
JavaScript
Raw Normal View History

2025-06-27 08:56:14 +08:00
"use strict";
const common_vendor = require("../../common/vendor.js");
const pages_addjigou_api_addjigou = require("../addjigou/api/addjigou.js");
const _sfc_main = {
__name: "workjoin",
setup(__props) {
const type = common_vendor.ref(0);
const workArray = common_vendor.ref([]);
const special = common_vendor.ref(false);
common_vendor.onLoad((options) => {
type.value = options.type || "";
common_vendor.index.getStorage({
key: "openid",
success: function(res) {
if (type.value == 1) {
pages_addjigou_api_addjigou.getMessageList(res.data).then((res2) => {
workArray.value = res2.result;
});
} else if (type.value == 3) {
pages_addjigou_api_addjigou.getMessageListsuccess(res.data).then((res2) => {
workArray.value = res2.result;
});
type.value = `1`;
special.value = true;
}
}
});
});
common_vendor.onPullDownRefresh(() => {
common_vendor.index.getStorage({
key: "openid",
success: function(res) {
if (type.value) {
if (special.value) {
pages_addjigou_api_addjigou.getMessageListsuccess(res.data).then((res2) => {
workArray.value = res2.result;
});
} else {
pages_addjigou_api_addjigou.getMessageList(res.data).then((res2) => {
workArray.value = res2.result;
});
}
}
}
});
common_vendor.index.stopPullDownRefresh();
});
const again = (item) => {
common_vendor.index.__f__("log", "at pages/login/workjoin.vue:103", "????", item);
common_vendor.index.setStorageSync("baddata", item);
common_vendor.index.setStorageSync("specicalid", item.id);
common_vendor.index.setStorageSync("backhuancun", {});
common_vendor.index.navigateTo({
url: `/pages/addjigou/name`
});
};
const jumpToAll = (element) => {
common_vendor.index.navigateTo({
url: `/pages/addjigou/all?element=${JSON.stringify(element)}`
});
};
return (_ctx, _cache) => {
return {
a: common_vendor.f(workArray.value, (item, index, i0) => {
return common_vendor.e({
a: common_vendor.t(item.comName),
b: common_vendor.t(item.updateTime),
c: common_vendor.t(item.status == 1 ? "审核中" : item.status == 2 ? `审核完成` : item.status == 3 ? `驳回` : `待提交`),
d: common_vendor.t(item.status == 3 ? `,驳回备注:${item.content}` : ``),
e: item.status == 3
}, item.status == 3 ? {
f: common_vendor.o(($event) => again(item), index)
} : {}, {
g: common_vendor.o(($event) => jumpToAll(item), index),
h: index
});
})
};
};
}
};
const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["__scopeId", "data-v-808c8183"]]);
wx.createPage(MiniProgramPage);
//# sourceMappingURL=../../../.sourcemap/mp-weixin/pages/login/workjoin.js.map