hldy_xcx/unpackage/dist/dev/mp-weixin/pages/oldmanindex/companyyaoqing.js

107 lines
3.5 KiB
JavaScript
Raw Normal View History

2025-09-15 17:23:33 +08:00
"use strict";
const common_vendor = require("../../common/vendor.js");
const pages_oldmanindex_api = require("./api.js");
if (!Math) {
queren();
}
const queren = () => "./queren.js";
const _sfc_main = /* @__PURE__ */ common_vendor.defineComponent({
__name: "companyyaoqing",
setup(__props) {
const hulijigouArray = common_vendor.ref([]);
const hulitarget = common_vendor.ref(-1);
common_vendor.ref(false);
common_vendor.ref("");
const querenshow = common_vendor.ref(false);
const buttonOpen = common_vendor.ref(false);
const goBack = () => {
common_vendor.index.navigateBack();
};
const search = () => {
buttonOpen.value = false;
hulitarget.value = -1;
pages_oldmanindex_api.getInvited(common_vendor.index.getStorageSync("openid")).then((res) => {
if (res.success) {
hulijigouArray.value = res.result;
}
});
};
common_vendor.ref(false);
const saveitem = common_vendor.ref({
employeesId: "",
orgCode: ""
});
const changeStatus = (item, status) => {
if (!status) {
querenshow.value = true;
saveitem.value = {
employeesId: item.employeesId,
orgCode: item.orgCode
};
return;
}
let data = {
employeeId: item.employeesId,
status: status ? 2 : 3,
orgCode: item.orgCode
};
pages_oldmanindex_api.invitedConfirm(data).then((res) => {
if (res.success) {
search();
}
});
};
const querensecond = () => {
querenshow.value = false;
let data = {
employeeId: saveitem.value.employeesId,
status: 3,
orgCode: saveitem.value.orgCode
};
pages_oldmanindex_api.invitedConfirm(data).then((res) => {
if (res.success) {
search();
}
});
};
search();
return (_ctx, _cache) => {
return common_vendor.e({
a: common_vendor.o(goBack),
b: !hulijigouArray.value.length
}, !hulijigouArray.value.length ? {} : {}, {
c: common_vendor.f(hulijigouArray.value, (item, index, i0) => {
return common_vendor.e({
a: common_vendor.t(item.departName),
b: common_vendor.t(item.comLegalPerson),
c: common_vendor.t(item.tel),
d: item.applyStatus === `1`
}, item.applyStatus === `1` ? {} : {}, {
e: item.applyStatus === `2`
}, item.applyStatus === `2` ? {} : {}, {
f: item.applyStatus === `3`
}, item.applyStatus === `3` ? {} : {}, {
g: common_vendor.t(item.comRegisterAddress),
h: item.applyStatus === `1`
}, item.applyStatus === `1` ? {
i: common_vendor.o(($event) => changeStatus(item, true), index),
j: common_vendor.o(($event) => changeStatus(item, false), index)
} : {}, {
k: index,
l: hulitarget.value === index ? "4rpx solid #0093FF" : "none",
m: item.applyStatus == 1 ? "370rpx" : "330rpx"
});
}),
d: common_vendor.o(($event) => querenshow.value = false),
e: common_vendor.o(querensecond),
f: common_vendor.p({
show: querenshow.value
})
});
};
}
});
const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["__scopeId", "data-v-2b078f5f"]]);
wx.createPage(MiniProgramPage);
//# sourceMappingURL=../../../.sourcemap/mp-weixin/pages/oldmanindex/companyyaoqing.js.map