Commit e3b84638 by 李伟康

修改页面组件

1 parent 688bf832
...@@ -5,6 +5,15 @@ Component({ ...@@ -5,6 +5,15 @@ Component({
*/ */
properties: { properties: {
tabList: Array, tabList: Array,
defaultIndex: {
type: Number,
value: -1,
observer(n) {
this.setData({
tabIndex: n
})
}
}
}, },
/** /**
......
...@@ -1511,8 +1511,9 @@ Component({ ...@@ -1511,8 +1511,9 @@ Component({
}, },
// 查看更多违规记录 // 查看更多违规记录
goPage() { goPage() {
let {violationStatus} = this.data
wx.navigateTo({ wx.navigateTo({
url: '/packageEquity/pages/receptionRecords/receptionRecords?hideScore=1', url: `/packageEquity/pages/receptionRecords/receptionRecords?hideScore=1&tabValue=${violationStatus}`,
}) })
wx.$track.setTrackData(0, 'see_more') wx.$track.setTrackData(0, 'see_more')
}, },
......
...@@ -629,6 +629,7 @@ swiper{ ...@@ -629,6 +629,7 @@ swiper{
background: transparent; background: transparent;
} }
.empty-box{ .empty-box{
padding-top: var(--fontSize14);
display: flex; display: flex;
flex-flow: column; flex-flow: column;
justify-content: center; justify-content: center;
......
...@@ -80,11 +80,11 @@ ...@@ -80,11 +80,11 @@
} }
.color-2{ .color-2{
color: #FF6053; color: #FF6053;
font-weight: 700; font-weight: 700 !important;
} }
.color-1{ .color-1{
color: #7F80FE; color: #7F80FE;
font-weight: 700; font-weight: 700 !important;
} }
.appeal-btn { .appeal-btn {
display: none; display: none;
......
...@@ -160,8 +160,10 @@ Page({ ...@@ -160,8 +160,10 @@ Page({
let {typeLists} = this.data let {typeLists} = this.data
this.setData({ this.setData({
record: options, record: options,
typeLists:options.hideScore ? typeLists.splice(0,1) : typeLists typeLists:options.hideScore ? typeLists.splice(0,1) : typeLists,
showViolationBtn: options.hideScore && options.violationStatus == 1
}, () => { }, () => {
console.log('000')
this.setAudio() this.setAudio()
}) })
} }
...@@ -193,6 +195,7 @@ Page({ ...@@ -193,6 +195,7 @@ Page({
wx.$util.getViewInfo('.reception-wrap', ({ wx.$util.getViewInfo('.reception-wrap', ({
height height
}) => { }) => {
console.log(1)
this.setData({ this.setData({
receptionWrapHeight: `${height * 2}rpx` receptionWrapHeight: `${height * 2}rpx`
}) })
......
...@@ -10,7 +10,11 @@ ...@@ -10,7 +10,11 @@
</view> </view>
<view class="reception-nav"> <view class="reception-nav">
<view class="reception-types"> <view class="reception-types">
<view class="type {{activeIndex==index?'active':''}}" wx:for="{{typeLists}}" data-index="{{index}}" bind:tap="changeType">{{item}}<text class="avg" wx:if="{{activeIndex==index&&avgDefence!==''}}" wx:key="index">{{avgDefence}}分</text></view> <block wx:for="{{typeLists}}" wx:key="index">
<view class="type {{activeIndex==index?'active':''}}" data-index="{{index}}" bind:tap="changeType">{{item}}
<text class="avg" wx:if="{{activeIndex==index&&avgDefence!==''}}" >{{avgDefence}}分</text>
</view>
</block>
</view> </view>
<view class="reception-operate"> <view class="reception-operate">
<gl-image class="img share" webp src="/equity/share-icon.png" bind:tap="share" /> <gl-image class="img share" webp src="/equity/share-icon.png" bind:tap="share" />
...@@ -31,4 +35,7 @@ ...@@ -31,4 +35,7 @@
<quality id="quality" wx:if="{{activeIndex==1}}" batchId="{{record.batchId}}"></quality> <quality id="quality" wx:if="{{activeIndex==1}}" batchId="{{record.batchId}}"></quality>
<attack wx:elif="{{activeIndex==2}}" defenceResultFlag="{{record.defenceResultFlag}}" batchId="{{record.batchId}}"></attack> <attack wx:elif="{{activeIndex==2}}" defenceResultFlag="{{record.defenceResultFlag}}" batchId="{{record.batchId}}"></attack>
</block> </block>
</view>
\ No newline at end of file \ No newline at end of file
</view>
<block wx:if="{{showViolationBtn}}">
去确认
</block>
\ No newline at end of file \ No newline at end of file
...@@ -25,6 +25,7 @@ Page({ ...@@ -25,6 +25,7 @@ Page({
loaded: false, loaded: false,
track_event_code: 'staff_reception_list', //埋点动作类型 track_event_code: 'staff_reception_list', //埋点动作类型
violationStatus: 1, //默认疑似违规 violationStatus: 1, //默认疑似违规
tabIndex: 0,
recordTabList: [{ recordTabList: [{
text: '疑似违规', text: '疑似违规',
value: 1 value: 1
...@@ -45,8 +46,14 @@ Page({ ...@@ -45,8 +46,14 @@ Page({
*/ */
onLoad(options) { onLoad(options) {
if (options.hideScore) { if (options.hideScore) {
let {
recordTabList
} = this.data,
tabIndex = recordTabList.findIndex(e => e.value == options.tabValue) || 0
this.setData({ this.setData({
hideScore: true hideScore: true,
tabIndex,
violationStatus: options.tabValue
}) })
} }
let userInfo = wx.$util.getUserInfo() || {} let userInfo = wx.$util.getUserInfo() || {}
......
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
</view> </view>
<block wx:if="{{hideScore}}"> <block wx:if="{{hideScore}}">
<view class="tab-box"> <view class="tab-box">
<record-tab tabList="{{recordTabList}}" bindclick="recordTabClick"></record-tab> <record-tab tabList="{{recordTabList}}" bindclick="recordTabClick" defaultIndex="{{tabIndex}}"></record-tab>
</view> </view>
</block> </block>
<scroll-view scroll-y class="list-box" enable-back-to-top refresher-enabled="{{true}}" bindrefresherrefresh="refreshListData" bindscrolltolower="onBottomRefresh" style="height: calc(100% - var(--fontSize168));" scroll-top="{{scrollTop}}" refresher-threshold="104" refresher-triggered="{{triggered}}"> <scroll-view scroll-y class="list-box" enable-back-to-top refresher-enabled="{{true}}" bindrefresherrefresh="refreshListData" bindscrolltolower="onBottomRefresh" style="height: calc(100% - var(--fontSize168));" scroll-top="{{scrollTop}}" refresher-threshold="104" refresher-triggered="{{triggered}}">
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!