Commit 2ca552ba by 李伟康

fix(OrderPopup): 优化员工列表搜索功能

- 修改 getList 方法,增加 search 参数来区分是否是搜索操作
- 更新 handleSearch 方法,传入 true 表示是搜索操作
- 在 popupType 变化时重置 searchValue
- 优化员工列表数据更新逻辑
1 parent 40c7b32e
<template> <template>
<!-- @start="$refs.customerTypeRef.open()" -->
<home-frame <home-frame
@preview="preview" @preview="preview"
@start="$refs.customerTypeRef.open()" @start="$refs.test.open()"
ref="home" ref="home"
:id="id" :id="id"
@openStep="openStep" @openStep="openStep"
...@@ -37,6 +38,12 @@ ...@@ -37,6 +38,12 @@
@choose="chooseCustomerType" @choose="chooseCustomerType"
title="请选择当前洽谈的客户类型" title="请选择当前洽谈的客户类型"
/> />
<order-popup
ref="test"
:data="data"
@onConfirm="data.customer.carSeriesId = $event.carSeriesId"
popupType="0"
/>
</template> </template>
</home-frame> </home-frame>
</template> </template>
...@@ -69,11 +76,19 @@ const defaultConfig = [ ...@@ -69,11 +76,19 @@ const defaultConfig = [
tabId: 3 tabId: 3
} }
] ]
import OrderPopup from '@/components/OrderPopup/index.vue'
export default { export default {
components: { HomeFrame, detail, CenterPopup }, components: { HomeFrame, detail, CenterPopup, OrderPopup },
name: 'boutique', name: 'boutique',
data () { data () {
return { return {
data: {
customer: {
carSeriesId: 1145120
},
userId: '1caea5b0a50b433bacf5be533af6a4e3',
sellerUserId: '9ec5c68f73e84357a427da9503a5ee8b'
},
moduleList: [], moduleList: [],
toolList: [], toolList: [],
chooseItem: {}, chooseItem: {},
...@@ -101,7 +116,7 @@ export default { ...@@ -101,7 +116,7 @@ export default {
icon: 'icon-customer-2' icon: 'icon-customer-2'
} }
]), ]),
loadComplete:false loadComplete: false
} }
}, },
onBackPress (options) { onBackPress (options) {
......
...@@ -46,10 +46,11 @@ class Track { ...@@ -46,10 +46,11 @@ class Track {
async sendTrackData () { async sendTrackData () {
const recordList = uni.getStorageSync('TRACK_LIST') || [] const recordList = uni.getStorageSync('TRACK_LIST') || []
if (recordList.length) { // if (recordList.length) {
const res = await uni.$api.commonApi.recordInsert({ recordList }) // const res = await uni.$api.commonApi.recordInsert({ recordList })
if (res) uni.setStorageSync('TRACK_LIST', []) // if (res)
} uni.setStorageSync('TRACK_LIST', [])
// }
} }
} }
......
...@@ -4,19 +4,20 @@ import { getTime, withinSpliter, daysBetween } from './util' ...@@ -4,19 +4,20 @@ import { getTime, withinSpliter, daysBetween } from './util'
class LocalLog { class LocalLog {
logger = null logger = null
constructor() { constructor() {
this.logger = new LogCat() this.logger = {}
// this.logger = new LogCat()
} }
debug(msg) { debug(msg) {
this.logger.writeLog(LogLevel.DEBUG, msg) // this.logger.writeLog(LogLevel.DEBUG, msg)
} }
info(msg) { info(msg) {
this.logger.writeLog(LogLevel.INFO, msg) // this.logger.writeLog(LogLevel.INFO, msg)
} }
warn(msg) { warn(msg) {
this.logger.writeLog(LogLevel.WARN, msg) // this.logger.writeLog(LogLevel.WARN, msg)
} }
error(msg) { error(msg) {
this.logger.writeLog(LogLevel.ERROR, msg) // this.logger.writeLog(LogLevel.ERROR, msg)
} }
getFiles(beginDate, endDate) { getFiles(beginDate, endDate) {
const logFiles = this.logger.getLogFileList() const logFiles = this.logger.getLogFileList()
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!