Commit c7d19ad2 by zhangxw

接口对接

1 parent 24ebd916
......@@ -205,7 +205,6 @@ Component({
let { userInfo, formData, staffList, sceneList } = this.data
formData.sceneType = sceneList.filter(val => val.active)[0]?.id || ''
formData.staffUUIDs = staffList.filter(val => val.active).map(subVal => {if (subVal.uuid) return subVal.uuid})
formData.shopMerchantIds =
this.triggerEvent('screenFlag')
const thisPage = wx.$router.getPageInstance()
if (formData?.partnerMerchantIds[0] !== userInfo.subLoginUser.merchantId) {
......
......@@ -21,6 +21,7 @@ Component({
type: Boolean,
value: false
},
tabBoxStyle: String,
index: {
type: Number,
observer: function (n) {
......
<wxs src="./Tab.wxs" module="filterUtils" />
<block>
<scroll-view class="tab-box flex" scroll-x enable-flex scroll-with-animation scroll-into-view="{{to}}" enhanced="{{true}}" show-scrollbar="{{false}}" style="{{tabHeight ? 'height: 88rpx;' : ''}}">
<scroll-view class="tab-box flex" scroll-x enable-flex scroll-with-animation scroll-into-view="{{to}}" enhanced="{{true}}" show-scrollbar="{{false}}" style="{{tabBoxStyle}}">
<block wx:for="{{tab}}" wx:key="index">
<view class="tab {{index==count?'active':''}}" style="width:{{itemWidth}}; margin-left: 32rpx" bindtap="click" data-count="{{index}}">
<view class="text text-center" style="{{tabHeight ? 'height: 88rpx;' : ''}}">{{item}}</view>
<view class="text text-center" style="{{tabBoxStyle}}">{{item}}</view>
<view wx:if="{{!noLine}}" class="line" style="{{tabHeight ? 'margin-top: 6rpx;' : ''}}" />
</view>
</block>
......
......@@ -14,6 +14,7 @@ Component({
observer: function (n) {
if (n) {
let { merchantRange, selectInfo } = this.data
console.log(selectInfo)
let activeIndex = merchantRange.findIndex(v => v.merchantId == selectInfo.shopMerchantIds[0])
if (merchantRange.length) merchantRange.unshift({merchantId: '', merchantName: '全部'})
merchantRange.forEach((item, ind) => {
......
......@@ -31,7 +31,8 @@ Page({
sceneType: '',
staffUUIDs: []
},
isShowFilterScreen: false
isShowFilterScreen: false,
tabBoxStyle: ''
},
back() {
this.setData({
......@@ -52,7 +53,8 @@ Page({
navbarReady(e) {
let { height, statusBarHeight } = e.detail
this.setData({
tabBarStyle: height / 2 + statusBarHeight
tabBarStyle: height / 2 + statusBarHeight,
tabBoxStyle: `height: ${height}rpx`
})
},
changeTabIndx(e) {
......
<!-- pages/tab/output/output.wxml -->
<navigation-bar navStyle="{{isShowFilterScreen ? 'background: #fff;' : navStyle}}" bindnavbarReady="navbarReady" navBarBoxStyle="{{!isShowFilterScreen ? navBarBoxStyle : 'justify-content: center;align-items: center'}}" navTitleStyle="{{navTitleStyle}}">
<block>
<tab wx:if="{{!isShowFilterScreen}}" noLine="{{true}}" tab="{{tabList}}" itemWidth="{{'136rpx'}}" index="{{tabIndx}}" tabHeight unreadClueCount="{{unreadClueCount}}" bindclick="changeTabIndx" class="tabContainer" />
<tab wx:if="{{!isShowFilterScreen}}" noLine="{{true}}" tab="{{tabList}}" itemWidth="{{'136rpx'}}" tabBoxStyle="{{tabBoxStyle}}" index="{{tabIndx}}" unreadClueCount="{{unreadClueCount}}" bindclick="changeTabIndx" class="tabContainer" />
<view class="screen_box">
<screen-box id="screenBox" formData="{{screenFormData}}" tabType="{{tabIndx}}" tabBarStyle="{{tabBarStyle}}" isShowFilterScreen="{{isShowFilterScreen}}" bindconfirm="screenConfirm"></screen-box>
</view>
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!