Overview
Comment:Ajout modif projet à la modif d'écriture
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | dev
Files: files | file ages | folders
SHA1: cda68df6239b8165fed9326d1bdcceb9216fdc97
User & Date: bohwaz on 2017-10-12 10:58:00
Other Links: branch diff | manifest | tags
Context
2017-10-12
11:16
Corrige création des dossiers à la mise à jour aussi check-in: 4ba838b75e user: bohwaz tags: dev
10:58
Ajout modif projet à la modif d'écriture check-in: cda68df623 user: bohwaz tags: dev
10:40
Projets: corrige sélecteur de projet dans la saisie d'opération check-in: 21645d32fa user: bohwaz tags: dev
Changes

Modified src/templates/admin/compta/operations/modifier.tpl from [cd8b85b8f0] to [9a345215f2].

44
45
46
47
48
49
50













51
52
53
54
55
56
57
            </dd>
{/if}

            <dt><label for="f_numero_piece">Numéro de pièce comptable</label></dt>
            <dd><input type="text" name="numero_piece" id="f_numero_piece" value="{form_field name=numero_piece data=$operation}" /></dd>
            <dt><label for="f_remarques">Remarques</label></dt>
            <dd><textarea name="remarques" id="f_remarques" rows="4" cols="30">{form_field name=remarques data=$operation}</textarea></dd>













        </dl>
    </fieldset>

{if !is_null($type)}
    <fieldset>
        <legend>Catégorie</legend>
        <dl class="catList">







>
>
>
>
>
>
>
>
>
>
>
>
>







44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
            </dd>
{/if}

            <dt><label for="f_numero_piece">Numéro de pièce comptable</label></dt>
            <dd><input type="text" name="numero_piece" id="f_numero_piece" value="{form_field name=numero_piece data=$operation}" /></dd>
            <dt><label for="f_remarques">Remarques</label></dt>
            <dd><textarea name="remarques" id="f_remarques" rows="4" cols="30">{form_field name=remarques data=$operation}</textarea></dd>

            {if count($projets) > 0}
            <dt><label for="f_projet">Projet</label></dt>
            <dd>
                <select name="projet" id="f_projet">
                    <option value="0">-- Aucun</option>
                    {foreach from=$projets key="id" item="libelle"}
                    <option value="{$id}"{form_field name="id_projet" selected=$id data=$operation}>{$libelle}</option>
                    {/foreach}
                </select>
            </dd>
            {/if}

        </dl>
    </fieldset>

{if !is_null($type)}
    <fieldset>
        <legend>Catégorie</legend>
        <dl class="catList">

Modified src/templates/admin/compta/operations/saisir.tpl from [64bc7f11d5] to [656bd84cf5].

33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
            <dd><textarea name="remarques" id="f_remarques" rows="4" cols="30">{form_field name=remarques}</textarea></dd>
            {if count($projets) > 0}
            <dt><label for="f_projet">Projet</label></dt>
            <dd>
                <select name="projet" id="f_projet">
                    <option value="0">-- Aucun</option>
                    {foreach from=$projets key="id" item="libelle"}
                    <option name="{$id}"{form_field name="projet" selected=$id}>{$libelle}</option>
                    {/foreach}
                </select>
            </dd>
            {/if}
        </dl>
        <dl class="type_recette type_depense">
            <dt><label for="f_moyen_paiement">Moyen de paiement</label> <b title="(Champ obligatoire)">obligatoire</b></dt>







|







33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
            <dd><textarea name="remarques" id="f_remarques" rows="4" cols="30">{form_field name=remarques}</textarea></dd>
            {if count($projets) > 0}
            <dt><label for="f_projet">Projet</label></dt>
            <dd>
                <select name="projet" id="f_projet">
                    <option value="0">-- Aucun</option>
                    {foreach from=$projets key="id" item="libelle"}
                    <option value="{$id}"{form_field name="projet" selected=$id}>{$libelle}</option>
                    {/foreach}
                </select>
            </dd>
            {/if}
        </dl>
        <dl class="type_recette type_depense">
            <dt><label for="f_moyen_paiement">Moyen de paiement</label> <b title="(Champ obligatoire)">obligatoire</b></dt>

Modified src/www/admin/compta/operations/modifier.php from [bf4b999eb2] to [3951adca3f].

111
112
113
114
115
116
117

118
119
120
121
122
123
124
                    'moyen_paiement'=>  f('moyen_paiement'),
                    'numero_cheque' =>  f('numero_cheque'),
                    'compte_credit' =>  $credit,
                    'compte_debit'  =>  $debit,
                    'numero_piece'  =>  f('numero_piece'),
                    'remarques'     =>  f('remarques'),
                    'id_categorie'  =>  (int)$cat->id,

                ]);
            }

            Utils::redirect('/admin/compta/operations/voir.php?id='.(int)$operation->id);
        }
        catch (UserException $e)
        {







>







111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
                    'moyen_paiement'=>  f('moyen_paiement'),
                    'numero_cheque' =>  f('numero_cheque'),
                    'compte_credit' =>  $credit,
                    'compte_debit'  =>  $debit,
                    'numero_piece'  =>  f('numero_piece'),
                    'remarques'     =>  f('remarques'),
                    'id_categorie'  =>  (int)$cat->id,
                    'id_projet'     =>  f('id_projet'),
                ]);
            }

            Utils::redirect('/admin/compta/operations/voir.php?id='.(int)$operation->id);
        }
        catch (UserException $e)
        {
135
136
137
138
139
140
141


142
143
144
145
}
else
{
    $tpl->assign('moyens_paiement', $cats->listMoyensPaiement());
    $tpl->assign('categories', $cats->getList($type));
    $tpl->assign('comptes_bancaires', $banques->getList());
}



$tpl->assign('operation', $operation);

$tpl->display('admin/compta/operations/modifier.tpl');







>
>




136
137
138
139
140
141
142
143
144
145
146
147
148
}
else
{
    $tpl->assign('moyens_paiement', $cats->listMoyensPaiement());
    $tpl->assign('categories', $cats->getList($type));
    $tpl->assign('comptes_bancaires', $banques->getList());
}

$tpl->assign('projets', (new Compta\Projets)->getAssocList());

$tpl->assign('operation', $operation);

$tpl->display('admin/compta/operations/modifier.tpl');