Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
R
rs-cloud-platform-ui
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
2
Merge Requests
2
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
周健威
rs-cloud-platform-ui
Commits
37612864
Commit
37612864
authored
Dec 09, 2020
by
obt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
接口修复
parent
5109062d
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
617 additions
and
45 deletions
+617
-45
singleImageX.vue
src/components/Upload/singleImageX.vue
+0
-3
index.vue
...eManagement/industryApplication/applicationCate/index.vue
+10
-5
index.vue
...nt/industryApplication/applicationList/addUpApp/index.vue
+392
-0
index.vue
...ent/industryApplication/applicationList/appList/index.vue
+210
-34
index.vue
...eManagement/industryApplication/applicationList/index.vue
+3
-2
index.vue
...s/webSiteManagement/newsCategory/nebulaDynamics/index.vue
+2
-1
No files found.
src/components/Upload/singleImageX.vue
View file @
37612864
...
...
@@ -66,7 +66,6 @@ export default {
onUploadRequest
(
data
)
{
this
.
uploading
=
true
;
let
fileObj
=
data
.
file
;
//获取图片详情信息
let
imgInfo
=
{};
let
temp
=
URL
.
createObjectURL
(
fileObj
)
...
...
@@ -78,8 +77,6 @@ export default {
}
imgInfo
.
size
=
fileObj
.
size
;
imgInfo
.
type
=
fileObj
.
type
;
// FormData 对象
let
form
=
new
FormData
();
// 文件对象
...
...
src/views/webSiteManagement/industryApplication/applicationCate/index.vue
View file @
37612864
<!--
* @Author: your name
* @Date: 2020-12-02 10:27:53
* @LastEditTime: 2020-12-0
8 17:56:34
* @LastEditTime: 2020-12-0
9 11:24:17
* @LastEditors: Please set LastEditors
* @Description: 类别管理
* @FilePath: \rs-cloud-platform-ui\src\views\webSiteManagement\industryApplication\applicationList\index.vue
...
...
@@ -446,10 +446,11 @@ export default {
message
:
"删除成功!!!"
,
type
:
'success'
});
let
index
=
this
.
tableData
.
findIndex
(
ele
=>
ele
.
id
==
type
.
id
)
if
(
index
!=-
1
){
this
.
tableData
.
splice
(
index
,
1
)
}
this
.
pullListApplicationType
()
// let index = this.tableData.findIndex(ele => ele.id == type.id)
// if(index!=-1){
// this.tableData.splice(index,1)
// }
}
else
{
this
.
$message
.
error
(
'操作失败,请稍后重试!!!'
);
}
...
...
@@ -483,6 +484,7 @@ export default {
message
:
message
,
type
:
'success'
});
this
.
pullAllApplicationType
()
}
else
{
this
.
$message
.
error
(
'操作失败,请稍后重试!!!'
);
}
...
...
@@ -491,10 +493,12 @@ export default {
changeHandleSize
(
val
)
{
// console.log(`每页 ${val} 条`);
this
.
typePagination
.
pageSize
=
val
this
.
pullListApplicationType
()
},
changeHandleCurrent
(
val
)
{
// console.log(`当前页: ${val}`);
this
.
typePagination
.
currentPage
=
val
this
.
pullListApplicationType
()
},
onPreview
(
url
){
this
.
form
.
coverImg
=
url
...
...
@@ -648,6 +652,7 @@ export default {
width
:
50px
;
height
:
50px
;
object-fit
:
cover
;
cursor
:
pointer
;
}
.operators
{
width
:
300px
;
...
...
src/views/webSiteManagement/industryApplication/applicationList/addApp/index.vue
→
src/views/webSiteManagement/industryApplication/applicationList/add
Up
App/index.vue
View file @
37612864
<!--
* @Author: your name
* @Date: 2020-12-04 09:09:37
* @LastEditTime: 2020-12-0
4 13:59:2
5
* @LastEditTime: 2020-12-0
9 11:34:1
5
* @LastEditors: Please set LastEditors
* @Description: In User Settings Edit
* @FilePath: \rs-cloud-platform-ui\src\views\webSiteManagement\industryApplication\applicationList\addApp\index.vue
...
...
@@ -15,19 +15,19 @@
</div>
</div>
<div
class=
"content"
>
<el-form
ref=
"form"
:model=
"form"
label-width=
"120px"
>
<el-form
ref=
"form"
:
rules=
"rules"
:
model=
"form"
label-width=
"120px"
>
<div
class=
"item"
>
<div
class=
"title"
>
基本信息
</div>
<div
class=
"form"
>
<el-form-item
label=
"
*应用名称
"
>
<el-form-item
label=
"
应用名称"
prop=
"title
"
>
<el-col
:span=
"12"
>
<el-input
v-model=
"form.
nam
e"
placeholder=
"请输入应用名称"
></el-input>
<el-input
v-model=
"form.
titl
e"
placeholder=
"请输入应用名称"
></el-input>
</el-col>
</el-form-item>
<el-form-item
label=
"
*封面图
"
>
<el-form-item
label=
"
封面图"
prop=
"coverImg
"
>
<singleImageX
:value=
"form.coverImg"
@
input=
"onCoverPreview"
></singleImageX>
</el-form-item>
<el-form-item
label=
"
*详情图
"
>
<el-form-item
label=
"
详情图"
prop=
"detailImg
"
>
<singleImageX
:value=
"form.detailImg"
@
input=
"onDetailPreview"
></singleImageX>
</el-form-item>
</div>
...
...
@@ -35,53 +35,53 @@
<div
class=
"item"
>
<div
class=
"title"
>
应用参数
</div>
<div
class=
"form"
>
<el-form-item
label=
"
*行业
"
>
<el-form-item
label=
"
行业"
prop=
"industry
"
>
<el-col
:span=
"12"
>
<el-input
v-model=
"form.industry"
placeholder=
"请输入行业"
></el-input>
</el-col>
</el-form-item>
<el-form-item
label=
"
*地区
"
>
<el-form-item
label=
"
地区"
prop=
"region
"
>
<el-col
:span=
"12"
>
<el-input
v-model=
"form.region"
placeholder=
"请输入地区"
></el-input>
</el-col>
</el-form-item>
<el-form-item
label=
"
*数据采集时间
"
>
<el-form-item
label=
"
数据采集时间"
prop=
"collectTime
"
>
<el-col
:span=
"12"
>
<el-input
v-model=
"form.collectTime"
placeholder=
"请输入数据采集时间"
></el-input>
</el-col>
</el-form-item>
<el-form-item
label=
"
*数据来源
"
>
<el-form-item
label=
"
数据来源"
prop=
"origin
"
>
<el-col
:span=
"12"
>
<el-input
v-model=
"form.origin"
placeholder=
"请输入数据来源"
></el-input>
</el-col>
</el-form-item>
<el-form-item
label=
"
*成果形式
"
>
<el-form-item
label=
"
成果形式"
prop=
"achievement
"
>
<el-col
:span=
"12"
>
<el-input
v-model=
"form.achievement"
placeholder=
"请输入成果形式"
></el-input>
</el-col>
</el-form-item>
<el-form-item
label=
"
*分辨率
"
>
<el-form-item
label=
"
分辨率"
prop=
"resolvpower
"
>
<el-col
:span=
"12"
>
<el-input
v-model=
"form.resolvpower"
placeholder=
"请输入分辨率"
></el-input>
</el-col>
</el-form-item>
<el-form-item
label=
"
*是否提供样例
"
>
<el-form-item
label=
"
是否提供样例"
prop=
"isSample
"
>
<el-radio-group
v-model=
"form.isSample"
>
<el-radio-button
label=
"是"
></el-radio-button>
<el-radio-button
label=
"否"
></el-radio-button>
</el-radio-group>
</el-form-item>
<el-form-item
label=
"
*是否提供定制
"
>
<el-form-item
label=
"
是否提供定制"
prop=
"isCustomized
"
>
<el-radio-group
v-model=
"form.isCustomized"
>
<el-radio-button
label=
"是"
></el-radio-button>
<el-radio-button
label=
"否"
></el-radio-button>
<el-radio-button
label=
"否"
></el-radio-button>
</el-radio-group>
</el-form-item>
<el-form-item
label=
"
*上传样例
"
>
<el-form-item
label=
"
上传样例"
prop=
"fileList
"
>
<el-upload
class=
"upload-demo"
action=
"#"
:auto-upload=
"false"
:on-preview=
"handlePreview"
:on-remove=
"handleRemove"
:before-remove=
"beforeRemove"
multiple
:limit=
"100"
:on-exceed=
"handleExceed"
:http-request=
"onUploadRequest"
:file-list=
"form.fileList"
>
<el-button
size=
"small"
type=
"primary"
>
点击上传
</el-button>
<
div
slot=
"tip"
class=
"el-upload__tip"
>
只能上传jpg/png文件,且不超过500kb
</div
>
<el-button
size=
"small"
type=
"primary"
>
上传文件
</el-button>
<
!--
<div
slot=
"tip"
class=
"el-upload__tip"
>
只能上传jpg/png文件,且不超过500kb
</div>
--
>
</el-upload>
</el-form-item>
</div>
...
...
@@ -89,8 +89,8 @@
<div
class=
"item"
>
<div
class=
"title"
>
应用简介
</div>
<div
class=
"form"
>
<el-form-item
label=
"
*产品简介
"
>
<kind-editor
id=
"editor_id"
:content
.
sync=
"form.
editorText"
:afterChange=
"afterChange()"
:loadStyleMode=
"false"
@
on-content-change=
"onContentChange"
></kind-editor>
<el-form-item
label=
"
产品简介"
prop=
"introduction
"
>
<kind-editor
id=
"editor_id"
:content
.
sync=
"form.
introduction"
:afterChange=
"afterChange()"
:loadStyleMode=
"false"
@
on-content-change=
"onContentChange"
></kind-editor>
</el-form-item>
</div>
</div>
...
...
@@ -106,6 +106,9 @@
<
script
>
import
singleImageX
from
'@/components/Upload/singleImageX'
;
import
KindEditor
from
"@/components/Kindeditor"
;
import
{
addUpdateApplicationInfo
}
from
"api/website/industryApplication/index"
;
export
default
{
name
:
'addApp'
,
components
:
{
...
...
@@ -114,24 +117,74 @@ export default {
},
data
(){
return
{
rules
:{
//title coverImg detailImg industry region collectTime origin achievement resolvpower isSample isCustomized fileList introduction
title
:
[{
required
:
true
,
message
:
'请输入应用名称'
,
trigger
:
'blur'
}],
coverImg
:
[{
required
:
true
,
message
:
'请上传封面图'
,
trigger
:
'blur'
}],
detailImg
:
[{
required
:
true
,
message
:
'请上传详情图'
,
trigger
:
'blur'
}],
industry
:
[{
required
:
true
,
message
:
'请输入行业'
,
trigger
:
'blur'
}],
region
:
[{
required
:
true
,
message
:
'请输入地区'
,
trigger
:
'blur'
}],
collectTime
:
[{
required
:
true
,
message
:
'请输入数据采集时间'
,
trigger
:
'blur'
}],
origin
:
[{
required
:
true
,
message
:
'请输入数据来源'
,
trigger
:
'blur'
}],
achievement
:
[{
required
:
true
,
message
:
'请输入成果形式'
,
trigger
:
'blur'
}],
resolvpower
:
[{
required
:
true
,
message
:
'请输入分辨率'
,
trigger
:
'blur'
}],
isSample
:
[{
required
:
true
,
message
:
'是否提供样例'
,
trigger
:
'blur'
}],
isCustomized
:
[{
required
:
true
,
message
:
'是否提供定制'
,
trigger
:
'blur'
}],
fileList
:
[{
required
:
true
,
message
:
'请上传样例'
,
trigger
:
'blur'
}],
introduction
:
[{
required
:
true
,
message
:
'请输入产品简介'
,
trigger
:
'blur'
}],
},
form
:
{
name
:
''
,
coverImg
:
''
,
detailImg
:
''
,
industry
:
''
,
region
:
''
,
collectTime
:
''
,
origin
:
''
,
achievement
:
''
,
resolvpower
:
''
,
isSample
:
'是'
,
isCustomized
:
'是'
,
fileList
:
[],
editorText
:
''
,
// 双向同步的变量
title
:
''
,
// 应用名称
coverImg
:
''
,
// 封面图
detailImg
:
''
,
// 详情图
industry
:
''
,
// 行业
region
:
''
,
// 地区
collectTime
:
''
,
// 采集时间
origin
:
''
,
// 数据来源
achievement
:
''
,
// 成果形式
resolvpower
:
''
,
// 分辨率
isSample
:
'是'
,
// 是否提供样例
isCustomized
:
'是'
,
// 是否定制
fileList
:
[],
// 样例图片路径集合
introduction
:
''
,
// 简介
}
}
},
mounted
()
{
if
(
!!
this
.
$parent
.
info
){
let
info
=
this
.
$parent
.
info
let
attribute
=
eval
(
"("
+
info
.
attribute
+
")"
)
console
.
log
(
"info=>"
,
info
)
console
.
log
(
"获取到的编辑数据=>"
,
attribute
)
this
.
form
.
title
=
info
.
title
this
.
form
.
coverImg
=
info
.
coverImg
this
.
form
.
detailImg
=
info
.
icon
.
url
this
.
form
.
industry
=
attribute
.
industry
this
.
form
.
region
=
attribute
.
area
this
.
form
.
collectTime
=
attribute
.
date
this
.
form
.
origin
=
attribute
.
source
this
.
form
.
achievement
=
attribute
.
achievements
this
.
form
.
resolvpower
=
attribute
.
ratio
this
.
form
.
isSample
=
info
.
examples
==
0
?
"否"
:
"是"
this
.
form
.
fileList
=
info
.
examples
!=
0
?
eval
(
"("
+
info
.
examplesJson
+
")"
):[]
this
.
form
.
introduction
=
info
.
introduction
this
.
form
.
isCustomized
=
info
.
customized
==
1
?
"是"
:
"否"
// this.form = {
// title: info.title,// 应用名称
// coverImg: info.coverImg,// 封面图
// detailImg: info.icon.url,// 详情图
// industry: attribute.industry,// 行业
// region: attribute.area,// 地区
// collectTime: attribute.date,// 采集时间
// origin: attribute.source,// 数据来源
// achievement: attribute.achievements,// 成果形式
// resolvpower: attribute.ratio,// 分辨率
// isCustomized: '是',// 是否定制
// isSample: info.examples==0?"是":"否",// 是否提供样例
// fileList: info.examples==0?eval("("+info.examplesJson+")"):[],// 样例图片路径集合
// introduction: info.introduction, // 简介
// }
}
this
.
$bus
.
$emit
(
'hideThreeRoute'
,
false
)
},
beforeDestroy
(){
...
...
@@ -148,30 +201,126 @@ export default {
this
.
$parent
.
componentName
=
'appList'
this
.
$bus
.
$emit
(
'hideThreeRoute'
,
true
)
},
// 上传样例
// 上传样例Begin
handlePreview
(
file
)
{
console
.
log
(
"handlePreview=>"
,
file
);
},
handleRemove
(
file
,
fileList
)
{
console
.
log
(
"handleRemove=>"
,
file
);
console
.
log
(
"handleRemove=>"
,
fileList
);
},
beforeRemove
(
file
,
fileList
)
{
return
this
.
$confirm
(
`确定移除
${
file
.
name
}
?`
);
},
handleExceed
(
files
,
fileList
)
{
this
.
$message
.
warning
(
`当前限制选择 3 个文件,本次选择了
${
files
.
length
}
个文件,共选择了
${
files
.
length
+
fileList
.
length
}
个文件`
);
},
onUploadRequest
(
data
)
{
console
.
log
(
"uploadData=>"
,
data
)
},
// 上传样例End
onCoverPreview
(
url
){
this
.
form
.
coverImg
=
url
},
onDetailPreview
(
url
){
this
.
form
.
detailImg
=
url
},
handleRemove
(
file
,
fileList
)
{
console
.
log
(
file
,
fileList
);
},
handlePreview
(
file
)
{
console
.
log
(
file
);
},
handleExceed
(
files
,
fileList
)
{
this
.
$message
.
warning
(
`当前限制选择 3 个文件,本次选择了
${
files
.
length
}
个文件,共选择了
${
files
.
length
+
fileList
.
length
}
个文件`
);
},
beforeRemove
(
file
,
fileList
)
{
return
this
.
$confirm
(
`确定移除
${
file
.
name
}
?`
);
},
onSubmit
()
{
console
.
log
(
'submit!'
);
if
(
this
.
form
.
title
==
''
){
this
.
$message
.
error
(
'请输入应用名称!!!'
);
}
else
if
(
this
.
form
.
coverImg
==
''
){
this
.
$message
.
error
(
'请上传封面图!!!'
);
}
else
if
(
this
.
detailImg
==
''
){
this
.
$message
.
error
(
'请上传详情图!!!'
);
}
else
if
(
this
.
form
.
introduction
==
''
){
this
.
$message
.
error
(
'请输入产品简介!!!'
);
}
else
if
(
this
.
form
.
industry
==
''
){
this
.
$message
.
error
(
'请输入行业!!!'
);
}
else
if
(
this
.
form
.
region
==
''
){
this
.
$message
.
error
(
'请输入地区!!!'
);
}
else
if
(
this
.
form
.
achievement
==
''
){
this
.
$message
.
error
(
'请输入成果形式!!!'
);
}
else
if
(
this
.
form
.
origin
==
''
){
this
.
$message
.
error
(
'请输入数据来源!!!'
);
}
else
if
(
this
.
form
.
collectTime
==
''
){
this
.
$message
.
error
(
'请输入数据采集时间!!!'
);
}
else
if
(
this
.
form
.
resolvpower
==
''
){
this
.
$message
.
error
(
'请输入分辨率!!!'
);
}
else
if
(
this
.
form
.
isSample
==
"是"
&&
this
.
form
.
fileList
.
length
==
0
){
this
.
$message
.
error
(
'请上传样例!!!'
);
}
else
{
let
data
,
message
if
(
this
.
$parent
.
info
){
data
=
{
id
:
this
.
$parent
.
info
.
id
,
title
:
this
.
form
.
title
,
coverImg
:
this
.
form
.
coverImg
,
detailImg
:
this
.
form
.
detailImg
,
introduction
:
this
.
form
.
introduction
,
attribute
:
JSON
.
stringify
({
industry
:
this
.
form
.
industry
,
area
:
this
.
form
.
region
,
achievements
:
this
.
form
.
achievement
,
source
:
this
.
form
.
origin
,
date
:
this
.
form
.
collectTime
,
ratio
:
this
.
form
.
resolvpower
}),
examples
:
this
.
form
.
isSample
==
"是"
?
1
:
0
,
examplesJson
:
JSON
.
stringify
(
this
.
form
.
fileList
),
protection
:
this
.
$parent
.
protection
,
rank
:
this
.
$parent
.
info
.
rank
,
status
:
this
.
$parent
.
info
.
status
,
firstTypeId
:
this
.
$parent
.
info
.
firstTypeId
,
firstTitle
:
this
.
$parent
.
info
.
firstTitle
,
secondTypeId
:
this
.
$parent
.
info
.
secondTypeId
,
secondTitle
:
this
.
$parent
.
info
.
secondTitle
,
indexShow
:
this
.
$parent
.
info
.
indexShow
,
isDel
:
this
.
$parent
.
info
.
isDel
,
customized
:
this
.
form
.
isCustomized
==
"是"
?
1
:
2
,
}
message
=
"修改成功!!!"
}
else
{
data
=
{
title
:
this
.
form
.
title
,
coverImg
:
this
.
form
.
coverImg
,
detailImg
:
this
.
form
.
detailImg
,
introduction
:
this
.
form
.
introduction
,
attribute
:
JSON
.
stringify
({
industry
:
this
.
form
.
industry
,
area
:
this
.
form
.
region
,
achievements
:
this
.
form
.
achievement
,
source
:
this
.
form
.
origin
,
date
:
this
.
form
.
collectTime
,
ratio
:
this
.
form
.
resolvpower
}),
examples
:
this
.
form
.
isSample
==
"是"
?
1
:
0
,
examplesJson
:
JSON
.
stringify
(
this
.
form
.
fileList
),
protection
:
""
,
indexShow
:
1
,
isDel
:
0
,
status
:
1
,
rank
:
0
,
firstTypeId
:
0
,
firstTitle
:
""
,
secondTypeId
:
0
,
secondTitle
:
""
,
customized
:
this
.
form
.
isCustomized
==
"是"
?
1
:
2
}
message
=
"添加成功!!!"
}
addUpdateApplicationInfo
(
data
).
then
(
res
=>
{
if
(
res
.
status
==
200
){
this
.
$message
({
message
:
message
,
type
:
'success'
});
this
.
$parent
.
componentName
=
"appList"
this
.
$parent
.
info
=
null
}
else
{
this
.
$message
.
error
(
'操作失败,请稍后重试!!!'
);
}
});
}
}
},
}
...
...
src/views/webSiteManagement/industryApplication/applicationList/appList/index.vue
View file @
37612864
<!--
* @Author: your name
* @Date: 2020-12-02 10:27:53
* @LastEditTime: 2020-12-0
4 09:49:19
* @LastEditTime: 2020-12-0
9 11:14:00
* @LastEditors: Please set LastEditors
* @Description: In User Settings Edit
* @FilePath: \rs-cloud-platform-ui\src\views\webSiteManagement\industryApplication\applicationList\index.vue
...
...
@@ -54,7 +54,7 @@
</div>
</div>
<div
class=
"addApp"
>
<div
class=
"add"
@
click
=
"$parent.componentName = 'addApp'
"
>
<div
class=
"add"
@
click
.
stop=
"addApp
"
>
新增应用
</div>
</div>
...
...
@@ -69,12 +69,12 @@
</el-table-column>
<el-table-column
label=
"应用类别"
width=
"200"
align=
"center"
>
<
template
slot-scope=
"scope"
>
<span>
{{
scope
.
row
.
type
}}
</span>
<span>
{{
getAttributeIndustry
(
scope
.
row
.
attribute
)
}}
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"应用名称"
align=
"center"
>
<
template
slot-scope=
"scope"
>
<span
class=
"introduce"
>
{{
scope
.
row
.
nam
e
}}
</span>
<span
class=
"introduce"
>
{{
scope
.
row
.
titl
e
}}
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"详情图"
align=
"center"
>
...
...
@@ -90,12 +90,12 @@
</el-table-column>
<el-table-column
label=
"发布时间"
width=
"150"
align=
"center"
>
<
template
slot-scope=
"scope"
>
<span>
{{
scope
.
row
.
dat
e
}}
</span>
<span>
{{
scope
.
row
.
crtTim
e
}}
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"状态"
width=
"150"
align=
"center"
>
<
template
slot-scope=
"scope"
>
<span>
{{
scope
.
row
.
status
}}
</span>
<span>
{{
scope
.
row
.
status
==
1
?
"上架"
:
"下架"
}}
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"操作"
width=
"150"
align=
"center"
>
...
...
@@ -103,15 +103,27 @@
<!--
<span>
{{
scope
.
row
.
operator
}}
</span>
-->
<span>
<div
class=
"operators"
>
<div
class=
"edit"
>
编辑
</div>
<div
class=
"offshelf"
>
下架
</div>
<div
class=
"delete"
>
删除
</div>
<div
class=
"edit"
@
click
.
stop=
"editApp(scope.row)"
>
编辑
</div>
<div
class=
"offshelf"
v-if=
"scope.row.status==1"
@
click
.
stop=
"changeInfoStatus(scope.row)"
>
下架
</div>
<div
class=
"upshelf"
v-else
@
click
.
stop=
"changeInfoStatus(scope.row)"
>
上架
</div>
<div
class=
"delete"
@
click
.
stop=
"delInfo(scope.row)"
>
删除
</div>
</div>
</span>
</
template
>
</el-table-column>
</el-table>
</div>
<div
class=
"infoPagination"
v-show=
"infoPagination"
>
<el-pagination
@
size-change=
"handleSizeChange"
@
current-change=
"handleCurrentChange"
:current-page
.
sync=
"infoPagination.currentPage"
:page-sizes=
"[10, 20, 30, 40]"
:page-size=
"infoPagination.pageSize"
layout=
"total, sizes, prev, pager, next, jumper"
:total=
"infoPagination.total"
>
</el-pagination>
</div>
<!-- 使用图片查看器预览当前缩略图 -->
<el-image-viewer
v-if=
"currentIcon.showPreview"
...
...
@@ -130,6 +142,8 @@ import {
getAllApplicationType
,
getListApplicationType
,
addUpdateApplicationType
,
getListApplicationInfo
,
addUpdateApplicationInfo
}
from
"api/website/industryApplication/index"
;
export
default
{
name
:
"ApplicationList"
,
...
...
@@ -153,51 +167,204 @@ export default {
//所有状态
status
:
[
{
value
:
"
1
"
,
value
:
""
,
label
:
"全部"
,
},
{
value
:
"
2
"
,
value
:
"
1
"
,
label
:
"上架"
,
},
{
value
:
"
3
"
,
value
:
"
2
"
,
label
:
"下架"
,
},
],
currentStatus
:
""
,
// 所有类别
types
:
[
{
value
:
"
1
"
,
value
:
""
,
label
:
"全部"
,
},
{
value
:
"2"
,
label
:
"数字农业"
,
},
],
currentType
:
"全部"
,
currentStatus
:
"全部"
,
currentType
:
""
,
// 表格数据
tableDataCache
:
[],
tableData
:
[
{
id
:
"1"
,
type
:
"类别"
,
name
:
"名称"
,
icon
:
{
url
:
"https://onemap.obtdata.com/wx/download/world.png"
,
showPreview
:
false
,
},
date
:
"发布时间"
,
status
:
"状态"
,
},
//
{
//
id: "1",
//
type: "类别",
//
name: "名称",
//
icon: {
//
url: "https://onemap.obtdata.com/wx/download/world.png",
//
showPreview: false,
//
},
//
date: "发布时间",
//
status: "状态",
//
},
],
infoPagination
:
{
currentPage
:
1
,
// 当前页码
pageSize
:
10
,
// 每页查询数量
total
:
0
,
// 总记录数量
},
};
},
mounted
()
{},
mounted
()
{
this
.
pullListApplicationInfo
()
},
methods
:
{
getAttributeIndustry
(
attribute
){
return
eval
(
"("
+
attribute
+
")"
).
industry
},
editApp
(
info
){
this
.
$parent
.
componentName
=
'addApp'
this
.
$parent
.
info
=
info
},
addApp
(){
this
.
$parent
.
componentName
=
'addApp'
this
.
$parent
.
info
=
null
},
// 分页获取应用详情数据
pullListApplicationInfo
(){
getListApplicationInfo
({
page
:
this
.
infoPagination
.
currentPage
,
limit
:
this
.
infoPagination
.
pageSize
}).
then
(
res
=>
{
if
(
res
.
status
==
200
){
console
.
log
(
"分页获取到的数据=>"
,
res
)
this
.
tableDataCache
=
[]
this
.
tableData
=
[]
this
.
infoPagination
.
total
=
res
.
data
.
totalCount
res
.
data
.
data
.
forEach
(
element
=>
{
this
.
tableDataCache
.
push
(
element
)
});
this
.
tableDataCache
.
forEach
(
element
=>
{
// 未被删除的
if
(
element
.
isDel
==
0
){
this
.
tableData
.
push
({
attribute
:
element
.
attribute
,
examples
:
element
.
examples
,
examplesJson
:
element
.
examplesJson
,
id
:
element
.
id
,
indexShow
:
element
.
indexShow
,
introduction
:
element
.
introduction
,
isDel
:
element
.
isDel
,
protection
:
element
.
protection
,
rank
:
element
.
rank
,
firstTypeId
:
element
.
firstTypeId
,
firstTitle
:
element
.
firstTitle
,
secondTypeId
:
element
.
secondTypeId
,
secondTitle
:
element
.
secondTitle
,
title
:
element
.
title
,
coverImg
:
element
.
coverImg
,
icon
:
{
url
:
element
.
detailImg
,
showPreview
:
false
,
},
crtTime
:
element
.
crtTime
,
status
:
element
.
status
,
updTime
:
element
.
updTime
,
customized
:
element
.
customized
,
});
}
});
}
})
},
// 删除应用详情
delInfo
(
info
){
this
.
$confirm
(
'确定继续执行该操作吗?'
,
'提示'
,
{
confirmButtonText
:
'确定'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
}).
then
(()
=>
{
let
data
=
{
id
:
info
.
id
,
title
:
info
.
title
,
coverImg
:
info
.
coverImg
,
detailImg
:
info
.
icon
.
url
,
introduction
:
info
.
introduction
,
attribute
:
info
.
attribute
,
examples
:
info
.
examples
,
examplesJson
:
info
.
examplesJson
,
protection
:
info
.
protection
,
rank
:
info
.
rank
,
status
:
info
.
status
,
firstTypeId
:
info
.
firstTypeId
,
secondTypeId
:
info
.
secondTypeId
,
indexShow
:
info
.
indexShow
,
firstTitle
:
info
.
firstTitle
,
secondTitle
:
info
.
secondTitle
,
isDel
:
"1"
,
customized
:
info
.
customized
,
}
console
.
log
(
"删除data=>"
,
data
)
addUpdateApplicationInfo
(
data
).
then
(
res
=>
{
if
(
res
.
status
==
200
){
this
.
$message
({
message
:
"删除成功!!!"
,
type
:
'success'
});
this
.
pullListApplicationInfo
()
}
else
{
this
.
$message
.
error
(
'操作失败,请稍后重试!!!'
);
}
});
})
},
// 上下架数据
changeInfoStatus
(
info
){
console
.
log
(
"info=>"
,
info
)
let
message
=
""
if
(
info
.
status
==
1
){
// 当前为上架
info
.
status
=
2
message
=
"下架成功!!!"
}
else
{
info
.
status
=
1
message
=
"上架成功!!!"
}
addUpdateApplicationInfo
({
id
:
info
.
id
,
title
:
info
.
title
,
coverImg
:
info
.
coverImg
,
detailImg
:
info
.
icon
.
url
,
introduction
:
info
.
introduction
,
attribute
:
info
.
attribute
,
examples
:
info
.
examples
,
examplesJson
:
info
.
examplesJson
,
protection
:
info
.
protection
,
rank
:
info
.
rank
,
status
:
info
.
status
,
firstTypeId
:
info
.
firstTypeId
,
secondTypeId
:
info
.
secondTypeId
,
indexShow
:
info
.
indexShow
,
firstTitle
:
info
.
firstTitle
,
secondTitle
:
info
.
secondTitle
,
customized
:
info
.
customized
,
}).
then
(
res
=>
{
if
(
res
.
status
==
200
){
this
.
$message
({
message
:
message
,
type
:
'success'
});
}
else
{
this
.
$message
.
error
(
'操作失败,请稍后重试!!!'
);
}
});
},
handleSizeChange
(
val
)
{
// console.log(`每页 ${val} 条`);
this
.
infoPagination
.
pageSize
=
val
this
.
pullListApplicationInfo
()
},
handleCurrentChange
(
val
)
{
// console.log(`当前页: ${val}`);
this
.
infoPagination
.
currentPage
=
val
this
.
pullListApplicationInfo
()
},
onPreview
(
url
){
this
.
form
.
coverImg
=
url
this
.
form
.
coverImg
=
url
},
showPreview
(
icon
)
{
this
.
currentIcon
=
icon
;
...
...
@@ -297,6 +464,7 @@ export default {
width
:
50px
;
height
:
50px
;
object-fit
:
cover
;
cursor
:
pointer
;
}
.operators
{
width
:
300px
;
...
...
@@ -306,6 +474,7 @@ export default {
justify-content
:
space-around
;
align-items
:
center
;
.edit
,
.upshelf
,
.offshelf
,
.delete
{
width
:
auto
;
...
...
@@ -316,15 +485,22 @@ export default {
align-items
:
center
;
cursor
:
pointer
;
}
.edit
,
.offshelf
{
.edit
,
.upshelf
{
color
:
#1890ff
;
}
.offshelf
{
color
:
#A6A9AD
;
}
.delete
{
color
:
#fe4066
;
}
}
}
}
.infoPagination
{
margin
:
1%
1%
0
1%
;
width
:
98%
;
height
:
auto
;
}
}
</
style
>
\ No newline at end of file
src/views/webSiteManagement/industryApplication/applicationList/index.vue
View file @
37612864
<!--
* @Author: your name
* @Date: 2020-12-02 10:27:53
* @LastEditTime: 2020-12-0
8 14:32:42
* @LastEditTime: 2020-12-0
9 09:43:51
* @LastEditors: Please set LastEditors
* @Description: 应用详情
* @FilePath: \rs-cloud-platform-ui\src\views\webSiteManagement\industryApplication\applicationList\index.vue
...
...
@@ -16,7 +16,7 @@
<
script
>
import
appList
from
'./appList/index'
import
addApp
from
'./addApp/index'
import
addApp
from
'./add
Up
App/index'
export
default
{
name
:
'Container'
,
components
:
{
...
...
@@ -26,6 +26,7 @@ export default {
data
(){
return
{
componentName
:
"appList"
,
info
:
null
,
}
},
mounted
()
{
...
...
src/views/webSiteManagement/newsCategory/nebulaDynamics/index.vue
View file @
37612864
<!--
* @Author: Jenkins
* @Date: 2020-12-01 09:54:12
* @LastEditTime: 2020-12-0
8 14:24:04
* @LastEditTime: 2020-12-0
9 11:14:35
* @LastEditors: Please set LastEditors
* @Description: 星云动态
* @FilePath: \rs-cloud-platform-ui\src\views\webSiteManagement\newsCategory\index.vue
...
...
@@ -1031,6 +1031,7 @@ export default {
width
:
50px
;
height
:
50px
;
object-fit
:
cover
;
cursor
:
pointer
;
}
.operators
{
width
:
300px
;
...
...
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