diff --git a/migrations/2024-11-01-080726_tile_cache/up.sql b/migrations/2024-11-01-080726_tile_cache/up.sql index 48839ae..da9b531 100644 --- a/migrations/2024-11-01-080726_tile_cache/up.sql +++ b/migrations/2024-11-01-080726_tile_cache/up.sql @@ -2,8 +2,8 @@ CREATE TABLE gtfs.tile_storage ( category smallint not null, z smallint not null, - x smallint not null, - y smallint not null, + x int not null, + y int not null, mvt_data bytea not null, added_time Timestamptz not null, diff --git a/src/models.rs b/src/models.rs index 384911e..65d70fd 100644 --- a/src/models.rs +++ b/src/models.rs @@ -418,8 +418,8 @@ pub struct IpToGeoAddr { pub struct TileStorage { pub category: i16, pub z: i16, - pub x: i16, - pub y: i16, + pub x: i32, + pub y: i32, pub mvt_data: Vec, pub added_time: chrono::DateTime } \ No newline at end of file diff --git a/src/schema.rs b/src/schema.rs index 4159ab5..3b9e508 100644 --- a/src/schema.rs +++ b/src/schema.rs @@ -465,8 +465,8 @@ pub mod gtfs { gtfs.tile_storage (category, z, x, y) { category -> Int2, z -> Int2, - x -> Int2, - y -> Int2, + x -> Int4, + y -> Int4, mvt_data -> Bytea, added_time -> Timestamptz, } diff --git a/src/tile_save_and_get.rs b/src/tile_save_and_get.rs index e69de29..4524ae4 100644 --- a/src/tile_save_and_get.rs +++ b/src/tile_save_and_get.rs @@ -0,0 +1,3 @@ +pub fn insert_tile(z: i16, x: i32, y: i32) { + +} \ No newline at end of file