1.0.1.sql 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. CREATE TABLE IF NOT EXISTS `dreamkas_operations` (
  2. `id` int(11) NOT NULL AUTO_INCREMENT,
  3. `operation_id` varchar(255) NOT NULL,
  4. `date_create` datetime NOT NULL,
  5. `date_finish` datetime NOT NULL,
  6. `date_resend` datetime NOT NULL,
  7. `status` varchar(255) NOT NULL,
  8. `error_code` varchar(255) NOT NULL,
  9. `error_message` varchar(255) NOT NULL,
  10. `receipt_id` varchar(255) NOT NULL,
  11. `operation_body` TEXT NOT NULL,
  12. `repeat_count` tinyint(3) NOT NULL DEFAULT 0,
  13. PRIMARY KEY (`id`),
  14. UNIQUE KEY (`operation_id`)
  15. ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
  16. CREATE TABLE IF NOT EXISTS `dreamkas_services_relations` (
  17. `id` int(11) NOT NULL AUTO_INCREMENT,
  18. `service` varchar(42) NOT NULL,
  19. `goods_id` varchar(255) NOT NULL,
  20. `goods_name` varchar(255) NOT NULL,
  21. `goods_type` varchar(255) NOT NULL,
  22. `goods_price` double NOT NULL,
  23. `goods_tax` varchar(255) NOT NULL,
  24. `goods_vendorcode` varchar(255) NOT NULL,
  25. PRIMARY KEY (`id`),
  26. UNIQUE KEY (`service`, `goods_id`)
  27. ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
  28. CREATE TABLE IF NOT EXISTS `dreamkas_banksta2_relations` (
  29. `id` int(11) NOT NULL AUTO_INCREMENT,
  30. `bs2_rec_id` int(11) NOT NULL,
  31. `operation_id` varchar(255) NOT NULL,
  32. `receipt_id` varchar(255) NOT NULL,
  33. PRIMARY KEY (`id`),
  34. UNIQUE KEY (bs2_rec_id),
  35. UNIQUE KEY (`operation_id`)
  36. ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
  37. CREATE TABLE IF NOT EXISTS `callmeback` (
  38. `id` int(11) NOT NULL AUTO_INCREMENT,
  39. `date` datetime NOT NULL,
  40. `number` varchar(250) DEFAULT NULL,
  41. `state` varchar(40) DEFAULT NULL,
  42. PRIMARY KEY (`id`)
  43. ) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=1;
  44. ALTER TABLE `salary_jobprices` CHANGE `time` `time` FLOAT NULL DEFAULT NULL;
  45. ALTER TABLE `dreamkas_operations` ADD `repeated_fiscop_id` varchar(255) NOT NULL AFTER `operation_body`;
  46. CREATE TABLE IF NOT EXISTS `qinq` (
  47. `id` INT NOT NULL AUTO_INCREMENT,
  48. `login` VARCHAR(45) NULL,
  49. `svlan` INT(4) NULL,
  50. `cvlan` INT(4) NULL,
  51. PRIMARY KEY (`id`),
  52. UNIQUE KEY (`login`)
  53. ) ENGINE = MyISAM AUTO_INCREMENT=1 DEFAULT CHARSET=UTF8;