From c211a8a199f2b11b6546a478bcb8038d4ee3aa2b Mon Sep 17 00:00:00 2001 From: Joe Arndt Date: Sun, 8 Feb 2026 17:55:41 -0600 Subject: [PATCH] added bruno files and corrected found issues --- .../Categories/LOC DELETE Category.bru | 15 +++++++++++++++ .../Categories/LOC GET Categories.bru | 11 +++++++++++ .../Categories/LOC GET Category By ID.bru | 15 +++++++++++++++ .../Categories/LOC POST Category.bru | 17 +++++++++++++++++ .../Categories/LOC PUT Category.bru | 18 ++++++++++++++++++ bruno/Common Cents/Categories/folder.bru | 11 +++++++++++ bruno/Common Cents/Expenses/folder.bru | 1 + .../Merchants/LOC DELETE Merchant.bru | 6 +++++- .../Merchants/LOC GET Merchant By ID.bru | 4 ++-- .../Merchants/LOC GET Merchants.bru | 2 +- .../Merchants/LOC POST Merchant.bru | 4 ++-- .../Merchants/LOC PUT Merchant.bru | 4 ++-- bruno/Common Cents/Merchants/folder.bru | 5 ++++- .../LOC DELETE Sub-category.bru | 15 +++++++++++++++ .../Sub-categories/LOC GET Sub-categories.bru | 11 +++++++++++ .../LOC GET Sub-category By ID.bru | 15 +++++++++++++++ .../Sub-categories/LOC POST Sub-category.bru | 17 +++++++++++++++++ .../Sub-categories/LOC PUT Sub-category.bru | 18 ++++++++++++++++++ bruno/Common Cents/Sub-categories/folder.bru | 11 +++++++++++ bruno/Common Cents/Tags/LOC DELETE Tag.bru | 15 +++++++++++++++ bruno/Common Cents/Tags/LOC GET Tag By ID.bru | 15 +++++++++++++++ bruno/Common Cents/Tags/LOC GET Tags.bru | 11 +++++++++++ bruno/Common Cents/Tags/LOC POST Tag.bru | 17 +++++++++++++++++ bruno/Common Cents/Tags/LOC PUT Tag.bru | 18 ++++++++++++++++++ bruno/Common Cents/Tags/folder.bru | 11 +++++++++++ common-cents.db | Bin 12288 -> 45056 bytes src/categories/categories.controller.ts | 2 +- src/categories/entities/category.entity.ts | 11 ++++++++++- .../entities/sub-category.entity.ts | 2 +- .../sub-categories.controller.ts | 2 +- src/tags/tags.controller.ts | 2 +- 31 files changed, 292 insertions(+), 14 deletions(-) create mode 100644 bruno/Common Cents/Categories/LOC DELETE Category.bru create mode 100644 bruno/Common Cents/Categories/LOC GET Categories.bru create mode 100644 bruno/Common Cents/Categories/LOC GET Category By ID.bru create mode 100644 bruno/Common Cents/Categories/LOC POST Category.bru create mode 100644 bruno/Common Cents/Categories/LOC PUT Category.bru create mode 100644 bruno/Common Cents/Categories/folder.bru create mode 100644 bruno/Common Cents/Sub-categories/LOC DELETE Sub-category.bru create mode 100644 bruno/Common Cents/Sub-categories/LOC GET Sub-categories.bru create mode 100644 bruno/Common Cents/Sub-categories/LOC GET Sub-category By ID.bru create mode 100644 bruno/Common Cents/Sub-categories/LOC POST Sub-category.bru create mode 100644 bruno/Common Cents/Sub-categories/LOC PUT Sub-category.bru create mode 100644 bruno/Common Cents/Sub-categories/folder.bru create mode 100644 bruno/Common Cents/Tags/LOC DELETE Tag.bru create mode 100644 bruno/Common Cents/Tags/LOC GET Tag By ID.bru create mode 100644 bruno/Common Cents/Tags/LOC GET Tags.bru create mode 100644 bruno/Common Cents/Tags/LOC POST Tag.bru create mode 100644 bruno/Common Cents/Tags/LOC PUT Tag.bru create mode 100644 bruno/Common Cents/Tags/folder.bru diff --git a/bruno/Common Cents/Categories/LOC DELETE Category.bru b/bruno/Common Cents/Categories/LOC DELETE Category.bru new file mode 100644 index 0000000..9f4a425 --- /dev/null +++ b/bruno/Common Cents/Categories/LOC DELETE Category.bru @@ -0,0 +1,15 @@ +meta { + name: LOC DELETE Category + type: http + seq: 5 +} + +delete { + url: {{localBaseUrl}}/{{resourcePath}}/{{resourceId}} + body: none + auth: inherit +} + +vars:pre-request { + resourceId: cbf30070-9ff7-419f-a567-f7d145be445b +} diff --git a/bruno/Common Cents/Categories/LOC GET Categories.bru b/bruno/Common Cents/Categories/LOC GET Categories.bru new file mode 100644 index 0000000..8d46826 --- /dev/null +++ b/bruno/Common Cents/Categories/LOC GET Categories.bru @@ -0,0 +1,11 @@ +meta { + name: LOC GET Categories + type: http + seq: 1 +} + +get { + url: {{localBaseUrl}}/{{resourcePath}} + body: none + auth: inherit +} diff --git a/bruno/Common Cents/Categories/LOC GET Category By ID.bru b/bruno/Common Cents/Categories/LOC GET Category By ID.bru new file mode 100644 index 0000000..76e9ed0 --- /dev/null +++ b/bruno/Common Cents/Categories/LOC GET Category By ID.bru @@ -0,0 +1,15 @@ +meta { + name: LOC GET Category By ID + type: http + seq: 2 +} + +get { + url: {{localBaseUrl}}/{{resourcePath}}/{{resourceId}} + body: none + auth: inherit +} + +vars:pre-request { + resourceId: 1d6d2842-b271-489b-bd93-e3ceaee5a139 +} diff --git a/bruno/Common Cents/Categories/LOC POST Category.bru b/bruno/Common Cents/Categories/LOC POST Category.bru new file mode 100644 index 0000000..9168b98 --- /dev/null +++ b/bruno/Common Cents/Categories/LOC POST Category.bru @@ -0,0 +1,17 @@ +meta { + name: LOC POST Category + type: http + seq: 3 +} + +post { + url: {{localBaseUrl}}/{{resourcePath}} + body: json + auth: inherit +} + +body:json { + { + "name": "Category Three" + } +} diff --git a/bruno/Common Cents/Categories/LOC PUT Category.bru b/bruno/Common Cents/Categories/LOC PUT Category.bru new file mode 100644 index 0000000..f76470f --- /dev/null +++ b/bruno/Common Cents/Categories/LOC PUT Category.bru @@ -0,0 +1,18 @@ +meta { + name: LOC PUT Category + type: http + seq: 4 +} + +put { + url: {{localBaseUrl}}/{{resourcePath}} + body: json + auth: inherit +} + +body:json { + { + "id": "1d6d2842-b271-489b-bd93-e3ceaee5a139", + "name": "Merchant One" + } +} diff --git a/bruno/Common Cents/Categories/folder.bru b/bruno/Common Cents/Categories/folder.bru new file mode 100644 index 0000000..c32401e --- /dev/null +++ b/bruno/Common Cents/Categories/folder.bru @@ -0,0 +1,11 @@ +meta { + name: Categories +} + +auth { + mode: inherit +} + +vars:pre-request { + resourcePath: categories +} diff --git a/bruno/Common Cents/Expenses/folder.bru b/bruno/Common Cents/Expenses/folder.bru index a577d38..9a3fbf0 100644 --- a/bruno/Common Cents/Expenses/folder.bru +++ b/bruno/Common Cents/Expenses/folder.bru @@ -1,3 +1,4 @@ meta { name: Expenses + seq: 2 } diff --git a/bruno/Common Cents/Merchants/LOC DELETE Merchant.bru b/bruno/Common Cents/Merchants/LOC DELETE Merchant.bru index cc0158a..2ae38e1 100644 --- a/bruno/Common Cents/Merchants/LOC DELETE Merchant.bru +++ b/bruno/Common Cents/Merchants/LOC DELETE Merchant.bru @@ -5,7 +5,11 @@ meta { } delete { - url: {{localBaseUrl}}/merchants/cbf30070-9ff7-419f-a567-f7d145be445b + url: {{localBaseUrl}}/{{resourcePath}}/{{resourceId}} body: none auth: inherit } + +vars:pre-request { + resourceId: cbf30070-9ff7-419f-a567-f7d145be445b +} diff --git a/bruno/Common Cents/Merchants/LOC GET Merchant By ID.bru b/bruno/Common Cents/Merchants/LOC GET Merchant By ID.bru index 55caec8..16281af 100644 --- a/bruno/Common Cents/Merchants/LOC GET Merchant By ID.bru +++ b/bruno/Common Cents/Merchants/LOC GET Merchant By ID.bru @@ -5,11 +5,11 @@ meta { } get { - url: {{localBaseUrl}}/merchants/{{merchantId}} + url: {{localBaseUrl}}/{{resourcePath}}/{{resourceId}} body: none auth: inherit } vars:pre-request { - merchantId: 1d6d2842-b271-489b-bd93-e3ceaee5a139 + resourceId: 1d6d2842-b271-489b-bd93-e3ceaee5a139 } diff --git a/bruno/Common Cents/Merchants/LOC GET Merchants.bru b/bruno/Common Cents/Merchants/LOC GET Merchants.bru index 35da33e..5ba79b7 100644 --- a/bruno/Common Cents/Merchants/LOC GET Merchants.bru +++ b/bruno/Common Cents/Merchants/LOC GET Merchants.bru @@ -5,7 +5,7 @@ meta { } get { - url: {{localBaseUrl}}/merchants + url: {{localBaseUrl}}/{{resourcePath}} body: none auth: inherit } diff --git a/bruno/Common Cents/Merchants/LOC POST Merchant.bru b/bruno/Common Cents/Merchants/LOC POST Merchant.bru index e78d086..60e5466 100644 --- a/bruno/Common Cents/Merchants/LOC POST Merchant.bru +++ b/bruno/Common Cents/Merchants/LOC POST Merchant.bru @@ -5,13 +5,13 @@ meta { } post { - url: {{localBaseUrl}}/merchants + url: {{localBaseUrl}}/{{resourcePath}} body: json auth: inherit } body:json { { - "name": "Walmart" + "name": "Merchant Three" } } diff --git a/bruno/Common Cents/Merchants/LOC PUT Merchant.bru b/bruno/Common Cents/Merchants/LOC PUT Merchant.bru index e91a0e8..80247ed 100644 --- a/bruno/Common Cents/Merchants/LOC PUT Merchant.bru +++ b/bruno/Common Cents/Merchants/LOC PUT Merchant.bru @@ -5,7 +5,7 @@ meta { } put { - url: {{localBaseUrl}}/merchants + url: {{localBaseUrl}}/{{resourcePath}} body: json auth: inherit } @@ -13,6 +13,6 @@ put { body:json { { "id": "1d6d2842-b271-489b-bd93-e3ceaee5a139", - "name": "Walmart" + "name": "Merchant One" } } diff --git a/bruno/Common Cents/Merchants/folder.bru b/bruno/Common Cents/Merchants/folder.bru index caac236..2ffb460 100644 --- a/bruno/Common Cents/Merchants/folder.bru +++ b/bruno/Common Cents/Merchants/folder.bru @@ -1,8 +1,11 @@ meta { name: Merchants - seq: 3 } auth { mode: inherit } + +vars:pre-request { + resourcePath: merchants +} diff --git a/bruno/Common Cents/Sub-categories/LOC DELETE Sub-category.bru b/bruno/Common Cents/Sub-categories/LOC DELETE Sub-category.bru new file mode 100644 index 0000000..c10a511 --- /dev/null +++ b/bruno/Common Cents/Sub-categories/LOC DELETE Sub-category.bru @@ -0,0 +1,15 @@ +meta { + name: LOC DELETE Sub-category + type: http + seq: 5 +} + +delete { + url: {{localBaseUrl}}/{{resourcePath}}/{{resourceId}} + body: none + auth: inherit +} + +vars:pre-request { + resourceId: cbf30070-9ff7-419f-a567-f7d145be445b +} diff --git a/bruno/Common Cents/Sub-categories/LOC GET Sub-categories.bru b/bruno/Common Cents/Sub-categories/LOC GET Sub-categories.bru new file mode 100644 index 0000000..e2eb171 --- /dev/null +++ b/bruno/Common Cents/Sub-categories/LOC GET Sub-categories.bru @@ -0,0 +1,11 @@ +meta { + name: LOC GET Sub-categories + type: http + seq: 1 +} + +get { + url: {{localBaseUrl}}/{{resourcePath}} + body: none + auth: inherit +} diff --git a/bruno/Common Cents/Sub-categories/LOC GET Sub-category By ID.bru b/bruno/Common Cents/Sub-categories/LOC GET Sub-category By ID.bru new file mode 100644 index 0000000..6703655 --- /dev/null +++ b/bruno/Common Cents/Sub-categories/LOC GET Sub-category By ID.bru @@ -0,0 +1,15 @@ +meta { + name: LOC GET Sub-category By ID + type: http + seq: 2 +} + +get { + url: {{localBaseUrl}}/{{resourcePath}}/{{resourceId}} + body: none + auth: inherit +} + +vars:pre-request { + resourceId: 1d6d2842-b271-489b-bd93-e3ceaee5a139 +} diff --git a/bruno/Common Cents/Sub-categories/LOC POST Sub-category.bru b/bruno/Common Cents/Sub-categories/LOC POST Sub-category.bru new file mode 100644 index 0000000..2d221f4 --- /dev/null +++ b/bruno/Common Cents/Sub-categories/LOC POST Sub-category.bru @@ -0,0 +1,17 @@ +meta { + name: LOC POST Sub-category + type: http + seq: 3 +} + +post { + url: {{localBaseUrl}}/{{resourcePath}} + body: json + auth: inherit +} + +body:json { + { + "name": "Sub-category Three" + } +} diff --git a/bruno/Common Cents/Sub-categories/LOC PUT Sub-category.bru b/bruno/Common Cents/Sub-categories/LOC PUT Sub-category.bru new file mode 100644 index 0000000..060a9b0 --- /dev/null +++ b/bruno/Common Cents/Sub-categories/LOC PUT Sub-category.bru @@ -0,0 +1,18 @@ +meta { + name: LOC PUT Sub-category + type: http + seq: 4 +} + +put { + url: {{localBaseUrl}}/{{resourcePath}} + body: json + auth: inherit +} + +body:json { + { + "id": "1d6d2842-b271-489b-bd93-e3ceaee5a139", + "name": "Merchant One" + } +} diff --git a/bruno/Common Cents/Sub-categories/folder.bru b/bruno/Common Cents/Sub-categories/folder.bru new file mode 100644 index 0000000..a7f720c --- /dev/null +++ b/bruno/Common Cents/Sub-categories/folder.bru @@ -0,0 +1,11 @@ +meta { + name: Sub-categories +} + +auth { + mode: inherit +} + +vars:pre-request { + resourcePath: sub-categories +} diff --git a/bruno/Common Cents/Tags/LOC DELETE Tag.bru b/bruno/Common Cents/Tags/LOC DELETE Tag.bru new file mode 100644 index 0000000..05f60dd --- /dev/null +++ b/bruno/Common Cents/Tags/LOC DELETE Tag.bru @@ -0,0 +1,15 @@ +meta { + name: LOC DELETE Tag + type: http + seq: 5 +} + +delete { + url: {{localBaseUrl}}/{{resourcePath}}/{{resourceId}} + body: none + auth: inherit +} + +vars:pre-request { + resourceId: cbf30070-9ff7-419f-a567-f7d145be445b +} diff --git a/bruno/Common Cents/Tags/LOC GET Tag By ID.bru b/bruno/Common Cents/Tags/LOC GET Tag By ID.bru new file mode 100644 index 0000000..8abbecb --- /dev/null +++ b/bruno/Common Cents/Tags/LOC GET Tag By ID.bru @@ -0,0 +1,15 @@ +meta { + name: LOC GET Tag By ID + type: http + seq: 2 +} + +get { + url: {{localBaseUrl}}/{{resourcePath}}/{{resourceId}} + body: none + auth: inherit +} + +vars:pre-request { + resourceId: 1d6d2842-b271-489b-bd93-e3ceaee5a139 +} diff --git a/bruno/Common Cents/Tags/LOC GET Tags.bru b/bruno/Common Cents/Tags/LOC GET Tags.bru new file mode 100644 index 0000000..dc19694 --- /dev/null +++ b/bruno/Common Cents/Tags/LOC GET Tags.bru @@ -0,0 +1,11 @@ +meta { + name: LOC GET Tags + type: http + seq: 1 +} + +get { + url: {{localBaseUrl}}/{{resourcePath}} + body: none + auth: inherit +} diff --git a/bruno/Common Cents/Tags/LOC POST Tag.bru b/bruno/Common Cents/Tags/LOC POST Tag.bru new file mode 100644 index 0000000..565a854 --- /dev/null +++ b/bruno/Common Cents/Tags/LOC POST Tag.bru @@ -0,0 +1,17 @@ +meta { + name: LOC POST Tag + type: http + seq: 3 +} + +post { + url: {{localBaseUrl}}/{{resourcePath}} + body: json + auth: inherit +} + +body:json { + { + "name": "Tag Three" + } +} diff --git a/bruno/Common Cents/Tags/LOC PUT Tag.bru b/bruno/Common Cents/Tags/LOC PUT Tag.bru new file mode 100644 index 0000000..ac4b434 --- /dev/null +++ b/bruno/Common Cents/Tags/LOC PUT Tag.bru @@ -0,0 +1,18 @@ +meta { + name: LOC PUT Tag + type: http + seq: 4 +} + +put { + url: {{localBaseUrl}}/{{resourcePath}} + body: json + auth: inherit +} + +body:json { + { + "id": "1d6d2842-b271-489b-bd93-e3ceaee5a139", + "name": "Merchant One" + } +} diff --git a/bruno/Common Cents/Tags/folder.bru b/bruno/Common Cents/Tags/folder.bru new file mode 100644 index 0000000..aa07bea --- /dev/null +++ b/bruno/Common Cents/Tags/folder.bru @@ -0,0 +1,11 @@ +meta { + name: Tags +} + +auth { + mode: inherit +} + +vars:pre-request { + resourcePath: tags +} diff --git a/common-cents.db b/common-cents.db index 448549dcbfbdb1db8817c33bc7dac91538a9cf70..656df02793aebdfd293419782f8ff440411bd172 100644 GIT binary patch literal 45056 zcmeI*O;6)S7zc2hP~L-Eu~JkaR4WoHD|T3qXZ)tBQYqrl!oKlx;1tc+V-{&iN(iNU z=z+@~d+fRD7wEO$U{&?fW4}UAz3#D390CdIc2gmc*!(RSJGRF&^RtDNnRzDL&o&QQ z#?2eeL)CJH^`T|k))%g8S=K#Tr)iy_)uwfd)=^r!OZ(WnmV4Gp^XKyHXVzqS#&UL? z*R#Jlto&Dbz5MI!*X5a+H}ARu&O-nK5P$##AOHafKmY=FLEvnDYP^yp_Sv(ukIwf# zZz=u4w9Mf*jize8tR0`|TB=%RztMd8??@eFE`iSYHxz7yHq{Ms_wU{ znLbxd_vzMGk5;$#+>P};_wkb*_wnxL<^#7{SBK{EqV9?N8`EQzT4GxV^~`*CeDs38 z1l1xswz1fMOr5kE#Wj6}t?}NHOdm~*R~8oRv!JM7w?^IVSbrV5hp$)uhm&KKwS~8p zwVOwcclRcrj*V58m+ifxi02hPHb*C>o|-Ek$NLI=<>XQu^Z}*3@4T^`%HpDZ*16~R z^pM-1IuE(mr+5Fx9;hyjSLWvIv*pe^ruJKEf3&Y6RXTD#^u^J!N;3C0bh>?w)1MEH z?B3Vm(6ryrdaJt~=`U3G@byaeaOA&Uhi)D<-rXzFe~|X~daF!p$*Eb+@6M03!2$sY zKmY;|fB*y_009U<00Izz!2cHrN~PWVA@^mNX~_iV9+SE8na-4ESC`iFg)fek>^mKjKWr ziKe^~!Hh_aGA2-5Bo~RE)J?lnzvR5KoIjmkXoCd;5P$##AOHafKmY;|fB*y_0D&75 zSSsz>gR~Nq+7}MeE->2|HpYe#vAdQ&HRLsKMM0uR1apZeDYQHlQV1-5k%qN1z4DeX7 zIMN}Lp(mNvGNA5#lW7qs8OE|maoSj+K>+i9$iqDHCCjPTpRUhx7Hi?LIEivDqde46 zaeZ(9|Eu;0fFXJms44^?009U<00Izz00bZa0SG|g)&<(#`hzqJ6#f5$v<4LY|ARCG zApZZ>A2u?C00bZa0SG_<0uX=z1Rwx`_fMdR|5uU7b)IF6Co*9a%%8A0%~EDm!jnkT z8~{38JD&!#C;s1A&Ut{r=&jMi77i1Rwwb2tWV=5P$##AOL}( z68P9IB@@LDY&dplaiaJ47>3FLm4yHVAOHafKmY;|fB*y_009ULsldhj|A_w|(l-Fr zh5!U0009U<00Izz00bZaf!h;k$Nvu!B~Zlw4-ywp#QzTx3($%G-?p6B&JWJ^?bR4L zK>z{}fB*y_009U<00Izz00i#1KthxJb3gJ@ql{uns$(Y8kS6b!VNNmsA~2cExSvPc zCz_>wasLs`_RsP>$bC=wOzB9_bOBMubi@sdxe2sTbW)oBq^FIDru}Dzdt73-T($;fXo9iA5z`K${u)Z!qxR;9n0kbTPlK26HGQF=jHU KGlz15i~;~)f-?pH diff --git a/src/categories/categories.controller.ts b/src/categories/categories.controller.ts index 2e56113..878f76c 100644 --- a/src/categories/categories.controller.ts +++ b/src/categories/categories.controller.ts @@ -50,7 +50,7 @@ export class CategoriesController { } try { - return this.categoriesService.create(category); + return await this.categoriesService.create(category); } catch (error) { throw new InternalServerErrorException(error); diff --git a/src/categories/entities/category.entity.ts b/src/categories/entities/category.entity.ts index 6f4fd52..25ee60c 100644 --- a/src/categories/entities/category.entity.ts +++ b/src/categories/entities/category.entity.ts @@ -1 +1,10 @@ -export class Category {} +import { Column, Entity, PrimaryGeneratedColumn } from 'typeorm'; + +@Entity() +export class Category { + @PrimaryGeneratedColumn('uuid') + id: string; + + @Column() + name: string; +} diff --git a/src/sub-categories/entities/sub-category.entity.ts b/src/sub-categories/entities/sub-category.entity.ts index a83bdfe..87f85ae 100644 --- a/src/sub-categories/entities/sub-category.entity.ts +++ b/src/sub-categories/entities/sub-category.entity.ts @@ -2,7 +2,7 @@ import { Column, Entity, PrimaryGeneratedColumn } from 'typeorm'; @Entity() export class SubCategory { - @PrimaryGeneratedColumn() + @PrimaryGeneratedColumn('uuid') id: string; @Column() diff --git a/src/sub-categories/sub-categories.controller.ts b/src/sub-categories/sub-categories.controller.ts index a39b1e7..9277087 100644 --- a/src/sub-categories/sub-categories.controller.ts +++ b/src/sub-categories/sub-categories.controller.ts @@ -50,7 +50,7 @@ export class SubCategoriesController { } try { - return this.subCategoriesService.create(subCategory); + return await this.subCategoriesService.create(subCategory); } catch (error) { throw new InternalServerErrorException(error); diff --git a/src/tags/tags.controller.ts b/src/tags/tags.controller.ts index d27412e..d627f8e 100644 --- a/src/tags/tags.controller.ts +++ b/src/tags/tags.controller.ts @@ -50,7 +50,7 @@ export class TagsController { } try { - return this.tagsService.create(tag); + return await this.tagsService.create(tag); } catch (error) { throw new InternalServerErrorException(error);