db: use a binary seaweedfs_fid

This commit is contained in:
Lucas 2023-03-05 17:23:13 +00:00
parent 6ecf98f917
commit 8655e5fa04
2 changed files with 6 additions and 6 deletions

View File

@ -31,9 +31,9 @@ __PACKAGE__->table("media");
=head2 seaweedfs_fid
data_type: 'text'
data_type: 'blob'
is_nullable: 0
size: 33
size: 32
=head2 filename
@ -53,7 +53,7 @@ __PACKAGE__->add_columns(
"media_id",
{ data_type => "integer", is_auto_increment => 1, is_nullable => 0 },
"seaweedfs_fid",
{ data_type => "text", is_nullable => 0, size => 33 },
{ data_type => "blob", is_nullable => 0, size => 32 },
"filename",
{ data_type => "text", is_nullable => 0, size => 256 },
"content_type",
@ -100,8 +100,8 @@ Composing rels: L</media_tags> -> tag
__PACKAGE__->many_to_many("tags", "media_tags", "tag");
# Created by DBIx::Class::Schema::Loader v0.07049 @ 2023-03-04 20:47:27
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:E7eWNfGOqqI1Kub7Vv/WHQ
# Created by DBIx::Class::Schema::Loader v0.07049 @ 2023-03-05 13:14:18
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:gY4mMvaQ+cUpA3gtQc9pjg
# You can replace this text with custom code or comments, and it will be preserved on regeneration

View File

@ -1,6 +1,6 @@
CREATE TABLE media(
media_id INTEGER PRIMARY KEY,
seaweedfs_fid TEXT (33) NOT NULL,
seaweedfs_fid BLOB (32) NOT NULL,
filename TEXT (256) NOT NULL,
content_type TEXT (256)
);