Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
guns-vip
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
chenjunxiong
guns-vip
Commits
6798548d
Commit
6798548d
authored
Dec 09, 2018
by
fengshuonan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改通知管理页面
parent
fc96e812
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
37 additions
and
26 deletions
+37
-26
src/main/webapp/WEB-INF/system/notice/notice_edit.html
+7
-6
src/main/webapp/assets/modular/system/notice/notice_edit.js
+30
-20
No files found.
src/main/webapp/WEB-INF/system/notice/notice_edit.html
View file @
6798548d
@layout("/common/_dialog.html",{plugins:["sweet-alert","layer"],js:["/assets/modular/system/notice/notice_edit.js"]}){
@layout("/common/_dialog.html",{plugins:["sweet-alert","layer"
,"wangEditor"
],js:["/assets/modular/system/notice/notice_edit.js"]}){
<div
class=
"container-fluid"
>
<div
class=
"container-fluid"
>
<form
id=
"noticeForm"
\@
submit=
"submitForm"
>
<form
id=
"noticeForm"
>
<input
id=
"noticeId"
value=
"${noticeId}"
type=
"hidden"
class=
"form-control"
>
<input
id=
"noticeId"
value=
"${noticeId}"
type=
"hidden"
class=
"form-control"
>
<input
id=
"contentVal"
value=
"${content}"
type=
"hidden"
class=
"form-control"
>
<div
class=
"row"
>
<div
class=
"row"
>
<div
class=
"col-12"
>
<div
class=
"col-12"
>
<div
class=
"form-group"
>
<div
class=
"form-group"
>
<h5>
标题
<span
class=
"text-danger"
>
*
</span></h5>
<h5>
标题
<span
class=
"text-danger"
>
*
</span></h5>
<div
class=
"controls"
>
<div
class=
"controls"
>
<input
v-model=
"title"
id=
"title"
value=
"${title}"
type=
"text"
class=
"form-control"
>
<input
id=
"title"
value=
"${title}"
type=
"text"
class=
"form-control"
>
</div>
</div>
</div>
</div>
<div
class=
"form-group"
>
<div
class=
"form-group"
>
<h5>
内容
<span
class=
"text-danger"
>
*
</span></h5>
<h5>
内容
<span
class=
"text-danger"
>
*
</span></h5>
<div
class=
"controls"
>
<div
class=
"controls"
>
<
input
v-model=
"content"
id=
"content"
value=
"${content}"
type=
"text"
class=
"form-control"
>
<
div
id=
"editor"
></div
>
</div>
</div>
</div>
</div>
</div>
</div>
...
@@ -23,8 +24,8 @@
...
@@ -23,8 +24,8 @@
<div
class=
"row"
>
<div
class=
"row"
>
<div
class=
"col-6"
>
<div
class=
"col-6"
>
<div
class=
"text-xs-right"
>
<div
class=
"text-xs-right"
>
<button
class=
"btn btn-info normal-button-width"
\@
click=
"ensure
"
>
提交
</button>
<button
class=
"btn btn-info normal-button-width"
onclick=
"NoticeEditDlg.ensure()
"
>
提交
</button>
<button
class=
"btn btn-inverse normal-button-width m-l-10"
\@
click=
"close
"
>
取消
</button>
<button
class=
"btn btn-inverse normal-button-width m-l-10"
onclick=
"NoticeEditDlg.close()
"
>
取消
</button>
</div>
</div>
</div>
</div>
</div>
</div>
...
...
src/main/webapp/assets/modular/system/notice/notice_edit.js
View file @
6798548d
...
@@ -22,6 +22,10 @@ NoticeEditDlg.close = function () {
...
@@ -22,6 +22,10 @@ NoticeEditDlg.close = function () {
*/
*/
NoticeEditDlg
.
validateForm
=
function
()
{
NoticeEditDlg
.
validateForm
=
function
()
{
//接收数据
NoticeEditDlg
.
data
.
title
=
$
(
"#title"
).
val
();
NoticeEditDlg
.
data
.
content
=
NoticeEditDlg
.
editor
.
txt
.
html
();
var
data
=
NoticeEditDlg
.
data
;
var
data
=
NoticeEditDlg
.
data
;
if
(
!
data
.
title
)
{
if
(
!
data
.
title
)
{
...
@@ -50,26 +54,32 @@ NoticeEditDlg.editSubmit = function () {
...
@@ -50,26 +54,32 @@ NoticeEditDlg.editSubmit = function () {
ajax
.
start
();
ajax
.
start
();
};
};
/**
* 确认按钮
*/
NoticeEditDlg
.
ensure
=
function
()
{
var
result
=
NoticeEditDlg
.
validateForm
();
if
(
result
===
true
)
{
NoticeEditDlg
.
editSubmit
();
}
else
{
Feng
.
alert
(
result
);
}
};
/**
* 取消按钮
*/
NoticeEditDlg
.
close
=
function
()
{
NoticeEditDlg
.
close
();
};
$
(
function
()
{
$
(
function
()
{
NoticeEditDlg
.
app
=
new
Vue
({
el
:
'#noticeForm'
,
//初始化编辑器
data
:
NoticeEditDlg
.
data
,
var
E
=
window
.
wangEditor
;
methods
:
{
var
editor
=
new
E
(
'#editor'
);
submitForm
:
function
(
e
)
{
editor
.
create
();
e
.
preventDefault
();
editor
.
txt
.
html
(
$
(
"#contentVal"
).
val
());
},
NoticeEditDlg
.
editor
=
editor
;
ensure
:
function
()
{
var
result
=
NoticeEditDlg
.
validateForm
();
if
(
result
===
true
)
{
NoticeEditDlg
.
editSubmit
();
}
else
{
Feng
.
alert
(
result
);
}
},
close
:
function
()
{
NoticeEditDlg
.
close
();
}
}
});
});
});
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