Commit 05e2713e authored by youjie's avatar youjie

修复bug

parent e28e1e59
<template> <template>
<view class="ActInProBox column" <view class="ActInProBox column"
:class="[Details.Level>0?`activeLv${Details.Level}`:'activeLv1']"> :class="[Details.Level>0?`activeLv${Details.Level}`:'activeLv1']">
<!--:scroll-top="scrollTop"-->
<scroll-view :scroll-y="true" <scroll-view :scroll-y="true"
style="height: 1px;flex: 1;box-sizing: border-box;" style="height: 1px;flex: 1;box-sizing: border-box;"
@scroll="scroll" @scroll="scroll">
:scroll-top="scrollTop">
<view class="ActInProHeaderBox" :style="{ opacity: 100 - boxOption + '%' }" <view class="ActInProHeaderBox" :style="{ opacity: 100 - boxOption + '%' }"
:class="[Details.Level>0?`activeLv${Details.Level}`:'activeLv1']"> :class="[Details.Level>0?`activeLv${Details.Level}`:'activeLv1']">
<headers :title="page" color="#fff"></headers> <headers :title="page" color="#fff"></headers>
...@@ -139,7 +139,7 @@ ...@@ -139,7 +139,7 @@
<view class="ActInProListTimeR">¥{{item.Money}}</view> <view class="ActInProListTimeR">¥{{item.Money}}</view>
</view> </view>
</view> </view>
<u-empty v-if="CustomerOrderList.length == 0" text="暂无数据" mode="data"></u-empty> <u-empty v-if="CustomerOrderList.length == 0" text="暂无数据" mode="data" padding-top="0"></u-empty>
</view> </view>
<view v-if="Details" <view v-if="Details"
class="RuleDetails"> class="RuleDetails">
...@@ -243,8 +243,8 @@ export default { ...@@ -243,8 +243,8 @@ export default {
scrollShow: false, // 新增是否显示滚动条,默认false scrollShow: false, // 新增是否显示滚动条,默认false
scrollAlign: 'left', // 滚动条初始位置 scrollAlign: 'left', // 滚动条初始位置
rotateLabel: false, // X轴label旋转 rotateLabel: false, // X轴label旋转
min: 0, // Y轴最小值 // min: 0, // Y轴最小值
max: 150, //Y轴大值 // max: 150, //Y轴大值
unit: '', // Y轴单位 unit: '', // Y轴单位
enableScroll: false, // 开启滚动模式 enableScroll: false, // 开启滚动模式
color: [ color: [
...@@ -256,6 +256,7 @@ export default { ...@@ -256,6 +256,7 @@ export default {
color: ["#1890FF","#91CB74","#FAC858","#EE6666","#73C0DE","#3CA272","#FC8452","#9A60B4","#ea7ccc"], color: ["#1890FF","#91CB74","#FAC858","#EE6666","#73C0DE","#3CA272","#FC8452","#9A60B4","#ea7ccc"],
padding: [25,5,10,5], padding: [25,5,10,5],
enableScroll: false, enableScroll: false,
pageScrollTop: 477,
legend: { legend: {
show: false, show: false,
}, },
...@@ -290,6 +291,8 @@ export default { ...@@ -290,6 +291,8 @@ export default {
}, },
}, },
isType: 2, isType: 2,
isVisible: 0,
scrollViewHeight: 0,
} }
}, },
watch:{ watch:{
...@@ -338,9 +341,30 @@ export default { ...@@ -338,9 +341,30 @@ export default {
this.msg.YearMonth = this.year + '-' + this.month this.msg.YearMonth = this.year + '-' + this.month
}, },
mounted() { mounted() {
const query = uni.createSelectorQuery().in(this);
query.select('.ActInProCenterBox').boundingClientRect(rect => {
this.scrollViewHeight = rect.height; // 获取 scroll-view 内容区域高度
}).exec();
this.getSignDetails() this.getSignDetails()
this.getElementPosition()
}, },
methods: { methods: {
// 获取元素位置
getElementPosition() {
const query = uni.createSelectorQuery().in(this);
query.select('.ActInProCenTimeBox').boundingClientRect(rect => {
if (rect) {
// 计算元素相对于 scroll-view 顶部的位置
const relativeTop = rect.top - this.scrollTop;
console.log('元素相对于可视区域顶部的位置:', relativeTop);
// 判断元素是否在可视区域内
const isVisible = relativeTop >= 0 && relativeTop <= this.scrollViewHeight;
this.isVisible = isVisible
console.log('元素是否可见:', isVisible);
}
}).exec();
},
formatNumberWithUnit(num) { formatNumberWithUnit(num) {
if (num === 0) return '0.00'; if (num === 0) return '0.00';
const units = ['', 'K', 'M', 'B', 'T']; // 单位数组:千(k)、百万(M)、十亿(B)、万亿(T) const units = ['', 'K', 'M', 'B', 'T']; // 单位数组:千(k)、百万(M)、十亿(B)、万亿(T)
...@@ -377,9 +401,7 @@ export default { ...@@ -377,9 +401,7 @@ export default {
let data = res.data let data = res.data
this.Details = data this.Details = data
this.CustomerOrderListAll = data.CustomerOrderList this.CustomerOrderListAll = data.CustomerOrderList
this.CustomerOrderList = data.CustomerOrderList.filter(item=>{ this.SelectDate(1)
return this.msg.YearMonth == item.CreateDate.slice(0,7)
})
let TotalAmount = 0 let TotalAmount = 0
for(let i=0;i<this.Details.OrderMonthList.length;i++){ for(let i=0;i<this.Details.OrderMonthList.length;i++){
...@@ -419,8 +441,7 @@ export default { ...@@ -419,8 +441,7 @@ export default {
this.$forceUpdate() this.$forceUpdate()
}, },
goTisp(){ goTisp(){
console.log(1111) this.scrollTop = this.scrollHeight?this.scrollHeight:1000000000
this.scrollTop = this.scrollHeight?this.scrollHeight:1000000
}, },
confirm(e){ confirm(e){
uni.hideLoading() uni.hideLoading()
...@@ -433,11 +454,8 @@ export default { ...@@ -433,11 +454,8 @@ export default {
this.msg.QStartDate = this.year + '-' + this.month + '-01' this.msg.QStartDate = this.year + '-' + this.month + '-01'
this.msg.QEndDate = this.year + '-' + this.month + '-'+now.getDate() this.msg.QEndDate = this.year + '-' + this.month + '-'+now.getDate()
this.msg.YearMonth = this.year + '-' + this.month this.msg.YearMonth = this.year + '-' + this.month
this.getCustomerOrderList() this.SelectDate(2)
this.showTime = false this.showTime = false
if(this.scrollTop>650){
this.scrollTop = 630
}
}, },
SelectDate(type){ SelectDate(type){
this.isType = type; this.isType = type;
...@@ -448,9 +466,6 @@ export default { ...@@ -448,9 +466,6 @@ export default {
}else{ }else{
this.showTime = true this.showTime = true
} }
if(this.scrollTop>650){
this.scrollTop = 630
}
}, },
goUrl(){ goUrl(){
uni.navigateTo({ uni.navigateTo({
......
...@@ -37,10 +37,11 @@ ...@@ -37,10 +37,11 @@
<view>银行账号</view> <view>银行账号</view>
<view class="col">{{ authInfor.CardNum }}</view> <view class="col">{{ authInfor.CardNum }}</view>
</view> </view>
<!--
<view class="PaymentProCText row-sbas-n"> <view class="PaymentProCText row-sbas-n">
<view>电话</view> <view>电话</view>
<view class="col">{{ authInfor.ContactNumber }}</view> <view class="col">{{ authInfor.ContactNumber }}</view>
</view> </view>-->
<view class="PaymentProCText row-sbas-n"> <view class="PaymentProCText row-sbas-n">
<view>服务人员</view> <view>服务人员</view>
<view class="col">{{ authInfor.EnterName }}</view> <view class="col">{{ authInfor.EnterName }}</view>
...@@ -154,7 +155,6 @@ export default { ...@@ -154,7 +155,6 @@ export default {
} }
}, },
mounted() { mounted() {
this.getInfor()
this.getSignDetails() this.getSignDetails()
}, },
methods: { methods: {
...@@ -192,6 +192,7 @@ export default { ...@@ -192,6 +192,7 @@ export default {
if (res.resultCode == 1) { if (res.resultCode == 1) {
let data = res.data let data = res.data
this.Details = data this.Details = data
this.authInfor = data
if(this.type==2){ if(this.type==2){
this.toExamineSteps[0].Time = data.CreateTime this.toExamineSteps[0].Time = data.CreateTime
this.toExamineSteps[1].Time = data.UpdateTime this.toExamineSteps[1].Time = data.UpdateTime
...@@ -228,11 +229,7 @@ export default { ...@@ -228,11 +229,7 @@ export default {
res=>{ res=>{
if (res.resultCode == 1) { if (res.resultCode == 1) {
let data = res.data let data = res.data
this.authInfor = data // this.authInfor.ContactNumber = data.ContactNumber?data.ContactNumber:''
if(this.type==2){
if(this.authInfor.Status==1||this.authInfor.Status==3) this.StepNum = 0
else this.StepNum = 1
}
} }
}) })
}, },
......
...@@ -84,7 +84,7 @@ ...@@ -84,7 +84,7 @@
</view> </view>
</view> </view>
</view> </view>
<u-empty v-if="CustomerOrderList.length == 0" text="暂无数据" mode="data"></u-empty> <u-empty v-if="CustomerOrderList.length == 0" text="暂无数据" mode="data" padding-top="0"></u-empty>
<view style="height: 20rpx;"></view> <view style="height: 20rpx;"></view>
</scroll-view> </scroll-view>
...@@ -270,6 +270,7 @@ export default { ...@@ -270,6 +270,7 @@ export default {
}, },
(res) => { (res) => {
if(res.resultCode == 1){ if(res.resultCode == 1){
uni.hideLoading()
uni.showToast({ uni.showToast({
title: '提交成功', title: '提交成功',
icon: 'success', icon: 'success',
...@@ -280,15 +281,15 @@ export default { ...@@ -280,15 +281,15 @@ export default {
url: `/pages/bigredrnvelope/PaymentProgress?type=3&ContractId=${this.ContractId}` url: `/pages/bigredrnvelope/PaymentProgress?type=3&ContractId=${this.ContractId}`
}) })
} }
uni.hideLoading()
},err=>{ },err=>{
uni.hideLoading()
uni.showToast({ uni.showToast({
title: err.message, title: err.message,
icon:'none', icon:'none',
duration: 2000, duration: 2000,
}) })
this.loading = false this.loading = false
uni.hideLoading()
} }
); );
...@@ -316,7 +317,7 @@ export default { ...@@ -316,7 +317,7 @@ export default {
let data = res.data let data = res.data
this.Details = data this.Details = data
this.CustomerOrderListAll = data.CustomerOrderList this.CustomerOrderListAll = data.CustomerOrderList
this.getCustomerOrderList() this.SelectDate(1)
uni.hideLoading() uni.hideLoading()
this.$forceUpdate() this.$forceUpdate()
} }
...@@ -351,9 +352,8 @@ export default { ...@@ -351,9 +352,8 @@ export default {
this.msg.QStartDate = this.year + '-' + this.month + '-01' this.msg.QStartDate = this.year + '-' + this.month + '-01'
this.msg.QEndDate = this.year + '-' + this.month + '-'+now.getDate() this.msg.QEndDate = this.year + '-' + this.month + '-'+now.getDate()
this.msg.YearMonth = this.year + '-' + this.month this.msg.YearMonth = this.year + '-' + this.month
this.getCustomerOrderList() this.SelectDate(2)
this.showTime = false this.showTime = false
// this.scrollTop = 630
}, },
SelectDate(type){ SelectDate(type){
this.isType = type; this.isType = type;
...@@ -364,7 +364,6 @@ export default { ...@@ -364,7 +364,6 @@ export default {
}else{ }else{
this.showTime = true this.showTime = true
} }
// this.scrollTop = 630
}, },
goUrl(){ goUrl(){
uni.navigateTo({ uni.navigateTo({
......
...@@ -17,7 +17,7 @@ export default { ...@@ -17,7 +17,7 @@ export default {
components: { }, components: { },
data() { data() {
return { return {
action: this.host2 + "/api/File/UploadTencent", // action: this.host2 + "/api/File/UploadTencent",
access_token: '', access_token: '',
} }
}, },
...@@ -83,7 +83,7 @@ export default { ...@@ -83,7 +83,7 @@ export default {
if (_res.data.direction == 1) { if (_res.data.direction == 1) {
//未定义,图片类型错误 //未定义,图片类型错误
wx.showToast({ wx.showToast({
title: "图片类型错误!", title: _res+'_22',//"图片类型错误!"
icon: "none", icon: "none",
duration: 1000, duration: 1000,
}); });
...@@ -133,8 +133,10 @@ export default { ...@@ -133,8 +133,10 @@ export default {
//图片上传 //图片上传
upFile(filePath,resCall) { upFile(filePath,resCall) {
let that = this; let that = this;
let MallBaseId = uni.getStorageSync("mall_UserInfo").MallBaseId ? uni.getStorageSync("mall_UserInfo").MallBaseId : 1;
let action = this.host2 + '/api/File/UploadTencent?MallBaseId=' + MallBaseId
uni.uploadFile({ uni.uploadFile({
url: that.action, url: action,
filePath: filePath, filePath: filePath,
name: 'file', name: 'file',
formData: { formData: {
...@@ -153,10 +155,10 @@ export default { ...@@ -153,10 +155,10 @@ export default {
} }
}, },
fail: function(res) { fail: function(err) {
console.log(res) console.log(err)
wx.showToast({ wx.showToast({
title: '上传失败!', title: '上传失败!'+JSON.stringify(err),
icon: 'none', icon: 'none',
duration: 1000 duration: 1000
}) })
...@@ -189,7 +191,7 @@ export default { ...@@ -189,7 +191,7 @@ export default {
}, },
fail(res) { fail(res) {
wx.showToast({ wx.showToast({
title: "图片类型错误!", title: res,//"图片类型错误!"
icon: "none", icon: "none",
duration: 1000, duration: 1000,
}); });
......
...@@ -53,7 +53,7 @@ ...@@ -53,7 +53,7 @@
</view> </view>
</view> </view>
</view> </view>
<view class="bigRedEnvLiYou" v-if="item.Status==3"> <view class="bigRedEnvLiYou" v-if="item.Status==3&&item.AuditContractReason">
驳回理由:{{ item.AuditContractReason }} 驳回理由:{{ item.AuditContractReason }}
</view> </view>
</view> </view>
...@@ -116,9 +116,10 @@ export default { ...@@ -116,9 +116,10 @@ export default {
}; };
this.showAuth = true; this.showAuth = true;
} }
this.getList()
}, },
mounted() { mounted() {
this.getList()
}, },
methods: { methods: {
formatAmount(value) { formatAmount(value) {
......
<template> <template>
<view class="bigRedEnvRule"> <view class="bigRedEnvRule">
<view class="bigRedEnvRuleHead">
<headers></headers>
</view>
<image mode="" style="height: 568rpx;" src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638796333602414702.jpg"/> <image mode="" style="height: 568rpx;" src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638796333602414702.jpg"/>
<image mode="" style="height: 939rpx;" src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638796333646350233.jpg"/> <image mode="" style="height: 939rpx;" src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638796333646350233.jpg"/>
<image mode="" style="height: 1031rpx;" src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638796333741115931.jpg"/> <image mode="" style="height: 1031rpx;" src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638796333741115931.jpg"/>
...@@ -20,9 +23,10 @@ ...@@ -20,9 +23,10 @@
</view> </view>
</template> </template>
<script> <script>
import headers from "@/components/header/header";
export default { export default {
components: { components: {
headers
}, },
data() { data() {
return { return {
...@@ -51,6 +55,12 @@ export default { ...@@ -51,6 +55,12 @@ export default {
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
@import url("@/asset/css/flex.css"); @import url("@/asset/css/flex.css");
.bigRedEnvRuleHead{
position: fixed;
left: 0;
top: 0;
z-index: 1;
}
.bigRedEnvRule{ .bigRedEnvRule{
} }
.bigRedEnvRule image{ .bigRedEnvRule image{
......
...@@ -284,9 +284,14 @@ ...@@ -284,9 +284,14 @@
<view style="margin-left: 50rpx;" @click="getUrl(3)">查看条款</view> <view style="margin-left: 50rpx;" @click="getUrl(3)">查看条款</view>
</view> </view>
</view> </view>
<view class="signAconNext" <view class="row-sbs-n">
:class="[msg.StepNum==4?'':'active']" @click="Next(4)"> <view v-if="msg.StepNum<4&&!loading" class="signAconNext signAconNextL col" @click="Prev(3)">
提交 上一步
</view>
<view class="signAconNext col"
:class="[msg.StepNum==5||loading?'':'active']" @click="Next(5)">
提交
</view>
</view> </view>
</view> </view>
</scroll-view> </scroll-view>
...@@ -362,6 +367,7 @@ export default { ...@@ -362,6 +367,7 @@ export default {
IsRenewalContract: 0, IsRenewalContract: 0,
ContractId: 0, ContractId: 0,
dataInfo: null, dataInfo: null,
isSign: false,
} }
}, },
onLoad(options) { onLoad(options) {
...@@ -371,6 +377,9 @@ export default { ...@@ -371,6 +377,9 @@ export default {
if(options.ContractId) { if(options.ContractId) {
this.ContractId = options.ContractId this.ContractId = options.ContractId
} }
if(options.isSign) {
this.isSign = options.isSign
}
}, },
onShow() { onShow() {
this.U = uni.getStorageSync("mall_UserInfo"); this.U = uni.getStorageSync("mall_UserInfo");
...@@ -414,14 +423,14 @@ export default { ...@@ -414,14 +423,14 @@ export default {
if(type==1) url = `https://activity.oytour.com/html/contract/index.html?msg=${encodeURIComponent(msg)}` if(type==1) url = `https://activity.oytour.com/html/contract/index.html?msg=${encodeURIComponent(msg)}`
if(type==2) url = `https://activity.oytour.com/html/contract/sign.html?msg=${encodeURIComponent(msg)}` if(type==2) url = `https://activity.oytour.com/html/contract/sign.html?msg=${encodeURIComponent(msg)}`
if(type==3) url = `https://activity.oytour.com/html/contract/index.html?ContractId=${this.msg.ContractId}` if(type==3) url = `https://activity.oytour.com/html/contract/index.html?ContractId=${this.msg.ContractId}`
if(process.env.NODE_ENV=="development") return console.log(url,"-----url") // if(process.env.NODE_ENV=="development") return console.log(url,"-----url")
if (url && url.length > 0) { if (url && url.length > 0) {
if(type==1||type==3){ if(type==1||type==3){
uni.navigateTo({ uni.navigateTo({
url: "/pages/webbox/webbox?u=" + encodeURIComponent(url), url: "/pages/webbox/webbox?u=" + encodeURIComponent(url),
}); });
}else if(type==2){ }else if(type==2){
uni.reLaunch({ uni.navigateTo({
url: "/pages/webbox/webbox?u=" + encodeURIComponent(url), url: "/pages/webbox/webbox?u=" + encodeURIComponent(url),
}); });
} }
...@@ -527,13 +536,15 @@ export default { ...@@ -527,13 +536,15 @@ export default {
}) })
return return
} }
if(this.msg.StepNum==4) return this.goWebUrl(1) // if(this.msg.StepNum==4) return this.goWebUrl(1)
const oldData = this.newMsg(type) const oldData = this.newMsg(type)
// console.log(oldData,'--------',type,!oldData) // console.log(oldData,'--------',type,!oldData)
// return // return
if(oldData) this.setInfor(type) if(oldData) this.setInfor(type)
else if(this.ContractId||type==4) this.setInfor(type) else if(this.ContractId||type==5) this.setInfor(type)
else if(type!=4) this.msg.StepNum = type else if(type!=5) {
this.msg.StepNum = type
}
}, },
onSuccess(data,type) { onSuccess(data,type) {
if(type==1) { if(type==1) {
...@@ -573,6 +584,10 @@ export default { ...@@ -573,6 +584,10 @@ export default {
},err=>{ },err=>{
uni.hideLoading() uni.hideLoading()
this.loading = false this.loading = false
uni.showToast({
title:err.message,
icon:'none'
})
console.log(err,'--------') console.log(err,'--------')
}) })
}, },
...@@ -648,7 +663,10 @@ export default { ...@@ -648,7 +663,10 @@ export default {
C_EndDate:data.RenewalContractEtime,// 合同结束时间 C_EndDate:data.RenewalContractEtime,// 合同结束时间
} }
if(this.IsRenewalContract||this.ContractId){ if(this.IsRenewalContract||this.ContractId){
this.msg.StepNum = 0 if(this.isSign){
this.msg.StepNum = 4
}else this.msg.StepNum = 0
if(this.IsRenewalContract==1) this.msg.ContractId = 0 if(this.IsRenewalContract==1) this.msg.ContractId = 0
if(this.ContractId) { if(this.ContractId) {
let ContractList = data.ContractList.filter(x=>{ let ContractList = data.ContractList.filter(x=>{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment