llx_c_email_templates.sql 2.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. -- ===================================================================
  2. -- Copyright (C) 2001-2002 Rodolphe Quiedeville <rodolphe@quiedeville.org>
  3. --
  4. -- This program is free software; you can redistribute it and/or modify
  5. -- it under the terms of the GNU General Public License as published by
  6. -- the Free Software Foundation; either version 3 of the License, or
  7. -- (at your option) any later version.
  8. --
  9. -- This program is distributed in the hope that it will be useful,
  10. -- but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. -- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. -- GNU General Public License for more details.
  13. --
  14. -- You should have received a copy of the GNU General Public License
  15. -- along with this program. If not, see <https://www.gnu.org/licenses/>.
  16. --
  17. -- Table with templates of emails
  18. -- ===================================================================
  19. create table llx_c_email_templates
  20. (
  21. rowid integer AUTO_INCREMENT PRIMARY KEY,
  22. entity integer DEFAULT 1 NOT NULL, -- multi company id
  23. module varchar(32), -- Nom du module en rapport avec le modele
  24. type_template varchar(32), -- template for which type of email (send invoice by email, send order, ...)
  25. lang varchar(6) DEFAULT '', -- We use a default to '' so the unique index that include this field will work
  26. private smallint DEFAULT 0 NOT NULL, -- Template public or private
  27. fk_user integer, -- Id user owner if template is private, or null
  28. datec datetime,
  29. tms timestamp DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
  30. label varchar(180), -- Label of predefined email
  31. position smallint, -- Position
  32. enabled varchar(255) DEFAULT '1', -- Condition to have this module visible
  33. active tinyint DEFAULT 1 NOT NULL,
  34. email_from varchar(255), -- default email from
  35. email_to varchar(255), -- default email to
  36. email_tocc varchar(255), -- default email to cc
  37. email_tobcc varchar(255), -- default email to bcc
  38. topic text, -- Predefined topic
  39. joinfiles text, -- Files to attach
  40. content mediumtext, -- Predefined text
  41. content_lines text -- Predefined lines
  42. )ENGINE=innodb;