[MERGE] Sync with saas-3
bzr revid: tde@openerp.com-20140303110400-arkw9yciv4eopb5a
This commit is contained in:
commit
d417da6c1a
|
@ -15,6 +15,7 @@ from openerp.tools.translate import _
|
|||
|
||||
_logger = logging.getLogger(__name__)
|
||||
|
||||
|
||||
#----------------------------------------------------------
|
||||
# helpers
|
||||
#----------------------------------------------------------
|
||||
|
@ -30,11 +31,15 @@ def fragment_to_query_string(func):
|
|||
var s = l.search ? (l.search === '?' ? '' : '&') : '?';
|
||||
r = l.pathname + l.search + s + q;
|
||||
}
|
||||
if (r == l) {
|
||||
r = '/';
|
||||
}
|
||||
window.location = r;
|
||||
</script></head><body></body></html>"""
|
||||
return func(self, *a, **kw)
|
||||
return wrapper
|
||||
|
||||
|
||||
#----------------------------------------------------------
|
||||
# Controller
|
||||
#----------------------------------------------------------
|
||||
|
@ -88,6 +93,7 @@ class OAuthLogin(openerp.addons.web.controllers.main.Home):
|
|||
|
||||
return response
|
||||
|
||||
|
||||
class OAuthController(http.Controller):
|
||||
|
||||
@http.route('/auth_oauth/signin', type='http', auth='none')
|
||||
|
|
|
@ -32,18 +32,17 @@
|
|||
<form class="oe_signup_form" role="form" method="post">
|
||||
<t t-call="web.database_select"/>
|
||||
|
||||
<div class="form-group field-login">
|
||||
<label for="login" class="control-label">Your Email</label>
|
||||
<input type="email" name="login" t-att-value="login" id="login" class="form-control" autofocus="autofocus"
|
||||
required="required" t-att-disabled="'disabled' if mode == 'reset' and token else None"/>
|
||||
<input type="hidden" name="login" t-att-value="login" t-if="mode == 'reset' and token"/>
|
||||
</div>
|
||||
|
||||
<div class="form-group field-name" t-if="not reset_without_token">
|
||||
<label for="name" class="control-label">Your Name</label>
|
||||
<input type="text" name="name" t-att-value="name" id="name" class="form-control" placeholder="e.g. John Doe"
|
||||
required="required" autofocus="autofocus" t-att-disabled="'disabled' if mode == 'reset' and token else None"/>
|
||||
</div>
|
||||
|
||||
<div class="form-group field-login">
|
||||
<label for="login" class="control-label">Your Email</label>
|
||||
<input type="email" name="login" t-att-value="login" id="login" class="form-control"
|
||||
t-att-autofocus="'autofocus' if reset_without_token else None"
|
||||
required="required" t-att-disabled="'disabled' if mode == 'reset' and token else None"/>
|
||||
<input type="hidden" name="login" t-att-value="login" t-if="mode == 'reset' and token"/>
|
||||
</div>
|
||||
|
||||
<div class="form-group field-password" t-if="not reset_without_token">
|
||||
|
|
|
@ -363,7 +363,7 @@ class calendar_alarm_manager(osv.AbstractModel):
|
|||
"""
|
||||
|
||||
filter_user = """
|
||||
LEFT JOIN calendar_event_res_partner_rel AS part_rel ON part_rel.calendar_event_id = cal.id
|
||||
RIGHT JOIN calendar_event_res_partner_rel AS part_rel ON part_rel.calendar_event_id = cal.id
|
||||
AND part_rel.res_partner_id = %s
|
||||
"""
|
||||
|
||||
|
@ -1515,7 +1515,7 @@ class calendar_event(osv.Model):
|
|||
continue
|
||||
if r['class'] == 'private':
|
||||
for f in r.keys():
|
||||
if f not in ('id', 'date', 'date_deadline', 'duration', 'user_id', 'state', 'interval', 'count'):
|
||||
if f not in ('id', 'date', 'date_deadline', 'duration', 'user_id', 'state', 'interval', 'count', 'recurrent_id_date'):
|
||||
if isinstance(r[f], list):
|
||||
r[f] = []
|
||||
else:
|
||||
|
|
|
@ -151,50 +151,58 @@
|
|||
</td>
|
||||
<td>
|
||||
<table cellspacing="0" cellpadding="0" border="0" style="margin-top: 15px; margin-left: 10px;font-size: 16px;">
|
||||
% if object.event_id.location:
|
||||
<tr style=" height: 30px;">
|
||||
<tr>
|
||||
<td style="vertical-align:top;">
|
||||
<div style="height: 25px; width: 120px; background : # CCCCCC; font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
Where
|
||||
</div>
|
||||
</td>
|
||||
<td colspan="1" style="vertical-align:top;">
|
||||
<div style = "font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif; font-size: 14px" >
|
||||
: ${object.event_id.location}
|
||||
<span style= "color:#A9A9A9; ">(<a href="http://maps.google.com/maps?oi=map&q=${object.event_id.location}">View Map</a>)
|
||||
</span>
|
||||
</div>
|
||||
% if object.event_id.location:
|
||||
<div style="width: 120px; background : #CCCCCC; font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
Where
|
||||
</div>
|
||||
% endif
|
||||
</td>
|
||||
<td style="vertical-align:top;">
|
||||
% if object.event_id.location:
|
||||
<div style = "font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif; font-size: 14px" >
|
||||
: ${object.event_id.location}
|
||||
<span style= "color:#A9A9A9; ">(<a href="http://maps.google.com/maps?oi=map&q=${object.event_id.location}">View Map</a>)
|
||||
</span>
|
||||
</div>
|
||||
% endif
|
||||
</td>
|
||||
</tr>
|
||||
% endif
|
||||
% if object.event_id.description :
|
||||
<tr style=" height:auto;">
|
||||
|
||||
<tr>
|
||||
<td style="vertical-align:top;">
|
||||
<div style="height:auto; width: 120px; background : # CCCCCC; font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
What
|
||||
</div>
|
||||
% if object.event_id.description :
|
||||
<div style="width: 120px; background : #CCCCCC; font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
What
|
||||
</div>
|
||||
% endif
|
||||
</td>
|
||||
<td colspan="3" style="vertical-align:text-top;">
|
||||
<div style="font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
: ${object.event_id.description}
|
||||
</div>
|
||||
<td style="vertical-align:text-top;">
|
||||
% if object.event_id.description :
|
||||
<div style="font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
: ${object.event_id.description}
|
||||
</div>
|
||||
% endif
|
||||
</td>
|
||||
</tr>
|
||||
% endif
|
||||
% if not object.event_id.allday and object.event_id.duration:
|
||||
<tr style=" height:auto;">
|
||||
|
||||
<tr>
|
||||
<td style="vertical-align:top;">
|
||||
<div style="height:auto; width: 120px; background : # CCCCCC; font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
Duration
|
||||
</div>
|
||||
% if not object.event_id.allday and object.event_id.duration:
|
||||
<div style="height:auto; width: 120px; background : #CCCCCC; font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
Duration
|
||||
</div>
|
||||
% endif
|
||||
</td>
|
||||
<td colspan="3" style="vertical-align:text-top;">
|
||||
<div style="font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
: ${('%dH%02d' % (object.event_id.duration,(object.event_id.duration*60)%60))}
|
||||
</div>
|
||||
% if not object.event_id.allday and object.event_id.duration:
|
||||
<div style="font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
: ${('%dH%02d' % (object.event_id.duration,(object.event_id.duration*60)%60))}
|
||||
</div>
|
||||
% endif
|
||||
</td>
|
||||
</tr>
|
||||
% endif
|
||||
</tr>
|
||||
<tr style=" height: 30px;">
|
||||
<td style="height: 25px;width: 120px; background : # CCCCCC; font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
<div>
|
||||
|
@ -219,9 +227,9 @@
|
|||
</table>
|
||||
</div>
|
||||
<div style="height: auto;width:450px; margin:0 auto;padding-top:20px;padding-bottom:40px;">
|
||||
<a style="padding: 8px 30px 8px 30px;border-radius: 6px;border: 1px solid #CCCCCC;background:#8A89BA;margin : 0 15px 0 0;text-decoration: none;color:#FFFFFF;" href="${ctx['base_url']}/calendar/meeting/accept?db=${ctx['dbname']}&token=${object.access_token}&action=${ctx['action_id']}&id=${object.event_id.id}">Accept</a>
|
||||
<a style="padding: 8px 30px 8px 30px;border-radius: 6px;border: 1px solid #CCCCCC;background:#808080;margin : 0 15px 0 0;text-decoration: none;color:#FFFFFF;" href="${ctx['base_url']}/calendar/meeting/decline?db=${ctx['dbname']}&token=${object.access_token}&action=${ctx['action_id']}&id=${object.event_id.id}">Decline</a>
|
||||
<a style="padding: 8px 30px 8px 30px;border-radius: 6px;border: 1px solid #CCCCCC;background:#D8D8D8;text-decoration: none;color:#FFFFFF;" href="${ctx['base_url']}/calendar/meeting/view?db=${ctx['dbname']}&token=${object.access_token}&action=${ctx['action_id']}&id=${object.event_id.id}">View</a>
|
||||
<a style="padding: 8px 30px 8px 30px;border-radius: 6px;border: 1px solid #CCCCCC;background:#8A89BA;margin : 0 15px 0 0;text-decoration: none;color:#FFFFFF;" href="/calendar/meeting/accept?db=${ctx['dbname']}&token=${object.access_token}&action=${ctx['action_id']}&id=${object.event_id.id}">Accept</a>
|
||||
<a style="padding: 8px 30px 8px 30px;border-radius: 6px;border: 1px solid #CCCCCC;background:#808080;margin : 0 15px 0 0;text-decoration: none;color:#FFFFFF;" href="/calendar/meeting/decline?db=${ctx['dbname']}&token=${object.access_token}&action=${ctx['action_id']}&id=${object.event_id.id}">Decline</a>
|
||||
<a style="padding: 8px 30px 8px 30px;border-radius: 6px;border: 1px solid #CCCCCC;background:#D8D8D8;text-decoration: none;color:#FFFFFF;" href="/calendar/meeting/view?db=${ctx['dbname']}&token=${object.access_token}&action=${ctx['action_id']}&id=${object.event_id.id}">View</a>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
|
@ -265,7 +273,7 @@
|
|||
</div>
|
||||
<div style="height: auto;margin-left:12px;margin-top:30px;">
|
||||
<table>
|
||||
<tr>
|
||||
<tr>
|
||||
<td>
|
||||
<div style="border-top-left-radius:3px;border-top-right-radius:3px;font-size:12px;border-collapse:separate;text-align:center;font-weight:bold;color:#ffffff;width:130px;min-height: 18px;border-color:#ffffff;background:#8a89ba;padding-top: 4px;">${object.event_id.get_interval(object.event_id.date, 'dayname')}</div>
|
||||
<div style="font-size:48px;min-height:auto;font-weight:bold;text-align:center;color: #5F5F5F;background-color: #E1E2F8;width: 130px;">
|
||||
|
@ -276,50 +284,58 @@
|
|||
</td>
|
||||
<td>
|
||||
<table cellspacing="0" cellpadding="0" border="0" style="margin-top: 15px; margin-left: 10px;font-size: 16px;">
|
||||
% if object.event_id.location:
|
||||
<tr style=" height: 30px;">
|
||||
<tr>
|
||||
<td style="vertical-align:top;">
|
||||
<div style="height: 25px; width: 120px; background : # CCCCCC; font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
Where
|
||||
</div>
|
||||
</td>
|
||||
<td colspan="1" style="vertical-align:top;">
|
||||
<div style = "font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif; font-size: 14px" >
|
||||
: ${object.event_id.location}
|
||||
<span style= "color:#A9A9A9; ">(<a href="http://maps.google.com/maps?oi=map&q=${object.event_id.location}">View Map</a>)
|
||||
</span>
|
||||
</div>
|
||||
% if object.event_id.location:
|
||||
<div style="width: 120px; background : #CCCCCC; font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
Where
|
||||
</div>
|
||||
% endif
|
||||
</td>
|
||||
<td style="vertical-align:top;">
|
||||
% if object.event_id.location:
|
||||
<div style = "font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif; font-size: 14px" >
|
||||
: ${object.event_id.location}
|
||||
<span style= "color:#A9A9A9; ">(<a href="http://maps.google.com/maps?oi=map&q=${object.event_id.location}">View Map</a>)
|
||||
</span>
|
||||
</div>
|
||||
% endif
|
||||
</td>
|
||||
</tr>
|
||||
% endif
|
||||
% if object.event_id.description :
|
||||
<tr style=" height:auto;">
|
||||
|
||||
<tr>
|
||||
<td style="vertical-align:top;">
|
||||
<div style="height:auto; width: 120px; background : # CCCCCC; font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
What
|
||||
</div>
|
||||
% if object.event_id.description :
|
||||
<div style="width: 120px; background : #CCCCCC; font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
What
|
||||
</div>
|
||||
% endif
|
||||
</td>
|
||||
<td colspan="3" style="vertical-align:text-top;">
|
||||
<div style="font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
: ${object.event_id.description}
|
||||
</div>
|
||||
<td style="vertical-align:text-top;">
|
||||
% if object.event_id.description :
|
||||
<div style="font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
: ${object.event_id.description}
|
||||
</div>
|
||||
% endif
|
||||
</td>
|
||||
</tr>
|
||||
% endif
|
||||
% if not object.event_id.allday and object.event_id.duration:
|
||||
<tr style=" height:auto;">
|
||||
|
||||
<tr>
|
||||
<td style="vertical-align:top;">
|
||||
<div style="height:auto; width: 120px; background : # CCCCCC; font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
Duration
|
||||
</div>
|
||||
% if not object.event_id.allday and object.event_id.duration:
|
||||
<div style="height:auto; width: 120px; background : #CCCCCC; font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
Duration
|
||||
</div>
|
||||
% endif
|
||||
</td>
|
||||
<td colspan="3" style="vertical-align:text-top;">
|
||||
<div style="font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
: ${('%dH%02d' % (object.event_id.duration,(object.event_id.duration*60)%60))}
|
||||
</div>
|
||||
% if not object.event_id.allday and object.event_id.duration:
|
||||
<div style="font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
: ${('%dH%02d' % (object.event_id.duration,(object.event_id.duration*60)%60))}
|
||||
</div>
|
||||
% endif
|
||||
</td>
|
||||
</tr>
|
||||
% endif
|
||||
</tr>
|
||||
<tr style=" height: 30px;">
|
||||
<td style="height: 25px;width: 120px; background : # CCCCCC; font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
<div>
|
||||
|
@ -341,12 +357,12 @@
|
|||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</table>
|
||||
</div>
|
||||
<div style="height: auto;width:450px; margin:0 auto;padding-top:20px;padding-bottom:40px;">
|
||||
<a style="padding: 8px 30px 8px 30px;border-radius: 6px;border: 1px solid #CCCCCC;background:#8A89BA;margin : 0 15px 0 0;text-decoration: none;color:#FFFFFF;" href="${ctx['base_url']}/calendar/meeting/accept?db=${ctx['dbname']}&token=${object.access_token}&action=${ctx['action_id']}&id=${object.event_id.id}">Accept</a>
|
||||
<a style="padding: 8px 30px 8px 30px;border-radius: 6px;border: 1px solid #CCCCCC;background:#808080;margin : 0 15px 0 0;text-decoration: none;color:#FFFFFF;" href="${ctx['base_url']}/calendar/meeting/decline?db=${ctx['dbname']}&token=${object.access_token}&action=${ctx['action_id']}&id=${object.event_id.id}">Decline</a>
|
||||
<a style="padding: 8px 30px 8px 30px;border-radius: 6px;border: 1px solid #CCCCCC;background:#D8D8D8;text-decoration: none;color:#FFFFFF;" href="${ctx['base_url']}/calendar/meeting/view?db=${ctx['dbname']}&token=${object.access_token}&action=${ctx['action_id']}&id=${object.event_id.id}">View</a>
|
||||
<a style="padding: 8px 30px 8px 30px;border-radius: 6px;border: 1px solid #CCCCCC;background:#8A89BA;margin : 0 15px 0 0;text-decoration: none;color:#FFFFFF;" href="/calendar/meeting/accept?db=${ctx['dbname']}&token=${object.access_token}&action=${ctx['action_id']}&id=${object.event_id.id}">Accept</a>
|
||||
<a style="padding: 8px 30px 8px 30px;border-radius: 6px;border: 1px solid #CCCCCC;background:#808080;margin : 0 15px 0 0;text-decoration: none;color:#FFFFFF;" href="/calendar/meeting/decline?db=${ctx['dbname']}&token=${object.access_token}&action=${ctx['action_id']}&id=${object.event_id.id}">Decline</a>
|
||||
<a style="padding: 8px 30px 8px 30px;border-radius: 6px;border: 1px solid #CCCCCC;background:#D8D8D8;text-decoration: none;color:#FFFFFF;" href="/calendar/meeting/view?db=${ctx['dbname']}&token=${object.access_token}&action=${ctx['action_id']}&id=${object.event_id.id}">View</a>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
|
@ -400,50 +416,58 @@
|
|||
</td>
|
||||
<td>
|
||||
<table cellspacing="0" cellpadding="0" border="0" style="margin-top: 15px; margin-left: 10px;font-size: 16px;">
|
||||
% if object.event_id.location:
|
||||
<tr style=" height: 30px;">
|
||||
<tr>
|
||||
<td style="vertical-align:top;">
|
||||
<div style="height: 25px; width: 120px; background : # CCCCCC; font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
Where
|
||||
</div>
|
||||
</td>
|
||||
<td colspan="1" style="vertical-align:top;">
|
||||
<div style = "font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif; font-size: 14px" >
|
||||
: ${object.event_id.location}
|
||||
<span style= "color:#A9A9A9; ">(<a href="http://maps.google.com/maps?oi=map&q=${object.event_id.location}">View Map</a>)
|
||||
</span>
|
||||
</div>
|
||||
% if object.event_id.location:
|
||||
<div style="width: 120px; background : #CCCCCC; font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
Where
|
||||
</div>
|
||||
% endif
|
||||
</td>
|
||||
<td style="vertical-align:top;">
|
||||
% if object.event_id.location:
|
||||
<div style = "font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif; font-size: 14px" >
|
||||
: ${object.event_id.location}
|
||||
<span style= "color:#A9A9A9; ">(<a href="http://maps.google.com/maps?oi=map&q=${object.event_id.location}">View Map</a>)
|
||||
</span>
|
||||
</div>
|
||||
% endif
|
||||
</td>
|
||||
</tr>
|
||||
% endif
|
||||
% if object.event_id.description :
|
||||
<tr style=" height:auto;">
|
||||
|
||||
<tr>
|
||||
<td style="vertical-align:top;">
|
||||
<div style="height:auto; width: 120px; background : # CCCCCC; font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
What
|
||||
</div>
|
||||
% if object.event_id.description :
|
||||
<div style="width: 120px; background : #CCCCCC; font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
What
|
||||
</div>
|
||||
% endif
|
||||
</td>
|
||||
<td colspan="3" style="vertical-align:text-top;">
|
||||
<div style="font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
: ${object.event_id.description}
|
||||
</div>
|
||||
<td style="vertical-align:text-top;">
|
||||
% if object.event_id.description :
|
||||
<div style="font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
: ${object.event_id.description}
|
||||
</div>
|
||||
% endif
|
||||
</td>
|
||||
</tr>
|
||||
% endif
|
||||
% if not object.event_id.allday and object.event_id.duration:
|
||||
<tr style=" height:auto;">
|
||||
|
||||
<tr>
|
||||
<td style="vertical-align:top;">
|
||||
<div style="height:auto; width: 120px; background : # CCCCCC; font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
Duration
|
||||
</div>
|
||||
% if not object.event_id.allday and object.event_id.duration:
|
||||
<div style="height:auto; width: 120px; background : #CCCCCC; font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
Duration
|
||||
</div>
|
||||
% endif
|
||||
</td>
|
||||
<td colspan="3" style="vertical-align:text-top;">
|
||||
<div style="font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
: ${('%dH%02d' % (object.event_id.duration,(object.event_id.duration*60)%60))}
|
||||
</div>
|
||||
% if not object.event_id.allday and object.event_id.duration:
|
||||
<div style="font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
: ${('%dH%02d' % (object.event_id.duration,(object.event_id.duration*60)%60))}
|
||||
</div>
|
||||
% endif
|
||||
</td>
|
||||
</tr>
|
||||
% endif
|
||||
</tr>
|
||||
<tr style=" height: 30px;">
|
||||
<td style="height: 25px;width: 120px; background : # CCCCCC; font-family: Lucica Grande', Ubuntu, Arial, Verdana, sans-serif;">
|
||||
<div>
|
||||
|
|
|
@ -186,12 +186,11 @@ class IrAttachment(osv.Model):
|
|||
def get_attachment_type(self, cr, uid, ids, name, args, context=None):
|
||||
result = {}
|
||||
for attachment in self.browse(cr, uid, ids, context=context):
|
||||
fileext = os.path.splitext(attachment.datas_fname)[1].lower()
|
||||
if not fileext or not fileext[1:] in self._fileext_to_type:
|
||||
return 'unknown'
|
||||
result[attachment.id] = self._fileext_to_type[fileext[1:]]
|
||||
fileext = os.path.splitext(attachment.datas_fname or '')[1].lower()[1:]
|
||||
result[attachment.id] = self._fileext_to_type.get(fileext, 'unknown')
|
||||
return result
|
||||
|
||||
_columns = {
|
||||
'file_type': fields.function(get_attachment_type, type='char', string='File Type'),
|
||||
'file_type_icon': fields.function(get_attachment_type, type='char', string='File Type Icon'),
|
||||
'file_type': fields.related('file_type_icon', type='char'), # FIXME remove in trunk
|
||||
}
|
||||
|
|
|
@ -351,12 +351,12 @@ class mail_message(osv.Model):
|
|||
partner_tree = dict((partner[0], partner) for partner in partners)
|
||||
|
||||
# 2. Attachments as SUPERUSER, because could receive msg and attachments for doc uid cannot see
|
||||
attachments = ir_attachment_obj.read(cr, SUPERUSER_ID, list(attachment_ids), ['id', 'datas_fname', 'name', 'file_type'], context=context)
|
||||
attachments = ir_attachment_obj.read(cr, SUPERUSER_ID, list(attachment_ids), ['id', 'datas_fname', 'name', 'file_type_icon'], context=context)
|
||||
attachments_tree = dict((attachment['id'], {
|
||||
'id': attachment['id'],
|
||||
'filename': attachment['datas_fname'],
|
||||
'name': attachment['name'],
|
||||
'file_type': attachment['file_type'],
|
||||
'file_type_icon': attachment['file_type_icon'],
|
||||
}) for attachment in attachments)
|
||||
|
||||
# 3. Update message dictionaries
|
||||
|
|
|
@ -88,10 +88,10 @@
|
|||
-->
|
||||
<t t-name="mail.thread.message.attachments">
|
||||
<t t-foreach='widget.attachment_ids' t-as='attachment'>
|
||||
<t t-if="attachment.file_type !== 'webimage'">
|
||||
<t t-if="attachment.file_type_icon !== 'webimage'">
|
||||
<div t-attf-class="oe_attachment #{attachment.upload ? 'oe_uploading' : ''}">
|
||||
<a t-att-href='attachment.url' target="_blank">
|
||||
<img t-att-src="'/mail/static/src/img/mimetypes/' + attachment.file_type + '.png'"></img>
|
||||
<img t-att-src="'/mail/static/src/img/mimetypes/' + attachment.file_type_icon + '.png'"></img>
|
||||
<div class='oe_name'><t t-raw='attachment.name' /></div>
|
||||
</a>
|
||||
<div class='oe_delete oe_e' title="Delete this attachment" t-att-data-id="attachment.id">[</div>
|
||||
|
@ -100,7 +100,7 @@
|
|||
</div>
|
||||
</div>
|
||||
</t>
|
||||
<t t-if="attachment.file_type === 'webimage'">
|
||||
<t t-if="attachment.file_type_icon === 'webimage'">
|
||||
<div t-attf-class="oe_attachment oe_preview #{attachment.upload ? 'oe_uploading' : ''}">
|
||||
<a t-att-href='attachment.url' target="_blank">
|
||||
<img t-att-src="widget.attachments_resize_image(attachment.id, [100,80])"></img>
|
||||
|
|
|
@ -30,10 +30,10 @@ class PaymentAcquirerOgone(osv.Model):
|
|||
@TDETODO: complete me
|
||||
"""
|
||||
return {
|
||||
'ogone_standard_order_url': 'https://secure.ogone.com/ncol/%s/orderstandard.asp' % env,
|
||||
'ogone_direct_order_url': 'https://secure.ogone.com/ncol/%s/orderdirect.asp' % env,
|
||||
'ogone_direct_query_url': 'https://secure.ogone.com/ncol/%s/querydirect.asp' % env,
|
||||
'ogone_afu_agree_url': 'https://secure.ogone.com/ncol/%s/AFU_agree.asp' % env,
|
||||
'ogone_standard_order_url': 'https://secure.ogone.com/ncol/%s/orderstandard_utf8.asp' % (env,),
|
||||
'ogone_direct_order_url': 'https://secure.ogone.com/ncol/%s/orderdirect_utf8.asp' % (env,),
|
||||
'ogone_direct_query_url': 'https://secure.ogone.com/ncol/%s/querydirect_utf8.asp' % (env,),
|
||||
'ogone_afu_agree_url': 'https://secure.ogone.com/ncol/%s/AFU_agree.asp' % (env,),
|
||||
}
|
||||
|
||||
_columns = {
|
||||
|
|
|
@ -70,6 +70,7 @@ class AcquirerPaypal(osv.Model):
|
|||
else:
|
||||
paypal_view = self.pool['ir.model.data'].get_object(cr, uid, 'payment_paypal', 'paypal_acquirer_button')
|
||||
self.create(cr, uid, {
|
||||
'name': 'paypal',
|
||||
'paypal_email_account': company_paypal_account,
|
||||
'view_template_id': paypal_view.id,
|
||||
}, context=context)
|
||||
|
|
|
@ -572,7 +572,7 @@ class res_partner(osv.osv):
|
|||
def google_map_img(self, cr, uid, ids, zoom=8, width=298, height=298, context=None):
|
||||
partner = self.browse(cr, uid, ids[0], context=context)
|
||||
params = {
|
||||
'center': '%s, %s %s, %s' % (partner.street, partner.city, partner.zip, partner.country_id and partner.country_id.name_get()[0][1] or ''),
|
||||
'center': '%s, %s %s, %s' % (partner.street or '', partner.city or '', partner.zip or '', partner.country_id and partner.country_id.name_get()[0][1] or ''),
|
||||
'size': "%sx%s" % (height, width),
|
||||
'zoom': zoom,
|
||||
'sensor': 'false',
|
||||
|
|
|
@ -394,22 +394,15 @@ div.carousel[data-snippet-id="slider"] .carousel-indicators .active {
|
|||
}
|
||||
|
||||
.parallax {
|
||||
position: relative;
|
||||
background-size: cover;
|
||||
display: table;
|
||||
width: 100%;
|
||||
min-height: 100px;
|
||||
}
|
||||
.parallax.oe_small {
|
||||
min-height: 200px;
|
||||
}
|
||||
.parallax.oe_medium {
|
||||
min-height: 300px;
|
||||
}
|
||||
.parallax.oe_big {
|
||||
min-height: 450px;
|
||||
}
|
||||
.parallax > div {
|
||||
position: relative;
|
||||
display: table;
|
||||
width: 100%;
|
||||
min-height: 200px;
|
||||
}
|
||||
.parallax > div > div {
|
||||
display: table-cell;
|
||||
vertical-align: middle;
|
||||
padding: 32px 0;
|
||||
|
|
|
@ -324,21 +324,16 @@ div.carousel[data-snippet-id="slider"]
|
|||
background-color: grey
|
||||
|
||||
.parallax
|
||||
position: relative
|
||||
background-size: cover
|
||||
display: table
|
||||
width: 100%
|
||||
min-height: 100px
|
||||
&.oe_small
|
||||
min-height: 200px
|
||||
&.oe_medium
|
||||
min-height: 300px
|
||||
&.oe_big
|
||||
min-height: 450px
|
||||
> div
|
||||
display: table-cell
|
||||
vertical-align: middle
|
||||
padding: 32px 0
|
||||
position: relative
|
||||
display: table
|
||||
width: 100%
|
||||
min-height: 200px
|
||||
> div
|
||||
display: table-cell
|
||||
vertical-align: middle
|
||||
padding: 32px 0
|
||||
|
||||
/* Background */
|
||||
|
||||
|
|
|
@ -20,6 +20,10 @@
|
|||
website.form(this.pathname, 'POST');
|
||||
});
|
||||
|
||||
$(document).on('click', '.cke_editable label', function (ev) {
|
||||
ev.preventDefault();
|
||||
});
|
||||
|
||||
$(document).on('submit', '.cke_editable form', function (ev) {
|
||||
// Disable form submition in editable mode
|
||||
ev.preventDefault();
|
||||
|
|
|
@ -64,6 +64,10 @@
|
|||
start: function () {
|
||||
this.$target.carousel({interval: 10000});
|
||||
},
|
||||
stop: function () {
|
||||
this.$target.carousel('pause');
|
||||
this.$target.removeData("bs.carousel");
|
||||
},
|
||||
});
|
||||
|
||||
website.snippet.animationRegistry.parallax = website.snippet.Animation.extend({
|
||||
|
|
|
@ -19,13 +19,23 @@
|
|||
edit: function () {
|
||||
var self = this;
|
||||
$("body").off('click');
|
||||
website.snippet.stop_animation();
|
||||
window.snippets = this.snippets = new website.snippet.BuildingBlock(this);
|
||||
this.snippets.appendTo(this.$el);
|
||||
|
||||
this.on('rte:ready', this, function () {
|
||||
self.snippets.$button.removeClass("hidden");
|
||||
website.snippet.stop_animation();
|
||||
website.snippet.start_animation();
|
||||
$(website.snippet.readyAnimation).each(function() {
|
||||
var animation = $(this).data("snippet-view");
|
||||
if (animation) {
|
||||
animation.$target.on('focus', '*', function(){
|
||||
animation.stop();
|
||||
});
|
||||
animation.$target.on('blur', '*', function(){
|
||||
animation.start();
|
||||
});
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
return this._super.apply(this, arguments);
|
||||
|
@ -1232,7 +1242,6 @@
|
|||
on_clone: function () {
|
||||
var $clone = this.$target.clone(false);
|
||||
var _class = $clone.attr("class").replace(/\s*(col-lg-offset-|col-md-offset-)([0-9-]+)/g, '');
|
||||
_class += ' col-md-1';
|
||||
$clone.attr("class", _class);
|
||||
this.$target.after($clone);
|
||||
this.hide_remove_button();
|
||||
|
@ -1315,7 +1324,6 @@
|
|||
this.$editor.find(".js_add").on('click', function () {self.on_add_slide(); return false;});
|
||||
this.$editor.find(".js_remove").on('click', function () {self.on_remove_slide(); return false;});
|
||||
|
||||
this.$target.carousel('pause');
|
||||
this.rebind_event();
|
||||
},
|
||||
on_add_slide: function () {
|
||||
|
@ -1458,7 +1466,10 @@
|
|||
self.$target.data("snippet-view").set_values();
|
||||
});
|
||||
this.$target.attr('contentEditable', 'false');
|
||||
this.$target.find('> div > .oe_structure').attr('contentEditable', 'true');
|
||||
|
||||
this.$target.find('> div > .oe_structure').attr('contentEditable', 'true'); // saas-3 retro-compatibility
|
||||
|
||||
this.$target.find('> div > div:not(.oe_structure) > .oe_structure').attr('contentEditable', 'true');
|
||||
},
|
||||
scroll: function () {
|
||||
var self = this;
|
||||
|
|
|
@ -792,7 +792,7 @@
|
|||
</ul>
|
||||
</li>
|
||||
<section class="oe_snippet_body parallax"
|
||||
style="height: 320px; background-image: url('/website/static/src/img/banner/mountains.jpg')"
|
||||
style="background-image: url('/website/static/src/img/banner/mountains.jpg')"
|
||||
data-scroll-background-ratio="0.3">
|
||||
<div><div class="oe_structure"/></div>
|
||||
</section>
|
||||
|
@ -804,10 +804,9 @@
|
|||
<span class="oe_snippet_thumbnail_title">Parallax Slider</span>
|
||||
</div>
|
||||
<section class="oe_snippet_body parallax" data-snippet-id="parallax"
|
||||
style="height: 320px; background-image: url('/website/static/src/img/parallax/quote.png')"
|
||||
style="background-image: url('/website/static/src/img/parallax/quote.png')"
|
||||
data-scroll-background-ratio="0.3">
|
||||
<div>
|
||||
<div class="oe_structure">
|
||||
<div><div><div class="oe_structure">
|
||||
<div id="myQuoteCarousel" class="carousel quotecarousel slide mb0" data-snippet-id="slider">
|
||||
<!-- Indicators -->
|
||||
<ol class="carousel-indicators mb0">
|
||||
|
@ -854,8 +853,7 @@
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div></div></div>
|
||||
</section>
|
||||
</div>
|
||||
|
||||
|
|
|
@ -80,8 +80,8 @@
|
|||
|
||||
<script type="text/javascript" src="/website/static/src/js/website.js"></script>
|
||||
|
||||
<script type="text/javascript" src="/website/static/lib/bootstrap/js/bootstrap.js"></script>
|
||||
<script t-if="not translatable" type="text/javascript" src="/website/static/src/js/website.snippets.animation.js"></script>
|
||||
<script type="text/javascript" src="/website/static/lib/bootstrap/js/bootstrap.js"></script>
|
||||
|
||||
<t t-raw="head or ''" name='layout_head'/>
|
||||
</head>
|
||||
|
|
|
@ -66,7 +66,7 @@
|
|||
</t>
|
||||
</div>
|
||||
<div>
|
||||
<i class="fa fa-clock-o"></i> <span t-field="event.date_begin"> </span> <i>to</i> <span t-field="event.date_end"> </span>
|
||||
<i class="fa fa-clock-o"></i> <span t-field="event.date_begin" t-field-options='{"hide_seconds":"True"}'> </span> <i>to</i> <span t-field="event.date_end" t-field-options='{"hide_seconds":"True"}'> </span>
|
||||
</div>
|
||||
<div t-field="event.address_id" t-field-options='{
|
||||
"widget": "contact",
|
||||
|
@ -233,8 +233,8 @@
|
|||
<div class="container">
|
||||
<h1 class="text-center" t-field="event.name"></h1>
|
||||
<h4 class="text-center text-muted">
|
||||
<i class="fa fa-clock-o"></i> <span t-field="event.date_begin"/> to
|
||||
<span t-field="event.date_end"/>
|
||||
<i class="fa fa-clock-o"></i> <span t-field="event.date_begin" t-field-options='{"hide_seconds":"True"}'/> to
|
||||
<span t-field="event.date_end" t-field-options='{"hide_seconds":"True"}'/>
|
||||
</h4>
|
||||
<h4 class="text-center text-muted"
|
||||
t-field="event.address_id" t-field-options='{
|
||||
|
@ -278,7 +278,7 @@
|
|||
<t t-raw="comment.body"/>
|
||||
<small class="pull-right muted text-right">
|
||||
<div t-field="comment.author_id"/>
|
||||
<div t-field="comment.date"/>
|
||||
<div t-field="comment.date" t-field-options='{"hide_seconds":"True"}'/>
|
||||
</small>
|
||||
</div>
|
||||
</li>
|
||||
|
@ -307,8 +307,8 @@
|
|||
<h4>When</h4>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<i class="fa fa-clock-o"></i> from <span t-field="event.date_begin"> </span><br/>
|
||||
<i class="fa fa-clock-o"></i> to <span t-field="event.date_end"> </span>
|
||||
<i class="fa fa-clock-o"></i> From <span t-field="event.date_begin" t-field-options='{"hide_seconds":"True"}'> </span><br/>
|
||||
<i class="fa fa-clock-o"></i> To <span t-field="event.date_end" t-field-options='{"hide_seconds":"True"}'> </span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
|
|
@ -152,7 +152,7 @@
|
|||
<t t-esc="speaker.name"/>,
|
||||
</t>
|
||||
</li>
|
||||
<li class="text-muted fa fa-calendar"> <span t-field="track.date"/></li>
|
||||
<li class="text-muted fa fa-calendar"> <span t-field="track.date" t-field-options='{"hide_seconds":"True"}'/></li>
|
||||
<li class="text-muted fa fa-map-marker" t-if="track.location_id">
|
||||
<span t-field="track.location_id"/>
|
||||
</li>
|
||||
|
@ -230,7 +230,7 @@
|
|||
</div>
|
||||
<div class="panel-body">
|
||||
<b>Date</b><br/>
|
||||
<span t-field="track.date"/><br/>
|
||||
<span t-field="track.date" t-field-options='{"hide_seconds":"True"}'/><br/>
|
||||
<b>Duration</b><br/>
|
||||
<span t-field="track.duration"/> minutes<br/>
|
||||
<b>Location</b><br/>
|
||||
|
|
|
@ -51,14 +51,14 @@
|
|||
<section class="oe_container">
|
||||
<div class="oe_row">
|
||||
<h2 class="oe_slogan">Post Your Jobs on Best Job Boards</h2>
|
||||
<h3 class="oe_slogan">LinkedIn, Monster, Kraigslist, Careerbuilder,...</h3>
|
||||
<h3 class="oe_slogan">LinkedIn, Monster, Craigslist, Careerbuilder,...</h3>
|
||||
<div class="oe_span6">
|
||||
<img class="oe_picture oe_screenshot" src="jobs3.png">
|
||||
</div>
|
||||
<div class="oe_span6">
|
||||
<p class='oe_mt32'>
|
||||
Connect automatically to most famous job board websites;
|
||||
linkedIn, Monster, Kraigslist, ... Every job position has a new
|
||||
linkedIn, Monster, Craigslist, ... Every job position has a new
|
||||
email address automatically assigned to route applications
|
||||
automatically to the right job position.
|
||||
</p><p>
|
||||
|
|
|
@ -7,7 +7,7 @@ from openerp.addons.web.http import request
|
|||
|
||||
class WebsiteEmailDesigner(http.Controller):
|
||||
|
||||
@http.route('/website_mail/email_designer/<model("email.template"):template>/', type='http', auth="public", website=True, multilang=True)
|
||||
@http.route('/website_mail/email_designer/<model("email.template"):template>/', type='http', auth="user", website=True, multilang=True)
|
||||
def index(self, template, **kw):
|
||||
values = {
|
||||
'template': template,
|
||||
|
@ -15,6 +15,6 @@ class WebsiteEmailDesigner(http.Controller):
|
|||
print template
|
||||
return request.website.render("website_mail.designer_index", values)
|
||||
|
||||
@http.route(['/website_mail/snippets'], type='json', auth="public", website=True)
|
||||
@http.route(['/website_mail/snippets'], type='json', auth="user", website=True)
|
||||
def snippets(self):
|
||||
return request.website._render('website_mail.email_designer_snippets')
|
||||
|
|
|
@ -181,19 +181,29 @@ class Ecommerce(http.Controller):
|
|||
|
||||
return request.redirect(url)
|
||||
|
||||
def attributes_to_ids(self, attributes):
|
||||
obj = request.registry.get('product.attribute.line')
|
||||
domain = []
|
||||
def attributes_to_ids(self, cr, uid, attributes):
|
||||
req = """
|
||||
SELECT product_tmpl_id as id, count(*) as nb_match
|
||||
FROM product_attribute_line
|
||||
WHERE 1!=1
|
||||
"""
|
||||
nb = 0
|
||||
for key_val in attributes:
|
||||
domain.append(("attribute_id", "=", key_val[0]))
|
||||
attribute_id = key_val[0]
|
||||
if isinstance(key_val[1], list):
|
||||
domain.append(("value", ">=", key_val[1][0]))
|
||||
domain.append(("value", "<=", key_val[1][1]))
|
||||
req += " OR ( attribute_id = %s AND value >= %s AND value <= %s)" % \
|
||||
(attribute_id, key_val[1][0], key_val[1][1])
|
||||
nb += 1
|
||||
else:
|
||||
domain.append(("value_id", "in", key_val[1:]))
|
||||
att_ids = obj.search(request.cr, request.uid, domain, context=request.context)
|
||||
att = obj.read(request.cr, request.uid, att_ids, ["product_tmpl_id"], context=request.context)
|
||||
return [r["product_tmpl_id"][0] for r in att]
|
||||
for value_id in key_val[1:]:
|
||||
req += " OR ( attribute_id = %s AND value_id = %s)" % \
|
||||
(attribute_id, value_id)
|
||||
nb += 1
|
||||
|
||||
req += " GROUP BY product_tmpl_id"
|
||||
cr.execute(req)
|
||||
result = cr.fetchall()
|
||||
return [id for id, nb_match in result if nb_match >= nb]
|
||||
|
||||
@http.route(['/shop/pricelist'], type='http', auth="public", website=True, multilang=True)
|
||||
def shop_promo(self, promo=None, **post):
|
||||
|
@ -221,7 +231,7 @@ class Ecommerce(http.Controller):
|
|||
if filters:
|
||||
filters = simplejson.loads(filters)
|
||||
if filters:
|
||||
ids = self.attributes_to_ids(filters)
|
||||
ids = self.attributes_to_ids(cr, uid, filters)
|
||||
domain.append(('id', 'in', ids or [0]))
|
||||
|
||||
url = "/shop/"
|
||||
|
@ -422,12 +432,11 @@ class Ecommerce(http.Controller):
|
|||
|
||||
partner = None
|
||||
public_id = request.registry['website'].get_public_user(cr, uid, context)
|
||||
if not request.uid == public_id:
|
||||
if request.uid != public_id:
|
||||
partner = orm_user.browse(cr, uid, uid, context).partner_id
|
||||
elif order.partner_id:
|
||||
domain = [("active", "=", False), ("partner_id", "=", order.partner_id.id)]
|
||||
user_ids = request.registry['res.users'].search(cr, SUPERUSER_ID, domain, context=context)
|
||||
if not user_ids or public_id not in user_ids:
|
||||
public_partner = orm_user.browse(cr, SUPERUSER_ID, public_id, context=context).partner_id.id
|
||||
if public_partner != order.partner_id.id:
|
||||
partner = orm_partner.browse(cr, SUPERUSER_ID, order.partner_id.id, context)
|
||||
|
||||
if partner:
|
||||
|
@ -501,9 +510,8 @@ class Ecommerce(http.Controller):
|
|||
if request.uid != public_id:
|
||||
partner_id = orm_user.browse(cr, SUPERUSER_ID, uid, context=context).partner_id.id
|
||||
elif order.partner_id:
|
||||
domain = [("active", "=", False), ("partner_id", "=", order.partner_id.id)]
|
||||
user_ids = request.registry['res.users'].search(cr, SUPERUSER_ID, domain, context=context)
|
||||
if not user_ids or public_id not in user_ids:
|
||||
public_partner = orm_user.browse(cr, SUPERUSER_ID, public_id, context=context).partner_id.id
|
||||
if public_partner != order.partner_id.id:
|
||||
partner_id = order.partner_id.id
|
||||
|
||||
if partner_id:
|
||||
|
@ -705,7 +713,6 @@ class Ecommerce(http.Controller):
|
|||
- UDPATE ME
|
||||
"""
|
||||
cr, uid, context = request.cr, request.uid, request.context
|
||||
email_act = None
|
||||
sale_order_obj = request.registry['sale.order']
|
||||
|
||||
if transaction_id is None:
|
||||
|
@ -719,17 +726,19 @@ class Ecommerce(http.Controller):
|
|||
order = request.registry['sale.order'].browse(cr, SUPERUSER_ID, sale_order_id, context=context)
|
||||
assert order.website_session_id == request.httprequest.session['website_session_id']
|
||||
|
||||
if not tx or not order:
|
||||
if not order:
|
||||
return request.redirect('/shop/')
|
||||
elif order.amount_total and not tx:
|
||||
return request.redirect('/shop/mycart')
|
||||
|
||||
if not order.amount_total or tx.state == 'done':
|
||||
# confirm the quotation
|
||||
sale_order_obj.action_button_confirm(cr, SUPERUSER_ID, [order.id], context=request.context)
|
||||
# send by email
|
||||
email_act = sale_order_obj.action_quotation_send(cr, SUPERUSER_ID, [order.id], context=request.context)
|
||||
sale_order_obj.action_quotation_send(cr, SUPERUSER_ID, [order.id], context=request.context)
|
||||
elif tx.state == 'pending':
|
||||
# send by email
|
||||
email_act = sale_order_obj.action_quotation_send(cr, SUPERUSER_ID, [order.id], context=request.context)
|
||||
sale_order_obj.action_quotation_send(cr, SUPERUSER_ID, [order.id], context=request.context)
|
||||
elif tx.state == 'cancel':
|
||||
# cancel the quotation
|
||||
sale_order_obj.action_cancel(cr, SUPERUSER_ID, [order.id], context=request.context)
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
@charset "utf-8";
|
||||
/* ---- Default Styles ---- */
|
||||
.oe_product {
|
||||
border: 1px solid rgba(100, 100, 100, 0.2);
|
||||
|
@ -52,7 +53,7 @@
|
|||
right: 0;
|
||||
bottom: 0;
|
||||
overflow: hidden;
|
||||
padding: 0 15px;
|
||||
padding: 0 15px 24px 0;
|
||||
max-height: 110px;
|
||||
min-height: 56px;
|
||||
border-top: 1px solid rgba(255, 255, 255, 0.2);
|
||||
|
|
|
@ -47,7 +47,7 @@
|
|||
right: 0
|
||||
bottom: 0
|
||||
overflow: hidden
|
||||
padding: 0 15px
|
||||
padding: 0 15px 24px 0
|
||||
max-height: 110px
|
||||
min-height: 56px
|
||||
border-top: 1px solid rgba(255,255,255,0.2)
|
||||
|
|
|
@ -107,6 +107,10 @@ $(document).ready(function () {
|
|||
$min.val( ui.values[ 0 ] );
|
||||
$max.val( ui.values[ 1 ] );
|
||||
$form.submit();
|
||||
},
|
||||
slide: function( event, ui ) {
|
||||
$min.val( ui.values[ 0 ] );
|
||||
$max.val( ui.values[ 1 ] );
|
||||
}
|
||||
});
|
||||
$min.val( $slider.slider( "values", 0 ) );
|
||||
|
|
|
@ -419,11 +419,11 @@
|
|||
<div>
|
||||
<div class="oe_msg_attachment" t-foreach='message.attachment_ids' t-as='attachment'>
|
||||
<a t-att-href="'/mail/download_attachment?model=mail.message&id='+str(message.id)+'&method=download_attachment&attachment_id='+str(attachment.id)" target="_blank">
|
||||
<t t-if="attachment.file_type == 'webimage'">
|
||||
<t t-if="attachment.file_type_icon == 'webimage'">
|
||||
<img t-att-src="'/web/binary/image?model=ir.attachment&field=datas&id=' + str(attachment.id) + '&resize=100,80'"
|
||||
class='oe_attachment_embedded'></img>
|
||||
</t>
|
||||
<t t-if="attachment.file_type != 'webimage'">
|
||||
<t t-if="attachment.file_type_icon != 'webimage'">
|
||||
<img t-att-src="'/mail/static/src/img/mimetypes/' + attachment.file_type + '.png'"
|
||||
class='oe_attachment_webimage'></img>
|
||||
</t>
|
||||
|
@ -608,9 +608,9 @@
|
|||
<t t-set="attribute" t-value="Ecommerce.has_search_filter(attribute_id.id)"/>
|
||||
<div style="margin: 0 20px;" class="js_slider"
|
||||
t-att-data-id="attribute_id.id"
|
||||
t-att-data-value-min="attribute and attribute[1][0] or attribute_id.float_min"
|
||||
t-att-data-value-min="attribute and attribute[1][0] or attribute_id.float_min or '0'"
|
||||
t-att-data-value-max="attribute and attribute[1][1] or attribute_id.float_max"
|
||||
t-att-data-min="attribute_id.float_min"
|
||||
t-att-data-min="attribute_id.float_min or '0'"
|
||||
t-att-data-max="attribute_id.float_max"></div>
|
||||
</li>
|
||||
</t>
|
||||
|
@ -784,7 +784,7 @@
|
|||
<div class="form-group col-lg-6" groups="sale.group_delivery_invoice_address">
|
||||
<label>
|
||||
<input type="checkbox" name="shipping_different" t-att-checked="shipping"/>
|
||||
Ship to a different address
|
||||
<span>Ship to a different address</span>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
|
|
Loading…
Reference in New Issue