Merge remote-tracking branch 'upstream/master'
This commit is contained in:
@@ -230,20 +230,20 @@ $(document).on('click', 'a.font_button', function (e) {
|
||||
<ul class="nav nav-list" rel="pagebookmark" id="filelist">
|
||||
<li><input type="text" placeholder="{{=T('Rapid Search')}}" class="input-block-level typeahead-tw search-query"></li>
|
||||
{{auto_complete_list=[]}}
|
||||
<br />
|
||||
<br />
|
||||
<div>
|
||||
<button onclick="jQuery('#form').slideToggle()" class="btn btn-mini">{{=T('Create')}}</button>
|
||||
<br />
|
||||
<div id="form">
|
||||
<div>
|
||||
{{=file_create_form('%s/' % app, '')}}
|
||||
</div>
|
||||
</div>
|
||||
<script>jQuery('#form').slideToggle()</script>
|
||||
</div>
|
||||
<br />
|
||||
<button onclick="jQuery('#form').slideToggle()" class="btn btn-mini">{{=T('Create')}}</button>
|
||||
<br />
|
||||
<div id="form">
|
||||
<div>
|
||||
{{=file_create_form('%s/' % app, '')}}
|
||||
</div>
|
||||
</div>
|
||||
<script>jQuery('#form').slideToggle()</script>
|
||||
</div>
|
||||
<br />
|
||||
<div id="files_menu">
|
||||
{{=LOAD('default', 'files_menu', vars={'app':app}, ajax=True)}}
|
||||
{{=LOAD('default', 'files_menu', vars={'app':app}, ajax=True)}}
|
||||
</div>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -284,10 +284,6 @@ select.autocomplete {
|
||||
* application customization
|
||||
* add custom rules
|
||||
*/
|
||||
|
||||
body {
|
||||
padding-top: 70px;
|
||||
}
|
||||
/* web2py logo */
|
||||
#web2py-logo {
|
||||
color: #c6cecc;
|
||||
@@ -317,18 +313,19 @@ body {
|
||||
color: #428bca;
|
||||
}
|
||||
|
||||
form {
|
||||
max-width: 600px;
|
||||
}
|
||||
ul.w2p_list {
|
||||
margin-left: 0px;
|
||||
}
|
||||
input.date,input.time,input.datetime,input.double,input.integer {
|
||||
width: 33.333%;
|
||||
}
|
||||
.container-full {
|
||||
margin: 0 auto; width: 100%;
|
||||
margin-left: 0;
|
||||
padding-left: 0;
|
||||
}
|
||||
.background {
|
||||
background: url(../images/background.jpg) no-repeat center center;
|
||||
}
|
||||
html {
|
||||
background-color: #333;
|
||||
}
|
||||
body {
|
||||
padding-top: 50px
|
||||
}
|
||||
@@ -347,6 +344,9 @@ footer {
|
||||
header h1 {
|
||||
color: white !important; text-shadow: 0 0 7px black;
|
||||
}
|
||||
header .jumbotron {
|
||||
background-color: transparent;
|
||||
}
|
||||
.nav a, .btn, .btn-default {
|
||||
text-shadow: none; font-weight: bold;
|
||||
}
|
||||
@@ -363,3 +363,181 @@ header h1 {
|
||||
#w2padmin-btn {
|
||||
margin:30px 0 30px 0;
|
||||
}
|
||||
.hidden {display:none;visibility:visible}
|
||||
.right {float:right; text-align:right}
|
||||
.left {float:left; text-align:left}
|
||||
.center {width:100%; text-align:center; vertical-align:middle}
|
||||
|
||||
/* fix ie problem with menu */
|
||||
|
||||
td.w2p_fw {padding-bottom:1px}
|
||||
td.w2p_fl,td.w2p_fw,td.w2p_fc {vertical-align:top}
|
||||
td.w2p_fl {text-align:left}
|
||||
td.w2p_fl, td.w2p_fw {padding-right:7px}
|
||||
td.w2p_fl,td.w2p_fc {padding-top:4px}
|
||||
div.w2p_export_menu {margin:5px 0}
|
||||
div.w2p_export_menu a, div.w2p_wiki_tags a, div.w2p_cloud a {margin-left:5px; padding:2px 5px; background-color:#f1f1f1; border-radius:5px; -moz-border-radius:5px; -webkit-border-radius:5px;}
|
||||
|
||||
/* tr#submit_record__row {border-top:1px solid #E5E5E5} */
|
||||
#submit_record__row td {padding-top:.5em}
|
||||
|
||||
/* Fix */
|
||||
#auth_user_remember__row label {display:inline}
|
||||
#web2py_user_form td {vertical-align:top}
|
||||
|
||||
div.error_wrapper {display:block}
|
||||
div.error {
|
||||
color:red;
|
||||
padding:5px;
|
||||
display:inline-block;
|
||||
}
|
||||
|
||||
.copyright {float:left}
|
||||
#poweredBy {float:right}
|
||||
|
||||
/* #MEDIA QUERIES SECTION */
|
||||
|
||||
/*
|
||||
*Grid
|
||||
*
|
||||
* The default style for SQLFORM.grid even using jquery-iu or another ui framework
|
||||
* will look better with the declarations below
|
||||
* if needed to remove base.css consider keeping these following lines in some css file.
|
||||
*/
|
||||
/* .web2py_table {border:1px solid #ccc} */
|
||||
.web2py_paginator {}
|
||||
.web2py_grid {width:100%}
|
||||
.web2py_grid table {width:100%}
|
||||
.web2py_grid tbody td {padding:2px 5px 2px 5px; vertical-align: middle;}
|
||||
.web2py_grid .web2py_form td {vertical-align: top;}
|
||||
|
||||
.web2py_grid thead th,.web2py_grid tfoot td {
|
||||
background-color:#EAEAEA;
|
||||
padding:10px 5px 10px 5px;
|
||||
}
|
||||
|
||||
.web2py_grid tr.odd {background-color:#F9F9F9}
|
||||
.web2py_grid tr:hover {background-color:#F5F5F5}
|
||||
|
||||
/*
|
||||
.web2py_breadcrumbs a {
|
||||
line-height:20px; margin-right:5px; display:inline-block;
|
||||
padding:3px 5px 3px 5px;
|
||||
font-family:'lucida grande',tahoma,verdana,arial,sans-serif;
|
||||
color:#3C3C3D;
|
||||
text-shadow:1px 1px 0 #FFFFFF;
|
||||
white-space:nowrap; overflow:visible; cursor:pointer;
|
||||
background:#ECECEC;
|
||||
border:1px solid #CACACA;
|
||||
-webkit-border-radius:2px; -moz-border-radius:2px;
|
||||
-webkit-background-clip:padding-box; border-radius:2px;
|
||||
outline:none; position:relative; zoom:1; *display:inline;
|
||||
}
|
||||
*/
|
||||
|
||||
.web2py_console form {
|
||||
width: 100%;
|
||||
display: inline;
|
||||
vertical-align: middle;
|
||||
margin: 0 0 0 5px;
|
||||
}
|
||||
|
||||
.web2py_console form select {
|
||||
margin:0;
|
||||
}
|
||||
|
||||
.web2py_search_actions {
|
||||
float:left;
|
||||
text-align:left;
|
||||
}
|
||||
|
||||
.web2py_grid .row_buttons {
|
||||
min-height:25px;
|
||||
vertical-align:middle;
|
||||
}
|
||||
.web2py_grid .row_buttons a {
|
||||
margin:3px;
|
||||
}
|
||||
|
||||
.web2py_search_actions {
|
||||
width:100%;
|
||||
}
|
||||
|
||||
.web2py_grid .row_buttons a,
|
||||
.web2py_paginator ul li a,
|
||||
.web2py_search_actions a,
|
||||
.web2py_console input[type=submit],
|
||||
.web2py_console input[type=button],
|
||||
.web2py_console button {
|
||||
line-height:20px;
|
||||
margin-right:2px; display:inline-block;
|
||||
padding:3px 5px 3px 5px;
|
||||
}
|
||||
|
||||
.web2py_counter {
|
||||
margin-top:5px;
|
||||
margin-right:2px;
|
||||
width:35%;
|
||||
float:right;
|
||||
text-align:right;
|
||||
}
|
||||
|
||||
/*Fix firefox problem*/
|
||||
.web2py_table {clear:both; display:block}
|
||||
|
||||
.web2py_paginator {
|
||||
padding:5px;
|
||||
text-align:right;
|
||||
background-color:#f2f2f2;
|
||||
|
||||
}
|
||||
.web2py_paginator ul {
|
||||
list-style-type:none;
|
||||
margin:0px;
|
||||
padding:0px;
|
||||
}
|
||||
|
||||
.web2py_paginator ul li {
|
||||
display:inline;
|
||||
}
|
||||
|
||||
.web2py_paginator .current {
|
||||
font-weight:bold;
|
||||
}
|
||||
|
||||
.web2py_breadcrumbs ul {
|
||||
list-style:none;
|
||||
margin-bottom:18px;
|
||||
}
|
||||
|
||||
li.w2p_grid_breadcrumb_elem {
|
||||
display:inline-block;
|
||||
}
|
||||
|
||||
.web2py_console form { vertical-align: middle; }
|
||||
.web2py_console input, .web2py_console select,
|
||||
.web2py_console a { margin: 2px; }
|
||||
|
||||
|
||||
#wiki_page_body {
|
||||
width: 600px;
|
||||
height: auto;
|
||||
min-height: 400px;
|
||||
}
|
||||
|
||||
/* fix some IE problems */
|
||||
|
||||
.ie-lte7 .topbar .container {z-index:2}
|
||||
.ie-lte8 div.flash{ filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#222222', endColorstr='#000000', GradientType=0 ); }
|
||||
.ie-lte8 div.flash:hover {filter:alpha(opacity=25);}
|
||||
.ie9 #w2p_query_panel {padding-bottom:2px}
|
||||
|
||||
.web2py_console .form-control {width: 20%; display: inline;}
|
||||
.web2py_console #w2p_keywords {width: 50%;}
|
||||
.web2py_search_actions a, .web2py_console input[type=submit], .web2py_console input[type=button], .web2py_console button { padding: 6px 12px; }
|
||||
|
||||
/*
|
||||
input.date,input.time,input.datetime,input.double,input.integer {
|
||||
max-width: 300px;
|
||||
}
|
||||
*/
|
||||
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -1,6 +1,17 @@
|
||||
{{left_sidebar_enabled,right_sidebar_enabled=False,('message' in globals())}}
|
||||
{{extend 'layout.html'}}
|
||||
|
||||
{{block header}}
|
||||
<header class="container-fluid background">
|
||||
<div class="jumbotron text-center">
|
||||
{{if response.title:}}
|
||||
<h1>{{=response.title}}
|
||||
<small>{{=response.subtitle or ''}}</small></h1>
|
||||
{{pass}}
|
||||
</div>
|
||||
</header>
|
||||
{{end}}
|
||||
|
||||
{{if 'message' in globals():}}
|
||||
<h2>{{=message}}</h2>
|
||||
<p class="lead">{{=T('How did you get here?')}}</p>
|
||||
|
||||
@@ -1,10 +1,4 @@
|
||||
<!--[if HTML5]><![endif]-->
|
||||
<!DOCTYPE html>
|
||||
<!-- paulirish.com/2008/conditional-stylesheets-vs-css-hacks-answer-neither/ -->
|
||||
<!--[if lt IE 7]><html class="ie ie6 ie-lte9 ie-lte8 ie-lte7 no-js" lang="{{=T.accepted_language or 'en'}}"> <![endif]-->
|
||||
<!--[if IE 7]><html class="ie ie7 ie-lte9 ie-lte8 ie-lte7 no-js" lang="{{=T.accepted_language or 'en'}}"> <![endif]-->
|
||||
<!--[if IE 8]><html class="ie ie8 ie-lte9 ie-lte8 no-js" lang="{{=T.accepted_language or 'en'}}"> <![endif]-->
|
||||
<!--[if IE 9]><html class="ie9 ie-lte9 no-js" lang="{{=T.accepted_language or 'en'}}"> <![endif]-->
|
||||
<!--[if (gt IE 9)|!(IE)]><!--> <html class="no-js" lang="{{=T.accepted_language or 'en'}}"> <!--<![endif]-->
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
@@ -26,23 +20,20 @@
|
||||
http://google.com/webmasters -->
|
||||
<meta name="google-site-verification" content="">
|
||||
<!-- include stylesheets -->
|
||||
{{
|
||||
response.files.insert(0,URL('static','css/web2py.css'))
|
||||
response.files.insert(1,URL('static','css/bootstrap.min.css'))
|
||||
response.files.insert(1,URL('static','css/bootstrap-theme.min.css'))
|
||||
response.files.insert(4,URL('static','css/web2py-bootstrap3.css'))
|
||||
}}
|
||||
<!-- All JavaScript at the bottom, except for Modernizr which enables
|
||||
HTML5 elements & feature detects -->
|
||||
<script src="{{=URL('static','js/modernizr.custom.js')}}"></script>
|
||||
<!-- Favicons -->
|
||||
<link rel="stylesheet" href="{{=URL('static','css/bootstrap.min.css')}}"/>
|
||||
<link rel="stylesheet" href="{{=URL('static','css/bootstrap-theme.min.css')}}"/>
|
||||
<link rel="stylesheet" href="{{=URL('static','css/web2py-bootstrap3.css')}}"/>
|
||||
<link rel="shortcut icon" href="{{=URL('static','images/favicon.ico')}}" type="image/x-icon">
|
||||
<link rel="apple-touch-icon" href="{{=URL('static','images/favicon.png')}}">
|
||||
{{include 'web2py_ajax.html'}}
|
||||
{{block head}}{{end}}
|
||||
<!-- All JavaScript at the bottom, except for Modernizr which enables
|
||||
HTML5 elements & feature detects -->
|
||||
<script src="{{=URL('static','js/modernizr-2.8.3.min.js')}}"><script>
|
||||
<!--[if lt IE 9]>
|
||||
<script src="{{=URL('static','js/respond.min.js')}}"></script>
|
||||
<script src="{{=URL('static','js/respond-1.4.2.min.js')}}"></script>
|
||||
<![endif]-->
|
||||
<!-- Favicons -->
|
||||
{{include 'web2py_ajax.html'}} <!-- this includes jquery.js, calendar.js/.css and web2py.js -->
|
||||
{{block head}}{{end}}
|
||||
{{
|
||||
# using sidebars need to know what sidebar you want to use
|
||||
mc0 = 'col-md-12'
|
||||
@@ -55,6 +46,7 @@
|
||||
}}
|
||||
</head>
|
||||
<body>
|
||||
<!--[if lt IE 8]><p class="browserupgrade">You are using an <strong>outdated</strong> browser. Please <a href="http://browsehappy.com/">upgrade your browser</a> to improve your experience.</p><![endif]-->
|
||||
<div class="flash alert alert-dismissable">{{=response.flash or ''}}</div>
|
||||
<!-- Navbar ======================================= -->
|
||||
<nav class="navbar navbar-inverse navbar-fixed-top" role="navigation">
|
||||
@@ -78,56 +70,49 @@
|
||||
</div>
|
||||
</div>
|
||||
</nav>
|
||||
<!-- Masthead ===================================== -->
|
||||
{{if URL()==URL('default','index'):}}
|
||||
<header class="container-full">
|
||||
<div class="jumbotron text-center background">
|
||||
{{if response.title:}}
|
||||
<h1>{{=response.title}}
|
||||
<small>{{=response.subtitle or ''}}</small></h1>
|
||||
{{pass}}
|
||||
</div>
|
||||
</header>
|
||||
{{pass}}
|
||||
<!-- Masthead ===================================== -->
|
||||
{{block header}}
|
||||
{{end}}
|
||||
<!-- Main ========================================= -->
|
||||
<main class="container" id="content" role="main">
|
||||
<div class="row">
|
||||
{{if left_sidebar_enabled:}}
|
||||
<!-- left sidebar ---------------------------------------------------------- -->
|
||||
<div class="col-md-3">
|
||||
{{block left_sidebar}}
|
||||
{{end left_sidebar}}
|
||||
</div>
|
||||
{{pass}}
|
||||
<!-- central column -------------------------------------------------------- -->
|
||||
<div class="{{=middle_column}}">
|
||||
{{block center_page}}
|
||||
{{include}}
|
||||
{{end center_page}}
|
||||
</div>
|
||||
{{if right_sidebar_enabled:}}
|
||||
<!-- right sidebar --------------------------------------------------------- -->
|
||||
<div class="col-md-3">
|
||||
{{block right_sidebar}}
|
||||
{{end right_sidebar}}
|
||||
</div>
|
||||
{{pass}}
|
||||
</div>
|
||||
</main>
|
||||
<!-- Footer ======================================= -->
|
||||
<!-- Begin page content -->
|
||||
<div class="container-fluid">
|
||||
{{if left_sidebar_enabled:}}
|
||||
<div class="col-md-3 left-sidebar">
|
||||
{{block left_sidebar}}
|
||||
<h3>Left Sidebar</h3>
|
||||
<p></p>
|
||||
{{end}}
|
||||
</div>
|
||||
{{pass}}
|
||||
|
||||
<footer class="container-full">
|
||||
<div class="row">
|
||||
{{block footer}}
|
||||
<div class="col-xs-6">
|
||||
<p>{{=T('Copyright')}} © {{=request.now.year}}</p>
|
||||
<div class="{{=middle_column}}">
|
||||
{{block center}}
|
||||
{{include}}
|
||||
{{end}}
|
||||
</div>
|
||||
|
||||
{{if right_sidebar_enabled:}}
|
||||
<div class="col-md-3">
|
||||
{{block right_sidebar}}
|
||||
<h3>Right Sidebar</h3>
|
||||
<p></p>
|
||||
{{end}}
|
||||
</div>
|
||||
<div class="col-xs-6">
|
||||
<p class="pull-right">{{=T('Powered by')}} <a href="http://www.web2py.com/">web2py</a></p>
|
||||
</div>
|
||||
{{end footer}}
|
||||
{{pass}}
|
||||
|
||||
</div>
|
||||
|
||||
{{block footer}} <!-- this is default footer -->
|
||||
<footer class="footer">
|
||||
<div class="container-fluid">
|
||||
<div class="copyright pull-left">{{=T('Copyright')}} © {{=request.now.year}}</div>
|
||||
<div id="poweredBy" class="pull-right">
|
||||
{{=T('Powered by')}}
|
||||
<a href="http://www.web2py.com/">web2py</a>
|
||||
</div>
|
||||
</div>
|
||||
</footer>
|
||||
{{end}}
|
||||
<!-- The javascript =============================== -->
|
||||
<script src="{{=URL('static','js/bootstrap.min.js')}}"></script>
|
||||
<script src="{{=URL('static','js/web2py-bootstrap3.js')}}"></script>
|
||||
|
||||
+1
-1
@@ -20,7 +20,7 @@ try:
|
||||
os.path.dirname(os.path.abspath(__file__)), "packages", "dal"))
|
||||
import pydal
|
||||
sys.modules['pydal'] = pydal
|
||||
except:
|
||||
except ImportError:
|
||||
raise RuntimeError(
|
||||
"web2py depends on pydal, which apparently you have not installed.\n" +
|
||||
"Probably you cloned the repository using git without '--recursive'" +
|
||||
|
||||
@@ -134,6 +134,8 @@ class DAL(pyDAL):
|
||||
'rows_render': sqlhtml.represent,
|
||||
'rows_xml': sqlhtml.SQLTABLE
|
||||
}
|
||||
Field = Field
|
||||
Table = Table
|
||||
|
||||
#: add web2py contrib drivers to pyDAL
|
||||
from pydal.drivers import DRIVERS
|
||||
|
||||
+1
-1
Submodule gluon/packages/dal updated: ccda442484...9bc003583a
+6
-3
@@ -3518,7 +3518,7 @@ class Auth(object):
|
||||
self.db(self.table_group().id == group_id).delete()
|
||||
self.db(self.table_membership().group_id == group_id).delete()
|
||||
self.db(self.table_permission().group_id == group_id).delete()
|
||||
self.update_groups()
|
||||
if group_id in self.user_groups: del self.user_groups[group_id]
|
||||
self.log_event(self.messages.del_group_log, dict(group_id=group_id))
|
||||
|
||||
def id_group(self, role):
|
||||
@@ -3587,7 +3587,10 @@ class Auth(object):
|
||||
return record.id
|
||||
else:
|
||||
id = membership.insert(group_id=group_id, user_id=user_id)
|
||||
self.update_groups()
|
||||
if role:
|
||||
self.user_groups[group_id] = role
|
||||
else:
|
||||
self.update_groups()
|
||||
self.log_event(self.messages['add_membership_log'],
|
||||
dict(user_id=user_id, group_id=group_id))
|
||||
return id
|
||||
@@ -3607,7 +3610,7 @@ class Auth(object):
|
||||
ret = self.db(membership.user_id
|
||||
== user_id)(membership.group_id
|
||||
== group_id).delete()
|
||||
self.update_groups()
|
||||
if group_id in self.user_groups: del self.user_groups[group_id]
|
||||
return ret
|
||||
|
||||
def has_permission(
|
||||
|
||||
Reference in New Issue
Block a user