Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
sensorConsult
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
zhanglw
sensorConsult
Commits
4bf9f221
Commit
4bf9f221
authored
Jul 19, 2023
by
zhanglw
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
内容管理
parent
700e23b0
Changes
11
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
720 additions
and
63 deletions
+720
-63
common.js
src/api/common.js
+10
-1
add.vue
src/views/backstage/contentMgt/homePage/add.vue
+91
-39
index.vue
src/views/backstage/contentMgt/homePage/index.vue
+6
-3
view.vue
src/views/backstage/contentMgt/homePage/view.vue
+520
-0
index.vue
src/views/backstage/contentMgt/productTabulate/index.vue
+13
-8
edit.vue
src/views/backstage/contentMgt/supplierTabulate/edit.vue
+41
-7
index.vue
src/views/backstage/contentMgt/supplierTabulate/index.vue
+1
-0
add.vue
src/views/backstage/customMgt/customTabulate/add.vue
+1
-1
edit.vue
src/views/backstage/customMgt/customTabulate/edit.vue
+13
-2
edit.vue
src/views/backstage/productMgt/productTabulate/edit.vue
+12
-1
edit.vue
src/views/homepage/console/edit.vue
+12
-1
No files found.
src/api/common.js
View file @
4bf9f221
...
@@ -23,6 +23,15 @@ export const HttpReq = {
...
@@ -23,6 +23,15 @@ export const HttpReq = {
return
res
return
res
})
})
},
},
deletePicture
:
function
(
data
)
{
return
request
({
url
:
'
/api/bsw/common/deletePicture
'
,
method
:
'
delete
'
,
data
:
data
}).
then
((
res
)
=>
{
return
res
})
},
// 获取行政区划
// 获取行政区划
findAreaByCodeAndType
:
function
(
params
)
{
findAreaByCodeAndType
:
function
(
params
)
{
return
request
({
return
request
({
...
@@ -317,7 +326,7 @@ export const HttpReq = {
...
@@ -317,7 +326,7 @@ export const HttpReq = {
})
})
},
},
// 内容管理-首页管理批量删除
// 内容管理-首页管理批量删除
b
atchDelete
:
function
(
data
)
{
hpB
atchDelete
:
function
(
data
)
{
return
request
({
return
request
({
url
:
'
/api/bsw/homePage/batchDelete
'
,
url
:
'
/api/bsw/homePage/batchDelete
'
,
method
:
'
delete
'
,
method
:
'
delete
'
,
...
...
src/views/backstage/contentMgt/homePage/add.vue
View file @
4bf9f221
...
@@ -68,7 +68,14 @@
...
@@ -68,7 +68,14 @@
</el-form-item>
</el-form-item>
<el-form-item
label=
"供应商名称:"
class=
"form-cell"
prop=
"supplierName"
>
<el-form-item
label=
"供应商名称:"
class=
"form-cell"
prop=
"supplierName"
>
<div
class=
"cell-box"
>
<div
class=
"cell-box"
>
<el-input
v-model=
"formData.supplierName"
placeholder=
"单行输入"
class=
"cell-input"
/>
<el-autocomplete
v-model=
"formData.supplierName"
class=
"cell-input"
:fetch-suggestions=
"querySearch"
placeholder=
"单行输入"
:trigger-on-focus=
"false"
@
select=
"handleSelect"
/>
</div>
</div>
</el-form-item>
</el-form-item>
<el-form-item
label=
"是否设置为钻石供应商:"
class=
"form-cell"
prop=
"diamondSupplier"
>
<el-form-item
label=
"是否设置为钻石供应商:"
class=
"form-cell"
prop=
"diamondSupplier"
>
...
@@ -192,7 +199,7 @@
...
@@ -192,7 +199,7 @@
<div
class=
"cell-box"
>
<div
class=
"cell-box"
>
<ul
class=
"el-upload-list el-upload-list--picture-card"
style=
"float: left"
>
<ul
class=
"el-upload-list el-upload-list--picture-card"
style=
"float: left"
>
<li
v-for=
"(item, index) in imgList"
:key=
"index"
tabindex=
"0"
class=
"el-upload-list__item is-success"
>
<li
v-for=
"(item, index) in imgList"
:key=
"index"
tabindex=
"0"
class=
"el-upload-list__item is-success"
>
<img
:src=
"imgSrcStart+
'/productPic/'+
item"
class=
"el-upload-list__item-thumbnail"
>
<img
:src=
"imgSrcStart+item"
class=
"el-upload-list__item-thumbnail"
>
<label
class=
"el-upload-list__item-status-label"
><i
class=
"el-icon-upload-success el-icon-check"
/></label>
<label
class=
"el-upload-list__item-status-label"
><i
class=
"el-icon-upload-success el-icon-check"
/></label>
<span
class=
"el-upload-list__item-actions"
>
<span
class=
"el-upload-list__item-actions"
>
<span
class=
"el-upload-list__item-preview"
@
click=
"dialogImgUrl=item;dialogImgVisible=true"
><i
class=
"el-icon-zoom-in"
/></span>
<span
class=
"el-upload-list__item-preview"
@
click=
"dialogImgUrl=item;dialogImgVisible=true"
><i
class=
"el-icon-zoom-in"
/></span>
...
@@ -201,21 +208,24 @@
...
@@ -201,21 +208,24 @@
</li>
</li>
</ul>
</ul>
<el-dialog
append-to-body
:visible.sync=
"dialogImgVisible"
>
<el-dialog
append-to-body
:visible.sync=
"dialogImgVisible"
>
<img
width=
"100%"
:src=
"imgSrcStart+
'/productPic/'+
dialogImgUrl"
>
<img
width=
"100%"
:src=
"imgSrcStart+dialogImgUrl"
>
</el-dialog>
</el-dialog>
<el-upload
<el-upload
ref=
"uploadCom"
ref=
"uploadCom"
action=
"/api/bsw/product/uploadProductPic"
action=
"/api/bsw/common/uploadPicture"
name=
"productPic"
name=
"multipartFile"
:data=
"
{mark:'logo'}"
list-type="picture-card"
list-type="picture-card"
:headers="uploadHeaders"
:headers="uploadHeaders"
:limit=
"
5
"
:limit="
1
"
:on-exceed="handleExceed"
:on-exceed="handleExceed"
:on-success="handleImported"
:on-success="handleImported"
:on-preview="handlePictureCardPreview"
:on-preview="handlePictureCardPreview"
:on-remove="handleRemove"
:on-remove="handleRemove"
>
>
<i
class=
"el-icon-plus"
/>
<div
slot=
"trigger"
@
click=
"handlePushClick($event)"
>
<i
class=
"el-icon-plus"
/>
</div>
</el-upload>
</el-upload>
<el-dialog
append-to-body
:visible.sync=
"dialogImageVisible"
>
<el-dialog
append-to-body
:visible.sync=
"dialogImageVisible"
>
<img
width=
"100%"
:src=
"dialogImageUrl"
>
<img
width=
"100%"
:src=
"dialogImageUrl"
>
...
@@ -315,11 +325,61 @@ export default {
...
@@ -315,11 +325,61 @@ export default {
})
})
},
},
methods
:
{
methods
:
{
checkEnterpriseName
(
rule
,
value
,
callback
)
{
this
.
$nextTick
(
_
=>
{
HttpReq
.
backstageApi
.
checkEnterpriseName
({
name
:
value
,
id
:
this
.
formData
.
supplierId
}).
then
((
res
)
=>
{
if
(
res
.
data
)
{
callback
()
}
else
{
callback
(
new
Error
(
res
.
msg
))
}
})
})
},
querySearch
(
queryString
,
cb
)
{
HttpReq
.
backstageApi
.
associateQueryEnterpriseName
({
name
:
queryString
}).
then
((
res
)
=>
{
cb
(
res
.
data
)
})
},
handleSelect
(
item
)
{
this
.
formData
.
supplierId
=
item
.
id
},
showView
()
{
showView
()
{
this
.
visible
=
true
this
.
visible
=
true
},
},
hideView
()
{
hideView
()
{
if
(
this
.
$refs
.
uploadCom
)
{
this
.
$refs
.
uploadCom
.
clearFiles
()
}
this
.
$refs
.
formViewRef
.
resetFields
()
this
.
$refs
.
formViewRef
.
resetFields
()
this
.
imgList
=
[]
this
.
formData
=
{
type
:
'
1
'
,
operationName
:
''
,
// 操作名称
channelName
:
''
,
// 频道名称
url
:
''
,
// 链接
searchType
:
''
,
// 搜索类型
content
:
''
,
// 内容
supplierId
:
''
,
// 供应商id
supplierName
:
''
,
// 供应商名称
popularSupplier
:
''
,
// 是否热门供应商
diamondSupplier
:
''
,
// 是否设置为钻石供应商
productType
:
''
,
// 产品分类
productId
:
''
,
// 产品ID
productOperationName
:
''
,
// 产品运营名称
trustworthyProduct
:
''
,
// 是否设置为信得过产品
popularProduct
:
''
,
// 是否设置为热门产品
rankingType
:
'
1
'
,
// 排行榜类型
partnerName
:
''
,
// 合作伙伴名称名称
partnerLogo
:
''
,
// 合作伙伴LOGO
linkName
:
''
,
// 链接名称
sort
:
1
,
// 顺序
homePageId
:
null
}
this
.
visible
=
false
this
.
visible
=
false
},
},
cancelView
()
{
cancelView
()
{
...
@@ -381,33 +441,14 @@ export default {
...
@@ -381,33 +441,14 @@ export default {
})
})
},
},
loadData
(
homePageId
)
{
loadData
(
homePageId
)
{
this
.
formData
=
{
type
:
'
1
'
,
operationName
:
''
,
// 操作名称
channelName
:
''
,
// 频道名称
url
:
''
,
// 链接
searchType
:
''
,
// 搜索类型
content
:
''
,
// 内容
supplierId
:
''
,
// 供应商id
supplierName
:
''
,
// 供应商名称
popularSupplier
:
''
,
// 是否热门供应商
diamondSupplier
:
''
,
// 是否设置为钻石供应商
productType
:
''
,
// 产品分类
productId
:
''
,
// 产品ID
productOperationName
:
''
,
// 产品运营名称
trustworthyProduct
:
''
,
// 是否设置为信得过产品
popularProduct
:
''
,
// 是否设置为热门产品
rankingType
:
'
1
'
,
// 排行榜类型
partnerName
:
''
,
// 合作伙伴名称名称
partnerLogo
:
''
,
// 合作伙伴LOGO
linkName
:
''
,
// 链接名称
sort
:
1
,
// 顺序
homePageId
:
null
}
if
(
homePageId
)
{
if
(
homePageId
)
{
this
.
title
=
'
编辑首页内容
'
HttpReq
.
backstageApi
.
queryHomePageById
({
homePageId
}).
then
((
res
)
=>
{
HttpReq
.
backstageApi
.
queryHomePageById
({
homePageId
}).
then
((
res
)
=>
{
if
(
res
.
code
===
200
)
{
if
(
res
.
code
===
200
)
{
this
.
formData
=
Object
.
assign
(
this
.
formData
,
res
.
data
)
this
.
formData
=
Object
.
assign
(
this
.
formData
,
res
.
data
)
if
(
this
.
formData
.
partnerLogo
)
{
this
.
imgList
=
this
.
formData
.
partnerLogo
.
split
(
'
;
'
)
}
}
else
{
}
else
{
this
.
$message
({
this
.
$message
({
message
:
res
.
msg
,
message
:
res
.
msg
,
...
@@ -415,6 +456,8 @@ export default {
...
@@ -415,6 +456,8 @@ export default {
})
})
}
}
})
})
}
else
{
this
.
title
=
'
添加首页内容
'
}
}
this
.
showView
()
this
.
showView
()
},
},
...
@@ -424,15 +467,24 @@ export default {
...
@@ -424,15 +467,24 @@ export default {
type
:
'
info
'
type
:
'
info
'
})
})
},
},
handlePushClick
(
event
)
{
if
(
this
.
formData
.
partnerLogo
!==
''
)
{
event
.
stopPropagation
()
this
.
$message
({
message
:
'
超出最大上传数量限制
'
,
type
:
'
info
'
})
}
},
handleRemoveImg
(
item
)
{
handleRemoveImg
(
item
)
{
this
.
imgList
.
splice
(
this
.
imgList
.
indexOf
(
item
),
1
)
this
.
imgList
.
splice
(
this
.
imgList
.
indexOf
(
item
),
1
)
const
arr
=
this
.
formData
.
p
roductPic
.
split
(
'
;
'
)
const
arr
=
this
.
formData
.
p
artnerLogo
.
split
(
'
;
'
)
arr
.
splice
(
arr
.
indexOf
(
item
),
1
)
arr
.
splice
(
arr
.
indexOf
(
item
),
1
)
this
.
formData
.
p
roductPic
=
arr
.
join
(
'
;
'
)
this
.
formData
.
p
artnerLogo
=
arr
.
join
(
'
;
'
)
},
},
handleRemove
(
file
,
fileList
)
{
handleRemove
(
file
,
fileList
)
{
HttpReq
.
backstageApi
.
deleteP
roductPic
({
HttpReq
.
backstageApi
.
deleteP
icture
({
productPic
:
file
.
response
.
productPic
multipartFile
:
file
.
response
.
pictures
}).
then
((
res
)
=>
{
}).
then
((
res
)
=>
{
this
.
$notify
({
this
.
$notify
({
title
:
res
.
msg
,
title
:
res
.
msg
,
...
@@ -441,9 +493,9 @@ export default {
...
@@ -441,9 +493,9 @@ export default {
})
})
const
arr
=
[]
const
arr
=
[]
fileList
.
forEach
(
item
=>
{
fileList
.
forEach
(
item
=>
{
arr
.
push
(
item
.
response
.
p
roductPic
)
arr
.
push
(
item
.
response
.
p
ictures
)
})
})
this
.
formData
.
p
roductPic
=
arr
.
join
(
'
;
'
)
this
.
formData
.
p
artnerLogo
=
arr
.
join
(
'
;
'
)
})
})
},
},
handlePictureCardPreview
(
file
)
{
handlePictureCardPreview
(
file
)
{
...
@@ -452,9 +504,9 @@ export default {
...
@@ -452,9 +504,9 @@ export default {
},
},
handleImported
(
response
,
file
,
fileList
)
{
handleImported
(
response
,
file
,
fileList
)
{
this
.
$nextTick
(()
=>
{
this
.
$nextTick
(()
=>
{
const
arr
=
this
.
formData
.
p
roductPic
?
this
.
formData
.
productPic
.
split
(
'
;
'
)
:
[]
const
arr
=
this
.
formData
.
p
artnerLogo
?
this
.
formData
.
partnerLogo
.
split
(
'
;
'
)
:
[]
arr
.
push
(
response
.
p
roductPic
)
arr
.
push
(
response
.
p
ictures
)
this
.
formData
.
p
roductPic
=
arr
.
join
(
'
;
'
)
this
.
formData
.
p
artnerLogo
=
arr
.
join
(
'
;
'
)
this
.
$notify
({
this
.
$notify
({
title
:
'
上传成功!
'
,
title
:
'
上传成功!
'
,
type
:
'
success
'
,
type
:
'
success
'
,
...
...
src/views/backstage/contentMgt/homePage/index.vue
View file @
4bf9f221
...
@@ -28,6 +28,7 @@
...
@@ -28,6 +28,7 @@
<el-table-column
type=
"index"
width=
"55"
label=
"序号"
:index=
"indexMethod"
/>
<el-table-column
type=
"index"
width=
"55"
label=
"序号"
:index=
"indexMethod"
/>
<el-table-column
prop=
"type"
label=
"位置"
width=
"200"
:formatter=
"(row, col, val)=>
{return dict.label.home_setting[val]}" />
<el-table-column
prop=
"type"
label=
"位置"
width=
"200"
:formatter=
"(row, col, val)=>
{return dict.label.home_setting[val]}" />
<el-table-column
prop=
"operationName"
label=
"操作名称"
/>
<el-table-column
prop=
"operationName"
label=
"操作名称"
/>
<el-table-column
prop=
"sort"
label=
"顺序"
width=
"100"
/>
<el-table-column
label=
"状态"
width=
"100"
>
<el-table-column
label=
"状态"
width=
"100"
>
<template
slot-scope=
"scope"
>
<template
slot-scope=
"scope"
>
<div
:style=
"'color:'+textColors[scope.row.status]"
>
{{
dict
.
label
.
issue_status
[
scope
.
row
.
status
]
}}
</div>
<div
:style=
"'color:'+textColors[scope.row.status]"
>
{{
dict
.
label
.
issue_status
[
scope
.
row
.
status
]
}}
</div>
...
@@ -47,15 +48,17 @@
...
@@ -47,15 +48,17 @@
<el-pagination
:total=
"total"
:current-page=
"page"
:page-size=
"pageSize"
style=
"margin-top: 8px;"
layout=
"total, prev, pager, next, sizes"
@
size-change=
"sizeChange"
@
current-change=
"pageChange"
/>
<el-pagination
:total=
"total"
:current-page=
"page"
:page-size=
"pageSize"
style=
"margin-top: 8px;"
layout=
"total, prev, pager, next, sizes"
@
size-change=
"sizeChange"
@
current-change=
"pageChange"
/>
</div>
</div>
<add-page
ref=
"addPage"
/>
<add-page
ref=
"addPage"
/>
<view-page
ref=
"viewPage"
/>
</div>
</div>
</template>
</template>
<
script
>
<
script
>
import
{
HttpReq
}
from
'
@/api/common
'
import
{
HttpReq
}
from
'
@/api/common
'
import
DateRangePicker
from
'
@/components/DateRangePicker
'
import
DateRangePicker
from
'
@/components/DateRangePicker
'
import
addPage
from
'
./add
'
import
addPage
from
'
./add
'
import
viewPage
from
'
./view
'
export
default
{
export
default
{
components
:
{
DateRangePicker
,
addPage
},
components
:
{
DateRangePicker
,
addPage
,
viewPage
},
dicts
:
[
'
issue_status
'
,
'
home_setting
'
],
dicts
:
[
'
issue_status
'
,
'
home_setting
'
],
data
()
{
data
()
{
return
{
return
{
...
@@ -121,10 +124,10 @@ export default {
...
@@ -121,10 +124,10 @@ export default {
this
.
$refs
.
addPage
.
loadData
(
item
.
homePageId
)
this
.
$refs
.
addPage
.
loadData
(
item
.
homePageId
)
},
},
toView
(
item
)
{
toView
(
item
)
{
this
.
$refs
.
add
Page
.
loadData
(
item
.
homePageId
)
this
.
$refs
.
view
Page
.
loadData
(
item
.
homePageId
)
},
},
toDelete
(
item
)
{
toDelete
(
item
)
{
HttpReq
.
backstageApi
.
b
atchDelete
({
HttpReq
.
backstageApi
.
hpB
atchDelete
({
ids
:
[
item
.
homePageId
]
ids
:
[
item
.
homePageId
]
}).
then
((
res
)
=>
{
}).
then
((
res
)
=>
{
this
.
$notify
({
this
.
$notify
({
...
...
src/views/backstage/contentMgt/homePage/view.vue
0 → 100644
View file @
4bf9f221
This diff is collapsed.
Click to expand it.
src/views/backstage/contentMgt/productTabulate/index.vue
View file @
4bf9f221
...
@@ -26,7 +26,7 @@
...
@@ -26,7 +26,7 @@
<el-table-column
prop=
"updateTime"
label=
"最后维护日期"
align=
"center"
width=
"200"
/>
<el-table-column
prop=
"updateTime"
label=
"最后维护日期"
align=
"center"
width=
"200"
/>
<el-table-column
label=
"操作"
align=
"right"
width=
"240"
>
<el-table-column
label=
"操作"
align=
"right"
width=
"240"
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
<el-tooltip
v-if=
"scope.row.status==='1'"
content=
"发布"
><el-button
round
plain
type=
"success"
icon=
"el-icon-finished"
@
click=
"
toEdit(
scope.row)"
/></el-tooltip>
<el-tooltip
v-if=
"scope.row.status==='1'"
content=
"发布"
><el-button
round
plain
type=
"success"
icon=
"el-icon-finished"
@
click=
"
batchOperate(1,
scope.row)"
/></el-tooltip>
<el-tooltip
content=
"设置"
><el-button
round
plain
icon=
"el-icon-s-tools"
@
click=
"toEdit(scope.row)"
/></el-tooltip>
<el-tooltip
content=
"设置"
><el-button
round
plain
icon=
"el-icon-s-tools"
@
click=
"toEdit(scope.row)"
/></el-tooltip>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
...
@@ -85,18 +85,23 @@ export default {
...
@@ -85,18 +85,23 @@ export default {
this
.
total
=
res
.
data
.
total
this
.
total
=
res
.
data
.
total
})
})
},
},
batchOperate
(
opt
)
{
batchOperate
(
type
,
row
)
{
if
(
!
this
.
multipleSelection
.
length
)
{
if
(
!
row
&&
!
this
.
multipleSelection
.
length
)
{
return
this
.
$message
({
return
this
.
$message
({
message
:
'
未选取数据
'
,
message
:
'
未选取数据
'
,
type
:
'
info
'
type
:
'
info
'
})
})
}
}
if
(
opt
)
{
HttpReq
.
backstageApi
.
releaseProductListPage
({
console
.
log
(
'
启用
'
,
this
.
multipleSelection
)
ids
:
row
?
[
row
.
productListPageId
]
:
this
.
multipleSelection
.
map
(
item
=>
{
return
item
.
productListPageId
})
}
else
{
}).
then
((
res
)
=>
{
console
.
log
(
'
启用
'
,
this
.
multipleSelection
)
this
.
$notify
({
}
title
:
res
.
msg
,
type
:
res
.
code
===
200
?
'
success
'
:
'
error
'
,
duration
:
2500
})
this
.
loadData
()
})
},
},
toEdit
(
item
)
{
toEdit
(
item
)
{
this
.
$refs
.
editPage
.
loadData
(
item
.
productListPageId
)
this
.
$refs
.
editPage
.
loadData
(
item
.
productListPageId
)
...
...
src/views/backstage/contentMgt/supplierTabulate/edit.vue
View file @
4bf9f221
...
@@ -2,24 +2,31 @@
...
@@ -2,24 +2,31 @@
<!-- 表单渲染 -->
<!-- 表单渲染 -->
<el-dialog
append-to-body
:close-on-click-modal=
"false"
:before-close=
"cancelView"
:visible=
"visible"
:title=
"title"
width=
"860px"
>
<el-dialog
append-to-body
:close-on-click-modal=
"false"
:before-close=
"cancelView"
:visible=
"visible"
:title=
"title"
width=
"860px"
>
<el-form
ref=
"formViewRef"
:model=
"formData"
:rules=
"rules"
:status-icon=
"true"
label-width=
"240px"
>
<el-form
ref=
"formViewRef"
:model=
"formData"
:rules=
"rules"
:status-icon=
"true"
label-width=
"240px"
>
<el-form-item
label=
"供应商名称:"
class=
"form-cell"
prop=
"
xxx
"
>
<el-form-item
label=
"供应商名称:"
class=
"form-cell"
prop=
"
supplierName
"
>
<div
class=
"cell-box"
>
<div
class=
"cell-box"
>
<el-input
v-model=
"formData.supplierName"
placeholder=
"单行输入"
class=
"cell-input"
/>
<el-autocomplete
v-model=
"formData.supplierName"
class=
"cell-input"
:fetch-suggestions=
"querySearch"
placeholder=
"单行输入"
:trigger-on-focus=
"false"
@
select=
"handleSelect"
/>
</div>
</div>
</el-form-item>
</el-form-item>
<el-form-item
label=
"供应商ID:"
class=
"form-cell"
prop=
"
xxx
"
>
<el-form-item
label=
"供应商ID:"
class=
"form-cell"
prop=
"
customerId
"
>
<div
class=
"cell-box"
>
<div
class=
"cell-box"
>
<el-input
v-model=
"formData.customerId"
placeholder=
"单行输入"
class=
"cell-input"
/>
<el-input
v-model=
"formData.customerId"
placeholder=
"单行输入"
class=
"cell-input"
/>
</div>
</div>
</el-form-item>
</el-form-item>
<el-form-item
label=
"标识设置:"
class=
"form-cell"
prop=
"
supplierLevel
"
>
<el-form-item
label=
"标识设置:"
class=
"form-cell"
prop=
"
mark
"
>
<div
class=
"cell-box"
>
<div
class=
"cell-box"
>
<el-select
v-model=
"formData.mark"
placeholder=
"无"
class=
"cell-select"
>
<el-select
v-model=
"formData.mark"
placeholder=
"无"
class=
"cell-select"
>
<el-option
v-for=
"item in dict.supplier_rank"
:key=
"item.value"
:label=
"item.label"
:value=
"item.value"
/>
<el-option
v-for=
"item in dict.supplier_rank"
:key=
"item.value"
:label=
"item.label"
:value=
"item.value"
/>
</el-select>
</el-select>
</div>
</div>
</el-form-item>
</el-form-item>
<el-form-item
label=
"顺序:"
class=
"form-cell"
prop=
"
operatingPeriod
"
>
<el-form-item
label=
"顺序:"
class=
"form-cell"
prop=
"
sort
"
>
<div
class=
"cell-box"
>
<div
class=
"cell-box"
>
<el-input
v-model.number=
"formData.sort"
type=
"number"
placeholder=
"请输入数字"
class=
"cell-input"
/>
<el-input
v-model.number=
"formData.sort"
type=
"number"
placeholder=
"请输入数字"
class=
"cell-input"
/>
</div>
</div>
...
@@ -44,7 +51,6 @@
...
@@ -44,7 +51,6 @@
</el-dialog>
</el-dialog>
</
template
>
</
template
>
<
script
>
<
script
>
import
{
getToken
}
from
'
@/utils/auth
'
import
{
HttpReq
}
from
'
@/api/common
'
import
{
HttpReq
}
from
'
@/api/common
'
export
default
{
export
default
{
...
@@ -64,12 +70,40 @@ export default {
...
@@ -64,12 +70,40 @@ export default {
productIdList
:
''
,
productIdList
:
''
,
supplierListPageId
:
null
supplierListPageId
:
null
},
},
rules
:
{}
rules
:
{
supplierName
:
{
validator
:
this
.
checkEnterpriseName
,
trigger
:
'
blur
'
}
}
}
}
},
},
mounted
()
{
mounted
()
{
},
},
methods
:
{
methods
:
{
checkEnterpriseName
(
rule
,
value
,
callback
)
{
this
.
$nextTick
(
_
=>
{
HttpReq
.
backstageApi
.
checkEnterpriseName
({
name
:
value
,
id
:
this
.
formData
.
customerId
}).
then
((
res
)
=>
{
if
(
res
.
data
)
{
callback
()
}
else
{
callback
(
new
Error
(
res
.
msg
))
}
})
})
},
querySearch
(
queryString
,
cb
)
{
HttpReq
.
backstageApi
.
associateQueryEnterpriseName
({
name
:
queryString
}).
then
((
res
)
=>
{
cb
(
res
.
data
)
})
},
handleSelect
(
item
)
{
this
.
formData
.
customerId
=
item
.
id
this
.
$refs
.
formViewRef
.
validateField
(
'
supplierName
'
,
valid
=>
{
return
valid
})
},
showView
()
{
showView
()
{
this
.
visible
=
true
this
.
visible
=
true
},
},
...
...
src/views/backstage/contentMgt/supplierTabulate/index.vue
View file @
4bf9f221
...
@@ -31,6 +31,7 @@
...
@@ -31,6 +31,7 @@
<el-table-column
type=
"index"
width=
"55"
label=
"序号"
:index=
"indexMethod"
/>
<el-table-column
type=
"index"
width=
"55"
label=
"序号"
:index=
"indexMethod"
/>
<el-table-column
prop=
"mark"
label=
"标识"
width=
"200"
:formatter=
"(row, col, val)=>
{return dict.label.supplier_rank[val]}" />
<el-table-column
prop=
"mark"
label=
"标识"
width=
"200"
:formatter=
"(row, col, val)=>
{return dict.label.supplier_rank[val]}" />
<el-table-column
prop=
"supplierName"
label=
"供应商名称"
/>
<el-table-column
prop=
"supplierName"
label=
"供应商名称"
/>
<el-table-column
prop=
"sort"
label=
"顺序"
width=
"100"
/>
<el-table-column
label=
"状态"
width=
"100"
>
<el-table-column
label=
"状态"
width=
"100"
>
<template
slot-scope=
"scope"
>
<template
slot-scope=
"scope"
>
<div
:style=
"'color:'+textColors[scope.row.status]"
>
{{
dict
.
label
.
issue_status
[
scope
.
row
.
status
]
}}
</div>
<div
:style=
"'color:'+textColors[scope.row.status]"
>
{{
dict
.
label
.
issue_status
[
scope
.
row
.
status
]
}}
</div>
...
...
src/views/backstage/customMgt/customTabulate/add.vue
View file @
4bf9f221
...
@@ -40,7 +40,7 @@
...
@@ -40,7 +40,7 @@
<div
class=
"cell-box"
>
<div
class=
"cell-box"
>
<el-upload
<el-upload
ref=
"uploadCom"
ref=
"uploadCom"
action=
"/api/bsw/users/up
date
BusinessLicense"
action=
"/api/bsw/users/up
load
BusinessLicense"
name=
"businessLicense"
name=
"businessLicense"
list-type=
"picture-card"
list-type=
"picture-card"
:headers=
"uploadHeaders"
:headers=
"uploadHeaders"
...
...
src/views/backstage/customMgt/customTabulate/edit.vue
View file @
4bf9f221
...
@@ -53,7 +53,7 @@
...
@@ -53,7 +53,7 @@
</el-dialog>
</el-dialog>
<el-upload
<el-upload
ref=
"uploadCom"
ref=
"uploadCom"
action=
"/api/bsw/users/up
date
BusinessLicense"
action=
"/api/bsw/users/up
load
BusinessLicense"
name=
"businessLicense"
name=
"businessLicense"
list-type=
"picture-card"
list-type=
"picture-card"
:headers=
"uploadHeaders"
:headers=
"uploadHeaders"
...
@@ -64,7 +64,9 @@
...
@@ -64,7 +64,9 @@
:on-preview=
"handlePictureCardPreview"
:on-preview=
"handlePictureCardPreview"
:on-remove=
"handleRemove"
:on-remove=
"handleRemove"
>
>
<i
class=
"el-icon-plus"
/>
<div
slot=
"trigger"
@
click=
"handlePushClick($event)"
>
<i
class=
"el-icon-plus"
/>
</div>
</el-upload>
</el-upload>
<el-dialog
append-to-body
:visible.sync=
"dialogImageVisible"
>
<el-dialog
append-to-body
:visible.sync=
"dialogImageVisible"
>
<img
width=
"100%"
:src=
"dialogImageUrl"
>
<img
width=
"100%"
:src=
"dialogImageUrl"
>
...
@@ -300,6 +302,15 @@ export default {
...
@@ -300,6 +302,15 @@ export default {
arr
.
splice
(
arr
.
indexOf
(
item
),
1
)
arr
.
splice
(
arr
.
indexOf
(
item
),
1
)
this
.
formData
.
businessLicense
=
arr
.
join
(
'
;
'
)
this
.
formData
.
businessLicense
=
arr
.
join
(
'
;
'
)
},
},
handlePushClick
(
event
)
{
if
(
this
.
formData
.
productPic
.
split
(
'
;
'
)
>=
2
)
{
event
.
stopPropagation
()
this
.
$message
({
message
:
'
超出最大上传数量限制
'
,
type
:
'
info
'
})
}
},
handleRemove
(
file
,
fileList
)
{
handleRemove
(
file
,
fileList
)
{
if
(
!
file
.
response
)
{
if
(
!
file
.
response
)
{
return
return
...
...
src/views/backstage/productMgt/productTabulate/edit.vue
View file @
4bf9f221
...
@@ -201,7 +201,9 @@
...
@@ -201,7 +201,9 @@
:on-preview=
"handlePictureCardPreview"
:on-preview=
"handlePictureCardPreview"
:on-remove=
"handleRemove"
:on-remove=
"handleRemove"
>
>
<i
class=
"el-icon-plus"
/>
<div
slot=
"trigger"
@
click=
"handlePushClick($event)"
>
<i
class=
"el-icon-plus"
/>
</div>
</el-upload>
</el-upload>
<el-dialog
append-to-body
:visible.sync=
"dialogImageVisible"
>
<el-dialog
append-to-body
:visible.sync=
"dialogImageVisible"
>
<img
width=
"100%"
:src=
"dialogImageUrl"
>
<img
width=
"100%"
:src=
"dialogImageUrl"
>
...
@@ -383,6 +385,15 @@ export default {
...
@@ -383,6 +385,15 @@ export default {
type
:
'
info
'
type
:
'
info
'
})
})
},
},
handlePushClick
(
event
)
{
if
(
this
.
formData
.
productPic
.
split
(
'
;
'
)
>=
5
)
{
event
.
stopPropagation
()
this
.
$message
({
message
:
'
超出最大上传数量限制
'
,
type
:
'
info
'
})
}
},
handleRemoveImg
(
item
)
{
handleRemoveImg
(
item
)
{
this
.
imgList
.
splice
(
this
.
imgList
.
indexOf
(
item
),
1
)
this
.
imgList
.
splice
(
this
.
imgList
.
indexOf
(
item
),
1
)
const
arr
=
this
.
formData
.
productPic
.
split
(
'
;
'
)
const
arr
=
this
.
formData
.
productPic
.
split
(
'
;
'
)
...
...
src/views/homepage/console/edit.vue
View file @
4bf9f221
...
@@ -180,7 +180,9 @@
...
@@ -180,7 +180,9 @@
:on-preview=
"handlePictureCardPreview"
:on-preview=
"handlePictureCardPreview"
:on-remove=
"handleRemove"
:on-remove=
"handleRemove"
>
>
<i
class=
"el-icon-plus"
/>
<div
slot=
"trigger"
@
click=
"handlePushClick($event)"
>
<i
class=
"el-icon-plus"
/>
</div>
</el-upload>
</el-upload>
<el-dialog
append-to-body
:visible.sync=
"dialogImageVisible"
>
<el-dialog
append-to-body
:visible.sync=
"dialogImageVisible"
>
<img
width=
"100%"
:src=
"dialogImageUrl"
>
<img
width=
"100%"
:src=
"dialogImageUrl"
>
...
@@ -384,6 +386,15 @@ export default {
...
@@ -384,6 +386,15 @@ export default {
this
.
formData
.
productPic
=
arr
.
join
(
'
;
'
)
this
.
formData
.
productPic
=
arr
.
join
(
'
;
'
)
})
})
},
},
handlePushClick
(
event
)
{
if
(
this
.
formData
.
productPic
.
split
(
'
;
'
)
>=
5
)
{
event
.
stopPropagation
()
this
.
$message
({
message
:
'
超出最大上传数量限制
'
,
type
:
'
info
'
})
}
},
handlePictureCardPreview
(
file
)
{
handlePictureCardPreview
(
file
)
{
this
.
dialogImageUrl
=
file
.
url
this
.
dialogImageUrl
=
file
.
url
this
.
dialogImageVisible
=
true
this
.
dialogImageVisible
=
true
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
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 comment