Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas
/
scrm-micro-activity-center
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 9eef2941
authored
Feb 06, 2023
by
李伟康
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
修改众筹活动
1 parent
40bd88e8
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
158 additions
and
55 deletions
src/components/selectSingleProDialog/index.vue
src/views/orderManage/index.vue
src/views/seckillActivity/crowdFundList.vue
src/views/seckillActivity/editCrowdFund.vue
src/components/selectSingleProDialog/index.vue
View file @
9eef294
<!-- 选择商品 - 单选 -->
<
template
>
<!-- :okText="productList.length ? '确定' : '创建商品'" -->
<GLDialog
class=
"single-pro"
bigTitle=
"选择商品"
mode=
"big"
:before-close=
"handleSingleSelectClose"
:okText=
"'确定'"
:visible
.
sync=
"isSingleSelectVisible"
@
onOk=
"handleSingleSelectConfirm"
@
onCancel=
"handleSingleSelectClose"
>
<GLDialog
class=
"single-pro"
bigTitle=
"选择商品"
mode=
"big"
:before-close=
"handleSingleSelectClose"
:okText=
"'确定'"
:visible
.
sync=
"isSingleSelectVisible"
@
onOk=
"handleSingleSelectConfirm"
@
onCancel=
"handleSingleSelectClose"
>
<div
style=
"max-height:60vh"
>
<div
class=
"noproDiv"
v-if=
"!productList.length && fnCallBack"
>
<div
class=
"noproDiv"
v-if=
"!productList.length && fnCallBack"
>
<img
src=
"@/assets/noPro.png"
/>
<p
class=
"noproP"
>
系统暂无已创建的商品
</p>
</div>
<el-radio-group
v-model=
"infoId"
v-if=
"productList.length"
class=
"pro-group"
>
<el-radio
:class=
"['pro-box', item.id == infoId ? 'active' : '']"
v-for=
"item in productList"
:key=
"item.id"
:label=
"item.id"
>
<img
v-show=
"item.id == infoId"
class=
"icon-check"
src=
"@/assets/icon-check.png"
/>
<img
class=
"goods-img"
:src=
"item.goodsImage"
/>
<div
class=
"txt-box"
>
<p
:title=
"item.goodsName"
class=
"ellipsis"
>
{{
item
.
goodsName
}}
</p>
<p
class=
"f-s-12"
>
销量:
{{
item
.
saleAmount
}}
</p>
<p
class=
"f-s-12"
>
库存:
{{
item
.
goodsStock
}}
</p>
<p
class=
"f-s-12"
>
零售价:
{{
item
.
retailPrice
}}
</p>
<p
:title=
"item.merchantName"
class=
"ellipsis f-s-12"
>
门店名称:
{{
item
.
merchantName
}}
</p>
</div>
</el-radio>
</el-radio-group>
<template
v-if=
"multiple"
>
<el-checkbox-group
v-model=
"infoIdList"
v-if=
"productList.length"
class=
"pro-group"
:max=
"multipleMax"
>
<el-checkbox
:class=
"['pro-box', infoIdList.includes(item.id) ? 'active' : '']"
v-for=
"item in productList"
:key=
"item.id"
:label=
"item.id"
>
<div
class=
"icon-number icon-check"
v-show=
"infoIdList.includes(item.id)"
>
{{
infoIdList
.
findIndex
(
e
=>
item
.
id
==
e
)
+
1
}}
</div>
<img
class=
"goods-img"
:src=
"item.goodsImage"
/>
<div
class=
"txt-box"
>
<p
:title=
"item.goodsName"
class=
"ellipsis"
>
{{
item
.
goodsName
}}
</p>
<p
class=
"f-s-12"
>
销量:
{{
item
.
saleAmount
}}
</p>
<p
class=
"f-s-12"
>
库存:
{{
item
.
goodsStock
}}
</p>
<p
class=
"f-s-12"
>
零售价:
{{
item
.
retailPrice
}}
</p>
<p
:title=
"item.merchantName"
class=
"ellipsis f-s-12"
>
门店名称:
{{
item
.
merchantName
}}
</p>
</div>
</el-checkbox>
</el-checkbox-group>
</
template
>
<
template
v-else
>
<el-radio-group
v-model=
"infoId"
v-if=
"productList.length"
class=
"pro-group"
>
<el-radio
:class=
"['pro-box', item.id == infoId ? 'active' : '']"
v-for=
"item in productList"
:key=
"item.id"
:label=
"item.id"
>
<img
v-show=
"item.id == infoId"
class=
"icon-check"
src=
"@/assets/icon-check.png"
/>
<img
class=
"goods-img"
:src=
"item.goodsImage"
/>
<div
class=
"txt-box"
>
<p
:title=
"item.goodsName"
class=
"ellipsis"
>
{{
item
.
goodsName
}}
</p>
<p
class=
"f-s-12"
>
销量:
{{
item
.
saleAmount
}}
</p>
<p
class=
"f-s-12"
>
库存:
{{
item
.
goodsStock
}}
</p>
<p
class=
"f-s-12"
>
零售价:
{{
item
.
retailPrice
}}
</p>
<p
:title=
"item.merchantName"
class=
"ellipsis f-s-12"
>
门店名称:
{{
item
.
merchantName
}}
</p>
</div>
</el-radio>
</el-radio-group>
</
template
>
</div>
</GLDialog>
</template>
...
...
@@ -46,13 +101,14 @@
// import { getGoodsList } from '@/api/modules/common'
export
default
{
name
:
'selectSingleProDialog'
,
data
()
{
data
()
{
return
{
userInfo
:
{},
infoId
:
''
,
minRatilPrice
:
''
,
productList
:
[],
fnCallBack
:
false
fnCallBack
:
false
,
infoIdList
:
[]
}
},
...
...
@@ -61,26 +117,30 @@ export default {
type
:
Boolean
,
default
:
false
},
selectedProInfo
:
{
type
:
Object
,
default
:
()
=>
{
}
},
selectedProInfo
:
[
Object
,
Array
],
merchantId
:
{
type
:
String
,
required
:
true
},
multiple
:
Boolean
,
multipleMax
:
{
type
:
Number
,
default
:
5
}
},
computed
:
{},
mounted
()
{
mounted
()
{
const
{
multiple
}
=
this
this
.
userInfo
=
this
.
$globalState
.
session
this
.
infoId
=
this
.
selectedProInfo
.
id
if
(
!
multiple
)
this
.
infoId
=
this
.
selectedProInfo
.
id
this
.
getList
()
},
methods
:
{
getList
()
{
getList
()
{
const
{
multiple
,
selectedProInfo
}
=
this
var
params
=
{
goodsStatus
:
1
,
isActivityUsing
:
1
,
...
...
@@ -95,6 +155,11 @@ export default {
// console.log(res)
this
.
fnCallBack
=
true
this
.
productList
=
res
.
list
if
(
multiple
)
{
selectedProInfo
.
length
&&
selectedProInfo
.
map
(
e
=>
{
if
(
e
.
id
)
this
.
infoIdList
.
push
(
e
.
id
)
})
}
this
.
productList
.
forEach
(
function
(
item
)
{
item
.
saleAmount
=
item
.
goodsStatistics
.
saleAmount
if
(
item
.
specificationDetailList
&&
item
.
specificationDetailList
.
length
>
1
)
{
...
...
@@ -117,13 +182,13 @@ export default {
item
.
goodsStock
=
item
.
specificationDetailList
[
0
].
stock
}
else
{
item
.
retailPrice
=
(
item
.
retailPrice
/
100
).
toFixed
(
2
)
console
.
log
(
item
.
retailPrice
)
item
.
minRatilPrice
=
item
.
retailPrice
}
})
})
},
handleSingleSelectConfirm
()
{
handleSingleSelectConfirm
()
{
const
{
multiple
,
infoIdList
}
=
this
if
(
!
this
.
productList
.
length
)
{
var
params
=
{
addOrEdit
:
1
,
...
...
@@ -136,26 +201,47 @@ export default {
})
return
true
}
if
(
!
this
.
infoId
)
{
this
.
$message
({
if
(
multiple
)
{
if
(
infoIdList
.
length
<
1
)
return
this
.
$message
({
message
:
'请选择商品'
,
type
:
'error'
,
customClass
:
'message-Z-zinde'
})
return
true
const
list
=
[]
infoIdList
.
map
(
e
=>
{
list
.
push
(
this
.
productList
.
find
(
item
=>
item
.
id
===
e
))
})
this
.
$emit
(
'handleSingleSelectConfirm'
,
list
)
}
else
{
if
(
!
this
.
infoId
)
{
this
.
$message
({
message
:
'请选择商品'
,
type
:
'error'
,
customClass
:
'message-Z-zinde'
})
return
true
}
var
selectInfo
=
this
.
productList
.
find
(
item
=>
item
.
id
===
this
.
infoId
)
this
.
$emit
(
'handleSingleSelectConfirm'
,
selectInfo
)
}
var
selectInfo
=
this
.
productList
.
find
(
item
=>
item
.
id
===
this
.
infoId
)
this
.
$emit
(
'handleSingleSelectConfirm'
,
selectInfo
)
},
handleSingleSelectClose
()
{
handleSingleSelectClose
()
{
this
.
$emit
(
'handleSingleSelectClose'
)
}
}
}
</
script
>
<
style
>
<
style
lang=
"scss"
>
.single-pro
.pro-group
{
margin-left
:
50px
;
.el-checkbox__input
{
opacity
:
0
!important
;
position
:
absolute
;
}
.el-checkbox__label
{
padding-left
:
0
!important
;
}
}
.single-pro
.pro-box
{
width
:
202px
;
...
...
@@ -181,6 +267,15 @@ export default {
width
:
32px
;
height
:
32px
;
}
.icon-number
{
background-color
:
#5850ff
;
color
:
#fff
;
display
:
flex
;
align-items
:
center
;
justify-content
:
center
;
border-radius
:
100%
;
overflow
:
hidden
;
}
.single-pro
p
{
margin
:
0
0
8px
0
;
}
...
...
src/views/orderManage/index.vue
View file @
9eef294
...
...
@@ -144,7 +144,7 @@
slot=
"assignName"
slot-scope=
"scope"
>
<div>
<div
class=
"flex-align"
>
<
template
v-if=
"scope.scope.assignStaffName"
>
<img
class=
"img-36 pointer img-circle"
...
...
@@ -1876,8 +1876,12 @@ export default {
margin
:
0
8px
0
0
!important
;
}
}
.el-select
.el-select__tags
>
span
{
width
:
80%
;
display
:
flex
!important
;
}
.el-select
.el-tag
{
max-width
:
60
%
!important
;
max-width
:
55
%
!important
;
}
.import-dialog
{
.el-dialog__body
{
...
...
src/views/seckillActivity/crowdFundList.vue
View file @
9eef294
...
...
@@ -624,8 +624,12 @@ export default {
}
</
script
>
<
style
scoped
>
<
style
>
.el-select
.el-select__tags
>
span
{
display
:
flex
!important
;
width
:
80%
;
}
.el-select
.el-tag
{
max-width
:
60
%
!important
;
max-width
:
55
%
!important
;
}
</
style
>
src/views/seckillActivity/editCrowdFund.vue
View file @
9eef294
This diff is collapsed.
Click to expand it.
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