This commit is contained in:
cclu 2023-06-15 14:28:15 +08:00
parent abec264df9
commit 980b0b77e1
15 changed files with 2277 additions and 686 deletions

View File

@ -179,7 +179,6 @@ function addUserBehavior(obj) {
} }
obj.visitChannels = store.state.visitChannels obj.visitChannels = store.state.visitChannels
let userDate = store.state.userData let userDate = store.state.userData
console.log('userDate123',userDate)
let req = { let req = {
userName:userDate.UserName, userName:userDate.UserName,
phoneNumber:userDate.Membership_Phone, phoneNumber:userDate.Membership_Phone,
@ -190,7 +189,6 @@ function addUserBehavior(obj) {
visitChannels:obj.visitChannels, visitChannels:obj.visitChannels,
behaviorRecordDesc:'' behaviorRecordDesc:''
} }
console.log('req',req)
request.$webGet('CommercialApi/UserBehavior/AddUserBehavior',req).then(() => { request.$webGet('CommercialApi/UserBehavior/AddUserBehavior',req).then(() => {
}) })

View File

@ -110,7 +110,8 @@
"path": "formatPortrait", "path": "formatPortrait",
"style": { "style": {
"navigationBarTitleText": "", "navigationBarTitleText": "",
"navigationStyle": "custom" "navigationStyle": "custom",
"disableScroll": true
} }
}, },
{ {
@ -156,6 +157,22 @@
"navigationBarTitleText": "", "navigationBarTitleText": "",
"navigationStyle": "custom" "navigationStyle": "custom"
} }
},
{
"path": "formatDetail",
"style": {
"navigationBarTitleText": "",
"navigationStyle": "custom",
"disableScroll": true
}
},
{
"path": "shopDetail",
"style": {
"navigationBarTitleText": "",
"navigationStyle": "custom",
"disableScroll": true
}
} }
] ]
}, },

View File

@ -227,8 +227,9 @@ export default {
m = '0' + m m = '0' + m
} }
this.thisMonth = m this.thisMonth = m
//
let systemInfo = uni.getSystemInfoSync() let systemInfo = uni.getSystemInfoSync()
//
this.statusBarHeight = Number(systemInfo.statusBarHeight)
// //
uni.setStorageSync('phoneInfo',systemInfo) uni.setStorageSync('phoneInfo',systemInfo)
this.statusBarHeight = Number(systemInfo.statusBarHeight) this.statusBarHeight = Number(systemInfo.statusBarHeight)

View File

