Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
glsx-web
/
glsx-dj-oss-equity
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 7754a4ef
authored
Oct 09, 2021
by
zhouzy
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
增加新的需求
1 parent
61176ba3
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
143 additions
and
111 deletions
src/api/api.js
src/mixins/carMixin.js
src/mixins/goodsMixin.js
src/views/customer/rightsCardManagement/index.vue
src/views/equity/list/index.vue
src/api/api.js
View file @
7754a4e
...
...
@@ -2,8 +2,10 @@ import request from './request'
export
const
commonApi
=
{
/**图片上传接口*/
upLoadImg
(
data
=
{})
{
return
request
(
data
,
'scrm.api.equity.common.upload.image'
,
'post'
,
[
'file'
])
},
return
request
(
data
,
'scrm.api.equity.common.upload.image'
,
'post'
,
[
'file'
])
}
}
export
const
orderApi
=
{
/**获取财务管理列表*/
...
...
@@ -59,10 +61,12 @@ export const orderApi = {
return
request
(
data
,
'scrm.api.equity.goods.get.by.id'
)
},
/** 第三方商品分页查询*/
getListWithPageOutGoods
(
data
=
{
supplier
:
'HW'
,
pageSize
:
99999
})
{
getListWithPageOutGoods
(
data
=
{
supplier
:
'HW'
,
pageSize
:
99999
}
)
{
return
request
(
data
,
'scrm.api.equity.goods.out.list.with.page'
)
},
/**商品编号获取商品信息(第三方)*/
...
...
@@ -91,15 +95,22 @@ export const orderApi = {
},
/** 获取渠道下所有品牌 */
getAllBrandList
(
data
=
{})
{
return
request
({
...
data
,
supplier
:
'HW'
,
pageNum
:
1
,
pageSize
:
9999
,
},
'scrm.api.equity.goods.brand.list.all'
)
},
return
request
(
{
...
data
,
supplier
:
'HW'
,
pageNum
:
1
,
pageSize
:
9999
},
'scrm.api.equity.goods.brand.list.all'
)
}
}
export
const
carEquityManageApi
=
{
/** 更改汽车展示状态*/
cardsDisplay
(
data
=
{})
{
return
request
(
data
,
'scrm.api.equity.car.service.main.page.flag.update'
)
},
/** 获取汽车权益列表*/
getCarList
(
data
=
{
pageSize
:
9999
,
pageNum
:
1
})
{
return
request
(
data
,
'scrm.api.equity.car.service.list'
)
...
...
@@ -119,16 +130,23 @@ export const carEquityManageApi = {
/** 更新汽车权益*/
updateEquity
(
data
=
{})
{
return
request
(
data
,
'scrm.api.equity.car.service.update'
)
}
,
}
}
export
const
goodsEquityManageApi
=
{
/** 商品首页展示*/
goodsDisplay
(
data
=
{})
{
return
request
(
data
,
'scrm.api.equity.goods.group.main.page.flag.update'
)
},
/**获取商品权益列表*/
getGoodsList
(
data
)
{
return
request
({
...
data
,
pageSize
:
9999
,
pageNum
:
1
},
'scrm.api.equity.goods.group.list'
)
return
request
(
{
...
data
,
pageSize
:
9999
,
pageNum
:
1
},
'scrm.api.equity.goods.group.list'
)
},
/**获取商品权益分类列表*/
getCategoryList
(
data
=
{
pageSize
:
9999
,
pageNum
:
1
})
{
...
...
@@ -167,16 +185,20 @@ export const goodsEquityManageApi = {
return
request
(
data
,
'scrm.api.equity.goods.group.update'
)
},
/** 获取品牌列表*/
getGoodsBrandList
(
data
=
{
supplier
:
'HW'
})
{
getGoodsBrandList
(
data
=
{
supplier
:
'HW'
}
)
{
return
request
(
data
,
'scrm.api.equity.goods.brand.list'
)
},
/* 获取品牌下商品形态列表*/
getAppearanceList
(
data
=
{})
{
return
request
({
...
data
,
supplier
:
'HW'
},
'scrm.api.equity.goods.appearance.list'
)
},
return
request
(
{
...
data
,
supplier
:
'HW'
},
'scrm.api.equity.goods.appearance.list'
)
}
}
export
const
equityApi
=
{
/*获取权益卡管理列表*/
...
...
@@ -219,8 +241,8 @@ export const equityApi = {
getCollectionMerchantList
(
data
=
{})
{
return
request
(
data
,
'scrm.api.equity.card.get.by.merchant.name'
)
},
/*获取推广信息*/
getQrUrl
(
data
=
{})
{
return
request
(
data
,
'scrm.api.equity.card.class.generate.try.url'
)
},
}
\ No newline at end of file
/*获取推广信息*/
getQrUrl
(
data
=
{})
{
return
request
(
data
,
'scrm.api.equity.card.class.generate.try.url'
)
}
}
src/mixins/carMixin.js
View file @
7754a4e
...
...
@@ -41,6 +41,12 @@ export default {
}[
cell
.
supplier
]
}
},
{
label
:
'排序展示'
,
prop
:
'mainPageFlag'
,
minWidth
:
'200'
,
addHtml
:
'mainPageFlag'
}
]
},
...
...
src/mixins/goodsMixin.js
View file @
7754a4e
...
...
@@ -43,6 +43,12 @@ export default {
return
'海威'
}
},
{
label
:
'排序展示'
,
prop
:
'mainPageFlag'
,
minWidth
:
'200'
,
addHtml
:
'mainPageFlag'
},
]
}
}
...
...
src/views/customer/rightsCardManagement/index.vue
View file @
7754a4e
...
...
@@ -268,6 +268,17 @@
maxlength=
"500"
></el-input>
</el-form-item>
<el-form-item
label=
" 售价:"
prop=
"price"
>
<el-input-number
v-model=
"ruleForm.price"
controls-position=
"right"
size=
"mini"
:min=
"1"
></el-input-number>
元
</el-form-item>
</div>
<div
class=
"baseinformation2"
>
<span
class=
"titleText"
>
其他信息
</span>
</div>
<div
class=
"form"
>
...
...
@@ -370,54 +381,6 @@ export default {
src
:
'./images/yiquan.jpg'
,
inputSwitch
:
true
,
dataSwitch
:
true
,
// storeOptions: [
// {
// id: '21',
// name: '辛巴克'
// }, {
// id: '22',
// name: '必胜客'
// },
// {
// id: '23',
// name: '肯德基'
// },
// {
// id: '24',
// name: '汉堡王'
// },
// {
// id: '27',
// name: '太平洋咖啡'
// },
// {
// id: '28',
// name: 'COSTA咖啡'
// },
// {
// id: '26',
// name: '哈根达斯'
// },
// {
// id: '25',
// name: 'CoCo都可'
// },
// {
// id: '30',
// name: '百果园 '
// },
// {
// id: '31',
// name: '腾讯会员'
// }, {
// id: '4',
// name: '淘票票'
// },
// {
// id: '2',
// name: '淘票票2'
// }
// ],
tryNum
:
''
,
effectiveNum
:
''
,
data
:
''
,
...
...
@@ -429,7 +392,8 @@ export default {
effectiveType
:
'1'
,
platformGoodsId
:
+
''
,
merchantName
:
''
,
id
:
''
id
:
''
,
price
:
''
},
editForm
:
{
url
:
''
,
...
...
@@ -441,21 +405,6 @@ export default {
imgSrc
:
require
(
"./images/card0.png"
),
src
:
"./images/card0.png"
},
// {
// id: "secondImg",
// imgSrc: require("./images/card1.png"),
// src: "./images/card1.png"
// },
// {
// id: "thirdImg",
// imgSrc: require("./images/card2.png"),
// src: "./images/card2.png"
// },
// {
// id: "forthImg",
// imgSrc: require("./images/card3.png"),
// src: "./images/card3.png"
// },
],
rules
:
{
cardClassName
:
[
...
...
@@ -476,6 +425,9 @@ export default {
],
tryNum
:
[
{
required
:
true
,
message
:
'请选择试用天数'
,
trigger
:
'blur'
}
],
price
:
[
{
required
:
true
,
message
:
'请选择售价'
,
trigger
:
'blur'
}
]
},
//权益卡管理界面
...
...
@@ -519,6 +471,13 @@ export default {
}
},
{
label
:
'售价'
,
prop
:
'price'
,
formatter
:
(
cellValue
)
=>
{
return
cellValue
.
price
+
'元'
}
},
{
label
:
'领卡用户'
,
prop
:
'recipientCount'
// width: 110,
...
...
src/views/equity/list/index.vue
View file @
7754a4e
...
...
@@ -16,6 +16,15 @@
:hasPage=
"false"
:hasNum=
"false"
>
<div
slot=
"mainPageFlag"
slot-scope=
"scope"
>
<el-button
type=
"text"
@
click=
"carsDisplay(scope.scope)"
>
{{
scope
.
scope
.
mainPageFlag
==
1
?
'取消首页展示'
:
'首页展示'
}}
</el-button>
</div>
<span
slot=
"auth-button"
slot-scope=
"scope"
...
...
@@ -98,6 +107,15 @@
:hasPage=
"false"
:hasNum=
"false"
>
<div
slot=
"mainPageFlag"
slot-scope=
"scope"
>
<el-button
type=
"text"
@
click=
"goodsDisplay(scope.scope)"
>
{{scope.scope.mainPageFlag==1?'取消首页展示':'首页展示'}}
</el-button>
</div>
<span
slot=
"auth-button"
slot-scope=
"scope"
...
...
@@ -105,10 +123,6 @@
>
<el-button
type=
"text"
@
click=
"editEquity(scope.scope,2)"
>
编辑
</el-button>
<el-button
type=
"text"
@
click=
"updateShelves(scope.scope,'goods')"
>
{{scope.scope.status == 0?'上架':'下架'}}
</el-button>
<el-button
...
...
@@ -128,13 +142,12 @@
</template>
<
script
type=
'text/ecmascript-6'
>
import
{
goodsMixin
,
carMixin
}
from
'@/mixins'
import
{
goodsEquityManageApi
,
carEquityManageApi
}
from
'@api/api'
export
default
{
name
:
''
,
mixins
:
[
carMixin
,
goodsMixin
],
data
()
{
data
()
{
return
{
showDialog
:
false
,
isEdit
:
false
,
...
...
@@ -142,19 +155,45 @@ export default {
editData
:
{}
}
},
mounted
()
{
//
this.init()
mounted
()
{
this
.
init
()
},
methods
:
{
init
()
{
/*更改汽车展示状态 */
carsDisplay
(
row
)
{
if
(
row
.
mainPageFlag
==
0
)
{
carEquityManageApi
.
cardsDisplay
({
id
:
row
.
id
,
mainPageFlag
:
1
})
.
then
(
res
=>
{})
}
else
{
carEquityManageApi
.
cardsDisplay
({
id
:
row
.
id
,
mainPageFlag
:
0
})
.
then
(
res
=>
{})
}
this
.
getCarList
()
},
/*改变商品展示状态 */
goodsDisplay
(
row
)
{
if
(
row
.
mainPageFlag
==
0
)
{
goodsEquityManageApi
.
goodsDisplay
({
id
:
row
.
id
,
mainPageFlag
:
1
})
.
then
(
res
=>
{})
}
else
{
goodsEquityManageApi
.
goodsDisplay
({
id
:
row
.
id
,
mainPageFlag
:
0
})
.
then
(
res
=>
{})
}
this
.
getCategoryList
()
},
addEquity
(
type
)
{
init
()
{
this
.
getCarList
()
this
.
getCategoryList
()
},
addEquity
(
type
)
{
this
.
dialogType
=
type
this
.
showDialog
=
true
},
setTop
(
id
,
type
)
{
setTop
(
id
,
type
)
{
let
target
=
type
==
'car'
?
carEquityManageApi
:
goodsEquityManageApi
target
.
setTop
({
id
}).
then
(({
code
,
message
})
=>
{
if
(
code
==
0
)
{
...
...
@@ -165,12 +204,12 @@ export default {
}
})
},
editEquity
(
data
,
type
)
{
editEquity
(
data
,
type
)
{
this
.
editData
=
data
this
.
isEdit
=
true
this
.
addEquity
(
type
)
},
updateShelves
({
id
,
status
},
type
)
{
updateShelves
({
id
,
status
},
type
)
{
let
target
=
type
==
'car'
?
carEquityManageApi
:
goodsEquityManageApi
status
=
status
==
1
?
0
:
1
const
callBack
=
()
=>
{
...
...
@@ -195,12 +234,12 @@ export default {
}
else
{
callBack
()
}
},
}
}
}
</
script
>
<
style
src=
"@a/css/tao.css"
></
style
>
<
style
src=
"@a/css/tao.css"
>
</
style
>
<
style
>
.equity-title
{
height
:
44px
;
...
...
@@ -261,4 +300,4 @@ export default {
.opacity
{
opacity
:
0.5
;
}
</
style
>
\ No newline at end of file
</
style
>
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