Commit 0235bd4a by chenwq

点击事件,添加搜索条件

1 parent 481a4da4
......@@ -110,7 +110,6 @@ Page({
},
setCurActivity() {
// console.log('setCurActivity---')
this.setData({
activityList: JSON.parse(JSON.stringify(this.data.sceneActivityObj['scene' + this.findSceneIdx()])),
// productStatus:0未申请;1申请中;2已开通;3:已结束
......@@ -138,7 +137,6 @@ Page({
},
handleJump(e) {
// console.log(this.data.activityList[this.data.activityActive])
var params = {
merchantInfo: this.data.merchantInfo,
sceneCodeActive: this.data.sceneCodeActive,
......@@ -212,10 +210,6 @@ Page({
sceneData: res,
sceneInfo: this.data.sceneInfo,
sceneActivityObj: sceneActivityObj
// ['sceneActivityObj.scene0']: data[0].productList,
// ['sceneActivityObj.scene1']: data[1].productList,
// ['sceneActivityObj.scene2']: data[2].productList,
// ['sceneActivityObj.scene3']: data[3].productList
})
// 首次进入,默认定位至SC004场景;需要调获取SC002和SC003场景的接口,以计算这两个场景的总额
if (isFirst) {
......@@ -230,7 +224,6 @@ Page({
this.getActivityRevenue(isFirst)
}
}
// console.log(this.data.sceneCodeActive == defaultSceneCode)
if (['SC002', 'SC003'].includes(this.data.sceneCodeActive)) {
this.getCustomerDetail()
} else if (this.data.sceneCodeActive == 'SC001') {
......@@ -408,7 +401,6 @@ Page({
}
var mockActivityList = this.data.mockObj?.crowdObj[obj.pIdx].merchantList[obj.idx].activityList
var actIds = mockActivityList.map(item => item.activityId)
// console.log(mockActivityList, 'mockActivityList')
data.activityList.forEach(item => {
let idx = actIds.findIndex(k => k == item.activityId)
if (idx != -1) {
......@@ -421,13 +413,11 @@ Page({
/** 查询场景4的产值 */
getActivityRevenue(isFirst = false) {
console.log(this.data.isMock, 'SC004--mock---')
wx.showLoading()
var params = this.dealSearchStatus()
outputApi
.getActivityRevenue({ merchantId: this.data.merchantInfo.merchantId, ...params })
.then(res => {
// console.log(this.data.sceneActivityObj, '++++++')
var actList = this.data.sceneActivityObj['scene' + (isFirst ? this.findSceneIdx('SC004') : this.findSceneIdx())]
var total = 0
res.forEach(item => {
......@@ -562,7 +552,6 @@ Page({
},
/**长按海报 */
async longtouch(e) {
// console.log('长按海报', e)
let { activityId } = e.detail
const res = await outputApi.reportPosterTrack({
activityId
......@@ -621,7 +610,6 @@ Page({
let pList = this.data.mockObj.crowdObj.map(item => item.pMerchantId)
for (let i = 0; i < this.data.mockObj.crowdObj.length; i++) {
let item = this.data.mockObj.crowdObj[i]
console.log(item, 'item---')
let cList = item.merchantList.map(k => k.merhantId)
if (cList.includes((id || this.data.merchantInfo.merchantId) + '') && pList.includes((pId || this.data.merchantInfo.pMerchantId) + '')) {
res = {
......@@ -638,15 +626,12 @@ Page({
// 判断是否Mock数据写死
judgeAccount() {
console.log(this.data.merchantInfo, 'this.data.merchantInfo')
console.log(this.data.mockObj, 'this.data.mockObj')
// 精品升级-SC002
// 售后众筹-SC004
this.setData({
['isMock.SC002']: this.judgeUpgrade().flag,
['isMock.SC004']: this.judgeCrowd().flag
})
console.log(this.data.isMock, 'isMock---')
},
async getMockInfo(userInfo) {
......@@ -655,7 +640,6 @@ Page({
mockObj: res,
isShowService: res.serviceMerchatList.includes(userInfo.merchantId + '')
})
console.log(this.data.isShowService, 'isShowService------')
},
// 二维码自动登录
......@@ -687,7 +671,8 @@ Page({
})
if(obj.fixSceneCode) {
this.setData({
sceneCodeActive: obj.fixSceneCode
sceneCodeActive: obj.fixSceneCode,
fixScenceCode: obj.fixSceneCode
})
}
......
// pages/tab/output/components/StaffSort/StaffSort.js
import { scenceList } from '~/pages/tab/index/constant/data'
const busiOptSceneCode = ['-1', 'SC001', 'SC002']
const busiOptSceneCode = ['-1', 'SC001', 'SC002', 'SC003']
import mineApi from '~/api/mineApi/index'
import { getNowMonth } from '~/utils/format'
import { IMG_URL } from '~/utils/constantData'
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!