From 4a9bcde9ea587bca73e02d08dc5a38e01bf88a3f Mon Sep 17 00:00:00 2001 From: Hayden <64056131+hay-kot@users.noreply.github.com> Date: Sat, 1 Apr 2023 12:08:44 -0800 Subject: [PATCH 1/5] fix insufficiently large max height for cards --- frontend/components/Base/Card.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontend/components/Base/Card.vue b/frontend/components/Base/Card.vue index 88fef80..512748c 100644 --- a/frontend/components/Base/Card.vue +++ b/frontend/components/Base/Card.vue @@ -23,7 +23,7 @@
Date: Sat, 1 Apr 2023 12:09:11 -0800 Subject: [PATCH 2/5] fix listener for resetItemDateTimes --- frontend/pages/tools.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontend/pages/tools.vue b/frontend/pages/tools.vue index 7612659..188a75f 100644 --- a/frontend/pages/tools.vue +++ b/frontend/pages/tools.vue @@ -73,7 +73,7 @@ Ensures that all items in your inventory have a valid import_ref field. This is done by randomly generating a 8 character string for each item that has an unset import_ref field. - + Resets the time value for all date time fields in your inventory to the beginning of the date. This is to fix a bug that was introduced early on in the development of the site that caused the time value to be From 3ed72daa64c77bc0ad2430257c1d0315ff1f0ecd Mon Sep 17 00:00:00 2001 From: Hayden <64056131+hay-kot@users.noreply.github.com> Date: Sat, 1 Apr 2023 12:09:20 -0800 Subject: [PATCH 3/5] support YYYY/MM/DD format for imports --- backend/internal/data/types/date.go | 1 + 1 file changed, 1 insertion(+) diff --git a/backend/internal/data/types/date.go b/backend/internal/data/types/date.go index 1b8b182..1c4b5fa 100644 --- a/backend/internal/data/types/date.go +++ b/backend/internal/data/types/date.go @@ -41,6 +41,7 @@ func DateFromString(s string) Date { try := [...]string{ "2006-01-02", "01/02/2006", + "2006/01/02", time.RFC3339, } From c41a43d80467dbd0c86a98107a7b1f88ac648cdc Mon Sep 17 00:00:00 2001 From: Hayden <64056131+hay-kot@users.noreply.github.com> Date: Sat, 1 Apr 2023 12:13:24 -0800 Subject: [PATCH 4/5] fix columns in docs --- docs/docs/import-csv.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/docs/import-csv.md b/docs/docs/import-csv.md index 5dffc38..8d5586f 100644 --- a/docs/docs/import-csv.md +++ b/docs/docs/import-csv.md @@ -64,12 +64,12 @@ Below are the supported columns. They are case sensitive, can be in any ordered | HB.notes | String (1000) | General notes about the product | | HB.purchase_from | String | Name of the place the item was purchased from | | HB.purchase_price | Float64 | | -| HB.purchase_at | Date | Date the item was purchased | +| HB.purchase_time | Date | Date the item was purchased | | HB.lifetime_warranty | Boolean | true or false - case insensitive | | HB.warranty_expires | Date | Date in the format | | HB.warranty_details | String | Details about the warranty | | HB.sold_to | String | Name of the person the item was sold to | -| HB.sold_at | Date | Date the item was sold | +| HB.sold_time | Date | Date the item was sold | | HB.sold_price | Float64 | | | HB.sold_notes | String (1000) | | From 0e48256b7763108ba0aabb1bfa0070595acdc775 Mon Sep 17 00:00:00 2001 From: Hayden <64056131+hay-kot@users.noreply.github.com> Date: Sat, 1 Apr 2023 12:21:05 -0800 Subject: [PATCH 5/5] use comma deliminator --- backend/app/api/handlers/v1/v1_ctrl_items.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/backend/app/api/handlers/v1/v1_ctrl_items.go b/backend/app/api/handlers/v1/v1_ctrl_items.go index d38c037..062fbad 100644 --- a/backend/app/api/handlers/v1/v1_ctrl_items.go +++ b/backend/app/api/handlers/v1/v1_ctrl_items.go @@ -261,7 +261,9 @@ func (ctrl *V1Controller) HandleItemsExport() errchain.HandlerFunc { w.Header().Set("Content-Type", "text/tsv") w.Header().Set("Content-Disposition", "attachment;filename=homebox-items.tsv") + writer := csv.NewWriter(w) + writer.Comma = '\t' return writer.WriteAll(csvData) } }