1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/chatonsinfos_ynh.git synced 2024-09-03 18:15:58 +02:00

[fix] Config panel

This commit is contained in:
ljf 2023-09-04 00:40:26 +02:00 committed by ljf (zamentur)
parent ff2ad870af
commit b21aa2a768
3 changed files with 28 additions and 28 deletions

View file

@ -30,7 +30,7 @@ services = []
type = "string" type = "string"
bind = "organization.description:" bind = "organization.description:"
[main.organization.status-level] [main.organization.status_level]
ask.fr = "Statut" ask.fr = "Statut"
type = "select" type = "select"
choices.ACTIVE = "Actif" choices.ACTIVE = "Actif"
@ -38,11 +38,11 @@ services = []
choices.AWAY = "Inactif" choices.AWAY = "Inactif"
bind = "organization.status.level:" bind = "organization.status.level:"
[main.organization.status-description] [main.organization.status_description]
ask.fr = "Description du statut" ask.fr = "Description du statut"
type = "string" type = "string"
bind = "organization.status.description:" bind = "organization.status.description:"
visible = "status-level == 'IDLE'" visible = "status_level == 'IDLE'"
[main.organization.startdate] [main.organization.startdate]
ask.fr = "Date de création" ask.fr = "Date de création"
@ -52,7 +52,7 @@ services = []
[main.organization.enddate] [main.organization.enddate]
ask.fr = "Date de fermeture" ask.fr = "Date de fermeture"
type = "date" type = "date"
visible = "status-level == 'AWAY'" visible = "status_level == 'AWAY'"
bind = "organization.enddate:" bind = "organization.enddate:"
@ -81,34 +81,34 @@ services = []
type = "url" type = "url"
bind = "organization.logo:" bind = "organization.logo:"
[main.organization.contact-url] [main.organization.contact_url]
ask.fr = "URL de contact" ask.fr = "URL de contact"
type = "url" type = "url"
bind = "organization.contact.url:" bind = "organization.contact.url:"
[main.organization.contact-mail] [main.organization.contact_mail]
ask.fr = "Mail de contact" ask.fr = "Mail de contact"
type = "email" type = "email"
bind = "organization.contact.email:" bind = "organization.contact.email:"
[main.organization.legal-url] [main.organization.legal_url]
ask.fr = "Mentions légales" ask.fr = "Mentions légales"
type = "url" type = "url"
bind = "organization.legal.url:" bind = "organization.legal.url:"
[main.organization.guide-technical] [main.organization.guide_technical]
ask.fr = "Documentation technique" ask.fr = "Documentation technique"
type = "url" type = "url"
bind = "organization.guide.technical:" bind = "organization.guide.technical:"
default = "https://yunohost.org/admindoc" default = "https://yunohost.org/admindoc"
[main.organization.guide-user] [main.organization.guide_user]
ask.fr = "Documentation utilisateurice" ask.fr = "Documentation utilisateurice"
type = "url" type = "url"
bind = "organization.guide.user:" bind = "organization.guide.user:"
default = "https://yunohost.org/user_guide" default = "https://yunohost.org/user_guide"
[main.organization.status-level-chatons] [main.organization.status_level_chatons]
ask.fr = "Statut" ask.fr = "Statut"
type = "select" type = "select"
choices.ACTIVE = "Actif" choices.ACTIVE = "Actif"
@ -117,39 +117,39 @@ services = []
bind = "organization.memberof.chatons.status.level:" bind = "organization.memberof.chatons.status.level:"
optional = false optional = false
[main.organization.status-description-chatons] [main.organization.status_description_chatons]
ask.fr = "Description du statut" ask.fr = "Description du statut"
type = "string" type = "string"
bind = "organization.memberof.chatons.status.description:" bind = "organization.memberof.chatons.status.description:"
visible = "status-level-chatons == 'IDLE'" visible = "status_level_chatons == 'IDLE'"
[main.organization.startdate-chatons] [main.organization.startdate_chatons]
ask.fr = "Date d'entrée dans le collectif" ask.fr = "Date d'entrée dans le collectif"
type = "date" type = "date"
bind = "organization.memberof.chatons.startdate:" bind = "organization.memberof.chatons.startdate:"
optional = false optional = false
[main.organization.enddate-chatons] [main.organization.enddate_chatons]
ask.fr = "Date de sortie du collectif" ask.fr = "Date de sortie du collectif"
type = "date" type = "date"
visible = "status-level-chatons == 'AWAY'" visible = "status_level_chatons == 'AWAY'"
bind = "organization.memberof.chatons.enddate:" bind = "organization.memberof.chatons.enddate:"
[main.owner] [main.owner]
name = "Propriétaire de l'organisation" name = "Propriétaire de l'organisation"
optional = true optional = true
[main.owner.owner-name] [main.owner.owner_name]
ask.fr = "Nom" ask.fr = "Nom"
type = "string" type = "string"
bind = "organization.owner.name:" bind = "organization.owner.name:"
[main.owner.owner-website] [main.owner.owner_website]
ask.fr = "siteweb" ask.fr = "siteweb"
type = "url" type = "url"
bind = "organization.owner.website:" bind = "organization.owner.website:"
[main.owner.owner-logo] [main.owner.owner_logo]
ask.fr = "Logo" ask.fr = "Logo"
type = "url" type = "url"
bind = "organization.owner.logo:" bind = "organization.owner.logo:"
@ -161,13 +161,13 @@ services = []
# help = "" # help = ""
optional = true optional = true
[main.location.country-name] [main.location.country_name]
ask.fr = "Pays de l'organisation" ask.fr = "Pays de l'organisation"
type = "string" type = "string"
bind = "organization.country.name:" bind = "organization.country.name:"
optional = false optional = false
[main.location.country-code] [main.location.country_code]
ask.fr = "Code pays de l'organisation" ask.fr = "Code pays de l'organisation"
help = "Table ISO 3166-1 alpha-2 : https://fr.wikipedia.org/wiki/ISO_3166-1#Table_de_codage" help = "Table ISO 3166-1 alpha-2 : https://fr.wikipedia.org/wiki/ISO_3166-1#Table_de_codage"
type = "string" type = "string"
@ -396,28 +396,28 @@ bind = ":{{ install_dir }}/public/{{ app }}.properties"
type = "url" type = "url"
bind = "service.logo:" bind = "service.logo:"
[{{ app }}.service.{{ app }}_legal-url] [{{ app }}.service.{{ app }}_legal_url]
ask.fr = "Mentions légales" ask.fr = "Mentions légales"
type = "url" type = "url"
bind = "service.legal.url:" bind = "service.legal.url:"
[{{ app }}.service.{{ app }}_guide-technical] [{{ app }}.service.{{ app }}_guide_technical]
ask.fr = "Documentation technique" ask.fr = "Documentation technique"
type = "url" type = "url"
bind = "service.guide.technical:" bind = "service.guide.technical:"
[{{ app }}.service.{{ app }}_guide-user] [{{ app }}.service.{{ app }}_guide_user]
ask.fr = "Documentation utilisateurices" ask.fr = "Documentation utilisateurices"
type = "url" type = "url"
bind = "service.guide.user:" bind = "service.guide.user:"
[{{ app }}.service.{{ app }}_contact-url] [{{ app }}.service.{{ app }}_contact_url]
ask.fr = "Page de support" ask.fr = "Page de support"
type = "url" type = "url"
bind = "service.contact.url:" bind = "service.contact.url:"
optional = true optional = true
[{{ app }}.service.{{ app }}_contact-email] [{{ app }}.service.{{ app }}_contact_email]
ask.fr = "Courriel de support" ask.fr = "Courriel de support"
type = "email" type = "email"
bind = "service.contact.email:" bind = "service.contact.email:"
@ -432,7 +432,7 @@ bind = ":{{ install_dir }}/public/{{ app }}.properties"
choices.Client = "Inscription liée à une relation commerciale (facture…)" choices.Client = "Inscription liée à une relation commerciale (facture…)"
bind = "service.registration:" bind = "service.registration:"
[{{ app }}.service.{{ app }}_registration-load] [{{ app }}.service.{{ app }}_registration_load]
ask.fr = "Capacité" ask.fr = "Capacité"
type = "select" type = "select"
choices.OPEN = "Le service accueille de nouveaux comptes" choices.OPEN = "Le service accueille de nouveaux comptes"

