home.html 13.5 KB
Newer Older
Dudás Ádám committed
1 2 3 4 5
{% extends "base.html" %}
{% load i18n %}

{% block content %}
<div class="boxes">
Danyi Bence committed
6 7 8 9
    <div class="contentblock" id="state">
        <h2>Virtuális gépek</h2>
        <ul class="wm-list">
            {% include "box-vmlist.html" %}
Danyi Bence committed
10
            <li id="new-wm-button" class="wm new">
Danyi Bence committed
11 12 13 14 15 16 17
                <div class="summary">
                    <div class="name">Új gép indítása</div>
                    <div class="clear"></div>
                </div>
            </li>
            <li id="new-wm" style="display: none">
                <h2>Rendelkezésre álló sablonok</h2>
Dányi Bence committed
18 19 20
                <p>
                    Mese, hogy mit is lehet csinálni.
                </p>
Danyi Bence committed
21 22 23 24 25 26 27 28
                <div class="container">
                    <ul class="wm-list modal">
                        {% for m in templates %}
                        <li class="wm">
                            <form method="POST" action="/vm/new/{{m.pk}}/">{% csrf_token %}
                                <div class="summary">
                                    <div class="name wm-on">{{m.name}}</div>
                                    <div class="status">
Dányi Bence committed
29
                                        3/10
Danyi Bence committed
30 31
                                    </div>
                                    <div class="clear"></div>
Danyi Bence committed
32
                                </div>
Danyi Bence committed
33 34 35 36 37 38 39 40 41
                                <div class="details">
                                    <h3>
                                        Részletek
                                    </h3>
                                    <ul>
                                        <li class="name">Rendszer: <span class="value">{{m.disk.name}}</span></li>
                                        <li class="type">Instance típus: <span class="value">{{m.instance_type.name}}</span></li>
                                        <li class="memory">Memória: <span class="value">{{m.instance_type.RAM}} MiB</span></li>
                                        <li class="cpu">CPU magok: <span class="value">{{m.instance_type.CPU}}</span></li>
Dányi Bence committed
42
                                        <li>&nbsp;<span class="value"><input type="submit" value="Indítás"/></span></li>
Danyi Bence committed
43 44 45 46 47 48 49
                                    </ul>
                                </div>
                            </form>
                        </li>
                        {% endfor %}
                    </ul>
                </div>
Danyi Bence committed
50
            </li>
Dányi Bence committed
51 52 53 54 55 56 57 58 59
            <li class="wm small">
                <div class="summary">
                    <div class="quota">
                        <div class="used" style="background-color: rgba(0,255,0,0.2); width: 0%"></div>
                    </div>
                    <div class="name">Saját Kvóta: 0/10</div>
                    <div class="clear"></div>
                </div>
            </li>
Danyi Bence committed
60 61 62 63 64
        </ul>
    </div>
    <div class="contentblock" id="template">
        <h2>Saját sablonok</h2>
        <ul class="wm-list">
Danyi Bence committed
65 66
            <li class="wm">
                <div class="summary">
Dányi Bence committed
67
                    <div class="quota">
Dányi Bence committed
68
                        <div class="used" style="background-color: rgba(0,255,0,0.2); width: 20%"></div>
Dányi Bence committed
69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91
                    </div>
                    <div class="name">Win7 Matlab</div>
                    <div class="status">2/10</div>
                    <div class="actions">
                        <a href="#" title="Átnevezés"><img src="/static/icons/pencil.png" alt="rename" /></a>
                        <a href="#" title="Törlés"><img src="/static/icons/minus-circle.png" alt="delete" /></a>
                        <a href="#" title="Megosztás"><img src="static/icons/user-share.png" alt="share" /></a>
                    </div>
                    <div class="clear"></div>
                </div>
                <div class="details">
                    <ul>
                        <li class="name">Rendszer: <span class="value">Windows 7 Desktop</span></li>
                        <li class="description">Leírás: <span class="value">Lorem ipsum dolor sit amet, consectetur adipiscing elit. Proin nibh arcu, cursus et sodales eu, iaculis id metus. Suspendisse et mauris nisi, luctus feugiat nisi. Nullam elementum tincidunt urna a luctus.</span><div class="clear"></div></li>
                        <li class="date">Létrehozva: <span class="value">2013.01.10. 13:40:22</span></li>
                        <li class="date">Módosítva: <span class="value">2013.01.10. 13:40:22</span></li>
                        <li class="count">Futó példányok: <span class="value">1 db</span></li>
                    </ul>
                </div>
            </li>
            <li class="wm">
                <div class="summary">
                    <div class="quota">
