refactor(front) : aligne l'ecran ajouter client sur la maquette (ERP-63)
- Layout maquette : en-tete avec retour, grille 3 colonnes (gap-x-[80px]), cartes ombrees pour les onglets, boutons Valider centres, libelles ajustes. - Telephones du formulaire principal en tableau (1 par defaut, + revele le 2e). - Information : Description en row-span-2 (alignement corrige via pt-1), Nombre de salaries en MalioInputText masque chiffres. - Adresse : carte ombree, suppression en absolute, sites en cases a cocher inline, pays France/Espagne, exclusivite Prospect appliquee au toggle. - Onglets : icones par onglet (TAB_ICONS) ; Statistiques / Rapports / Echanges passent en edit-only (absents a la creation, option includeEditOnlyTabs pour la modification).
This commit is contained in:
@@ -12,7 +12,7 @@ import {
|
||||
type ContactDraft,
|
||||
} from '../clientFormRules'
|
||||
|
||||
describe('buildClientFormTabKeys (gating onglet Comptabilite)', () => {
|
||||
describe('buildClientFormTabKeys (gating onglet Comptabilite + onglets edit-only)', () => {
|
||||
it('inclut l onglet accounting si l utilisateur a accounting.view', () => {
|
||||
expect(buildClientFormTabKeys(true)).toContain('accounting')
|
||||
})
|
||||
@@ -21,8 +21,16 @@ describe('buildClientFormTabKeys (gating onglet Comptabilite)', () => {
|
||||
expect(buildClientFormTabKeys(false)).not.toContain('accounting')
|
||||
})
|
||||
|
||||
it('place accounting entre transport et statistics quand present', () => {
|
||||
it('a la creation, exclut Statistiques / Rapports / Echanges', () => {
|
||||
const keys = buildClientFormTabKeys(true)
|
||||
expect(keys).toEqual(['information', 'contact', 'address', 'transport', 'accounting'])
|
||||
expect(keys).not.toContain('statistics')
|
||||
expect(keys).not.toContain('reports')
|
||||
expect(keys).not.toContain('exchanges')
|
||||
})
|
||||
|
||||
it('en modification (includeEditOnlyTabs), ajoute les onglets edit-only en fin', () => {
|
||||
const keys = buildClientFormTabKeys(true, { includeEditOnlyTabs: true })
|
||||
expect(keys).toEqual([
|
||||
'information',
|
||||
'contact',
|
||||
|
||||
Reference in New Issue
Block a user