Created
March 5, 2013 08:25
-
-
Save mkdizajn/5088786 to your computer and use it in GitHub Desktop.
sql for fiskalizacija modul table's
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CREATE TABLE IF NOT EXISTS `inchoo_fiskalizacija_cert` ( | |
`cert_id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT 'Id', | |
`created_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT 'Created At', | |
`website_id` int(11) NOT NULL COMMENT 'Website Id', | |
`pfx_cert` text NOT NULL COMMENT 'Original Certificate in PFX format', | |
`pem_private_key` text NOT NULL COMMENT 'Private Key in PEM format', | |
`pem_private_key_passphrase` text NOT NULL COMMENT 'Passphrase for Private Key in PEM format', | |
`pem_public_cert` text NOT NULL COMMENT 'Public Certificate in PEM format', | |
`pem_public_cert_name` text NOT NULL COMMENT 'Name of the Public Certificate in PEM format', | |
`pem_public_cert_serial_number` int(11) NOT NULL COMMENT 'Serial Number of the Public Certificate in PEM format', | |
`pem_public_cert_hash` text NOT NULL COMMENT 'Hash of the Public Certificate in PEM format', | |
`pem_public_cert_info` text NOT NULL COMMENT 'Info from Public Certificate in PEM format', | |
`valid_from` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT 'Valid From', | |
`valid_to` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT 'Valid To', | |
PRIMARY KEY (`cert_id`), | |
UNIQUE KEY `UNQ_INCHOO_FISKALIZACIJA_CERT_WEBSITE_ID` (`website_id`), | |
UNIQUE KEY `UNQ_INCHOO_FISKALIZACIJA_CERT_PEM_PUBLIC_CERT_SERIAL_NUMBER` (`pem_public_cert_serial_number`) | |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Fiscalization Certificates' AUTO_INCREMENT=2 ; | |
-- | |
-- Dumping data for table `inchoo_fiskalizacija_cert` | |
-- | |
-- | |
-- Table structure for table `inchoo_fiskalizacija_invoice` | |
-- | |
CREATE TABLE IF NOT EXISTS `inchoo_fiskalizacija_invoice` ( | |
`entity_id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT 'Id', | |
`created_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT 'Created At', | |
`invoice_entity_id` int(11) NOT NULL COMMENT 'Invoice Id, points to sales_flat_invoice.entity_id', | |
`xml_request_raw_body` text NOT NULL COMMENT 'Final XML request, non-signed ready to be signed', | |
`signed_xml_request_raw_body` text NOT NULL COMMENT 'Final signed XML request, ready to be sent to fiscalization SOAP service', | |
`total_request_attempts` int(11) NOT NULL COMMENT 'Number of attempts sending the request', | |
`br_rac` text COMMENT 'Broj racuna', | |
`oib` varchar(11) DEFAULT NULL COMMENT 'OIB firme', | |
`blagajnik` text COMMENT 'Blagajnik', | |
`zast_kod` varchar(32) DEFAULT NULL COMMENT 'Zastitni kod', | |
`jir` varchar(36) DEFAULT NULL COMMENT 'Time when requested passed and JIR was obtained', | |
`jir_obtained_at` timestamp NULL DEFAULT NULL COMMENT 'Time when requested passed and JIR was obtained', | |
`last_service_response_body` text COMMENT 'Last service response body', | |
`last_service_response_status` int(11) DEFAULT NULL COMMENT 'Last service response status', | |
`modified_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT 'Time when entry was last modified', | |
PRIMARY KEY (`entity_id`), | |
UNIQUE KEY `UNQ_INCHOO_FISKALIZACIJA_INVOICE_INVOICE_ENTITY_ID` (`invoice_entity_id`) | |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Fiscalization Invoice' AUTO_INCREMENT=5 ; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment