Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
glsx
/
gl_tape
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
3
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 068c7a67
authored
Aug 26, 2025
by
cen
Browse Files
Options
Browse Files
Tag
Download
Plain Diff
Merge branch 'V4.56.0' of
http://192.168.3.233:8090/glsx/gl_tape
into V4.56.0
2 parents
b8bda5ab
5f7c3ace
Show whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
193 additions
and
112 deletions
components/OrderPopup/components/CarModelList.vue
components/OrderPopup/components/CouponList.vue
components/OrderPopup/components/DiversionMerchant.vue
components/OrderPopup/components/EmployeeList.vue
components/OrderPopup/components/GoodsList.vue
components/OrderPopup/components/PackageList.vue
components/OrderPopup/components/SkuGoodsList.vue
components/OrderPopup/components/popupmixin.js
components/OrderPopup/config.js
components/OrderPopup/index.vue
components/OrderPopup/components/CarModelList.vue
View file @
068c7a6
...
@@ -58,22 +58,15 @@
...
@@ -58,22 +58,15 @@
</template>
</template>
<
script
type=
'text/ecmascript-6'
>
<
script
type=
'text/ecmascript-6'
>
import
popupmixin
from
'./popupmixin'
export
default
{
export
default
{
mixins
:
[
popupmixin
],
name
:
'CarModelList'
,
name
:
'CarModelList'
,
inject
:
[
'userInfo'
],
data
()
{
data
()
{
return
{
return
{
list
:
[],
currentId
:
''
,
searchList
:
[],
letter
:
'A'
,
letter
:
'A'
,
searchStatus
:
false
,
}
}
},
},
props
:
{
params
:
Object
,
data
:
Object
,
},
mounted
()
{
mounted
()
{
},
},
methods
:
{
methods
:
{
...
@@ -93,7 +86,7 @@ export default {
...
@@ -93,7 +86,7 @@ export default {
if
(
data
&&
data
.
length
)
{
if
(
data
&&
data
.
length
)
{
this
.
initCarList
(
data
)
this
.
initCarList
(
data
)
params
.
cacheData
=
data
params
.
cacheData
=
data
this
.
$emit
(
'update:params'
,
params
)
this
.
updateParams
(
params
)
}
}
},
},
initCarList
(
carData
)
{
initCarList
(
carData
)
{
...
...
components/OrderPopup/components/CouponList.vue
View file @
068c7a6
...
@@ -48,22 +48,15 @@
...
@@ -48,22 +48,15 @@
</template>
</template>
<
script
type=
'text/ecmascript-6'
>
<
script
type=
'text/ecmascript-6'
>
import
popupmixin
from
'./popupmixin'
export
default
{
export
default
{
mixins
:
[
popupmixin
],
name
:
'CouponList'
,
name
:
'CouponList'
,
inject
:
[
'userInfo'
],
data
()
{
data
()
{
return
{
return
{
list
:
[],
currentId
:
''
,
searchList
:
[],
searchStatus
:
false
,
customerCouponList
:
[]
customerCouponList
:
[]
}
}
},
},
props
:
{
params
:
Object
,
data
:
Object
,
},
watch
:
{
watch
:
{
'data.customer.customerPhone'
:
{
'data.customer.customerPhone'
:
{
handler
(
val
)
{
handler
(
val
)
{
...
@@ -94,7 +87,7 @@ export default {
...
@@ -94,7 +87,7 @@ export default {
if
(
data
&&
data
.
length
)
{
if
(
data
&&
data
.
length
)
{
this
.
initCouponList
(
data
)
this
.
initCouponList
(
data
)
params
.
cacheData
=
data
params
.
cacheData
=
data
this
.
$emit
(
'update:params'
,
params
)
this
.
updateParams
(
params
)
}
}
},
},
initCouponList
(
data
)
{
initCouponList
(
data
)
{
...
...
components/OrderPopup/components/DiversionMerchant.vue
View file @
068c7a6
...
@@ -14,19 +14,14 @@
...
@@ -14,19 +14,14 @@
</template>
</template>
<
script
type=
'text/ecmascript-6'
>
<
script
type=
'text/ecmascript-6'
>
import
popupmixin
from
'./popupmixin'
export
default
{
export
default
{
mixins
:
[
popupmixin
],
name
:
'DiversionMerchant'
,
name
:
'DiversionMerchant'
,
inject
:
[
'userInfo'
],
data
()
{
data
()
{
return
{
return
{
list
:
[],
currentId
:
''
}
}
},
},
props
:
{
params
:
Object
,
data
:
Object
,
},
mounted
()
{
mounted
()
{
},
},
methods
:
{
methods
:
{
...
@@ -46,7 +41,7 @@ export default {
...
@@ -46,7 +41,7 @@ export default {
this
.
$emit
(
'onComplete'
)
this
.
$emit
(
'onComplete'
)
this
.
list
=
data
this
.
list
=
data
params
.
cacheData
=
data
params
.
cacheData
=
data
this
.
$emit
(
'update:params'
,
params
)
this
.
updateParams
(
params
)
}
}
},
},
choose
(
i
)
{
choose
(
i
)
{
...
...
components/OrderPopup/components/EmployeeList.vue
View file @
068c7a6
...
@@ -14,19 +14,15 @@
...
@@ -14,19 +14,15 @@
</template>
</template>
<
script
type=
'text/ecmascript-6'
>
<
script
type=
'text/ecmascript-6'
>
import
popupmixin
from
'./popupmixin'
export
default
{
export
default
{
mixins
:
[
popupmixin
],
name
:
'EmployeeList'
,
name
:
'EmployeeList'
,
inject
:
[
'userInfo'
],
inject
:
[
'userInfo'
],
data
()
{
data
()
{
return
{
return
{
list
:
[],
currentId
:
''
}
}
},
},
props
:
{
params
:
Object
,
data
:
Object
},
mounted
()
{
mounted
()
{
},
},
methods
:
{
methods
:
{
...
@@ -49,7 +45,7 @@ export default {
...
@@ -49,7 +45,7 @@ export default {
this
.
$emit
(
'onComplete'
)
this
.
$emit
(
'onComplete'
)
this
.
list
=
data
this
.
list
=
data
params
.
cacheData
=
data
params
.
cacheData
=
data
this
.
$emit
(
'update:params'
,
params
)
this
.
updateParams
(
params
)
}
}
},
},
handleSearch
(
searchValue
)
{
handleSearch
(
searchValue
)
{
...
...
components/OrderPopup/components/GoodsList.vue
View file @
068c7a6
...
@@ -22,23 +22,14 @@
...
@@ -22,23 +22,14 @@
</template>
</template>
<
script
type=
'text/ecmascript-6'
>
<
script
type=
'text/ecmascript-6'
>
import
popupmixin
from
'./popupmixin'
export
default
{
export
default
{
mixins
:
[
popupmixin
],
name
:
'GoodsList'
,
name
:
'GoodsList'
,
inject
:
[
'userInfo'
,
'baseConfigData'
],
data
()
{
data
()
{
return
{
return
{
list
:
[],
currentIds
:
[],
chooseList
:
[],
searchStatus
:
false
,
searchList
:
[],
}
}
},
},
props
:
{
params
:
Object
,
data
:
[
Object
,
Array
],
dataKey
:
String
},
mounted
()
{
mounted
()
{
},
},
methods
:
{
methods
:
{
...
@@ -60,7 +51,7 @@ export default {
...
@@ -60,7 +51,7 @@ export default {
if
(
response
&&
response
.
length
)
{
if
(
response
&&
response
.
length
)
{
this
.
list
=
this
.
initGoodsList
(
response
)
this
.
list
=
this
.
initGoodsList
(
response
)
params
.
cacheData
=
response
params
.
cacheData
=
response
this
.
$emit
(
'update:params'
,
params
)
this
.
updateParams
(
params
)
}
}
},
},
handleSearch
(
searchValue
)
{
handleSearch
(
searchValue
)
{
...
...
components/OrderPopup/components/PackageList.vue
View file @
068c7a6
<
template
>
<
template
>
<view
class=
"goods-list"
>
<view
class=
"goods-list"
>
<!--
<template
v-if=
"list.length"
>
-->
<template
v-if=
"params.loadComplete"
>
<template
v-for=
"(item, index) in (searchStatus ? searchList : list)"
>
<template
v-if=
"listData.length"
>
<template
v-for=
"(item, index) in listData"
>
<view
<view
:key=
"index"
:key=
"index"
@
click=
"choose(item)"
@
click=
"choose(item)"
...
@@ -33,29 +34,21 @@
...
@@ -33,29 +34,21 @@
</view>
</view>
</view>
</view>
</template>
</template>
<!-- </template> -->
</template>
</template>
</view>
</view>
</template>
</template>
<
script
type=
'text/ecmascript-6'
>
<
script
type=
'text/ecmascript-6'
>
import
NP
from
'number-precision'
import
NP
from
'number-precision'
import
popupmixin
from
'./popupmixin'
export
default
{
export
default
{
mixins
:
[
popupmixin
],
name
:
'PackageList'
,
name
:
'PackageList'
,
inject
:
[
'userInfo'
,
'baseConfigData'
],
data
()
{
data
()
{
return
{
return
{
list
:
[],
currentIds
:
[],
chooseList
:
[],
searchStatus
:
false
,
searchList
:
[],
}
}
},
},
props
:
{
params
:
Object
,
data
:
[
Object
,
Array
],
dataKey
:
String
},
mounted
()
{
mounted
()
{
},
},
methods
:
{
methods
:
{
...
@@ -77,7 +70,7 @@ export default {
...
@@ -77,7 +70,7 @@ export default {
if
(
response
&&
response
.
length
)
{
if
(
response
&&
response
.
length
)
{
this
.
list
=
this
.
initGoodsList
(
response
)
this
.
list
=
this
.
initGoodsList
(
response
)
params
.
cacheData
=
response
params
.
cacheData
=
response
this
.
$emit
(
'update:params'
,
params
)
this
.
updateParams
(
params
)
}
}
},
},
handleSearch
(
searchValue
)
{
handleSearch
(
searchValue
)
{
...
...
components/OrderPopup/components/SkuGoodsList.vue
View file @
068c7a6
<
template
>
<
template
>
<view
class=
"goods-list"
>
<view
class=
"goods-list"
>
<template
v-for=
"(i, index) in (searchStatus ? searchList : list)"
>
<template
v-if=
"params.loadComplete"
>
<template
v-if=
"listData.length"
>
<template
v-for=
"(i, index) in listData"
>
<view
<view
:key=
"index"
:key=
"index"
@
click
.
stop=
"choose(i ,index)"
@
click
.
stop=
"choose(i ,index)"
...
@@ -64,14 +66,21 @@
...
@@ -64,14 +66,21 @@
<view
class=
"label"
>
<view
class=
"label"
>
{{
specific
.
specificationName
}}
{{
specific
.
specificationName
}}
</view>
</view>
<view
class=
"value
"
>
<view
class=
"value flex
"
>
<template
v-if=
"specific.value"
>
<template
v-if=
"specific.value"
>
{{
specific
.
value
}}
{{
specific
.
value
}}
</
template
>
</
template
>
<text
<text
class=
"placeholder
"
class=
"placeholder flex
"
v-else
v-else
>
请选择
</text>
>
请选择
</text>
<uni-icons
type=
"right"
size=
"14"
class=
"arrow"
/>
</view>
</view>
</view>
</view>
</picker>
</picker>
...
@@ -81,28 +90,21 @@
...
@@ -81,28 +90,21 @@
</template>
</template>
</view>
</view>
</template>
</template>
</template>
</template>
</view>
</view>
</template>
</template>
<
script
type=
'text/ecmascript-6'
>
<
script
type=
'text/ecmascript-6'
>
import
popupmixin
from
'./popupmixin'
export
default
{
export
default
{
mixins
:
[
popupmixin
],
name
:
'SkuGoodsList'
,
name
:
'SkuGoodsList'
,
inject
:
[
'userInfo'
,
'baseConfigData'
],
data
()
{
data
()
{
return
{
return
{
list
:
[],
currentIds
:
[],
chooseList
:
[],
searchStatus
:
false
,
searchList
:
[],
}
}
},
},
props
:
{
params
:
Object
,
data
:
[
Object
,
Array
],
dataKey
:
String
},
mounted
()
{
mounted
()
{
},
},
methods
:
{
methods
:
{
...
@@ -124,7 +126,7 @@ export default {
...
@@ -124,7 +126,7 @@ export default {
if
(
response
&&
response
.
length
)
{
if
(
response
&&
response
.
length
)
{
this
.
list
=
this
.
initGoodsList
(
response
)
this
.
list
=
this
.
initGoodsList
(
response
)
params
.
cacheData
=
response
params
.
cacheData
=
response
this
.
$emit
(
'update:params'
,
params
)
this
.
updateParams
(
params
)
}
}
},
},
handleSearch
(
searchValue
)
{
handleSearch
(
searchValue
)
{
...
@@ -135,7 +137,12 @@ export default {
...
@@ -135,7 +137,12 @@ export default {
arr
=
[]
arr
=
[]
goodsList
.
map
(
c
=>
{
goodsList
.
map
(
c
=>
{
let
name
=
''
let
name
=
''
if
(
c
.
goodsFlag
==
3
&&
c
.
packageGoods
)
name
=
c
.
packageGoods
.
packageName
||
c
.
packageGoods
.
packageAlias
if
(
c
.
goodsFlag
==
1
&&
c
.
goods
)
{
name
=
c
.
goods
.
goodsAlias
||
c
.
goods
.
upgradeGoodsName
||
c
.
goods
.
goodsName
||
''
}
if
(
c
.
goodsFlag
==
2
&&
c
.
multipleSpecificationsGoods
)
{
name
=
c
.
multipleSpecificationsGoods
.
baseGoodsName
}
if
(
name
.
indexOf
(
searchValue
)
!=
-
1
)
{
if
(
name
.
indexOf
(
searchValue
)
!=
-
1
)
{
arr
.
push
(
c
)
arr
.
push
(
c
)
}
}
...
@@ -462,6 +469,9 @@ export default {
...
@@ -462,6 +469,9 @@ export default {
margin-left
:
auto
;
margin-left
:
auto
;
max-width
:
50%
;
max-width
:
50%
;
flex-shrink
:
0
;
flex-shrink
:
0
;
.arrow
{
margin-left
:
4
rpx
;
}
}
}
&
:last-of-type
{
&
:last-of-type
{
border
:
none
;
border
:
none
;
...
...
components/OrderPopup/components/popupmixin.js
0 → 100644
View file @
068c7a6
export
default
{
inject
:
[
'userInfo'
,
'baseConfigData'
],
data
()
{
return
{
list
:
[],
searchStatus
:
false
,
searchList
:
[],
chooseList
:
[],
currentId
:
''
,
currentIds
:
[],
}
},
props
:
{
params
:
Object
,
data
:
[
Object
,
Array
],
dataKey
:
String
},
computed
:
{
listData
()
{
return
this
.
searchStatus
?
this
.
searchList
:
this
.
list
},
noData
()
{
return
!
this
.
listData
.
length
}
},
watch
:
{
noData
:
{
handler
(
val
)
{
let
{
params
}
=
this
params
.
noData
=
val
this
.
updateParams
(
params
)
},
deep
:
true
}
},
methods
:
{
updateParams
(
params
)
{
this
.
$emit
(
'update:params'
,
params
)
}
}
}
\ No newline at end of file
\ No newline at end of file
components/OrderPopup/config.js
View file @
068c7a6
...
@@ -21,39 +21,61 @@ const componentConfig = {
...
@@ -21,39 +21,61 @@ const componentConfig = {
name
:
'EmployeeList'
,
name
:
'EmployeeList'
,
title
:
'销售顾问/录单员'
,
title
:
'销售顾问/录单员'
,
placeholder
:
'请输入姓名'
,
placeholder
:
'请输入姓名'
,
idKey
:
'userId'
idKey
:
'userId'
,
cacheData
:
[],
loadComplete
:
false
,
searchValue
:
''
,
noData
:
false
},
},
1
:
{
1
:
{
name
:
'EmployeeList'
,
name
:
'EmployeeList'
,
title
:
'交付专员'
,
title
:
'交付专员'
,
placeholder
:
'请输入姓名'
,
placeholder
:
'请输入姓名'
,
nullTips
:
'请选择交付专员'
,
nullTips
:
'请选择交付专员'
,
idKey
:
'deliveryUserId'
idKey
:
'deliveryUserId'
,
cacheData
:
[],
loadComplete
:
false
,
searchValue
:
''
,
noData
:
false
},
},
2
:
{
2
:
{
name
:
'DiversionMerchant'
,
name
:
'DiversionMerchant'
,
title
:
'二级流量方'
,
title
:
'二级流量方'
,
hideSearch
:
true
,
hideSearch
:
true
,
idKey
:
'subShopMerchantId'
idKey
:
'subShopMerchantId'
,
cacheData
:
[],
loadComplete
:
false
},
},
3
:
{
3
:
{
name
:
'EmployeeList'
,
name
:
'EmployeeList'
,
title
:
'转化人员'
,
title
:
'转化人员'
,
placeholder
:
'请输入姓名'
,
placeholder
:
'请输入姓名'
,
idKey
:
'sellerUserId'
,
idKey
:
'sellerUserId'
,
cacheData
:
[],
loadComplete
:
false
,
searchValue
:
''
,
noData
:
false
},
},
4
:
{
4
:
{
name
:
'CarModelList'
,
name
:
'CarModelList'
,
title
:
'选择车型'
,
title
:
'选择车型'
,
placeholder
:
'查找'
,
placeholder
:
'查找'
,
idKey
:
'carSeriesId'
idKey
:
'carSeriesId'
,
cacheData
:
[],
loadComplete
:
false
,
searchValue
:
''
,
noData
:
false
},
},
5
:
{
5
:
{
name
:
'CouponList'
,
name
:
'CouponList'
,
title
:
'选择礼券'
,
title
:
'选择礼券'
,
placeholder
:
'查找'
,
placeholder
:
'查找'
,
idKey
:
'customerCouponCode'
,
idKey
:
'customerCouponCode'
,
nullTips
:
'优惠券不能为空'
nullTips
:
'优惠券不能为空'
,
cacheData
:
[],
loadComplete
:
false
,
searchValue
:
''
,
noData
:
false
},
},
6
:
{
6
:
{
name
:
'GoodsList'
,
name
:
'GoodsList'
,
...
@@ -61,7 +83,11 @@ const componentConfig = {
...
@@ -61,7 +83,11 @@ const componentConfig = {
placeholder
:
'请输入名称'
,
placeholder
:
'请输入名称'
,
idKey
:
'goodsId'
,
idKey
:
'goodsId'
,
nullTips
:
'请勾选商品'
,
nullTips
:
'请勾选商品'
,
goodsType
:
[
1
]
//前档
goodsType
:
[
1
],
//前档
cacheData
:
[],
loadComplete
:
false
,
searchValue
:
''
,
noData
:
false
},
},
7
:
{
7
:
{
name
:
'GoodsList'
,
name
:
'GoodsList'
,
...
@@ -69,7 +95,11 @@ const componentConfig = {
...
@@ -69,7 +95,11 @@ const componentConfig = {
placeholder
:
'请输入名称'
,
placeholder
:
'请输入名称'
,
idKey
:
'goodsId'
,
idKey
:
'goodsId'
,
nullTips
:
'请勾选商品'
,
nullTips
:
'请勾选商品'
,
goodsType
:
[
2
]
// 前侧窗玻璃
goodsType
:
[
2
],
// 前侧窗玻璃
cacheData
:
[],
loadComplete
:
false
,
searchValue
:
''
,
noData
:
false
},
},
8
:
{
8
:
{
name
:
'GoodsList'
,
name
:
'GoodsList'
,
...
@@ -77,7 +107,11 @@ const componentConfig = {
...
@@ -77,7 +107,11 @@ const componentConfig = {
placeholder
:
'请输入名称'
,
placeholder
:
'请输入名称'
,
idKey
:
'goodsId'
,
idKey
:
'goodsId'
,
nullTips
:
'请勾选商品'
,
nullTips
:
'请勾选商品'
,
goodsType
:
[
3
]
// 后侧窗玻璃
goodsType
:
[
3
],
// 后侧窗玻璃
cacheData
:
[],
loadComplete
:
false
,
searchValue
:
''
,
noData
:
false
},
},
9
:
{
9
:
{
name
:
'GoodsList'
,
name
:
'GoodsList'
,
...
@@ -85,7 +119,11 @@ const componentConfig = {
...
@@ -85,7 +119,11 @@ const componentConfig = {
placeholder
:
'请输入名称'
,
placeholder
:
'请输入名称'
,
idKey
:
'goodsId'
,
idKey
:
'goodsId'
,
nullTips
:
'请勾选商品'
,
nullTips
:
'请勾选商品'
,
goodsType
:
[
4
]
// 后档
goodsType
:
[
4
],
// 后档
cacheData
:
[],
loadComplete
:
false
,
searchValue
:
''
,
noData
:
false
},
},
10
:
{
10
:
{
name
:
'GoodsList'
,
name
:
'GoodsList'
,
...
@@ -93,26 +131,38 @@ const componentConfig = {
...
@@ -93,26 +131,38 @@ const componentConfig = {
placeholder
:
'请输入名称'
,
placeholder
:
'请输入名称'
,
idKey
:
'goodsId'
,
idKey
:
'goodsId'
,
nullTips
:
'请勾选商品'
,
nullTips
:
'请勾选商品'
,
goodsType
:
[
5
,
6
,
7
]
// 天窗
goodsType
:
[
5
,
6
,
7
],
// 天窗
cacheData
:
[],
loadComplete
:
false
,
searchValue
:
''
,
noData
:
false
},
},
11
:
{
11
:
{
name
:
'PackageList'
,
name
:
'PackageList'
,
title
:
'选择套餐'
,
title
:
'选择套餐'
,
placeholder
:
'查找'
,
placeholder
:
'查找'
,
nullTips
:
'请勾选套餐'
,
nullTips
:
'请勾选套餐'
,
idKey
:
'packageCode'
idKey
:
'packageCode'
,
cacheData
:
[],
loadComplete
:
false
,
searchValue
:
''
,
noData
:
false
},
},
12
:
{
12
:
{
name
:
'SkuGoodsList'
,
name
:
'SkuGoodsList'
,
title
:
'选择商品'
,
title
:
'选择商品'
,
nullTips
:
'请勾选商品'
,
nullTips
:
'请勾选商品'
,
placeholder
:
'查找'
,
placeholder
:
'查找'
,
cacheData
:
[],
loadComplete
:
false
,
searchValue
:
''
,
noData
:
false
},
},
13
:
{
13
:
{
name
:
'DateTime'
,
name
:
'DateTime'
,
title
:
'选择时间'
,
title
:
'选择时间'
,
hideSearch
:
true
,
hideSearch
:
true
,
loadComplete
:
false
}
}
}
}
export
default
{
componentConfig
}
export
default
{
componentConfig
}
\ No newline at end of file
\ No newline at end of file
components/OrderPopup/index.vue
View file @
068c7a6
...
@@ -19,14 +19,14 @@
...
@@ -19,14 +19,14 @@
></uni-icons>
></uni-icons>
</view>
</view>
</view>
</view>
<template
v-if=
"!componentObject.hideSearch"
>
<template
v-if=
"!componentObject
[popupType]
.hideSearch"
>
<view
class=
"popup-search"
>
<view
class=
"popup-search"
>
<input
<input
class=
"input"
class=
"input"
type=
"text"
type=
"text"
:placeholder=
"componentObject.placeholder || '请输入'"
:placeholder=
"componentObject
[popupType]
.placeholder || '请输入'"
placeholder-class=
"placeholder"
placeholder-class=
"placeholder"
v-model=
"componentObject.searchValue"
v-model=
"componentObject
[popupType]
.searchValue"
confirm-type=
"search"
confirm-type=
"search"
@
confirm=
"handleSearch"
@
confirm=
"handleSearch"
>
>
...
@@ -37,29 +37,33 @@
...
@@ -37,29 +37,33 @@
<uni-icons
<uni-icons
type=
"closeempty"
type=
"closeempty"
size=
"16"
size=
"16"
v-if=
"componentObject.searchValue"
v-if=
"componentObject
[popupType]
.searchValue"
></uni-icons>
></uni-icons>
</view>
</view>
</view>
</view>
</
template
>
</
template
>
<view
:class=
"['popup-body',{ 'hide-search' :componentObject.hideSearch}]"
>
<view
:class=
"['popup-body',{ 'hide-search' :componentObject
[popupType]
.hideSearch}]"
>
<scroll-view
<scroll-view
scroll-y
scroll-y
:class=
"['popup-scroll-view',{show:loadComplete}]"
:class=
"['popup-scroll-view',{show:
componentObject[popupType].
loadComplete}]"
>
>
<component
<component
:is=
"componentObject.name"
:is=
"componentObject
[popupType]
.name"
:params
.
sync=
"componentObject"
:params
.
sync=
"componentObject
[popupType]
"
:data=
"data"
:data=
"data"
:dataKey=
"dataKey"
:dataKey=
"dataKey"
ref=
"componentRef"
ref=
"componentRef"
@
choose=
"chooseContent = $event"
@
choose=
"chooseContent = $event"
@
openSkuPopup=
"openSkuPopup"
@
openSkuPopup=
"openSkuPopup"
@
onComplete=
"loadComplete = true"
@
onComplete=
"componentObject[popupType].loadComplete = true"
@
updateCacheData=
"updateCacheData"
></component>
></component>
<
template
v-if=
"componentObject[popupType].noData"
>
<view
class=
"nothing flex"
>
暂无数据
</view>
</
template
>
</scroll-view>
</scroll-view>
<image
<image
v-if=
"!loadComplete"
v-if=
"!
componentObject[popupType].
loadComplete"
class=
"loading"
class=
"loading"
src=
"../../assets/images/common/loadding.gif"
src=
"../../assets/images/common/loadding.gif"
/>
/>
...
@@ -127,14 +131,12 @@ export default {
...
@@ -127,14 +131,12 @@ export default {
return
{
return
{
position
:
'bottom'
,
position
:
'bottom'
,
chooseContent
:
null
,
chooseContent
:
null
,
componentObject
:
null
,
componentObject
:
config
.
componentConfig
,
loadComplete
:
false
}
}
},
},
watch
:
{
watch
:
{
popupType
:
{
popupType
:
{
handler
(
val
)
{
handler
(
val
)
{
this
.
componentObject
=
config
.
componentConfig
[
this
.
popupType
]
if
(
val
==
11
||
val
==
12
)
this
.
position
=
'right'
if
(
val
==
11
||
val
==
12
)
this
.
position
=
'right'
else
this
.
position
=
'bottom'
else
this
.
position
=
'bottom'
},
},
...
@@ -143,9 +145,15 @@ export default {
...
@@ -143,9 +145,15 @@ export default {
},
},
externalData
:
{
externalData
:
{
handler
(
val
)
{
handler
(
val
)
{
if
(
val
&&
this
.
componentObject
)
this
.
componentObject
.
cacheData
=
val
if
(
val
)
{
}
if
(
val
&&
val
.
length
&&
this
.
componentObject
[
this
.
popupType
])
{
this
.
componentObject
[
this
.
popupType
].
cacheData
=
val
}
},
},
deep
:
true
,
deep
:
true
,
immediate
:
true
}
}
},
},
computed
:
{
computed
:
{
...
@@ -170,6 +178,7 @@ export default {
...
@@ -170,6 +178,7 @@ export default {
this
.
initPopupData
()
this
.
initPopupData
()
},
},
cancel
()
{
cancel
()
{
console
.
log
()
this
.
$refs
.
popup
.
close
()
this
.
$refs
.
popup
.
close
()
this
.
$emit
(
'cancel'
)
this
.
$emit
(
'cancel'
)
},
},
...
@@ -180,7 +189,7 @@ export default {
...
@@ -180,7 +189,7 @@ export default {
initPopupData
()
{
initPopupData
()
{
let
componentRef
=
this
.
componentRef
()
let
componentRef
=
this
.
componentRef
()
if
(
!
componentRef
)
setTimeout
(
this
.
initPopupData
,
.
1
e3
)
if
(
!
componentRef
)
setTimeout
(
this
.
initPopupData
,
.
1
e3
)
else
componentRef
.
getList
&&
componentRef
.
getList
(
this
.
componentObject
.
searchValue
)
else
componentRef
.
getList
&&
componentRef
.
getList
(
this
.
componentObject
[
this
.
popupType
]
.
searchValue
)
},
},
handleSearch
()
{
handleSearch
()
{
let
componentRef
=
this
.
componentRef
()
let
componentRef
=
this
.
componentRef
()
...
@@ -188,7 +197,7 @@ export default {
...
@@ -188,7 +197,7 @@ export default {
title
:
'请稍后再试'
,
title
:
'请稍后再试'
,
icon
:
'none'
icon
:
'none'
})
})
else
componentRef
.
handleSearch
(
this
.
componentObject
.
searchValue
)
else
componentRef
.
handleSearch
(
this
.
componentObject
[
this
.
popupType
]
.
searchValue
)
},
},
confirm
()
{
confirm
()
{
try
{
try
{
...
@@ -197,14 +206,14 @@ export default {
...
@@ -197,14 +206,14 @@ export default {
chooseContent
=
this
.
componentRef
().
getResult
()
chooseContent
=
this
.
componentRef
().
getResult
()
}
}
if
(
chooseContent
)
{
if
(
chooseContent
)
{
if
(
Array
.
isArray
(
chooseContent
)
&&
!
chooseContent
.
length
&&
componentObject
.
nullTips
)
throw
componentObject
.
nullTips
if
(
Array
.
isArray
(
chooseContent
)
&&
!
chooseContent
.
length
&&
componentObject
[
popupType
]
.
nullTips
)
throw
componentObject
.
nullTips
this
.
$emit
(
'onConfirm'
,
{
this
.
$emit
(
'onConfirm'
,
{
chooseContent
,
chooseContent
,
popupType
popupType
})
})
this
.
$refs
.
popup
.
close
()
this
.
$refs
.
popup
.
close
()
}
else
{
}
else
{
if
(
componentObject
.
nullTips
)
throw
componentObject
.
nullTips
if
(
componentObject
[
popupType
].
nullTips
)
throw
componentObject
[
popupType
]
.
nullTips
}
}
}
catch
(
error
)
{
}
catch
(
error
)
{
uni
.
showToast
({
uni
.
showToast
({
...
@@ -224,9 +233,9 @@ export default {
...
@@ -224,9 +233,9 @@ export default {
})
})
},
},
clear
()
{
clear
()
{
this
.
componentObject
.
searchValue
=
''
this
.
componentObject
[
this
.
popupType
]
.
searchValue
=
''
this
.
handleSearch
()
this
.
handleSearch
()
}
}
,
}
}
}
}
</
script
>
</
script
>
...
@@ -335,6 +344,15 @@ export default {
...
@@ -335,6 +344,15 @@ export default {
background
:
linear-gradient
(
0deg
,
#2c66f7
0%
,
#48a6ff
100%
);
background
:
linear-gradient
(
0deg
,
#2c66f7
0%
,
#48a6ff
100%
);
}
}
}
}
.nothing
{
position
:
absolute
;
top
:
0
;
left
:
0
;
width
:
100%
;
height
:
100%
;
z-index
:
2
;
justify-content
:
center
;
}
}
}
.right-box
{
.right-box
{
width
:
46vw
;
width
:
46vw
;
...
...
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment