Commit 2703a404 authored by youjie's avatar youjie

优化及修复

parent ff1ad60b
......@@ -250,7 +250,7 @@ export default {
this.OtherList = this.params.OtherOrderInfo.OtherList
this.OtherList.forEach(x=>{
x.UseDate = x.UseDate?this.$utils.formatDates(new Date(x.UseDate),'yyyy-MM-dd'):''
let findIndex = this.options.findIndex(y=>y.id==x.CostProject)
let findIndex = this.options.findIndex(y=>y.id==x.CostProject&&x.ID>0)
if(findIndex!=-1) x.CostProjectStr =this.options[findIndex].name
let findIndex2 = this.currencyList.findIndex(y=>y.id==x.Currency)
if(findIndex2!=-1) x.CurrencyName =this.currencyList[findIndex2].name
......
......@@ -42,7 +42,7 @@
</view>
</view>
<view class="infor1-c-r PY30 colorFFF flex1">
<view class="day fz32 PX30">Day{{ item.DayNum>9?item.DayNum:'0'+item.DayNum }}</view>
<view class="day fz32 PX30">Day{{ item.DayNum>9?item.DayNum:item.DayNum }}</view>
<view class="color333 text row items-center MT10 PX30">
{{ item.Title }}
</view>
......
......@@ -100,7 +100,7 @@
z-index: 2;
}
.richText{
white-space: pre-wrap;
// white-space: pre-wrap;
}
.name-ali{
overflow: hidden;
......@@ -233,7 +233,7 @@
<view v-if="dataList.productRecommend" class="fz28 PB20">
<rich-text :nodes="dataList.productRecommend" class="richText"></rich-text>
</view>
<view v-else class="fz28 PB20" style="color: #7B7B7B;">填写</view>
<view v-else class="fz28 PB20" style="color: #7B7B7B;">填写</view>
</view>
</view>
<view class="bjLine"></view>
......@@ -274,7 +274,7 @@
</view>
</view>
</template>
<view v-else class="fz28 PB20" style="color: #7B7B7B;">航班信息</view>
<view v-else class="fz28 PB20" style="color: #7B7B7B;">航班信息</view>
</view>
</view>
<view class="bjLine"></view>
......@@ -406,7 +406,7 @@
<text class="fz32 fontBold ML20">预定须知</text>
</view>
<view class="PB20">
<text class="itiner-win">重要提示</text>
<text class="itiner-win colorE1432E fontBold">重要提示</text>
</view>
<view class="PB20">
<view class="fz26">
......
......@@ -71,33 +71,17 @@
:style="[boxOption>0?'titleStyle':'']">
<headers textAlign="left" :title="pageTitle" color="#fff"></headers>
<scroll-view class="reimbursementInforTsBox" :scroll-x="true"
>
:scroll-left="scrollLeft">
<view class="reimbursementInforT-text row-aic-n">
<view class="reimbursementInforText"
:class="[params.type==item.id?'active':'']"
v-for="(item,index) in titles"
:id="`refs_${index+1}`"
:key="index"
@click="getType(item)">{{ item.name }}</view>
</view>
</scroll-view>
</view>
<!--
<view class="reimbursementInforTitle fixed"
:style="{ opacity: boxOption + '%' }">
<headers textAlign="left" :title="pageTitle" color="#fff"></headers>
<scroll-view class="reimbursementInforTsBox" :scroll-x="true"
:style="[titleStyle]"
:scroll-left="scrollLeft"
@scroll="scrollHandler">
<view class="reimbursementInforT-text row-aic-n">
<view class="reimbursementInforText"
:class="[params.type==item.id?'active':'']"
v-for="(item,index) in titles"
:key="index"
@click="getType(item)">{{ item.name }}</view>
</view>
</scroll-view>
</view>-->
<headeDatas v-show="params.type<5" :currencyList="currencyList" :data="params" @change="getNewData"></headeDatas>
</view>
<!-- 车信息-->
......@@ -171,42 +155,62 @@ export default {
{
name:'车辆',
id: 1,
val: 'refs1',
left: 0,
},
{
name:'酒店',
id: 2,
val: 'refs2',
left: 0,
},
{
name:'餐食',
id: 3,
val: 'refs3',
left: 0,
},
{
name:'门票',
id: 4,
val: 'refs4',
left: 0,
},
{
name:'其他费用',
id: 5,
val: 'refs5',
left: 0,
},
{
name:'小费收入',
id: 6,
val: 'refs6',
left: 0,
},
{
name:'团费小计',
id: 7,
val: 'refs7',
left: 0,
},
{
name:'自费收入',
id: 8,
val: 'refs8',
left: 0,
},
{
name:'自费支出',
id: 9,
val: 'refs9',
left: 0,
},
{
name:'购物报账',
id: 10,
val: 'refs10',
left: 0,
},
],
currencyVisible: false,
......@@ -290,6 +294,28 @@ export default {
});
this.getOptionData()
this.getCurrencyList()
this.$nextTick(() => {
this.titles.forEach((x, index) => {
// 查询当前元素的位置
uni.createSelectorQuery()
.in(this) // 限定在当前组件内查询(关键!)
.select(`#refs_${index + 1}`) // 匹配元素的 id
.fields({
position: true, // 获取位置信息(left/top)
size: true // 获取尺寸(width/height)
})
.exec((res) => {
if (res[0]) {
const { left, top, width, height } = res[0];
// console.log(`元素 ${index} 的横向位置(left):`, left); // 单位:px
// console.log(`元素 ${index} 的宽度:`, width);
x.left = width*(index)
} else {
console.log(`未找到元素 refs_${index + 1}`);
}
});
});
});
},
methods: {
saveData(){
......@@ -319,6 +345,7 @@ export default {
getType(item){
this.params.type = item.id
this.oldDataIndex = item.id
this.scrollLeft = item.left
},
init() {
uni.showLoading()
......
......@@ -34,7 +34,7 @@
background: #FF8445;
}
.roomListCenter.active4 .roomListC-L-type{
background: #e0a015;
background: #FF528B;
}
.roomListC-box{
background: #F8F8F8;
......
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