llx_expedition.sql 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. -- ===================================================================
  2. -- Copyright (C) 2003-2010 Rodolphe Quiedeville <rodolphe@quiedeville.org>
  3. -- Copyright (C) 2008-2010 Regis Houssin <regis.houssin@inodbox.com>
  4. -- Copyright (C) 2011-2012 Laurent Destailleur <eldy@users.sourceforge.net>
  5. -- Copyright (C) 2012 Juanjo Menent <jmenent@2byte.es>
  6. --
  7. -- This program is free software; you can redistribute it and/or modify
  8. -- it under the terms of the GNU General Public License as published by
  9. -- the Free Software Foundation; either version 3 of the License, or
  10. -- (at your option) any later version.
  11. --
  12. -- This program is distributed in the hope that it will be useful,
  13. -- but WITHOUT ANY WARRANTY; without even the implied warranty of
  14. -- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  15. -- GNU General Public License for more details.
  16. --
  17. -- You should have received a copy of the GNU General Public License
  18. -- along with this program. If not, see <https://www.gnu.org/licenses/>.
  19. --
  20. -- ===================================================================
  21. create table llx_expedition
  22. (
  23. rowid integer AUTO_INCREMENT PRIMARY KEY,
  24. tms timestamp DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
  25. ref varchar(30) NOT NULL,
  26. entity integer DEFAULT 1 NOT NULL, -- multi company id
  27. fk_soc integer NOT NULL,
  28. fk_projet integer DEFAULT NULL,
  29. ref_ext varchar(255), -- reference into an external system (not used by dolibarr)
  30. ref_customer varchar(255), -- customer number
  31. date_creation datetime, -- date de creation
  32. fk_user_author integer, -- author of creation
  33. fk_user_modif integer, -- author of last change
  34. date_valid datetime, -- date de validation
  35. fk_user_valid integer, -- valideur
  36. date_delivery datetime DEFAULT NULL, -- date planned of delivery
  37. date_expedition datetime, -- not used (deprecated)
  38. fk_address integer DEFAULT NULL, -- delivery address (deprecated)
  39. fk_shipping_method integer,
  40. tracking_number varchar(50),
  41. fk_statut smallint DEFAULT 0, -- 0 = draft, 1 = validated, 2 = billed or closed depending on WORKFLOW_BILL_ON_SHIPMENT option
  42. billed smallint DEFAULT 0,
  43. height float, -- height
  44. width float, -- with
  45. size_units integer, -- unit of all sizes (height, width, depth)
  46. size float, -- depth
  47. weight_units integer, -- unit of weight
  48. weight float, -- weight
  49. note_private text,
  50. note_public text,
  51. model_pdf varchar(255),
  52. last_main_doc varchar(255), -- relative filepath+filename of last main generated document
  53. fk_incoterms integer, -- for incoterms
  54. location_incoterms varchar(255), -- for incoterms
  55. import_key varchar(14),
  56. extraparams varchar(255) -- for other parameters with json format
  57. )ENGINE=innodb;