Basic buttons fixed.
[redakcja.git] / project / templates / explorer / editor.html
1 {% extends "base.html" %}
2
3 {% block extrahead %}
4         <script type="text/javascript" charset="utf-8">
5                 var fileId = '{{ fileid }}';
6         </script>
7     <script src="{{STATIC_URL}}js/lib/codemirror/codemirror.js" type="text/javascript" charset="utf-8"></script>
8         
9         {# Scriptlets #}
10         <script src="http://localhost:8000/api/toolbar/scriptlets" type="text/javascript" charset="utf-8"></script>
11         
12         {# App and views #}
13         <script src="{{STATIC_URL}}js/app.js" type="text/javascript" charset="utf-8"></script>
14         <script src="{{STATIC_URL}}js/views/view.js" type="text/javascript" charset="utf-8"></script>
15         <script src="{{STATIC_URL}}js/views/editor.js" type="text/javascript" charset="utf-8"></script>
16         <script src="{{STATIC_URL}}js/views/button_toolbar.js" type="text/javascript" charset="utf-8"></script>
17         <script src="{{STATIC_URL}}js/views/split.js" type="text/javascript" charset="utf-8"></script>
18         <script src="{{STATIC_URL}}js/views/xml.js" type="text/javascript" charset="utf-8"></script>
19         <script src="{{STATIC_URL}}js/views/html.js" type="text/javascript" charset="utf-8"></script>
20         <script src="{{STATIC_URL}}js/views/panel_container.js" type="text/javascript" charset="utf-8"></script>
21         
22         <script src="{{STATIC_URL}}js/models.js" type="text/javascript" charset="utf-8"></script>
23         
24         {# JavaScript templates #}
25         <script type="text/html" charset="utf-8" id="panel-container-view-template">
26                 <select>
27                         <% for (panel in panels) { %>
28                         <option value="<%= panel %>"><%= panel %></option>
29                         <% }; %>
30                 </select>
31                 <div class="content-view"></div>
32         </script>
33         
34         <script type="text/html" charset="utf-8" id="xml-view-template">
35                 <div class="xmlview-toolbar"></div>
36                 <div class="xmlview">
37                         
38                 </div>
39         </script>
40         
41         <script type="text/html" charset="utf-8" id="html-view-template">
42                 <div class="htmlview">
43                 </div>
44         </script>
45         
46         <script type="text/html" charset="utf-8" id="button-toolbar-view-template">
47                 <div class="buttontoolbarview">
48                         <div class="buttontoolbarview-tabs">
49                         <% for (var i=0; i < buttons.length; i++) { %>
50                                 <a href="#" class="buttontoolbarview-tab" ui:groupindex="<%= i %>"><%= buttons[i].name %></a>
51                         <% }; %>
52                         </div>
53                         <div class="buttontoolbarview-groups">
54                         <% for (var i=0; i < buttons.length; i++) { %>
55                                 <div class="buttontoolbarview-group" ui:groupIndex="<%= i %>" style="display: none">
56                                         <% for (var j=0; j < buttons[i].buttons.length; j++) { %>
57                                                 <% if (buttons[i].buttons[j].scriptlet_id) { %>
58                                                 <a href="#" class="buttontoolbarview-button" ui:groupindex="<%= i %>" ui:buttonindex="<%= j %>">
59                                                         <%= buttons[i].buttons[j].label %>
60                                                 </a>
61                                                 <% } %>
62                                         <% } %>
63                                 </div>
64                         <% }; %>
65                         </div>
66                 </div>
67         </script>
68 {% endblock extrahead %}
69
70 {% block breadcrumbs %}<a href="{% url file_list %}">Platforma Redakcyjna</a> &gt; {{ fileid }}{% endblock breadcrumbs %}
71
72 {% block message-box %}
73     <div class="msg-info" id="save-waiting"><p>Zapisuję dane na serwerze.</p><p class="data"></p></div>
74     <div class="msg-success" id="save-successful"><p>Zapisano :)</p><p class="data"></p></div>
75     <div class="msg-warning" id="save-warn"><p>Zapisano. Uwagi: (</p><p class="data"></p></div>
76     <div class="msg-error" id="save-error"><p>Błąd przy zapisie.</p> <p class="data"></p></div>
77
78     <div class="msg-success" id="generic-yes"><p class="data"></p></div>
79     <div class="msg-info" id="generic-info"><p class="data"></p></div>
80     <div class="msg-error" id="generic-error"><p class="data"></p></div>
81     
82     <div class="msg-warning" id="not-implemented"><p>Tej funkcji jeszcze nie ma :(</p><p class="data"></p></div>
83     
84 {% endblock %}
85
86 {% block header-toolbar %}
87         <button>Merge</button> <button>Update</button>
88 {% endblock %}
89
90 {% block maincontent %}
91         <div id="splitview">
92                 <div id="left-panel-container" class='panel-container'></div>
93             <div id="right-panel-container" class='panel-container'></div>
94     </div>
95
96
97     {# <div id="commit-dialog" class="jqmWindow"> #}
98     {#     <form action="{% url file_commit fileid %}" method="POST"> #}
99     {#         <label for="message">Commit message:</label> #}
100     {#         <textarea cols="60" rows="10" name="message" id="commit-dialog-message"></textarea> #}
101     {#         <p id="commit-dialog-error-empty-message">Wiadomość nie może być pusta.</p>                 #}
102     {#         <fieldset id="commit-dialog-related-issues"  #}
103     {#                   ui:ajax-src="http://localhost:3000/publications/issues/{{fileid}}"> #}
104     {#             <legend>Related issues</legend> #}
105     {#             <div class="loading-box" style="display: none;"> #}
106     {#                 <p>Loading related issues...</p> #}
107     {#             </div> #}
108     {#             <div class="container-box">No related issues.</div> #}
109     {#         </fieldset> #}
110     {#         <p> #}
111     {#            <input type="button" value="Save" id="commit-dialog-save-button" /> #}
112     {#            <input type="reset" value="Cancel" id="commit-dialog-cancel-button" /> #}
113     {#         </p> #}
114     {#     </form> #}
115     {# </div> #}
116     {#  #}
117     {# <div id="split-dialog" class="jqmWindow"> #}
118     {#     <div class="container-box"> </div> #}
119     {#     <div class="loading-box" style="display: none;"> #}
120     {#         <p>Loading dialog contents...</p> #}
121     {#         <!-- <p><button type="button" class="dialog-close-button">Close</button></p> --> #}
122     {#     </div> #}
123     {#     <div class="fatal-error-box" style="display: none;"> #}
124     {#         <p>Server error, while loading dialog :(</p> #}
125     {#         <p><button type="button" class="dialog-close-button">Close</button></p> #}
126     {#     </div> #}
127     {# </div> #}
128 {% endblock maincontent %}