Skip to content

Commit

Permalink
cd
Browse files Browse the repository at this point in the history
  • Loading branch information
CodeMaster482 committed Dec 12, 2023
1 parent 830b442 commit c61404a
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 22 deletions.
28 changes: 14 additions & 14 deletions internal/microservices/category/category_models.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,23 +5,23 @@ import "github.com/google/uuid"
// input output models
type (
TagInput struct {
UserId uuid.UUID `json:"user_id"`
ParentId uuid.UUID `json:"parent_id"`
Image int `json:"image_id"`
Name string `json:"name"`
ShowIncome bool `json:"show_income"`
ShowOutcome bool `json:"show_outcome"`
Regular bool `json:"regular"`
UserId uuid.UUID `json:"user_id"`
ParentId uuid.UUID `json:"parent_id"`
// Image int `json:"image_id"`
Name string `json:"name"`
ShowIncome bool `json:"show_income"`
ShowOutcome bool `json:"show_outcome"`
Regular bool `json:"regular"`
}

TagUpdateInput struct {
UserID uuid.UUID `json:"user_id" valid:"required"`
ParentID uuid.UUID `json:"parent_id" valid:"-"`
Image int `json:"image_id"`
Name string `json:"name" valid:"required"`
ShowIncome bool `json:"show_income" valid:"-"`
ShowOutcome bool `json:"show_outcome" valid:"-"`
Regular bool `json:"regular" valid:"-"`
UserID uuid.UUID `json:"user_id" valid:"required"`
ParentID uuid.UUID `json:"parent_id" valid:"-"`
// Image int `json:"image_id"`
Name string `json:"name" valid:"required"`
ShowIncome bool `json:"show_income" valid:"-"`
ShowOutcome bool `json:"show_outcome" valid:"-"`
Regular bool `json:"regular" valid:"-"`
}

TagDeleteInput struct {
Expand Down
16 changes: 8 additions & 8 deletions internal/models/category.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,14 @@ import (
)

type Category struct {
ID uuid.UUID `json:"id" valid:"-"`
UserID uuid.UUID `json:"user_id" valid:"required"`
ParentID uuid.UUID `json:"parent_id" valid:"-"`
Image int `json:"image_id" valid:"-"`
Name string `json:"name" valid:"required"`
ShowIncome bool `json:"show_income" valid:"-"`
ShowOutcome bool `json:"show_outcome" valid:"-"`
Regular bool `json:"regular" valid:"-"`
ID uuid.UUID `json:"id" valid:"-"`
UserID uuid.UUID `json:"user_id" valid:"required"`
ParentID uuid.UUID `json:"parent_id" valid:"-"`
// Image int `json:"image_id" valid:"-"`
Name string `json:"name" valid:"required"`
ShowIncome bool `json:"show_income" valid:"-"`
ShowOutcome bool `json:"show_outcome" valid:"-"`
Regular bool `json:"regular" valid:"-"`
}

func (c *Category) CategoryValidate() error {
Expand Down

0 comments on commit c61404a

Please sign in to comment.