Revision 12269b45

b/snf-astakos-app/astakos/im/static/im/css/modules.css
402 402
.stats ul										{ margin:0; padding:0; list-style:none outside none; }
403 403
.stats ul li 									{ margin:0 0 1em 0; padding:0 0 1em 0; list-style:none outside none; background:url(../images/stats-line.jpg) repeat-x left bottom}
404 404
.stats .bar										{ padding: 0; text-align:center;  float:left; width:200px;}
405
.stats .bar div									{ width:340px; height:30px; border:1px solid #000;}
405
.stats .bar div									{ width:340px; height:30px; border:1px solid #000; margin-top:20px;}
406 406
.stats .bar span								{ text-align:right; display:block; height:100%; color:#fff;  line-height:30px; font-size:1.231em; text-indent:50px;}
407 407
.stats .red .bar span							{ background:#ef4f54; }
408 408
.stats .yellow .bar span						{ background:#f6921e; }
......
414 414
.stats .vm .img-wrap							{ background-image:url(../images/vm-stats.png) }
415 415
.stats .ram .img-wrap							{ background-image:url(../images/ram-stats.png) }
416 416
.stats .network .img-wrap						{ background-image:url(../images/network-stats.png) }
417
.stats .disk .img-wrap							{ background-image:url(../images/disk-stats.png) }
418
.stats .storage .img-wrap						{ background-image:url(../images/storage-stats.png) }
417
.stats .disksize .img-wrap							{ background-image:url(../images/disk-stats.png) }
418
.stats .diskspace .img-wrap						{ background-image:url(../images/storage-stats.png) }
419 419
.stats .bandwidth .img-wrap						{ background-image:url(../images/bandwidth-stats.png) }
420 420

  
421 421
.stats .red .img-wrap							{ background-position: 15px 7px; }
b/snf-astakos-app/astakos/im/templates/im/astakosgroup_list.html
22 22
	    </form>
23 23
	    {% else %}
24 24
    
25
		<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. <br>You can <a href="{% url group_create_list %}">create a new group</a> or <a href="{% url group_search %}">join</a> to an existing one.</p>
25
		<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. <br>You can <!--<a href="{% url group_create_list %}">create a new group</a>--> <a href="{% url group_add 'course' %}">create a new group</a>or <a href="{% url group_search %}">join</a> to an existing one.</p>
26 26
		
27 27
		<div class="widjets"> 
28 28
			<a href="#" class="widjet-x" title="remove boxes">X</a>
......
30 30
				<li>
31 31
					<div>
32 32
						<p>WELCOME!<br>Connect with a world of people who share your passions.<br>With millions of groups at your fingertips, it's easy to find the group that's best for you -- no matter your interest.</p><p style="text-align: center"><img alt="THINK ABOUT IT" src="/static/im/images/create.png"></p>
33
						<p class="btn"><a href="{% url group_create_list %}" class="submit">CREATE</a></p>
33
						<p class="btn"><a href="{% url group_add 'course' %}" class="submit">CREATE</a></p>
34
						<!--<p class="btn"><a href="{% url group_create_list %}" class="submit">CREATE</a></p>-->
34 35
					</div>
35 36
				</li>
36 37
				<li>
b/snf-astakos-app/astakos/im/templates/im/resource_list.html
7 7
    <div class="stats clearfix">
8 8
		<ul>
9 9
			{% for r in data %}
10
			 
11
    		<li class="clearfix  {{ r.load_class }} {{ r.name}}">
10
			{% with resource_presentation|lookup:r.name as resource_info %}
11
    		<li class="clearfix  {{ r.load_class }} {{ r.name|get_value_after_dot}}">
12 12
    			<div class="img-wrap">&nbsp;</div>
13 13
    			<div class="info">
14
    				<h3>{{ r.description }}</h3>
14
    				<h3>{{ resource_info.report_desc }}</h3>
15 15
    				<p>
16 16
    					{{ r.ratio|floatformat }}% Used<br>
17
    					You are using {{ r.currValue }} {{ r.unit }} out of your {{ r.maxValue }}{{ r.unit }} {{ r.plural|capfirst }} - Aouch!
17
    					You are using {{ r.currValue }} {{ r.unit }} out of your {{ r.maxValue }} {{ r.unit }} {% if resource_info.is_abbreviation %}{{ r.name|get_value_after_dot|upper }}{% else %}{{ r.name|get_value_after_dot }}{% endif %}{% if not r.unit %}s {% endif  %} 
18 18
    				</p>
19 19
    			</div>
20 20
    			<div class="bar">
21 21
    				<div><span style="width:{{ r.ratio|floatformat }}%;">{{ r.ratio|floatformat }}% &nbsp;&nbsp;</span></div>
22 22
    			</div>
23 23
    		</li>
24
    		{% endwith %}
24 25
    		{% endfor %}
25 26
    	</ul>
26 27
    </div>    
b/snf-astakos-app/astakos/im/views.py
664 664
                                                        extra_context))
665 665

  
666 666

  
667

  
668
resource_presentation = {
669
       'compute': {
670
            'help_text':'group compute help text',
671
            'is_abbreviation':False,
672
            'report_desc':''
673
        },
674
        'storage': {
675
            'help_text':'group storage help text',
676
            'is_abbreviation':False,
677
            'report_desc':''
678
        },
679
        'pithos+.diskspace': {
680
            'help_text':'resource pithos+.diskspace help text',
681
            'is_abbreviation':False,
682
            'report_desc':'Diskspace used'
683
        },
684
        'cyclades.vm': {
685
            'help_text':'resource cyclades.vm help text resource cyclades.vm help text resource cyclades.vm help text resource cyclades.vm help text',
686
            'is_abbreviation':True,
687
            'report_desc':'Number of Virtual Machines'
688
        },
689
        'cyclades.disksize': {
690
            'help_text':'resource cyclades.disksize help text',
691
            'is_abbreviation':False,
692
            'report_desc':'Amount of Disksize used'
693
        },
694
        'cyclades.ram': {
695
            'help_text':'resource cyclades.ram help text',
696
            'is_abbreviation':True,
697
            'report_desc':'RAM used'
698
        },
699
        'cyclades.cpu': {
700
            'help_text':'resource cyclades.cpu help text',
701
            'is_abbreviation':True,
702
            'report_desc':'CPUs used'
703
        }
704
    }
705

  
667 706
@require_http_methods(["GET", "POST"])
668 707
@signed_terms_required
669 708
@login_required
......
695 734
    except:
696 735
        return HttpResponseBadRequest(_('No such group kind'))
697 736
    
698
    resource_presentation = {
699
       'compute': {
700
            'help_text':'group compute help text',
701
        },
702
        'storage': {
703
            'help_text':'group storage help text',
704
        },
705
        'pithos+.diskspace': {
706
            'help_text':'resource pithos+.diskspace help text',
707
            'is_abbreviation':False,
708
        },
709
        'cyclades.vm': {
710
            'help_text':'resource cyclades.vm help text resource cyclades.vm help text resource cyclades.vm help text resource cyclades.vm help text',
711
            'is_abbreviation':True,
712
        },
713
        'cyclades.disksize': {
714
            'help_text':'resource cyclades.disksize help text',
715
            'is_abbreviation':False,
716
        },
717
        'cyclades.ram': {
718
            'help_text':'resource cyclades.ram help text',
719
            'is_abbreviation':True,
720
        },
721
        'cyclades.cpu': {
722
            'help_text':'resource cyclades.cpu help text',
723
            'is_abbreviation':True,
724
        }
725
    }
737
    
726 738

  
727 739
    post_save_redirect = '/im/group/%(id)s/'
728 740
    context_processors = None
......
1166 1178
        messages.error(request, result.reason)
1167 1179
    return render_response('im/resource_list.html',
1168 1180
                           data=data,
1181
                           resource_presentation=resource_presentation,
1169 1182
                           context_instance=get_context(request))
1170 1183

  
1171 1184

  

Also available in: Unified diff