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

@ -127,7 +127,8 @@ function noDecimal(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) {
@ -200,6 +212,7 @@ function addUserBehavior(obj) {
})
}
function addUserBehaviorNew(obj) {
var pages = getCurrentPages() // 获取加载的页面
@ -270,10 +283,19 @@ function getThisMonthDay(value){
flag = true
}
switch (m) {
case 1: case 3: case 5: case 7: case 8: case 10: case 12:
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:
case 4:
case 6:
case 9:
case 11:
howDay = 30
break
case 2:
@ -361,10 +383,19 @@ function getThisMonthDateList(value){
flag = true
}
switch (m) {
case 1: case 3: case 5: case 7: case 8: case 10: case 12:
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:
case 4:
case 6:
case 9:
case 11:
howDay = 30
break
case 2:
@ -380,7 +411,10 @@ function getThisMonthDateList(value){
if (i > howDay) {
break
} 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
@ -579,6 +613,7 @@ export default {
getThisTimeMonth,
handleGetMonthDay,
fmoney,
formatNumber,
noDecimal,
changeStringToDate,
toNextRoute,

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,17 +161,40 @@ 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;
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

View File

@ -2,17 +2,37 @@
<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' }">
<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>
<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>
@ -40,7 +60,12 @@
</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>
@ -48,210 +73,253 @@
</template>
<script>
import request from '@/util/index.js'
import {mapActions, mapState} from 'vuex'
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)
const lastDay = this.$util.cutDate(new Date(), "YYYY-MM-DD", -1);
return {
page:'/pages/userCenter/userCenter',
statusBarHeight:'',
menu:'',
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 },],
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: '商业经营',
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',
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: '节日特刊',
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',
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',
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: '商业画像',
name: "商业画像",
value: 2,
list: [
{
id:'',
name: '车流',
homeUrl: '/pages/commercialBINew/carPortrait',
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/user/traffic.svg',
isNotice:'',
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:'',
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:'',
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:'',
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:'',
id: "",
name: "品牌",
homeUrl: "/pages/commercialBI/formatPortrait",
imagePath:
"https://eshangtech.com/ShopICO/ahyd-BID/user/brand.svg",
isNotice: "",
type: 5,
value: 2,
},
],
},
{
name: '业务审批',
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',
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,
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/user/bidding.svg',
},
{
id:'8fea5036-d67e-476e-9e56-5f379ba6ae18',
name: '服务区报销',
homeUrl: '/pages/serviceAreaReimbursement/serviceAreaReimbursement',
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/serviceAreaReimbur.svg',
imagePath:
"https://eshangtech.com/ShopICO/ahyd-BID/user/bidding.svg",
},
{
id:'ac661db4-1af1-4732-88db-76bc05eec335',
name: '合同审批',
homeUrl: '/pages/contract/contract',
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/contractApproval.svg',
imagePath:
"https://eshangtech.com/ShopICO/ahyd-BID/user/serviceAreaReimbur.svg",
},
{
id:'056b29d7-4721-47ee-ad25-660814e1f3a9',
name: '商品审批',
homeUrl: '/pages/businessApproval/businessApproval',
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/productApproval.svg',
imagePath:
"https://eshangtech.com/ShopICO/ahyd-BID/user/contractApproval.svg",
},
{
id:'2290e96d-c6d7-4dde-b5b7-e699b615ff2f',
name: '招商审批',
homeUrl: '/pages/investment/investment',
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/promotionApproval.svg',
imagePath:
"https://eshangtech.com/ShopICO/ahyd-BID/user/productApproval.svg",
},
{
id:'c802a38f-3bbd-4db0-89b6-34e404c8d8cc',
name: '权限审批',
homeUrl: '/pages/authorityApproval/index',
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/authorityApproval.svg',
imagePath:
"https://eshangtech.com/ShopICO/ahyd-BID/user/promotionApproval.svg",
},
{
id:'b0b63a75-56c9-4f1d-aacb-a26e62b47e3e',
name: '数据校验',
homeUrl: '/pages/dataSummary/dataSummary',
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/dataVerification.svg',
imagePath:
"https://eshangtech.com/ShopICO/ahyd-BID/user/authorityApproval.svg",
},
{
id:'b0b63a75-56c9-4f1d-aacb-a26e62b47e3e',
name: '分润切换',
homeUrl: '/pages/projectWarning/index',
id: "b0b63a75-56c9-4f1d-aacb-a26e62b47e3e",
name: "数据校验",
homeUrl: "/pages/dataSummary/dataSummary",
notice: 0,
value: 3,
isNotice: false,
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/index/changeMoney.svg',
imagePath:
"https://eshangtech.com/ShopICO/ahyd-BID/user/dataVerification.svg",
},
{
id:'a927bf4d-f924-4034-b964-d1a8bd401d09',
name: '结算审批',
homeUrl: '/pages/settlementApproval/index',
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',
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: '现场管理',
name: "现场管理",
value: 4,
list: [
{
id:'',
name: '基础信息',
homeUrl: '/pages/map/detail?come=user',
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/user/basicInformation.svg',
id: "",
name: "基础信息",
homeUrl: "/pages/map/detail?come=user",
imagePath:
"https://eshangtech.com/ShopICO/ahyd-BID/user/basicInformation.svg",
isNotice: true,
notice: 0,
type: 0,
@ -259,10 +327,11 @@ import Tabbar from "../../components/tabbar/tabbar.vue";
value: 4,
},
{
id:'30f0e7d0-4e01-4a63-a65b-613e1f427335',
name: '考评考核',
homeUrl: '/pages/examine/index',
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/user/assessment.svg',
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,
@ -270,19 +339,21 @@ import Tabbar from "../../components/tabbar/tabbar.vue";
value: 4,
},
{
id:'d405ae13-3388-41c0-a5f6-d11194d0a943',
name: '投诉建议',
homeUrl: '/pages/suggestion/suggestion',
imagePath: 'https://eshangtech.com/ShopICO/ahyd-BID/user/complaintSuggest.svg',
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',
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,
@ -291,132 +362,145 @@ import Tabbar from "../../components/tabbar/tabbar.vue";
},
],
isTrue: false, //
special:false
special: false,
};
},
components: {
userList,Tabbar
userList,
Tabbar,
},
computed: {
...mapState({
toDoMsg:(state)=>{return state.toDoMsg},
user: (state)=>{ return state.userData},
toDoMsg: (state) => {
return state.toDoMsg;
},
user: (state) => {
return state.userData;
},
phone: (state) => {
let phoneStr = state.userData.Membership_Phone
let phoneStr = state.userData.Membership_Phone;
if (phoneStr) {
return phoneStr.substr(0,3)+' **** '+phoneStr.substr(phoneStr.length-2,phoneStr.length-1)
return (
phoneStr.substr(0, 3) +
" **** " +
phoneStr.substr(phoneStr.length - 2, phoneStr.length - 1)
);
} else {
return ''
return "";
}
},
})
}),
},
onLoad() {
//
let systemInfo = uni.getSystemInfoSync()
this.statusBarHeight = Number(systemInfo.statusBarHeight)
let systemInfo = uni.getSystemInfoSync();
this.statusBarHeight = Number(systemInfo.statusBarHeight);
//
this.menu = uni.getMenuButtonBoundingClientRect()
this.handleGetWarningList()
this.dataList[2].list.forEach(item=>{
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
item.isNotice = true;
}
}
}
if(item.id==='a927bf4d-f924-4034-b964-d1a8bd401d09'){
item.isNotice = true
if (item.id === "a927bf4d-f924-4034-b964-d1a8bd401d09") {
item.isNotice = true;
}
})
});
//
this.dataList[3].list.forEach(item=>{
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
item.isNotice = true;
}
}
}
})
});
//
this.dataList[2].list.forEach(item=>{
this.dataList[2].list.forEach((item) => {
for (let key in this.toDoMsg) {
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) {
if (key === item.id) {
item.notice = this.toDoMsg[key]
item.notice = this.toDoMsg[key];
}
}
})
});
//
let userInfo = uni.getStorageSync('vuex')
if (userInfo.userData.AuthorityInfo['89a1f248-2113-4d57-84b1-c2e6edb9e8ee']===1){
this.isTrue = true
let userInfo = uni.getStorageSync("vuex");
if (
userInfo.userData.AuthorityInfo[
"89a1f248-2113-4d57-84b1-c2e6edb9e8ee"
] === 1
) {
this.isTrue = true;
} else {
this.isTrue = false
this.isTrue = false;
uni.navigateTo({
url:`/pages/commercialBI/noData?type=index`
})
url: `/pages/commercialBI/noData?type=index`,
});
}
},
onShow() {
uni.hideTabBar()
uni.hideTabBar();
},
onUnload() {
this.$util.addUserBehavior()
this.$util.addUserBehavior();
},
methods: {
...mapActions(['getTodoList']),
...mapActions(["getTodoList"]),
toPage(url) {
if (this.isTrue === true) {
this.$util.toNextRoute('navigateTo', url)
this.$util.toNextRoute("navigateTo", url);
} else {
uni.showToast({
title: '暂无权限请联系管理员',
icon: 'none'
})
title: "暂无权限请联系管理员",
icon: "none",
});
}
},
//
handleGetPhone(value) {
return value.substring(0, 3) + '****' + value.substring(7)
return value.substring(0, 3) + "****" + value.substring(7);
},
handleGoEmpower() {
this.$util.toNextRoute('navigateTo', '/pages/register/register')
this.$util.toNextRoute("navigateTo", "/pages/register/register");
},
handleNews() {
if (this.special) {
this.$util.toNextRoute('navigateTo', '/pages/commercialBI/specialCase')
this.$util.toNextRoute("navigateTo", "/pages/commercialBI/specialCase");
}
},
handleGetWarningList() {
const date = new Date()
const date = new Date();
//
let h = date.getHours() - 1
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=>{
ShowCount: 20,
};
request
.$webGet("CommercialApi/BigData/GetBayonetWarning", req)
.then((res) => {
if (res.Result_Data.List.length > 0) {
this.special = true
this.special = true;
}
})
});
},
},
}
};
</script>
<style scoped lang="scss">
@ -431,9 +515,10 @@ import Tabbar from "../../components/tabbar/tabbar.vue";
position: relative;
.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;
@ -459,9 +544,10 @@ import Tabbar from "../../components/tabbar/tabbar.vue";
position: absolute;
width: 8px;
height: 8px;
background: #D7000F;
background: #d7000f;
border-radius: 50%;
right:0;top: 4px;
right: 0;
top: 4px;
}
}
}
@ -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;
@ -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) => {