rename
This commit is contained in:
parent
00ed9b7b7e
commit
cc9d489fe1
16 changed files with 33 additions and 26 deletions
|
|
@ -1 +1,3 @@
|
|||
module github.com/maddalax/mhtml/framework/tooling/astgen
|
||||
|
||||
go 1.23.0
|
||||
|
|
@ -1 +1,3 @@
|
|||
module github.com/maddalax/mhtml/framework/tooling/copyassets
|
||||
|
||||
go 1.23.0
|
||||
|
|
@ -1 +1,3 @@
|
|||
module github.com/maddalax/mhtml/framework/tooling/downloadtemplate
|
||||
|
||||
go 1.23.0
|
||||
|
|
@ -1 +1,3 @@
|
|||
module github.com/maddalax/mhtml/framework/tooling/mhtml
|
||||
|
||||
go 1.23.0
|
||||
3
setup.md
3
setup.md
|
|
@ -1,2 +1 @@
|
|||
go install github.com/maddalax/mhtml/framework/tooling/mhtml
|
||||
|
||||
go run github.com/maddalax/mhtml/framework/tooling/mhtml@latest -task template
|
||||
|
|
@ -4,7 +4,7 @@ import (
|
|||
"errors"
|
||||
"github.com/gofiber/fiber/v2"
|
||||
"github.com/google/uuid"
|
||||
"github.com/maddalax/mhtml/starter-template/database"
|
||||
"starter-template/database"
|
||||
"time"
|
||||
)
|
||||
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
module github.com/maddalax/mhtml/starter-template
|
||||
module starter-template
|
||||
|
||||
go 1.23.0
|
||||
|
||||
|
|
|
|||
|
|
@ -4,9 +4,9 @@ import (
|
|||
"github.com/gofiber/fiber/v2"
|
||||
"github.com/google/uuid"
|
||||
"github.com/maddalax/mhtml/framework/h"
|
||||
"github.com/maddalax/mhtml/starter-template/pages"
|
||||
"github.com/maddalax/mhtml/starter-template/partials/load"
|
||||
"log"
|
||||
"starter-template/pages"
|
||||
"starter-template/partials/load"
|
||||
"time"
|
||||
)
|
||||
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ package news
|
|||
import (
|
||||
"fmt"
|
||||
"github.com/maddalax/mhtml/framework/h"
|
||||
"github.com/maddalax/mhtml/starter-template/database"
|
||||
"starter-template/database"
|
||||
"time"
|
||||
)
|
||||
|
||||
|
|
|
|||
|
|
@ -2,8 +2,8 @@ package base
|
|||
|
||||
import (
|
||||
"github.com/maddalax/mhtml/framework/h"
|
||||
"github.com/maddalax/mhtml/starter-template/partials"
|
||||
"github.com/maddalax/mhtml/starter-template/partials/sheet"
|
||||
"starter-template/partials"
|
||||
"starter-template/partials/sheet"
|
||||
)
|
||||
|
||||
func RootPage(children ...h.Renderable) h.Renderable {
|
||||
|
|
|
|||
|
|
@ -3,8 +3,8 @@ package pages
|
|||
import (
|
||||
"github.com/gofiber/fiber/v2"
|
||||
"github.com/maddalax/mhtml/framework/h"
|
||||
"github.com/maddalax/mhtml/starter-template/pages/base"
|
||||
"github.com/maddalax/mhtml/starter-template/partials"
|
||||
"starter-template/pages/base"
|
||||
"starter-template/partials"
|
||||
)
|
||||
|
||||
func ListPage(ctx *fiber.Ctx) *h.Page {
|
||||
|
|
|
|||
|
|
@ -3,8 +3,8 @@ package pages
|
|||
import (
|
||||
"github.com/gofiber/fiber/v2"
|
||||
"github.com/maddalax/mhtml/framework/h"
|
||||
"github.com/maddalax/mhtml/starter-template/pages/base"
|
||||
"github.com/maddalax/mhtml/starter-template/partials/patient"
|
||||
"starter-template/pages/base"
|
||||
"starter-template/partials/patient"
|
||||
)
|
||||
|
||||
func PatientsIndex(ctx *fiber.Ctx) *h.Page {
|
||||
|
|
|
|||
|
|
@ -3,9 +3,9 @@ package load
|
|||
|
||||
import "github.com/maddalax/mhtml/framework/h"
|
||||
import "github.com/gofiber/fiber/v2"
|
||||
import "github.com/maddalax/mhtml/starter-template/partials"
|
||||
import "github.com/maddalax/mhtml/starter-template/partials/patient"
|
||||
import "github.com/maddalax/mhtml/starter-template/partials/sheet"
|
||||
import "starter-template/partials"
|
||||
import "starter-template/partials/patient"
|
||||
import "starter-template/partials/sheet"
|
||||
|
||||
func GetPartialFromContext(ctx *fiber.Ctx) *h.Partial {
|
||||
path := ctx.Path()
|
||||
|
|
@ -34,7 +34,7 @@ func GetPartialFromContext(ctx *fiber.Ctx) *h.Partial {
|
|||
}
|
||||
|
||||
func RegisterPartials(f *fiber.App) {
|
||||
f.All("github.com/maddalax/mhtml/starter-template/partials*", func(ctx *fiber.Ctx) error {
|
||||
f.All("starter-template/partials*", func(ctx *fiber.Ctx) error {
|
||||
partial := GetPartialFromContext(ctx)
|
||||
if partial == nil {
|
||||
return ctx.SendStatus(404)
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ import (
|
|||
"github.com/gofiber/fiber/v2"
|
||||
"github.com/maddalax/mhtml/framework-ui/ui"
|
||||
"github.com/maddalax/mhtml/framework/h"
|
||||
"github.com/maddalax/mhtml/starter-template/news"
|
||||
"starter-template/news"
|
||||
)
|
||||
|
||||
func NewsSheet(ctx *fiber.Ctx) *h.Partial {
|
||||
|
|
|
|||
|
|
@ -3,8 +3,8 @@ package patient
|
|||
import (
|
||||
"github.com/gofiber/fiber/v2"
|
||||
"github.com/maddalax/mhtml/framework/h"
|
||||
"github.com/maddalax/mhtml/starter-template/features/patient"
|
||||
"github.com/maddalax/mhtml/starter-template/partials/sheet"
|
||||
"starter-template/features/patient"
|
||||
"starter-template/partials/sheet"
|
||||
)
|
||||
|
||||
func Create(ctx *fiber.Ctx) *h.Partial {
|
||||
|
|
|
|||
|
|
@ -4,8 +4,8 @@ import (
|
|||
"github.com/gofiber/fiber/v2"
|
||||
"github.com/maddalax/mhtml/framework-ui/ui"
|
||||
"github.com/maddalax/mhtml/framework/h"
|
||||
"github.com/maddalax/mhtml/starter-template/features/patient"
|
||||
"github.com/maddalax/mhtml/starter-template/partials/sheet"
|
||||
"starter-template/features/patient"
|
||||
"starter-template/partials/sheet"
|
||||
"strings"
|
||||
)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue