Skip to content

Commit

Permalink
Merge pull request #65 from go-park-mail-ru/revert-64-TP-easyjson
Browse files Browse the repository at this point in the history
Revert "Tp easyjson"
  • Loading branch information
qosmioo authored Dec 18, 2024
2 parents 4abf308 + cce2a17 commit 094daa0
Show file tree
Hide file tree
Showing 16 changed files with 0 additions and 1,621 deletions.
6 changes: 0 additions & 6 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@ MAIN_PATH=./cmd/app

GOTMPDIR=./tmp

EASYJSON=easyjson

build:
mkdir -p $(BIN_DIR)
GOTMPDIR=$(GOTMPDIR) go build -o $(BIN_DIR)/$(BINARY_NAME) $(MAIN_PATH)
Expand All @@ -27,8 +25,4 @@ run: build
swagger:
swag init -g $(MAIN_PATH)/main.go -o ./docs

generate:
@echo "Generating easyjson files..."
@find . -name '*.go' -exec $(EASYJSON) -all {} \;

.PHONY: build test clean run swagger
24 changes: 0 additions & 24 deletions internal/delivery/http/utils/httpJSON.go

This file was deleted.

7 changes: 0 additions & 7 deletions internal/entity/dto/advert.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
//go:generate easyjson -all .
package dto

import (
Expand All @@ -7,7 +6,6 @@ import (
"github.com/google/uuid"
)

//easyjson:json
type AdvertRequest struct {
CategoryId uuid.UUID `json:"category_id"`
Title string `json:"title"`
Expand All @@ -18,7 +16,6 @@ type AdvertRequest struct {
Location string `json:"location"`
}

//easyjson:json
type PreviewAdvert struct {
ID uuid.UUID `json:"id"`
SellerId uuid.UUID `json:"seller_id"`
Expand All @@ -32,21 +29,18 @@ type PreviewAdvert struct {
PromotedUntil time.Time `json:"promoted_until"`
}

//easyjson:json
type PreviewAdvertCard struct {
Preview PreviewAdvert `json:"preview"`
IsSaved bool `json:"is_saved"`
IsViewed bool `json:"is_viewed"`
}

//easyjson:json
type MyPreviewAdvertCard struct {
Preview PreviewAdvert `json:"preview"`
ViewsNumber uint `json:"views_number"`
SavesNumber uint `json:"saves_number"`
}

//easyjson:json
type Advert struct {
ID uuid.UUID `json:"id"`
SellerId uuid.UUID `json:"seller_id"`
Expand All @@ -65,7 +59,6 @@ type Advert struct {
PromotedUntil time.Time `json:"promoted_until"`
}

//easyjson:json
type AdvertCard struct {
Advert Advert `json:"advert"`
IsSaved bool `json:"is_saved"`
Expand Down
58 changes: 0 additions & 58 deletions internal/entity/dto/advert_easyjson.go

This file was deleted.

4 changes: 0 additions & 4 deletions internal/entity/dto/auth.go
Original file line number Diff line number Diff line change
@@ -1,19 +1,15 @@
//go:generate easyjson -all .
package dto

//easyjson:json
type Signup struct {
Email string `json:"email"`
Password string `json:"password"`
}

//easyjson:json
type Login struct {
Email string `json:"email"`
Password string `json:"password"`
}

//easyjson:json
type UpdatePassword struct {
OldPassword string `json:"old_password"`
NewPassword string `json:"new_password"`
Expand Down
Loading

0 comments on commit 094daa0

Please sign in to comment.