This commit is contained in:
cclu 2025-01-17 18:18:49 +08:00
parent 883029c818
commit c8aa5edef1
6 changed files with 804 additions and 644 deletions

View File

@ -65,7 +65,7 @@ import request from '@/util/index.js'
// } // }
const netChange = () => { const netChange = () => {
uni.onNetworkStatusChange(function(res) { uni.onNetworkStatusChange(function (res) {
// console.log(res.isConnected) // console.log(res.isConnected)
store.mutations.isConnect(res.isConnected) store.mutations.isConnect(res.isConnected)
if (!res.isConnected) { if (!res.isConnected) {
@ -110,24 +110,25 @@ const fmoney = (s, n) => {
for (let i = 0; i < l.length; i++) { for (let i = 0; i < l.length; i++) {
t += l[i] + ((i + 1) % 3 == 0 && (i + 1) != l.length ? "," : ""); t += l[i] + ((i + 1) % 3 == 0 && (i + 1) != l.length ? "," : "");
} }
if (n===0){ if (n === 0) {
return s return s
}else{ } else {
return fuhao + [...t].reverse().join("") + "." + r; return fuhao + [...t].reverse().join("") + "." + r;
} }
} }
// 四舍五入不保留小数的 金额化数字方法 // 四舍五入不保留小数的 金额化数字方法
function noDecimal(s){ function noDecimal(s) {
console.log('s',s) console.log('s', s)
let fuhao = ''; //如果数字小于零则值为- let fuhao = ''; //如果数字小于零则值为-
if (s < 0) { if (s < 0) {
s = Math.abs(s); s = Math.abs(s);
fuhao = '-' fuhao = '-'
} }
s = parseFloat((s + "").replace(/[^\d\.-]/g, "")) + "" s = parseFloat((s + "").replace(/[^\d\.-]/g, "")) + ""
let l = s.split(".")[0].split("").reverse(), r = s.split(".")[1]; let l = s.split(".")[0].split("").reverse(),
r = s.split(".")[1];
let t = '' let t = ''
for (let i = 0; i < l.length; i++) { for (let i = 0; i < l.length; i++) {
t += l[i] + ((i + 1) % 3 == 0 && (i + 1) != l.length ? "," : ""); t += l[i] + ((i + 1) % 3 == 0 && (i + 1) != l.length ? "," : "");
@ -144,11 +145,11 @@ function changeStringToDate(s) {
if (s.length === 14) { if (s.length === 14) {
return s.substring(0, 4) + '-' + s.substring(4, 6) + '-' + s.substring(6, 8) + ' ' + return s.substring(0, 4) + '-' + s.substring(4, 6) + '-' + s.substring(6, 8) + ' ' +
s.substring(8, 10) + ':' + s.substring(10, 12) + ':' + s.substring(12, 14); s.substring(8, 10) + ':' + s.substring(10, 12) + ':' + s.substring(12, 14);
} } else if (s.length === 8) {
else if (s.length === 8) {
return s.substring(0, 4) + '-' + s.substring(4, 6) + '-' + s.substring(6, 8); return s.substring(0, 4) + '-' + s.substring(4, 6) + '-' + s.substring(6, 8);
} }
} }
function toNextRoute(type, url) { function toNextRoute(type, url) {
uni[type]({ uni[type]({
url: url, url: url,
@ -161,6 +162,17 @@ function toNextRoute(type, url) {
}) })
} }
function formatNumber(num) {
// 先保留两位小数,不四舍五入
num = Math.floor(num * 100) / 100;
// 添加千分号
let [integer, decimal] = num.toString().split('.');
integer = integer.replace(/\B(?=(\d{3})+(?!\d))/g, ','); // 千分号格式化
return decimal ? `${integer}.${decimal}` : integer; // 如果有小数部分则保留
}
// 记录用户行为的方法 每个页面的onUnload里面要调用 // 记录用户行为的方法 每个页面的onUnload里面要调用
function addUserBehavior(obj) { function addUserBehavior(obj) {
@ -184,22 +196,23 @@ function addUserBehavior(obj) {
let baseInfo = uni.getStorageSync('userInfo') let baseInfo = uni.getStorageSync('userInfo')
let req = { let req = {
userName:userDate.UserName, userName: userDate.UserName,
phoneNumber:userDate.Membership_Phone, phoneNumber: userDate.Membership_Phone,
userId:userDate.UserId ? userDate.UserId:'', userId: userDate.UserId ? userDate.UserId : '',
wechatAppId:'wx4fb5da2b8d9e0e43', wechatAppId: 'wx4fb5da2b8d9e0e43',
intoRoute:obj.intoRoute, intoRoute: obj.intoRoute,
outtoRoute:obj.outtoRoute, outtoRoute: obj.outtoRoute,
visitChannels:obj.visitChannels, visitChannels: obj.visitChannels,
behaviorRecordDesc:'', behaviorRecordDesc: '',
LoginIP: baseInfo.ip || '', LoginIP: baseInfo.ip || '',
LoginPlace: (baseInfo.prov ? baseInfo.prov : '' ) + (baseInfo.prov && baseInfo.city ? '-' : '') + (baseInfo.city ? baseInfo.city : ''), LoginPlace: (baseInfo.prov ? baseInfo.prov : '') + (baseInfo.prov && baseInfo.city ? '-' : '') + (baseInfo.city ? baseInfo.city : ''),
SOURCE_PLATFORM: '数智化看板' SOURCE_PLATFORM: '数智化看板'
} }
request.$webGet('CommercialApi/UserBehavior/AddUserBehavior',req).then(() => { request.$webGet('CommercialApi/UserBehavior/AddUserBehavior', req).then(() => {
}) })
} }
function addUserBehaviorNew(obj) { function addUserBehaviorNew(obj) {
var pages = getCurrentPages() // 获取加载的页面 var pages = getCurrentPages() // 获取加载的页面
@ -219,16 +232,16 @@ function addUserBehaviorNew(obj) {
obj.visitChannels = store.state.visitChannels obj.visitChannels = store.state.visitChannels
let userDate = store.state.userData let userDate = store.state.userData
let req = { let req = {
userName:userDate.UserName, userName: userDate.UserName,
phoneNumber:userDate.Membership_Phone, phoneNumber: userDate.Membership_Phone,
userId:userDate.UserId ? userDate.UserId:'', userId: userDate.UserId ? userDate.UserId : '',
wechatAppId:'wx4fb5da2b8d9e0e43', wechatAppId: 'wx4fb5da2b8d9e0e43',
intoRoute:obj.intoRoute, intoRoute: obj.intoRoute,
outtoRoute:obj.outtoRoute, outtoRoute: obj.outtoRoute,
visitChannels:obj.visitChannels, visitChannels: obj.visitChannels,
behaviorRecordDesc:'' behaviorRecordDesc: ''
} }
request.$webGet('CommercialApi/UserBehavior/AddUserBehavior',req).then(() => { request.$webGet('CommercialApi/UserBehavior/AddUserBehavior', req).then(() => {
}) })
} }
@ -260,26 +273,35 @@ async function getFieldEnumByField(params) {
// 得到这个月有多少天 // 得到这个月有多少天
function getThisMonthDay(value){ function getThisMonthDay(value) {
let date = new Date(value) let date = new Date(value)
let y = date.getFullYear() let y = date.getFullYear()
let m = date.getMonth() + 1 let m = date.getMonth() + 1
let howDay; let howDay;
let flag = false let flag = false
if( y%4 ===0 && y%100!==0 || y%400===0 ){ if (y % 4 === 0 && y % 100 !== 0 || y % 400 === 0) {
flag=true flag = true
} }
switch (m){ switch (m) {
case 1: case 3: case 5: case 7: case 8: case 10: case 12: case 1:
howDay=31 case 3:
case 5:
case 7:
case 8:
case 10:
case 12:
howDay = 31
break break
case 4: case 6: case 9: case 11: case 4:
howDay=30 case 6:
case 9:
case 11:
howDay = 30
break break
case 2 : case 2:
if(flag){ if (flag) {
howDay=29 howDay = 29
}else{ } else {
howDay = 28 howDay = 28
} }
break break
@ -288,56 +310,56 @@ function getThisMonthDay(value){
} }
// 输入时间拿到月份 // 输入时间拿到月份
function getThisMonth(value){ function getThisMonth(value) {
const date = new Date(value) const date = new Date(value)
let y = date.getFullYear() let y = date.getFullYear()
let m = date.getMonth()+1 let m = date.getMonth() + 1
if (m<10){ if (m < 10) {
m = '0'+m m = '0' + m
} }
return `${y}${m}` return `${y}${m}`
} }
// 输入时间得到带-的月份 // 输入时间得到带-的月份
function getThisMonthHaveHeng(value){ function getThisMonthHaveHeng(value) {
const date = new Date(value) const date = new Date(value)
let y = date.getFullYear() let y = date.getFullYear()
let m = date.getMonth()+1 let m = date.getMonth() + 1
if (m<10){ if (m < 10) {
m = '0'+m m = '0' + m
} }
return `${y}-${m}` return `${y}-${m}`
} }
//有横杠 //有横杠
function getThisMonthHave(value){ function getThisMonthHave(value) {
const date = new Date(value) const date = new Date(value)
let y = date.getFullYear() let y = date.getFullYear()
let m = date.getMonth()+1 let m = date.getMonth() + 1
if (m<10){ if (m < 10) {
m = '0'+m m = '0' + m
} }
return `${y}-${m}` return `${y}-${m}`
} }
// 显示月日 // 显示月日
function handleGetMonthDay(value){ function handleGetMonthDay(value) {
const date = new Date(value) const date = new Date(value)
let m = date.getMonth()+1 let m = date.getMonth() + 1
if (m<10){ if (m < 10) {
m = '0'+m m = '0' + m
} }
let d = date.getDate() let d = date.getDate()
if (d<10){ if (d < 10) {
d = '0' + d d = '0' + d
} }
return `${m}-${d}` return `${m}-${d}`
} }
// 输入时间拿到月份 输出月份的字符串 // 输入时间拿到月份 输出月份的字符串
function getThisTimeMonth(value){ function getThisTimeMonth(value) {
const date = new Date(value) const date = new Date(value)
let m = date.getMonth()+1 let m = date.getMonth() + 1
if (m<10){ if (m < 10) {
m = '0'+m m = '0' + m
} }
return `${m}` return `${m}`
} }
@ -351,42 +373,54 @@ function playVideo(opt) {
} }
// 输入年份和月份 输出该月的天数 是一个数组 格式为 *月**日 // 输入年份和月份 输出该月的天数 是一个数组 格式为 *月**日
function getThisMonthDateList(value){ function getThisMonthDateList(value) {
let date = new Date(value) let date = new Date(value)
let y = date.getFullYear() let y = date.getFullYear()
let m = date.getMonth() + 1 let m = date.getMonth() + 1
let howDay; let howDay;
let flag = false let flag = false
if( y%4 ===0 && y%100!==0 || y%400===0 ){ if (y % 4 === 0 && y % 100 !== 0 || y % 400 === 0) {
flag = true flag = true
} }
switch (m){ switch (m) {
case 1: case 3: case 5: case 7: case 8: case 10: case 12: case 1:
howDay=31 case 3:
case 5:
case 7:
case 8:
case 10:
case 12:
howDay = 31
break break
case 4: case 6: case 9: case 11: case 4:
howDay=30 case 6:
case 9:
case 11:
howDay = 30
break break
case 2 : case 2:
if(flag){ if (flag) {
howDay=29 howDay = 29
}else{ } else {
howDay = 28 howDay = 28
} }
break break
} }
let list = [] let list = []
for (let i = 0;i <= howDay,++i;) { for (let i = 0; i <= howDay, ++i;) {
if (i>howDay){ if (i > howDay) {
break break
}else{ } else {
list.push({label:`${m}${i}`,value:`${y}-${m<10?'0'+m:m}-${i<10?'0'+i:i}`}) list.push({
label: `${m}${i}`,
value: `${y}-${m<10?'0'+m:m}-${i<10?'0'+i:i}`
})
} }
} }
return list return list
} }
// 传入 老的时间和要变成的时间 老时间要日期 新时间不用 月份为1无效 // 传入 老的时间和要变成的时间 老时间要日期 新时间不用 月份为1无效
function handleReduceAMonth(nowTime,newTime){ function handleReduceAMonth(nowTime, newTime) {
const oldDate = new Date(nowTime) const oldDate = new Date(nowTime)
let y = oldDate.getFullYear() let y = oldDate.getFullYear()
let m = oldDate.getMonth() + 1 let m = oldDate.getMonth() + 1
@ -395,98 +429,98 @@ function handleReduceAMonth(nowTime,newTime){
const newDate = new Date(newTime) const newDate = new Date(newTime)
let newY = newDate.getFullYear() let newY = newDate.getFullYear()
let newM = newDate.getMonth() + 1 let newM = newDate.getMonth() + 1
let thisMonth = newM<10?'0'+newM:newM let thisMonth = newM < 10 ? '0' + newM : newM
let howDay = this.getThisMonthDay(`${y}-${m}`) let howDay = this.getThisMonthDay(`${y}-${m}`)
let newHowDay = this.getThisMonthDay(`${newY}-${thisMonth}`) let newHowDay = this.getThisMonthDay(`${newY}-${thisMonth}`)
const nowDate = new Date() const nowDate = new Date()
let nowM =nowDate.getMonth() + 1 let nowM = nowDate.getMonth() + 1
let nowD = nowDate.getDate() let nowD = nowDate.getDate()
if (d === newHowDay){ if (d === newHowDay) {
if (d<nowD){ if (d < nowD) {
if (newM<10){ if (newM < 10) {
newM = '0' + newM newM = '0' + newM
} }
if (newHowDay<10){ if (newHowDay < 10) {
newHowDay = '0' + newHowDay newHowDay = '0' + newHowDay
} }
return `${newY}-${newM}-${newHowDay}` return `${newY}-${newM}-${newHowDay}`
}else{ } else {
if (newM===nowM){ if (newM === nowM) {
if (newM<10){ if (newM < 10) {
newM = '0' + newM newM = '0' + newM
} }
if (nowD<10){ if (nowD < 10) {
nowD = '0' + nowD nowD = '0' + nowD
} }
return `${newY}-${newM}-${nowD}` return `${newY}-${newM}-${nowD}`
}else{ } else {
if (newM<10){ if (newM < 10) {
newM = '0' + newM newM = '0' + newM
} }
if (newHowDay<10){ if (newHowDay < 10) {
newHowDay = '0' + newHowDay newHowDay = '0' + newHowDay
} }
return `${newY}-${newM}-${newHowDay}` return `${newY}-${newM}-${newHowDay}`
} }
} }
}else{ } else {
if (newM===2){ if (newM === 2) {
if (d>newHowDay){ if (d > newHowDay) {
if (newM<10){ if (newM < 10) {
newM = '0' + newM newM = '0' + newM
} }
if (newHowDay<10){ if (newHowDay < 10) {
newHowDay = '0' + newHowDay newHowDay = '0' + newHowDay
} }
return `${newY}-${newM}-${newHowDay}` return `${newY}-${newM}-${newHowDay}`
}else{ } else {
if (newM<10){ if (newM < 10) {
newM = '0' + newM newM = '0' + newM
} }
if (d<10){ if (d < 10) {
d = '0' + d d = '0' + d
} }
return `${newY}-${newM}-${d}` return `${newY}-${newM}-${d}`
} }
}else{ } else {
if (nowD<d){ if (nowD < d) {
if (nowM===newM){ if (nowM === newM) {
if (newM<10){ if (newM < 10) {
newM = '0' + newM newM = '0' + newM
} }
if (nowD<10){ if (nowD < 10) {
nowD = '0' + nowD nowD = '0' + nowD
} }
return `${newY}-${newM}-${nowD}` return `${newY}-${newM}-${nowD}`
}else{ } else {
if (d<newHowDay){ if (d < newHowDay) {
if (newM<10){ if (newM < 10) {
newM = '0' + newM newM = '0' + newM
} }
if (d<10){ if (d < 10) {
d = '0' + d d = '0' + d
} }
return `${newY}-${newM}-${d}` return `${newY}-${newM}-${d}`
}else{ } else {
if (newM<10){ if (newM < 10) {
newM = '0' + newM newM = '0' + newM
} }
if (newHowDay<10){ if (newHowDay < 10) {
newHowDay = '0' +newHowDay newHowDay = '0' + newHowDay
} }
return `${newY}-${newM}-${newHowDay}` return `${newY}-${newM}-${newHowDay}`
} }
} }
}else { } else {
if (newM<10){ if (newM < 10) {
newM = '0' + newM newM = '0' + newM
} }
if (d<10){ if (d < 10) {
d = '0' +d d = '0' + d
} }
return `${newY}-${newM}-${d}` return `${newY}-${newM}-${d}`
} }
@ -494,7 +528,7 @@ function handleReduceAMonth(nowTime,newTime){
} }
} }
// 不四舍五入 保留两位小数的金额化方法 // 不四舍五入 保留两位小数的金额化方法
function getMoney(money){ function getMoney(money) {
if (!money || isNaN(money)) return "0.00"; if (!money || isNaN(money)) return "0.00";
let num = parseFloat(money + '') + ''; let num = parseFloat(money + '') + '';
num = parseInt(money * 100 + '') / 100 + '' num = parseInt(money * 100 + '') / 100 + ''
@ -518,7 +552,7 @@ function getMoney(money){
return num; return num;
} }
// 不四舍五入 不保留两位小数的金额化方法 // 不四舍五入 不保留两位小数的金额化方法
function getMoneyNoDecimal(money){ function getMoneyNoDecimal(money) {
if (!money || isNaN(money)) return "0"; if (!money || isNaN(money)) return "0";
let num = parseFloat(money + '') + ''; let num = parseFloat(money + '') + '';
num = parseInt(money * 100 + '') / 100 + '' num = parseInt(money * 100 + '') / 100 + ''
@ -539,23 +573,23 @@ function getMoneyNoDecimal(money){
} }
// 封装的排序数组的方法 // 封装的排序数组的方法
// list 为排序的数组 field 为按照那个字段排序 type 正序还是倒序 1正 2倒 // list 为排序的数组 field 为按照那个字段排序 type 正序还是倒序 1正 2倒
const handleGetSortList = (list,field,type)=>{ const handleGetSortList = (list, field, type) => {
if (list && list.length>0){ if (list && list.length > 0) {
let len = list.length let len = list.length
if (type===2){ if (type === 2) {
for (var i = 0; i < len - 1;i++){ for (var i = 0; i < len - 1; i++) {
for (var j = 0; j < len - 1 - i; j++) { for (var j = 0; j < len - 1 - i; j++) {
if (list[i][field]<list[j][field]){ if (list[i][field] < list[j][field]) {
var temp = list[j]; var temp = list[j];
list[j] = list[j + 1]; list[j] = list[j + 1];
list[j + 1] = temp; list[j + 1] = temp;
} }
} }
} }
}else{ } else {
for (var i = 0; i < len - 1;i++){ for (var i = 0; i < len - 1; i++) {
for (var j = 0; j < len - 1 - i; j++) { for (var j = 0; j < len - 1 - i; j++) {
if (list[i][field]>list[j][field]){ if (list[i][field] > list[j][field]) {
var temp = list[j]; var temp = list[j];
list[j] = list[j + 1]; list[j] = list[j + 1];
list[j + 1] = temp; list[j + 1] = temp;
@ -579,6 +613,7 @@ export default {
getThisTimeMonth, getThisTimeMonth,
handleGetMonthDay, handleGetMonthDay,
fmoney, fmoney,
formatNumber,
noDecimal, noDecimal,
changeStringToDate, changeStringToDate,
toNextRoute, toNextRoute,

View File

@ -8,7 +8,7 @@
src="https://eshangtech.com/ShopICO/ahyd-BID/examine/leftArrowWhite.svg" src="https://eshangtech.com/ShopICO/ahyd-BID/examine/leftArrowWhite.svg"
></image> ></image>
</view> </view>
<p class="title">提单申请</p> <p class="title">{{ item.BillState === 1 ? "已提单" : "提单申请" }}</p>
<view class="content"> <view class="content">
<view class="detail"> <view class="detail">
@ -38,8 +38,8 @@
<view class="right"> <view class="right">
<p class="detailTitle"> <p class="detailTitle">
{{ {{
detailInfo.BUSINESSPROCESS_NAME detailInfo.BusinessProcess_Name
? detailInfo.BUSINESSPROCESS_NAME.split("】")[1] ? detailInfo.BusinessProcess_Name.split("】")[1]
: "-" : "-"
}} }}
</p> </p>
@ -48,7 +48,7 @@
class="serviceFixed" class="serviceFixed"
src="https://eshangtech.com/ShopICO/yxcl/projectWarning/position.svg" src="https://eshangtech.com/ShopICO/yxcl/projectWarning/position.svg"
></image> ></image>
<span class="service">{{ detailInfo.SERVERPART_NAME }}</span> <span class="service">{{ detailInfo.Serverpart_Name }}</span>
</view> </view>
<view class="other"> <view class="other">
<view class="item"> <view class="item">
@ -56,7 +56,7 @@
class="icon" class="icon"
src="https://eshangtech.com/ShopICO/yxcl/projectWarning/user.svg" src="https://eshangtech.com/ShopICO/yxcl/projectWarning/user.svg"
></image> ></image>
<span class="value">{{ detailInfo.STAFF_NAME || "-" }}</span> <span class="value">{{ detailInfo.Staff_Name || "-" }}</span>
</view> </view>
<!-- <view class="item"> <!-- <view class="item">
<image <image
@ -88,8 +88,10 @@
></image> ></image>
<span class="text">提单时间</span> <span class="text">提单时间</span>
<span class="money">{{ <span class="money">{{
detailInfo.BUSINESS_ENDDATE detailInfo.BusinessProcess_EndDate
? $moment(detailInfo.BUSINESS_ENDDATE).format("YYYY/MM/DD") ? $moment(detailInfo.BusinessProcess_EndDate).format(
"YYYY/MM/DD"
)
: "-" : "-"
}}</span> }}</span>
</view> </view>
@ -107,13 +109,23 @@
</view> </view>
</view> </view>
<view class="contentTextBox"> <view class="contentTextBox" v-if="detailInfo.BillState !== 1">
<textarea placeholder="请输入审核意见" v-model="desc"></textarea> <textarea v-model="desc"></textarea>
</view> </view>
<view class="bottomBtn" v-if="detailInfo.BillState !== 1"> <view class="bottomBtn" v-if="detailInfo.BillState !== 1">
<button class="btn change" @click="handleBillLading">发起提单</button> <button class="btn change" @click="handleBillLading">发起提单</button>
</view> </view>
<view class="bottomBtn" v-if="detailInfo.BillState === 1">
<button
:style="{
background: '#e0ba98',
}"
class="btn change"
>
已发起
</button>
</view>
</view> </view>
</view> </view>
</template> </template>
@ -124,7 +136,7 @@ export default {
return { return {
menu: {}, // menu: {}, //
detailInfo: {}, // detailInfo: {}, //
desc: "", // desc: "项目结算完成,发起提单审批流程", //
}; };
}, },
@ -149,16 +161,39 @@ export default {
uni.showLoading({ uni.showLoading({
title: "加载中...", title: "加载中...",
}); });
let req = {
BUSINESSAPPROVALId: id, const req = {
SearchParameter: {
BusinessApproval_ID: id,
BusinessProcess_State: 9000,
Operation_Type: 11,
PendState: 3,
},
}; };
const data = await this.$request.$webGet( const data = await this.$request.$webPost(
"EShangApiMain/BusinessProcess/GetBUSINESSAPPROVALDetail", "EShangApiMain/Finance/GetMonthAccountProinst",
req req
); );
console.log("data", data); console.log("data", data);
this.detailInfo = data.Result_Data; let list = data.Result_Data.List;
console.log("this.detailInfo", this.detailInfo); if (list && list.length > 0) {
this.detailInfo = list[0];
this.detailInfo.Liquidation_Amount = this.$util.formatNumber(
this.detailInfo.Liquidation_Amount
);
}
console.log("this.detailInfo ", this.detailInfo);
// let req = {
// BUSINESSAPPROVALId: id,
// };
// const data = await this.$request.$webGet(
// "EShangApiMain/BusinessProcess/GetBUSINESSAPPROVALDetail",
// req
// );
// console.log("data", data);
// this.detailInfo = data.Result_Data;
// console.log("this.detailInfo", this.detailInfo);
uni.hideLoading(); uni.hideLoading();
}, },
@ -170,6 +205,14 @@ export default {
}, },
// //
async handleBillLading() { async handleBillLading() {
if (!this.desc) {
uni.showToast({
title: "请先输入审核意见!",
icon: "none",
});
return;
}
console.log("user", this.user); console.log("user", this.user);
const req = { const req = {
businessApprovalID: this.detailInfo.BusinessApproval_ID, businessApprovalID: this.detailInfo.BusinessApproval_ID,
@ -189,7 +232,7 @@ export default {
let _this = this; let _this = this;
setTimeout(() => { setTimeout(() => {
_this.handleGetDetail(_this.BUSINESSAPPROVAL_ID); _this.handleGetDetail(_this.BUSINESSAPPROVAL_ID);
}); }, 2000);
// if (data.Result_Code === 100) { // if (data.Result_Code === 100) {
// setTimeout(() => { // setTimeout(() => {

View File

@ -31,7 +31,12 @@
</view> </view>
</view> </view>
</view> </view>
<scroll-view class="billList" v-if="pageList && pageList.length > 0"> <scroll-view
scroll-y
class="billList"
v-if="pageList && pageList.length > 0"
@scrolltolower="handleScrolltolower"
>
<!-- <list-unit <!-- <list-unit
v-for="(item, index) in pageList" v-for="(item, index) in pageList"
:key="index" :key="index"
@ -87,6 +92,12 @@
</view> </view>
</view> </view>
</view> </view>
<!-- 底部提示 -->
<view class="load-more" v-if="pageList.length > 0">
<text>{{
!pageMsg.isOver ? "正在加载,请稍后..." : "——— 我是有底线的 ———"
}}</text>
</view>
</scroll-view> </scroll-view>
<!-- 无数据时的页面显示 --> <!-- 无数据时的页面显示 -->
<view v-else> <view v-else>
@ -97,12 +108,7 @@
<!-- <text name="other">请选择其它日期进行查询</text> --> <!-- <text name="other">请选择其它日期进行查询</text> -->
</noFound> </noFound>
</view> </view>
<!-- 底部提示 -->
<view class="load-more" v-if="pageList.length > 0">
<text>{{
!pageData.isEnd ? "正在加载,请稍后..." : "——— 我是有底线的 ———"
}}</text>
</view>
<uni-popup <uni-popup
:show="showPop" :show="showPop"
@hidePopup="closePop" @hidePopup="closePop"
@ -156,57 +162,11 @@ export default {
pageMsg: { pageMsg: {
pageSize: 10, pageSize: 10,
pageIndex: 1, pageIndex: 1,
isOver: false,
}, // }, //
searchText: "", // searchText: "", //
BillState: "", // 1 0 BillState: "", // 1 0
pageList: [ pageList: [], //
{
Accept_Code: null,
ApproveStaff_ID: null,
ApproveStaff_Name: "",
BUSINESSPROJECT_ID: 540,
BUSINESSPROJECT_NAME: "龙门寺服务区特产零售项目",
BillState: null,
BusinessApproval_ID: 10045,
BusinessProcess_Desc: "已审核,拟同意!请复核",
BusinessProcess_EndDate: "2025/01/13 10:14:21",
BusinessProcess_ID: 540,
BusinessProcess_Name: "龙门寺服务区特产零售项目年度结算",
BusinessProcess_StartDate: "2024/11/20 16:15:07",
BusinessProcess_State: 9000,
BusinessProcess_StateSearch: null,
ENDDATE: "2024/01/31",
Liquidation_Amount: 12873.78,
MERCHANTS_ID: -1128,
MERCHANTS_NAME: "安徽马郢乡村旅游农民专业合作社",
ModuleGuid: null,
NextState: null,
Operation_Type: "11",
PaymentTerms: 0,
PendState: 1,
Proinst_ID: 1891,
REGISTERCOMPACT_ID: null,
REVENUE_AMOUNT: null,
RejectStaff_Name: "",
Reject_Info: "",
SHOPROYALTY_ID: 1891,
STARTDATE: "2023/02/01",
ServerpartShop_ID: "958,959",
ServerpartShop_Name: "东区马郢特产店,西区马郢特产店",
Serverpart_Codes: null,
Serverpart_ID: 419,
Serverpart_IDS: null,
Serverpart_Name: "龙门寺服务区",
Staff_ID: 906,
Staff_Name: "肖方俊【龙门寺服务区】",
},
{},
{},
{},
{},
{},
{},
], //
activeType: 0, // activeType: 0, //
menuList: [ menuList: [
{ {
@ -236,7 +196,7 @@ export default {
}, },
onLoad() { onLoad() {
// //
// this.handleGetList(); this.handleGetList();
}, },
onShow() { onShow() {
if (!this.isFirst) { if (!this.isFirst) {
@ -247,6 +207,11 @@ export default {
} }
}, },
methods: { methods: {
//
handleScrolltolower() {
this.pageMsg.pageIndex = this.pageMsg.pageIndex + 1;
this.handleGetList();
},
// //
async handleGetList() { async handleGetList() {
const req = { const req = {
@ -271,12 +236,20 @@ export default {
); );
console.log("list", data); console.log("list", data);
let list = data.Result_Data.List; let list = data.Result_Data.List;
if (list && list.length > 0) { let oldList = [];
this.pageList = list; if (this.pageList && this.pageList.length > 0) {
} else { oldList = this.pageList;
this.pageList = [];
} }
if (list && list.length > 0) {
list.forEach((item) => {
item.BusinessProcess_Name = item.BusinessProcess_Name.split("】")[1];
});
if (list.length < 10) {
this.pageMsg.isOver = true;
}
}
this.pageList = oldList.concat(list);
uni.hideLoading(); uni.hideLoading();
}, },
// //
@ -289,6 +262,15 @@ export default {
// tab // tab
handleClick(obj) { handleClick(obj) {
this.activeType = obj.id; this.activeType = obj.id;
this.BillState =
obj.id === 0 ? "" : obj.id === 1 ? 1 : obj.id === 2 ? "0" : "";
this.pageList = [];
this.pageMsg = {
pageSize: 10,
pageIndex: 1,
isOver: false,
};
this.handleGetList();
}, },
}, },
}; };

View File

@ -1203,14 +1203,18 @@
selectVersion3Obj["累计"].RevenueINC selectVersion3Obj["累计"].RevenueINC
.curYearData || "-" .curYearData || "-"
}}</text> }}</text>
<text class="label">{{(Math.floor(index / 12) + 2023)}}/万元</text> <text class="label"
>{{ Math.floor(index / 12) + 2023 }}/万元</text
>
</div> </div>
<div class="rightBox carRight"> <div class="rightBox carRight">
<text class="value">{{ <text class="value">{{
selectVersion3Obj["累计"].RevenueINC.lYearData || selectVersion3Obj["累计"].RevenueINC.lYearData ||
"-" "-"
}}</text> }}</text>
<text class="label">{{(Math.floor(index / 12) + 2022)}}/万元</text> <text class="label"
>{{ Math.floor(index / 12) + 2022 }}/万元</text
>
</div> </div>
<img <img
class="pkLogo" class="pkLogo"
@ -1304,14 +1308,18 @@
selectVersion3Obj["累计"].AccountINC selectVersion3Obj["累计"].AccountINC
.curYearData || "-" .curYearData || "-"
}}</text> }}</text>
<text class="label">{{(Math.floor(index / 12) + 2023)}}/万元</text> <text class="label"
>{{ Math.floor(index / 12) + 2023 }}/万元</text
>
</div> </div>
<div class="rightBox qmCarRight"> <div class="rightBox qmCarRight">
<text class="value">{{ <text class="value">{{
selectVersion3Obj["累计"].AccountINC.lYearData || selectVersion3Obj["累计"].AccountINC.lYearData ||
"-" "-"
}}</text> }}</text>
<text class="label">{{(Math.floor(index / 12) + 2022)}}/万元</text> <text class="label"
>{{ Math.floor(index / 12) + 2022 }}/万元</text
>
</div> </div>
<img <img
class="pkLogo" class="pkLogo"
@ -1405,14 +1413,18 @@
selectVersion3Obj["累计"].BayonetINC selectVersion3Obj["累计"].BayonetINC
.curYearData || "-" .curYearData || "-"
}}</text> }}</text>
<text class="label">{{(Math.floor(index / 12) + 2023)}}/万元</text> <text class="label"
>{{ Math.floor(index / 12) + 2023 }}/万元</text
>
</div> </div>
<div class="rightBox summerHolidayRightBox"> <div class="rightBox summerHolidayRightBox">
<text class="value">{{ <text class="value">{{
selectVersion3Obj["累计"].BayonetINC.lYearData || selectVersion3Obj["累计"].BayonetINC.lYearData ||
"-" "-"
}}</text> }}</text>
<text class="label">{{(Math.floor(index / 12) + 2022)}}/万元</text> <text class="label"
>{{ Math.floor(index / 12) + 2022 }}/万元</text
>
</div> </div>
<img <img
class="pkLogo" class="pkLogo"
@ -4694,9 +4706,10 @@
</view> </view>
</view> </view>
<!-- <view <view
class="funItem" class="funItem"
style="margin-top: 32rpx" style="margin-top: 32rpx"
v-if="false"
@click="goToBillLading" @click="goToBillLading"
> >
<view class="funItemContent"> <view class="funItemContent">
@ -4708,7 +4721,7 @@
</view> </view>
<text class="funText">提单申请</text> <text class="funText">提单申请</text>
</view> </view>
</view> --> </view>
<!-- 数智统计--> <!-- 数智统计-->
<view <view
@ -6226,7 +6239,7 @@ export default {
this.$util.toNextRoute("navigateTo", `/pages/robot/index`); this.$util.toNextRoute("navigateTo", `/pages/robot/index`);
// this.$util.toNextRoute("navigateTo", `/pages/testPage/index`); // this.$util.toNextRoute("navigateTo", `/pages/testPage/index`);
}, },
goToBillLading(){ goToBillLading() {
this.$util.toNextRoute("navigateTo", `/pages/billOfLading/index`); this.$util.toNextRoute("navigateTo", `/pages/billOfLading/index`);
}, },
handleShowTrafficDetail() { handleShowTrafficDetail() {

View File

@ -1,30 +1,50 @@
<template> <template>
<view class="main" style="padding-bottom: env(safe-area-inset-bottom)"> <view class="main" style="padding-bottom: env(safe-area-inset-bottom)">
<view class="userBg"> <view class="userBg">
<div class="headerTop" :style="{ height: menu.bottom + 5 + 'px'}"> <div class="headerTop" :style="{ height: menu.bottom + 5 + 'px' }">
<view class="news" :style="{ top: menu.top+16 + 'px', lineHeight: menu.bottom - menu.top + 'px' }"> <view
class="news"
:style="{
top: menu.top + 16 + 'px',
lineHeight: menu.bottom - menu.top + 'px',
}"
>
<view class="box"> <view class="box">
<!-- @click="handleNews"--> <!-- @click="handleNews"-->
<image class="img" src="https://eshangtech.com/ShopICO/ahyd-BID/index/news.svg" @click="handleNews"></image> <image
class="img"
src="https://eshangtech.com/ShopICO/ahyd-BID/index/news.svg"
@click="handleNews"
></image>
<view class="red"></view> <view class="red"></view>
</view> </view>
</view> </view>
<view class="userTitle" :style="{ top: menu.top + 'px', lineHeight: menu.bottom - menu.top + 'px' }">我的</view> <view
class="userTitle"
:style="{
top: menu.top + 'px',
lineHeight: menu.bottom - menu.top + 'px',
}"
>我的</view
>
</div> </div>
<div class="userBox" :style="{ top: menu.bottom + 18 + 'px' }"> <div class="userBox" :style="{ top: menu.bottom + 18 + 'px' }">
<image class="userBgImg" src="https://eshangtech.com/ShopICO/ahyd-BID/user/userBg.png"></image> <image
class="userBgImg"
src="https://eshangtech.com/ShopICO/ahyd-BID/user/userBg.png"
></image>
<view class="box" v-if="user.Membership_Id"> <view class="box" v-if="user.Membership_Id">
<view class="headImg"> <view class="headImg">
<image :src="user.Membership_Headimage"></image> <image :src="user.Membership_Headimage"></image>
</view> </view>
<view class="message"> <view class="message">
<view class="people"> <view class="people">
<p class="name">{{user.Membership_Name}}</p> <p class="name">{{ user.Membership_Name }}</p>
<!-- <view class="person"> <view class="personName">{{user.DepartmentName}}</view> </view>--> <!-- <view class="person"> <view class="personName">{{user.DepartmentName}}</view> </view>-->
<view class="person">{{user.DepartmentName}}</view> <view class="person">{{ user.DepartmentName }}</view>
</view> </view>
<p class="phone">{{ handleGetPhone(user.Membership_Phone) }}</p> <p class="phone">{{ handleGetPhone(user.Membership_Phone) }}</p>
<p class="address">{{user.OwnerUnitName}}</p> <p class="address">{{ user.OwnerUnitName }}</p>
</view> </view>
</view> </view>
<view v-else> <view v-else>
@ -40,383 +60,447 @@
</view> </view>
<view class="menu" :style="{ top: -(117 - menu.bottom) + 'px' }"> <view class="menu" :style="{ top: -(117 - menu.bottom) + 'px' }">
<userList v-for="(item, index) in dataList" :key="index" :item='item' :lastDay="lastDay" ></userList> <userList
v-for="(item, index) in dataList"
:key="index"
:item="item"
:lastDay="lastDay"
></userList>
</view> </view>
<Tabbar ref="tabbar" :page="page" ></Tabbar> <Tabbar ref="tabbar" :page="page"></Tabbar>
</view> </view>
</template> </template>
<script> <script>
import request from '@/util/index.js' import request from "@/util/index.js";
import {mapActions, mapState} from 'vuex' import { mapActions, mapState } from "vuex";
import userList from "./components/userList.vue"; import userList from "./components/userList.vue";
import Tabbar from "../../components/tabbar/tabbar.vue"; import Tabbar from "../../components/tabbar/tabbar.vue";
export default { export default {
data() { data() {
const lastDay = this.$util.cutDate(new Date(), 'YYYY-MM-DD', -1) const lastDay = this.$util.cutDate(new Date(), "YYYY-MM-DD", -1);
return { return {
page:'/pages/userCenter/userCenter', page: "/pages/userCenter/userCenter",
statusBarHeight:'', statusBarHeight: "",
menu:'', menu: "",
lastDay:lastDay, lastDay: lastDay,
userLists:[ { url: 'https://eshangtech.com/ShopICO/ahyd-BID/user/position.svg', name: '我的服务区', value: 1 }, userLists: [
{ url: 'https://eshangtech.com/ShopICO/ahyd-BID/user/limit.svg', name: '我的权限', value: 2 },],
dataList :[
{ {
name: '商业经营', url: "https://eshangtech.com/ShopICO/ahyd-BID/user/position.svg",
value: 1, name: "我的服务区",
list: [
{
id:'74934d31-385a-4eed-80bb-9c9ed7da29b5',
name: '每日营收',
homeUrl: '/pages/everdayRenven/index',
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/user/dailyRevenue.svg',
bgUrl:'https://eshangtech.com/ShopICO/ahyd-BID/user/firstBg_1.png',
isNotice:true,
value: 1, value: 1,
}, },
{ {
id:'', url: "https://eshangtech.com/ShopICO/ahyd-BID/user/limit.svg",
name: '节日特刊', name: "我的权限",
value: 2,
},
],
dataList: [
{
name: "商业经营",
value: 1,
list: [
{
id: "74934d31-385a-4eed-80bb-9c9ed7da29b5",
name: "每日营收",
homeUrl: "/pages/everdayRenven/index",
imagePath:
"https://eshangtech.com/ShopICO/ahyd-BID/user/dailyRevenue.svg",
bgUrl:
"https://eshangtech.com/ShopICO/ahyd-BID/user/firstBg_1.png",
isNotice: true,
value: 1,
},
{
id: "",
name: "节日特刊",
homeUrl: `/pages/nationalPage/index?time=${lastDay}&type=true`, homeUrl: `/pages/nationalPage/index?time=${lastDay}&type=true`,
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/user/festival.svg', imagePath:
bgUrl:'https://eshangtech.com/ShopICO/ahyd-BID/user/firstBg_2.png', "https://eshangtech.com/ShopICO/ahyd-BID/user/festival.svg",
isNotice:true, bgUrl:
"https://eshangtech.com/ShopICO/ahyd-BID/user/firstBg_2.png",
isNotice: true,
value: 1, value: 1,
}, },
{ {
id:'4a34e1d4-47c9-4c06-8e8e-f38c6bd9450b', id: "4a34e1d4-47c9-4c06-8e8e-f38c6bd9450b",
name: '经营报表', name: "经营报表",
homeUrl: '/pages/operatingStatements/index', homeUrl: "/pages/operatingStatements/index",
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/user/reportForms.svg', imagePath:
bgUrl:'https://eshangtech.com/ShopICO/ahyd-BID/user/firstBg_3.png', "https://eshangtech.com/ShopICO/ahyd-BID/user/reportForms.svg",
isNotice:true, bgUrl:
"https://eshangtech.com/ShopICO/ahyd-BID/user/firstBg_3.png",
isNotice: true,
value: 1, value: 1,
}, },
], ],
}, },
{ {
name: '商业画像', name: "商业画像",
value: 2, value: 2,
list: [ list: [
{ {
id:'', id: "",
name: '车流', name: "车流",
homeUrl: '/pages/commercialBINew/carPortrait', homeUrl: "/pages/commercialBINew/carPortrait",
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/user/traffic.svg', imagePath:
isNotice:'', "https://eshangtech.com/ShopICO/ahyd-BID/user/traffic.svg",
type:1, isNotice: "",
type: 1,
value: 2, value: 2,
}, },
{ {
id:'', id: "",
name: '客群', name: "客群",
homeUrl: '/pages/commercialBI/guestPortrait', homeUrl: "/pages/commercialBI/guestPortrait",
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/user/customerGroup.svg', imagePath:
isNotice:'', "https://eshangtech.com/ShopICO/ahyd-BID/user/customerGroup.svg",
type:2, isNotice: "",
type: 2,
value: 2, value: 2,
}, },
{ {
id:'', id: "",
name: '经营', name: "经营",
homeUrl: '/pages/commercialBI/managePortrait', homeUrl: "/pages/commercialBI/managePortrait",
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/user/manage.svg', imagePath:
isNotice:'', "https://eshangtech.com/ShopICO/ahyd-BID/user/manage.svg",
type:3, isNotice: "",
type: 3,
value: 2, value: 2,
}, },
{ {
id:'', id: "",
name: '交易', name: "交易",
homeUrl: '/pages/commercialBI/businessPortrait', homeUrl: "/pages/commercialBI/businessPortrait",
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/user/business.svg', imagePath:
isNotice:'', "https://eshangtech.com/ShopICO/ahyd-BID/user/business.svg",
type:4, isNotice: "",
type: 4,
value: 2, value: 2,
}, },
{ {
id:'', id: "",
name: '品牌', name: "品牌",
homeUrl: '/pages/commercialBI/formatPortrait', homeUrl: "/pages/commercialBI/formatPortrait",
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/user/brand.svg', imagePath:
isNotice:'', "https://eshangtech.com/ShopICO/ahyd-BID/user/brand.svg",
type:5, isNotice: "",
type: 5,
value: 2, value: 2,
}, },
], ],
}, },
{ {
name: '业务审批', name: "业务审批",
value: 3, value: 3,
list: [ list: [
{ {
id:'1a2907bd-c2f5-4ef9-9ead-70496650ace6', id: "1a2907bd-c2f5-4ef9-9ead-70496650ace6",
name: '财务审批', name: "财务审批",
homeUrl: '/pages/expenseApproval/expenseApproval', homeUrl: "/pages/expenseApproval/expenseApproval",
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/user/financialApproval.svg', imagePath:
notice:0, "https://eshangtech.com/ShopICO/ahyd-BID/user/financialApproval.svg",
notice: 0,
value: 3, value: 3,
isNotice:false isNotice: false,
}, },
{ {
id:'916cdbb5-f05b-4624-b6c4-9f111d4389fc', id: "916cdbb5-f05b-4624-b6c4-9f111d4389fc",
name: '招标投标', name: "招标投标",
homeUrl: '/pages/tender/tender', homeUrl: "/pages/tender/tender",
notice:0, notice: 0,
value: 3, value: 3,
isNotice:false, isNotice: false,
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/user/bidding.svg', imagePath:
"https://eshangtech.com/ShopICO/ahyd-BID/user/bidding.svg",
}, },
{ {
id:'8fea5036-d67e-476e-9e56-5f379ba6ae18', id: "8fea5036-d67e-476e-9e56-5f379ba6ae18",
name: '服务区报销', name: "服务区报销",
homeUrl: '/pages/serviceAreaReimbursement/serviceAreaReimbursement', homeUrl:
notice:0, "/pages/serviceAreaReimbursement/serviceAreaReimbursement",
notice: 0,
value: 3, value: 3,
isNotice:false, isNotice: false,
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/user/serviceAreaReimbur.svg', imagePath:
"https://eshangtech.com/ShopICO/ahyd-BID/user/serviceAreaReimbur.svg",
}, },
{ {
id:'ac661db4-1af1-4732-88db-76bc05eec335', id: "ac661db4-1af1-4732-88db-76bc05eec335",
name: '合同审批', name: "合同审批",
homeUrl: '/pages/contract/contract', homeUrl: "/pages/contract/contract",
notice:0, notice: 0,
value: 3, value: 3,
isNotice:false, isNotice: false,
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/user/contractApproval.svg', imagePath:
"https://eshangtech.com/ShopICO/ahyd-BID/user/contractApproval.svg",
}, },
{ {
id:'056b29d7-4721-47ee-ad25-660814e1f3a9', id: "056b29d7-4721-47ee-ad25-660814e1f3a9",
name: '商品审批', name: "商品审批",
homeUrl: '/pages/businessApproval/businessApproval', homeUrl: "/pages/businessApproval/businessApproval",
notice:0, notice: 0,
value: 3, value: 3,
isNotice:false, isNotice: false,
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/user/productApproval.svg', imagePath:
"https://eshangtech.com/ShopICO/ahyd-BID/user/productApproval.svg",
}, },
{ {
id:'2290e96d-c6d7-4dde-b5b7-e699b615ff2f', id: "2290e96d-c6d7-4dde-b5b7-e699b615ff2f",
name: '招商审批', name: "招商审批",
homeUrl: '/pages/investment/investment', homeUrl: "/pages/investment/investment",
notice:0, notice: 0,
value: 3, value: 3,
isNotice:false, isNotice: false,
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/user/promotionApproval.svg', imagePath:
"https://eshangtech.com/ShopICO/ahyd-BID/user/promotionApproval.svg",
}, },
{ {
id:'c802a38f-3bbd-4db0-89b6-34e404c8d8cc', id: "c802a38f-3bbd-4db0-89b6-34e404c8d8cc",
name: '权限审批', name: "权限审批",
homeUrl: '/pages/authorityApproval/index', homeUrl: "/pages/authorityApproval/index",
notice:0, notice: 0,
value: 3, value: 3,
isNotice:false, isNotice: false,
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/user/authorityApproval.svg', imagePath:
"https://eshangtech.com/ShopICO/ahyd-BID/user/authorityApproval.svg",
}, },
{ {
id:'b0b63a75-56c9-4f1d-aacb-a26e62b47e3e', id: "b0b63a75-56c9-4f1d-aacb-a26e62b47e3e",
name: '数据校验', name: "数据校验",
homeUrl: '/pages/dataSummary/dataSummary', homeUrl: "/pages/dataSummary/dataSummary",
notice:0, notice: 0,
value: 3, value: 3,
isNotice:false, isNotice: false,
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/user/dataVerification.svg', imagePath:
"https://eshangtech.com/ShopICO/ahyd-BID/user/dataVerification.svg",
}, },
{ {
id:'b0b63a75-56c9-4f1d-aacb-a26e62b47e3e', id: "b0b63a75-56c9-4f1d-aacb-a26e62b47e3e",
name: '分润切换', name: "分润切换",
homeUrl: '/pages/projectWarning/index', homeUrl: "/pages/projectWarning/index",
notice:0, notice: 0,
value: 3, value: 3,
isNotice:false, isNotice: false,
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/index/changeMoney.svg', imagePath:
"https://eshangtech.com/ShopICO/ahyd-BID/index/changeMoney.svg",
}, },
{ {
id:'a927bf4d-f924-4034-b964-d1a8bd401d09', id: "a927bf4d-f924-4034-b964-d1a8bd401d09",
name: '结算审批', name: "结算审批",
homeUrl: '/pages/settlementApproval/index', homeUrl: "/pages/settlementApproval/index",
notice:0, notice: 0,
value: 3, value: 3,
isNotice:false, isNotice: false,
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/index/changeMoney.svg', imagePath:
"https://eshangtech.com/ShopICO/ahyd-BID/index/changeMoney.svg",
},
{
id: "632e1a7f-de9e-4553-b5c0-f1bc77abc08c",
name: "结算提单",
homeUrl: "/pages/billOfLading/index",
notice: 0,
value: 3,
isNotice: false,
imagePath:
"https://eshangtech.com/ShopICO/ahyd-BID/index/changeMoney.svg",
}, },
], ],
}, },
{ {
name: '现场管理', name: "现场管理",
value: 4, value: 4,
list: [ list: [
{ {
id:'', id: "",
name: '基础信息', name: "基础信息",
homeUrl: '/pages/map/detail?come=user', homeUrl: "/pages/map/detail?come=user",
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/user/basicInformation.svg', imagePath:
isNotice:true, "https://eshangtech.com/ShopICO/ahyd-BID/user/basicInformation.svg",
notice:0, isNotice: true,
type:0, notice: 0,
type: 0,
summaryOfPortraits: true, summaryOfPortraits: true,
value: 4, value: 4,
}, },
{ {
id:'30f0e7d0-4e01-4a63-a65b-613e1f427335', id: "30f0e7d0-4e01-4a63-a65b-613e1f427335",
name: '考评考核', name: "考评考核",
homeUrl: '/pages/examine/index', homeUrl: "/pages/examine/index",
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/user/assessment.svg', imagePath:
isNotice:false, "https://eshangtech.com/ShopICO/ahyd-BID/user/assessment.svg",
notice:0, isNotice: false,
notice: 0,
summaryOfPortraits: true, summaryOfPortraits: true,
type:6, type: 6,
value: 4, value: 4,
}, },
{ {
id:'d405ae13-3388-41c0-a5f6-d11194d0a943', id: "d405ae13-3388-41c0-a5f6-d11194d0a943",
name: '投诉建议', name: "投诉建议",
homeUrl: '/pages/suggestion/suggestion', homeUrl: "/pages/suggestion/suggestion",
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/user/complaintSuggest.svg', imagePath:
isNotice:false, "https://eshangtech.com/ShopICO/ahyd-BID/user/complaintSuggest.svg",
notice:0, isNotice: false,
notice: 0,
value: 4, value: 4,
}, },
{ {
id:'ebd8cae4-d36d-4ea0-a7e9-61e566bf9e24', id: "ebd8cae4-d36d-4ea0-a7e9-61e566bf9e24",
name: '收银稽查', name: "收银稽查",
homeUrl: '/pages/cashAudit/list', homeUrl: "/pages/cashAudit/list",
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/user/cashierInspection.svg', imagePath:
isNotice:false, "https://eshangtech.com/ShopICO/ahyd-BID/user/cashierInspection.svg",
notice:0, isNotice: false,
notice: 0,
value: 4, value: 4,
}, },
], ],
}, },
], ],
isTrue:false,// isTrue: false, //
special:false special: false,
}; };
}, },
components:{ components: {
userList,Tabbar userList,
Tabbar,
}, },
computed: { computed: {
...mapState({ ...mapState({
toDoMsg:(state)=>{return state.toDoMsg}, toDoMsg: (state) => {
user: (state)=>{ return state.userData}, return state.toDoMsg;
phone: (state)=>{ },
let phoneStr = state.userData.Membership_Phone user: (state) => {
if(phoneStr){ return state.userData;
return phoneStr.substr(0,3)+' **** '+phoneStr.substr(phoneStr.length-2,phoneStr.length-1) },
}else { phone: (state) => {
return '' let phoneStr = state.userData.Membership_Phone;
if (phoneStr) {
return (
phoneStr.substr(0, 3) +
" **** " +
phoneStr.substr(phoneStr.length - 2, phoneStr.length - 1)
);
} else {
return "";
} }
}, },
}),
})
}, },
onLoad(){ onLoad() {
// //
let systemInfo = uni.getSystemInfoSync() let systemInfo = uni.getSystemInfoSync();
this.statusBarHeight = Number(systemInfo.statusBarHeight) this.statusBarHeight = Number(systemInfo.statusBarHeight);
// //
this.menu = uni.getMenuButtonBoundingClientRect() this.menu = uni.getMenuButtonBoundingClientRect();
this.handleGetWarningList() this.handleGetWarningList();
this.dataList[2].list.forEach(item=>{ this.dataList[2].list.forEach((item) => {
for(let key in this.user.AuthorityInfo){ for (let key in this.user.AuthorityInfo) {
if (key === item.id){ if (key === item.id) {
if (this.user.AuthorityInfo[key]===1){ if (this.user.AuthorityInfo[key] === 1) {
item.isNotice = true item.isNotice = true;
} }
} }
} }
if(item.id==='a927bf4d-f924-4034-b964-d1a8bd401d09'){ if (item.id === "a927bf4d-f924-4034-b964-d1a8bd401d09") {
item.isNotice = true item.isNotice = true;
} }
}) });
// //
this.dataList[3].list.forEach(item=>{ this.dataList[3].list.forEach((item) => {
for(let key in this.user.AuthorityInfo){ for (let key in this.user.AuthorityInfo) {
if (key === item.id){ if (key === item.id) {
if (this.user.AuthorityInfo[key]===1){ if (this.user.AuthorityInfo[key] === 1) {
item.isNotice = true item.isNotice = true;
} }
} }
} }
}) });
// //
this.dataList[2].list.forEach(item=>{ this.dataList[2].list.forEach((item) => {
for(let key in this.toDoMsg){ for (let key in this.toDoMsg) {
if (key === item.id){ if (key === item.id) {
item.notice = this.toDoMsg[key] item.notice = this.toDoMsg[key];
} }
} }
}) });
this.dataList[3].list.forEach(item=>{ this.dataList[3].list.forEach((item) => {
for(let key in this.toDoMsg){ for (let key in this.toDoMsg) {
if (key === item.id){ if (key === item.id) {
item.notice = this.toDoMsg[key] item.notice = this.toDoMsg[key];
} }
} }
}) });
// //
let userInfo = uni.getStorageSync('vuex') let userInfo = uni.getStorageSync("vuex");
if (userInfo.userData.AuthorityInfo['89a1f248-2113-4d57-84b1-c2e6edb9e8ee']===1){ if (
this.isTrue = true userInfo.userData.AuthorityInfo[
}else{ "89a1f248-2113-4d57-84b1-c2e6edb9e8ee"
this.isTrue = false ] === 1
) {
this.isTrue = true;
} else {
this.isTrue = false;
uni.navigateTo({ uni.navigateTo({
url:`/pages/commercialBI/noData?type=index` url: `/pages/commercialBI/noData?type=index`,
}) });
} }
}, },
onShow(){ onShow() {
uni.hideTabBar() uni.hideTabBar();
}, },
onUnload() { onUnload() {
this.$util.addUserBehavior() this.$util.addUserBehavior();
}, },
methods:{ methods: {
...mapActions(['getTodoList']), ...mapActions(["getTodoList"]),
toPage(url) { toPage(url) {
if (this.isTrue === true){ if (this.isTrue === true) {
this.$util.toNextRoute('navigateTo', url) this.$util.toNextRoute("navigateTo", url);
}else{ } else {
uni.showToast({ uni.showToast({
title: '暂无权限请联系管理员', title: "暂无权限请联系管理员",
icon: 'none' icon: "none",
}) });
} }
}, },
// //
handleGetPhone(value) { handleGetPhone(value) {
return value.substring(0, 3) + '****' + value.substring(7) return value.substring(0, 3) + "****" + value.substring(7);
}, },
handleGoEmpower(){ handleGoEmpower() {
this.$util.toNextRoute('navigateTo', '/pages/register/register') this.$util.toNextRoute("navigateTo", "/pages/register/register");
}, },
handleNews(){ handleNews() {
if (this.special){ if (this.special) {
this.$util.toNextRoute('navigateTo', '/pages/commercialBI/specialCase') this.$util.toNextRoute("navigateTo", "/pages/commercialBI/specialCase");
} }
}, },
handleGetWarningList(){ handleGetWarningList() {
const date = new Date() const date = new Date();
// //
let h = date.getHours() - 1 let h = date.getHours() - 1;
const req= { const req = {
// this.single // this.single
StatisticsDate: this.lastDay, StatisticsDate: this.lastDay,
StatisticsHour:h, StatisticsHour: h,
StatisticsType:1, StatisticsType: 1,
ShowCount:20 ShowCount: 20,
};
request
.$webGet("CommercialApi/BigData/GetBayonetWarning", req)
.then((res) => {
if (res.Result_Data.List.length > 0) {
this.special = true;
} }
request.$webGet('CommercialApi/BigData/GetBayonetWarning',req).then(res=>{ });
if (res.Result_Data.List.length>0){
this.special = true
}
})
}, },
}, },
} };
</script> </script>
<style scoped lang="scss"> <style scoped lang="scss">
@ -429,16 +513,17 @@ import Tabbar from "../../components/tabbar/tabbar.vue";
height: 280px; height: 280px;
background: linear-gradient(315deg, #ff8d95 0%, #ffdca8 100%); background: linear-gradient(315deg, #ff8d95 0%, #ffdca8 100%);
position: relative; position: relative;
.headerTop{ .headerTop {
width: 100%; width: 100%;
background: linear-gradient(260deg, #FEA199 0%, #FFD6A7 100%); background: linear-gradient(260deg, #fea199 0%, #ffd6a7 100%);
position: fixed; position: fixed;
top: 0;left:0; top: 0;
left: 0;
box-sizing: border-box; box-sizing: border-box;
padding: 0 15px; padding: 0 15px;
z-index:9999999; z-index: 9999999;
} }
.news{ .news {
width: 24px; width: 24px;
height: 24px; height: 24px;
position: absolute; position: absolute;
@ -447,21 +532,22 @@ import Tabbar from "../../components/tabbar/tabbar.vue";
display: flex; display: flex;
justify-content: center; justify-content: center;
align-items: center; align-items: center;
.box{ .box {
width: 100%; width: 100%;
height: 100%; height: 100%;
position: relative; position: relative;
.img{ .img {
width: 100%; width: 100%;
height: 100%; height: 100%;
} }
.red{ .red {
position: absolute; position: absolute;
width: 8px; width: 8px;
height: 8px; height: 8px;
background: #D7000F; background: #d7000f;
border-radius: 50%; border-radius: 50%;
right:0;top: 4px; right: 0;
top: 4px;
} }
} }
} }
@ -483,7 +569,7 @@ import Tabbar from "../../components/tabbar/tabbar.vue";
background-size: cover; background-size: cover;
padding: 16px 0 0 16px; padding: 16px 0 0 16px;
position: relative; position: relative;
.userBgImg{ .userBgImg {
position: absolute; position: absolute;
left: 0; left: 0;
top: 0; top: 0;
@ -507,7 +593,7 @@ import Tabbar from "../../components/tabbar/tabbar.vue";
} }
} }
.message { .message {
flex:1; flex: 1;
.people { .people {
display: flex; display: flex;
align-items: center; align-items: center;
@ -526,7 +612,7 @@ import Tabbar from "../../components/tabbar/tabbar.vue";
border-radius: 5px; border-radius: 5px;
overflow: hidden; overflow: hidden;
padding: 0 5px; padding: 0 5px;
border:1px solid #FEA001; border: 1px solid #fea001;
//background: linear-gradient(134deg, rgba(255, 165, 0, 1), rgba(220, 55, 7, 1)); //background: linear-gradient(134deg, rgba(255, 165, 0, 1), rgba(220, 55, 7, 1));
.personName { .personName {
display: flex; display: flex;
@ -565,7 +651,11 @@ import Tabbar from "../../components/tabbar/tabbar.vue";
.other { .other {
width: 100%; width: 100%;
height: 40px; height: 40px;
background: linear-gradient(315deg, rgba(255, 141, 149, 0.2), rgba(255, 220, 168, 0.2)); background: linear-gradient(
315deg,
rgba(255, 141, 149, 0.2),
rgba(255, 220, 168, 0.2)
);
display: flex; display: flex;
align-items: center; align-items: center;
justify-content: space-between; justify-content: space-between;
@ -592,7 +682,7 @@ import Tabbar from "../../components/tabbar/tabbar.vue";
} }
} }
.item:first-child:after { .item:first-child:after {
content: ''; content: "";
width: 1px; width: 1px;
height: 24px; height: 24px;
background: #782717; background: #782717;
@ -611,7 +701,7 @@ import Tabbar from "../../components/tabbar/tabbar.vue";
padding: 24px 16px calc(env(safe-area-inset-bottom) + 82px) 16px; padding: 24px 16px calc(env(safe-area-inset-bottom) + 82px) 16px;
position: relative; position: relative;
border-radius: 32rpx 32rpx 2rpx 2rpx; border-radius: 32rpx 32rpx 2rpx 2rpx;
.main{ .main {
.title { .title {
font-size: 34rpx; font-size: 34rpx;
font-family: PingFangSC-Semibold, PingFang SC; font-family: PingFangSC-Semibold, PingFang SC;
@ -648,13 +738,13 @@ import Tabbar from "../../components/tabbar/tabbar.vue";
} }
} }
.firstBg_1 { .firstBg_1 {
background: url('https://eshangtech.com/ShopICO/ahyd-BID/index/firstBg_1.png'); background: url("https://eshangtech.com/ShopICO/ahyd-BID/index/firstBg_1.png");
} }
.firstBg_2 { .firstBg_2 {
background: url('https://eshangtech.com/ShopICO/ahyd-BID/index/firstBg_2.png'); background: url("https://eshangtech.com/ShopICO/ahyd-BID/index/firstBg_2.png");
} }
.firstBg_3 { .firstBg_3 {
background: url('https://eshangtech.com/ShopICO/ahyd-BID/index/firstBg_3.png'); background: url("https://eshangtech.com/ShopICO/ahyd-BID/index/firstBg_3.png");
} }
} }
.second { .second {

View File

@ -20,7 +20,6 @@ export default {
* @return {Promise} promise 返回promise供后续操作 * @return {Promise} promise 返回promise供后续操作
*/ */
request: function (method, url, data, isWebApi) { request: function (method, url, data, isWebApi) {
var promise = new Promise((resolve, reject) => { var promise = new Promise((resolve, reject) => {
//init //init
Store.state.isLoading = true Store.state.isLoading = true
@ -35,8 +34,6 @@ export default {
data.memberShipId = !data.memberShipId ? (Store.state.userData.Membership_Id || '') : data.memberShipId = !data.memberShipId ? (Store.state.userData.Membership_Id || '') :
data.memberShipId // ||'3255' 1170386 1125717 // data.memberShipId // ||'3255' 1170386 1125717 //
let requstOptions = { let requstOptions = {
url: url, url: url,
data: data, data: data,
@ -74,7 +71,7 @@ export default {
'WeChat_AppId': 'wxa99ef047735c031e', 'WeChat_AppId': 'wxa99ef047735c031e',
'memberShipId': !data.memberShipId ? (Store.state.userData.Membership_Id || '') : data.memberShipId, 'memberShipId': !data.memberShipId ? (Store.state.userData.Membership_Id || '') : data.memberShipId,
'SourcePlatform': 'minProgram', 'SourcePlatform': 'minProgram',
"UserID": Store.state.userData.UserIdEncrypted, "UserId": Store.state.userData.UserId,
} }
} }
requstOptions.success = (res) => { requstOptions.success = (res) => {