view_bbs_make.go 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. package route
  2. import "opennamu/route/tool"
  3. func View_bbs_make(config tool.Config) string {
  4. db := tool.DB_connect()
  5. defer tool.DB_close(db)
  6. data_html := `
  7. <form method="post">
  8. <input class="__ON_INPUT__" placeholder="` + tool.Get_language(db, "bbs_name", true) + `" name="bbs_name">
  9. <hr class="main_hr">
  10. <span class="__ON_SELECT_DIV__">
  11. <select class="__ON_SELECT__" name="bbs_type">
  12. <option value="comment">` + tool.Get_language(db, "comment_base", true) + `</option>
  13. <option value="thread">` + tool.Get_language(db, "thread_base", true) + `</option>
  14. </select>
  15. </span>
  16. <hr class="main_hr">
  17. <button class="__ON_BUTTON__" type="submit">` + tool.Get_language(db, "save", true) + `</button>
  18. </form>
  19. `
  20. return tool.Get_template(
  21. db,
  22. config,
  23. tool.Get_language(db, "bbs_make", true),
  24. data_html,
  25. []any{},
  26. [][]any{
  27. { "bbs/main", tool.Get_language(db, "return", true) },
  28. },
  29. map[string]string{},
  30. )
  31. }