-- Job Card print log
-- Tracks every time a Job Card was printed for an MO

CREATE TABLE IF NOT EXISTS llx_jobcard_printlog (
    rowid       INT AUTO_INCREMENT PRIMARY KEY,
    fk_mo       INT          NOT NULL,
    fk_user     INT          NOT NULL,
    date_print  DATETIME     NOT NULL,
    copies      TINYINT      NOT NULL DEFAULT 1,
    format      VARCHAR(10)  NOT NULL DEFAULT 'A4',
    note        VARCHAR(255),
    entity      INT          NOT NULL DEFAULT 1,
    INDEX idx_jobcard_printlog_fk_mo (fk_mo),
    INDEX idx_jobcard_printlog_entity (entity)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