Dányi Bence committed
92
                        <div class="used" style="background-color: rgba(255,128,0,0.2); width: 70%"></div>
Dányi Bence committed
93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115
                    </div>
                    <div class="name">Win7 Matlab</div>
                    <div class="status">7/10</div>
                    <div class="actions">
                        <a href="#" title="Átnevezés"><img src="/static/icons/pencil.png" alt="rename" /></a>
                        <a href="#" title="Törlés"><img src="/static/icons/minus-circle.png" alt="delete" /></a>
                        <a href="#" title="Megosztás"><img src="static/icons/user-share.png" alt="share" /></a>
                    </div>
                    <div class="clear"></div>
                </div>
                <div class="details">
                    <ul>
                        <li class="name">Rendszer: <span class="value">Windows 7 Desktop</span></li>
                        <li class="description">Leírás: <span class="value">Lorem ipsum dolor sit amet, consectetur adipiscing elit. Proin nibh arcu, cursus et sodales eu, iaculis id metus. Suspendisse et mauris nisi, luctus feugiat nisi. Nullam elementum tincidunt urna a luctus.</span><div class="clear"></div></li>
                        <li class="date">Létrehozva: <span class="value">2013.01.10. 13:40:22</span></li>
                        <li class="date">Módosítva: <span class="value">2013.01.10. 13:40:22</span></li>
                        <li class="count">Futó példányok: <span class="value">5 db</span></li>
                    </ul>
                </div>
            </li>
            <li class="wm">
                <div class="summary">
                    <div class="quota">
Dányi Bence committed
116
                        <div class="used" style="background-color: rgba(255,0,0,0.2); width: 100%"></div>
Dányi Bence committed
117
                    </div>
Danyi Bence committed
118
                    <div class="name">Win7 Matlab</div>
Dányi Bence committed
119
                    <div class="status">10/10</div>
Danyi Bence committed
120 121 122 123 124 125 126 127 128 129 130 131 132
                    <div class="actions">
                        <a href="#" title="Átnevezés"><img src="/static/icons/pencil.png" alt="rename" /></a>
                        <a href="#" title="Törlés"><img src="/static/icons/minus-circle.png" alt="delete" /></a>
                        <a href="#" title="Megosztás"><img src="static/icons/user-share.png" alt="share" /></a>
                    </div>
                    <div class="clear"></div>
                </div>
                <div class="details">
                    <ul>
                        <li class="name">Rendszer: <span class="value">Windows 7 Desktop</span></li>
                        <li class="description">Leírás: <span class="value">Lorem ipsum dolor sit amet, consectetur adipiscing elit. Proin nibh arcu, cursus et sodales eu, iaculis id metus. Suspendisse et mauris nisi, luctus feugiat nisi. Nullam elementum tincidunt urna a luctus.</span><div class="clear"></div></li>
                        <li class="date">Létrehozva: <span class="value">2013.01.10. 13:40:22</span></li>
                        <li class="date">Módosítva: <span class="value">2013.01.10. 13:40:22</span></li>
Dányi Bence committed
133
                        <li class="count">Futó példányok: <span class="value">10 db</span></li>
Danyi Bence committed
134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152
                    </ul>
                </div>
            </li>
            <li class="wm">
                <div class="summary unfinished">
                    <div class="name">Win7 Matlab</div>
                    <div class="status">FÉLKÉSZ</div>
                    <div class="actions">
                        <a href="#" title="Átnevezés"><img src="/static/icons/pencil.png" alt="rename" /></a>
                        <a href="#" title="Törlés"><img src="/static/icons/minus-circle.png" alt="delete" /></a>
                    </div>
                    <div class="clear"></div>
                </div>
                <div class="details">
                    <ul>
                        <li class="name">Rendszer: <span class="value">Windows 7 Desktop</span></li>
                        <li class="description">Leírás: <span class="value">Lorem ipsum dolor sit amet, consectetur adipiscing elit. Proin nibh arcu, cursus et sodales eu, iaculis id metus. Suspendisse et mauris nisi, luctus feugiat nisi. Nullam elementum tincidunt urna a luctus.</span><div class="clear"></div></li>
                        <li class="date">Létrehozva: <span class="value">2013.01.10. 13:40:22</span></li>
                        <li class="date">Módosítva: <span class="value">2013.01.10. 13:40:22</span></li>
