table_router.go 2.7 KB
package routers

import (
	"github.com/beego/beego/v2/server/web"
	"gitlab.fjmaimaimai.com/allied-creation/character-library-metadata-bastion/pkg/port/beego/controllers"
)

func init() {
	web.Router("/data/tables/", &controllers.TableController{}, "Post:CreateTable")
	//web.Router("/data/tables/:tableId", &controllers.TableController{}, "Put:UpdateTable")
	web.Router("/data/tables/:tableId", &controllers.TableController{}, "Get:GetTable")
	web.Router("/data/tables/prepare", &controllers.TableController{}, "Get:PrepareTable")
	web.Router("/data/tables/:tableId", &controllers.TableController{}, "Delete:RemoveTable")
	web.Router("/data/tables/", &controllers.TableController{}, "Get:ListTable")
	web.Router("/data/tables/search", &controllers.TableController{}, "Post:Search")
	web.Router("/data/tables/relation-graph", &controllers.TableController{}, "Post:RelationGraph")
	web.Router("/data/tables/apply-on", &controllers.TableController{}, "Post:ApplyOn")
	web.Router("/data/tables/valid-expr-sql", &controllers.TableController{}, "Post:ValidExprSql")
	web.Router("/data/tables/check", &controllers.TableController{}, "Post:CheckRowDuplicate")
	web.Router("/data/tables/check-row-value-duplicate", &controllers.TableController{}, "Post:CheckRowValueDuplicate")
	web.Router("/data/tables/search-appended-list", &controllers.TableController{}, "Post:SearchAppendedList")
	web.Router("/data/tables/search-sub-table-list", &controllers.TableController{}, "Post:SearchSubTableList")
	web.Router("/data/tables/search-query-set-tables", &controllers.TableController{}, "Post:SearchQuerySetTables")

	//web.Router("/data/tables/split-data-table", &controllers.TableController{}, "Post:SplitDataTable")
	//web.Router("/data/tables/batch-edit-sub-table", &controllers.TableController{}, "Post:BatchEditSubTable")
	web.Router("/data/tables/copy-data-table", &controllers.TableController{}, "Post:CopyDataTable")
	web.Router("/data/tables/update-table-struct/:tableId", &controllers.TableController{}, "Put:UpdateTableStruct")
	web.Router("/data/tables/add-sub-table", &controllers.TableController{}, "Post:AddTableStruct")
	web.Router("/data/tables/export-table", &controllers.TableController{}, "Post:ExportDataTable")

	web.Router("/data/tables/table-preview", &controllers.TableController{}, "Post:TablePreview")
	web.Router("/data/tables/row-edit", &controllers.TableController{}, "Post:RowEdit")

	web.Router("/data/field-optional-values", &controllers.TableController{}, "Post:FieldOptionalValues")
	web.Router("/data/table-object-search", &controllers.TableController{}, "Post:TableObjectSearch")

	web.Router("/business/db-table-preview", &controllers.TableController{}, "Post:DBTablePreview")
	web.Router("/data/table-preview", &controllers.TableController{}, "Post:Preview")

}