started adding autojoinroles

This commit is contained in:
2024-03-04 01:18:48 +01:00
parent f11d3bc6c8
commit eb6a2dbc5c
5 changed files with 106 additions and 2 deletions

24
tool.go Normal file
View File

@@ -0,0 +1,24 @@
package main
import "encoding/json"
type ModalJsonField struct {
Label string `json:"label"`
IsParagraph bool `json:"is_paragraph"`
Value string `json:"value"`
Required bool `json:"required"`
MinLength int `json:"min_length"`
MaxLength int `json:"max_length"`
}
type ModalJson struct {
FormType string `json:"form_type"`
Title string `json:"title"`
Form []ModalJsonField `json:"form"`
}
func jsonStringShowModal(jsonString string, id string) {
var modal ModalJson
json.Unmarshal([]byte(jsonString), &modal)
}