Dányi Bence committed
153
                        <li class="count">Futó példányok: <span class="value">8 db</span></li>
Danyi Bence committed
154 155 156
                    </ul>
                </div>
            </li>
Danyi Bence committed
157 158 159 160 161 162
            <li id="new-template-button" class="wm new">
                <div class="summary">
                    <div class="name">Új Sablon</div>
                    <div class="clear"></div>
                </div>
            </li>
Dányi Bence committed
163 164 165
            <li class="wm small">
                <div class="summary">
                    <div class="quota">
Dányi Bence committed
166
                        <div class="used" style="background-color: rgba(0,255,0,0.2); width: 19%"></div>
Dányi Bence committed
167
                    </div>
Dányi Bence committed
168
                    <div class="name">Elosztható Kvóta: 19/100</div>
Dányi Bence committed
169 170 171
                    <div class="clear"></div>
                </div>
            </li>
Danyi Bence committed
172 173
        </ul>
    </div>
Dudás Ádám committed
174 175 176 177 178 179 180 181 182 183 184 185
    {% for box in boxes %}
    {% if forloop.counter0|divisibleby:2 %}
        <div class="contentblock">
            <h2>{{ box.title }}</h2>
            <div class="content">
                {{ box.text|safe }}
            </div>
        </div>
    {% endif %}
    {% endfor %}
</div>
<div class="boxes">
186 187 188 189 190 191
    <div class="contentblock">
        <h2>
            Adattár
        </h2>
        <div class="content">
            <ul class="file-list">
Dányi Bence committed
192
                <li class="wm small">
193
                    <div class="summary">
Dányi Bence committed
194 195 196 197 198 199 200
                        <div class="name">Jelenlegi hely: <span data-bind="text: currentPath"></span></div>
                        <div class="clear"></div>
                    </div>
                </li>
                <li class="wm real" data-bind="visible: notInRoot, click: jumpUp">
                    <div class="summary">
                        <div class="name filetype-jump-out">
Dányi Bence committed
201
                            ..
Dányi Bence committed
202 203 204 205
                        </div>
                        <div class="clear"></div>
                    </div>
                </li>
206 207 208 209 210 211 212
                <li class="wm small real" data-bind="visible: files().length == 0">
                    <div class="summary">
                        <div class="name">Nincs megjeleníthető fájl.</div>
                        <div class="clear"></div>
                    </div>
                </li>
                <!-- ko foreach: {data:files,afterAdd:fadeIn} -->
Dányi Bence committed
213 214 215 216
                <li class="wm real">
                    <div class="summary" data-bind="click: clickHandler">
                        <div class="name" data-bind="text: name, attr: {class: getTypeClass}"></div>
                        <div class="info" data-bind="text: size"></div>
217
                        <div class="actions">
Dányi Bence committed
218 219 220 221 222 223 224 225 226
                            <a href="#">
                                <img src="/static/icons/pencil.png" alt="rename" />
                            </a>
                            <a href="#" data-bind="click: $parent.delete, clickBubble: false">
                                <img src="/static/icons/minus-circle.png" alt="delete" />
                            </a>
                            <a href="#" data-bind="click: $parent.download, clickBubble: false">
                                <img src="/static/icons/download-cloud.png" alt="download" />
                            </a>
227 228 229 230
                        </div>
                        <div class="clear"></div>
                    </div>
                    <div class="details">
Dányi Bence committed
231 232
                        <div class="details-container">
                            <ul>
Dányi Bence committed
233 234
                                <li>Módosítva: <span class="value" data-bind="text: mTime"></span></li>
                                <li>Típus: <span class="value" data-bind="text: type"></span></li>
Dányi Bence committed
235
                            </ul>
236 237 238
                        </div>
                    </div>
                </li>
Dányi Bence committed
239
                <!-- /ko -->
240 241
                <li class="file-details wm" id="load-more-files" data-bind="visible: (files().length>0 && files().length != allFiles.length)">
                    <div class="summary" data-bind="click: showMore">
242
                        <div class="name filetype-more">
243
                            Mutass több fájlt!
244 245 246 247 248 249 250 251 252 253 254 255 256
                        </div>
                        <div class="clear"></div>
                    </div>
                </li>
                <li class="file-upload wm">
                    <div class="summary">
                        <div class="name filetype-up">Fájlfeltöltés</div>
                        <div class="clear"></div>
                    </div>
                </li>
            </ul>
        </div>
    </div>
Dudás Ádám committed
257 258
</div>
{% endblock %}