windows package
This commit is contained in:
31
database/versions/14f1813ae8e3_1_0_1.py
Normal file
31
database/versions/14f1813ae8e3_1_0_1.py
Normal file
@ -0,0 +1,31 @@
|
||||
"""1.0.1
|
||||
|
||||
Revision ID: 14f1813ae8e3
|
||||
Revises: 9f4edd55c2d4
|
||||
Create Date: 2023-07-27 12:34:57.839443
|
||||
|
||||
"""
|
||||
from alembic import op
|
||||
import sqlalchemy as sa
|
||||
|
||||
|
||||
# revision identifiers, used by Alembic.
|
||||
revision = '14f1813ae8e3'
|
||||
down_revision = '9f4edd55c2d4'
|
||||
branch_labels = None
|
||||
depends_on = None
|
||||
|
||||
|
||||
def upgrade() -> None:
|
||||
# ### commands auto generated by Alembic - please adjust! ###
|
||||
try:
|
||||
with op.batch_alter_table("subscribe") as batch_op:
|
||||
batch_op.add_column(sa.Column('best_version', sa.Integer, nullable=True))
|
||||
batch_op.add_column(sa.Column('current_priority', sa.Integer, nullable=True))
|
||||
except Exception as e:
|
||||
pass
|
||||
# ### end Alembic commands ###
|
||||
|
||||
|
||||
def downgrade() -> None:
|
||||
pass
|
30
database/versions/1e169250e949_1_0_4.py
Normal file
30
database/versions/1e169250e949_1_0_4.py
Normal file
@ -0,0 +1,30 @@
|
||||
"""1.0.4
|
||||
|
||||
Revision ID: 1e169250e949
|
||||
Revises: 52ab4930be04
|
||||
Create Date: 2023-09-01 09:56:33.907661
|
||||
|
||||
"""
|
||||
from alembic import op
|
||||
import sqlalchemy as sa
|
||||
|
||||
|
||||
# revision identifiers, used by Alembic.
|
||||
revision = '1e169250e949'
|
||||
down_revision = '52ab4930be04'
|
||||
branch_labels = None
|
||||
depends_on = None
|
||||
|
||||
|
||||
def upgrade() -> None:
|
||||
# ### commands auto generated by Alembic - please adjust! ###
|
||||
try:
|
||||
with op.batch_alter_table("subscribe") as batch_op:
|
||||
batch_op.add_column(sa.Column('date', sa.String, nullable=True))
|
||||
except Exception as e:
|
||||
pass
|
||||
# ### end Alembic commands ###
|
||||
|
||||
|
||||
def downgrade() -> None:
|
||||
pass
|
40
database/versions/232dfa044617_1_0_6.py
Normal file
40
database/versions/232dfa044617_1_0_6.py
Normal file
@ -0,0 +1,40 @@
|
||||
"""1.0.6
|
||||
|
||||
Revision ID: 232dfa044617
|
||||
Revises: e734c7fe6056
|
||||
Create Date: 2023-09-19 21:34:41.994617
|
||||
|
||||
"""
|
||||
from alembic import op
|
||||
import sqlalchemy as sa
|
||||
|
||||
|
||||
# revision identifiers, used by Alembic.
|
||||
revision = '232dfa044617'
|
||||
down_revision = 'e734c7fe6056'
|
||||
branch_labels = None
|
||||
depends_on = None
|
||||
|
||||
|
||||
def upgrade() -> None:
|
||||
# ### commands auto generated by Alembic - please adjust! ###
|
||||
# 搜索优先级
|
||||
op.execute("delete from systemconfig where key = 'SearchFilterRules';")
|
||||
op.execute(
|
||||
"insert into systemconfig(key, value) VALUES('SearchFilterRules', (select value from systemconfig where key= 'FilterRules'));")
|
||||
# 订阅优先级
|
||||
op.execute("delete from systemconfig where key = 'SubscribeFilterRules';")
|
||||
op.execute(
|
||||
"insert into systemconfig(key, value) VALUES('SubscribeFilterRules', (select value from systemconfig where key= 'FilterRules'));")
|
||||
# 洗版优先级
|
||||
op.execute("delete from systemconfig where key = 'BestVersionFilterRules';")
|
||||
op.execute(
|
||||
"insert into systemconfig(key, value) VALUES('BestVersionFilterRules', (select value from systemconfig where key= 'FilterRules2'));")
|
||||
# 删除旧的优先级规则
|
||||
op.execute("delete from systemconfig where key = 'FilterRules';")
|
||||
op.execute("delete from systemconfig where key = 'FilterRules2';")
|
||||
# ### end Alembic commands ###
|
||||
|
||||
|
||||
def downgrade() -> None:
|
||||
pass
|
29
database/versions/30329639c12b_1_0_7.py
Normal file
29
database/versions/30329639c12b_1_0_7.py
Normal file
@ -0,0 +1,29 @@
|
||||
"""1.0.7
|
||||
|
||||
Revision ID: 30329639c12b
|
||||
Revises: 232dfa044617
|
||||
Create Date: 2023-09-23 08:25:59.776488
|
||||
|
||||
"""
|
||||
from alembic import op
|
||||
import sqlalchemy as sa
|
||||
|
||||
|
||||
# revision identifiers, used by Alembic.
|
||||
revision = '30329639c12b'
|
||||
down_revision = '232dfa044617'
|
||||
branch_labels = None
|
||||
depends_on = None
|
||||
|
||||
|
||||
def upgrade() -> None:
|
||||
# ### commands auto generated by Alembic - please adjust! ###
|
||||
op.execute("delete from systemconfig where key = 'DefaultFilterRules';")
|
||||
op.execute(
|
||||
"insert into systemconfig(key, value) VALUES('DefaultFilterRules', (select value from systemconfig where key= 'DefaultIncludeExcludeFilter'));")
|
||||
op.execute("delete from systemconfig where key = 'DefaultIncludeExcludeFilter';")
|
||||
# ### end Alembic commands ###
|
||||
|
||||
|
||||
def downgrade() -> None:
|
||||
pass
|
28
database/versions/52ab4930be04_1_0_3.py
Normal file
28
database/versions/52ab4930be04_1_0_3.py
Normal file
@ -0,0 +1,28 @@
|
||||
"""1_0_3
|
||||
|
||||
Revision ID: 52ab4930be04
|
||||
Revises: ec5fb51fc300
|
||||
Create Date: 2023-08-28 13:21:45.152012
|
||||
|
||||
"""
|
||||
from alembic import op
|
||||
|
||||
# revision identifiers, used by Alembic.
|
||||
revision = '52ab4930be04'
|
||||
down_revision = 'ec5fb51fc300'
|
||||
branch_labels = None
|
||||
depends_on = None
|
||||
|
||||
|
||||
def upgrade() -> None:
|
||||
# ### commands auto generated by Alembic - please adjust! ###
|
||||
op.execute("delete from systemconfig where key = 'RssSites';")
|
||||
op.execute("insert into systemconfig(key, value) VALUES('RssSites', (select value from systemconfig where key= 'IndexerSites'));")
|
||||
op.execute("delete from systemconfig where key = 'SearchResults';")
|
||||
# ### end Alembic commands ###
|
||||
|
||||
|
||||
def downgrade() -> None:
|
||||
# ### commands auto generated by Alembic - please adjust! ###
|
||||
pass
|
||||
# ### end Alembic commands ###
|
32
database/versions/9f4edd55c2d4_1_0_0.py
Normal file
32
database/versions/9f4edd55c2d4_1_0_0.py
Normal file
@ -0,0 +1,32 @@
|
||||
"""1.0.0
|
||||
|
||||
Revision ID: 9f4edd55c2d4
|
||||
Revises:
|
||||
Create Date: 2023-07-13 12:27:26.402317
|
||||
|
||||
"""
|
||||
from alembic import op
|
||||
import sqlalchemy as sa
|
||||
|
||||
|
||||
# revision identifiers, used by Alembic.
|
||||
revision = '9f4edd55c2d4'
|
||||
down_revision = None
|
||||
branch_labels = None
|
||||
depends_on = None
|
||||
|
||||
|
||||
def upgrade() -> None:
|
||||
# ### commands auto generated by Alembic - please adjust! ###
|
||||
try:
|
||||
with op.batch_alter_table("subscribe") as batch_op:
|
||||
batch_op.add_column(sa.Column('sites', sa.Text, nullable=True))
|
||||
except Exception as e:
|
||||
pass
|
||||
# ### end Alembic commands ###
|
||||
|
||||
|
||||
def downgrade() -> None:
|
||||
# ### commands auto generated by Alembic - please adjust! ###
|
||||
pass
|
||||
# ### end Alembic commands ###
|
30
database/versions/a521fbc28b18_1_0_9.py
Normal file
30
database/versions/a521fbc28b18_1_0_9.py
Normal file
@ -0,0 +1,30 @@
|
||||
"""1_0_9
|
||||
|
||||
Revision ID: a521fbc28b18
|
||||
Revises: b2f011d3a8b7
|
||||
Create Date: 2023-09-28 13:37:16.479360
|
||||
|
||||
"""
|
||||
from alembic import op
|
||||
import sqlalchemy as sa
|
||||
|
||||
|
||||
# revision identifiers, used by Alembic.
|
||||
revision = 'a521fbc28b18'
|
||||
down_revision = 'b2f011d3a8b7'
|
||||
branch_labels = None
|
||||
depends_on = None
|
||||
|
||||
|
||||
def upgrade() -> None:
|
||||
# ### commands auto generated by Alembic - please adjust! ###
|
||||
try:
|
||||
with op.batch_alter_table("downloadhistory") as batch_op:
|
||||
batch_op.add_column(sa.Column('date', sa.String, nullable=True))
|
||||
batch_op.add_column(sa.Column('channel', sa.String, nullable=True))
|
||||
except Exception as e:
|
||||
pass
|
||||
# ### end Alembic commands ###
|
||||
|
||||
def downgrade() -> None:
|
||||
pass
|
29
database/versions/b2f011d3a8b7_1_0_8.py
Normal file
29
database/versions/b2f011d3a8b7_1_0_8.py
Normal file
@ -0,0 +1,29 @@
|
||||
"""1_0_8
|
||||
|
||||
Revision ID: b2f011d3a8b7
|
||||
Revises: 30329639c12b
|
||||
Create Date: 2023-09-28 10:15:58.410003
|
||||
|
||||
"""
|
||||
from alembic import op
|
||||
import sqlalchemy as sa
|
||||
|
||||
|
||||
# revision identifiers, used by Alembic.
|
||||
revision = 'b2f011d3a8b7'
|
||||
down_revision = '30329639c12b'
|
||||
branch_labels = None
|
||||
depends_on = None
|
||||
|
||||
|
||||
def upgrade() -> None:
|
||||
# ### commands auto generated by Alembic - please adjust! ###
|
||||
try:
|
||||
with op.batch_alter_table("downloadhistory") as batch_op:
|
||||
batch_op.add_column(sa.Column('userid', sa.String, nullable=True))
|
||||
except Exception as e:
|
||||
pass
|
||||
# ### end Alembic commands ###
|
||||
|
||||
def downgrade() -> None:
|
||||
pass
|
27
database/versions/e734c7fe6056_1_0_5.py
Normal file
27
database/versions/e734c7fe6056_1_0_5.py
Normal file
@ -0,0 +1,27 @@
|
||||
"""1.0.5
|
||||
|
||||
Revision ID: e734c7fe6056
|
||||
Revises: 1e169250e949
|
||||
Create Date: 2023-09-07 18:19:41.250957
|
||||
|
||||
"""
|
||||
from alembic import op
|
||||
|
||||
# revision identifiers, used by Alembic.
|
||||
revision = 'e734c7fe6056'
|
||||
down_revision = '1e169250e949'
|
||||
branch_labels = None
|
||||
depends_on = None
|
||||
|
||||
|
||||
def upgrade() -> None:
|
||||
# ### commands auto generated by Alembic - please adjust! ###
|
||||
try:
|
||||
op.create_index('ix_transferhistory_tmdbid', 'transferhistory', ['tmdbid'], unique=False)
|
||||
except Exception as err:
|
||||
pass
|
||||
# ### end Alembic commands ###
|
||||
|
||||
|
||||
def downgrade() -> None:
|
||||
pass
|
32
database/versions/ec5fb51fc300_1_0_2.py
Normal file
32
database/versions/ec5fb51fc300_1_0_2.py
Normal file
@ -0,0 +1,32 @@
|
||||
"""1.0.2
|
||||
|
||||
Revision ID: ec5fb51fc300
|
||||
Revises: 14f1813ae8e3
|
||||
Create Date: 2023-08-12 17:55:06.509548
|
||||
|
||||
"""
|
||||
from alembic import op
|
||||
import sqlalchemy as sa
|
||||
|
||||
|
||||
# revision identifiers, used by Alembic.
|
||||
revision = 'ec5fb51fc300'
|
||||
down_revision = '14f1813ae8e3'
|
||||
branch_labels = None
|
||||
depends_on = None
|
||||
|
||||
|
||||
def upgrade() -> None:
|
||||
# ### commands auto generated by Alembic - please adjust! ###
|
||||
try:
|
||||
with op.batch_alter_table("transferhistory") as batch_op:
|
||||
batch_op.add_column(sa.Column('files', sa.String, nullable=True))
|
||||
with op.batch_alter_table("rss") as batch_op:
|
||||
batch_op.add_column(sa.Column('filter', sa.Integer, nullable=True))
|
||||
except Exception as e:
|
||||
pass
|
||||
# ### end Alembic commands ###
|
||||
|
||||
|
||||
def downgrade() -> None:
|
||||
pass
|
Reference in New Issue
Block a user