View | Details | Raw Unified | Return to bug 21066
Collapse All | Expand All

(-)a/installer/data/mysql/atomicupdate/bug_21066.perl (+9 lines)
Line 0 Link Here
1
$DBversion = 'XXX'; # will be replaced by the RM
2
if( CheckVersion( $DBversion ) ) {
3
    $dbh->do(q|
4
        ALTER TABLE opac_news
5
        CHANGE COLUMN timestamp publicationdate date DEFAULT NULL,
6
        ADD COLUMN updated_on timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP
7
    |);
8
    NewVersion( $DBversion, 21066, "Update table opac_news");
9
}
(-)a/installer/data/mysql/kohastructure.sql (-2 / +2 lines)
Lines 1723-1729 CREATE TABLE `opac_news` ( -- data from the news tool Link Here
1723
  `title` varchar(250) NOT NULL default '', -- title of the news article
1723
  `title` varchar(250) NOT NULL default '', -- title of the news article
1724
  `content` MEDIUMTEXT NOT NULL, -- the body of your news article
1724
  `content` MEDIUMTEXT NOT NULL, -- the body of your news article
1725
  `lang` varchar(50) NOT NULL default '', -- location for the article (koha is the staff client, slip is the circulation receipt and language codes are for the opac)
1725
  `lang` varchar(50) NOT NULL default '', -- location for the article (koha is the staff client, slip is the circulation receipt and language codes are for the opac)
1726
  `timestamp` timestamp NOT NULL default CURRENT_TIMESTAMP, -- pulibcation date and time
1726
  `publicationdate` date DEFAULT NULL, -- publication date
1727
  `updated_on` timestamp NOT NULL default CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, -- last modification
1727
  `expirationdate` date default NULL, -- date the article is set to expire or no longer be visible
1728
  `expirationdate` date default NULL, -- date the article is set to expire or no longer be visible
1728
  `number` int(11) default NULL, -- the order in which this article appears in that specific location
1729
  `number` int(11) default NULL, -- the order in which this article appears in that specific location
1729
  `borrowernumber` int(11) default NULL, -- The user who created the news article
1730
  `borrowernumber` int(11) default NULL, -- The user who created the news article
1730
- 

Return to bug 21066