Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Gelencsér Szabolcs
/
circlestack
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
4c7d268c
authored
Apr 27, 2015
by
Bach Dániel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dashboard: add preview
parent
b8e19b76
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
32 additions
and
0 deletions
+32
-0
circle/dashboard/static/dashboard/dashboard.js
+10
-0
circle/dashboard/templates/dashboard/message-edit.html
+22
-0
No files found.
circle/dashboard/static/dashboard/dashboard.js
View file @
4c7d268c
...
@@ -545,4 +545,14 @@ $(function () {
...
@@ -545,4 +545,14 @@ $(function () {
closed
.
push
(
$
(
this
).
data
(
'id'
));
closed
.
push
(
$
(
this
).
data
(
'id'
));
setCookie
(
'broadcast-messages'
,
JSON
.
stringify
(
closed
),
7
*
24
*
60
*
60
*
1000
,
"/"
);
setCookie
(
'broadcast-messages'
,
JSON
.
stringify
(
closed
),
7
*
24
*
60
*
60
*
1000
,
"/"
);
});
});
$
(
"#id_message"
).
on
(
'input'
,
function
()
{
$
(
'.broadcast-message'
).
html
(
$
(
this
).
val
());
});
$
(
"#id_effect"
).
on
(
'input'
,
function
()
{
$
(
'.broadcast-message'
).
removeClass
(
'alert-info alert-warning alert-success alert-danger'
).
addClass
(
"alert-"
+
$
(
this
).
val
());
});
});
});
circle/dashboard/templates/dashboard/message-edit.html
View file @
4c7d268c
...
@@ -31,4 +31,26 @@
...
@@ -31,4 +31,26 @@
</div>
</div>
</div>
</div>
</div>
</div>
<div
class=
"row"
>
<div
class=
"col-md-12"
>
<div
class=
"panel panel-default"
>
<div
class=
"panel-heading"
>
<h3
class=
"no-margin"
>
<i
class=
"fa fa-eye"
></i>
{% trans "Preview" %}
</h3>
</div>
<div
class=
"panel-body"
>
<div
class=
"alert alert-{{ message.effect }} text-center broadcast-message"
>
{{ message.message|safe }}
</div>
</div>
<!-- .panel-body -->
</div>
</div>
</div>
{% endblock %}
{% block broadcast_messages %}
{% endblock %}
{% endblock %}
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