From bda0b16e4a95eccbaa6566de9a8ef18deb8740d0 Mon Sep 17 00:00:00 2001 From: Vincent Vanwaelscappel Date: Fri, 2 Sep 2022 19:52:25 +0200 Subject: [PATCH] wait #5423 --- src/app/Models/Company.php | 23 ++++++++++++++++++++--- 1 file changed, 20 insertions(+), 3 deletions(-) diff --git a/src/app/Models/Company.php b/src/app/Models/Company.php index d8f38d4..71685da 100644 --- a/src/app/Models/Company.php +++ b/src/app/Models/Company.php @@ -98,18 +98,35 @@ class Company extends CubistMagicAbstractModel 'type' => Integer::class, 'tab' => __('Chiffres'), 'column' => true, - 'column_label'=>__('CA'), + 'column_label' => __('CA'), 'read_only' => true]); $currentYear = date('Y'); for ($i = $currentYear; $i >= 2006; $i--) { $this->addField('c_ca_' . $i, Integer::class, __('Chiffre d\'affaire') . ' ' . $i, ['tab' => __('Chiffres'), - 'column' => ($i >= $currentYear - 3), + 'column' => ($i >= $currentYear - 2), //'column' => true, - 'column_label'=>__('CA').' '.$i, + 'column_label' => __('CA') . ' ' . $i, 'read_only' => true]); } + + $this->addField(['name' => 'c_unpaid', + 'label' => __('Impayés'), + 'type' => Integer::class, + 'tab' => __('Chiffres'), + 'column' => true, + 'column_label' => __('Impayés'), + 'read_only' => true]); + + for ($i = $currentYear; $i >= 2006; $i--) { + $this->addField('c_unpaid_' . $i, Integer::class, __('Impayés') . ' ' . $i, ['tab' => __('Impayés'), + 'column' => false, + 'column_label' => __('Impayés') . ' ' . $i, + 'read_only' => true]); + } + + $this->addField(['name' => 'e1_ws_signatures', 'type' => 'Hidden']); -- 2.39.5