Skip to content

Commit

Permalink
drafts schema update
Browse files Browse the repository at this point in the history
  • Loading branch information
pHAlkaline committed Feb 26, 2024
1 parent 048235a commit 01747cc
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
2 changes: 1 addition & 1 deletion app/Config/Schema/i18n.php
Expand Up @@ -64,7 +64,7 @@ public function after($event = array()) {
'model' => array('type' => 'string', 'null' => false, 'key' => 'index'),
'foreign_key' => array('type' => 'integer', 'null' => false, 'length' => 10, 'key' => 'index'),
'field' => array('type' => 'string', 'null' => false, 'key' => 'index'),
'content' => array('type' => 'text', 'null' => true, 'default' => null),
'content' => array('type' => 'longtext', 'null' => true, 'default' => null),
'indexes' => array('PRIMARY' => array('column' => 'id', 'unique' => 1), 'locale' => array('column' => 'locale', 'unique' => 0), 'model' => array('column' => 'model', 'unique' => 0), 'row_id' => array('column' => 'foreign_key', 'unique' => 0), 'field' => array('column' => 'field', 'unique' => 0))
);

Expand Down
4 changes: 2 additions & 2 deletions app/Config/Schema/phkondo.sql
Expand Up @@ -104,8 +104,8 @@ DROP TABLE IF EXISTS `drafts`;
CREATE TABLE `drafts` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`title` varchar(100) NOT NULL,
`content` text NOT NULL,
`content_model` text DEFAULT NULL,
`content` longtext NOT NULL,
`content_model` longtext DEFAULT NULL,
`modified` datetime DEFAULT NULL,
`created` datetime DEFAULT NULL,
PRIMARY KEY (`id`)
Expand Down
3 changes: 3 additions & 0 deletions app/Config/Schema/update_1.10_to_1.11.sql
Expand Up @@ -41,6 +41,9 @@ ALTER TABLE `notes` DROP FOREIGN KEY `notes_ibfk_7`;
ALTER TABLE `notes` ADD CONSTRAINT `notes_ibfk_7` FOREIGN KEY (`receipt_id`) REFERENCES `receipts`(`id`) ON DELETE SET NULL ON UPDATE CASCADE;
ALTER TABLE `payment_advices` ADD `due_date` DATE NULL AFTER `document_date`;

ALTER TABLE `drafts` CHANGE `content` `content` LONGTEXT NOT NULL;
ALTER TABLE `drafts` CHANGE `content_model` `content_model` LONGTEXT NOT NULL;

-- eng
UPDATE `receipt_statuses` SET `name` = 'Issued' WHERE `receipt_statuses`.`id` = 2;
-- ita
Expand Down

0 comments on commit 01747cc

Please sign in to comment.