Commit Graph

773 Commits

Author SHA1 Message Date
boudet jean pascal
a4b8cb7008 NEW : adds visual indicators on the Sales Order card (commande/card.php) (#37460)
* This PR adds visual indicators on the Sales Order card (commande/card.php) to quickly identify if an order or its lines are shippable based on current stock levels. This feature mirrors the existing functionality found in the Orders List, bringing valuable logistics information directly into the Order Card context.

Key Features:
Global Shippable Status: Adds a "shippable" icon (Truck) next to the "Planned delivery date" field.

Logic: Checks if all products in the order are in stock.

Condition: Visible only if Stock and Shipment modules are enabled, a delivery date is set, and the order is validated.

Visual: Green icon if fully shippable, Red/Warning if stock is insufficient. Includes a detailed tooltip.

Per-Line Shippable Status: Adds a new "Shippable" column in the product lines table.

Logic: Compares real stock vs. remaining quantity to ship for each line.

Visual: Displays a green/red status bullet (standard Dolibarr status icons) directly in the line.

Implementation: Done by updating objectline_title.tpl.php and objectline_view.tpl.php with specific checks for the commande element.

New Configuration Option: Added a hidden option ORDER_DISABLE_SHIPPABLE_ICON_ON_CARD to disable this feature if needed (configurable in Home > Setup > Other Setup or via module settings).

Backend Optimization: Added a new method getShippableInfos() in commande.class.php to centralize the stock check logic (optimized with stock caching to avoid N+1 query issues).

Technical Details:
Modified Files:

commande/card.php: Integration of the global icon next to the date.

commande/class/commande.class.php: Added getShippableInfos() method.

core/tpl/objectline_title.tpl.php: Added "Shippable" column header (conditional for Orders).

core/tpl/objectline_view.tpl.php: Added "Shippable" column cell content (conditional for Orders).

Performance: Logic uses static caching for product stock to minimize database impact when rendering large orders.

* missed element

* img_picto

* phan add

* load_stock and global $i

* phan

* ci retour

* change icon
change phan directive

* phan

* Fight against optionflation

Signed-off-by: Laurent Destailleur <eldy@destailleur.fr>

* Change condition for displaying shippable icon

Signed-off-by: Laurent Destailleur <eldy@destailleur.fr>

* Change condition for displaying shippable status icon

Signed-off-by: Laurent Destailleur <eldy@destailleur.fr>

* Update card.php

Signed-off-by: Laurent Destailleur <eldy@destailleur.fr>

* Update shippable status condition in template

Signed-off-by: Laurent Destailleur <eldy@destailleur.fr>

* Update shippable status condition logic

Signed-off-by: Laurent Destailleur <eldy@destailleur.fr>

---------

Signed-off-by: Laurent Destailleur <eldy@destailleur.fr>
Co-authored-by: jpb <jean-pascal.boudet@atm-consulting>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-03-12 14:42:31 +01:00
Laurent Destailleur
1ee077f797 CI 2026-03-12 02:02:58 +01:00
Laurent Destailleur
a9c85c78e2 Automated merge from 23.0 to develop 2026-02-28 12:17:11 +01:00
Laurent Destailleur
6a458223b1 Automated merge from 22.0 by tool pullmerge.sh 2026-02-28 11:31:01 +01:00
Anthony Berton
ce02010542 FIX - Show POS in Order and Invoice list (#37364)
* FIX - Show POS in Order and Invoice list

* Update list.php

* Change $showpos value type from int to string

* Refactor POS fields visibility logic

---------

Co-authored-by: Anthony Berton <anthony.berton@bb2a.fr>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-27 17:15:41 +01:00
Laurent Destailleur
3d55a7a792 Merge branch '22.0' of git@github.com:Dolibarr/dolibarr.git into 22.0 2025-12-22 15:11:32 +01:00
Frédéric FRANCE
ec46ff9b10 fix search import key filter not working 2025-12-18 13:28:16 +01:00
Florian HENRY
12936afb13 review 2025-12-04 19:58:42 +01:00
Florian HENRY
7f3ac106fc fix: when create bills from orders list, title and subtotal attribute is now copied 2025-12-04 11:00:58 +01:00
Florian HENRY
c39cba8395 fix: when create bills from orders list, title and subtotal attribute is now copied 2025-12-04 10:57:24 +01:00
Francis Appels
079a55153f Fix php warning in order list (#36202)
* Fix order list php warning

* missing td
2025-11-11 17:42:03 +01:00
Laurent Destailleur
17e78c99a2 Fix responsive 2025-10-17 23:50:31 +02:00
HENRY Florian
b117b315a2 fix: if MAXREFONDOC is set to -1 do not output Orders in Pulbic note (#35493)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2025-09-28 21:01:10 +02:00
ldestailleur
f65903d006 Merge branch '22.0' of git@github.com:Dolibarr/dolibarr.git into 22.0 2025-09-26 01:23:02 +02:00
atm-GregM
35bb894393 FIX check commande liste validate (#35479) 2025-09-25 11:57:49 +02:00
Laurent Destailleur
d8e1560275 Merge branch '21.0' of git@github.com:Dolibarr/dolibarr.git into 22.0 2025-08-01 00:13:19 +02:00
Mohamed DAOUD
04672e1d80 fix use delivery date v21 (#34831) 2025-07-29 21:09:46 +02:00
ldestailleur
80e5f7fe66 Fix tooltip 2025-07-21 18:58:25 +02:00
ldestailleur
270caf0dcb Debug v22 2025-07-17 19:30:58 +02:00
ldestailleur
423b302a2b Debug v22 2025-07-17 19:30:58 +02:00
Quentin-Seekness
b91b46d898 Filter on search_project lost on next pages (#34646)
The filter on the p.title of the command list doesn't work if you switch result pages. It's simply not kept in the next page url.

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2025-06-27 00:28:36 +02:00
ldestailleur
0ae1f2fb9d Fix CI 2025-06-18 16:53:20 +02:00
ldestailleur
65bb64e9cd Fix CI 2025-06-18 16:24:37 +02:00
ldestailleur
5e4f167815 Debug v22 - missing module_source in view mode of card 2025-06-16 23:49:56 +02:00
atm-lena
50f9ec8b52 Invoice List : add tag filter (#34521)
* Invoice List : add tag filter

* Invoice List : Add operator to invoice filter

* Add tag filter in order list

* Clean code

---------

Co-authored-by: atm-lena <lena.papazian@atm-consulting.fr>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2025-06-15 03:02:13 +02:00
ldestailleur
7ad71279a7 Fix CI 2025-06-11 17:33:07 +02:00
ldestailleur
45c7c7f9bc Fix variable not defined 2025-06-11 17:15:58 +02:00
ldestailleur
9e26f5a98e Debug v22 2025-06-11 12:45:15 +02:00
ldestailleur
b5a871bf99 Close #34344 2025-06-04 10:48:29 +02:00
Frédéric FRANCE
de763b4b43 clean code of order (#33880)
* clean code of order

* clean code of order

* clean code of order

* clean code of order
2025-04-16 21:09:45 +02:00
lvessiller-opendsi
4963639d67 NEW input reason for customer invoice (#33599)
* NEW input reason for customer invoice

* Fix CI error

* Fix format fk_input_reason in array of fileds

* Add invoices in translate key of source dictionary
2025-04-16 01:02:26 +02:00
ldestailleur
d9753254b1 Look and feel v22 for description/notes into lines 2025-03-26 14:39:42 +01:00
ldestailleur
ec0b487b28 NEW Can filter on public/private notes in list sale orders thirdparties 2025-03-26 14:12:55 +01:00
Laurent Destailleur
41377a9917 Merge pull request #33313 from mdeweerd/phan/big_violators
Fix PhanTypeMismatchArgument in commonobject, commande/card,
2025-03-05 13:05:42 +01:00
ldestailleur
6c9e25677c close #33310 2025-03-05 13:03:35 +01:00
MDW
4096d0ee2f Qual: Fix phan notices for commande 2025-03-05 12:15:14 +01:00
ldestailleur
e8f8416215 NEW Filter on date creation/date modification in invoice list 2025-02-18 13:56:44 +01:00
Laurent Destailleur (aka Eldy)
9bc2a3a6bd Merge branch '21.0' of git@github.com:Dolibarr/dolibarr.git into develop 2025-02-11 22:24:47 +01:00
Laurent Destailleur (aka Eldy)
2fc2e045be NEW Add link to create shipment on picto 2025-02-11 18:45:39 +01:00
Laurent Destailleur (aka Eldy)
d6aac69d90 Debug v21 2025-02-11 16:28:37 +01:00
Laurent Destailleur
adae4f0fb3 Merge branch '21.0' of git@github.com:Dolibarr/dolibarr.git into develop 2025-01-27 01:37:52 +01:00
Laurent Destailleur
940e42c1e4 Merge branch '20.0' of git@github.com:Dolibarr/dolibarr.git into 21.0 2025-01-27 01:30:34 +01:00
Laurent Destailleur (aka Eldy)
f11d701486 Merge branch '21.0' of git@github.com:Dolibarr/dolibarr.git into develop 2025-01-19 15:02:20 +01:00
Laurent Destailleur (aka Eldy)
55591fc8c6 Debug v21 2025-01-18 19:20:55 +01:00
Laurent Destailleur
79d5c0c418 Debug v23 2026-01-15 16:12:14 +01:00
Laurent Destailleur
8abeb47da1 Merge branch '22.0' of git@github.com:Dolibarr/dolibarr.git into develop 2025-12-22 16:06:05 +01:00
Laurent Destailleur
c32cae4051 Merge branch '22.0' of git@github.com:Dolibarr/dolibarr.git into develop 2025-12-05 16:42:25 +01:00
Laurent Destailleur
34bd3f5755 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into
develop
2025-11-12 22:02:50 +01:00
Frédéric FRANCE
9b512f565f try to make new checks (#35976)
* try to make new checks

* try to make new checks

* try to make new checks

* try to make new checks

* try to make new checks

* try to make new checks
2025-10-28 00:57:01 +01:00
Laurent Destailleur
fe71668d0d Replace use of DISTINCT with WHERE EXISTS 2025-10-24 03:15:51 +02:00