diff --git a/.sqlx/query-c49b88eda9a62743783bc894f01bb6198594f94a3e0856abde0efdb4e49dbab8.json b/.sqlx/query-7b1265f893e68df4ebde549fed8dc1872c723d1294521a72d9d2251f4ddd8da6.json similarity index 65% rename from .sqlx/query-c49b88eda9a62743783bc894f01bb6198594f94a3e0856abde0efdb4e49dbab8.json rename to .sqlx/query-7b1265f893e68df4ebde549fed8dc1872c723d1294521a72d9d2251f4ddd8da6.json index 9b27b4a..785ebb3 100644 --- a/.sqlx/query-c49b88eda9a62743783bc894f01bb6198594f94a3e0856abde0efdb4e49dbab8.json +++ b/.sqlx/query-7b1265f893e68df4ebde549fed8dc1872c723d1294521a72d9d2251f4ddd8da6.json @@ -1,6 +1,6 @@ { "db_name": "PostgreSQL", - "query": "SELECT\n items.name,\n items.parent,\n items.class,\n item_classes.name AS \"class_name\",\n items.original_packaging,\n items.description\n FROM items\n JOIN item_classes\n ON items.class = item_classes.id\n WHERE items.id = $1", + "query": "SELECT\n items.name,\n items.parent,\n items.class,\n items.original_packaging,\n items.description\n FROM items\n WHERE items.id = $1", "describe": { "columns": [ { @@ -20,16 +20,11 @@ }, { "ordinal": 3, - "name": "class_name", - "type_info": "Varchar" - }, - { - "ordinal": 4, "name": "original_packaging", "type_info": "Uuid" }, { - "ordinal": 5, + "ordinal": 4, "name": "description", "type_info": "Varchar" } @@ -43,10 +38,9 @@ true, true, false, - false, true, false ] }, - "hash": "c49b88eda9a62743783bc894f01bb6198594f94a3e0856abde0efdb4e49dbab8" + "hash": "7b1265f893e68df4ebde549fed8dc1872c723d1294521a72d9d2251f4ddd8da6" } diff --git a/src/database/items/edit.rs b/src/database/items/edit.rs index 91b3bcd..061c3b9 100644 --- a/src/database/items/edit.rs +++ b/src/database/items/edit.rs @@ -24,12 +24,9 @@ impl ItemRepository { items.name, items.parent, items.class, - item_classes.name AS "class_name", items.original_packaging, items.description FROM items - JOIN item_classes - ON items.class = item_classes.id WHERE items.id = $1"#, id )