1 Commits

Author SHA1 Message Date
b26de27165 fix: create method 2025-03-12 16:20:10 +07:00
2 changed files with 2 additions and 2 deletions

View File

@@ -3,7 +3,7 @@
## Install ## Install
```shell ```shell
go install git.gogacoder.ru/NTO/crudgen/cmd/crudgen@v1.0.13 go install git.gogacoder.ru/NTO/crudgen/cmd/crudgen@v1.0.14
``` ```
## Run ## Run

View File

@@ -2,7 +2,7 @@ package internal
const CreateRawTemplate = `func (service *{{.ServiceName}}) Create(item {{.EntityType}}) ({{.EntityType}}, error) { const CreateRawTemplate = `func (service *{{.ServiceName}}) Create(item {{.EntityType}}) ({{.EntityType}}, error) {
utils.ReplaceEmptySlicesWithNil(&item) utils.ReplaceEmptySlicesWithNil(&item)
err := dal.Author.Create(&item) err := dal.{{.EntityType}}.Create(&item)
if err != nil { if err != nil {
return item, err return item, err
} }