View file

@ -88,7 +88,7 @@ create_service_properties() {
update_subs() { update_subs() {
local app_published local app_published
local app=chatonsinfos local app=chatonsinfos
export apps=$(yunohost app list | grep "id\:" | sed "s/ *id: //g") export apps=$(yunohost app list | grep "id\:" | sed "s/ *id: //g" | grep -v chatonsinfos)
local orga_path="$install_dir/public/organization.properties" local orga_path="$install_dir/public/organization.properties"
# Remove all subs # Remove all subs

View file

@ -74,7 +74,7 @@ ynh_app_config_apply() {
# Update date of properties files # Update date of properties files
local date=$(date '+%Y-%m-%dT%H:%M:%S') local date=$(date '+%Y-%m-%dT%H:%M:%S')
ynh_write_var_in_file --file="$install_dir/public/organization.properties" --key="file.datetime" --value="$date" ynh_write_var_in_file --file="$install_dir/public/organization.properties" --key="file.datetime" --value="$date"
local apps=$(yunohost app list | grep "id\:" | sed "s/ *id: //g") local apps=$(yunohost app list | grep "id\:" | sed "s/ *id: //g" | grep -v chatonsinfos)
for _app_id in $apps for _app_id in $apps
do do
ynh_write_var_in_file --file="$install_dir/public/$_app_id.properties" --key="file.datetime" --value="$date" ynh_write_var_in_file --file="$install_dir/public/$_app_id.properties" --key="file.datetime" --value="$date"