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
4983776b
Commit
4983776b
authored
Dec 10, 2020
by
obt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
代码更新
parent
dc25d190
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
53 additions
and
45 deletions
+53
-45
index.vue
...s/webSiteManagement/newsCategory/nebulaDynamics/index.vue
+37
-37
index.vue
...iews/webSiteManagement/newsCategory/newsCreator/index.vue
+16
-8
No files found.
src/views/webSiteManagement/newsCategory/nebulaDynamics/index.vue
View file @
4983776b
<!--
<!--
* @Author: Jenkins
* @Author: Jenkins
* @Date: 2020-12-01 09:54:12
* @Date: 2020-12-01 09:54:12
* @LastEditTime: 2020-12-10 14:
06:42
* @LastEditTime: 2020-12-10 14:
46:34
* @LastEditors: Please set LastEditors
* @LastEditors: Please set LastEditors
* @Description: 星云动态
* @Description: 星云动态
* @FilePath: \rs-cloud-platform-ui\src\views\webSiteManagement\newsCategory\index.vue
* @FilePath: \rs-cloud-platform-ui\src\views\webSiteManagement\newsCategory\index.vue
...
@@ -45,7 +45,7 @@
...
@@ -45,7 +45,7 @@
<span>
{{
scope
.
row
.
id
}}
</span>
<span>
{{
scope
.
row
.
id
}}
</span>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
<el-table-column
label=
"类型名称
(中文)
"
align=
"center"
>
<el-table-column
label=
"类型名称"
align=
"center"
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
<span>
{{
scope
.
row
.
name
}}
</span>
<span>
{{
scope
.
row
.
name
}}
</span>
</
template
>
</
template
>
...
@@ -85,7 +85,7 @@
...
@@ -85,7 +85,7 @@
<!-- 编辑类型弹框 -->
<!-- 编辑类型弹框 -->
<el-dialog
<el-dialog
width=
"40%"
width=
"40%"
title=
"
添加
类型"
title=
"
编辑
类型"
:visible
.
sync=
"typeEditorVisible"
:visible
.
sync=
"typeEditorVisible"
append-to-body
append-to-body
>
>
...
@@ -95,12 +95,12 @@
...
@@ -95,12 +95,12 @@
<el-col
:span=
"14"
>
<el-col
:span=
"14"
>
<el-input
<el-input
v-model=
"editorType.name"
v-model=
"editorType.name"
placeholder=
"请输入类型名称
(中文)
"
placeholder=
"请输入类型名称"
size=
"100px"
size=
"100px"
></el-input>
></el-input>
</el-col>
</el-col>
</div>
</div>
<div
class=
"content"
>
<
!-- <
div class="content">
<span>*英文名称</span>
<span>*英文名称</span>
<el-col :span="14">
<el-col :span="14">
<el-input
<el-input
...
@@ -108,7 +108,7 @@
...
@@ -108,7 +108,7 @@
placeholder="请输入类型名称(英文)"
placeholder="请输入类型名称(英文)"
></el-input>
></el-input>
</el-col>
</el-col>
</div>
</div>
-->
<div
class=
"content"
>
<div
class=
"content"
>
<span>
*类型排序
</span>
<span>
*类型排序
</span>
<el-col
:span=
"14"
>
<el-col
:span=
"14"
>
...
@@ -119,7 +119,7 @@
...
@@ -119,7 +119,7 @@
</el-col>
</el-col>
</div>
</div>
<div
class=
"operators"
>
<div
class=
"operators"
>
<div
class=
"cancel"
@
click
.
stop=
"
typeEditorVisible = false
"
>
取消
</div>
<div
class=
"cancel"
@
click
.
stop=
"
cancelEditor
"
>
取消
</div>
<div
class=
"confirm"
@
click
.
stop=
"confirmEditor"
>
确定
</div>
<div
class=
"confirm"
@
click
.
stop=
"confirmEditor"
>
确定
</div>
</div>
</div>
</div>
</div>
...
@@ -127,7 +127,7 @@
...
@@ -127,7 +127,7 @@
<!-- 添加类型弹框 -->
<!-- 添加类型弹框 -->
<el-dialog
<el-dialog
width=
"40%"
width=
"40%"
title=
"
编辑
类型"
title=
"
添加
类型"
:visible
.
sync=
"typeCreatorVisible"
:visible
.
sync=
"typeCreatorVisible"
append-to-body
append-to-body
>
>
...
@@ -137,12 +137,12 @@
...
@@ -137,12 +137,12 @@
<el-col
:span=
"14"
>
<el-col
:span=
"14"
>
<el-input
<el-input
v-model=
"newType"
v-model=
"newType"
placeholder=
"请输入类型名称
(中文)
"
placeholder=
"请输入类型名称"
size=
"100px"
size=
"100px"
></el-input>
></el-input>
</el-col>
</el-col>
</div>
</div>
<div
class=
"content"
>
<div
class=
"content"
>
<span>
*类型排序
</span>
<span>
*类型排序
</span>
<el-col
:span=
"14"
>
<el-col
:span=
"14"
>
<el-input
<el-input
...
@@ -218,7 +218,7 @@
...
@@ -218,7 +218,7 @@
>
>
<el-table-column
label=
"序号"
width=
"100"
align=
"center"
>
<el-table-column
label=
"序号"
width=
"100"
align=
"center"
>
<
template
slot-scope=
"scope"
>
<
template
slot-scope=
"scope"
>
<span>
{{
scope
.
row
.
i
ndex
}}
</span>
<span>
{{
scope
.
row
.
i
d
}}
</span>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
<el-table-column
label=
"资讯标题"
align=
"center"
>
<el-table-column
label=
"资讯标题"
align=
"center"
>
...
@@ -670,8 +670,8 @@ export default {
...
@@ -670,8 +670,8 @@ export default {
if
(
this
.
currentSort
==
1
){
if
(
this
.
currentSort
==
1
){
// 按降序
// 按降序
this
.
tableData
.
sort
((
obj1
,
obj2
)
=>
{
this
.
tableData
.
sort
((
obj1
,
obj2
)
=>
{
let
val1
=
parseInt
((
obj1
.
i
ndex
+
""
))
let
val1
=
parseInt
((
obj1
.
i
d
+
""
))
let
val2
=
parseInt
((
obj2
.
i
ndex
+
""
))
let
val2
=
parseInt
((
obj2
.
i
d
+
""
))
if
(
val1
<
val2
){
if
(
val1
<
val2
){
return
1
return
1
}
else
if
(
val1
>
val2
){
}
else
if
(
val1
>
val2
){
...
@@ -683,8 +683,8 @@ export default {
...
@@ -683,8 +683,8 @@ export default {
}
else
{
}
else
{
// 按升序
// 按升序
this
.
tableData
.
sort
((
obj1
,
obj2
)
=>
{
this
.
tableData
.
sort
((
obj1
,
obj2
)
=>
{
let
val1
=
parseInt
((
obj1
.
i
ndex
+
""
))
let
val1
=
parseInt
((
obj1
.
i
d
+
""
))
let
val2
=
parseInt
((
obj2
.
i
ndex
+
""
))
let
val2
=
parseInt
((
obj2
.
i
d
+
""
))
if
(
val1
<
val2
){
if
(
val1
<
val2
){
return
-
1
return
-
1
}
else
if
(
val1
>
val2
){
}
else
if
(
val1
>
val2
){
...
@@ -863,34 +863,34 @@ export default {
...
@@ -863,34 +863,34 @@ export default {
},
},
clickTypeEditor
(
type
){
clickTypeEditor
(
type
){
this
.
typeEditorVisible
=
true
this
.
typeEditorVisible
=
true
this
.
editorType
=
type
this
.
editorType
=
type
},
cancelEditor
(){
this
.
pullListNewsType
()
this
.
typeEditorVisible
=
false
},
},
// 修改类型
// 修改类型
confirmEditor
(){
confirmEditor
(){
// 中文对应
// 中文对应
if
(
/^
(?:[\u
3400-
\u
4DB5
\u
4E00-
\u
9FEA
\u
FA0E
\u
FA0F
\u
FA11
\u
FA13
\u
FA14
\u
FA1F
\u
FA21
\u
FA23
\u
FA24
\u
FA27-
\u
FA29
]
|
[\u
D840-
\u
D868
\u
D86A-
\u
D86C
\u
D86F-
\u
D872
\u
D874-
\u
D879
][\u
DC00-
\u
DFFF
]
|
\u
D869
[\u
DC00-
\u
DED6
\u
DF00-
\u
DFFF
]
|
\u
D86D
[\u
DC00-
\u
DF34
\u
DF40-
\u
DFFF
]
|
\u
D86E
[\u
DC00-
\u
DC1D
\u
DC20-
\u
DFFF
]
|
\u
D873
[\u
DC00-
\u
DEA1
\u
DEB0-
\u
DFFF
]
|
\u
D87A
[\u
DC00-
\u
DFE0
])
+$/
.
test
(
this
.
editorType
.
name
)){
if
(
/^
(?:[\u
3400-
\u
4DB5
\u
4E00-
\u
9FEA
\u
FA0E
\u
FA0F
\u
FA11
\u
FA13
\u
FA14
\u
FA1F
\u
FA21
\u
FA23
\u
FA24
\u
FA27-
\u
FA29
]
|
[\u
D840-
\u
D868
\u
D86A-
\u
D86C
\u
D86F-
\u
D872
\u
D874-
\u
D879
][\u
DC00-
\u
DFFF
]
|
\u
D869
[\u
DC00-
\u
DED6
\u
DF00-
\u
DFFF
]
|
\u
D86D
[\u
DC00-
\u
DF34
\u
DF40-
\u
DFFF
]
|
\u
D86E
[\u
DC00-
\u
DC1D
\u
DC20-
\u
DFFF
]
|
\u
D873
[\u
DC00-
\u
DEA1
\u
DEB0-
\u
DFFF
]
|
\u
D87A
[\u
DC00-
\u
DFE0
])
+$/
.
test
(
this
.
editorType
.
name
)){
// 非中文对应
if
(
this
.
editorType
.
sort
>=
0
&&
this
.
editorType
.
sort
<
10000
){
if
(
!
/^
(?:[\u
3400-
\u
4DB5
\u
4E00-
\u
9FEA
\u
FA0E
\u
FA0F
\u
FA11
\u
FA13
\u
FA14
\u
FA1F
\u
FA21
\u
FA23
\u
FA24
\u
FA27-
\u
FA29
]
|
[\u
D840-
\u
D868
\u
D86A-
\u
D86C
\u
D86F-
\u
D872
\u
D874-
\u
D879
][\u
DC00-
\u
DFFF
]
|
\u
D869
[\u
DC00-
\u
DED6
\u
DF00-
\u
DFFF
]
|
\u
D86D
[\u
DC00-
\u
DF34
\u
DF40-
\u
DFFF
]
|
\u
D86E
[\u
DC00-
\u
DC1D
\u
DC20-
\u
DFFF
]
|
\u
D873
[\u
DC00-
\u
DEA1
\u
DEB0-
\u
DFFF
]
|
\u
D87A
[\u
DC00-
\u
DFE0
])
+$/
.
test
(
this
.
editorType
.
nameEn
)){
// 上传修改
if
(
this
.
editorType
.
sort
>=
0
&&
this
.
editorType
.
sort
<
10000
){
addUpdateNewsType
({
// 上传修改
id
:
this
.
editorType
.
id
,
addUpdateNewsType
({
nameCn
:
this
.
editorType
.
name
,
id
:
this
.
editorType
.
id
,
nameEn
:
this
.
editorType
.
nameEn
,
nameCn
:
this
.
editorType
.
name
,
rank
:
this
.
editorType
.
sort
,
nameEn
:
this
.
editorType
.
nameEn
,
status
:
this
.
editorType
.
status
,
// 1启用,2不启用
rank
:
this
.
editorType
.
sort
,
isDel
:
this
.
editorType
.
isDel
,
// 0不删除,1删除
status
:
this
.
editorType
.
status
,
// 1启用,2不启用
});
isDel
:
this
.
editorType
.
isDel
,
// 0不删除,1删除
this
.
$message
({
});
message
:
'修改成功!!!'
,
this
.
$message
({
type
:
'success'
message
:
'修改成功!!!'
,
})
type
:
'success'
this
.
pullListNewsType
()
})
this
.
typeEditorVisible
=
false
this
.
typeEditorVisible
=
false
}
else
{
this
.
$message
.
error
(
'排序值不在指定范围,请输入正确的排序值!!!'
);
}
}
else
{
}
else
{
this
.
$message
.
error
(
'
英文名称不正确
!!!'
);
this
.
$message
.
error
(
'
排序值不在指定范围,请输入正确的排序值
!!!'
);
}
}
}
else
{
}
else
{
this
.
$message
.
error
(
'中文名称不正确!!!'
);
this
.
$message
.
error
(
'中文名称不正确!!!'
);
...
...
src/views/webSiteManagement/newsCategory/newsCreator/index.vue
View file @
4983776b
<!--
<!--
* @Author: Jenkins
* @Author: Jenkins
* @Date: 2020-12-02 14:49:10
* @Date: 2020-12-02 14:49:10
* @LastEditTime: 2020-12-10 1
3:04:57
* @LastEditTime: 2020-12-10 1
4:18:11
* @LastEditors: Please set LastEditors
* @LastEditors: Please set LastEditors
* @Description: 创建新闻
* @Description: 创建新闻
* @FilePath: \rs-cloud-platform-ui\src\views\webSiteManagement\newsCategory\newsCreator\index.vue
* @FilePath: \rs-cloud-platform-ui\src\views\webSiteManagement\newsCategory\newsCreator\index.vue
...
@@ -16,21 +16,21 @@
...
@@ -16,21 +16,21 @@
</div>
</div>
</div>
</div>
<div
class=
"form"
>
<div
class=
"form"
>
<el-form
ref=
"form"
:model=
"form"
label-width=
"80px"
>
<el-form
ref=
"form"
:
rules=
"rules"
:
model=
"form"
label-width=
"80px"
>
<el-form-item
label=
"
*资讯标题
"
>
<el-form-item
label=
"
资讯标题"
prop=
"title
"
>
<el-col
:span=
"12"
>
<el-col
:span=
"12"
>
<el-input
v-model=
"form.title"
placeholder=
"请输入资讯标题"
></el-input>
<el-input
v-model=
"form.title"
placeholder=
"请输入资讯标题"
></el-input>
</el-col>
</el-col>
</el-form-item>
</el-form-item>
<el-form-item
label=
"
*封面图
"
>
<el-form-item
label=
"
封面图"
prop=
"coverImg
"
>
<singleImageX
:value=
"form.coverImg"
@
input=
"onPreview"
></singleImageX>
<singleImageX
:value=
"form.coverImg"
@
input=
"onPreview"
></singleImageX>
</el-form-item>
</el-form-item>
<el-form-item
label=
"
*资讯简介
"
>
<el-form-item
label=
"
资讯简介"
prop=
"introduce
"
>
<el-col
:span=
"12"
>
<el-col
:span=
"12"
>
<el-input
v-model=
"form.introduce"
placeholder=
"请输入资讯简介"
></el-input>
<el-input
v-model=
"form.introduce"
placeholder=
"请输入资讯简介"
></el-input>
</el-col>
</el-col>
</el-form-item>
</el-form-item>
<el-form-item
label=
"
*资讯类型
"
>
<el-form-item
label=
"
资讯类型"
prop=
"region
"
>
<el-col
:span=
"8"
>
<el-col
:span=
"8"
>
<el-select
v-model=
"form.region"
placeholder=
"请选择选择资讯类型"
>
<el-select
v-model=
"form.region"
placeholder=
"请选择选择资讯类型"
>
<el-option
<el-option
...
@@ -45,12 +45,12 @@
...
@@ -45,12 +45,12 @@
</el-select>
</el-select>
</el-col>
</el-col>
</el-form-item>
</el-form-item>
<el-form-item
label=
"
*资讯详情
"
>
<el-form-item
label=
"
资讯详情"
prop=
"content
"
>
<el-col
:span=
"20"
>
<el-col
:span=
"20"
>
<kind-editor
id=
"editor_id"
:content
.
sync=
"form.content"
:afterChange=
"afterChange()"
:loadStyleMode=
"false"
@
on-content-change=
"onContentChange"
></kind-editor>
<kind-editor
id=
"editor_id"
:content
.
sync=
"form.content"
:afterChange=
"afterChange()"
:loadStyleMode=
"false"
@
on-content-change=
"onContentChange"
></kind-editor>
</el-col>
</el-col>
</el-form-item>
</el-form-item>
<el-form-item
label=
"
*排序
"
>
<el-form-item
label=
"
排序"
prop=
"sort
"
>
<el-col
:span=
"12"
>
<el-col
:span=
"12"
>
<el-input
type=
"number"
v-model=
"form.sort"
placeholder=
"请输入序号"
></el-input>
<el-input
type=
"number"
v-model=
"form.sort"
placeholder=
"请输入序号"
></el-input>
</el-col>
</el-col>
...
@@ -90,6 +90,14 @@ export default {
...
@@ -90,6 +90,14 @@ export default {
sort
:
''
,
sort
:
''
,
content
:
''
,
content
:
''
,
},
},
rules
:{
title
:
[{
required
:
true
,
message
:
'请输入资讯标题'
,
trigger
:
'blur'
}],
coverImg
:
[{
required
:
true
,
message
:
'请上传封面图'
,
trigger
:
'blur'
}],
introduce
:
[{
required
:
true
,
message
:
'请输入资讯简介'
,
trigger
:
'blur'
}],
region
:
[{
required
:
true
,
message
:
'请选择选择资讯类型'
,
trigger
:
'blur'
}],
content
:
[{
required
:
true
,
message
:
'请输入资讯详情'
,
trigger
:
'blur'
}],
sort
:
[{
required
:
true
,
message
:
'请输入序号'
,
trigger
:
'blur'
}],
},
}
}
},
},
mounted
()
{
mounted
()
{
...
...
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