cyl/master-apply
wangxia 14 hours ago
parent 3912e7a63f
commit 6510a4d62b

@ -464,7 +464,7 @@ export default {
let that = this; let that = this;
if (uni.getStorageSync("apply-token")) { if (uni.getStorageSync("apply-token")) {
that.G.Get(that.api.bind_getApplyNum, {}, (res) => { that.G.Get(that.api.bind_getApplyNum, {}, (res) => {
console.log("获取待处理数量:", res); // console.log("", res);
that.G.Get(that.api.person_applyNum, {}, (applyNum) => { that.G.Get(that.api.person_applyNum, {}, (applyNum) => {
if (res.approvePassHasNotRed + applyNum > 0) { if (res.approvePassHasNotRed + applyNum > 0) {
uni.setTabBarBadge({ uni.setTabBarBadge({

@ -84,7 +84,7 @@
@clickItem="handleClickNus" @clickItem="handleClickNus"
/> --> /> -->
</view> </view>
<view class="g_mt_10 g_position_rela" v-if="userInfo.admin || isTeamleader"> <view class="g_mt_10 g_position_rela u-skeleton" v-if="userInfo.admin || isTeamleader">
<view class="g_radius_50 g_text_c" style="position: absolute; right: 16px; top: 5px; color: #fff; background-color: #ff4400; font-size: 12px; min-width: 16px" v-if="applyNum > 0"> <view class="g_radius_50 g_text_c" style="position: absolute; right: 16px; top: 5px; color: #fff; background-color: #ff4400; font-size: 12px; min-width: 16px" v-if="applyNum > 0">
{{ applyNum }} {{ applyNum }}
</view> </view>

File diff suppressed because it is too large Load Diff

@ -82,9 +82,9 @@
<div class="g_flex_1"> <div class="g_flex_1">
<rh-button primaryColor='#00b666' btnText="已关注发单号" size="auto" @clickBtn="handleCancel" type="noStyle" class></rh-button> <rh-button primaryColor='#00b666' btnText="已关注发单号" size="auto" @clickBtn="handleCancel" type="noStyle" class></rh-button>
</div> </div>
<div class="g_ml_16 g_flex_1"> <!-- <div class="g_ml_16 g_flex_1">
<rh-button primaryColor='#00b666' btnText="联系客服" class="" type="noStyle" size="auto" @clickBtn="goIm"></rh-button> <rh-button primaryColor='#00b666' btnText="联系客服" class="" type="noStyle" size="auto" @clickBtn="goIm"></rh-button>
</div> </div> -->
<!-- <div style="width:calc((100vw - 50px) / 2);"> <!-- <div style="width:calc((100vw - 50px) / 2);">
<rh-button primaryColor='#00b666' btnText="联系客服" size="auto" type="disabled" class></rh-button> <rh-button primaryColor='#00b666' btnText="联系客服" size="auto" type="disabled" class></rh-button>
</div>--> </div>-->
@ -94,9 +94,9 @@
<div class="g_flex_1"> <div class="g_flex_1">
<rh-button primaryColor='#00b666' btnText="互相关注" size="auto" type="noStyle" @clickBtn="handleCancel" class></rh-button> <rh-button primaryColor='#00b666' btnText="互相关注" size="auto" type="noStyle" @clickBtn="handleCancel" class></rh-button>
</div> </div>
<div class="g_ml_16 g_flex_1"> <!-- <div class="g_ml_16 g_flex_1">
<rh-button primaryColor='#00b666' btnText="联系客服" class="" type="noStyle" size="auto" @clickBtn="goIm"></rh-button> <rh-button primaryColor='#00b666' btnText="联系客服" class="" type="noStyle" size="auto" @clickBtn="goIm"></rh-button>
</div> </div> -->
</div> </div>
<div style="width: calc(100vw - 40px)" v-else-if="(info.recordStatus == 3 || info.recordStatus == 4) && !isSelf"> <div style="width: calc(100vw - 40px)" v-else-if="(info.recordStatus == 3 || info.recordStatus == 4) && !isSelf">

@ -9,9 +9,9 @@
<view class="g_flex_1 g_mr_12"> <view class="g_flex_1 g_mr_12">
<rh-button primaryColor='#00b666' btnText="继续报名" type="primary" size="small_auto" @clickBtn="goReturn" /> <rh-button primaryColor='#00b666' btnText="继续报名" type="primary" size="small_auto" @clickBtn="goReturn" />
</view> </view>
<view class="g_flex_1"> <!-- <view class="g_flex_1">
<rh-button primaryColor='#00b666' btnText="联系客服" size="small_auto" @clickBtn="sendJobInfo" /> <rh-button primaryColor='#00b666' btnText="联系客服" size="small_auto" @clickBtn="sendJobInfo" />
</view> </view> -->
</view> </view>
<view class="g_flex_row_center"> <view class="g_flex_row_center">
<view class="g_c_sub g_mt_16 g_fs_14 g_text_c g_w_all g_fw_700" style="position: fixed; bottom: 56px; width: calc(100vw - 20px); left: 50%; transform: translateX(-50%)" hover-class="thover" @click="goList"></view> <view class="g_c_sub g_mt_16 g_fs_14 g_text_c g_w_all g_fw_700" style="position: fixed; bottom: 56px; width: calc(100vw - 20px); left: 50%; transform: translateX(-50%)" hover-class="thover" @click="goList"></view>

@ -231,11 +231,20 @@ export default {
}; };
this.G.Post(this.api.order_userApplyApprove, params, (res) => { this.G.Post(this.api.order_userApplyApprove, params, (res) => {
console.log(res); console.log(res);
that.applyList.forEach(() => { if (that.applyList.far.length > 0) {
that.applyList.far.forEach((item) => {
if (that.currentUser.id == item.id) { if (that.currentUser.id == item.id) {
item.status = 1; item.status = 1;
} }
}); });
}
if (that.applyList.near.length > 0) {
that.applyList.near.forEach((item) => {
if (that.currentUser.id == item.id) {
item.status = 1;
}
});
}
uni.showToast({ uni.showToast({
title: "操作成功", title: "操作成功",
icon: "none", icon: "none",

@ -4,7 +4,7 @@
<div class="g_flex_column_between" :style="{ 'min-height': `calc(100vh - ${0}px)` }"> <div class="g_flex_column_between" :style="{ 'min-height': `calc(100vh - ${0}px)` }">
<div class> <div class>
<div class="g_h_10"></div> <div class="g_h_10"></div>
<div class="g_flex_row_start g_bg_f g_mb_10" style="padding: 12px 16px" @click="goPage('/root/person/applyManage')" v-if="applyNum !== 0"> <div class="g_flex_row_start g_bg_f g_mb_10" style="padding: 12px 16px" @click="goPage('/root/person/applyManage')" v-if="applyNum == 0">
<div class="g_mr_16 g_w_48 g_h_48 t-icon t-icon-wodetuandui" style="background-repeat: no-repeat"></div> <div class="g_mr_16 g_w_48 g_h_48 t-icon t-icon-wodetuandui" style="background-repeat: no-repeat"></div>
<div> <div>
<div class="g_fs_18">新的成员</div> <div class="g_fs_18">新的成员</div>

@ -1,5 +1,5 @@
let data = { let data = {
setReg($str, $type = 'default') { setReg ($str, $type = 'default') {
if ($type == 'tel') { if ($type == 'tel') {
return /^1[3-9]\d{9}$/.test($str); return /^1[3-9]\d{9}$/.test($str);
} }
@ -12,7 +12,7 @@ let data = {
* @params returnFeeType 类型 * @params returnFeeType 类型
* @params $type 1共享 0 普通 * @params $type 1共享 0 普通
*/ */
setReturnFee(returnFee, returnFeeType, $type) { setReturnFee (returnFee, returnFeeType, $type) {
// // console.log('here'); // // console.log('here');
let servetype = '-', let servetype = '-',
$num = 1; $num = 1;
@ -41,7 +41,7 @@ let data = {
return servetype return servetype
}, },
/* 对象重组成字符串 */ /* 对象重组成字符串 */
objToStr(obj = {}, type = 'url') { objToStr (obj = {}, type = 'url') {
let str = ''; let str = '';
if (type == 'url') { if (type == 'url') {
str = Object.keys(obj) str = Object.keys(obj)
@ -54,7 +54,7 @@ let data = {
} }
return str; return str;
}, },
isLogin() { isLogin () {
let that = this; let that = this;
if (!uni.getStorageSync("apply-token")) { if (!uni.getStorageSync("apply-token")) {
uni.reLaunch({ uni.reLaunch({
@ -65,7 +65,7 @@ let data = {
return true; return true;
} }
}, },
setNavStyle($form = 'default') { setNavStyle ($form = 'default') {
if ($form == 'home') { if ($form == 'home') {
uni.setNavigationBarColor({ uni.setNavigationBarColor({
backgroundColor: "#fff", backgroundColor: "#fff",
@ -73,7 +73,7 @@ let data = {
}) })
} }
}, },
getInfoByIDcard(idCard) { getInfoByIDcard (idCard) {
let info = {} let info = {}
let birthday let birthday
if (idCard.length !== 15 && idCard.length !== 18) { if (idCard.length !== 15 && idCard.length !== 18) {
@ -104,7 +104,7 @@ let data = {
// console.log('info', info); // console.log('info', info);
return info return info
}, },
shareFun( shareFun (
path = "/pages/home/index", path = "/pages/home/index",
image = "", image = "",
title = "报名助手" title = "报名助手"
@ -118,7 +118,7 @@ let data = {
// console.log('分享数据:', params) // console.log('分享数据:', params)
return params; return params;
}, },
isValidIdCard(idCard) { isValidIdCard (idCard) {
const idCardRegex = /^[1-9]\d{5}(18|19|20)\d{2}(0[1-9]|1[0-2])(0[1-9]|[1-2][0-9]|3[0-1])\d{3}[\dXx]$/; const idCardRegex = /^[1-9]\d{5}(18|19|20)\d{2}(0[1-9]|1[0-2])(0[1-9]|[1-2][0-9]|3[0-1])\d{3}[\dXx]$/;
if (!idCardRegex.test(idCard)) { if (!idCardRegex.test(idCard)) {
return false; return false;
@ -135,7 +135,7 @@ let data = {
const checkCode = checkCodeList[sum % 11]; const checkCode = checkCodeList[sum % 11];
return checkCode === idCard[17].toUpperCase(); return checkCode === idCard[17].toUpperCase();
}, },
sceneToJson(sceneStr) { sceneToJson (sceneStr) {
let json = {}; let json = {};
let array = sceneStr.split(","); let array = sceneStr.split(",");
array.forEach((item) => { array.forEach((item) => {
@ -146,7 +146,7 @@ let data = {
}); });
return json; return json;
}, },
handleConfirm( handleConfirm (
options options
) { ) {
// console.log(options); // console.log(options);
@ -158,7 +158,7 @@ let data = {
confirmColor: options.confirmColor || "#576b95", confirmColor: options.confirmColor || "#576b95",
cancelColor: options.cancelColor || "#000", cancelColor: options.cancelColor || "#000",
cancelText: options.cancelText || "取消", cancelText: options.cancelText || "取消",
success(res) { success (res) {
options.success(res); options.success(res);
} }
}); });
@ -168,7 +168,7 @@ let data = {
* @param item * @param item
* @returns * @returns
*/ */
isNotEmptyCheck(value) { isNotEmptyCheck (value) {
return !this.isEmptyCheck(value); return !this.isEmptyCheck(value);
}, },
/** /**
@ -176,14 +176,14 @@ let data = {
* @param item * @param item
* @returns * @returns
*/ */
isEmptyCheck(value) { isEmptyCheck (value) {
if (value == null || value === "" || value == "null" || typeof value == "undefined") { if (value == null || value === "" || value == "null" || typeof value == "undefined") {
return true; return true;
} }
return false; return false;
}, },
getDistanceName(distance) { getDistanceName (distance) {
let str = ""; let str = "";
if (this.isNotEmptyCheck(distance)) { if (this.isNotEmptyCheck(distance)) {
@ -198,7 +198,7 @@ let data = {
return str; return str;
}, },
getPointTime(str = '', type = 'default') { getPointTime (str = '', type = 'default') {
let that = this; let that = this;
let year, month, date, hours, minute, second; let year, month, date, hours, minute, second;
let time; let time;
@ -267,7 +267,7 @@ let data = {
} else { } else {
// 周一~周六 // 周一~周六
if (str == 'first') { if (str == 'first') {
function getPreviousSundayDate() { function getPreviousSundayDate () {
const today = new Date(); const today = new Date();
const dayOfWeek = today.getDay(); const dayOfWeek = today.getDay();
const daysSinceLastSunday = (dayOfWeek + 6) % 7 + 8; const daysSinceLastSunday = (dayOfWeek + 6) % 7 + 8;
@ -278,7 +278,7 @@ let data = {
time = new Date(getPreviousSundayDate()); time = new Date(getPreviousSundayDate());
type = "YY--MM--DD" type = "YY--MM--DD"
} else if (str == 'last') { } else if (str == 'last') {
function getPreviousSaturdayDate() { function getPreviousSaturdayDate () {
const today = new Date(); const today = new Date();
const dayOfWeek = today.getDay(); const dayOfWeek = today.getDay();
const daysSinceLastSaturday = (dayOfWeek + 6) % 7 + 2; const daysSinceLastSaturday = (dayOfWeek + 6) % 7 + 2;
@ -302,7 +302,7 @@ let data = {
time = new Date(new Date().getFullYear(), new Date().getMonth() - 1 + 1, 0); time = new Date(new Date().getFullYear(), new Date().getMonth() - 1 + 1, 0);
} }
type = "YY--MM--DD" type = "YY--MM--DD"
} else if (type == "first-week") {} else { } else if (type == "first-week") { } else {
// 时间戳 // 时间戳
time = str ? new Date(str) : new Date(new Date().getTime()); time = str ? new Date(str) : new Date(new Date().getTime());
} }
@ -348,7 +348,7 @@ let data = {
} }
return result; return result;
}, },
disposeJobListData(jobList) { disposeJobListData (jobList) {
let that = this; let that = this;
if (jobList !== undefined) { if (jobList !== undefined) {
if (Array.isArray(jobList)) { if (Array.isArray(jobList)) {
@ -556,7 +556,7 @@ let data = {
} }
return jobList; return jobList;
}, },
getjobRequestLabelNamesArray(jobRequestLabelNames) { getjobRequestLabelNamesArray (jobRequestLabelNames) {
if (this.isNotEmptyCheck(jobRequestLabelNames)) { if (this.isNotEmptyCheck(jobRequestLabelNames)) {
return jobRequestLabelNames.split(", "); return jobRequestLabelNames.split(", ");
} }
@ -565,7 +565,7 @@ let data = {
/** /**
* 根据工种类型ID获取名称 * 根据工种类型ID获取名称
*/ */
getWorkTypeById(id) { getWorkTypeById (id) {
let str = ""; let str = "";
let array = this.workTypeArray(); let array = this.workTypeArray();
array.forEach((item) => { array.forEach((item) => {
@ -578,7 +578,7 @@ let data = {
/** /**
* 工种类型 * 工种类型
*/ */
workTypeArray() { workTypeArray () {
let workTypeArray = [{ let workTypeArray = [{
id: 0, id: 0,
name: "全职", name: "全职",
@ -617,7 +617,7 @@ let data = {
]; ];
return workTypeArray; return workTypeArray;
}, },
getGenderByMinAge(res) { getGenderByMinAge (res) {
// // console.log("==================", res); // // console.log("==================", res);
let str = ""; let str = "";
if (res.minAgeMan && res.minAgeWoman) { if (res.minAgeMan && res.minAgeWoman) {
@ -629,7 +629,7 @@ let data = {
} }
return str; return str;
}, },
toGetAddressv3($list) { toGetAddressv3 ($list) {
if ($list && $list.length > 0) { if ($list && $list.length > 0) {
$list.forEach(item => { $list.forEach(item => {
let storeDistrict = item.storeAddr || item.storeDistrict; let storeDistrict = item.storeAddr || item.storeDistrict;
@ -640,13 +640,13 @@ let data = {
return []; return [];
} }
}, },
setJobInfoPositionv3(str) { setJobInfoPositionv3 (str) {
str = str.replace(//g, ''); str = str.replace(//g, '');
var reg = /.+?(省|市|自治区|自治州|县|区)/g; // 省市区的正则 var reg = /.+?(省|市|自治区|自治州|县|区)/g; // 省市区的正则
let matches = str.match(reg); let matches = str.match(reg);
let result = ''; let result = '';
function getStr(str) { function getStr (str) {
if (matches[0].includes('省') || matches[0].includes('自治区') || matches[0].includes('自治州')) { if (matches[0].includes('省') || matches[0].includes('自治区') || matches[0].includes('自治州')) {
if (matches[1].includes('市') && matches[2].includes('市')) { if (matches[1].includes('市') && matches[2].includes('市')) {
result = `${matches[0]}${matches[2]}`; result = `${matches[0]}${matches[2]}`;
@ -695,7 +695,7 @@ let data = {
return result; return result;
}, },
getSalaryClassifyValueHtml(salaryClassify, salaryClassifyValue, salaryClassifyValue1) { getSalaryClassifyValueHtml (salaryClassify, salaryClassifyValue, salaryClassifyValue1) {
var salary = this.moneyToFixed(salaryClassifyValue); var salary = this.moneyToFixed(salaryClassifyValue);
var salary1 = this.moneyToFixed(salaryClassifyValue1); var salary1 = this.moneyToFixed(salaryClassifyValue1);
@ -721,7 +721,7 @@ let data = {
} }
}, },
/* 同步 */ /* 同步 */
moneyToFixed(money, fixed = 2, multiplicator = 100) { moneyToFixed (money, fixed = 2, multiplicator = 100) {
if (money != 0 && money != null && money != "" && money != undefined) { if (money != 0 && money != null && money != "" && money != undefined) {
return this.cutZero(new Number(money / multiplicator).toFixed(fixed)); return this.cutZero(new Number(money / multiplicator).toFixed(fixed));
} else { } else {
@ -729,7 +729,7 @@ let data = {
} }
}, },
/* 同步 */ /* 同步 */
cutZero(old) { cutZero (old) {
//拷贝一份 返回去掉零的新串 //拷贝一份 返回去掉零的新串
let newstr = old; let newstr = old;
//循环变量 小数部分长度 //循环变量 小数部分长度
@ -756,7 +756,7 @@ let data = {
} }
return old; return old;
}, },
setDeadLine(time, type) { setDeadLine (time, type) {
if (type) { if (type) {
// 交付助手的倒计时 // 交付助手的倒计时
let differenceTime = new Date().getTime() - new Date(time).getTime() let differenceTime = new Date().getTime() - new Date(time).getTime()
@ -832,7 +832,7 @@ let data = {
/** /**
* 文字绘制 * 文字绘制
*/ */
fillTextLineBreak(ctx, text, x, y, lw, lh, color = "#333", font = "32", weight = "500", align = "left") { fillTextLineBreak (ctx, text, x, y, lw, lh, color = "#333", font = "32", weight = "500", align = "left") {
var i = 0; var i = 0;
var n = 0; var n = 0;
var r = -1; var r = -1;
@ -851,7 +851,7 @@ let data = {
} }
}, },
// 计算总体宽度 // 计算总体宽度
calculateTotalWidth(ctx, segments) { calculateTotalWidth (ctx, segments) {
let totalWidth = 0; let totalWidth = 0;
segments.forEach((segment) => { segments.forEach((segment) => {
// console.log('segment', segment); // console.log('segment', segment);
@ -864,7 +864,7 @@ let data = {
return totalWidth; return totalWidth;
}, },
// 绘制单行居中的拼接文本 // 绘制单行居中的拼接文本
drawCenteredText(ctx, x, y, textSegments) { drawCenteredText (ctx, x, y, textSegments) {
// 计算总宽度 // 计算总宽度
const totalWidth = this.calculateTotalWidth(ctx, textSegments); const totalWidth = this.calculateTotalWidth(ctx, textSegments);
@ -896,7 +896,7 @@ let data = {
/** /**
* 背景图绘制 * 背景图绘制
*/ */
roundRect(ctx, img, bg_x, bg_y, bg_w, bg_h, bg_r) { roundRect (ctx, img, bg_x, bg_y, bg_w, bg_h, bg_r) {
// 开始绘制 // 开始绘制
ctx.save(); ctx.save();
ctx.beginPath(); ctx.beginPath();
@ -909,7 +909,7 @@ let data = {
// 恢复之前保存的绘图上下文 // 恢复之前保存的绘图上下文
ctx.restore(); ctx.restore();
}, },
roundRect_yuan(ctx, x, y, size, color) { roundRect_yuan (ctx, x, y, size, color) {
// 开始绘制 // 开始绘制
ctx.save(); // 保存 ctx.save(); // 保存
@ -924,7 +924,7 @@ let data = {
ctx.restore(); ctx.restore();
}, },
roundRect1(ctx, x, y, w, h, r, color) { roundRect1 (ctx, x, y, w, h, r, color) {
//绘制圆角矩形(无填充色)) //绘制圆角矩形(无填充色))
ctx.save(); ctx.save();
ctx.fillStyle = color; ctx.fillStyle = color;
@ -937,7 +937,7 @@ let data = {
ctx.closePath(); ctx.closePath();
}, },
// 绘制折线 // 绘制折线
setZigzag(ctx) { setZigzag (ctx) {
// 定义折线的点坐标 (形成90度角) // 定义折线的点坐标 (形成90度角)
const points = [{ const points = [{
x: 100, x: 100,
@ -1027,7 +1027,7 @@ let data = {
/** /**
* canvas绘图 end * canvas绘图 end
*/ */
policyNumToHanZi(i, type = 'other') { policyNumToHanZi (i, type = 'other') {
let pickerStr; let pickerStr;
if (i <= 9) { if (i <= 9) {
switch (i) { switch (i) {
@ -1068,6 +1068,34 @@ let data = {
} }
return pickerStr return pickerStr
}, },
/**
* 根据薪资类型和薪资值获取薪资展示
*/
getSalaryClassifyValue (salaryClassify, salaryClassifyValue, salaryClassifyValue1) {
var salary = this.moneyToFixed(salaryClassifyValue);
var salary1 = this.moneyToFixed(salaryClassifyValue1);
if (salaryClassify == 0) {
return `${salary}元/小时`;
} else if (salaryClassify == 1) {
return `${salary}元/天`;
} else if (salaryClassify == 2) {
return `${salary}`;
} else if (salaryClassify == 3) {
return `${salary}`;
} else if (salaryClassify == 4) {
return `计件`;
} else if (salaryClassify == 5) {
return `保底${salary}`;
} else if (salaryClassify == 6) {
return `面议`;
} else if (salaryClassify == 7) {
return salary + '-' + salary1 + `元/月`;
} else {
return "-";
}
},
} }
export default data; export default data;
Loading…
Cancel
Save