local req='"method":"Chain33.ConvertExectoAddr","params":[{"execname":"'"${exector}"'"}]'
echo"#request: $req"
resp=$(curl -ksd"{$req}""${MAIN_HTTP}")
echo"#response: $resp"
# GAME_ADDR=$(echo "${res}" | jq -r ".result")
echo_rst "$FUNCNAME""$?"
}
function CreateContentStorageTx(){
local req='"method":"Chain33.CreateTransaction","params":[{"execer":"'"${EXECTOR}"'", "actionName":"ContentStorage", "payload":{"content": '"${CONENT}"'}}]'
local req='"method":"Chain33.Query","params":[{"execer":"'"${EXECTOR}"'","funcName":"QueryGameListByStatusAndAddr","payload":{"status":'"${status}"',"address":""}}]'
echo"#request: $req"
resp=$(curl -ksd"{$req}""${MAIN_HTTP}")
echo"#response: $resp"
GAMES=$(echo"${resp}" | jq -r".result.games")
echo"${GAMES}"
echo_rst "$FUNCNAME""$?"
}
function QueryGameByGameId(){
local gameId=$1
local status=$2
local req='"method":"Chain33.Query","params":[{"execer":"'"${EXECTOR}"'","funcName":"QueryGameById","payload":{"gameId":"'"${gameId}"'"}}]'