@ -0,0 +1,614 @@
<template>
<div class="main">
<div class="header">
<div class="headerBox">
<div class="headerTop" :style="{height:(menu.bottom + 6) + 'px'}">
<div class="box" :style="{top:(menu.bottom - (menu.height / 2)) + 'px'}">
<div class="icon" @click="handleBack">
<image class="img" src="https://eshangtech.com/ShopICO/ahyd-BID/examine/leftArrowWhite.svg"></image>
</div>
<text class="title">品牌详情</text>
<div class="seize"></div>
</div>
</div>
<div class="detail" :style="{top:(menu.bottom + 22) + 'px'}">
<div class="box" >
<div class="left">
<image v-if="detail.BRAND_STATE === 1" class="img" :src="detail.BRAND_INTRO"></image>
</div>
<div class="right">
<div class="top">
<text class="title" :style="{fontSize:detail.BRAND_NAME.length>8?'12px':'16px'}">{{detail.BRAND_NAME}}</text>
<image class="icon" src="https://eshangtech.com/ShopICO/ahyd-BID/brand/effective.svg"></image>
</div>
<div class="descBox">
<text class="desc">{{detail.BRAND_DESC}}</text>
<text v-if="detail.BRAND_DESC.length>11" class="more" @click="handleMore($event)">展开</text>
</div>
<div class="labelList">
<!-- <text class="labelItem">美食排行榜</text>-->
<!-- <text class="labelItem">这是标签</text>-->
<!-- <text class="labelItem">这是标签标签</text>-->
</div>
<div class="typeList">
<text class="typeItem">{{detail.BUSINESSTRADE_NAME}}</text>
<text class="typeItem">{{detail.BRAND_TYPENAME}}</text>
</div>
<div class="suggest">
<text class="value">{{detail.COMMISSION_RATIO}}</text>
<text class="text">建议提成比例</text>
</div>
</div>
<div class="typeBox">
<image class="typeIcon" src="https://eshangtech.com/ShopICO/ahyd-BID/brand/foodIcon.svg"></image>
<text class="text">服务区</text>
<text class="number">{{detail.ServerpartList.length}}</text>
</div>
</div>
</div>
</div>
</div>
<div class="businessProject" >
<div class="top">
<text class="projectTitle">经营项目</text>
<text v-if="serviceList && serviceList.length>0" class="number">({{`${serviceList.length}`}})</text>
</div>
<scroll-view class="list" scroll-y="true" :scroll-with-animation="true">
<div class="listItem" v-for="(item,index) in serviceList" :key="index" @click="handleShopDetail(item)">
<div class="itemTop">
<div class="left">
<div class="iconBox">
<image class="icon" src="https://eshangtech.com/ShopICO/ahyd-BID/brand/servicePosition.svg"></image>
</div>
<div class="content">
<text class="name">{{item.SERVERPART_NAME}}</text>
<div class="type">
<image class="typeIcon" src="https://eshangtech.com/ShopICO/ahyd-BID/brand/typeIcon.svg"></image>
<text class="text">{{item.SERVERPART_TYPE}}</text>
</div>
</div>
</div>
<div class="right">
<text class="price">{{item.SECTIONFLOW_NUM}}</text>
<text class="unit">断面流量</text>
</div>
</div>
<div class="itemContent">
<div class="contentTop">
<div class="left">
<text class="itemTitle">{{item.BUSINESSPROJECT_NAME || '-'}}</text>
<div class="typeBox" v-if="item.COMMODITY_COUNT > 0">
<!-- <image class="icon" src="https://eshangtech.com/ShopICO/ahyd-BID/brand/store.svg"></image>-->
<!-- <text class="typeName">在售商品</text>-->
</div>
</div>
<div class="right">
<text class="price">{{item.PROJECT_AMOUNT || '0'}}</text>
<text class="unit" >( 万元 )</text>
</div>
</div>
<div class="bottomItem">
<image class="bottomIcon" src="https://eshangtech.com/ShopICO/ahyd-BID/brand/storeIcon.svg"></image>
<text class="text">{{item.COOPMERCHANTS_NAME || '-'}}</text>
</div>
<div class="bottomItem">
<image class="bottomIcon" src="https://eshangtech.com/ShopICO/ahyd-BID/brand/fixed.svg"></image>
<text class="text">{{item.SERVERPARTSHOP_NAME || '-'}}</text>
</div>
<div class="bottomItem">
<image class="bottomIcon" src="https://eshangtech.com/ShopICO/ahyd-BID/brand/date.svg"></image>
<text class="text">{{ item.PROJECT_STARTDATE && item.PROJECT_ENDDATE ?`${item.PROJECT_STARTDATE}-${item.PROJECT_ENDDATE}`:'-' }}</text>
</div>
</div>
</div>
</scroll-view>
</div>
<div class="meng" v-if="isShow" @click="handleClose">
<div class="descPopup" :style="{top:descTop +'px',left:(descLeft - 130)+'px'}">
{{detail.BRAND_DESC}}
</div>
</div>
</div>
</template>
<script>
import request from '@/util/index.js'
export default {
name: "formatDetail",
data() {
return {
menu:{},
detail:{},//
serviceList:[],//
descTop:0,//
descLeft:0,//
isShow: false,//
}
},
onLoad(query){
this.menu = uni.getMenuButtonBoundingClientRect()
console.log('query',query)
console.log('query',JSON.parse(query.detail))
this.detail = JSON.parse(query.detail)
this.handleGetList()
},
methods:{
//s
handleBack(){
uni.navigateBack({
delta: 1
});
},
//
async handleGetList(){
uni.showLoading({
title: '正在加载...'
})
const req = {
BusinessTradeId: this.detail.BRAND_INDUSTRY,
BusinessBrandId: this.detail.BRAND_ID,
}
const data = await request.$webGet(`EShangApiMain/BusinessProject/GetBrandReceivables`,req)
console.log('data',data)
this.serviceList = data.Result_Data.List
this.serviceList.forEach(item=>{
item.SECTIONFLOW_NUM = this.$util.noDecimal(item.SECTIONFLOW_NUM)
})
console.log('this.serviceList',this.serviceList)
uni.hideLoading()
},
handleMore(e){
console.log(e)
this.descTop = e.detail.y + 15
this.descLeft = e.detail.x
this.isShow = true
},
handleClose(){
this.isShow = false
},
handleShopDetail(item){
console.log('item',item)
uni.navigateTo({
url:`/pages/commercialBI/shopDetail?id=${item.COOPMERCHANTS_ID}&COOPMERCHANTSID=${item.COOPMERCHANTS_ID_Encrypted}`
})
}
}
}
</script>
<style scoped lang="scss">
.main{
background: #fff;
.header{
width: 100%;
height: 316px;
background: linear-gradient(180deg, #7660FF 0%, #ABCAFF 100%);
.headerBox{
width: 100%;
height: 100%;
position: relative;
z-index: 1;
.headerTop{
width: 100vw;
position: fixed;
top: 0;
left: 0;
z-index:99999;
.box{
padding: 0 16px;
position: absolute;
box-sizing: border-box;
width: 100%;
display: flex;
justify-content: space-between;
align-items: center;
transform: translateY(-50%);
.icon{
width: 24px;
height: 24px;
.img{
width: 100%;
height: 100%;
}
}
.title{
font-size: 18px;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 600;
color: #fff;
line-height: 28px;
}
.seize{
width: 24px;
height: 24px;
}
}
}
.detail{
width: 100%;
box-sizing: border-box;
padding: 0 16px;
position: absolute;
.box{
width: 100%;
background: linear-gradient(45deg, #E0F3FF 0%, #E7EEFF 29%, #F1F4FF 50%, #E3EAFF 65%, #D8D2FF 100%);
border-radius: 8px;
border: 1px solid #FCFCFF;
box-sizing: border-box;
padding: 12px;
display: flex;
position: relative;
.left{
width: 72px;
height: 72px;
border: 3px solid #fff;
border-radius: 8px;
.img{
width: 100%;
height: 100%;
}
}
.right{
margin-left: 12px;
.top{
display: flex;
align-items: center;
.title{
font-size: 16px;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 600;
color: #051433;
line-height: 22px;
}
.icon{
width: 16px;
height: 16px;
margin-left: 6px;
}
}
.descBox{
display: flex;
align-items: center;
.desc{
width: 150px;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
display: inline-block;
height: 18px;
font-size: 12px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #5C5773;
line-height: 18px;
}
.more{
color: #396CFF;
font-size: 12px
}
}
.labelList{
height: 18px;
display: flex;
margin-top: 4px;
.labelItem{
padding: 0 4px;
background: rgba(57, 108, 255, 0.1);
border-radius: 4rpx;
font-size: 12px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #396CFF;
line-height: 18px;
margin-right:5px
}
}
.typeList{
margin-top: 18px;
border-radius: 2px;
.typeItem{
display: inline-block;
background: linear-gradient(270deg, rgba(90, 199, 255, 0.15) 0%, rgba(90, 193, 255, 0.15) 100%);
font-size: 14px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #0075A1;
line-height: 22px;
margin-right: 8px;
padding: 1px 8px;
}
}
.suggest{
margin-top: 8px;
background: linear-gradient(90deg, rgba(72,119,255,0.15) 0%, rgba(72, 119, 255, 0) 100%);
border-radius: 2px;
box-sizing: border-box;
padding: 4px 8px;
.value{
font-size: 14px;
font-family: DINAlternate-Bold, DINAlternate;
font-weight: bold;
color: #396CFF;
line-height: 16px;
}
.text{
font-size: 12px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #8995B5;
line-height: 18px;
margin-left: 4px;
}
}
}
.typeBox{
display: flex;
align-items: center;
background: linear-gradient(135deg, #77A1FF 0%, #7967FF 100%);
border-radius: 0 8px 0 5px;
padding: 3px 8px;
//border-image: linear-gradient(227deg, rgba(255, 255, 255, 1), rgba(234, 240, 255, 1), rgba(255, 255, 255, 0)) 1 1;
position: absolute;
right: 0;top: 0;
.typeIcon{
width: 14px;
height: 14px;
}
.text{
font-size: 12px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #E3DEFF;
line-height: 18px;
margin-left: 4px;
}
.number{
font-size: 14px;
font-family: DINAlternate-Bold, DINAlternate;
font-weight: bold;
color: #FFFFFF;
margin-left: 8px;
}
}
}
}
}
}
.businessProject{
width: 100%;
transform: translateY(-16px);
height: calc(100vh - 316px);
border-top-left-radius: 16px;
border-top-right-radius: 16px;
background: #fff;
box-sizing: border-box;
padding: 16px;
.top{
display: flex;
align-items: center;
.projectTitle{
font-size: 17px;
font-family: PingFangSC-Semibold, PingFang SC;
font-weight: 600;
color: #051433;
line-height: 24px
}
.number{
font-size: 14px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #786B6C;
line-height: 20px;
margin-left: 4px;
}
}
.list{
width: 100%;
height: calc(100vh - 372px);
margin-top: 8px;
.listItem{
width: 100%;
border-radius: 8px;
border: 1px solid #E8E7FF;
box-sizing: border-box;
overflow: hidden;
display: flex;
flex-direction: column;
margin-bottom: 12px;
background: linear-gradient(207deg, rgba(202, 202, 255, 0.25) 0%, rgba(243, 242, 255, 0.25) 100%);
.itemTop{
width: 100%;
height: 60px;
background: linear-gradient(270deg, #EBECFF 0%, #E9F9FF 100%);
padding: 8px;
box-sizing: border-box;
display: flex;
justify-content: space-between;
.left{
display: flex;
align-items: center;
.iconBox{
width: 36px;
height: 36px;
border: 2px solid #fff;
border-radius: 50%;
.icon{
width: 100%;
height: 100%;
}
}
.content{
margin-left: 16px;
.name{
font-size: 16px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #051433;
line-height: 22px;
}
.type{
width: 48px;
height: 16px;
border: 1px solid #4F92FF;
display: flex;
align-items: center;
border-radius: 3px;
.typeIcon{
width: 21px;
height: 100%;
}
.text{
font-size: 12px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #6370FF;
line-height: 12px;
margin-left: 2px;
}
}
}
}
.right{
display: flex;
flex-direction: column;
.price{
font-size: 18px;
font-family: DINAlternate-Bold, DINAlternate;
font-weight: bold;
color: #683FF6;
line-height: 22px;
text-align: right;
}
.unit{
font-size: 14px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #A3A2B9;
line-height: 18px;
}
}
}
.itemContent{
width: 100%;
flex: 1;
box-sizing: border-box;
padding: 16px 12px;
.contentTop{
width: 100%;
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 16px;
.left{
width: 80%;
.itemTitle{
font-size: 14px;
font-family: PingFangSC-Semibold, PingFang SC;
font-weight: 600;
color: #051433;
line-height: 20px;
}
.typeBox{
display: flex;
align-items: center;
margin-top: 4px;
.icon{
width: 18px;
height: 18px;
}
.typeName{
font-size: 12px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #5C5773;
line-height: 18px;
margin-left: 4px;
}
}
}
.right{
display: flex;
flex-direction: column;
width: 20%;
.price{
font-size: 18px;
font-family: DINAlternate-Bold, DINAlternate;
font-weight: bold;
color: #683FF6;
line-height: 22px;
text-align: right;
}
.unit{
font-size: 12px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #ABA9B9;
line-height: 18px;
text-align: right;
}
}
}
.bottomItem{
display: flex;
align-items: flex-start;
margin-bottom: 4px;
.bottomIcon{
width: 16px;
height: 16px;
margin-right: 4px;
margin-top: 2px;
}
.text{
flex: 1;
font-size: 14px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #5C5773;
line-height: 22px;
}
}
}
}
::-webkit-scrollbar {
width: 4px;
height: 4px;
color:transparent;
}
/*定义滚动条轨道 内阴影+圆角*/
::-webkit-scrollbar-track {
border-radius: 10px;
background-color:transparent;
}
/*定义滑块 内阴影+圆角*/
::-webkit-scrollbar-thumb {
border-radius: 10px;
background-color:transparent;
}
}
}
.meng{
position: relative;
width: 100vw;
height: 100vh;
top: -100vh;left: 0;
z-index: 99;
.descPopup{
width: 200px;
background: #FFFFFF;
box-shadow: 0 0 30px 0 rgba(22,4,82,0.13);
border-radius: 6px;
box-sizing: border-box;
padding: 12px;
position: fixed;
top: 0;left: 16px;
}
}
}
</style>

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,743 @@
<template>
<div class="main">
<div class="header">
<div class="headerBox">
<div class="headerTop" :style="{height:(menu.bottom + 6) + 'px'}">
<div class="box" :style="{top:(menu.bottom - (menu.height / 2)) + 'px'}">
<div class="icon" @click="handleBack">
<image class="img" src="https://eshangtech.com/ShopICO/ahyd-BID/examine/leftArrowWhite.svg"></image>
</div>
<text class="title">商家详情</text>
<div class="seize"></div>
</div>
</div>
<div class="detail" :style="{top:(menu.bottom + 22) + 'px'}">
<div class="box" >
<div class="left">
<image class="img" src="https://eshangtech.com/ShopICO/ahyd-BID/brand/storeIcon.png"></image>
</div>
<div class="right">
<div class="top">
<text class="title" :style="{fontSize:detail.BRAND_NAME.length>8?'12px':'16px'}">{{detail.COOPMERCHANTS_NAME}}</text>
<!-- <image class="icon" src="https://eshangtech.com/ShopICO/ahyd-BID/brand/effective.svg"></image>-->
</div>
<!-- <div class="otherMessage">-->
<!-- <span class="label">统一信用代码:</span>-->
<!-- <span class="value">{{detail.TAXPAYER_IDENTIFYCODE || '-'}}</span>-->
<!-- </div>-->
<!-- <div class="otherMessage">-->
<!-- <span class="label">联系人:</span>-->
<!-- </div>-->
<div class="person" v-for="(subItem,subIndex) in personList" :key="subIndex">
<span class="name">{{subItem.LINKER_NAME}}</span>
<span class="phone">{{subItem.LINKER_MOBILEPHONE}}</span>
<!-- <span class="state">{{subItem.LINKER_STATE===1?'有效':'无效'}}</span>-->
</div>
<div class="brandList">
<div class="imgBox" v-if="subItem.ico" v-for="(subItem,subIndex) in detail.BrandList" :key="subIndex" >
<img class="brandItem" :src="subItem.ico"/>
</div>
</div>
<!-- <div class="descBox">-->
<!-- <text class="desc">{{detail.BRAND_DESC}}</text>-->
<!-- <text v-if="detail.BRAND_DESC.length>11" class="more" @click="handleMore($event)">展开</text>-->
<!-- </div>-->
<!-- <div class="labelList">-->
<!-- <text class="labelItem">美食排行榜</text>-->
<!-- <text class="labelItem">这是标签</text>-->
<!-- <text class="labelItem">这是标签标签</text>-->
<!-- </div>-->
<!-- <div class="typeList">-->
<!-- <text class="typeItem">{{detail.BUSINESSTRADE_NAME}}</text>-->
<!-- <text class="typeItem">{{detail.BRAND_TYPENAME}}</text>-->
<!-- </div>-->
<!-- <div class="suggest">-->
<!-- <text class="value">{{detail.COMMISSION_RATIO}}</text>-->
<!-- <text class="text">建议提成比例</text>-->
<!-- </div>-->
</div>
<!-- <div class="typeBox">-->
<!-- <image class="typeIcon" src="https://eshangtech.com/ShopICO/ahyd-BID/brand/foodIcon.svg"></image>-->
<!-- <text class="text">服务区</text>-->
<!-- <text class="number">{{detail.ServerpartList.length}}</text>-->
<!-- </div>-->
</div>
</div>
</div>
</div>
<div class="businessProject" >
<div class="top">
<text class="projectTitle">经营项目</text>
<text v-if="serviceList && serviceList.length>0" class="number">({{`${serviceList.length}`}})</text>
</div>
<scroll-view class="list" scroll-y="true" :scroll-with-animation="true">
<div class="listItem" v-for="(item,index) in serviceList" :key="index" @click="handleShopDetail(item)">
<div class="itemTop">
<div class="left">
<div class="iconBox">
<image class="icon" src="https://eshangtech.com/ShopICO/ahyd-BID/brand/servicePosition.svg"></image>
</div>
<div class="content">
<text class="name">{{item.SERVERPART_NAME}}</text>
<div class="type">
<image class="typeIcon" src="https://eshangtech.com/ShopICO/ahyd-BID/brand/typeIcon.svg"></image>
<text class="text">{{typeObj[item.SERVERPART_TYPE]}}</text>
</div>
</div>
</div>
<div class="right">
<text class="price">{{item.SECTIONFLOW_NUM}}</text>
<text class="unit">断面流量</text>
</div>
</div>
<div class="itemContent">
<div class="contentTop">
<div class="left">
<text class="itemTitle">{{item.BUSINESSPROJECT_NAME || '-'}}</text>
<div class="typeBox" v-if="item.COMMODITY_COUNT > 0">
<!-- <image class="icon" src="https://eshangtech.com/ShopICO/ahyd-BID/brand/store.svg"></image>-->
<!-- <text class="typeName">在售商品</text>-->
</div>
</div>
<div class="right">
<text class="price">{{item.PROJECT_AMOUNT || '0'}}</text>
<text class="unit" >( 万元 )</text>
</div>
</div>
<!-- <div class="bottomItem">-->
<!-- <image class="bottomIcon" src="https://eshangtech.com/ShopICO/ahyd-BID/brand/storeIcon.svg"></image>-->
<!-- <text class="text">{{item.COOPMERCHANTS_NAME || '-'}}</text>-->
<!-- </div>-->
<div class="bottomItem">
<image class="bottomIcon" src="https://eshangtech.com/ShopICO/ahyd-BID/brand/fixed.svg"></image>
<text class="text">{{item.SERVERPARTSHOP_NAME || '-'}}</text>
</div>
<div class="bottomItem">
<image class="bottomIcon" src="https://eshangtech.com/ShopICO/ahyd-BID/brand/date.svg"></image>
<text class="text">{{ item.PROJECT_STARTDATE && item.PROJECT_ENDDATE ?`${item.PROJECT_STARTDATE}-${item.PROJECT_ENDDATE}`:'-' }}</text>
</div>
</div>
</div>
</scroll-view>
</div>
<div class="meng" v-if="isShow" @click="handleClose">
<div class="descPopup" :style="{top:descTop +'px',left:(descLeft - 130)+'px'}">
{{detail.BRAND_DESC}}
</div>
</div>
</div>
</template>
<script>
import request from '@/util/index.js'
export default {
name: 'shopDetail',
data(){
return {
menu:{},
detail:{},//
serviceList:[],//
descTop:0,//
descLeft:0,//
isShow: false,//
id:'',
COOPMERCHANTSID:'',
typeObj:{
'1000':'A类',
'2000':'B类',
'3000':'C类',
'4000':'D类'
},
personList:[]
}
},
onLoad(query){
this.menu = uni.getMenuButtonBoundingClientRect()
console.log('query',query)
this.id = query.id
this.COOPMERCHANTSID = query.COOPMERCHANTSID
console.log('this.id',this.id)
console.log('this.COOPMERCHANTSID',this.COOPMERCHANTSID)
//
this.getDetail()
//
this.handleGetList()
//
this.handlePerson()
},
methods:{
//
async getDetail(){
const req = {
CoopMerchantsId:this.id
}
const data = await request.$webGet('EShangApiMain/Merchants/GetCoopMerchantsDetail',req)
this.detail = data.Result_Data
console.log('data',data.Result_Data)
},
//
async handlePerson(){
const req = {
searchParameter:{
COOPMERCHANTS_ID:this.id
},
PageIndex:1,
pagesize: 20
}
const data = await request.$webPost('EShangApiMain/Merchants/GetCoopMerchantsLinkerList',req)
console.log('person',data)
let list = []
data.Result_Data.List.forEach(item=>{
if (item.LINKER_STATE===1){
list.push(item)
}
})
this.personList = [list[0]]
},
//s
handleBack(){
uni.navigateBack({
delta: 1
});
},
//
async handleGetList(){
uni.showLoading({
title: '正在加载...'
})
const req = {
MerchantsId: this.COOPMERCHANTSID,
}
const data = await request.$webGet(`EShangApiMain/BusinessProject/GetMerchantsReceivables`,req)
console.log('list',data)
this.serviceList = data.Result_Data.AccountReceivablesList
this.serviceList.forEach(item=>{
item.SECTIONFLOW_NUM = this.$util.noDecimal(item.SECTIONFLOW_NUM)
})
console.log('this.serviceList',this.serviceList)
uni.hideLoading()
},
handleMore(e){
console.log(e)
this.descTop = e.detail.y + 15
this.descLeft = e.detail.x
this.isShow = true
},
handleClose(){
this.isShow = false
},
}
}
</script>
<style scoped lang="scss">
.main{
background: #fff;
.header{
width: 100%;
height: 316px;
background: linear-gradient(180deg, #7660FF 0%, #ABCAFF 100%);
.headerBox{
width: 100%;
height: 100%;
position: relative;
z-index: 1;
.headerTop{
width: 100vw;
position: fixed;
top: 0;
left: 0;
z-index:99999;
.box{
padding: 0 16px;
position: absolute;
box-sizing: border-box;
width: 100%;
display: flex;
justify-content: space-between;
align-items: center;
transform: translateY(-50%);
.icon{
width: 24px;
height: 24px;
.img{
width: 100%;
height: 100%;
}
}
.title{
font-size: 18px;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 600;
color: #fff;
line-height: 28px;
}
.seize{
width: 24px;
height: 24px;
}
}
}
.detail{
width: 100%;
box-sizing: border-box;
padding: 0 16px;
position: absolute;
.box{
width: 100%;
min-height: 164px;
background: linear-gradient(45deg, #E0F3FF 0%, #E7EEFF 29%, #F1F4FF 50%, #E3EAFF 65%, #D8D2FF 100%);
border-radius: 8px;
border: 1px solid #FCFCFF;
box-sizing: border-box;
padding: 12px;
display: flex;
position: relative;
.left{
width: 72px;
height: 72px;
border-radius: 8px;
background: #fff;
display: flex;
align-items: center;
justify-content: center;
.img{
width: 40px;
height: 40px;
}
}
.right{
margin-left: 12px;
.top{
display: flex;
align-items: center;
.title{
display: inline-block;
width: 100%;
height: 44px;
font-size: 16px;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 600;
color: #051433;
line-height: 22px;
}
.icon{
width: 16px;
height: 16px;
margin-left: 6px;
}
}
.otherMessage{
display: flex;
justify-content: space-between;
align-items: center;
.label{
display: inline-block;
text-align: left;
font-size: 14px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: rgba(0, 0, 0, 0.65);
}
.value{
display: inline-block;
text-align: right;
font-size: 14px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: rgba(0, 0, 0, 0.85);
}
}
.person{
width: 100%;
height: 28px;
display: flex;
align-items: center;
.name{
text-align: left;
font-size: 14px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: rgba(0, 0, 0, 0.65);
}
.phone{
font-size: 14px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: rgba(0, 0, 0, 0.65);
margin-left: 12px;
}
}
.brandList{
width: 100%;
display: flex;
margin-top: 10px;
.imgBox{
width: 60px;
height: 60px;
border-radius: 6px;
margin-right: 8px;
overflow: hidden;
.brandItem{
width: 60px;
height: 60px;
}
}
}
.descBox{
display: flex;
align-items: center;
.desc{
width: 150px;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
display: inline-block;
height: 18px;
font-size: 12px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #5C5773;
line-height: 18px;
}
.more{
color: #396CFF;
font-size: 12px
}
}
.labelList{
height: 18px;
display: flex;
margin-top: 4px;
.labelItem{
padding: 0 4px;
background: rgba(57, 108, 255, 0.1);
border-radius: 4rpx;
font-size: 12px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #396CFF;
line-height: 18px;
margin-right:5px
}
}
.typeList{
margin-top: 18px;
border-radius: 2px;
.typeItem{
display: inline-block;
background: linear-gradient(270deg, rgba(90, 199, 255, 0.15) 0%, rgba(90, 193, 255, 0.15) 100%);
font-size: 14px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #0075A1;
line-height: 22px;
margin-right: 8px;
padding: 1px 8px;
}
}
.suggest{
margin-top: 8px;
background: linear-gradient(90deg, rgba(72,119,255,0.15) 0%, rgba(72, 119, 255, 0) 100%);
border-radius: 2px;
box-sizing: border-box;
padding: 4px 8px;
.value{
font-size: 14px;
font-family: DINAlternate-Bold, DINAlternate;
font-weight: bold;
color: #396CFF;
line-height: 16px;
}
.text{
font-size: 12px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #8995B5;
line-height: 18px;
margin-left: 4px;
}
}
}
.typeBox{
display: flex;
align-items: center;
background: linear-gradient(135deg, #77A1FF 0%, #7967FF 100%);
border-radius: 0 8px 0 5px;
padding: 3px 8px;
//border-image: linear-gradient(227deg, rgba(255, 255, 255, 1), rgba(234, 240, 255, 1), rgba(255, 255, 255, 0)) 1 1;
position: absolute;
right: 0;top: 0;
.typeIcon{
width: 14px;
height: 14px;
}
.text{
font-size: 12px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #E3DEFF;
line-height: 18px;
margin-left: 4px;
}
.number{
font-size: 14px;
font-family: DINAlternate-Bold, DINAlternate;
font-weight: bold;
color: #FFFFFF;
margin-left: 8px;
}
}
}
}
}
}
.businessProject{
width: 100%;
transform: translateY(-16px);
height: calc(100vh - 316px);
border-top-left-radius: 16px;
border-top-right-radius: 16px;
background: #fff;
box-sizing: border-box;
padding: 16px;
.top{
display: flex;
align-items: center;
.projectTitle{
font-size: 17px;
font-family: PingFangSC-Semibold, PingFang SC;
font-weight: 600;
color: #051433;
line-height: 24px
}
.number{
font-size: 14px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #786B6C;
line-height: 20px;
margin-left: 4px;
}
}
.list{
width: 100%;
height: calc(100vh - 372px);
margin-top: 8px;
.listItem{
width: 100%;
border-radius: 8px;
border: 1px solid #E8E7FF;
box-sizing: border-box;
overflow: hidden;
display: flex;
flex-direction: column;
margin-bottom: 12px;
background: linear-gradient(207deg, rgba(202, 202, 255, 0.25) 0%, rgba(243, 242, 255, 0.25) 100%);
.itemTop{
width: 100%;
height: 60px;
background: linear-gradient(270deg, #EBECFF 0%, #E9F9FF 100%);
padding: 8px;
box-sizing: border-box;
display: flex;
justify-content: space-between;
.left{
display: flex;
align-items: center;
.iconBox{
width: 36px;
height: 36px;
border: 2px solid #fff;
border-radius: 50%;
.icon{
width: 100%;
height: 100%;
}
}
.content{
margin-left: 16px;
.name{
font-size: 16px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #051433;
line-height: 22px;
}
.type{
width: 48px;
height: 16px;
border: 1px solid #4F92FF;
display: flex;
align-items: center;
border-radius: 3px;
.typeIcon{
width: 21px;
height: 18px;
}
.text{
font-size: 12px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #6370FF;
line-height: 12px;
margin-left: 2px;
}
}
}
}
.right{
display: flex;
flex-direction: column;
.price{
font-size: 18px;
font-family: DINAlternate-Bold, DINAlternate;
font-weight: bold;
color: #683FF6;
line-height: 22px;
text-align: right;
}
.unit{
font-size: 14px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #A3A2B9;
line-height: 18px;
}
}
}
.itemContent{
width: 100%;
flex: 1;
box-sizing: border-box;
padding: 16px 12px;
.contentTop{
width: 100%;
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 16px;
.left{
width: 80%;
.itemTitle{
font-size: 14px;
font-family: PingFangSC-Semibold, PingFang SC;
font-weight: 600;
color: #051433;
line-height: 20px;
}
.typeBox{
display: flex;
align-items: center;
margin-top: 4px;
.icon{
width: 18px;
height: 18px;
}
.typeName{
font-size: 12px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #5C5773;
line-height: 18px;
margin-left: 4px;
}
}
}
.right{
display: flex;
flex-direction: column;
width: 20%;
.price{
font-size: 18px;
font-family: DINAlternate-Bold, DINAlternate;
font-weight: bold;
color: #683FF6;
line-height: 22px;
text-align: right;
}
.unit{
font-size: 12px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #ABA9B9;
line-height: 18px;
text-align: right;
}
}
}
.bottomItem{
display: flex;
align-items: flex-start;
margin-bottom: 4px;
.bottomIcon{
width: 16px;
height: 16px;
margin-right: 4px;
margin-top: 2px;
}
.text{
flex: 1;
font-size: 14px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #5C5773;
line-height: 22px;
}
}
}
}
::-webkit-scrollbar {
width: 4px;
height: 4px;
color:transparent;
}
/*定义滚动条轨道 内阴影+圆角*/
::-webkit-scrollbar-track {
border-radius: 10px;
background-color:transparent;
}
/*定义滑块 内阴影+圆角*/
::-webkit-scrollbar-thumb {
border-radius: 10px;
background-color:transparent;
}
}
}
.meng{
position: relative;
width: 100vw;
height: 100vh;
top: -100vh;left: 0;
z-index: 99;
.descPopup{
width: 200px;
background: #FFFFFF;
box-shadow: 0 0 30px 0 rgba(22,4,82,0.13);
border-radius: 6px;
box-sizing: border-box;
padding: 12px;
position: fixed;
top: 0;left: 16px;
}
}
}
</style>

View File

@ -146,7 +146,7 @@ export default{
this.searchTime = uni.getStorageSync('lastDay') this.searchTime = uni.getStorageSync('lastDay')
this.lastDay = uni.getStorageSync('lastDay') this.lastDay = uni.getStorageSync('lastDay')
// //
const date = new Date(this.searchTime) const date = new Date(this.lastDay)
let month = date.getMonth() + 1 let month = date.getMonth() + 1
// //
// //
@ -159,34 +159,40 @@ export default{
// this.handleAreaDetailList() // this.handleAreaDetailList()
}, },
onReady(){ onReady(){
//
this.getThisMonth() this.getThisMonth()
}, },
methods:{ methods:{
// //
getThisMonth(){ getThisMonth(){
const date = new Date() //
const date = new Date(this.searchTime)
const month = date.getMonth() + 1 const month = date.getMonth() + 1
this.selectMonth = month this.selectMonth = month
this.selectMonthId = `item${month}` this.selectMonthId = `item${month}`
}, },
// //
handleSelectMonth(value){ handleSelectMonth(value){
// id
this.selectMonth = value this.selectMonth = value
this.selectMonthId = `item${value}` this.selectMonthId = `item${value}`
this.selectDetail = value - 1 this.selectDetail = value - 1
}, },
// //
//
handleDetailScroll(e){ handleDetailScroll(e){
// id // id
const date = new Date(this.lastDay) const date = new Date(this.lastDay)
let year = date.getFullYear() let year = date.getFullYear()
let month = date.getMonth() + 1 let month = date.getMonth() + 1
let day = date.getDate() let day = date.getDate()
// id
this.selectDetail = e.detail.current this.selectDetail = e.detail.current
this.selectMonth = this.selectDetail + 1 this.selectMonth = this.selectDetail + 1
this.selectMonthId = `item${this.selectDetail<5?1:this.selectDetail}` this.selectMonthId = `item${this.selectDetail<5?1:this.selectDetail}`
// //
if (month === this.selectMonth){ if (month === this.selectMonth){
// ios 100 ios
if (month<10){ if (month<10){
month = '0' + month month = '0' + month
} }
@ -199,6 +205,7 @@ export default{
let d = this.$util.getThisMonthDay(`${year}-${m}`) let d = this.$util.getThisMonthDay(`${year}-${m}`)
this.searchTime = `${year}-${m}-${d}` this.searchTime = `${year}-${m}-${d}`
} }
//
this.handleAreaDetailList() this.handleAreaDetailList()
}, },
async handleAreaDetailList(){ async handleAreaDetailList(){

View File

@ -51,7 +51,7 @@
<view class="serviceItem" v-for="(item,index) in serviceList" :key="index"> <view class="serviceItem" v-for="(item,index) in serviceList" :key="index">
<view class="itemTitle"> <view class="itemTitle">
<span class="title">{{item.SERVERPART_NAME}}</span> <span class="title">{{item.SERVERPART_NAME}}</span>
<span :class="selectMonth%3===0?'secondUnit':'unit'">{{selectMonth%3===0?`${Math.abs(selectMonth/3)===1?'一':Math.abs(selectMonth/3)===2?'二':Math.abs(selectMonth/3)===3?'三':'四'}季度`:'月度'}}</span> <span :class="item.EXAMINE_MQUARTER!=='0'?'secondUnit':'unit'">{{item.EXAMINE_MQUARTER!=='0'?item.EXAMINE_MQUARTER==='1'?'一'+'季度':item.EXAMINE_MQUARTER==='2'?'二'+'季度':item.EXAMINE_MQUARTER==='3'?'三'+'季度':'四' + '季度':'月度'}}</span>
</view> </view>
<view class="detail" v-for="(subItem,subIndex) in item.list" :key="subIndex"> <view class="detail" v-for="(subItem,subIndex) in item.list" :key="subIndex">
<view class="detailTop"> <view class="detailTop">
@ -285,10 +285,10 @@ export default {
this.statusBarHeight = Number(systemInfo.statusBarHeight) this.statusBarHeight = Number(systemInfo.statusBarHeight)
this.menu = uni.getMenuButtonBoundingClientRect() this.menu = uni.getMenuButtonBoundingClientRect()
// lastDay // lastDay
this.searchTime = uni.getStorageSync('lastDay') this.searchTime = new Date()
this.lastDay = uni.getStorageSync('lastDay') this.lastDay = uni.getStorageSync('lastDay')
// //
const date = new Date(this.searchTime) const date = new Date()
let month = date.getMonth() + 1 let month = date.getMonth() + 1
// //
let list = [] let list = []
@ -300,7 +300,7 @@ export default {
this.monthList = list this.monthList = list
// //
this.dateList = this.$util.getThisMonthDateList(date) this.dateList = this.$util.getThisMonthDateList(date)
console.log('this.dateList1',this.dateList) console.log('this.dateList',this.dateList)
// //
this.getAreaList() this.getAreaList()
}, },
@ -327,9 +327,12 @@ export default {
this.selectMonth = month this.selectMonth = month
this.current='item'+month this.current='item'+month
// //
if (day<10){
day = '0' + day
}
this.selectDate = `${year}-${month}-${day}` this.selectDate = `${year}-${month}-${day}`
console.log('this.selectDate',this.selectDate)
this.currentDate = 'item'+`${year}-${month}-${showDay}` this.currentDate = 'item'+`${year}-${month}-${showDay}`
console.log('this.currentDate',this.currentDate)
}, },
// //
handleShowPopup(value,obj){ handleShowPopup(value,obj){
@ -362,7 +365,6 @@ export default {
}, },
// //
handleSelectMonth(value){ handleSelectMonth(value){
console.log('value',value)
this.selectMonth = value this.selectMonth = value
// //
const nowDate = new Date() const nowDate = new Date()
@ -371,17 +373,16 @@ export default {
nowMonth = '0' + nowMonth nowMonth = '0' + nowMonth
} }
// //
console.log('this.searchTime',this.searchTime)
const date = new Date(this.searchTime) const date = new Date(this.searchTime)
let y = date.getFullYear() let y = date.getFullYear()
// //
if (nowMonth === this.selectMonth){ if (nowMonth === this.selectMonth){
this.searchTime = this.lastDay // this.searchTime = this.lastDay
this.searchTime = new Date()
}else{ }else{
let howDay = this.$util.getThisMonthDay(`${y}-${this.selectMonth}`) let howDay = this.$util.getThisMonthDay(`${y}-${this.selectMonth}`)
this.searchTime = `${y}-${this.selectMonth}-${howDay}` this.searchTime = `${y}-${this.selectMonth}-${howDay}`
} }
console.log(' this.searchTime', this.searchTime)
let howDay = this.$util.getThisMonthDay(`${y}-${this.selectMonth}`) let howDay = this.$util.getThisMonthDay(`${y}-${this.selectMonth}`)
const listDate = new Date(`${y}-${this.selectMonth}`) const listDate = new Date(`${y}-${this.selectMonth}`)
let listY = listDate.getFullYear() let listY = listDate.getFullYear()
@ -396,22 +397,15 @@ export default {
} }
// //
this.dateList = list this.dateList = list
console.log('this.dateList',this.dateList)
// //
console.log('this.selectDate',this.selectDate)
console.log('111',`${y}-${this.selectMonth}`)
this.selectDate = this.$util.handleReduceAMonth(`${this.selectDate}`,`${y}-${this.selectMonth}`) this.selectDate = this.$util.handleReduceAMonth(`${this.selectDate}`,`${y}-${this.selectMonth}`)
console.log('this.selectDate2',this.selectDate)
// //
const selectTime = new Date(this.selectDate) const selectTime = new Date(this.selectDate)
let selectY = selectTime.getFullYear() let selectY = selectTime.getFullYear()
let selectM = selectTime.getMonth() + 1 let selectM = selectTime.getMonth() + 1
console.log('selectTime',selectTime)
// //
let selectD = selectTime.getDate() - 4 > 0?selectTime.getDate() - 4:1 let selectD = selectTime.getDate() - 4 > 0?selectTime.getDate() - 4:1
console.log('selectD',selectD)
this.currentDate = 'item' + `${selectY}-${selectM<10?'0'+selectM:selectM}-${selectD<10?'0'+selectD:selectD}` this.currentDate = 'item' + `${selectY}-${selectM<10?'0'+selectM:selectM}-${selectD<10?'0'+selectD:selectD}`
console.log('this.currentDate',this.currentDate)
if (this.selectTab===1){ if (this.selectTab===1){
// //
@ -448,12 +442,10 @@ export default {
}, },
// //
handleChangeDate(value){ handleChangeDate(value){
console.log('value',value)
let time = `${value.split('-')[0]}-${value.split('-')[1]<10?'0'+value.split('-')[1]:value.split('-')[1]}-${value.split('-')[2]}`
const date = new Date() const date = new Date()
let m = date.getMonth() +1 let m = date.getMonth() +1
let d = date.getDate() let d = date.getDate()
const selectDay = new Date(time) const selectDay = new Date(value)
let selectM = selectDay.getMonth() +1 let selectM = selectDay.getMonth() +1
let selectD = selectDay.getDate() let selectD = selectDay.getDate()
if (d < selectD && m <= selectM){ if (d < selectD && m <= selectM){
@ -528,6 +520,9 @@ export default {
m = '0' + m m = '0' + m
} }
let d = date.getDate() let d = date.getDate()
if (d<10){
d = '0' + d
}
let startTime = `${y}-${m}-01` let startTime = `${y}-${m}-01`
let endTime = `${y}-${m}-${d}` let endTime = `${y}-${m}-${d}`

View File

@ -487,10 +487,8 @@ export default {
user:{ user:{
// onLoad user // onLoad user
handler:function (value){ handler:function (value){
console.log('value',value)
let userInfo = uni.getStorageSync('vuex') let userInfo = uni.getStorageSync('vuex')
userInfo = JSON.parse(userInfo) userInfo = JSON.parse(userInfo)
console.log('userInfo11',userInfo)
if (this.isReturn===true){ if (this.isReturn===true){
// //
if (userInfo.userData.AuthorityInfo['89a1f248-2113-4d57-84b1-c2e6edb9e8ee']===1){ if (userInfo.userData.AuthorityInfo['89a1f248-2113-4d57-84b1-c2e6edb9e8ee']===1){
@ -526,7 +524,6 @@ export default {
} }
if (!this.isReturn){ if (!this.isReturn){
this.getData(this.option) this.getData(this.option)
console.log('watch')
this.handleNoticeMonth() this.handleNoticeMonth()
this.handleNoticeYear() this.handleNoticeYear()
} }
@ -577,11 +574,12 @@ export default {
if (d - 8 <0){ if (d - 8 <0){
let k = 8 - d let k = 8 - d
m = m - 1 m = m - 1
const time = `${y}-${m}`
howDay = this.$util.getThisMonthDay(time)
if (m<10){ if (m<10){
m = '0' + m m = '0' + m
} }
const time = `${y}-${m}`
console.log('time',time)
howDay = this.$util.getThisMonthDay(time)
this.startDate = `${y}-${m}-${howDay - k}` this.startDate = `${y}-${m}-${howDay - k}`
}else{ }else{
if (m<10){ if (m<10){
@ -611,9 +609,7 @@ export default {
url:`/pages/commercialBI/noData?type=noAuthor` url:`/pages/commercialBI/noData?type=noAuthor`
}) })
} }
console.log('onLoad',this.isReturn)
if (!this.isReturn){ if (!this.isReturn){
console.log('onLoad2',this.isReturn)
let userInfo = uni.getStorageSync('vuex') let userInfo = uni.getStorageSync('vuex')
userInfo = JSON.parse(userInfo) userInfo = JSON.parse(userInfo)
// //
@ -780,15 +776,15 @@ export default {
this.showNoticeYear = false this.showNoticeYear = false
}, },
handlePlanPageGo(type){ handlePlanPageGo(type){
this.$util.toNextRoute('navigateTo', `/pages/commercialBI/yearPlan`) // this.$util.toNextRoute('navigateTo', `/pages/commercialBI/yearPlan`)
// if (!this.isReturn){ if (!this.isReturn){
// this.$util.toNextRoute('navigateTo', `/pages/commercialBI/planMonth?lastDay=${this.lastDay}&type=${type}`) this.$util.toNextRoute('navigateTo', `/pages/commercialBI/planMonth?lastDay=${this.lastDay}&type=${type}`)
// }else{ }else{
// uni.showToast({ uni.showToast({
// title: '', title: '暂无权限请联系管理员',
// icon: 'none' icon: 'none'
// }) })
// } }
}, },
handlePage(){ handlePage(){
if (!this.isReturn){ if (!this.isReturn){
@ -810,7 +806,8 @@ export default {
}) })
} }
}, },
getData(option){ // option type
getData(option,type){
// //
if (this.user.Membership_Id){ if (this.user.Membership_Id){
uni.showLoading({ uni.showLoading({
@ -819,15 +816,19 @@ export default {
} }
// //
if (option.ProvinceCode) { // if (option.ProvinceCode) { //
console.log('推送')
this.theRequest = option this.theRequest = option
option.time = this.$util.cutDate(option.time, 'YYYY-MM-DD') option.time = this.$util.cutDate(option.time, 'YYYY-MM-DD')
option.month = this.$util.cutDate(option.time, 'YYYYMM') option.month = this.$util.cutDate(option.time, 'YYYYMM')
console.log('type',type)
if (!type){
this.lastDay = this.$util.cutDate(option.time, 'YYYY-MM-DD') this.lastDay = this.$util.cutDate(option.time, 'YYYY-MM-DD')
// //
this.single = timestampToTime((new Date(this.lastDay).getTime())) this.single = timestampToTime((new Date(this.lastDay).getTime()))
// //
const date = new Date(this.lastDay) const date = new Date(this.lastDay)
this.thisDay = getThisDay(date.getDay()) this.thisDay = getThisDay(date.getDay())
}
// //
this.initData() this.initData()
// //
@ -890,10 +891,10 @@ export default {
}, },
// //
onRefresh(){ onRefresh(type){
// //
if (!this.isReturn){ if (!this.isReturn){
this.getData(this.option) this.getData(this.option,type)
} }
}, },
getUnUpLoadList(){ getUnUpLoadList(){
@ -941,7 +942,7 @@ export default {
this.carInfo.Vehicle_Count = res.Result_Data.Vehicle_Count?res.Result_Data.Vehicle_Count:'-' this.carInfo.Vehicle_Count = res.Result_Data.Vehicle_Count?res.Result_Data.Vehicle_Count:'-'
}) })
}, },
initYesterdayData(){ async initYesterdayData(){
let flag1 = false let flag1 = false
let flag2 = false let flag2 = false
let flag3 = false let flag3 = false
@ -1002,15 +1003,23 @@ export default {
Statistics_Date: this.lastDay, Statistics_Date: this.lastDay,
ShowCompareRate:true ShowCompareRate:true
} }
request.$webGet('CommercialApi/Revenue/GetMallDeliver',todayData).then(res=>{ const data = await request.$webGet('CommercialApi/Revenue/GetMallDeliver',todayData)
// data this.lastDayBillCount = data.Result_Data
this.lastDayBillCount = res.Result_Data
this.detailTypeList[2].value = this.lastDayBillCount.DeliverBill_Count this.detailTypeList[2].value = this.lastDayBillCount.DeliverBill_Count
this.detailTypeList[2].add = this.lastDayBillCount.DeliverBillGrowth_Count this.detailTypeList[2].add = this.lastDayBillCount.DeliverBillGrowth_Count
this.detailTypeList[3].value = this.$util.fmoney(this.lastDayBillCount.MonthDeliver_Price) this.detailTypeList[3].value = this.$util.fmoney(this.lastDayBillCount.MonthDeliver_Price)
this.detailTypeList[3].yesterValue = this.$util.fmoney(this.lastDayBillCount.Deliver_Price) this.detailTypeList[3].yesterValue = this.$util.fmoney(this.lastDayBillCount.Deliver_Price)
flag2 = true flag2 = true
}) // .then(res=>{
// console.log('flag2',res)
// // data
// this.lastDayBillCount = res.Result_Data
// this.detailTypeList[2].value = this.lastDayBillCount.DeliverBill_Count
// this.detailTypeList[2].add = this.lastDayBillCount.DeliverBillGrowth_Count
// this.detailTypeList[3].value = this.$util.fmoney(this.lastDayBillCount.MonthDeliver_Price)
// this.detailTypeList[3].yesterValue = this.$util.fmoney(this.lastDayBillCount.Deliver_Price)
// flag2 = true
// })
// //
// //
// const deliveData = { // const deliveData = {
@ -1075,6 +1084,8 @@ export default {
this.showTableData = result.RevenuePushModel this.showTableData = result.RevenuePushModel
this.showTableData.compared = result.GrowthRate this.showTableData.compared = result.GrowthRate
// //
console.log('flag2',flag2)
console.log('flag3',flag3)
if (flag2 && flag3 ){ if (flag2 && flag3 ){
this.todayAmount() this.todayAmount()
} }
@ -1103,10 +1114,13 @@ export default {
// //
bindDateChange(e){ bindDateChange(e){
let isOnRefresh = false let isOnRefresh = false
console.log('this.startDate',this.startDate)
console.log('this.noChangeLastDay',this.noChangeLastDay)
let startTime = new Date(this.startDate).getTime() let startTime = new Date(this.startDate).getTime()
let endTime = new Date(this.noChangeLastDay).getTime() - 8 * 3600 * 1000 // let endTime = new Date(this.noChangeLastDay).getTime() - 8 * 3600 * 1000 //
const date = new Date(e.detail.value).getTime() - 8 * 3600 * 1000 const date = new Date(e.detail.value).getTime() - 8 * 3600 * 1000
let startDate = new Date(this.startDate) let startDate = new Date(this.startDate)
console.log('startDate',startDate)
let startMonth = startDate.getMonth() + 1 let startMonth = startDate.getMonth() + 1
let startDay = startDate.getDate() let startDay = startDate.getDate()
let endDate = new Date(this.noChangeLastDay) let endDate = new Date(this.noChangeLastDay)
@ -1118,14 +1132,18 @@ export default {
}else{ }else{
isOnRefresh = true isOnRefresh = true
} }
console.log('isOnRefresh',isOnRefresh)
console.log('timestampToTime(date)',timestampToTime(date))
// //
if (isOnRefresh){ if (isOnRefresh){
this.single = timestampToTime(date) this.single = timestampToTime(date)
this.lastDay = e.detail.value this.lastDay = e.detail.value
uni.setStorageSync('lastDay',this.lastDay) uni.setStorageSync('lastDay',this.lastDay)
this.thisDay = getThisDay(new Date(e.detail.value).getDay()) this.thisDay = getThisDay(new Date(e.detail.value).getDay())
this.onRefresh() this.onRefresh(true)
}else{ }else{
console.log('startMonth',startMonth)
console.log('startDay',startDay)
uni.showModal({ uni.showModal({
title: `数据看板仅支持查看${startMonth}.${startDay}-${endMonth}.${endDay}的数据,更多数据请登陆商业综合平台查看`, title: `数据看板仅支持查看${startMonth}.${startDay}-${endMonth}.${endDay}的数据,更多数据请登陆商业综合平台查看`,
icon:'none', icon:'none',

View File

@ -29,8 +29,9 @@
<view :class="selectTab===item.value?'tabItem selectItem':'tabItem'" v-for="(item,index) in tabList" :key="index" @click="changeTab(item.value)">{{item.label}}</view> <view :class="selectTab===item.value?'tabItem selectItem':'tabItem'" v-for="(item,index) in tabList" :key="index" @click="changeTab(item.value)">{{item.label}}</view>
</view> </view>
<view class="list"> <view class="list">
<scroll-view scroll-y="true" style="width: 100%;height: 100%"> <scroll-view v-if="serviceDetailShowList.length>0" scroll-y="true" style="width: 100%;height: 100%">
<view class="listItem" v-for="(item,index) in serviceDetailShowList" :key="index" @click="goPage(item)"> <view class="listItem" v-for="(item,index) in serviceDetailShowList" :key="index" @click="goPage(item)">
<view>
<view class="top"> <view class="top">
<view class="left"> <view class="left">
<p class="title">{{item.Serverpart_Name}}</p> <p class="title">{{item.Serverpart_Name}}</p>
@ -60,7 +61,12 @@
<span class="money">{{item.Budget_Amount}}</span> <span class="money">{{item.Budget_Amount}}</span>
</view> </view>
</view> </view>
</view>
</scroll-view> </scroll-view>
<view class="noData" v-else>
<image class="img" src="https://eshangtech.com/ShopICO/ahyd-BID/commercial/noData.svg"></image>
<text>暂无数据</text>
</view>
</view> </view>
</view> </view>
<uniPopup type="bottom" :round="true" :show="showPop" @hidePopup="hidePopup"> <uniPopup type="bottom" :round="true" :show="showPop" @hidePopup="hidePopup">
@ -145,7 +151,6 @@ export default {
if (value===1){ if (value===1){
this.serviceDetailShowList = this.serviceDetailList this.serviceDetailShowList = this.serviceDetailList
}else if (value===2){ }else if (value===2){
console.log(111)
this.serviceDetailShowList = this.serviceDetailList.filter(item=>item.Growth_Rate>0) this.serviceDetailShowList = this.serviceDetailList.filter(item=>item.Growth_Rate>0)
}else if (value===3){ }else if (value===3){
this.serviceDetailShowList = this.serviceDetailList.filter(item=>item.Growth_Rate<0) this.serviceDetailShowList = this.serviceDetailList.filter(item=>item.Growth_Rate<0)
@ -154,7 +159,6 @@ export default {
// //
async handleAreaMonthPlan(){ async handleAreaMonthPlan(){
uni.showLoading({title:'正在加载'}) uni.showLoading({title:'正在加载'})
console.log('this.searchTime',this.searchTime)
const req = { const req = {
StatisticsDate:this.searchTime, StatisticsDate:this.searchTime,
ProvinceCode:'340000', ProvinceCode:'340000',
@ -163,6 +167,7 @@ export default {
} }
const data = await request.$webGet('CommercialApi/Revenue/GetProvinceRevenueBudget',req) const data = await request.$webGet('CommercialApi/Revenue/GetProvinceRevenueBudget',req)
this.serviceDetailList = data.Result_Data.RegionBudgetList this.serviceDetailList = data.Result_Data.RegionBudgetList
//
this.serviceDetailList.forEach(item=>{ this.serviceDetailList.forEach(item=>{
for (let key in item){ for (let key in item){
for (let key in item){ for (let key in item){
@ -175,7 +180,6 @@ export default {
// //
this.serviceDetailShowList = this.serviceDetailList this.serviceDetailShowList = this.serviceDetailList
uni.hideLoading() uni.hideLoading()
console.log('this.serviceDetailList',this.serviceDetailList)
}, },
handleBack(){ handleBack(){
uni.navigateBack({ uni.navigateBack({
@ -190,7 +194,7 @@ export default {
hidePopup(){ hidePopup(){
this.showPop = false this.showPop = false
}, },
// //
handleChangeArea(item){ handleChangeArea(item){
// id // id
this.selectAreaValue = item.value this.selectAreaValue = item.value
@ -215,18 +219,15 @@ export default {
}) })
this.areaList = list this.areaList = list
this.areaList.forEach(item=>{ this.areaList.forEach(item=>{
console.log('item',item)
if (item.value === this.selectAreaValue){ if (item.value === this.selectAreaValue){
this.selectAreaValue = item.value this.selectAreaValue = item.value
this.selectAreaName = item.label this.selectAreaName = item.label
} }
}) })
console.log('this.areaList',this.areaList)
} }
}, },
// //
goPage(item){ goPage(item){
console.log('item',item)
this.$util.toNextRoute('navigateTo', '/pages/plan/servicePlanMonth?id='+item.Serverpart_ID+'&search='+this.searchTime+'&obj=' + JSON.stringify(item) +'&selectAreaValue=' this.$util.toNextRoute('navigateTo', '/pages/plan/servicePlanMonth?id='+item.Serverpart_ID+'&search='+this.searchTime+'&obj=' + JSON.stringify(item) +'&selectAreaValue='
+this.selectAreaValue) +this.selectAreaValue)
} }
@ -489,6 +490,18 @@ export default {
} }
} }
} }
.noData{
width: 100%;
height: 100%;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
.img{
width: 80px;
height: 80px;
}
}
} }
} }
.popup{ .popup{

View File

@ -121,17 +121,19 @@
<view class="subItem" v-for="(thirdItem,thirdIndex) in subItem.children" :key="thirdIndex"> <view class="subItem" v-for="(thirdItem,thirdIndex) in subItem.children" :key="thirdIndex">
<view class="link" v-if="thirdIndex + 1 !== subItem.children.length"></view> <view class="link" v-if="thirdIndex + 1 !== subItem.children.length"></view>
<view class="subTop"> <view class="subTop">
<image class="icon" :src="`https://eshangtech.com/ShopICO/ahyd-BID/plan/${item.node.ACCOUNT_CODE==='营业收入'?thirdItem.node.ACCOUNT_CODE==='便利店'?'store' <image class="icon" :src="`https://eshangtech.com/ShopICO/ahyd-BID/plan/${
:thirdItem.node.ACCOUNT_CODE==='餐饮(含小吃)'?'mainWorkFood' item.node.ACCOUNT_CODE==='营业收入'?subItem.node.ACCOUNT_CODE==='自营收入'?
:thirdItem.node.ACCOUNT_CODE==='客房及其他'?'mainWorkRoom':'' thirdItem.node.ACCOUNT_CODE==='便利店'?'store':thirdItem.node.ACCOUNT_CODE==='餐饮(含小吃)'?'mainWorkFood':'mainWorkRoom'
:thirdItem.node.ACCOUNT_CODE==='餐饮租赁收入'?''
:thirdItem.node.ACCOUNT_CODE==='商铺租赁收入'?''
:thirdItem.node.ACCOUNT_CODE==='场地租赁汇总'?'':''
:item.node.ACCOUNT_CODE==='营业成本'?thirdItem.node.ACCOUNT_CODE==='便利店'?'costStore' :item.node.ACCOUNT_CODE==='营业成本'?thirdItem.node.ACCOUNT_CODE==='便利店'?'costStore'
:thirdItem.node.ACCOUNT_CODE==='餐饮销售成本'?'costFood' :thirdItem.node.ACCOUNT_CODE==='餐饮销售成本'?'costFood'
:thirdItem.node.ACCOUNT_CODE==='员工餐成本'?'costBook' :thirdItem.node.ACCOUNT_CODE==='员工餐成本'?'costBook':'costRoom'
:thirdItem.node.ACCOUNT_CODE==='客房'?'costRoom':'' :thirdItem.node.ACCOUNT_CODE==='综合毛利率 (不含员工餐)'?'grossAdd'
:item.node.ACCOUNT_CODE==='毛利率'?thirdItem.node.ACCOUNT_CODE==='综合毛利率 (不含员工餐)'?'grossAdd'
:thirdItem.node.ACCOUNT_CODE==='综合毛利率 (含员工餐)'?'grossUser' :thirdItem.node.ACCOUNT_CODE==='综合毛利率 (含员工餐)'?'grossUser'
:thirdItem.node.ACCOUNT_CODE==='便利店'?'grossStore' :thirdItem.node.ACCOUNT_CODE==='便利店'?'grossStore':'grossFood'
:thirdItem.node.ACCOUNT_CODE==='餐饮'?'grossFood':'':''}.svg`"></image> }.svg`"></image>
<span class="text">{{thirdItem.node.ACCOUNT_CODE}}</span> <span class="text">{{thirdItem.node.ACCOUNT_CODE}}</span>
</view> </view>
<view class="subBox"> <view class="subBox">
@ -152,7 +154,7 @@
<span class="value">{{thirdItem.node.BUDGETDETAIL_AMOUNT || '-'}}</span> <span class="value">{{thirdItem.node.BUDGETDETAIL_AMOUNT || '-'}}</span>
</view> </view>
<view class="progress"> <view class="progress">
<view class="reality" v-if="thirdItem.node.Budget_Degree" :style="{width:thirdItem.node.Budget_Degree>=100?'100%':thirdItem.node.Budget_Degree + '%'}"></view> <view class="reality" v-if="thirdItem.node.Budget_Degree" :style="{width:thirdItem.node.Budget_Degree>=200?'100%':(thirdItem.node.Budget_Degree / 100)*40 + 'px'}"></view>
<view class="plan"></view> <view class="plan"></view>
<view class="add"> <view class="add">
<image v-if="thirdItem.node.Budget_Degree" class="addIcon" :src="thirdItem.node.Budget_Degree>0?'https://eshangtech.com/ShopICO/ahyd-BID/plan/add.svg':'https://eshangtech.com/ShopICO/ahyd-BID/plan/reduce.svg'"></image> <image v-if="thirdItem.node.Budget_Degree" class="addIcon" :src="thirdItem.node.Budget_Degree>0?'https://eshangtech.com/ShopICO/ahyd-BID/plan/add.svg':'https://eshangtech.com/ShopICO/ahyd-BID/plan/reduce.svg'"></image>
@ -192,9 +194,9 @@ export default {
monthList:[{label:'1月',value:1},{label:'2月',value:2},{label:'3月',value:3},{label:'4月',value:4},{label:'5月',value:5},{label:'6月',value:6},{label:'7月',value:7}, {label:'8月',value:8},{label:'9月',value:9},{label:'10月',value:10},{label:'11月',value:11},{label:'12月',value:12}], monthList:[{label:'1月',value:1},{label:'2月',value:2},{label:'3月',value:3},{label:'4月',value:4},{label:'5月',value:5},{label:'6月',value:6},{label:'7月',value:7}, {label:'8月',value:8},{label:'9月',value:9},{label:'10月',value:10},{label:'11月',value:11},{label:'12月',value:12}],
selectMonth:0,// selectMonth:0,//
selectMonthId:'',// id selectMonthId:'',// id
swiperList:[{label:1111},{label:2222},{label:3333},{label:4444},{label:5555},{label:6666},{label:7777},{label:8888},{label:9999},{label:1010}, {label:11111111},{label:1212}], swiperList:[{},{},{},{},{},{},{},{},{},{}, {},{}],
selectDetail:0,// selectDetail:0,//
detailList:[{list:[1,2,3]},{list:[1,2,3]},{list:[1,2,3]},{list:[1,2,3]}], detailList:[],
serviceId:'',// ID serviceId:'',// ID
showPop:false,// popup showPop:false,// popup
selectAreaValue:'',// ID selectAreaValue:'',// ID
@ -204,10 +206,11 @@ export default {
} }
}, },
onLoad(query){ onLoad(query){
console.log(query) console.log('query',query)
// query id searchTime // query id searchTime
// //
this.menu = uni.getMenuButtonBoundingClientRect() this.menu = uni.getMenuButtonBoundingClientRect()
//
// lastDay // lastDay
if (query.search){ if (query.search){
this.searchTime = query.search this.searchTime = query.search
@ -225,19 +228,22 @@ export default {
} }
this.lastDay = uni.getStorageSync('lastDay') this.lastDay = uni.getStorageSync('lastDay')
// //
console.log('this.searchTime',this.searchTime)
const date = new Date(this.searchTime) const date = new Date(this.searchTime)
let month = date.getMonth() + 1 let month = date.getMonth() + 1
//
const nowDate = new Date(this.lastDay)
let nowMonth = nowDate.getMonth() + 1
// //
this.monthList = this.monthList.filter(item=>item.value<=month) this.monthList = this.monthList.filter(item=>item.value<=nowMonth)
// //
this.swiperList = this.swiperList.filter((item,index)=>index<month) this.swiperList = this.swiperList.filter((item,index)=>index<nowMonth)
// //
this.selectDetail = month - 1 this.selectDetail = month - 1
// id // id
this.serviceId = query.id this.serviceId = query.id
// //
this.getServiceList() this.getServiceList()
//
this.getServiceDetail() this.getServiceDetail()
}, },
onReady(){ onReady(){
@ -250,8 +256,8 @@ export default {
this.selectMonth = month this.selectMonth = month
this.selectMonthId = `item${month}` this.selectMonthId = `item${month}`
}, },
//
handleDetailScroll(e){ handleDetailScroll(e){
console.log('e.detail.current',e.detail.current)
this.selectDetail = e.detail.current this.selectDetail = e.detail.current
this.selectMonth = e.detail.current + 1 this.selectMonth = e.detail.current + 1
const date = new Date(this.lastDay) const date = new Date(this.lastDay)
@ -309,7 +315,6 @@ export default {
} }
} }
const totalData = await request.$webGet('CommercialApi/Budget/GetBudgetProjectDetailList',req) const totalData = await request.$webGet('CommercialApi/Budget/GetBudgetProjectDetailList',req)
console.log(totalData)
this.detailList = totalData.Result_Data.List this.detailList = totalData.Result_Data.List
// //
this.detailList.forEach(item=>{ this.detailList.forEach(item=>{
@ -328,7 +333,6 @@ export default {
} }
} }
}) })
console.log('this.detailList',this.detailList)
}, },
// //
async handleServiceDetail(){ async handleServiceDetail(){
@ -347,6 +351,7 @@ export default {
let d = this.$util.getThisMonthDay(this.searchTime) let d = this.$util.getThisMonthDay(this.searchTime)
reqTime=`${y}-${m}-${d}` reqTime=`${y}-${m}-${d}`
} }
//
let req = { let req = {
Province_Code:'340000', Province_Code:'340000',
Statistics_Date:reqTime, Statistics_Date:reqTime,
@ -355,13 +360,11 @@ export default {
} }
const data = await request.$webGet('CommercialApi/Revenue/GetRevenueBudget',req) const data = await request.$webGet('CommercialApi/Revenue/GetRevenueBudget',req)
this.serviceDetailObj = data.Result_Data this.serviceDetailObj = data.Result_Data
for (let key in this.serviceDetailObj){
for (let key in this.serviceDetailObj){ for (let key in this.serviceDetailObj){
if (key==='RevenueMonth_Amount' || key==='BudgetMonth_Amount'){ if (key==='RevenueMonth_Amount' || key==='BudgetMonth_Amount'){
this.serviceDetailObj[key] = this.$util.fmoney(this.serviceDetailObj[key]) this.serviceDetailObj[key] = this.$util.fmoney(this.serviceDetailObj[key])
} }
} }
}
uni.hideLoading() uni.hideLoading()
}, },
// //
@ -377,13 +380,14 @@ export default {
item.children = this.editData(item.children) item.children = this.editData(item.children)
if (item.node.ShowRevenue_Amount){ if (item.node.ShowRevenue_Amount){
item.node.REVENUE_AMOUNT = item.node.REVENUE_AMOUNT ? this.$util.fmoney(item.node.REVENUE_AMOUNT ) :'' item.node.REVENUE_AMOUNT = item.node.REVENUE_AMOUNT ? this.$util.fmoney(item.node.REVENUE_AMOUNT ) :''
item.node.REVENUE_AMOUNT = this.$util.fmoney(item.node.REVENUE_AMOUNT) item.node.BUDGETDETAIL_AMOUNT = item.node.BUDGETDETAIL_AMOUNT? this.$util.fmoney(item.node.BUDGETDETAIL_AMOUNT ) :''
} }
}else{ }else{
//
item.children = [{},{},{}] item.children = [{},{},{}]
if (item.node.REVENUE_AMOUNT){ if (item.node.REVENUE_AMOUNT){
item.node.REVENUE_AMOUNT = item.node.REVENUE_AMOUNT ? this.$util.fmoney(item.node.REVENUE_AMOUNT ) :'' item.node.REVENUE_AMOUNT = item.node.REVENUE_AMOUNT ? this.$util.fmoney(item.node.REVENUE_AMOUNT ) :''
item.node.REVENUE_AMOUNT = this.$util.fmoney(item.node.REVENUE_AMOUNT) item.node.BUDGETDETAIL_AMOUNT = item.node.BUDGETDETAIL_AMOUNT? this.$util.fmoney(item.node.BUDGETDETAIL_AMOUNT ) :''
}else{ }else{
item.node.REVENUE_AMOUNT = '-' item.node.REVENUE_AMOUNT = '-'
} }
@ -404,7 +408,10 @@ export default {
// id // id
this.selectServiceId = item.value this.selectServiceId = item.value
this.selectServiceName = item.label.split('服务区')[0] this.selectServiceName = item.label.split('服务区')[0]
//
this.handleServiceDetail() this.handleServiceDetail()
//
this.getServiceDetail()
// //
this.hidePopup() this.hidePopup()
}, },

View File

@ -7,7 +7,6 @@
<p class="contentName">{{item.BUSINESSPROJECT_NAME}}</p> <p class="contentName">{{item.BUSINESSPROJECT_NAME}}</p>
<!-- 右侧 --> <!-- 右侧 -->
<!-- 有效状态 --> <!-- 有效状态 -->
<p v-if="item.DealMark===0" class="other-coast">{{item.PROJECTWARNING_STATE===1000?'待切换':item.PROJECTWARNING_STATE===2000?'审核中':item.PROJECTWARNING_STATE===9000?'已切换':item.PROJECTWARNING_STATE===9999?'暂不切换':''}}</p> <p v-if="item.DealMark===0" class="other-coast">{{item.PROJECTWARNING_STATE===1000?'待切换':item.PROJECTWARNING_STATE===2000?'审核中':item.PROJECTWARNING_STATE===9000?'已切换':item.PROJECTWARNING_STATE===9999?'暂不切换':''}}</p>
<p v-else class="other-coastGray">{{item.PROJECTWARNING_STATE===1000?'待切换':item.PROJECTWARNING_STATE===2000?'审核中':item.PROJECTWARNING_STATE===9000?'已切换':item.PROJECTWARNING_STATE===9999?'暂不切换':''}}</p> <p v-else class="other-coastGray">{{item.PROJECTWARNING_STATE===1000?'待切换':item.PROJECTWARNING_STATE===2000?'审核中':item.PROJECTWARNING_STATE===9000?'已切换':item.PROJECTWARNING_STATE===9999?'暂不切换':''}}</p>
<!-- <p v-else :class="item.PROJECTWARNING_STATE===9999 || item.PROJECTWARNING_STATE===9000?'other-coast other-coastGray':'other-coast'">{{item.PROJECTWARNING_STATE===1000?'待切换':item.PROJECTWARNING_STATE===2000?'审核中':item.PROJECTWARNING_STATE===9000?'已切换':item.PROJECTWARNING_STATE===9999?'暂不切换':''}}</p>--> <!-- <p v-else :class="item.PROJECTWARNING_STATE===9999 || item.PROJECTWARNING_STATE===9000?'other-coast other-coastGray':'other-coast'">{{item.PROJECTWARNING_STATE===1000?'待切换':item.PROJECTWARNING_STATE===2000?'审核中':item.PROJECTWARNING_STATE===9000?'已切换':item.PROJECTWARNING_STATE===9999?'暂不切换':''}}</p>-->
@ -24,14 +23,17 @@
<!-- 中间 --> <!-- 中间 -->
<!-- 资质到期时间 --> <!-- 资质到期时间 -->
<p class="titleStyle" > <p class="titleStyle" >
<!-- 先判断是否有切换时间,如果有直接显示已切换,没有切换时间再判断是否有天数 有就显示天数没有就显示完成保底 -->
<text v-if="item.SWITCH_DATE">
<text style="font-size:18px;line-height:50px;margin:0 4px;color: red;">已切换</text>
</text>
<text v-else>
<text v-if="item.EXPIREDAYS!==0"> <text v-if="item.EXPIREDAYS!==0">
<text style="font-size: 12px;color: orangered;">预计</text> <text style="font-size: 12px;color: orangered;">预计</text>
<text style="font-size: 28px;line-height: 50px;margin: 0 4px;">{{item.EXPIREDAYS}}</text> <text style="font-size: 28px;line-height: 50px;margin: 0 4px;">{{item.EXPIREDAYS}}</text>
<text style="font-size: 12px;"></text> <text style="font-size: 12px;"></text>
</text> </text>
<text v-else> <text style="font-size:18px;line-height:50px;margin:0 4px;" v-else>完成保底</text>
<text style="fontSize:18px;lineHeight:50px;margin:0 4px;color: red;" v-if="item.SWITCH_DATE">已切换</text>
<text style="fontSize:18px;lineHeight:50px;margin:0 4px;" v-else>完成保底</text>
</text> </text>
</p> </p>
</view> </view>
@ -46,7 +48,8 @@
<span class="content-span">{{item.BUSINESS_TYPE===1000?'合作经营':item.BUSINESS_TYPE===2000?'固定租金':''}}</span> <span class="content-span">{{item.BUSINESS_TYPE===1000?'合作经营':item.BUSINESS_TYPE===2000?'固定租金':''}}</span>
</view> </view>
<!-- 卡片第四行第一项右侧数据 --> <!-- 卡片第四行第一项右侧数据 -->
<text class="content-span lh15">{{item.WARNING_DATE}}</text> <!-- CHANG_DATE是SWITCH_DATE不保留时分秒的数据 获取数组的地方加的 -->
<text class="content-span lh15">{{item.SWITCH_DATE?item.CHANG_DATE:item.WARNING_DATE}}</text>
</view> </view>
</view> </view>
</template> </template>

View File

@ -64,6 +64,9 @@
商家<span class="strong">{{SJValue|| '-'}}%</span> 商家<span class="strong">{{SJValue|| '-'}}%</span>
<span v-if="dataDetail.PROJECTWARNING_STATE>0&&dataDetail.PROJECTWARNING_STATE<9000"></span> <span v-if="dataDetail.PROJECTWARNING_STATE>0&&dataDetail.PROJECTWARNING_STATE<9000"></span>
</view> </view>
<view v-if='dataDetail.PROJECTWARNING_STATE>0 && dataDetail.PROJECTWARNING_STATE<9000' class="text" style="margin-top: 8px" :style="{marginBottom: dataDetail.PROJECTWARNING_STATE===2000?'8px':'0px'}">
<span>{{ `切换日期默认设定:` }}<span class="strong">{{configTime}}</span></span>
</view>
</view> </view>
</view> </view>
<view class="contain" v-if="storeList.length && storeList.length>0"> <view class="contain" v-if="storeList.length && storeList.length>0">
@ -107,6 +110,7 @@ export default {
desc:[],// desc:[],//
type:true,// type:true,//
storeList:[],// storeList:[],//
configTime:''
} }
}, },
onLoad(query){ onLoad(query){
@ -114,19 +118,24 @@ export default {
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()
console.log('this.menu',this.menu)
this.PROJECTWARNING_ID = query.id this.PROJECTWARNING_ID = query.id
this.handleGetDetail() this.handleGetDetail()
this.useDate = Store.state.userData this.useDate = Store.state.userData
console.log('this.useDate',this.useDate)
if (query.type==='no'){ if (query.type==='no'){
this.type = false this.type = false
} }
this.handleStore() this.handleStore()
const date= new Date()
let m = date.getMonth() + 1
if (m === 12){
m = 1
}else{
m = m + 1
}
this.configTime = `${m}月1日0点`
}, },
// //
onUnload() { onUnload() {
console.log('页面关闭')
// //
this.$util.addUserBehaviorNew() this.$util.addUserBehaviorNew()
}, },
@ -141,7 +150,6 @@ export default {
}).then(res=>{ }).then(res=>{
uni.hideLoading() uni.hideLoading()
this.dataDetail = res.Result_Data this.dataDetail = res.Result_Data
console.log('this.dataDetail',this.dataDetail)
// //
for (let key in this.dataDetail){ for (let key in this.dataDetail){
if (key==='REVENUEDAILY_AMOUNT' || key==='REVENUE_AMOUNT' || key==='ROYALTY_PRICE' || key==='SUBROYALTY_PRICE' || key==='TICKET_FEE' || key==='MINTURNOVER'){ if (key==='REVENUEDAILY_AMOUNT' || key==='REVENUE_AMOUNT' || key==='ROYALTY_PRICE' || key==='SUBROYALTY_PRICE' || key==='TICKET_FEE' || key==='MINTURNOVER'){
@ -155,8 +163,6 @@ export default {
this.desc[0] = this.dataDetail.PROJECTWARNING_DESC.split('【')[0] this.desc[0] = this.dataDetail.PROJECTWARNING_DESC.split('【')[0]
this.desc[1] = this.dataDetail.PROJECTWARNING_DESC.split('【')[1].split('')[1] this.desc[1] = this.dataDetail.PROJECTWARNING_DESC.split('【')[1].split('')[1]
} }
console.log('this.time',this.time)
console.log('this.desc',this.desc)
}) })
}, },
handleStore(){ handleStore(){
@ -170,7 +176,6 @@ export default {
SortStr: "APPROVED_DATE desc" SortStr: "APPROVED_DATE desc"
}).then(res=>{ }).then(res=>{
this.storeList = res.Result_Data.List this.storeList = res.Result_Data.List
console.log('this.storeList',this.storeList)
}) })
}, },
// //
@ -212,7 +217,6 @@ export default {
if (this.dataDetail.PROJECTWARNING_STATE===1000){ if (this.dataDetail.PROJECTWARNING_STATE===1000){
this.handleBack() this.handleBack()
} }
console.log('res')
uni.showToast({ uni.showToast({
title: res.Result_Desc, title: res.Result_Desc,
icon: 'none' icon: 'none'

View File

@ -35,11 +35,11 @@
<p class="title" style="margin-top: 20px">日期</p> <p class="title" style="margin-top: 20px">日期</p>
<view class="selectTime"> <view class="selectTime">
<picker class="time" mode="date" @change="handlechangeTime($event,0)"> <picker class="time" mode="date" @change="handlechangeTime($event,0)">
<text>{{searchTime[0]}}</text> <text>{{'请选择开始时间'}}</text>
</picker> </picker>
- -
<picker class="time" style="text-align: right" mode="date" @change="handlechangeTime($event,1)"> <picker class="time" style="text-align: right" mode="date" @change="handlechangeTime($event,1)">
<text>{{searchTime[1]}}</text> <text>{{'请选择结束时间'}}</text>
</picker> </picker>
</view> </view>
<view class="popbtn" @click="reloadList">确定</view> <view class="popbtn" @click="reloadList">确定</view>
@ -58,8 +58,8 @@ import UniPop from '@/components/uni-popup.vue'
export default { export default {
components: {ListUnit,UniPop}, components: {ListUnit,UniPop},
data() { data() {
let stime = this.$util.cutDate(new Date(), 'YYYY-MM-DD', -6) let stime = ''
let etime = this.$util.cutDate(new Date(), 'YYYY-MM-DD') let etime = ''
return { return {
menuList: [ menuList: [
{ // { //
@ -119,6 +119,7 @@ export default {
onShow(){ onShow(){
this.pageData.pageIndex = 1 this.pageData.pageIndex = 1
this.handleGetList() this.handleGetList()
this.pageData.isEnd = false
}, },
onReachBottom () { onReachBottom () {
if (!this.pageData.isEnd){ if (!this.pageData.isEnd){
@ -161,7 +162,7 @@ export default {
WARNING_DATE_Start:this.searchTime[0],// () WARNING_DATE_Start:this.searchTime[0],// ()
WARNING_DATE_End:this.searchTime[1],// () WARNING_DATE_End:this.searchTime[1],// ()
PROJECTWARNING_STATE:'',// PROJECTWARNING_STATE:'',//
PROJECTWARNING_STATES:'',// () PROJECTWARNING_STATES:this.activeType===1?'1000,2000':this.activeType===2?'9000':'',// ()
RECORD_DATE:'',// RECORD_DATE:'',//
PROJECTWARNING_DESC:'',// PROJECTWARNING_DESC:'',//
REVENUE_AMOUNT:'',// REVENUE_AMOUNT:'',//
@ -189,18 +190,38 @@ export default {
} else { } else {
// //
let list = res.Result_Data.List.filter(p => { let list = res.Result_Data.List.filter(p => {
if (p.SWITCH_DATE){
const date = new Date(p.SWITCH_DATE)
const y = date.getFullYear()
let m = date.getMonth() + 1
let d = date.getDate()
if (m<10){
m = '0'+m
}
if (d<10){
d = '0'+d
}
p.CHANG_DATE = `${y}-${m}-${d}`
}
if (this.activeType === 1) { if (this.activeType === 1) {
return p.BUSINESS_TYPE === 1000 return p.PROJECTWARNING_STATE === 1000 || p.PROJECTWARNING_STATE === 2000
} else if (this.activeType === 2) { } else if (this.activeType === 2) {
return p.BUSINESS_TYPE === 9000 return p.PROJECTWARNING_STATE === 9000
} else { } else {
return true return true
} }
}) })
console.log('list',list)
if (list.length > 0) { if (list.length > 0) {
this.TotalCount = res.Result_Data.TotalCount this.TotalCount = res.Result_Data.TotalCount
if (this.pageData.pageIndex === 1) { if (this.pageData.pageIndex === 1) {
this.pageList = list this.pageList = list
if (list.length<this.TotalCount){
}else{
this.pageData.isEnd = true
}
} else { } else {
if (this.pageList.length<this.TotalCount){ if (this.pageList.length<this.TotalCount){
this.pageList = this.pageList.concat(list) this.pageList = this.pageList.concat(list)

View File

@ -45,3 +45,27 @@ export function handleYesterday(value) {
return `${y}-${m}-${d}` return `${y}-${m}-${d}`
} }
// 处理树列表数据的方法
export function wrapTreeNode(data) {
const wrapData = data.map((item) => {
const node = { ...item.node };
if (item.children && item.children.length > 0) {
node.children = wrapTreeNode(item.children);
}
return node
});
return wrapData;
}
export function tableList(list) {
return {
data: list.List || [],
current: list.PageIndex || 1,
pageSize: list.pageSize || 10,
total: list.TotalCount || 0,
otherData: list?.OtherData || '',
success: true,
};
}