예제 #1
0
func resetSystemUserAction(username string) {
	m := resetSystemUserJSON{username}
	jsonStr, err := json.Marshal(m)
	internal.Check(err)
	fmt.Print(internal.ReqWant("PUT", http.StatusCreated, "/user/resetsystem", jsonStr))
}
예제 #2
0
파일: check.go 프로젝트: bnjjj/tatcli
func checkUserAction(username string, fixPrivateTopics, fixDefaultGroup bool) {
	m := checkUserJSON{username, fixPrivateTopics, fixDefaultGroup}
	jsonStr, err := json.Marshal(m)
	internal.Check(err)
	fmt.Println(internal.ReqWant("PUT", http.StatusCreated, "/user/check", jsonStr))
}
예제 #3
0
func convertUserAction(username, canWriteNotifications string) {
	m := convertUserJSON{username, canWriteNotifications}
	jsonStr, err := json.Marshal(m)
	internal.Check(err)
	fmt.Print(internal.ReqWant("PUT", http.StatusCreated, "/user/convert", jsonStr))
}