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

View File

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

View File

@ -31,7 +31,12 @@
</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
v-for="(item, index) in pageList"
:key="index"
@ -87,6 +92,12 @@
</view>
</view>
</view>
<!-- 底部提示 -->
<view class="load-more" v-if="pageList.length > 0">
<text>{{
!pageMsg.isOver ? "正在加载,请稍后..." : "——— 我是有底线的 ———"
}}</text>
</view>
</scroll-view>
<!-- 无数据时的页面显示 -->
<view v-else>
@ -97,12 +108,7 @@
<!-- <text name="other">请选择其它日期进行查询</text> -->
</noFound>
</view>
<!-- 底部提示 -->
<view class="load-more" v-if="pageList.length > 0">
<text>{{
!pageData.isEnd ? "正在加载,请稍后..." : "——— 我是有底线的 ———"
}}</text>
</view>
<uni-popup
:show="showPop"
@hidePopup="closePop"
@ -156,57 +162,11 @@ export default {
pageMsg: {
pageSize: 10,
pageIndex: 1,
isOver: false,
}, //
searchText: "", //
BillState: "", // 1 0
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: "肖方俊【龙门寺服务区】",
},
{},
{},
{},
{},
{},
{},
], //
pageList: [], //
activeType: 0, //
menuList: [
{
@ -236,7 +196,7 @@ export default {
},
onLoad() {
//
// this.handleGetList();
this.handleGetList();
},
onShow() {
if (!this.isFirst) {
@ -247,6 +207,11 @@ export default {
}
},
methods: {
//
handleScrolltolower() {
this.pageMsg.pageIndex = this.pageMsg.pageIndex + 1;
this.handleGetList();
},
//
async handleGetList() {
const req = {
@ -271,12 +236,20 @@ export default {
);
console.log("list", data);
let list = data.Result_Data.List;
if (list && list.length > 0) {
this.pageList = list;
} else {
this.pageList = [];
let oldList = [];
if (this.pageList && this.pageList.length > 0) {
oldList = 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();
},
//
@ -289,6 +262,15 @@ export default {
// tab
handleClick(obj) {
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
.curYearData || "-"
}}</text>
<text class="label">{{(Math.floor(index / 12) + 2023)}}/万元</text>
<text class="label"
>{{ Math.floor(index / 12) + 2023 }}/万元</text
>
</div>
<div class="rightBox carRight">
<text class="value">{{
selectVersion3Obj["累计"].RevenueINC.lYearData ||
"-"
}}</text>
<text class="label">{{(Math.floor(index / 12) + 2022)}}/万元</text>
<text class="label"
>{{ Math.floor(index / 12) + 2022 }}/万元</text
>
</div>
<img
class="pkLogo"
@ -1304,14 +1308,18 @@
selectVersion3Obj["累计"].AccountINC
.curYearData || "-"
}}</text>
<text class="label">{{(Math.floor(index / 12) + 2023)}}/万元</text>
<text class="label"
>{{ Math.floor(index / 12) + 2023 }}/万元</text
>
</div>
<div class="rightBox qmCarRight">
<text class="value">{{
selectVersion3Obj["累计"].AccountINC.lYearData ||
"-"
}}</text>
<text class="label">{{(Math.floor(index / 12) + 2022)}}/万元</text>
<text class="label"
>{{ Math.floor(index / 12) + 2022 }}/万元</text
>
</div>
<img
class="pkLogo"
@ -1405,14 +1413,18 @@
selectVersion3Obj["累计"].BayonetINC
.curYearData || "-"
}}</text>
<text class="label">{{(Math.floor(index / 12) + 2023)}}/万元</text>
<text class="label"
>{{ Math.floor(index / 12) + 2023 }}/万元</text
>
</div>
<div class="rightBox summerHolidayRightBox">
<text class="value">{{
selectVersion3Obj["累计"].BayonetINC.lYearData ||
"-"
}}</text>
<text class="label">{{(Math.floor(index / 12) + 2022)}}/万元</text>
<text class="label"
>{{ Math.floor(index / 12) + 2022 }}/万元</text
>
</div>
<img
class="pkLogo"
@ -4694,9 +4706,10 @@
</view>
</view>
<!-- <view
<view
class="funItem"
style="margin-top: 32rpx"
v-if="false"
@click="goToBillLading"
>
<view class="funItemContent">
@ -4708,7 +4721,7 @@
</view>
<text class="funText">提单申请</text>
</view>
</view> -->
</view>
<!-- 数智统计-->
<view
@ -6226,7 +6239,7 @@ export default {
this.$util.toNextRoute("navigateTo", `/pages/robot/index`);
// this.$util.toNextRoute("navigateTo", `/pages/testPage/index`);
},
goToBillLading(){
goToBillLading() {
this.$util.toNextRoute("navigateTo", `/pages/billOfLading/index`);
},
handleShowTrafficDetail() {

View File

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

View File

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