'+a.addText+" "),h=d.find("tr:last a")):(c.filter(":last").after('"),h=c.filter(":last").next().find("a"));h.click(function(d){d.preventDefault();var f=b("#id_"+a.prefix+"-TOTAL_FORMS"),d=b("#"+a.prefix+
3 | "-empty"),c=d.clone(true);c.removeClass(a.emptyCssClass).addClass(a.formCssClass).attr("id",a.prefix+"-"+g);c.is("tr")?c.children(":last").append('"):c.is("ul")||c.is("ol")?c.append(''+a.deleteText+" "):c.children(":first").append(''+a.deleteText+" ");c.find("*").each(function(){i(this,
4 | a.prefix,f.val())});c.insertBefore(b(d));b(f).val(parseInt(f.val(),10)+1);g=g+1;e.val()!==""&&e.val()-f.val()<=0&&h.parent().hide();c.find("a."+a.deleteCssClass).click(function(d){d.preventDefault();d=b(this).parents("."+a.formCssClass);d.remove();g=g-1;a.removed&&a.removed(d);d=b("."+a.formCssClass);b("#id_"+a.prefix+"-TOTAL_FORMS").val(d.length);(e.val()===""||e.val()-d.length>0)&&h.parent().show();for(var c=0,f=d.length;c oldIndex) {
57 | lo = oldIndex;
58 | hi = newIndex;
59 | direction = -1;
60 | } else {
61 | direction = 1;
62 | hi = oldIndex;
63 | lo = newIndex;
64 | }
65 | var lis2 = new Array(); // We will build the new order in this array
66 | for (var i = 0; i < lis.length; i++) {
67 | if (i < lo || i > hi) {
68 | // Position of items not between the indexes is unaffected
69 | lis2[i] = lis[i];
70 | continue;
71 | } else if (i == newIndex) {
72 | lis2[i] = lis[oldIndex];
73 | continue;
74 | } else {
75 | // Item is between the two indexes - move it along 1
76 | lis2[i] = lis[i - direction];
77 | }
78 | }
79 | // Re-index everything
80 | reIndex(lis2);
81 | lis = lis2;
82 | draw();
83 | // document.getElementById('hiddenOrder').value = getOrder();
84 | document.getElementsBySelector('input[name=order_]')[0].value = getOrder();
85 | }
86 |
87 | function reIndex(lis) {
88 | for (var i = 0; i < lis.length; i++) {
89 | lis[i].index = i;
90 | }
91 | }
92 |
93 | function draw() {
94 | for (var i = 0; i < lis.length; i++) {
95 | var li = lis[i];
96 | li.index = i;
97 | li.style.position = 'absolute';
98 | li.style.left = (10 + left) + 'px';
99 | li.style.top = (10 + top + (i * height)) + 'px';
100 | }
101 | }
102 |
103 | function getOrder() {
104 | var order = new Array(lis.length);
105 | for (var i = 0; i < lis.length; i++) {
106 | order[i] = lis[i].id.substring(1, 100);
107 | }
108 | return order.join(',');
109 | }
110 |
111 | function setOrder(id_list) {
112 | /* Set the current order to match the lsit of IDs */
113 | var temp_lis = new Array();
114 | for (var i = 0; i < id_list.length; i++) {
115 | var id = 'p' + id_list[i];
116 | temp_lis[temp_lis.length] = document.getElementById(id);
117 | }
118 | reIndex(temp_lis);
119 | lis = temp_lis;
120 | draw();
121 | }
122 |
123 | function addEvent(elm, evType, fn, useCapture)
124 | // addEvent and removeEvent
125 | // cross-browser event handling for IE5+, NS6 and Mozilla
126 | // By Scott Andrew
127 | {
128 | if (elm.addEventListener){
129 | elm.addEventListener(evType, fn, useCapture);
130 | return true;
131 | } else if (elm.attachEvent){
132 | var r = elm.attachEvent("on"+evType, fn);
133 | return r;
134 | } else {
135 | elm['on'+evType] = fn;
136 | }
137 | }
138 |
--------------------------------------------------------------------------------
/weather/static/admin/js/SelectBox.js:
--------------------------------------------------------------------------------
1 | var SelectBox = {
2 | cache: new Object(),
3 | init: function(id) {
4 | var box = document.getElementById(id);
5 | var node;
6 | SelectBox.cache[id] = new Array();
7 | var cache = SelectBox.cache[id];
8 | for (var i = 0; (node = box.options[i]); i++) {
9 | cache.push({value: node.value, text: node.text, displayed: 1});
10 | }
11 | },
12 | redisplay: function(id) {
13 | // Repopulate HTML select box from cache
14 | var box = document.getElementById(id);
15 | box.options.length = 0; // clear all options
16 | for (var i = 0, j = SelectBox.cache[id].length; i < j; i++) {
17 | var node = SelectBox.cache[id][i];
18 | if (node.displayed) {
19 | box.options[box.options.length] = new Option(node.text, node.value, false, false);
20 | }
21 | }
22 | },
23 | filter: function(id, text) {
24 | // Redisplay the HTML select box, displaying only the choices containing ALL
25 | // the words in text. (It's an AND search.)
26 | var tokens = text.toLowerCase().split(/\s+/);
27 | var node, token;
28 | for (var i = 0; (node = SelectBox.cache[id][i]); i++) {
29 | node.displayed = 1;
30 | for (var j = 0; (token = tokens[j]); j++) {
31 | if (node.text.toLowerCase().indexOf(token) == -1) {
32 | node.displayed = 0;
33 | }
34 | }
35 | }
36 | SelectBox.redisplay(id);
37 | },
38 | delete_from_cache: function(id, value) {
39 | var node, delete_index = null;
40 | for (var i = 0; (node = SelectBox.cache[id][i]); i++) {
41 | if (node.value == value) {
42 | delete_index = i;
43 | break;
44 | }
45 | }
46 | var j = SelectBox.cache[id].length - 1;
47 | for (var i = delete_index; i < j; i++) {
48 | SelectBox.cache[id][i] = SelectBox.cache[id][i+1];
49 | }
50 | SelectBox.cache[id].length--;
51 | },
52 | add_to_cache: function(id, option) {
53 | SelectBox.cache[id].push({value: option.value, text: option.text, displayed: 1});
54 | },
55 | cache_contains: function(id, value) {
56 | // Check if an item is contained in the cache
57 | var node;
58 | for (var i = 0; (node = SelectBox.cache[id][i]); i++) {
59 | if (node.value == value) {
60 | return true;
61 | }
62 | }
63 | return false;
64 | },
65 | move: function(from, to) {
66 | var from_box = document.getElementById(from);
67 | var to_box = document.getElementById(to);
68 | var option;
69 | for (var i = 0; (option = from_box.options[i]); i++) {
70 | if (option.selected && SelectBox.cache_contains(from, option.value)) {
71 | SelectBox.add_to_cache(to, {value: option.value, text: option.text, displayed: 1});
72 | SelectBox.delete_from_cache(from, option.value);
73 | }
74 | }
75 | SelectBox.redisplay(from);
76 | SelectBox.redisplay(to);
77 | },
78 | move_all: function(from, to) {
79 | var from_box = document.getElementById(from);
80 | var to_box = document.getElementById(to);
81 | var option;
82 | for (var i = 0; (option = from_box.options[i]); i++) {
83 | if (SelectBox.cache_contains(from, option.value)) {
84 | SelectBox.add_to_cache(to, {value: option.value, text: option.text, displayed: 1});
85 | SelectBox.delete_from_cache(from, option.value);
86 | }
87 | }
88 | SelectBox.redisplay(from);
89 | SelectBox.redisplay(to);
90 | },
91 | sort: function(id) {
92 | SelectBox.cache[id].sort( function(a, b) {
93 | a = a.text.toLowerCase();
94 | b = b.text.toLowerCase();
95 | try {
96 | if (a > b) return 1;
97 | if (a < b) return -1;
98 | }
99 | catch (e) {
100 | // silently fail on IE 'unknown' exception
101 | }
102 | return 0;
103 | } );
104 | },
105 | select_all: function(id) {
106 | var box = document.getElementById(id);
107 | for (var i = 0; i < box.options.length; i++) {
108 | box.options[i].selected = 'selected';
109 | }
110 | }
111 | }
112 |
--------------------------------------------------------------------------------
/weather/settings/dev.py:
--------------------------------------------------------------------------------
1 | """Development settings and globals."""
2 |
3 | from common import *
4 | from os.path import join, normpath
5 |
6 | ########## DEBUG CONFIGURATION
7 | DEBUG = True
8 | TEMPLATE_DEBUG = DEBUG
9 | ########## END DEBUG CONFIGURATION
10 |
11 |
12 | ########## EMAIL CONFIGURATION
13 | # EMAIL_BACKEND = 'django.core.mail.backends.dummy.EmailBackend'
14 | # EMAIL_BACKEND = 'django.core.mail.backends.console.EmailBackend'
15 |
16 | # EMAIL SMTP BACKEND SETTINGS
17 | EMAIL_BACKEND = 'django.core.mail.backends.smtp.EmailBackend'
18 | EMAIL_USE_TLS = True
19 | EMAIL_HOST = 'smtp.gmail.com'
20 | EMAIL_HOST_USER = 'john.sandall@gmail.com'
21 | EMAIL_HOST_PASSWORD = 'cxhaezhnbehnflcj'
22 | EMAIL_PORT = 587
23 | EMAIL_SUBJECT_PREFIX = '[%s] ' % SITE_NAME
24 | SERVER_EMAIL = EMAIL_HOST_USER
25 |
26 | ########## END EMAIL CONFIGURATION
27 |
28 |
29 | ########## DATABASE CONFIGURATION
30 | DATABASES = {
31 | 'default': {
32 | 'ENGINE': 'django.db.backends.mysql', # Add 'postgresql_psycopg2', 'mysql', 'sqlite3' or 'oracle'.
33 | 'NAME': 'weather', # Or path to database file if using sqlite3.
34 | 'USER': 'john', # Not used with sqlite3.
35 | 'PASSWORD': 'djohn', # Not used with sqlite3.
36 | 'HOST': '', # Set to empty string for localhost. Not used with sqlite3.
37 | 'PORT': '', # Set to empty string for default. Not used with sqlite3.
38 | }
39 | }
40 |
41 | # SQLite config
42 | #DATABASES = {
43 | # 'default': {
44 | # 'ENGINE': 'django.db.backends.sqlite3',
45 | # 'NAME': normpath(join(SITE_ROOT, 'db', 'default.db')),
46 | # 'USER': '',
47 | # 'PASSWORD': '',
48 | # 'HOST': '',
49 | # 'PORT': '',
50 | # }
51 | #}
52 | ########## END DATABASE CONFIGURATION
53 |
54 |
55 | ########## CACHE CONFIGURATION
56 | CACHES = {
57 | 'default': {
58 | 'BACKEND': 'django.core.cache.backends.dummy.DummyCache',
59 | #'BACKEND': 'django.core.cache.backends.locmem.LocMemCache',
60 | }
61 | }
62 | ########## END CACHE CONFIGURATION
63 |
64 |
65 | ########## DJANGO-DEBUG-TOOLBAR CONFIGURATION
66 | MIDDLEWARE_CLASSES += (
67 | 'debug_toolbar.middleware.DebugToolbarMiddleware',
68 | )
69 |
70 | INSTALLED_APPS += (
71 | 'debug_toolbar',
72 | )
73 |
74 | # IPs allowed to see django-debug-toolbar output.
75 | INTERNAL_IPS = ('127.0.0.1',)
76 |
77 | DEBUG_TOOLBAR_CONFIG = {
78 | # If set to True (default), the debug toolbar will show an intermediate
79 | # page upon redirect so you can view any debug information prior to
80 | # redirecting. This page will provide a link to the redirect destination
81 | # you can follow when ready. If set to False, redirects will proceed as
82 | # normal.
83 | 'INTERCEPT_REDIRECTS': False,
84 |
85 | # If not set or set to None, the debug_toolbar middleware will use its
86 | # built-in show_toolbar method for determining whether the toolbar should
87 | # show or not. The default checks are that DEBUG must be set to True and
88 | # the IP of the request must be in INTERNAL_IPS. You can provide your own
89 | # method for displaying the toolbar which contains your custom logic. This
90 | # method should return True or False.
91 | 'SHOW_TOOLBAR_CALLBACK': None,
92 |
93 | # An array of custom signals that might be in your project, defined as the
94 | # python path to the signal.
95 | 'EXTRA_SIGNALS': [],
96 |
97 | # If set to True (the default) then code in Django itself won't be shown in
98 | # SQL stacktraces.
99 | 'HIDE_DJANGO_SQL': True,
100 |
101 | # If set to True (the default) then a template's context will be included
102 | # with it in the Template debug panel. Turning this off is useful when you
103 | # have large template contexts, or you have template contexts with lazy
104 | # datastructures that you don't want to be evaluated.
105 | 'SHOW_TEMPLATE_CONTEXT': True,
106 |
107 | # If set, this will be the tag to which debug_toolbar will attach the debug
108 | # toolbar. Defaults to 'body'.
109 | 'TAG': 'body',
110 | }
111 | ########## END DJANGO-DEBUG-TOOLBAR CONFIGURATION
112 |
113 |
114 | ########## CELERY CONFIGURATION
115 | #INSTALLED_APPS += (
116 | # 'djkombu',
117 | #)
118 |
119 | #BROKER_BACKEND = 'djkombu.transport.DatabaseTransport'
120 |
121 | # See: http://docs.celeryq.org/en/latest/configuration.html#celery-always-eager
122 | #CELERY_ALWAYS_EAGER = True
123 | ########## END CELERY CONFIGURATION
--------------------------------------------------------------------------------
/weather/assets/less/bootstrap/responsive-767px-max.less:
--------------------------------------------------------------------------------
1 | //
2 | // Responsive: Landscape phone to desktop/tablet
3 | // --------------------------------------------------
4 |
5 |
6 | @media (max-width: 767px) {
7 |
8 | // Padding to set content in a bit
9 | body {
10 | padding-left: 20px;
11 | padding-right: 20px;
12 | }
13 | // Negative indent the now static "fixed" navbar
14 | .navbar-fixed-top,
15 | .navbar-fixed-bottom,
16 | .navbar-static-top {
17 | margin-left: -20px;
18 | margin-right: -20px;
19 | }
20 | // Remove padding on container given explicit padding set on body
21 | .container-fluid {
22 | padding: 0;
23 | }
24 |
25 | // TYPOGRAPHY
26 | // ----------
27 | // Reset horizontal dl
28 | .dl-horizontal {
29 | dt {
30 | float: none;
31 | clear: none;
32 | width: auto;
33 | text-align: left;
34 | }
35 | dd {
36 | margin-left: 0;
37 | }
38 | }
39 |
40 | // GRID & CONTAINERS
41 | // -----------------
42 | // Remove width from containers
43 | .container {
44 | width: auto;
45 | }
46 | // Fluid rows
47 | .row-fluid {
48 | width: 100%;
49 | }
50 | // Undo negative margin on rows and thumbnails
51 | .row,
52 | .thumbnails {
53 | margin-left: 0;
54 | }
55 | .thumbnails > li {
56 | float: none;
57 | margin-left: 0; // Reset the default margin for all li elements when no .span* classes are present
58 | }
59 | // Make all grid-sized elements block level again
60 | [class*="span"],
61 | .uneditable-input[class*="span"], // Makes uneditable inputs full-width when using grid sizing
62 | .row-fluid [class*="span"] {
63 | float: none;
64 | display: block;
65 | width: 100%;
66 | margin-left: 0;
67 | .box-sizing(border-box);
68 | }
69 | .span12,
70 | .row-fluid .span12 {
71 | width: 100%;
72 | .box-sizing(border-box);
73 | }
74 | .row-fluid [class*="offset"]:first-child {
75 | margin-left: 0;
76 | }
77 |
78 | // FORM FIELDS
79 | // -----------
80 | // Make span* classes full width
81 | .input-large,
82 | .input-xlarge,
83 | .input-xxlarge,
84 | input[class*="span"],
85 | select[class*="span"],
86 | textarea[class*="span"],
87 | .uneditable-input {
88 | .input-block-level();
89 | }
90 | // But don't let it screw up prepend/append inputs
91 | .input-prepend input,
92 | .input-append input,
93 | .input-prepend input[class*="span"],
94 | .input-append input[class*="span"] {
95 | display: inline-block; // redeclare so they don't wrap to new lines
96 | width: auto;
97 | }
98 | .controls-row [class*="span"] + [class*="span"] {
99 | margin-left: 0;
100 | }
101 |
102 | // Modals
103 | .modal {
104 | position: fixed;
105 | top: 20px;
106 | left: 20px;
107 | right: 20px;
108 | width: auto;
109 | margin: 0;
110 | &.fade { top: -100px; }
111 | &.fade.in { top: 20px; }
112 | }
113 |
114 | }
115 |
116 |
117 |
118 | // UP TO LANDSCAPE PHONE
119 | // ---------------------
120 |
121 | @media (max-width: 480px) {
122 |
123 | // Smooth out the collapsing/expanding nav
124 | .nav-collapse {
125 | -webkit-transform: translate3d(0, 0, 0); // activate the GPU
126 | }
127 |
128 | // Block level the page header small tag for readability
129 | .page-header h1 small {
130 | display: block;
131 | line-height: @baseLineHeight;
132 | }
133 |
134 | // Update checkboxes for iOS
135 | input[type="checkbox"],
136 | input[type="radio"] {
137 | border: 1px solid #ccc;
138 | }
139 |
140 | // Remove the horizontal form styles
141 | .form-horizontal {
142 | .control-label {
143 | float: none;
144 | width: auto;
145 | padding-top: 0;
146 | text-align: left;
147 | }
148 | // Move over all input controls and content
149 | .controls {
150 | margin-left: 0;
151 | }
152 | // Move the options list down to align with labels
153 | .control-list {
154 | padding-top: 0; // has to be padding because margin collaspes
155 | }
156 | // Move over buttons in .form-actions to align with .controls
157 | .form-actions {
158 | padding-left: 10px;
159 | padding-right: 10px;
160 | }
161 | }
162 |
163 | // Medias
164 | // Reset float and spacing to stack
165 | .media .pull-left,
166 | .media .pull-right {
167 | float: none;
168 | display: block;
169 | margin-bottom: 10px;
170 | }
171 | // Remove side margins since we stack instead of indent
172 | .media-object {
173 | margin-right: 0;
174 | margin-left: 0;
175 | }
176 |
177 | // Modals
178 | .modal {
179 | top: 10px;
180 | left: 10px;
181 | right: 10px;
182 | }
183 | .modal-header .close {
184 | padding: 10px;
185 | margin: -10px;
186 | }
187 |
188 | // Carousel
189 | .carousel-caption {
190 | position: static;
191 | }
192 |
193 | }
194 |
--------------------------------------------------------------------------------
/weather/static/less/bootstrap/responsive-767px-max.less:
--------------------------------------------------------------------------------
1 | //
2 | // Responsive: Landscape phone to desktop/tablet
3 | // --------------------------------------------------
4 |
5 |
6 | @media (max-width: 767px) {
7 |
8 | // Padding to set content in a bit
9 | body {
10 | padding-left: 20px;
11 | padding-right: 20px;
12 | }
13 | // Negative indent the now static "fixed" navbar
14 | .navbar-fixed-top,
15 | .navbar-fixed-bottom,
16 | .navbar-static-top {
17 | margin-left: -20px;
18 | margin-right: -20px;
19 | }
20 | // Remove padding on container given explicit padding set on body
21 | .container-fluid {
22 | padding: 0;
23 | }
24 |
25 | // TYPOGRAPHY
26 | // ----------
27 | // Reset horizontal dl
28 | .dl-horizontal {
29 | dt {
30 | float: none;
31 | clear: none;
32 | width: auto;
33 | text-align: left;
34 | }
35 | dd {
36 | margin-left: 0;
37 | }
38 | }
39 |
40 | // GRID & CONTAINERS
41 | // -----------------
42 | // Remove width from containers
43 | .container {
44 | width: auto;
45 | }
46 | // Fluid rows
47 | .row-fluid {
48 | width: 100%;
49 | }
50 | // Undo negative margin on rows and thumbnails
51 | .row,
52 | .thumbnails {
53 | margin-left: 0;
54 | }
55 | .thumbnails > li {
56 | float: none;
57 | margin-left: 0; // Reset the default margin for all li elements when no .span* classes are present
58 | }
59 | // Make all grid-sized elements block level again
60 | [class*="span"],
61 | .uneditable-input[class*="span"], // Makes uneditable inputs full-width when using grid sizing
62 | .row-fluid [class*="span"] {
63 | float: none;
64 | display: block;
65 | width: 100%;
66 | margin-left: 0;
67 | .box-sizing(border-box);
68 | }
69 | .span12,
70 | .row-fluid .span12 {
71 | width: 100%;
72 | .box-sizing(border-box);
73 | }
74 | .row-fluid [class*="offset"]:first-child {
75 | margin-left: 0;
76 | }
77 |
78 | // FORM FIELDS
79 | // -----------
80 | // Make span* classes full width
81 | .input-large,
82 | .input-xlarge,
83 | .input-xxlarge,
84 | input[class*="span"],
85 | select[class*="span"],
86 | textarea[class*="span"],
87 | .uneditable-input {
88 | .input-block-level();
89 | }
90 | // But don't let it screw up prepend/append inputs
91 | .input-prepend input,
92 | .input-append input,
93 | .input-prepend input[class*="span"],
94 | .input-append input[class*="span"] {
95 | display: inline-block; // redeclare so they don't wrap to new lines
96 | width: auto;
97 | }
98 | .controls-row [class*="span"] + [class*="span"] {
99 | margin-left: 0;
100 | }
101 |
102 | // Modals
103 | .modal {
104 | position: fixed;
105 | top: 20px;
106 | left: 20px;
107 | right: 20px;
108 | width: auto;
109 | margin: 0;
110 | &.fade { top: -100px; }
111 | &.fade.in { top: 20px; }
112 | }
113 |
114 | }
115 |
116 |
117 |
118 | // UP TO LANDSCAPE PHONE
119 | // ---------------------
120 |
121 | @media (max-width: 480px) {
122 |
123 | // Smooth out the collapsing/expanding nav
124 | .nav-collapse {
125 | -webkit-transform: translate3d(0, 0, 0); // activate the GPU
126 | }
127 |
128 | // Block level the page header small tag for readability
129 | .page-header h1 small {
130 | display: block;
131 | line-height: @baseLineHeight;
132 | }
133 |
134 | // Update checkboxes for iOS
135 | input[type="checkbox"],
136 | input[type="radio"] {
137 | border: 1px solid #ccc;
138 | }
139 |
140 | // Remove the horizontal form styles
141 | .form-horizontal {
142 | .control-label {
143 | float: none;
144 | width: auto;
145 | padding-top: 0;
146 | text-align: left;
147 | }
148 | // Move over all input controls and content
149 | .controls {
150 | margin-left: 0;
151 | }
152 | // Move the options list down to align with labels
153 | .control-list {
154 | padding-top: 0; // has to be padding because margin collaspes
155 | }
156 | // Move over buttons in .form-actions to align with .controls
157 | .form-actions {
158 | padding-left: 10px;
159 | padding-right: 10px;
160 | }
161 | }
162 |
163 | // Medias
164 | // Reset float and spacing to stack
165 | .media .pull-left,
166 | .media .pull-right {
167 | float: none;
168 | display: block;
169 | margin-bottom: 10px;
170 | }
171 | // Remove side margins since we stack instead of indent
172 | .media-object {
173 | margin-right: 0;
174 | margin-left: 0;
175 | }
176 |
177 | // Modals
178 | .modal {
179 | top: 10px;
180 | left: 10px;
181 | right: 10px;
182 | }
183 | .modal-header .close {
184 | padding: 10px;
185 | margin: -10px;
186 | }
187 |
188 | // Carousel
189 | .carousel-caption {
190 | position: static;
191 | }
192 |
193 | }
194 |
--------------------------------------------------------------------------------
/weather/assets/less/bootstrap/tests/forms.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Bootstrap, from Twitter
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
19 |
20 |
21 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
177 |
178 |
179 |
180 |
--------------------------------------------------------------------------------
/weather/static/less/bootstrap/tests/forms.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Bootstrap, from Twitter
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
19 |
20 |
21 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
40 |
41 |
175 |
176 |
177 |
178 |
179 |
180 |
--------------------------------------------------------------------------------
/weather/assets/less/bootstrap/responsive-navbar.less:
--------------------------------------------------------------------------------
1 | //
2 | // Responsive: Navbar
3 | // --------------------------------------------------
4 |
5 |
6 | // TABLETS AND BELOW
7 | // -----------------
8 | @media (max-width: @navbarCollapseWidth) {
9 |
10 | // UNFIX THE TOPBAR
11 | // ----------------
12 | // Remove any padding from the body
13 | body {
14 | padding-top: 0;
15 | }
16 | // Unfix the navbars
17 | .navbar-fixed-top,
18 | .navbar-fixed-bottom {
19 | position: static;
20 | }
21 | .navbar-fixed-top {
22 | margin-bottom: @baseLineHeight;
23 | }
24 | .navbar-fixed-bottom {
25 | margin-top: @baseLineHeight;
26 | }
27 | .navbar-fixed-top .navbar-inner,
28 | .navbar-fixed-bottom .navbar-inner {
29 | padding: 5px;
30 | }
31 | .navbar .container {
32 | width: auto;
33 | padding: 0;
34 | }
35 | // Account for brand name
36 | .navbar .brand {
37 | padding-left: 10px;
38 | padding-right: 10px;
39 | margin: 0 0 0 -5px;
40 | }
41 |
42 | // COLLAPSIBLE NAVBAR
43 | // ------------------
44 | // Nav collapse clears brand
45 | .nav-collapse {
46 | clear: both;
47 | }
48 | // Block-level the nav
49 | .nav-collapse .nav {
50 | float: none;
51 | margin: 0 0 (@baseLineHeight / 2);
52 | }
53 | .nav-collapse .nav > li {
54 | float: none;
55 | }
56 | .nav-collapse .nav > li > a {
57 | margin-bottom: 2px;
58 | }
59 | .nav-collapse .nav > .divider-vertical {
60 | display: none;
61 | }
62 | .nav-collapse .nav .nav-header {
63 | color: @navbarText;
64 | text-shadow: none;
65 | }
66 | // Nav and dropdown links in navbar
67 | .nav-collapse .nav > li > a,
68 | .nav-collapse .dropdown-menu a {
69 | padding: 9px 15px;
70 | font-weight: bold;
71 | color: @navbarLinkColor;
72 | .border-radius(3px);
73 | }
74 | // Buttons
75 | .nav-collapse .btn {
76 | padding: 4px 10px 4px;
77 | font-weight: normal;
78 | .border-radius(@baseBorderRadius);
79 | }
80 | .nav-collapse .dropdown-menu li + li a {
81 | margin-bottom: 2px;
82 | }
83 | .nav-collapse .nav > li > a:hover,
84 | .nav-collapse .dropdown-menu a:hover {
85 | background-color: @navbarBackground;
86 | }
87 | .navbar-inverse .nav-collapse .nav > li > a,
88 | .navbar-inverse .nav-collapse .dropdown-menu a {
89 | color: @navbarInverseLinkColor;
90 | }
91 | .navbar-inverse .nav-collapse .nav > li > a:hover,
92 | .navbar-inverse .nav-collapse .dropdown-menu a:hover {
93 | background-color: @navbarInverseBackground;
94 | }
95 | // Buttons in the navbar
96 | .nav-collapse.in .btn-group {
97 | margin-top: 5px;
98 | padding: 0;
99 | }
100 | // Dropdowns in the navbar
101 | .nav-collapse .dropdown-menu {
102 | position: static;
103 | top: auto;
104 | left: auto;
105 | float: none;
106 | display: none;
107 | max-width: none;
108 | margin: 0 15px;
109 | padding: 0;
110 | background-color: transparent;
111 | border: none;
112 | .border-radius(0);
113 | .box-shadow(none);
114 | }
115 | .nav-collapse .open > .dropdown-menu {
116 | display: block;
117 | }
118 |
119 | .nav-collapse .dropdown-menu:before,
120 | .nav-collapse .dropdown-menu:after {
121 | display: none;
122 | }
123 | .nav-collapse .dropdown-menu .divider {
124 | display: none;
125 | }
126 | .nav-collapse .nav > li > .dropdown-menu {
127 | &:before,
128 | &:after {
129 | display: none;
130 | }
131 | }
132 | // Forms in navbar
133 | .nav-collapse .navbar-form,
134 | .nav-collapse .navbar-search {
135 | float: none;
136 | padding: (@baseLineHeight / 2) 15px;
137 | margin: (@baseLineHeight / 2) 0;
138 | border-top: 1px solid @navbarBackground;
139 | border-bottom: 1px solid @navbarBackground;
140 | .box-shadow(~"inset 0 1px 0 rgba(255,255,255,.1), 0 1px 0 rgba(255,255,255,.1)");
141 | }
142 | .navbar-inverse .nav-collapse .navbar-form,
143 | .navbar-inverse .nav-collapse .navbar-search {
144 | border-top-color: @navbarInverseBackground;
145 | border-bottom-color: @navbarInverseBackground;
146 | }
147 | // Pull right (secondary) nav content
148 | .navbar .nav-collapse .nav.pull-right {
149 | float: none;
150 | margin-left: 0;
151 | }
152 | // Hide everything in the navbar save .brand and toggle button */
153 | .nav-collapse,
154 | .nav-collapse.collapse {
155 | overflow: hidden;
156 | height: 0;
157 | }
158 | // Navbar button
159 | .navbar .btn-navbar {
160 | display: block;
161 | }
162 |
163 | // STATIC NAVBAR
164 | // -------------
165 | .navbar-static .navbar-inner {
166 | padding-left: 10px;
167 | padding-right: 10px;
168 | }
169 |
170 |
171 | }
172 |
173 |
174 | // DEFAULT DESKTOP
175 | // ---------------
176 |
177 | @media (min-width: @navbarCollapseDesktopWidth) {
178 |
179 | // Required to make the collapsing navbar work on regular desktops
180 | .nav-collapse.collapse {
181 | height: auto !important;
182 | overflow: visible !important;
183 | }
184 |
185 | }
186 |
--------------------------------------------------------------------------------
/weather/static/less/bootstrap/responsive-navbar.less:
--------------------------------------------------------------------------------
1 | //
2 | // Responsive: Navbar
3 | // --------------------------------------------------
4 |
5 |
6 | // TABLETS AND BELOW
7 | // -----------------
8 | @media (max-width: @navbarCollapseWidth) {
9 |
10 | // UNFIX THE TOPBAR
11 | // ----------------
12 | // Remove any padding from the body
13 | body {
14 | padding-top: 0;
15 | }
16 | // Unfix the navbars
17 | .navbar-fixed-top,
18 | .navbar-fixed-bottom {
19 | position: static;
20 | }
21 | .navbar-fixed-top {
22 | margin-bottom: @baseLineHeight;
23 | }
24 | .navbar-fixed-bottom {
25 | margin-top: @baseLineHeight;
26 | }
27 | .navbar-fixed-top .navbar-inner,
28 | .navbar-fixed-bottom .navbar-inner {
29 | padding: 5px;
30 | }
31 | .navbar .container {
32 | width: auto;
33 | padding: 0;
34 | }
35 | // Account for brand name
36 | .navbar .brand {
37 | padding-left: 10px;
38 | padding-right: 10px;
39 | margin: 0 0 0 -5px;
40 | }
41 |
42 | // COLLAPSIBLE NAVBAR
43 | // ------------------
44 | // Nav collapse clears brand
45 | .nav-collapse {
46 | clear: both;
47 | }
48 | // Block-level the nav
49 | .nav-collapse .nav {
50 | float: none;
51 | margin: 0 0 (@baseLineHeight / 2);
52 | }
53 | .nav-collapse .nav > li {
54 | float: none;
55 | }
56 | .nav-collapse .nav > li > a {
57 | margin-bottom: 2px;
58 | }
59 | .nav-collapse .nav > .divider-vertical {
60 | display: none;
61 | }
62 | .nav-collapse .nav .nav-header {
63 | color: @navbarText;
64 | text-shadow: none;
65 | }
66 | // Nav and dropdown links in navbar
67 | .nav-collapse .nav > li > a,
68 | .nav-collapse .dropdown-menu a {
69 | padding: 9px 15px;
70 | font-weight: bold;
71 | color: @navbarLinkColor;
72 | .border-radius(3px);
73 | }
74 | // Buttons
75 | .nav-collapse .btn {
76 | padding: 4px 10px 4px;
77 | font-weight: normal;
78 | .border-radius(@baseBorderRadius);
79 | }
80 | .nav-collapse .dropdown-menu li + li a {
81 | margin-bottom: 2px;
82 | }
83 | .nav-collapse .nav > li > a:hover,
84 | .nav-collapse .dropdown-menu a:hover {
85 | background-color: @navbarBackground;
86 | }
87 | .navbar-inverse .nav-collapse .nav > li > a,
88 | .navbar-inverse .nav-collapse .dropdown-menu a {
89 | color: @navbarInverseLinkColor;
90 | }
91 | .navbar-inverse .nav-collapse .nav > li > a:hover,
92 | .navbar-inverse .nav-collapse .dropdown-menu a:hover {
93 | background-color: @navbarInverseBackground;
94 | }
95 | // Buttons in the navbar
96 | .nav-collapse.in .btn-group {
97 | margin-top: 5px;
98 | padding: 0;
99 | }
100 | // Dropdowns in the navbar
101 | .nav-collapse .dropdown-menu {
102 | position: static;
103 | top: auto;
104 | left: auto;
105 | float: none;
106 | display: none;
107 | max-width: none;
108 | margin: 0 15px;
109 | padding: 0;
110 | background-color: transparent;
111 | border: none;
112 | .border-radius(0);
113 | .box-shadow(none);
114 | }
115 | .nav-collapse .open > .dropdown-menu {
116 | display: block;
117 | }
118 |
119 | .nav-collapse .dropdown-menu:before,
120 | .nav-collapse .dropdown-menu:after {
121 | display: none;
122 | }
123 | .nav-collapse .dropdown-menu .divider {
124 | display: none;
125 | }
126 | .nav-collapse .nav > li > .dropdown-menu {
127 | &:before,
128 | &:after {
129 | display: none;
130 | }
131 | }
132 | // Forms in navbar
133 | .nav-collapse .navbar-form,
134 | .nav-collapse .navbar-search {
135 | float: none;
136 | padding: (@baseLineHeight / 2) 15px;
137 | margin: (@baseLineHeight / 2) 0;
138 | border-top: 1px solid @navbarBackground;
139 | border-bottom: 1px solid @navbarBackground;
140 | .box-shadow(~"inset 0 1px 0 rgba(255,255,255,.1), 0 1px 0 rgba(255,255,255,.1)");
141 | }
142 | .navbar-inverse .nav-collapse .navbar-form,
143 | .navbar-inverse .nav-collapse .navbar-search {
144 | border-top-color: @navbarInverseBackground;
145 | border-bottom-color: @navbarInverseBackground;
146 | }
147 | // Pull right (secondary) nav content
148 | .navbar .nav-collapse .nav.pull-right {
149 | float: none;
150 | margin-left: 0;
151 | }
152 | // Hide everything in the navbar save .brand and toggle button */
153 | .nav-collapse,
154 | .nav-collapse.collapse {
155 | overflow: hidden;
156 | height: 0;
157 | }
158 | // Navbar button
159 | .navbar .btn-navbar {
160 | display: block;
161 | }
162 |
163 | // STATIC NAVBAR
164 | // -------------
165 | .navbar-static .navbar-inner {
166 | padding-left: 10px;
167 | padding-right: 10px;
168 | }
169 |
170 |
171 | }
172 |
173 |
174 | // DEFAULT DESKTOP
175 | // ---------------
176 |
177 | @media (min-width: @navbarCollapseDesktopWidth) {
178 |
179 | // Required to make the collapsing navbar work on regular desktops
180 | .nav-collapse.collapse {
181 | height: auto !important;
182 | overflow: visible !important;
183 | }
184 |
185 | }
186 |
--------------------------------------------------------------------------------
/weather/static/admin/css/rtl.css:
--------------------------------------------------------------------------------
1 | body {
2 | direction: rtl;
3 | }
4 |
5 | /* LOGIN */
6 |
7 | .login .form-row {
8 | float: right;
9 | }
10 |
11 | .login .form-row label {
12 | float: right;
13 | padding-left: 0.5em;
14 | padding-right: 0;
15 | text-align: left;
16 | }
17 |
18 | .login .submit-row {
19 | clear: both;
20 | padding: 1em 9.4em 0 0;
21 | }
22 |
23 | /* GLOBAL */
24 |
25 | th {
26 | text-align: right;
27 | }
28 |
29 | .module h2, .module caption {
30 | text-align: right;
31 | }
32 |
33 | .addlink, .changelink {
34 | padding-left: 0px;
35 | padding-right: 12px;
36 | background-position: 100% 0.2em;
37 | }
38 |
39 | .deletelink {
40 | padding-left: 0px;
41 | padding-right: 12px;
42 | background-position: 100% 0.25em;
43 | }
44 |
45 | .object-tools {
46 | float: left;
47 | }
48 |
49 | thead th:first-child,
50 | tfoot td:first-child {
51 | border-left: 1px solid #ddd !important;
52 | }
53 |
54 | /* LAYOUT */
55 |
56 | #user-tools {
57 | right: auto;
58 | left: 0;
59 | text-align: left;
60 | }
61 |
62 | div.breadcrumbs {
63 | text-align: right;
64 | }
65 |
66 | #content-main {
67 | float: right;
68 | }
69 |
70 | #content-related {
71 | float: left;
72 | margin-left: -19em;
73 | margin-right: auto;
74 | }
75 |
76 | .colMS {
77 | margin-left: 20em !important;
78 | margin-right: 10px !important;
79 | }
80 |
81 | /* SORTABLE TABLES */
82 |
83 | table thead th.sorted .sortoptions {
84 | float: left;
85 | }
86 |
87 | thead th.sorted .text {
88 | padding-right: 0;
89 | padding-left: 42px;
90 | }
91 |
92 | /* dashboard styles */
93 |
94 | .dashboard .module table td a {
95 | padding-left: .6em;
96 | padding-right: 12px;
97 | }
98 |
99 | /* changelists styles */
100 |
101 | .change-list .filtered {
102 | background: white url(../img/changelist-bg_rtl.gif) top left repeat-y !important;
103 | }
104 |
105 | .change-list .filtered table {
106 | border-left: 1px solid #ddd;
107 | border-right: 0px none;
108 | }
109 |
110 | #changelist-filter {
111 | right: auto;
112 | left: 0;
113 | border-left: 0px none;
114 | border-right: 1px solid #ddd;
115 | }
116 |
117 | .change-list .filtered .results, .change-list .filtered .paginator, .filtered #toolbar, .filtered div.xfull {
118 | margin-right: 0px !important;
119 | margin-left: 160px !important;
120 | }
121 |
122 | #changelist-filter li.selected {
123 | border-left: 0px none;
124 | padding-left: 0px;
125 | margin-left: 0;
126 | border-right: 5px solid #ccc;
127 | padding-right: 5px;
128 | margin-right: -10px;
129 | }
130 |
131 | .filtered .actions {
132 | border-left:1px solid #DDDDDD;
133 | margin-left:160px !important;
134 | border-right: 0 none;
135 | margin-right:0 !important;
136 | }
137 |
138 | #changelist table tbody td:first-child, #changelist table tbody th:first-child {
139 | border-right: 0;
140 | border-left: 1px solid #ddd;
141 | }
142 |
143 | /* FORMS */
144 |
145 | .aligned label {
146 | padding: 0 0 3px 1em;
147 | float: right;
148 | }
149 |
150 | .submit-row {
151 | text-align: left
152 | }
153 |
154 | .submit-row p.deletelink-box {
155 | float: right;
156 | }
157 |
158 | .submit-row .deletelink {
159 | background: url(../img/icon_deletelink.gif) 0 50% no-repeat;
160 | padding-right: 14px;
161 | }
162 |
163 | .vDateField, .vTimeField {
164 | margin-left: 2px;
165 | }
166 |
167 | form ul.inline li {
168 | float: right;
169 | padding-right: 0;
170 | padding-left: 7px;
171 | }
172 |
173 | input[type=submit].default, .submit-row input.default {
174 | float: left;
175 | }
176 |
177 | fieldset .field-box {
178 | float: right;
179 | margin-left: 20px;
180 | margin-right: 0;
181 | }
182 |
183 | .errorlist li {
184 | background-position: 100% .3em;
185 | padding: 4px 25px 4px 5px;
186 | }
187 |
188 | .errornote {
189 | background-position: 100% .3em;
190 | padding: 4px 25px 4px 5px;
191 | }
192 |
193 | /* WIDGETS */
194 |
195 | .calendarnav-previous {
196 | top: 0;
197 | left: auto;
198 | right: 0;
199 | }
200 |
201 | .calendarnav-next {
202 | top: 0;
203 | right: auto;
204 | left: 0;
205 | }
206 |
207 | .calendar caption, .calendarbox h2 {
208 | text-align: center;
209 | }
210 |
211 | .selector {
212 | float: right;
213 | }
214 |
215 | .selector .selector-filter {
216 | text-align: right;
217 | }
218 |
219 | .inline-deletelink {
220 | float: left;
221 | }
222 |
223 | /* MISC */
224 |
225 | .inline-related h2, .inline-group h2 {
226 | text-align: right
227 | }
228 |
229 | .inline-related h3 span.delete {
230 | padding-right: 20px;
231 | padding-left: inherit;
232 | left: 10px;
233 | right: inherit;
234 | float:left;
235 | }
236 |
237 | .inline-related h3 span.delete label {
238 | margin-left: inherit;
239 | margin-right: 2px;
240 | }
241 |
242 | /* IE7 specific bug fixes */
243 |
244 | div.colM {
245 | position: relative;
246 | }
247 |
248 | .submit-row input {
249 | float: left;
250 | }
--------------------------------------------------------------------------------
/weather/assets/less/bootstrap/tests/navbar-fixed-top.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Bootstrap, from Twitter
6 |
7 |
8 |
9 |
10 |
11 |
12 |
18 |
19 |
20 |
21 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
72 |
73 |
74 |
75 |
76 |
77 |
Navbar example
78 |
This example is a quick exercise to illustrate how the default, static navbar and fixed to top navbar work. It includes the responsive CSS and HTML, so it also adapts to your viewport and device.
79 |
80 | View navbar docs »
81 |
82 |
83 |
84 |
85 |
86 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
--------------------------------------------------------------------------------
/weather/static/less/bootstrap/tests/navbar-fixed-top.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Bootstrap, from Twitter
6 |
7 |
8 |
9 |
10 |
11 |
12 |
18 |
19 |
20 |
21 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
72 |
73 |
74 |
75 |
76 |
77 |
Navbar example
78 |
This example is a quick exercise to illustrate how the default, static navbar and fixed to top navbar work. It includes the responsive CSS and HTML, so it also adapts to your viewport and device.
79 |
80 | View navbar docs »
81 |
82 |
83 |
84 |
85 |
86 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
--------------------------------------------------------------------------------
/weather/assets/less/bootstrap/tests/navbar-static-top.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Bootstrap, from Twitter
6 |
7 |
8 |
9 |
10 |
11 |
12 |
20 |
21 |
22 |
23 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
Navbar example
81 |
This example is a quick exercise to illustrate how the default, static navbar and fixed to top navbar work. It includes the responsive CSS and HTML, so it also adapts to your viewport and device.
82 |
83 | View navbar docs »
84 |
85 |
86 |
87 |
88 |
89 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
--------------------------------------------------------------------------------
/weather/static/less/bootstrap/tests/navbar-static-top.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Bootstrap, from Twitter
6 |
7 |
8 |
9 |
10 |
11 |
12 |
20 |
21 |
22 |
23 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
Navbar example
81 |
This example is a quick exercise to illustrate how the default, static navbar and fixed to top navbar work. It includes the responsive CSS and HTML, so it also adapts to your viewport and device.
82 |
83 | View navbar docs »
84 |
85 |
86 |
87 |
88 |
89 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
--------------------------------------------------------------------------------
/weather/templates/404.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Page Not Found :(
6 |
141 |
142 |
143 |
144 |
Not found :(
145 |
Sorry, but the page you were trying to view does not exist.
146 |
It looks like this was the result of either:
147 |
148 | a mistyped address
149 | an out-of-date link
150 |
151 |
154 |
155 |
156 |
157 |
158 |
--------------------------------------------------------------------------------
/weather/assets/less/bootstrap/tests/navbar.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Bootstrap, from Twitter
6 |
7 |
8 |
9 |
10 |
11 |
12 |
21 |
22 |
23 |
24 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
77 |
78 |
79 |
80 |
Navbar example
81 |
This example is a quick exercise to illustrate how the default, static navbar and fixed to top navbar work. It includes the responsive CSS and HTML, so it also adapts to your viewport and device.
82 |
83 | View navbar docs »
84 |
85 |
86 |
87 |
88 |
89 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
--------------------------------------------------------------------------------
/weather/static/less/bootstrap/tests/navbar.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Bootstrap, from Twitter
6 |
7 |
8 |
9 |
10 |
11 |
12 |
21 |
22 |
23 |
24 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
77 |
78 |
79 |
80 |
Navbar example
81 |
This example is a quick exercise to illustrate how the default, static navbar and fixed to top navbar work. It includes the responsive CSS and HTML, so it also adapts to your viewport and device.
82 |
83 | View navbar docs »
84 |
85 |
86 |
87 |
88 |
89 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
--------------------------------------------------------------------------------