Fixed project list
All checks were successful
build and deploy portfolio / build (push) Successful in 39s
build and deploy portfolio / publish-portfolio (push) Successful in 3s
build and deploy portfolio / publish-docs (push) Successful in 4s

This commit is contained in:
darius 2025-02-25 22:12:29 +01:00
parent 43c2a5b20d
commit fe2d5fda26
2 changed files with 11 additions and 16 deletions

16
main.go
View File

@ -41,20 +41,16 @@ func main() {
http.MethodPatch,
http.MethodDelete,
},
AllowedHeaders: []string{"*"},
AllowedHeaders: []string{"Authorization", "Content-Type", "*"},
AllowCredentials: true,
Debug: true,
})
//init api routes
apiMux := api.Routes()
//run api server
go func() {
err := http.ListenAndServe(":4001", c.Handler(apiMux))
if err != nil {
log.Fatal(err)
}
}()
// block main thread
select {}
err = http.ListenAndServe(":4001", c.Handler(apiMux))
if err != nil {
log.Fatal(err)
}
}

View File

@ -56,19 +56,18 @@ func EditProject(project *ent.Project) g.Node {
b.ImgSq64,
),
),
Input(Type("hidden"), Value(strconv.Itoa(project.ID)), Name("project_id")),
//b.Label("ID: "+strconv.Itoa(project.ID), Name("project_id")),
b.Textarea(strconv.Itoa(project.ID), b.Rows(1), e.Name("project_id"), e.ReadOnly(true)),
b.Label("Name"),
b.Textarea(project.Name, b.Rows(1), Name("project_name")),
b.Textarea(project.Name, b.Rows(1), e.Name("project_name")),
b.Subtitle(
6,
b.Label("Repo"),
b.Textarea(project.URL, b.Rows(1), Name("project_repo")),
b.Textarea(project.URL, b.Rows(1), e.Name("project_repo")),
b.Label("Docs"),
b.Textarea(project.DocURL, b.Rows(1), Name("project_docs"))),
b.Textarea(project.DocURL, b.Rows(1), e.Name("project_docs"))),
),
b.Content(
b.Textarea(project.Description, Name("project_description")),
b.Textarea(project.Description, e.Name("project_description")),
),
//b.CardFooter(