Attention ! Gitlab fournissant maintenant nativement des certificats Let’s Encrypt aux domaines personnalisés des Gitlab Pages, nous avons coupé notre service qui le faisait automatiquement pour vous.

Il est impératif, pour que votre domaine personnalisé continue à avoir un certificat Let’s Encrypt à jour, d’activer la fonctionnalité native dans les paramètres de votre projet. Cette activation remplacera votre certificat actuel par un nouveau certificat Let’s Encrypt géré par Gitlab.

Voir les détails sur https://docs.framasoft.org/fr/gitlab/gitlab-pages-le.html

Commit 28036a47 authored by Majerti - Tjebbes's avatar Majerti - Tjebbes

Merge branch 'fix_1236' into 'master'

Fix 1236

Closes #1235 and #1236

See merge request endi/autonomie!1113
parents 9e704d79 323874b8
Pipeline #119241 passed with stage
in 3 minutes and 41 seconds
......@@ -286,7 +286,7 @@ def deferred_default_phase(node, kw):
if phase_id is not None:
phases = _get_phases_from_request(request)
if phase_id in [str(phase[0]) for phase in phases]:
return int(phase)
return int(phase_id)
else:
return colander.null
elif hasattr(request.context, 'phase_id'):
......@@ -314,8 +314,9 @@ def get_business_types_from_request(request):
result.append(project.project_type.default_business_type)
for business_type in project.business_types:
if business_type.allowed(request):
result.append(business_type)
if business_type != project.project_type.default_business_type:
if business_type.allowed(request):
result.append(business_type)
# fix 1065
if hasattr(context, "business_type") and context.business_type:
......
......@@ -237,8 +237,11 @@ class Project(Node):
)
for business_type in self.business_types:
if business_type.allowed(request):
business_types.append(business_type.__json__(request))
# Dans certains cas le type par défaut est aussi dans les "autres"
# types (Cas du changement de type de projet)
if business_type != self.project_type.default_business_type:
if business_type.allowed(request):
business_types.append(business_type.__json__(request))
return dict(
id=self.id,
......
......@@ -207,11 +207,16 @@ var TaskAddProxy = {
}
},
toggle_phase:function(phases){
/*
* Toggle phase visibility and disable it if necessary
*
* :param list phases: List of phase objects (not including the default
* one : "Ne pas ranger ...")
*/
var disabled = true;
var visible = false;
if (! _.isUndefined(phases)){
if (phases.length > 0){
console.log(phases);
if (phases.length >= 1){
disabled = false;
visible = true;
}
......@@ -220,6 +225,9 @@ var TaskAddProxy = {
this.ui.phase.parent().toggle(visible);
},
toggle_business_type:function(business_types){
/*
* Only show business_type selector if needed (more than one option)
*/
var disabled = true;
var visible = true;
if (! _.isUndefined(business_types)){
......@@ -275,7 +283,7 @@ var TaskAddProxy = {
_.bind(this.projectChange, this)
);
}
if (this.ui.phase.find('option').length == 0){
if (this.ui.phase.find('option').length <= 1){
this.toggle_phase([]);
}
if (this.ui.business_type.find('option').length <= 1){
......
......@@ -521,7 +521,7 @@ def get_company_acl(self):
acl = DEFAULT_PERM_NEW[:]
acl.append((Allow, Authenticated, 'visit'))
perms = [
"view_company",
"view.company",
"edit_company",
# for logo and header
"view.file",
......
......@@ -27,7 +27,7 @@
Permissions :
admin_company : disable/enable add/remove employees
view_company : view all informations concerning the company
view.company : view all informations concerning the company
edit_company : edit company options
A - Des permissions à définir sur l'ensemble de l'application
......@@ -409,7 +409,7 @@ def includeme(config):
route_name='company',
renderer='company_index.mako',
request_param='action=index',
permission='view_company',
permission='view.company',
)
config.add_view(
company_view,
......@@ -446,5 +446,5 @@ def includeme(config):
panel,
route_name='company',
request_param=request_param,
permission="view_company",
permission="view.company",
)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment