You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
apply-assistant-v3/root/person/pwdForget.vue

179 lines
5.4 KiB
Vue

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

<template>
<div class="g_bg_page g_pl_10 g_pr_10">
<div class="g_h_20"></div>
<div class="g_mb_10 g_fs_18 g_pl_10">{{ beFllowAgencyInfo.inviteUserName || "-" }}邀请您加入他的团队</div>
<div class="r_box g_pt_24 g_text_c g_pl_20 g_pr_20">
<div class="g_pb_16">
<img class="g_h_80 g_w_80 g_radius_50" :src="beFllowAgencyInfo.logo || 'https://matripe-cms.oss-cn-beijing.aliyuncs.com/dailibaoming/APP/default.svg'" alt="" />
<div class="g_fs_20 g_mt_12 g_mb_12 g_fw_600">
{{ beFllowAgencyInfo.agencyName || "-" }}
</div>
<div class="g_c_9 g_fs_14">
{{ beFllowAgencyInfo.desp || "-" }}
</div>
</div>
<div class="g_flex_row_between g_pb_12 g_pt_12" style="border-top: 1rpx dotted #eee">
<div v-for="item in numList" class="g_flex_row_center flex_end">
<div class="g_fs_20 g_fw_600">{{ item.num }}</div>
<div class="g_fs_14 g_c_9">{{ item.label }}</div>
</div>
</div>
</div>
<div class="g_mt_30">
<div class="g_fs_18 g_mb_8 g_pl_12">填写企业简称:</div>
<div class="r_box g_pl_10">
<u-input v-model="agencyInfo.fullName" height="88" placeholder="区域+名称,如:上海发财劳务"></u-input>
</div>
<div class="g_fs_12 g_c_9 g_mt_6 g_pl_12">设置后系统将自动创建团队并关注该发单号,您作为创建人可在我的页面管理团队。</div>
</div>
<div class="g_mt_84">
<quickLogin @successLogin="successLogin" v-if="!agencyInfo.id">
<g-button btnText="申请关注" type="primary" class=""></g-button>
</quickLogin>
<div v-else>
<g-button v-if="beFllowAgencyInfo.recordStatus == 1" btnText="已关注" type="disabled" class=""></g-button>
<g-button v-else-if="beFllowAgencyInfo.recordStatus == 2" btnText="互相关注" type="disabled" class=""></g-button>
<g-button v-else-if="(beFllowAgencyInfo.recordStatus == 3 || beFllowAgencyInfo.recordStatus == 4) && !isSelf" btnText="申请关注" type="primary" class="" @clickBtn="applyAdd"></g-button>
<g-button v-else-if="beFllowAgencyInfo.recordStatus == 5" btnText="等待通过" type="disabled" class=""></g-button>
<g-button v-else-if="beFllowAgencyInfo.recordStatus == 6 && !isSelf" btnText="申请关注" type="primary" class="" @clickBtn="applyAdd"></g-button>
</div>
</div>
</div>
</template>
<script>
import quickLogin from "../../components/quickLogin.vue";
export default {
components: {
quickLogin,
},
data() {
return {
beFllowAgencyInfo: {
agencyName: "",
fullName: "",
},
info: {},
agencyInfo: {
fullName: "",
}, // 登陆者的代理信息
userInfo: {
userName: "",
userId: "",
},
numList: [
{ label: "总职位", num: "-" },
{ label: "最近更新", num: "-" },
{ label: "粉丝", num: "-" },
],
inviteUserId: "",
uid: "",
ing: false,
scene: "",
isSelf: false,
};
},
onLoad(options) {
let that = this;
console.log(options);
options.scene = "id=3087_101125";
if (options.scene) {
console.log("XXXXXXXXXXXX");
//扫小程序码携带参数
this.scene = options.scene;
var sceneStr = decodeURIComponent(options.scene);
var sceneJson = this.G.sceneToJson(sceneStr);
console.log("sceneJson===", sceneJson);
this.inviteUserId = sceneJson.id.split("_")[1]; //被关注团队的邀请人id
this.uid = sceneJson.id.split("_")[0]; // 被关注团队的id
that.G.Get("/checkUserLogin", {}, (res) => {
console.log("checkUserLogin", res);
if (res) {
that.getAgencyInfo().then(() => {
that.getAgencyById();
});
} else {
that.getAgencyById();
}
});
}
},
created() {},
methods: {
applyAdd() {
let that = this;
if (!this.agencyInfo.fullName) {
uni.showToast({
title: "请输入企业简称",
icon: "none",
});
return;
}
if (this.ing) {
return;
}
that.ing = true;
let _code = 1; // 账号搜索
// if (this.from == "friend") {
// _code = 2; // 名片分享
// } else {
if (this.scene) {
_code = 3; // 扫一扫
} else {
_code = 1; // 账号搜索
}
// }
this.G.Get(this.api.bind_subscribeSubmit + "/" + that.uid, { agencyId: that.agencyInfo.id, agencyName: that.agencyInfo.fullName, source: _code, remark: " " }, (res) => {
uni.showToast({
title: "申请成功",
icon: "none",
});
uni.navigateTo({
url: "/root/person/inviteFollowSuccess",
});
// that.checkHasApply();
console.log(res);
});
},
getAgencyById() {
let that = this;
this.G.Get(this.api.order_getAgencyByIdForApply, { agencyId: that.uid, inviteUserId: this.inviteUserId }, (res) => {
console.log("resresresresresres", res);
that.beFllowAgencyInfo = res;
if (res.id == that.agencyInfo.id) {
that.isSelf = true;
}
that.numList = [
{ label: "总职位", num: res.jobNum },
{ label: "最近更新", num: res.recruitmentJobNum },
{ label: "粉丝", num: res.downNum },
];
});
},
successLogin(e) {
console.log("successLogin", e);
this.getAgencyInfo();
this.getAgencyById();
this.applyAdd();
},
getAgencyInfo() {
let that = this;
return new Promise((reso, reject) => {
that.G.Get(that.api.login_agencyInfo, {}, (aRes) => {
console.log("获取团队信息:", aRes);
that.agencyInfo = { ...aRes.agency, fullName: aRes.agency.fullName ? aRes.agency.fullName : that.agencyInfo.fullName };
uni.setStorageSync("agencyInfo", aRes.agency);
reso();
});
});
},
},
};
</script>
<style></style>