encore des erreurs de désinstallation corrigées !

FossilOrigin-Name: 4a86c1b18ea6bef9a5b1ba038e8321d97e2e7657c5a813d4e1bed29116c24695
This commit is contained in:
engel 2022-03-03 13:15:48 +00:00
parent 95c8063083
commit 8147e5791a
5 changed files with 18 additions and 8 deletions

View File

@ -18,10 +18,7 @@
*} *}
<dl class="config"> <dl class="config">
<dt><label>Objet (but) de l'association</label> <b title="Champ obligatoire">(obligatoire)</b></dt> <dt><label>Objet (but) de l'association</label> <b title="Champ obligatoire">(obligatoire)</b></dt>
{input type="textarea" name="objet_asso" source=$plugin.config label="" required="required" cols="50" rows="6" maxlength=300} {input type="textarea" name="objet_asso" source=$plugin.config label="" required="required" cols="50" rows="4" maxlength=300}
{*
{input type="text" name="objet_asso" source=$plugin.config label="" required="required" maxlength=300}
*}
</dl> </dl>
{* {*
</fieldset> </fieldset>

View File

@ -52,11 +52,13 @@
<h2>Choisir le taux de réduction</h2> <h2>Choisir le taux de réduction</h2>
<fieldset> <fieldset>
{foreach from=$plugin_config->reduction item="reduc"} {foreach from=$plugin_config->reduction item="reduc"}
{if $reduc->valeur == 1}
<span class="radio-btn"> <span class="radio-btn">
<input type="radio" id="{$reduc->taux}" <input type="radio" id="{$reduc->taux}"
name="taux_reduction" value="{$reduc->taux}" /> name="taux_reduction" value="{$reduc->taux}" />
<label for="{$reduc->taux}">{$reduc->taux}{if $reduc->remarque != ""} - {$reduc->remarque}{/if}</label> <label for="{$reduc->taux}">{$reduc->taux}{if $reduc->remarque != ""} - {$reduc->remarque}{/if}</label>
</span> </span>
{/if}
{/foreach} {/foreach}
</fieldset> </fieldset>
</div> </div>
@ -92,11 +94,13 @@
</td> </td>
<td> <td>
{foreach from=$plugin_config->reduction item="reduc"} {foreach from=$plugin_config->reduction item="reduc"}
{if $reduc->valeur == 1}
<span class="radio-btn"> <span class="radio-btn">
<input type="radio" id="taux_{$reduc->taux}_{$activite.idTarif}" <input type="radio" id="taux_{$reduc->taux}_{$activite.idTarif}"
name="taux_reduction_{$activite.idTarif}" value="{$reduc->taux}" disabled /> name="taux_reduction_{$activite.idTarif}" value="{$reduc->taux}" disabled />
<label for="taux_{$reduc->taux}_{$activite.idTarif}">{$reduc->taux}{if $reduc->remarque != ""} - {$reduc->remarque}{/if}</label> <label for="taux_{$reduc->taux}_{$activite.idTarif}">{$reduc->taux}{if $reduc->remarque != ""} - {$reduc->remarque}{/if}</label>
</span> </span>
{/if}
{/foreach} {/foreach}
</td> </td>
<td>{if $activite.descActivite != ""}{$activite.descActivite} ; {/if}{$activite.descTarif}</td> <td>{if $activite.descActivite != ""}{$activite.descActivite} ; {/if}{$activite.descTarif}</td>

View File

@ -6,10 +6,15 @@ use Garradin\Entities\Files\File;
// signature par défaut // signature par défaut
$default_signature_file = \Garradin\Files\Files::get('skel/plugin/recusfiscaux/default_signature.png'); $default_signature_file = \Garradin\Files\Files::get('skel/plugin/recusfiscaux/default_signature.png');
$default_signature_file->delete(); if (null !== $default_signature_file) {
$default_signature_file->delete();
}
// signature réelle // signature réelle
$signature = $plugin->getConfig('signature'); $signature = $plugin->getConfig('signature');
if (null !== $signature) { if (null !== $signature) {
\Garradin\Files\Files::get($signature)->delete(); $sig_file = \Garradin\Files\Files::get($signature);
if (null !== $sig_file) {
$sig_file->delete();
}
} }

View File

@ -50,7 +50,10 @@ if (f('save') && $form->check('recusfiscaux_config'))
// supprimer la signature précédente, si besoin // supprimer la signature précédente, si besoin
if (null !== $plugin->getConfig('signature')) if (null !== $plugin->getConfig('signature'))
{ {
\Garradin\Files\Files::get($plugin->getConfig('signature'))->delete(); $sig_file = \Garradin\Files\Files::get($plugin->getConfig('signature'));
if (null !== $sig_file) {
$sig_file->delete();
}
} }
// puis installer la nouvelle // puis installer la nouvelle
$plugin->setConfig('signature', $_SESSION['sig_file'][0]->path); $plugin->setConfig('signature', $_SESSION['sig_file'][0]->path);

View File

@ -26,8 +26,9 @@ h3.personne {
} }
#signature #signature
{ {
padding : 1em 0.5em 0 0.5em;
max-width: 300px; max-width: 300px;
max-height 150px; max-height: 150px;
} }
dl.config dl.config
{ {