Update schema for size support of enclosures
This commit is contained in:
parent
1da6e22006
commit
06c4c9ebae
5 changed files with 23 additions and 3 deletions
|
@ -1,6 +1,6 @@
|
|||
<?php
|
||||
define('EXPECTED_CONFIG_VERSION', 26);
|
||||
define('SCHEMA_VERSION', 125);
|
||||
define('SCHEMA_VERSION', 126);
|
||||
|
||||
define('LABEL_BASE_INDEX', -1024);
|
||||
define('PLUGIN_FEED_BASE_INDEX', -128);
|
||||
|
|
|
@ -301,7 +301,7 @@ create table ttrss_tags (id integer primary key auto_increment,
|
|||
|
||||
create table ttrss_version (schema_version int not null) ENGINE=InnoDB DEFAULT CHARSET=UTF8;
|
||||
|
||||
insert into ttrss_version values (125);
|
||||
insert into ttrss_version values (126);
|
||||
|
||||
create table ttrss_enclosures (id integer primary key auto_increment,
|
||||
content_url text not null,
|
||||
|
@ -309,6 +309,8 @@ create table ttrss_enclosures (id integer primary key auto_increment,
|
|||
post_id integer not null,
|
||||
title text not null,
|
||||
duration text not null,
|
||||
width integer not null default 0,
|
||||
height integer not null default 0,
|
||||
index (post_id),
|
||||
foreign key (post_id) references ttrss_entries(id) ON DELETE cascade) ENGINE=InnoDB DEFAULT CHARSET=UTF8;
|
||||
|
||||
|
|
|
@ -261,13 +261,15 @@ create index ttrss_tags_post_int_id_idx on ttrss_tags(post_int_id);
|
|||
|
||||
create table ttrss_version (schema_version int not null);
|
||||
|
||||
insert into ttrss_version values (125);
|
||||
insert into ttrss_version values (126);
|
||||
|
||||
create table ttrss_enclosures (id serial not null primary key,
|
||||
content_url text not null,
|
||||
content_type varchar(250) not null,
|
||||
title text not null,
|
||||
duration text not null,
|
||||
width integer not null default 0,
|
||||
height integer not null default 0,
|
||||
post_id integer references ttrss_entries(id) ON DELETE cascade NOT NULL);
|
||||
|
||||
create index ttrss_enclosures_post_id_idx on ttrss_enclosures(post_id);
|
||||
|
|
8
schema/versions/mysql/126.sql
Normal file
8
schema/versions/mysql/126.sql
Normal file
|
@ -0,0 +1,8 @@
|
|||
begin;
|
||||
|
||||
alter table ttrss_enclosures add column width integer not null default 0;
|
||||
alter table ttrss_enclosures add column height integer not null default 0;
|
||||
|
||||
update ttrss_version set schema_version = 126;
|
||||
|
||||
commit;
|
8
schema/versions/pgsql/126.sql
Normal file
8
schema/versions/pgsql/126.sql
Normal file
|
@ -0,0 +1,8 @@
|
|||
begin;
|
||||
|
||||
alter table ttrss_enclosures add column height integer not null default 0;
|
||||
alter table ttrss_enclosures add column width integer not null default 0;
|
||||
|
||||
update ttrss_version set schema_version = 126;
|
||||
|
||||
commit;
|
Loading…
Reference in a new issue