Merge branch 'dev' of http://git.legu.cc/liwei_3d/go_dreamfactory into dev
This commit is contained in:
commit
1785037abb
@ -3352,55 +3352,79 @@
|
||||
"text_cn": "基础效果抵抗"
|
||||
},
|
||||
{
|
||||
"key": "hero_star_1",
|
||||
"key": "star_2",
|
||||
"text_cn": "优秀"
|
||||
},
|
||||
{
|
||||
"key": "hero_star_2",
|
||||
"key": "star_3",
|
||||
"text_cn": "稀有"
|
||||
},
|
||||
{
|
||||
"key": "hero_star_3",
|
||||
"key": "star_4",
|
||||
"text_cn": "史诗"
|
||||
},
|
||||
{
|
||||
"key": "hero_star_4",
|
||||
"key": "star_5",
|
||||
"text_cn": "传说"
|
||||
},
|
||||
{
|
||||
"key": "hero_color_1",
|
||||
"key": "color_1",
|
||||
"text_cn": "优秀"
|
||||
},
|
||||
{
|
||||
"key": "hero_color_2",
|
||||
"key": "color_2",
|
||||
"text_cn": "稀有"
|
||||
},
|
||||
{
|
||||
"key": "hero_color_3",
|
||||
"key": "color_3",
|
||||
"text_cn": "史诗"
|
||||
},
|
||||
{
|
||||
"key": "hero_color_4",
|
||||
"key": "color_4",
|
||||
"text_cn": "传说"
|
||||
},
|
||||
{
|
||||
"key": "hero_job_10017",
|
||||
"key": "color_5",
|
||||
"text_cn": "不朽"
|
||||
},
|
||||
{
|
||||
"key": "color_6",
|
||||
"text_cn": "超凡"
|
||||
},
|
||||
{
|
||||
"key": "race_1",
|
||||
"text_cn": "灼热"
|
||||
},
|
||||
{
|
||||
"key": "race_2",
|
||||
"text_cn": "涌动"
|
||||
},
|
||||
{
|
||||
"key": "race_3",
|
||||
"text_cn": "呼啸"
|
||||
},
|
||||
{
|
||||
"key": "race_4",
|
||||
"text_cn": "闪耀"
|
||||
},
|
||||
{
|
||||
"key": "job_1",
|
||||
"text_cn": "输出"
|
||||
},
|
||||
{
|
||||
"key": "hero_job_10018",
|
||||
"key": "job_2",
|
||||
"text_cn": "防御"
|
||||
},
|
||||
{
|
||||
"key": "hero_job_10019",
|
||||
"key": "job_3",
|
||||
"text_cn": "辅助"
|
||||
},
|
||||
{
|
||||
"key": "hero_job_10020",
|
||||
"key": "job_4",
|
||||
"text_cn": "控制"
|
||||
},
|
||||
{
|
||||
"key": "hero_job_10021",
|
||||
"key": "job_5",
|
||||
"text_cn": "材料"
|
||||
},
|
||||
{
|
||||
@ -3536,8 +3560,20 @@
|
||||
"text_cn": "本地测试服"
|
||||
},
|
||||
{
|
||||
"key": "server_10002",
|
||||
"text_cn": "外网测试服"
|
||||
"key": "server_10006",
|
||||
"text_cn": "乌鸦岭"
|
||||
},
|
||||
{
|
||||
"key": "server_10003",
|
||||
"text_cn": "和平谷"
|
||||
},
|
||||
{
|
||||
"key": "server_10004",
|
||||
"text_cn": "凤凰城"
|
||||
},
|
||||
{
|
||||
"key": "server_10005",
|
||||
"text_cn": "翡翠宫"
|
||||
},
|
||||
{
|
||||
"key": "skillname_190011000",
|
||||
@ -3579,6 +3615,14 @@
|
||||
"key": "tips_1002",
|
||||
"text_cn": "暂未开放"
|
||||
},
|
||||
{
|
||||
"key": "tips_1003",
|
||||
"text_cn": "当前星球容量超载,请更换星球开启冒险"
|
||||
},
|
||||
{
|
||||
"key": "tips_1004",
|
||||
"text_cn": "当前世界正在建设中,请稍后进入"
|
||||
},
|
||||
{
|
||||
"key": "nonactivated",
|
||||
"text_cn": "未激活"
|
||||
@ -3587,26 +3631,6 @@
|
||||
"key": "activated",
|
||||
"text_cn": "已激活"
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10001",
|
||||
"text_cn": "探险"
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10002",
|
||||
"text_cn": "英雄"
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10003",
|
||||
"text_cn": "商店"
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10004",
|
||||
"text_cn": "好友"
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10005",
|
||||
"text_cn": "任务"
|
||||
},
|
||||
{
|
||||
"key": "opencond_prompt_10001",
|
||||
"text_cn": "通关2-26开启"
|
||||
@ -3621,7 +3645,7 @@
|
||||
},
|
||||
{
|
||||
"key": "num_1001",
|
||||
"text_cn": "迷雾岛屿"
|
||||
"text_cn": "美食馆"
|
||||
},
|
||||
{
|
||||
"key": "num_1002",
|
||||
@ -3633,7 +3657,7 @@
|
||||
},
|
||||
{
|
||||
"key": "num_1004",
|
||||
"text_cn": "地下角斗场"
|
||||
"text_cn": "黑暗料理大赛"
|
||||
},
|
||||
{
|
||||
"key": "num_1005",
|
||||
@ -3645,7 +3669,7 @@
|
||||
},
|
||||
{
|
||||
"key": "num_1007",
|
||||
"text_cn": "维京远征"
|
||||
"text_cn": "篝火舞会"
|
||||
},
|
||||
{
|
||||
"key": "num_1008",
|
||||
@ -3657,7 +3681,7 @@
|
||||
},
|
||||
{
|
||||
"key": "num_1010",
|
||||
"text_cn": "黑暗料理大赛"
|
||||
"text_cn": "地下角斗场"
|
||||
},
|
||||
{
|
||||
"key": "num_1011",
|
||||
@ -3665,11 +3689,11 @@
|
||||
},
|
||||
{
|
||||
"key": "num_1012",
|
||||
"text_cn": "疯狂竞技赛"
|
||||
"text_cn": "五侠擂台"
|
||||
},
|
||||
{
|
||||
"key": "num_1013",
|
||||
"text_cn": "五侠擂台"
|
||||
"text_cn": "疯狂竞技赛"
|
||||
},
|
||||
{
|
||||
"key": "num_1014",
|
||||
@ -3677,7 +3701,7 @@
|
||||
},
|
||||
{
|
||||
"key": "num_1015",
|
||||
"text_cn": "篝火舞会"
|
||||
"text_cn": "维京远征"
|
||||
},
|
||||
{
|
||||
"key": "num_1016",
|
||||
@ -3692,15 +3716,71 @@
|
||||
"text_cn": "戈伯铁匠铺"
|
||||
},
|
||||
{
|
||||
"key": "num_1019",
|
||||
"key": "opencond_name_10001",
|
||||
"text_cn": "背包"
|
||||
},
|
||||
{
|
||||
"key": "num_1020",
|
||||
"key": "opencond_name_10002",
|
||||
"text_cn": "购物"
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10003",
|
||||
"text_cn": "联盟"
|
||||
},
|
||||
{
|
||||
"key": "num_1021",
|
||||
"key": "opencond_name_10004",
|
||||
"text_cn": "邮件"
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10005",
|
||||
"text_cn": "好友"
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10006",
|
||||
"text_cn": "卡牌"
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10007",
|
||||
"text_cn": "寝室"
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10008",
|
||||
"text_cn": "商城"
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10009",
|
||||
"text_cn": "活动"
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10010",
|
||||
"text_cn": "任务"
|
||||
},
|
||||
{
|
||||
"key": "hero_help_10001",
|
||||
"text_cn": "养成说明"
|
||||
},
|
||||
{
|
||||
"key": "hero_help_10002",
|
||||
"text_cn": "英雄升级"
|
||||
},
|
||||
{
|
||||
"key": "hero_help_10003",
|
||||
"text_cn": "英雄可通过出战或吸收经验精灵提升等级"
|
||||
},
|
||||
{
|
||||
"key": "hero_help_10004",
|
||||
"text_cn": "英雄升星"
|
||||
},
|
||||
{
|
||||
"key": "hero_help_10005",
|
||||
"text_cn": "不同星级的英雄有不同的等级上限,3星为30级,4星为40级,5星为50级,6星为60级。\u003Cbr/\u003E英雄达到等级上限后,需要通过升星进一步提升等级。\u003Cbr/\u003E升星后英雄的属性将得到提升。\u003Cbr/\u003E升星精灵是英雄升星的优质素材"
|
||||
},
|
||||
{
|
||||
"key": "hero_help_10006",
|
||||
"text_cn": "技能升级"
|
||||
},
|
||||
{
|
||||
"key": "hero_help_10007",
|
||||
"text_cn": "使用稀有/史诗/传说品质的技能精灵可以提升对应品质英雄的技能等级,技能升级时将随机选择还可以继续升级的技能。\u003Cbr/\u003E如果英雄的所有技能等级满级,将不能再使用技能精灵提升等级"
|
||||
}
|
||||
]
|
@ -289,7 +289,7 @@
|
||||
},
|
||||
{
|
||||
"key": "hero_35001",
|
||||
"text_en": "master"
|
||||
"text_en": "Master Shifu"
|
||||
},
|
||||
{
|
||||
"key": "hero_35002",
|
||||
@ -357,11 +357,11 @@
|
||||
},
|
||||
{
|
||||
"key": "hero_44005",
|
||||
"text_en": "Xiaoyi"
|
||||
"text_en": "EEP"
|
||||
},
|
||||
{
|
||||
"key": "hero_44006",
|
||||
"text_en": "Tiger Tiger"
|
||||
"text_en": "Tigress"
|
||||
},
|
||||
{
|
||||
"key": "hero_45001",
|
||||
@ -3352,55 +3352,79 @@
|
||||
"text_en": "base effect resistance"
|
||||
},
|
||||
{
|
||||
"key": "hero_star_1",
|
||||
"key": "star_2",
|
||||
"text_en": "Excellent"
|
||||
},
|
||||
{
|
||||
"key": "hero_star_2",
|
||||
"key": "star_3",
|
||||
"text_en": "Rare"
|
||||
},
|
||||
{
|
||||
"key": "hero_star_3",
|
||||
"key": "star_4",
|
||||
"text_en": "Epic"
|
||||
},
|
||||
{
|
||||
"key": "hero_star_4",
|
||||
"key": "star_5",
|
||||
"text_en": "Legend"
|
||||
},
|
||||
{
|
||||
"key": "hero_color_1",
|
||||
"key": "color_1",
|
||||
"text_en": "Excellent"
|
||||
},
|
||||
{
|
||||
"key": "hero_color_2",
|
||||
"key": "color_2",
|
||||
"text_en": "Rare"
|
||||
},
|
||||
{
|
||||
"key": "hero_color_3",
|
||||
"key": "color_3",
|
||||
"text_en": "Epic"
|
||||
},
|
||||
{
|
||||
"key": "hero_color_4",
|
||||
"key": "color_4",
|
||||
"text_en": "Legend"
|
||||
},
|
||||
{
|
||||
"key": "hero_job_10017",
|
||||
"key": "color_5",
|
||||
"text_en": "Eternity"
|
||||
},
|
||||
{
|
||||
"key": "color_6",
|
||||
"text_en": "Uncommon"
|
||||
},
|
||||
{
|
||||
"key": "race_1",
|
||||
"text_en": "Hot"
|
||||
},
|
||||
{
|
||||
"key": "race_2",
|
||||
"text_en": "Surge"
|
||||
},
|
||||
{
|
||||
"key": "race_3",
|
||||
"text_en": "Whistling"
|
||||
},
|
||||
{
|
||||
"key": "race_4",
|
||||
"text_en": "Shine"
|
||||
},
|
||||
{
|
||||
"key": "job_1",
|
||||
"text_en": "Output"
|
||||
},
|
||||
{
|
||||
"key": "hero_job_10018",
|
||||
"key": "job_2",
|
||||
"text_en": "Defense"
|
||||
},
|
||||
{
|
||||
"key": "hero_job_10019",
|
||||
"key": "job_3",
|
||||
"text_en": "Auxiliary"
|
||||
},
|
||||
{
|
||||
"key": "hero_job_10020",
|
||||
"key": "job_4",
|
||||
"text_en": "Control"
|
||||
},
|
||||
{
|
||||
"key": "hero_job_10021",
|
||||
"key": "job_5",
|
||||
"text_en": "Material"
|
||||
},
|
||||
{
|
||||
@ -3536,8 +3560,20 @@
|
||||
"text_en": "Local test server"
|
||||
},
|
||||
{
|
||||
"key": "server_10002",
|
||||
"text_en": "Extranet test server"
|
||||
"key": "server_10006",
|
||||
"text_en": "Raven Point"
|
||||
},
|
||||
{
|
||||
"key": "server_10003",
|
||||
"text_en": "The Valley of Peace"
|
||||
},
|
||||
{
|
||||
"key": "server_10004",
|
||||
"text_en": "Gongmen"
|
||||
},
|
||||
{
|
||||
"key": "server_10005",
|
||||
"text_en": "Jade Palace"
|
||||
},
|
||||
{
|
||||
"key": "skillname_190011000",
|
||||
@ -3577,7 +3613,15 @@
|
||||
},
|
||||
{
|
||||
"key": "tips_1002",
|
||||
"text_en": "Not yet open"
|
||||
"text_en": "Not open yet"
|
||||
},
|
||||
{
|
||||
"key": "tips_1003",
|
||||
"text_en": "The current planet capacity is overloaded, please change the planet and start the adventure"
|
||||
},
|
||||
{
|
||||
"key": "tips_1004",
|
||||
"text_en": "At present, the world is under construction. Please enter later"
|
||||
},
|
||||
{
|
||||
"key": "nonactivated",
|
||||
@ -3587,26 +3631,6 @@
|
||||
"key": "activated",
|
||||
"text_en": "Activated"
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10001",
|
||||
"text_en": ""
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10002",
|
||||
"text_en": "CARD"
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10003",
|
||||
"text_en": "SHOPS"
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10004",
|
||||
"text_en": "FRIENDS"
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10005",
|
||||
"text_en": ""
|
||||
},
|
||||
{
|
||||
"key": "opencond_prompt_10001",
|
||||
"text_en": ""
|
||||
@ -3621,11 +3645,11 @@
|
||||
},
|
||||
{
|
||||
"key": "num_1001",
|
||||
"text_en": "Misty Island"
|
||||
"text_en": "GOURMET RESTAURANT"
|
||||
},
|
||||
{
|
||||
"key": "num_1002",
|
||||
"text_en": "MOON"
|
||||
"text_en": "SUMMON"
|
||||
},
|
||||
{
|
||||
"key": "num_1003",
|
||||
@ -3633,19 +3657,19 @@
|
||||
},
|
||||
{
|
||||
"key": "num_1004",
|
||||
"text_en": "Underground Arena"
|
||||
"text_en": "Dark Cuisine"
|
||||
},
|
||||
{
|
||||
"key": "num_1005",
|
||||
"text_en": "Caravan"
|
||||
"text_en": "CARAVAN"
|
||||
},
|
||||
{
|
||||
"key": "num_1006",
|
||||
"text_en": "Library"
|
||||
"text_en": "LIBRARY"
|
||||
},
|
||||
{
|
||||
"key": "num_1007",
|
||||
"text_en": "EXPEDITION"
|
||||
"text_en": "BONEFIRE DANCE"
|
||||
},
|
||||
{
|
||||
"key": "num_1008",
|
||||
@ -3653,11 +3677,11 @@
|
||||
},
|
||||
{
|
||||
"key": "num_1009",
|
||||
"text_en": "BATTLE!"
|
||||
"text_en": "Catch It!"
|
||||
},
|
||||
{
|
||||
"key": "num_1010",
|
||||
"text_en": "DARK CUISINE"
|
||||
"text_en": "ARENA"
|
||||
},
|
||||
{
|
||||
"key": "num_1011",
|
||||
@ -3665,42 +3689,98 @@
|
||||
},
|
||||
{
|
||||
"key": "num_1012",
|
||||
"text_en": "CRAZED"
|
||||
},
|
||||
{
|
||||
"key": "num_1013",
|
||||
"text_en": "TRAIN"
|
||||
},
|
||||
{
|
||||
"key": "num_1013",
|
||||
"text_en": "CRAZY"
|
||||
},
|
||||
{
|
||||
"key": "num_1014",
|
||||
"text_en": "TRIALS"
|
||||
"text_en": "ADVENTURE"
|
||||
},
|
||||
{
|
||||
"key": "num_1015",
|
||||
"text_en": "Bonfire Dance"
|
||||
"text_en": "EXPEDITION"
|
||||
},
|
||||
{
|
||||
"key": "num_1016",
|
||||
"text_en": "MIRROR"
|
||||
"text_en": "FESTIVAL"
|
||||
},
|
||||
{
|
||||
"key": "num_1017",
|
||||
"text_en": "Gourmet restaurant"
|
||||
"text_en": "GOURMET RESTAURANT"
|
||||
},
|
||||
{
|
||||
"key": "num_1018",
|
||||
"text_en": "Gober blacksmith shop"
|
||||
"text_en": "GOBER BACKSMITH SHOP"
|
||||
},
|
||||
{
|
||||
"key": "num_1019",
|
||||
"key": "opencond_name_10001",
|
||||
"text_en": "INVENTORY"
|
||||
},
|
||||
{
|
||||
"key": "num_1020",
|
||||
"key": "opencond_name_10002",
|
||||
"text_en": "SHOP"
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10003",
|
||||
"text_en": "UNION"
|
||||
},
|
||||
{
|
||||
"key": "num_1021",
|
||||
"key": "opencond_name_10004",
|
||||
"text_en": "MAIL"
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10005",
|
||||
"text_en": "SOCIAL"
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10006",
|
||||
"text_en": "CARDS"
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10007",
|
||||
"text_en": "DORM"
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10008",
|
||||
"text_en": "CHARGE"
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10009",
|
||||
"text_en": "EVENT"
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10010",
|
||||
"text_en": "MISSIONS"
|
||||
},
|
||||
{
|
||||
"key": "hero_help_10001",
|
||||
"text_en": "养成说明"
|
||||
},
|
||||
{
|
||||
"key": "hero_help_10002",
|
||||
"text_en": "英雄升级"
|
||||
},
|
||||
{
|
||||
"key": "hero_help_10003",
|
||||
"text_en": "英雄可通过出战或吸收经验精灵提升等级"
|
||||
},
|
||||
{
|
||||
"key": "hero_help_10004",
|
||||
"text_en": "英雄升星"
|
||||
},
|
||||
{
|
||||
"key": "hero_help_10005",
|
||||
"text_en": "不同星级的英雄有不同的等级上限,3星为30级,4星为40级,5星为50级,6星为60级。\u003Cbr/\u003E英雄达到等级上限后,需要通过升星进一步提升等级。\u003Cbr/\u003E升星后英雄的属性将得到提升。\u003Cbr/\u003E升星精灵是英雄升星的优质素材"
|
||||
},
|
||||
{
|
||||
"key": "hero_help_10006",
|
||||
"text_en": "技能升级"
|
||||
},
|
||||
{
|
||||
"key": "hero_help_10007",
|
||||
"text_en": "使用稀有/史诗/传说品质的技能精灵可以提升对应品质英雄的技能等级,技能升级时将随机选择还可以继续升级的技能。\u003Cbr/\u003E如果英雄的所有技能等级满级,将不能再使用技能精灵提升等级"
|
||||
}
|
||||
]
|
@ -3352,55 +3352,79 @@
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "hero_star_1",
|
||||
"key": "star_2",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "hero_star_2",
|
||||
"key": "star_3",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "hero_star_3",
|
||||
"key": "star_4",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "hero_star_4",
|
||||
"key": "star_5",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "hero_color_1",
|
||||
"key": "color_1",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "hero_color_2",
|
||||
"key": "color_2",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "hero_color_3",
|
||||
"key": "color_3",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "hero_color_4",
|
||||
"key": "color_4",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "hero_job_10017",
|
||||
"key": "color_5",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "hero_job_10018",
|
||||
"key": "color_6",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "hero_job_10019",
|
||||
"key": "race_1",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "hero_job_10020",
|
||||
"key": "race_2",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "hero_job_10021",
|
||||
"key": "race_3",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "race_4",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "job_1",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "job_2",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "job_3",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "job_4",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "job_5",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
@ -3536,7 +3560,19 @@
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "server_10002",
|
||||
"key": "server_10006",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "server_10003",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "server_10004",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "server_10005",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
@ -3579,6 +3615,14 @@
|
||||
"key": "tips_1002",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "tips_1003",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "tips_1004",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "nonactivated",
|
||||
"text_tw": ""
|
||||
@ -3587,26 +3631,6 @@
|
||||
"key": "activated",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10001",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10002",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10003",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10004",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10005",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "opencond_prompt_10001",
|
||||
"text_tw": ""
|
||||
@ -3692,15 +3716,71 @@
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "num_1019",
|
||||
"key": "opencond_name_10001",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "num_1020",
|
||||
"key": "opencond_name_10002",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "num_1021",
|
||||
"key": "opencond_name_10003",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10004",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10005",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10006",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10007",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10008",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10009",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "opencond_name_10010",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "hero_help_10001",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "hero_help_10002",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "hero_help_10003",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "hero_help_10004",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "hero_help_10005",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "hero_help_10006",
|
||||
"text_tw": ""
|
||||
},
|
||||
{
|
||||
"key": "hero_help_10007",
|
||||
"text_tw": ""
|
||||
}
|
||||
]
|
@ -34,5 +34,17 @@
|
||||
"img": "wp_icon_0002",
|
||||
"ico": "wp_icon_0002",
|
||||
"intr": "主角经验"
|
||||
},
|
||||
{
|
||||
"key": "friend",
|
||||
"name": "友情点",
|
||||
"color": 1,
|
||||
"effects": "",
|
||||
"access": 0,
|
||||
"star": 2,
|
||||
"race": 0,
|
||||
"img": "",
|
||||
"ico": "",
|
||||
"intr": "友情点用于友情商店"
|
||||
}
|
||||
]
|
@ -1,29 +1,14 @@
|
||||
[
|
||||
{
|
||||
"index": "max_hy",
|
||||
"var": "30",
|
||||
"intr": "最大好友数"
|
||||
},
|
||||
{
|
||||
"index": "max_getreward",
|
||||
"var": "10002,99",
|
||||
"intr": "领取/赠送奖励"
|
||||
},
|
||||
{
|
||||
"index": "max_get",
|
||||
"var": "30",
|
||||
"intr": "每日领取/赠送次数"
|
||||
},
|
||||
{
|
||||
"index": "max_char",
|
||||
"var": "100",
|
||||
"intr": "聊天最大输入字符数量"
|
||||
},
|
||||
{
|
||||
"index": "max_hmd",
|
||||
"var": "30",
|
||||
"intr": "最大黑名单数"
|
||||
},
|
||||
{
|
||||
"index": "task_reset",
|
||||
"var": "8",
|
||||
@ -58,5 +43,40 @@
|
||||
"index": "equipsuitsum",
|
||||
"var": "4,4,4,4,2,2",
|
||||
"intr": "装备位置对应数量"
|
||||
},
|
||||
{
|
||||
"index": "friend_maxnum",
|
||||
"var": "50",
|
||||
"intr": "最大好友数量"
|
||||
},
|
||||
{
|
||||
"index": "friend_minnum",
|
||||
"var": "0",
|
||||
"intr": "最少好友数量"
|
||||
},
|
||||
{
|
||||
"index": "friend_maxgetnum",
|
||||
"var": "20",
|
||||
"intr": "每日最大获赠的友情点数量"
|
||||
},
|
||||
{
|
||||
"index": "friend_maxsendnum",
|
||||
"var": "50",
|
||||
"intr": "每日最大可送出的友情点数量"
|
||||
},
|
||||
{
|
||||
"index": "friend_date",
|
||||
"var": "7",
|
||||
"intr": "申请记录保留时间/天"
|
||||
},
|
||||
{
|
||||
"index": "friend_recordtime",
|
||||
"var": "7",
|
||||
"intr": "助战记录保留时间/天"
|
||||
},
|
||||
{
|
||||
"index": "friend_black",
|
||||
"var": "50",
|
||||
"intr": "最大黑名单数"
|
||||
}
|
||||
]
|
@ -18,5 +18,15 @@
|
||||
"n": 20
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"index": "friend_peize",
|
||||
"var": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "friend",
|
||||
"n": 100
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
@ -9,8 +9,8 @@
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"key": "server_10002",
|
||||
"text": "外网测试服"
|
||||
"key": "server_10003",
|
||||
"text": "和平谷"
|
||||
},
|
||||
"ips": "119.3.89.14:7891",
|
||||
"debug": false
|
||||
@ -30,5 +30,29 @@
|
||||
},
|
||||
"ips": "10.0.0.85:7891",
|
||||
"debug": true
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"key": "server_10004",
|
||||
"text": "凤凰城"
|
||||
},
|
||||
"ips": "119.3.89.14:7891",
|
||||
"debug": false
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"key": "server_10005",
|
||||
"text": "翡翠宫"
|
||||
},
|
||||
"ips": "119.3.89.14:7891",
|
||||
"debug": false
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"key": "server_10006",
|
||||
"text": "乌鸦岭"
|
||||
},
|
||||
"ips": "119.3.89.14:7891",
|
||||
"debug": false
|
||||
}
|
||||
]
|
@ -1,29 +1,14 @@
|
||||
[
|
||||
{
|
||||
"index": "max_hy",
|
||||
"var": "30",
|
||||
"intr": "最大好友数"
|
||||
},
|
||||
{
|
||||
"index": "max_getreward",
|
||||
"var": "10002,99",
|
||||
"intr": "领取/赠送奖励"
|
||||
},
|
||||
{
|
||||
"index": "max_get",
|
||||
"var": "30",
|
||||
"intr": "每日领取/赠送次数"
|
||||
},
|
||||
{
|
||||
"index": "max_char",
|
||||
"var": "100",
|
||||
"intr": "聊天最大输入字符数量"
|
||||
},
|
||||
{
|
||||
"index": "max_hmd",
|
||||
"var": "30",
|
||||
"intr": "最大黑名单数"
|
||||
},
|
||||
{
|
||||
"index": "task_reset",
|
||||
"var": "8",
|
||||
@ -58,5 +43,40 @@
|
||||
"index": "equipsuitsum",
|
||||
"var": "4,4,4,4,2,2",
|
||||
"intr": "装备位置对应数量"
|
||||
},
|
||||
{
|
||||
"index": "friend_maxnum",
|
||||
"var": "50",
|
||||
"intr": "最大好友数量"
|
||||
},
|
||||
{
|
||||
"index": "friend_minnum",
|
||||
"var": "0",
|
||||
"intr": "最少好友数量"
|
||||
},
|
||||
{
|
||||
"index": "friend_maxgetnum",
|
||||
"var": "20",
|
||||
"intr": "每日最大获赠的友情点数量"
|
||||
},
|
||||
{
|
||||
"index": "friend_maxsendnum",
|
||||
"var": "50",
|
||||
"intr": "每日最大可送出的友情点数量"
|
||||
},
|
||||
{
|
||||
"index": "friend_date",
|
||||
"var": "7",
|
||||
"intr": "申请记录保留时间/天"
|
||||
},
|
||||
{
|
||||
"index": "friend_recordtime",
|
||||
"var": "7",
|
||||
"intr": "助战记录保留时间/天"
|
||||
},
|
||||
{
|
||||
"index": "friend_black",
|
||||
"var": "50",
|
||||
"intr": "最大黑名单数"
|
||||
}
|
||||
]
|
File diff suppressed because it is too large
Load Diff
@ -145,80 +145,116 @@
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "hero_star_1",
|
||||
"text": "hero_star_1"
|
||||
"key": "star_2",
|
||||
"text": "star_2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "hero_star_2",
|
||||
"text": "hero_star_2"
|
||||
"key": "star_3",
|
||||
"text": "star_3"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "hero_star_3",
|
||||
"text": "hero_star_3"
|
||||
"key": "star_4",
|
||||
"text": "star_4"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "hero_star_4",
|
||||
"text": "hero_star_4"
|
||||
"key": "star_5",
|
||||
"text": "star_5"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "hero_color_1",
|
||||
"text": "hero_color_1"
|
||||
"key": "color_1",
|
||||
"text": "color_1"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "hero_color_2",
|
||||
"text": "hero_color_2"
|
||||
"key": "color_2",
|
||||
"text": "color_2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "hero_color_3",
|
||||
"text": "hero_color_3"
|
||||
"key": "color_3",
|
||||
"text": "color_3"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "hero_color_4",
|
||||
"text": "hero_color_4"
|
||||
"key": "color_4",
|
||||
"text": "color_4"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "hero_job_10017",
|
||||
"text": "hero_job_10017"
|
||||
"key": "color_5",
|
||||
"text": "color_5"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "hero_job_10018",
|
||||
"text": "hero_job_10018"
|
||||
"key": "color_6",
|
||||
"text": "color_6"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "hero_job_10019",
|
||||
"text": "hero_job_10019"
|
||||
"key": "race_1",
|
||||
"text": "race_1"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "hero_job_10020",
|
||||
"text": "hero_job_10020"
|
||||
"key": "race_2",
|
||||
"text": "race_2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "hero_job_10021",
|
||||
"text": "hero_job_10021"
|
||||
"key": "race_3",
|
||||
"text": "race_3"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "race_4",
|
||||
"text": "race_4"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "job_1",
|
||||
"text": "job_1"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "job_2",
|
||||
"text": "job_2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "job_3",
|
||||
"text": "job_3"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "job_4",
|
||||
"text": "job_4"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "job_5",
|
||||
"text": "job_5"
|
||||
}
|
||||
},
|
||||
{
|
||||
@ -323,6 +359,18 @@
|
||||
"text": "tips_1002"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "tips_1003",
|
||||
"text": "tips_1003"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "tips_1004",
|
||||
"text": "tips_1004"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "num_1001",
|
||||
@ -431,6 +479,66 @@
|
||||
"text": "num_1018"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "opencond_name_10001",
|
||||
"text": "opencond_name_10001"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "opencond_name_10002",
|
||||
"text": "opencond_name_10002"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "opencond_name_10003",
|
||||
"text": "opencond_name_10003"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "opencond_name_10004",
|
||||
"text": "opencond_name_10004"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "opencond_name_10005",
|
||||
"text": "opencond_name_10005"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "opencond_name_10006",
|
||||
"text": "opencond_name_10006"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "opencond_name_10007",
|
||||
"text": "opencond_name_10007"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "opencond_name_10008",
|
||||
"text": "opencond_name_10008"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "opencond_name_10009",
|
||||
"text": "opencond_name_10009"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "opencond_name_10010",
|
||||
"text": "opencond_name_10010"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "skill_190011000",
|
||||
@ -502,5 +610,47 @@
|
||||
"key": "skill_190011004",
|
||||
"text": "skill_190011004"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "hero_help_10001",
|
||||
"text": "hero_help_10001"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "hero_help_10002",
|
||||
"text": "hero_help_10002"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "hero_help_10003",
|
||||
"text": "hero_help_10003"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "hero_help_10004",
|
||||
"text": "hero_help_10004"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "hero_help_10005",
|
||||
"text": "hero_help_10005"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "hero_help_10006",
|
||||
"text": "hero_help_10006"
|
||||
}
|
||||
},
|
||||
{
|
||||
"keycode": {
|
||||
"key": "hero_help_10007",
|
||||
"text": "hero_help_10007"
|
||||
}
|
||||
}
|
||||
]
|
File diff suppressed because it is too large
Load Diff
@ -37,14 +37,14 @@
|
||||
"key": "opencond_name_10003",
|
||||
"text": "商店"
|
||||
},
|
||||
"main": "{\u0022lv\u0022: 0}",
|
||||
"main": "{\u0022lv\u0022: 999}",
|
||||
"optional": "",
|
||||
"wkqbx": 0,
|
||||
"kqbx": 0,
|
||||
"img": "",
|
||||
"prompt": {
|
||||
"key": "",
|
||||
"text": ""
|
||||
"key": "opencond_prompt_10002",
|
||||
"text": "暂不开启,敬请期待"
|
||||
}
|
||||
},
|
||||
{
|
||||
@ -85,7 +85,7 @@
|
||||
"key": "opencond_name_10005",
|
||||
"text": "任务"
|
||||
},
|
||||
"main": "{\u0022lv\u0022: 0}",
|
||||
"main": "{\u0022lv\u0022: 999}",
|
||||
"optional": "",
|
||||
"wkqbx": 0,
|
||||
"kqbx": 0,
|
||||
|
2498
bin/json/game_pagoda.json
Normal file
2498
bin/json/game_pagoda.json
Normal file
File diff suppressed because it is too large
Load Diff
146
bin/json/game_pagodaseasonreward.json
Normal file
146
bin/json/game_pagodaseasonreward.json
Normal file
@ -0,0 +1,146 @@
|
||||
[
|
||||
{
|
||||
"key": 1,
|
||||
"ranking": [
|
||||
1,
|
||||
1
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 10
|
||||
},
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "gold",
|
||||
"n": 1000
|
||||
},
|
||||
{
|
||||
"a": "item",
|
||||
"t": "10002",
|
||||
"n": 1
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 2,
|
||||
"ranking": [
|
||||
2,
|
||||
2
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 10
|
||||
},
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "gold",
|
||||
"n": 1050
|
||||
},
|
||||
{
|
||||
"a": "item",
|
||||
"t": "10002",
|
||||
"n": 1
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 3,
|
||||
"ranking": [
|
||||
3,
|
||||
3
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 10
|
||||
},
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "gold",
|
||||
"n": 1100
|
||||
},
|
||||
{
|
||||
"a": "item",
|
||||
"t": "10002",
|
||||
"n": 1
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 4,
|
||||
"ranking": [
|
||||
4,
|
||||
10
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 10
|
||||
},
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "gold",
|
||||
"n": 1150
|
||||
},
|
||||
{
|
||||
"a": "item",
|
||||
"t": "10002",
|
||||
"n": 1
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 5,
|
||||
"ranking": [
|
||||
11,
|
||||
20
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 10
|
||||
},
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "gold",
|
||||
"n": 1200
|
||||
},
|
||||
{
|
||||
"a": "item",
|
||||
"t": "10002",
|
||||
"n": 1
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 6,
|
||||
"ranking": [
|
||||
21,
|
||||
50
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 10
|
||||
},
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "gold",
|
||||
"n": 1250
|
||||
},
|
||||
{
|
||||
"a": "item",
|
||||
"t": "10002",
|
||||
"n": 1
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
282
bin/json/game_pagodataskreward.json
Normal file
282
bin/json/game_pagodataskreward.json
Normal file
@ -0,0 +1,282 @@
|
||||
[
|
||||
{
|
||||
"key": 1,
|
||||
"pagoda_type": 1,
|
||||
"layer_num": [
|
||||
10
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 50
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 2,
|
||||
"pagoda_type": 1,
|
||||
"layer_num": [
|
||||
20
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 100
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 3,
|
||||
"pagoda_type": 1,
|
||||
"layer_num": [
|
||||
30
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 150
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 4,
|
||||
"pagoda_type": 1,
|
||||
"layer_num": [
|
||||
40
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 200
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 5,
|
||||
"pagoda_type": 1,
|
||||
"layer_num": [
|
||||
50
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 250
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 6,
|
||||
"pagoda_type": 1,
|
||||
"layer_num": [
|
||||
60
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 300
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 7,
|
||||
"pagoda_type": 1,
|
||||
"layer_num": [
|
||||
70
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 350
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 8,
|
||||
"pagoda_type": 1,
|
||||
"layer_num": [
|
||||
80
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 400
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 9,
|
||||
"pagoda_type": 1,
|
||||
"layer_num": [
|
||||
90
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 450
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 10,
|
||||
"pagoda_type": 1,
|
||||
"layer_num": [
|
||||
100
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 500
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 11,
|
||||
"pagoda_type": 2,
|
||||
"layer_num": [
|
||||
5
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 50
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 12,
|
||||
"pagoda_type": 2,
|
||||
"layer_num": [
|
||||
10
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 100
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 13,
|
||||
"pagoda_type": 2,
|
||||
"layer_num": [
|
||||
15
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 150
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 14,
|
||||
"pagoda_type": 2,
|
||||
"layer_num": [
|
||||
20
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 200
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 15,
|
||||
"pagoda_type": 2,
|
||||
"layer_num": [
|
||||
25
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 250
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 16,
|
||||
"pagoda_type": 2,
|
||||
"layer_num": [
|
||||
30
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 300
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 17,
|
||||
"pagoda_type": 2,
|
||||
"layer_num": [
|
||||
35
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 350
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 18,
|
||||
"pagoda_type": 2,
|
||||
"layer_num": [
|
||||
40
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 400
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 19,
|
||||
"pagoda_type": 2,
|
||||
"layer_num": [
|
||||
45
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 450
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"key": 20,
|
||||
"pagoda_type": 2,
|
||||
"layer_num": [
|
||||
50
|
||||
],
|
||||
"reward": [
|
||||
{
|
||||
"a": "attr",
|
||||
"t": "diamond",
|
||||
"n": 500
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -8,19 +8,18 @@
|
||||
},
|
||||
"Desc": {
|
||||
"key": "skill_buffdes_390001001",
|
||||
"text": "攻击提升40%"
|
||||
"text": "攻击提升"
|
||||
},
|
||||
"Tags": [
|
||||
"201"
|
||||
"201",
|
||||
"402"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [
|
||||
"402"
|
||||
],
|
||||
"buffico": "buff_2",
|
||||
"buffeffect": "effect_buff_attackup",
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
"buffeffect": "",
|
||||
"buffpos": ""
|
||||
},
|
||||
{
|
||||
@ -32,19 +31,18 @@
|
||||
},
|
||||
"Desc": {
|
||||
"key": "skill_buffdes_390001002",
|
||||
"text": "防御提升60%"
|
||||
"text": "防御提升"
|
||||
},
|
||||
"Tags": [
|
||||
"201"
|
||||
"201",
|
||||
"402"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [
|
||||
"402"
|
||||
],
|
||||
"buffico": "buff_1",
|
||||
"buffeffect": "effect_buff_fangyu",
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
"buffeffect": "",
|
||||
"buffpos": ""
|
||||
},
|
||||
{
|
||||
@ -56,17 +54,16 @@
|
||||
},
|
||||
"Desc": {
|
||||
"key": "skill_buffdes_390001003",
|
||||
"text": "速度提升30%"
|
||||
"text": "速度提升"
|
||||
},
|
||||
"Tags": [
|
||||
"201"
|
||||
"201",
|
||||
"402"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [
|
||||
"402"
|
||||
],
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
"buffeffect": "",
|
||||
"buffpos": ""
|
||||
@ -80,17 +77,16 @@
|
||||
},
|
||||
"Desc": {
|
||||
"key": "skill_buffdes_390001004",
|
||||
"text": "暴击率提升30%"
|
||||
"text": "暴击率提升"
|
||||
},
|
||||
"Tags": [
|
||||
"201"
|
||||
"201",
|
||||
"402"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [
|
||||
"402"
|
||||
],
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
"buffeffect": "",
|
||||
"buffpos": ""
|
||||
@ -104,17 +100,16 @@
|
||||
},
|
||||
"Desc": {
|
||||
"key": "skill_buffdes_390001005",
|
||||
"text": "受到暴击概率降低30%"
|
||||
"text": "受到暴击概率降低"
|
||||
},
|
||||
"Tags": [
|
||||
"201"
|
||||
"201",
|
||||
"402"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [
|
||||
"402"
|
||||
],
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
"buffeffect": "",
|
||||
"buffpos": ""
|
||||
@ -131,14 +126,14 @@
|
||||
"text": "(无法驱散类状态)每层使自身攻击力提升5%,每10层使自身受到伤害降低3%。最高可叠加50层"
|
||||
},
|
||||
"Tags": [
|
||||
"303"
|
||||
"303",
|
||||
"50",
|
||||
"True"
|
||||
],
|
||||
"OverlayTimes": 50,
|
||||
"SameID": true,
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [
|
||||
"402"
|
||||
],
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
"buffeffect": "",
|
||||
"buffpos": ""
|
||||
@ -155,14 +150,14 @@
|
||||
"text": "每层使自身基础防御提升10%,效果抵抗提升5%,最多可叠加10层。"
|
||||
},
|
||||
"Tags": [
|
||||
"201"
|
||||
"303",
|
||||
"10",
|
||||
"True"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [
|
||||
"402"
|
||||
],
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
"buffeffect": "",
|
||||
"buffpos": ""
|
||||
@ -179,14 +174,14 @@
|
||||
"text": "每次受到攻击提升20%的防御,最多叠加5层"
|
||||
},
|
||||
"Tags": [
|
||||
"201"
|
||||
"303",
|
||||
"5",
|
||||
"True"
|
||||
],
|
||||
"OverlayTimes": 5,
|
||||
"SameID": true,
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [
|
||||
"402"
|
||||
],
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
"buffeffect": "",
|
||||
"buffpos": ""
|
||||
@ -200,17 +195,16 @@
|
||||
},
|
||||
"Desc": {
|
||||
"key": "skill_buffdes_390002001",
|
||||
"text": "攻击下降40%"
|
||||
"text": "攻击下降"
|
||||
},
|
||||
"Tags": [
|
||||
"202"
|
||||
"202",
|
||||
"302"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [
|
||||
"302"
|
||||
],
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
"buffeffect": "",
|
||||
"buffpos": ""
|
||||
@ -224,17 +218,16 @@
|
||||
},
|
||||
"Desc": {
|
||||
"key": "skill_buffdes_390002002",
|
||||
"text": "防御下降60%"
|
||||
"text": "防御下降"
|
||||
},
|
||||
"Tags": [
|
||||
"202"
|
||||
"202",
|
||||
"302"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [
|
||||
"302"
|
||||
],
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
"buffeffect": "",
|
||||
"buffpos": ""
|
||||
@ -248,17 +241,16 @@
|
||||
},
|
||||
"Desc": {
|
||||
"key": "skill_buffdes_390002003",
|
||||
"text": "速度下降30%"
|
||||
"text": "速度下降"
|
||||
},
|
||||
"Tags": [
|
||||
"202"
|
||||
"202",
|
||||
"302"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [
|
||||
"302"
|
||||
],
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
"buffeffect": "",
|
||||
"buffpos": ""
|
||||
@ -272,17 +264,16 @@
|
||||
},
|
||||
"Desc": {
|
||||
"key": "skill_buffdes_390002004",
|
||||
"text": "暴击率下降30%"
|
||||
"text": "暴击率下降"
|
||||
},
|
||||
"Tags": [
|
||||
"202"
|
||||
"202",
|
||||
"302"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [
|
||||
"302"
|
||||
],
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
"buffeffect": "",
|
||||
"buffpos": ""
|
||||
@ -296,17 +287,16 @@
|
||||
},
|
||||
"Desc": {
|
||||
"key": "skill_buffdes_390002005",
|
||||
"text": "被攻击时,受到的伤害提高25%"
|
||||
"text": "被攻击时,受到的伤害提高"
|
||||
},
|
||||
"Tags": [
|
||||
"202"
|
||||
"202",
|
||||
"302"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [
|
||||
"302"
|
||||
],
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
"buffeffect": "",
|
||||
"buffpos": ""
|
||||
@ -320,24 +310,23 @@
|
||||
},
|
||||
"Desc": {
|
||||
"key": "skill_buffdes_390002006",
|
||||
"text": "失手率提升50%"
|
||||
"text": "失手率提升"
|
||||
},
|
||||
"Tags": [
|
||||
"202"
|
||||
"202",
|
||||
"302"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [
|
||||
"302"
|
||||
],
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
"buffeffect": "",
|
||||
"buffpos": ""
|
||||
},
|
||||
{
|
||||
"Id": 390003001,
|
||||
"Type": "TagBuff",
|
||||
"Type": "ProBuff",
|
||||
"Name": {
|
||||
"key": "skill_buff_390003001",
|
||||
"text": "无敌"
|
||||
@ -347,22 +336,19 @@
|
||||
"text": "不会受到任何伤害"
|
||||
},
|
||||
"Tags": [
|
||||
"201",
|
||||
"301"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [
|
||||
"402"
|
||||
],
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
"buffeffect": "",
|
||||
"buffpos": ""
|
||||
},
|
||||
{
|
||||
"Id": 390003002,
|
||||
"Type": "TagBuff",
|
||||
"Type": "ProBuff",
|
||||
"Name": {
|
||||
"key": "skill_buff_390003002",
|
||||
"text": "对峙"
|
||||
@ -372,22 +358,19 @@
|
||||
"text": "生命最低降为1"
|
||||
},
|
||||
"Tags": [
|
||||
"201",
|
||||
"501"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [
|
||||
"402"
|
||||
],
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
"buffeffect": "",
|
||||
"buffpos": ""
|
||||
},
|
||||
{
|
||||
"Id": 390003003,
|
||||
"Type": "TagBuff",
|
||||
"Type": "ProBuff",
|
||||
"Name": {
|
||||
"key": "skill_buff_390003003",
|
||||
"text": "免疫控制效果"
|
||||
@ -402,16 +385,14 @@
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [
|
||||
"402"
|
||||
],
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
"buffeffect": "",
|
||||
"buffpos": ""
|
||||
},
|
||||
{
|
||||
"Id": 390003004,
|
||||
"Type": "TagBuff",
|
||||
"Type": "ProBuff",
|
||||
"Name": {
|
||||
"key": "skill_buff_390003004",
|
||||
"text": "免除死亡"
|
||||
@ -440,20 +421,19 @@
|
||||
},
|
||||
"Desc": {
|
||||
"key": "skill_buffdes_390004001",
|
||||
"text": "无法进行任务行动"
|
||||
"text": "无法进行任何行动"
|
||||
},
|
||||
"Tags": [
|
||||
"202",
|
||||
"604"
|
||||
"604",
|
||||
"302"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [
|
||||
"302"
|
||||
],
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
"buffeffect": "effect_buff_xuanyun",
|
||||
"buffeffect": "",
|
||||
"buffpos": ""
|
||||
},
|
||||
{
|
||||
@ -469,16 +449,15 @@
|
||||
},
|
||||
"Tags": [
|
||||
"202",
|
||||
"604"
|
||||
"604",
|
||||
"302"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [
|
||||
"302"
|
||||
],
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
"buffeffect": "effect_buff_bingdong",
|
||||
"buffeffect": "",
|
||||
"buffpos": ""
|
||||
},
|
||||
{
|
||||
@ -494,14 +473,13 @@
|
||||
},
|
||||
"Tags": [
|
||||
"202",
|
||||
"401"
|
||||
"401",
|
||||
"302"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [
|
||||
"302"
|
||||
],
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
"buffeffect": "",
|
||||
"buffpos": ""
|
||||
@ -519,17 +497,13 @@
|
||||
},
|
||||
"Tags": [
|
||||
"202",
|
||||
"604",
|
||||
"602",
|
||||
"204"
|
||||
"302"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [
|
||||
"302",
|
||||
"304"
|
||||
],
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
"buffeffect": "",
|
||||
"buffpos": ""
|
||||
@ -548,15 +522,12 @@
|
||||
"Tags": [
|
||||
"202",
|
||||
"603",
|
||||
"204"
|
||||
"302"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [
|
||||
"302",
|
||||
"304"
|
||||
],
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
"buffeffect": "",
|
||||
"buffpos": ""
|
||||
@ -574,17 +545,13 @@
|
||||
},
|
||||
"Tags": [
|
||||
"202",
|
||||
"604",
|
||||
"606",
|
||||
"204"
|
||||
"302"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [
|
||||
"302",
|
||||
"304"
|
||||
],
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
"buffeffect": "",
|
||||
"buffpos": ""
|
||||
@ -602,15 +569,13 @@
|
||||
},
|
||||
"Tags": [
|
||||
"202",
|
||||
"204"
|
||||
"603",
|
||||
"302"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [
|
||||
"302",
|
||||
"304"
|
||||
],
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
"buffeffect": "",
|
||||
"buffpos": ""
|
||||
@ -620,21 +585,20 @@
|
||||
"Type": "TagBuff",
|
||||
"Name": {
|
||||
"key": "skill_buff_390004008",
|
||||
"text": "猫猫威慑 "
|
||||
"text": "猫猫威慑"
|
||||
},
|
||||
"Desc": {
|
||||
"key": "skill_buffdes_390004008",
|
||||
"text": "携带者阵亡时清除此状态,并对携带者一方全体造成崔佛(释放者)攻击力40%的效果附加伤害,每层使伤害系数提升40%,最多可叠加5层。"
|
||||
},
|
||||
"Tags": [
|
||||
"202"
|
||||
"202",
|
||||
"302"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [
|
||||
"302"
|
||||
],
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
"buffeffect": "",
|
||||
"buffpos": ""
|
||||
@ -651,8 +615,9 @@
|
||||
"text": "(无法驱散类状态)可以增强炎阳灼射的威力。"
|
||||
},
|
||||
"Tags": [
|
||||
"201",
|
||||
"303"
|
||||
"202",
|
||||
"303",
|
||||
"302"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
@ -667,11 +632,11 @@
|
||||
"Type": "TagBuff",
|
||||
"Name": {
|
||||
"key": "skill_buff_390005002",
|
||||
"text": "无法获得减益"
|
||||
"text": "免疫"
|
||||
},
|
||||
"Desc": {
|
||||
"key": "skill_buffdes_390005002",
|
||||
"text": "无法获得减益效果(不可驱散)(不配置标签)"
|
||||
"text": "无法获得减益效果"
|
||||
},
|
||||
"Tags": [
|
||||
"302"
|
||||
@ -715,10 +680,10 @@
|
||||
},
|
||||
"Desc": {
|
||||
"key": "skill_buffdes_390006001",
|
||||
"text": "无法附加增益状态(不可驱散)(不配置标签)"
|
||||
"text": "无法附加增益状态"
|
||||
},
|
||||
"Tags": [
|
||||
"302"
|
||||
"402"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
@ -737,9 +702,12 @@
|
||||
},
|
||||
"Desc": {
|
||||
"key": "skill_buffdes_300102103",
|
||||
"text": "受到的所有伤害降低10%"
|
||||
"text": "受到的所有伤害降低"
|
||||
},
|
||||
"Tags": [],
|
||||
"Tags": [
|
||||
"201",
|
||||
"402"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
@ -750,7 +718,7 @@
|
||||
},
|
||||
{
|
||||
"Id": 300162105,
|
||||
"Type": "CallShieldBuff",
|
||||
"Type": "CallShield",
|
||||
"Name": {
|
||||
"key": "",
|
||||
"text": ""
|
||||
@ -759,7 +727,10 @@
|
||||
"key": "",
|
||||
"text": ""
|
||||
},
|
||||
"Tags": [],
|
||||
"Tags": [
|
||||
"201",
|
||||
"402"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
@ -780,10 +751,13 @@
|
||||
"text": "每层为崔佛(释放者)提供15%伤害减免"
|
||||
},
|
||||
"Tags": [
|
||||
"201"
|
||||
"201",
|
||||
"2",
|
||||
"True",
|
||||
"402"
|
||||
],
|
||||
"OverlayTimes": 2,
|
||||
"SameID": true,
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": [],
|
||||
"buffico": "",
|
||||
@ -802,7 +776,8 @@
|
||||
"text": "增加护盾"
|
||||
},
|
||||
"Tags": [
|
||||
"102"
|
||||
"201",
|
||||
"402"
|
||||
],
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
|
@ -519,7 +519,7 @@
|
||||
"When": "ImpEff",
|
||||
"Where": "Target=3,Eff1,EffID=101,TriLim=1",
|
||||
"AddCon": [
|
||||
"BuffRely,Rely0,Key=300192112,Op=1,Val=1",
|
||||
"Type=BuffRely,RelyType=0,Key=300192112,Op=1,Val=1",
|
||||
"ProJudge,Judge1,Key=NowHp_Per,Op=0,Val=500"
|
||||
],
|
||||
"Type": "CallSkillPas",
|
||||
@ -536,7 +536,7 @@
|
||||
"When": "ImpEff",
|
||||
"Where": "Target=3,Eff1,EffID=101,TriLim=1",
|
||||
"AddCon": [
|
||||
"BuffRely,Rely0,Key=300192112,Op=1,Val=1",
|
||||
"Type=BuffRely,RelyType=0,Key=300192112,Op=1,Val=1",
|
||||
"ProJudge,Judge1,Key=NowHp_Per,Op=5,Val=500"
|
||||
],
|
||||
"Type": "CallSkillPas",
|
||||
@ -553,7 +553,7 @@
|
||||
"When": "ImpEff",
|
||||
"Where": "Target=3,Eff1,EffID=101,TriLim=1",
|
||||
"AddCon": [
|
||||
"BuffRely,Rely0,Key=300192112,Op=0,Val=0"
|
||||
"Type=BuffRely,RelyType=0,Key=300192112,Op=0,Val=0"
|
||||
],
|
||||
"Type": "CallSkillPas",
|
||||
"MaxEmitTimes": 0,
|
||||
@ -569,7 +569,7 @@
|
||||
"When": "ImpEff",
|
||||
"Where": "Target=3,Eff0,EffID=300192114",
|
||||
"AddCon": [
|
||||
"BuffRely,Rely0,Key=300192114,Op=0,Val=1"
|
||||
"Type=BuffRely,RelyType=0,Key=300192114,Op=0,Val=1"
|
||||
],
|
||||
"Type": "CallSkillPas",
|
||||
"MaxEmitTimes": 0,
|
||||
@ -627,7 +627,7 @@
|
||||
"When": "ImpEff",
|
||||
"Where": "Target=3,Eff1,EffID=101",
|
||||
"AddCon": [
|
||||
"ProJudge,Judge1,Key=NowHp_Per,Op=0,Val=500"
|
||||
"Type=ProJudge,RelyType=1,Key=NowHp_Per,Op=0,Val=500"
|
||||
],
|
||||
"Type": "CallSkillPas",
|
||||
"MaxEmitTimes": 0,
|
||||
@ -678,5 +678,21 @@
|
||||
"Tags": [],
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": []
|
||||
},
|
||||
{
|
||||
"Id": 425004301,
|
||||
"Desc": "友方攻击时检测",
|
||||
"When": "RouFro",
|
||||
"Where": "Target=4,TesLim=1,TriLim=1",
|
||||
"AddCon": [
|
||||
"Type=CallSkillPas"
|
||||
],
|
||||
"Type": "",
|
||||
"MaxEmitTimes": 0,
|
||||
"OverlayTimes": 0,
|
||||
"SameID": false,
|
||||
"Tags": [],
|
||||
"RelyTags": [],
|
||||
"NoRelyTags": []
|
||||
}
|
||||
]
|
@ -518,7 +518,7 @@
|
||||
{
|
||||
"id": "manual",
|
||||
"file": "HeroManualWindow",
|
||||
"unloadpkg": 1,
|
||||
"unloadpkg": 2,
|
||||
"loadtype": 0,
|
||||
"full": 1,
|
||||
"blur": 0,
|
||||
@ -706,5 +706,41 @@
|
||||
"packagename": "zhandou",
|
||||
"comname": "cropping",
|
||||
"des": "遮幅"
|
||||
},
|
||||
{
|
||||
"id": "saleconfirmpopup",
|
||||
"file": "SaleConfirmPopup",
|
||||
"unloadpkg": 3,
|
||||
"loadtype": 1,
|
||||
"full": 0,
|
||||
"blur": 1,
|
||||
"package": "tips/tips",
|
||||
"packagename": "tips",
|
||||
"comname": "SaleTips",
|
||||
"des": "出售确认弹窗"
|
||||
},
|
||||
{
|
||||
"id": "accesstopopup",
|
||||
"file": "AccessToPopup",
|
||||
"unloadpkg": 3,
|
||||
"loadtype": 1,
|
||||
"full": 0,
|
||||
"blur": 1,
|
||||
"package": "tips/tips",
|
||||
"packagename": "tips",
|
||||
"comname": "AccessTo",
|
||||
"des": "跳转弹窗"
|
||||
},
|
||||
{
|
||||
"id": "rolestrategy",
|
||||
"file": "RoleStrategyWindow",
|
||||
"unloadpkg": 2,
|
||||
"loadtype": 1,
|
||||
"full": 3,
|
||||
"blur": 0,
|
||||
"package": "roledetails/roledetails",
|
||||
"packagename": "roledetails",
|
||||
"comname": "rolestrategy",
|
||||
"des": "角色攻略"
|
||||
}
|
||||
]
|
@ -28,7 +28,7 @@ var res string
|
||||
func TestMain(m *testing.M) {
|
||||
if err := cache.OnInit(nil, cache.Set_Redis_Addr([]string{
|
||||
// "10.0.0.9:6986",
|
||||
"10.0.0.9:9001", "10.0.0.9:9002",
|
||||
"10.0.0.9:9001","10.0.0.9:9002","10.0.0.9:9003","10.0.0.9:9004","10.0.0.9:9005","10.0.0.9:9006",
|
||||
}),
|
||||
cache.Set_Redis_Password(""),
|
||||
// cache.Set_Redis_Password("li13451234"),
|
||||
@ -47,7 +47,7 @@ func TestMain(m *testing.M) {
|
||||
}
|
||||
|
||||
func BenchmarkRedis(b *testing.B) {
|
||||
uid := "0_62b18fce6d57b34781846f64"
|
||||
uid := "2_62ec8ab8828fb7bf67b220b6"
|
||||
heroRedisKey := fmt.Sprintf("hero_%s%s", uid, "{herotest}")
|
||||
var (
|
||||
// ncpu = runtime.NumCPU()
|
||||
|
@ -94,23 +94,23 @@ func (r *Robot) Run() {
|
||||
r.AccountLogin()
|
||||
}
|
||||
|
||||
ticker := time.NewTicker(time.Second * 5)
|
||||
go func() {
|
||||
for {
|
||||
r.printBuilders()
|
||||
<-ticker.C
|
||||
if len(r.builderMap) == 0 {
|
||||
r.printReport(&TestReport{
|
||||
caseTotal: r.caseTotal,
|
||||
caseSuccess: r.caseSuccess,
|
||||
caseError: r.caseError,
|
||||
})
|
||||
os.Exit(0)
|
||||
}
|
||||
}
|
||||
}()
|
||||
// ticker := time.NewTicker(time.Second * 5)
|
||||
// go func() {
|
||||
// for {
|
||||
// r.printBuilders()
|
||||
// <-ticker.C
|
||||
// if len(r.builderMap) == 0 {
|
||||
// r.printReport(&TestReport{
|
||||
// caseTotal: r.caseTotal,
|
||||
// caseSuccess: r.caseSuccess,
|
||||
// caseError: r.caseError,
|
||||
// })
|
||||
// os.Exit(0)
|
||||
// }
|
||||
// }
|
||||
// }()
|
||||
|
||||
select {}
|
||||
// select {}
|
||||
|
||||
}
|
||||
|
||||
@ -154,7 +154,7 @@ func (r *Robot) handleReq() {
|
||||
for len(r.builderMap) > 0 {
|
||||
for _, b := range r.builderMap {
|
||||
if b.enabled && b.req != nil {
|
||||
time.Sleep(time.Millisecond * 500)
|
||||
// time.Sleep(time.Millisecond * 500)
|
||||
b.start = time.Now()
|
||||
r.start = time.Now()
|
||||
head := &pb.UserMessage{MainType: b.mainType, SubType: b.subType}
|
||||
|
4
cmd/v2/build.bat
Normal file
4
cmd/v2/build.bat
Normal file
@ -0,0 +1,4 @@
|
||||
@echo off
|
||||
|
||||
rem build desktop
|
||||
go build -ldflags -H=windowsgui -o robot.exe
|
21
cmd/v2/lib/common/constant.go
Normal file
21
cmd/v2/lib/common/constant.go
Normal file
@ -0,0 +1,21 @@
|
||||
package common
|
||||
|
||||
type (
|
||||
WindowAspect int64
|
||||
WindowMode int64
|
||||
WindowAction int64
|
||||
)
|
||||
|
||||
const (
|
||||
WindowAspect_Normal WindowAspect = iota
|
||||
WindowAspect_FullScreen
|
||||
)
|
||||
|
||||
const (
|
||||
DEFAULT_RESOURCE_PATH = "resources"
|
||||
)
|
||||
|
||||
const (
|
||||
CONFIG_SERVICE_NAME = "name"
|
||||
CONFIG_SERVICE_URL = "url"
|
||||
)
|
153
cmd/v2/lib/common/lang.go
Normal file
153
cmd/v2/lib/common/lang.go
Normal file
@ -0,0 +1,153 @@
|
||||
package common
|
||||
|
||||
// en
|
||||
// const (
|
||||
// // app
|
||||
// APP_NAME = "protocol"
|
||||
|
||||
// app_testcase
|
||||
// APP_TESTCASE_INTRO = "select on left"
|
||||
// APP_TESTCASE_TITLE = "protocol test"
|
||||
// APP_TESTCASE_TITLE = "path"
|
||||
// APP_TESTCASE_BTN_CLEARLOG = "Clear Log"
|
||||
|
||||
//form
|
||||
// APP_TESTCASE_FORM_LABEL_HEROOBJID = "HeroObjID"
|
||||
// APP_TESTCASE_FORM_LABEL_RACECARD = "RaceObjID"
|
||||
// APP_TESTCASE_FORM_LABEL_CARD = "Hero"
|
||||
// APP_TESTCASE_FORM_LABEL_EXPCARDS = "ExpCardID"
|
||||
// APP_TESTCASE_FORM_LABEL_OID = "HeroObjOID"
|
||||
// APP_TESTCASE_FORM_LABEL_NUM = "Amount"
|
||||
// APP_TESTCASE_FORM_TASKTAG = "TaskTag"
|
||||
// APP_TESTCASE_FORM_TASK_OID = "TaskID"
|
||||
// APP_TESTCASE_FORM_NICKNAME = "NickName"
|
||||
// APP_TESTCASE_OPTIONS = "Option"
|
||||
// AAP_TESTCASE_FORM_TASK_DAY = "Day"
|
||||
// AAP_TESTCASE_FORM_TASK_WEEK = "Week"
|
||||
// AAP_TESTCASE_FORM_TASK_ACHIEVE = "Achieve"
|
||||
// // toolbar
|
||||
// TOOLBAR_WELCOME = "welcome"
|
||||
// TOOLBAR_TESTER = "tester"
|
||||
|
||||
// //button
|
||||
// BUTTON_LOGIN = "login"
|
||||
// BUTTON_REGISTE = "registe"
|
||||
// BUTTON_RANDOM = "random"
|
||||
// BUTTON_OK = "ok"
|
||||
// BUTTON_CANCEL = "cancel"
|
||||
|
||||
// //label
|
||||
// LABEL_CHOOSE = "welcome,The service you choose is "
|
||||
// LABEL_NICKNAME = "nickname"
|
||||
// LABEL_ACCOUNT = "account"
|
||||
// LABEL_WELCOME = "welcome "
|
||||
|
||||
// // form title
|
||||
// FORM_TITLE_CREATEROLE = "create role"
|
||||
// FORM_TITLE_LOGIN = "login"
|
||||
|
||||
// // info
|
||||
// INFO_WAIT = "Please wait"
|
||||
|
||||
// // menu
|
||||
// MENU_FILE = "file"
|
||||
|
||||
// //toy
|
||||
// // datetiem
|
||||
// DATETIME = "datetime"
|
||||
// //userinfo
|
||||
// USERINFO_TITLE = "用户信息"
|
||||
// USERINFO_UID = "UID"
|
||||
// USERINFO_ACC = "Acc"
|
||||
// USERINFO_NAME = "Name"
|
||||
// USERINFO_LV = "Lv"
|
||||
// USERINFO_GOLD = "Gold"
|
||||
// USERINFO_EXP = "Exp"
|
||||
// USERINFO_VIP = "VIP"
|
||||
// USERINFO_AVATAR = "Ava"
|
||||
// USERINFO_BTN_COPY = "COPY"
|
||||
// )
|
||||
|
||||
// zh
|
||||
const (
|
||||
// app
|
||||
APP_NAME = "机器人"
|
||||
|
||||
//about
|
||||
APP_ABOUT_TITLE = "关于"
|
||||
APP_ABOUT_CONFIRM = "好的"
|
||||
APP_ABOUT_INFO = `GUI 梦工厂工具`
|
||||
|
||||
// app_testcase
|
||||
APP_TESTCASE_TITLE = "接口测试"
|
||||
APP_TESTCASE_LABEL_PATH = "路径"
|
||||
APP_TESTCASE_BTN_CLEARLOG = "清除"
|
||||
APP_TESTCASE_INTRO = "选择左侧的测试接口"
|
||||
|
||||
// toolbar
|
||||
TOOLBAR_MONITOR = "监控"
|
||||
TOOLBAR_TESTER = "接口测试"
|
||||
|
||||
//monitor
|
||||
APP_MONITOR_TITLE_ID = "编号"
|
||||
APP_MONITOR_TITLE_DATE = "时间"
|
||||
APP_MONITOR_TITLE_DATA = "数据"
|
||||
APP_MONITOR_BTN_VIEW = "查看"
|
||||
|
||||
//form
|
||||
APP_TESTCASE_FORM_LABEL_HEROOBJID = "卡片OID"
|
||||
APP_TESTCASE_FORM_LABEL_RACECARD = "种族卡片"
|
||||
APP_TESTCASE_FORM_LABEL_CARD = "卡片"
|
||||
APP_TESTCASE_FORM_LABEL_EXPCARDS = "经验卡"
|
||||
APP_TESTCASE_FORM_LABEL_OID = "卡片OID"
|
||||
APP_TESTCASE_FORM_LABEL_NUM = "卡片数量"
|
||||
APP_TESTCASE_FORM_TASKTAG = "任务类型"
|
||||
APP_TESTCASE_FORM_TASK_OID = "任务OID"
|
||||
APP_TESTCASE_FORM_NICKNAME = "昵称"
|
||||
APP_TESTCASE_OPTIONS = "选填"
|
||||
AAP_TESTCASE_FORM_TASK_DAY = "日常任务"
|
||||
APP_TESTCASE_FORM_TASK_WEEK = "周常任务"
|
||||
APP_TESTCASE_FORM_TASK_ACHIEVE = "成就"
|
||||
APP_TESTCASE_FORM_BINGO = "命令"
|
||||
APP_TESTCASE_BTN_PUSH = "推送"
|
||||
APP_TESTCASE_FORM_LABEL_FID = "好友ID"
|
||||
|
||||
//button
|
||||
BUTTON_LOGIN = "登录"
|
||||
BUTTON_REGISTE = "注册"
|
||||
BUTTON_RANDOM = "随机"
|
||||
BUTTON_OK = "确定"
|
||||
BUTTON_CANCEL = "取消"
|
||||
|
||||
//label
|
||||
LABEL_CHOOSE = "欢迎,你即将登录的服务是[%s]%s"
|
||||
LABEL_NICKNAME = "昵称"
|
||||
LABEL_ACCOUNT = "账号"
|
||||
LABEL_WELCOME = "欢迎 "
|
||||
|
||||
// form title
|
||||
FORM_TITLE_CREATEROLE = "创角"
|
||||
FORM_TITLE_LOGIN = "登录"
|
||||
|
||||
// info
|
||||
INFO_WAIT = "请稍后"
|
||||
|
||||
// menu
|
||||
MENU_FILE = "文件"
|
||||
|
||||
// toy
|
||||
// datetiem
|
||||
DATETIME = "时钟"
|
||||
|
||||
// userinfo
|
||||
USERINFO_BTN_COPY = "复制UID"
|
||||
USERINFO_TITLE = "用户信息"
|
||||
USERINFO_UID = "UID"
|
||||
USERINFO_ACC = "账号"
|
||||
USERINFO_NAME = "昵称"
|
||||
USERINFO_LV = "等级"
|
||||
USERINFO_GOLD = "金币"
|
||||
USERINFO_EXP = "经验"
|
||||
USERINFO_VIP = "贵宾"
|
||||
USERINFO_AVATAR = "头像"
|
||||
)
|
24
cmd/v2/lib/common/sec.go
Normal file
24
cmd/v2/lib/common/sec.go
Normal file
@ -0,0 +1,24 @@
|
||||
package common
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"go_dreamfactory/cmd/v2/model"
|
||||
"go_dreamfactory/utils"
|
||||
"time"
|
||||
|
||||
jsoniter "github.com/json-iterator/go"
|
||||
"github.com/nacos-group/nacos-sdk-go/util"
|
||||
)
|
||||
|
||||
func BuildSecStr(sid int32, account string) string {
|
||||
jsonByte, _ := jsoniter.Marshal(&model.LoginParam{
|
||||
Account: account,
|
||||
ServerId: sid,
|
||||
TimeStamp: time.Now().Unix(),
|
||||
})
|
||||
jsonBase64 := utils.Base64Encode(jsonByte)
|
||||
// log.Printf("client base64:%s", jsonBase64)
|
||||
clientMd5key := util.Md5(jsonBase64)
|
||||
// log.Printf("client md5:%s", clientMd5key)
|
||||
return fmt.Sprintf("CE:%s%s", clientMd5key, jsonBase64)
|
||||
}
|
43
cmd/v2/lib/common/utils.go
Normal file
43
cmd/v2/lib/common/utils.go
Normal file
@ -0,0 +1,43 @@
|
||||
package common
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"encoding/json"
|
||||
)
|
||||
|
||||
func FormatJson(data string) (string, error) {
|
||||
var out bytes.Buffer
|
||||
err := json.Indent(&out, []byte(data), "", " ")
|
||||
return out.String(), err
|
||||
}
|
||||
|
||||
func SubStr(str string, start int, length int) (result string) {
|
||||
s := []rune(str)
|
||||
total := len(s)
|
||||
if total == 0 {
|
||||
return
|
||||
}
|
||||
// 允许从尾部开始计算
|
||||
if start < 0 {
|
||||
start = total + start
|
||||
if start < 0 {
|
||||
return
|
||||
}
|
||||
}
|
||||
if start > total {
|
||||
return
|
||||
}
|
||||
// 到末尾
|
||||
if length < 0 {
|
||||
length = total
|
||||
}
|
||||
|
||||
end := start + length
|
||||
if end > total {
|
||||
result = string(s[start:])
|
||||
} else {
|
||||
result = string(s[start:end])
|
||||
}
|
||||
|
||||
return
|
||||
}
|
12
cmd/v2/lib/common/utils_test.go
Normal file
12
cmd/v2/lib/common/utils_test.go
Normal file
@ -0,0 +1,12 @@
|
||||
package common
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"testing"
|
||||
)
|
||||
|
||||
func TestSubStr(t *testing.T) {
|
||||
str := "type.googleapis.com/UserResChangePush"
|
||||
r := SubStr(str, 20, len(str))
|
||||
fmt.Println(r)
|
||||
}
|
107
cmd/v2/main.go
Normal file
107
cmd/v2/main.go
Normal file
@ -0,0 +1,107 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"go_dreamfactory/cmd/v2/lib/common"
|
||||
"go_dreamfactory/cmd/v2/service"
|
||||
"go_dreamfactory/cmd/v2/service/observer"
|
||||
"go_dreamfactory/cmd/v2/ui"
|
||||
"io"
|
||||
"os"
|
||||
|
||||
"fyne.io/fyne/v2/app"
|
||||
"github.com/sirupsen/logrus"
|
||||
)
|
||||
|
||||
var (
|
||||
connService service.ConnService
|
||||
pttService service.PttService
|
||||
configService service.ConfigService
|
||||
obs = observer.NewObserver()
|
||||
logger *logrus.Logger
|
||||
)
|
||||
|
||||
//
|
||||
func init() {
|
||||
var err error
|
||||
|
||||
if err = setupConfig(); err != nil {
|
||||
fmt.Println(err)
|
||||
os.Exit(1)
|
||||
}
|
||||
|
||||
// initialize logger
|
||||
if err = setupLogger(); err != nil {
|
||||
fmt.Println(err)
|
||||
os.Exit(1)
|
||||
}
|
||||
|
||||
if err = setupWsConn(); err != nil {
|
||||
fmt.Println(err)
|
||||
os.Exit(1)
|
||||
}
|
||||
|
||||
if err = setupPtt(); err != nil {
|
||||
fmt.Println(err)
|
||||
os.Exit(1)
|
||||
}
|
||||
}
|
||||
|
||||
func main() {
|
||||
logrus.Info("Starting...")
|
||||
|
||||
// create a new ui
|
||||
appUI := ui.NewUI(app.NewWithID("protocol-test-tool"), configService, connService, pttService, obs)
|
||||
mainWindow := ui.NewMainWindow(appUI)
|
||||
|
||||
mainWindow.CreateWindow(common.APP_NAME, 1366, 768, true)
|
||||
|
||||
appUI.Run()
|
||||
}
|
||||
|
||||
func setupPtt() (err error) {
|
||||
pttService = service.NewPttService(connService)
|
||||
return
|
||||
}
|
||||
|
||||
func setupWsConn() (err error) {
|
||||
connService = service.NewConnService(obs)
|
||||
return
|
||||
}
|
||||
|
||||
func setupConfig() (err error) {
|
||||
configService, err = service.NewConfigService()
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
if err = configService.ApplyConfig(); err != nil {
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
func setupLogger() (err error) {
|
||||
logrus.SetFormatter(&logrus.TextFormatter{
|
||||
DisableColors: true,
|
||||
FullTimestamp: true,
|
||||
})
|
||||
|
||||
logrus.SetLevel(logrus.DebugLevel)
|
||||
logrus.SetOutput(os.Stdout)
|
||||
|
||||
//设置output,默认为stderr,可以为任何io.Writer,比如文件*os.File
|
||||
file, err := os.OpenFile("robot_v2.log", os.O_CREATE|os.O_WRONLY|os.O_TRUNC, 0666)
|
||||
writers := []io.Writer{
|
||||
file,
|
||||
os.Stdout}
|
||||
|
||||
//同时写文件和屏幕
|
||||
fileAndStdoutWriter := io.MultiWriter(writers...)
|
||||
if err == nil {
|
||||
logrus.SetOutput(fileAndStdoutWriter)
|
||||
} else {
|
||||
logrus.Fatal("failed to log to file.")
|
||||
}
|
||||
return nil
|
||||
}
|
24
cmd/v2/model/friend.go
Normal file
24
cmd/v2/model/friend.go
Normal file
@ -0,0 +1,24 @@
|
||||
package model
|
||||
|
||||
type FriendModel struct {
|
||||
Uid string
|
||||
Name string
|
||||
}
|
||||
|
||||
type FriendModelList struct {
|
||||
DataList []*FriendModel
|
||||
}
|
||||
|
||||
func NewFriendModelList() *FriendModelList {
|
||||
return &FriendModelList{
|
||||
DataList: make([]*FriendModel, 0),
|
||||
}
|
||||
}
|
||||
|
||||
func (s *FriendModelList) AsInterfaceArray() []interface{} {
|
||||
rs := make([]interface{}, len(s.DataList), len(s.DataList))
|
||||
for i := range s.DataList {
|
||||
rs[i] = s.DataList[i]
|
||||
}
|
||||
return rs
|
||||
}
|
7
cmd/v2/model/login.go
Normal file
7
cmd/v2/model/login.go
Normal file
@ -0,0 +1,7 @@
|
||||
package model
|
||||
|
||||
type LoginParam struct {
|
||||
Account string `json:"account"`
|
||||
ServerId int32 `json:"serverId"`
|
||||
TimeStamp int64 `json:"timestamp"`
|
||||
}
|
29
cmd/v2/model/push.go
Normal file
29
cmd/v2/model/push.go
Normal file
@ -0,0 +1,29 @@
|
||||
package model
|
||||
|
||||
import (
|
||||
"go_dreamfactory/pb"
|
||||
)
|
||||
|
||||
type PushModel struct {
|
||||
MethodName string
|
||||
DataTime string
|
||||
Msg *pb.UserMessage
|
||||
}
|
||||
|
||||
type PushModelList struct {
|
||||
DataList []*PushModel
|
||||
}
|
||||
|
||||
func NewPushModelList() *PushModelList {
|
||||
return &PushModelList{
|
||||
DataList: make([]*PushModel, 0),
|
||||
}
|
||||
}
|
||||
|
||||
func (s *PushModelList) AsInterfaceArray() []interface{} {
|
||||
rs := make([]interface{}, len(s.DataList), len(s.DataList))
|
||||
for i := range s.DataList {
|
||||
rs[i] = s.DataList[i]
|
||||
}
|
||||
return rs
|
||||
}
|
15
cmd/v2/model/testcase.go
Normal file
15
cmd/v2/model/testcase.go
Normal file
@ -0,0 +1,15 @@
|
||||
package model
|
||||
|
||||
import "google.golang.org/protobuf/proto"
|
||||
|
||||
type TestCase struct {
|
||||
Id string //用例ID 如果没有指定,会自动赋值uuid
|
||||
Desc string //用例描述
|
||||
MainType string //协议类型 L1
|
||||
SubType string //协议类型 L2
|
||||
Req proto.Message //请求类型
|
||||
Rsp proto.Message //响应类型
|
||||
Enabled bool //是否启用
|
||||
// View MyCaseView //视图
|
||||
Print func(rsp proto.Message) string //定义打印
|
||||
}
|
18
cmd/v2/readme.md
Normal file
18
cmd/v2/readme.md
Normal file
@ -0,0 +1,18 @@
|
||||
## install tool
|
||||
|
||||
go install fyne.io/fyne/v2/cmd/fyne@latest
|
||||
|
||||
## install font
|
||||
|
||||
### fyne CLI 打包
|
||||
|
||||
fyne bundle msyh.ttc >> bundled.go
|
||||
-- 打包粗体
|
||||
fyne bundle -append msyhbd.ttc >> bundled.go
|
||||
(不要使用powershell 或vscode自带终端)
|
||||
|
||||
## 开发协议参数表单
|
||||
|
||||
1.
|
||||
2.
|
||||
3.
|
17
cmd/v2/resources/config.yaml
Normal file
17
cmd/v2/resources/config.yaml
Normal file
@ -0,0 +1,17 @@
|
||||
services:
|
||||
- service:
|
||||
sid: 1
|
||||
name: 外网
|
||||
url: ws://119.3.89.14:7891/gateway
|
||||
- service:
|
||||
sid: 2
|
||||
name: 赵长远
|
||||
url: ws://10.0.0.238:7891/gateway
|
||||
- service:
|
||||
sid: 3
|
||||
name: 内网
|
||||
url: ws://10.0.0.9:7891/gateway
|
||||
- service:
|
||||
sid: 4
|
||||
name: service4
|
||||
url: ws://10.0.0.101:7891/gateway
|
105
cmd/v2/service/configService.go
Normal file
105
cmd/v2/service/configService.go
Normal file
@ -0,0 +1,105 @@
|
||||
package service
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"go_dreamfactory/cmd/v2/lib/common"
|
||||
|
||||
"github.com/sirupsen/logrus"
|
||||
"github.com/spf13/viper"
|
||||
)
|
||||
|
||||
type ConfigService interface {
|
||||
GetConfig() *Config
|
||||
LoadConfig() error
|
||||
ApplyConfig() error
|
||||
}
|
||||
|
||||
type ConfigServiceImpl struct {
|
||||
ResourcePath string
|
||||
Config *Config
|
||||
}
|
||||
|
||||
type ServiceConf struct {
|
||||
SId int32 `yaml:"sid"`
|
||||
Name string `yaml:"name"`
|
||||
Url string `yaml:"url"`
|
||||
}
|
||||
|
||||
type Services struct {
|
||||
Service *ServiceConf `yaml:"service"`
|
||||
}
|
||||
|
||||
type Config struct {
|
||||
Services []*Services `yaml:"services"`
|
||||
}
|
||||
|
||||
func NewConfigService() (ConfigService, error) {
|
||||
srv := &ConfigServiceImpl{
|
||||
ResourcePath: common.DEFAULT_RESOURCE_PATH,
|
||||
Config: &Config{},
|
||||
}
|
||||
err := srv.init()
|
||||
return srv, err
|
||||
}
|
||||
|
||||
func (c *ConfigServiceImpl) LoadConfig() error {
|
||||
viper.AddConfigPath("./" + c.ResourcePath)
|
||||
return viper.ReadInConfig()
|
||||
}
|
||||
|
||||
func (c *ConfigServiceImpl) ApplyConfig() error {
|
||||
if err := c.LoadConfig(); err != nil {
|
||||
logrus.Error(err)
|
||||
return err
|
||||
}
|
||||
if err := viper.Unmarshal(c.Config); err != nil {
|
||||
logrus.Error(err)
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (c *ConfigServiceImpl) Unmarshal() error {
|
||||
if sArr, ok := viper.Get("services").([]interface{}); ok {
|
||||
for _, service := range sArr {
|
||||
if services, ok := service.(map[interface{}]interface{}); ok {
|
||||
for _, v := range services {
|
||||
if vv, ok := v.(map[interface{}]interface{}); ok {
|
||||
for k, _ := range vv {
|
||||
kk := k.(string)
|
||||
logrus.Debug(vv[kk])
|
||||
srvConf := &ServiceConf{}
|
||||
switch kk {
|
||||
case "sid":
|
||||
srvConf.SId = vv[kk].(int32)
|
||||
case "name":
|
||||
srvConf.Name = vv[kk].(string)
|
||||
case "url":
|
||||
srvConf.Url = vv[kk].(string)
|
||||
default:
|
||||
return fmt.Errorf("config key[%s] not foud", kk)
|
||||
}
|
||||
c.Config.Services = append(c.Config.Services, &Services{})
|
||||
}
|
||||
|
||||
}
|
||||
logrus.Debug(v)
|
||||
// if v
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (c *ConfigServiceImpl) GetConfig() *Config {
|
||||
return c.Config
|
||||
}
|
||||
|
||||
func (c *ConfigServiceImpl) init() error {
|
||||
viper.SetConfigName("config")
|
||||
viper.SetConfigType("yaml")
|
||||
return nil
|
||||
}
|
194
cmd/v2/service/connService.go
Normal file
194
cmd/v2/service/connService.go
Normal file
@ -0,0 +1,194 @@
|
||||
package service
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/lib/common"
|
||||
"go_dreamfactory/cmd/v2/model"
|
||||
"go_dreamfactory/cmd/v2/service/observer"
|
||||
"go_dreamfactory/comm"
|
||||
"go_dreamfactory/pb"
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
"github.com/gorilla/websocket"
|
||||
"github.com/sirupsen/logrus"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
var (
|
||||
conn *ConnServiceImpl
|
||||
)
|
||||
|
||||
type ConnService interface {
|
||||
Connect(wsUrl string) error
|
||||
SendMsg(msg *pb.UserMessage, rsp proto.Message) (err error)
|
||||
ReceiveMsg() (code pb.ErrorCode, msg *pb.UserMessage)
|
||||
ListenerPush()
|
||||
}
|
||||
|
||||
type ConnServiceImpl struct {
|
||||
ws *websocket.Conn
|
||||
obs observer.Observer
|
||||
}
|
||||
|
||||
func NewConnService(obs observer.Observer) ConnService {
|
||||
conn = &ConnServiceImpl{obs: obs}
|
||||
return conn
|
||||
}
|
||||
|
||||
func GetConnService() *ConnServiceImpl {
|
||||
return conn
|
||||
}
|
||||
|
||||
// connect ...
|
||||
func (c *ConnServiceImpl) Connect(wsUrl string) error {
|
||||
dialer := &websocket.Dialer{
|
||||
HandshakeTimeout: 5 * time.Second,
|
||||
}
|
||||
ws, _, err := dialer.Dial(wsUrl, nil)
|
||||
if err != nil {
|
||||
logrus.Errorf("websocket conn err:%v", err)
|
||||
return err
|
||||
}
|
||||
c.ws = ws
|
||||
|
||||
ticker := time.NewTicker(2 * time.Second)
|
||||
go func() {
|
||||
for {
|
||||
_ = <-ticker.C
|
||||
if err := c.ws.WriteMessage(websocket.PingMessage, []byte{}); err != nil {
|
||||
c.obs.Notify(observer.EVENT_PING, err)
|
||||
break
|
||||
}
|
||||
}
|
||||
}()
|
||||
return nil
|
||||
}
|
||||
|
||||
// listener push
|
||||
func (c *ConnServiceImpl) ListenerPush() {
|
||||
go func() {
|
||||
for {
|
||||
time.Sleep(time.Millisecond * 200)
|
||||
msg := &pb.UserMessage{}
|
||||
_, data, err := c.ws.ReadMessage()
|
||||
if err != nil {
|
||||
logrus.Errorf("readMessage err:%v", err)
|
||||
return
|
||||
}
|
||||
|
||||
if err = proto.Unmarshal(data, msg); err != nil {
|
||||
return
|
||||
}
|
||||
// logrus.WithFields(
|
||||
// logrus.Fields{"MainType": msg.MainType, "SubType": msg.SubType},
|
||||
// ).Debug(msg.Data.TypeUrl)
|
||||
|
||||
methodStr := msg.Data.TypeUrl
|
||||
methodName := common.SubStr(methodStr, 20, len(methodStr))
|
||||
p := &model.PushModel{
|
||||
// MainType: msg.MainType,
|
||||
// SubType: msg.SubType,
|
||||
MethodName: methodName,
|
||||
DataTime: time.Now().Format(time.RFC3339),
|
||||
// Rsp: msg.Data,
|
||||
Msg: msg,
|
||||
}
|
||||
logrus.WithFields(
|
||||
logrus.Fields{"MainType": msg.MainType, "SubType": msg.SubType},
|
||||
).Debug(methodName)
|
||||
|
||||
renderRespPanel := func(p *model.PushModel) {
|
||||
// data, err := anypb.New(p.Msg)
|
||||
// if err != nil {
|
||||
// logrus.Error(err)
|
||||
// return
|
||||
// }
|
||||
c.obs.Notify(observer.EVENT_CASE_RSP, p.Msg)
|
||||
}
|
||||
|
||||
if strings.HasSuffix(methodName, "Push") {
|
||||
c.obs.Notify(observer.EVENT_APP_PUSH, p)
|
||||
if methodName == "NotifyErrorNotifyPush" {
|
||||
renderRespPanel(p)
|
||||
}
|
||||
} else {
|
||||
//render appTestcase respPanel
|
||||
renderRespPanel(p)
|
||||
}
|
||||
}
|
||||
}()
|
||||
|
||||
}
|
||||
|
||||
// SendMsg ....
|
||||
func (c *ConnServiceImpl) SendMsg(msg *pb.UserMessage, rsp proto.Message) (err error) {
|
||||
// msg.Sec = r.BuildSecStr()
|
||||
if comm.ProtoMarshal(rsp, msg) {
|
||||
if data, err := proto.Marshal(msg); err != nil {
|
||||
return err
|
||||
} else {
|
||||
return c.ws.WriteMessage(websocket.BinaryMessage, data)
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// ReceiveMsg ....
|
||||
func (c *ConnServiceImpl) ReceiveMsg() (code pb.ErrorCode, msg *pb.UserMessage) {
|
||||
msg = &pb.UserMessage{}
|
||||
_, data, err := c.ws.ReadMessage()
|
||||
if err != nil {
|
||||
code = pb.ErrorCode_SystemError
|
||||
logrus.Errorf("readMessage err:%v", err)
|
||||
return
|
||||
}
|
||||
|
||||
if err = proto.Unmarshal(data, msg); err != nil {
|
||||
return
|
||||
}
|
||||
|
||||
if code = c.handleNotify(msg); code != pb.ErrorCode_Success {
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
// err notify
|
||||
func (c *ConnServiceImpl) handleNotify(msg *pb.UserMessage) (code pb.ErrorCode) {
|
||||
if msg.MainType == "notify" && msg.SubType == "errornotify" {
|
||||
rsp := &pb.NotifyErrorNotifyPush{}
|
||||
if !comm.ProtoUnmarshal(msg, rsp) {
|
||||
code = pb.ErrorCode_PbError
|
||||
return
|
||||
}
|
||||
code = rsp.Code
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// response
|
||||
// func (c *ConnServiceImpl) RespHandle(t *model.TestCase) {
|
||||
// for {
|
||||
// if code, msg := c.ReceiveMsg(); code != pb.ErrorCode_Success {
|
||||
// c.obs.Notify(observer.EVENT_APP_LOG, cast.ToString(code))
|
||||
// } else {
|
||||
// if msg.MainType == t.MainType && msg.SubType == t.SubType {
|
||||
// if t.Print == nil {
|
||||
// if a, err := ptypes.MarshalAny(msg.Data); err != nil {
|
||||
// c.obs.Notify(observer.EVENT_APP_LOG, err.Error())
|
||||
// } else {
|
||||
// c.obs.Notify(observer.EVENT_APP_LOG, a.String())
|
||||
// }
|
||||
// } else {
|
||||
// if !comm.ProtoUnmarshal(msg, t.Rsp) {
|
||||
// return
|
||||
// }
|
||||
// c.obs.Notify(observer.EVENT_APP_LOG, t.Print(t.Rsp))
|
||||
// }
|
||||
// break
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
13
cmd/v2/service/observer/event.go
Normal file
13
cmd/v2/service/observer/event.go
Normal file
@ -0,0 +1,13 @@
|
||||
package observer
|
||||
|
||||
const (
|
||||
EVENT_PING = "ping"
|
||||
//用户详情
|
||||
EVENT_USERINFO Event = "userinfo"
|
||||
//协议推送
|
||||
EVENT_APP_PUSH Event = "push"
|
||||
//测试用例响应事件
|
||||
EVENT_CASE_RSP Event = "response"
|
||||
// 清空 ui数据事件
|
||||
EVENT_UI_CLEAN = "uiclean"
|
||||
)
|
56
cmd/v2/service/observer/observer.go
Normal file
56
cmd/v2/service/observer/observer.go
Normal file
@ -0,0 +1,56 @@
|
||||
package observer
|
||||
|
||||
import "sync"
|
||||
|
||||
type (
|
||||
Event string
|
||||
|
||||
OnNotify func(data interface{}, args ...interface{})
|
||||
|
||||
Listener struct {
|
||||
OnNotify OnNotify
|
||||
}
|
||||
|
||||
Observer interface {
|
||||
AddListener(event Event, listener Listener)
|
||||
Remove(event Event)
|
||||
Notify(event Event, data interface{}, args ...interface{})
|
||||
}
|
||||
|
||||
ObserverImpl struct {
|
||||
listeners map[Event][]Listener
|
||||
}
|
||||
)
|
||||
|
||||
var (
|
||||
obs *ObserverImpl
|
||||
singletonObserver sync.Once
|
||||
)
|
||||
|
||||
func NewObserver() *ObserverImpl {
|
||||
singletonObserver.Do(func() {
|
||||
obs = &ObserverImpl{}
|
||||
})
|
||||
return obs
|
||||
}
|
||||
|
||||
func (o *ObserverImpl) AddListener(event Event, listener Listener) {
|
||||
if o.listeners == nil {
|
||||
o.listeners = map[Event][]Listener{}
|
||||
}
|
||||
o.listeners[event] = append(o.listeners[event], listener)
|
||||
}
|
||||
|
||||
func (o *ObserverImpl) Remove(event Event) {
|
||||
delete(o.listeners, event)
|
||||
}
|
||||
|
||||
func (o *ObserverImpl) Notify(event Event, data interface{}, args ...interface{}) {
|
||||
if listeners, ok := o.listeners[event]; !ok {
|
||||
return
|
||||
} else {
|
||||
for _, listener := range listeners {
|
||||
go listener.OnNotify(data, args...)
|
||||
}
|
||||
}
|
||||
}
|
129
cmd/v2/service/pttService.go
Normal file
129
cmd/v2/service/pttService.go
Normal file
@ -0,0 +1,129 @@
|
||||
package service
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/lib/common"
|
||||
"go_dreamfactory/comm"
|
||||
"go_dreamfactory/modules/user"
|
||||
"go_dreamfactory/pb"
|
||||
|
||||
"github.com/sirupsen/logrus"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
var (
|
||||
ptt PttService
|
||||
)
|
||||
|
||||
type PttService interface {
|
||||
Login(sid int32, account string) (code pb.ErrorCode, rsp *pb.UserLoginResp)
|
||||
CreateRole(nickName string) (code pb.ErrorCode, rsp *pb.UserCreateResp)
|
||||
GetUser() *UserInfo
|
||||
SetUser(dbUser *pb.DBUser, dbUserExpand *pb.DBUserExpand)
|
||||
SendToClient(mainType, subType string, rsp proto.Message) error
|
||||
}
|
||||
|
||||
type PttServiceImpl struct {
|
||||
connService ConnService
|
||||
user *UserInfo
|
||||
}
|
||||
|
||||
type UserInfo struct {
|
||||
DbUser *pb.DBUser
|
||||
DbUserExpand *pb.DBUserExpand
|
||||
}
|
||||
|
||||
func NewPttService(connService ConnService) PttService {
|
||||
ptt = &PttServiceImpl{
|
||||
connService: connService,
|
||||
}
|
||||
return ptt
|
||||
}
|
||||
|
||||
func GetPttService() PttService {
|
||||
return ptt
|
||||
}
|
||||
|
||||
func (p *PttServiceImpl) GetUser() *UserInfo {
|
||||
return p.user
|
||||
}
|
||||
|
||||
func (p *PttServiceImpl) SetUser(dbUser *pb.DBUser, dbUserExpand *pb.DBUserExpand) {
|
||||
p.user = &UserInfo{DbUser: dbUser, DbUserExpand: dbUserExpand}
|
||||
}
|
||||
|
||||
func (p *PttServiceImpl) SendToClient(mainType, subType string, rsp proto.Message) (err error) {
|
||||
msg := &pb.UserMessage{MainType: mainType, SubType: subType}
|
||||
msg.Sec = common.BuildSecStr(p.user.DbUser.Sid, p.user.DbUser.Binduid)
|
||||
if err = p.connService.SendMsg(msg, rsp); err != nil {
|
||||
logrus.WithField("err", err).Error(err)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// Login
|
||||
func (p *PttServiceImpl) Login(sid int32, account string) (code pb.ErrorCode, rsp *pb.UserLoginResp) {
|
||||
head := &pb.UserMessage{MainType: string(comm.ModuleUser), SubType: user.UserSubTypeLogin}
|
||||
head.Sec = common.BuildSecStr(sid, account)
|
||||
if err := p.connService.SendMsg(head, &pb.UserLoginReq{
|
||||
Account: account,
|
||||
Sid: sid,
|
||||
}); err != nil {
|
||||
code = pb.ErrorCode_SystemError
|
||||
logrus.WithField("err", err).Error("Login")
|
||||
return
|
||||
}
|
||||
|
||||
//respone
|
||||
for {
|
||||
if cd, msg := p.connService.ReceiveMsg(); cd != pb.ErrorCode_Success {
|
||||
code = cd
|
||||
break
|
||||
} else {
|
||||
//suc
|
||||
rsp = &pb.UserLoginResp{}
|
||||
if msg.MainType == string(comm.ModuleUser) && msg.SubType == user.UserSubTypeLogin {
|
||||
if !comm.ProtoUnmarshal(msg, rsp) {
|
||||
code = pb.ErrorCode_PbError
|
||||
return
|
||||
}
|
||||
break
|
||||
}
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// create role
|
||||
func (p *PttServiceImpl) CreateRole(nickName string) (code pb.ErrorCode, rsp *pb.UserCreateResp) {
|
||||
head := &pb.UserMessage{MainType: string(comm.ModuleUser), SubType: user.UserSubTypeCreate}
|
||||
head.Sec = common.BuildSecStr(p.user.DbUser.Sid, p.user.DbUser.Binduid)
|
||||
if err := p.connService.SendMsg(head, &pb.UserCreateReq{
|
||||
NickName: nickName,
|
||||
}); err != nil {
|
||||
code = pb.ErrorCode_SystemError
|
||||
logrus.WithField("err", err).Error("CreateRole")
|
||||
return
|
||||
}
|
||||
|
||||
//response
|
||||
// for {
|
||||
// if cd, msg := p.connService.ReceiveMsg(); cd != pb.ErrorCode_Success {
|
||||
// code = cd
|
||||
// break
|
||||
// } else {
|
||||
// rsp = &pb.UserCreateResp{}
|
||||
// if msg.MainType == string(comm.ModuleUser) && msg.SubType == user.UserSubTypeCreate {
|
||||
// if !comm.ProtoUnmarshal(msg, rsp) {
|
||||
// code = pb.ErrorCode_PbError
|
||||
// return
|
||||
// }
|
||||
// logrus.
|
||||
// WithFields(logrus.Fields{"nickname": nickName}).
|
||||
// WithFields(logrus.Fields{"rsp": rsp.IsSucc}).
|
||||
// Debug("response create role")
|
||||
// break
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
return
|
||||
}
|
12
cmd/v2/theme/bundled.go
Normal file
12
cmd/v2/theme/bundled.go
Normal file
File diff suppressed because one or more lines are too long
29
cmd/v2/theme/mytheme.go
Normal file
29
cmd/v2/theme/mytheme.go
Normal file
@ -0,0 +1,29 @@
|
||||
package theme
|
||||
|
||||
import (
|
||||
"image/color"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/theme"
|
||||
)
|
||||
|
||||
type MyTheme struct{}
|
||||
|
||||
var _ fyne.Theme = (*MyTheme)(nil)
|
||||
|
||||
// return bundled font resource
|
||||
// ResourceSourceHanSansTtf 即是 bundle.go 文件中 var 的变量名
|
||||
func (m MyTheme) Font(s fyne.TextStyle) fyne.Resource {
|
||||
return resourceMsyhTtc
|
||||
}
|
||||
func (*MyTheme) Color(n fyne.ThemeColorName, v fyne.ThemeVariant) color.Color {
|
||||
return theme.DarkTheme().Color(n, v)
|
||||
}
|
||||
|
||||
func (*MyTheme) Icon(n fyne.ThemeIconName) fyne.Resource {
|
||||
return theme.DarkTheme().Icon(n)
|
||||
}
|
||||
|
||||
func (*MyTheme) Size(n fyne.ThemeSizeName) float32 {
|
||||
return theme.DarkTheme().Size(n)
|
||||
}
|
24
cmd/v2/ui/about.go
Normal file
24
cmd/v2/ui/about.go
Normal file
@ -0,0 +1,24 @@
|
||||
package ui
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/lib/common"
|
||||
|
||||
"fyne.io/fyne/v2/dialog"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
)
|
||||
|
||||
type about struct {
|
||||
aboutDialog dialog.Dialog
|
||||
}
|
||||
|
||||
func newAbout() *about {
|
||||
var a about
|
||||
content := widget.NewCard("", "", widget.NewRichTextFromMarkdown(common.APP_ABOUT_INFO))
|
||||
a.aboutDialog = dialog.NewCustom(common.APP_ABOUT_TITLE, common.APP_ABOUT_CONFIRM, content, globalWin.w)
|
||||
|
||||
return &a
|
||||
}
|
||||
|
||||
func showAbout() {
|
||||
newAbout().aboutDialog.Show()
|
||||
}
|
92
cmd/v2/ui/app_container.go
Normal file
92
cmd/v2/ui/app_container.go
Normal file
@ -0,0 +1,92 @@
|
||||
package ui
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/service/observer"
|
||||
|
||||
"fyne.io/fyne/v2/container"
|
||||
)
|
||||
|
||||
type appContainer struct {
|
||||
appStatusMap map[string]appStatus
|
||||
container.DocTabs
|
||||
obs observer.Observer
|
||||
}
|
||||
|
||||
func newAppContainer(obs observer.Observer) *appContainer {
|
||||
at := &appContainer{obs: obs}
|
||||
|
||||
at.appStatusMap = make(map[string]appStatus)
|
||||
at.CloseIntercept = at.closeHandle
|
||||
at.SetTabLocation(container.TabLocationTop)
|
||||
at.ExtendBaseWidget(at)
|
||||
at.OnSelected = func(item *container.TabItem) {
|
||||
item.Content.Refresh()
|
||||
}
|
||||
return at
|
||||
}
|
||||
|
||||
type appStatus struct {
|
||||
lazyInit bool
|
||||
}
|
||||
|
||||
func (at *appContainer) closeHandle(tab *container.TabItem) {
|
||||
for _, app := range appRegister {
|
||||
if app.GetAppName() == tab.Text {
|
||||
if app.OnClose() {
|
||||
at.Remove(tab)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func (at *appContainer) openApp(app appInterface) error {
|
||||
for _, appItem := range at.Items {
|
||||
if appItem.Text == app.GetAppName() {
|
||||
at.Select(appItem)
|
||||
return nil
|
||||
}
|
||||
}
|
||||
err := at.initApp(app)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
tab := app.GetTabItem()
|
||||
at.Append(tab)
|
||||
at.Select(tab)
|
||||
return nil
|
||||
}
|
||||
|
||||
// open default app
|
||||
func (at *appContainer) openDefaultApp() (string, error) {
|
||||
var firstTab *container.TabItem
|
||||
for _, app := range appRegister {
|
||||
if app.OpenDefault() {
|
||||
if err := at.initApp(app); err != nil {
|
||||
return app.GetAppName(), err
|
||||
}
|
||||
tab := app.GetTabItem()
|
||||
at.Append(tab)
|
||||
if firstTab == nil {
|
||||
firstTab = tab
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if firstTab != nil {
|
||||
at.Select(firstTab)
|
||||
}
|
||||
return "", nil
|
||||
}
|
||||
|
||||
func (at *appContainer) initApp(app appInterface) error {
|
||||
st, ok := at.appStatusMap[app.GetAppName()]
|
||||
if !ok || !st.lazyInit {
|
||||
err := app.LazyInit(at.obs)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
at.appStatusMap[app.GetAppName()] = appStatus{lazyInit: true}
|
||||
}
|
||||
return nil
|
||||
}
|
46
cmd/v2/ui/app_interface.go
Normal file
46
cmd/v2/ui/app_interface.go
Normal file
@ -0,0 +1,46 @@
|
||||
package ui
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/service/observer"
|
||||
|
||||
"fyne.io/fyne/v2/container"
|
||||
)
|
||||
|
||||
type appInterface interface {
|
||||
LazyInit(obs observer.Observer) error
|
||||
GetTabItem() *container.TabItem
|
||||
GetAppName() string
|
||||
OpenDefault() bool
|
||||
OnClose() bool
|
||||
}
|
||||
|
||||
var (
|
||||
appRegister = []appInterface{
|
||||
&appMonitor{},
|
||||
&appTester{},
|
||||
}
|
||||
)
|
||||
|
||||
type appAdapter struct {
|
||||
tabItem *container.TabItem
|
||||
}
|
||||
|
||||
func (a appAdapter) LazyInit() error {
|
||||
panic("implement LazyInit")
|
||||
}
|
||||
|
||||
func (a appAdapter) GetAppName() string {
|
||||
panic("implement GetAppName()")
|
||||
}
|
||||
|
||||
func (a appAdapter) OpenDefault() bool {
|
||||
return false
|
||||
}
|
||||
|
||||
func (a appAdapter) GetTabItem() *container.TabItem {
|
||||
return a.tabItem
|
||||
}
|
||||
|
||||
func (a appAdapter) OnClose() bool {
|
||||
return true
|
||||
}
|
142
cmd/v2/ui/app_monitor.go
Normal file
142
cmd/v2/ui/app_monitor.go
Normal file
@ -0,0 +1,142 @@
|
||||
package ui
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"go_dreamfactory/cmd/v2/lib/common"
|
||||
"go_dreamfactory/cmd/v2/model"
|
||||
"go_dreamfactory/cmd/v2/service/observer"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/container"
|
||||
"fyne.io/fyne/v2/data/binding"
|
||||
"fyne.io/fyne/v2/layout"
|
||||
"fyne.io/fyne/v2/theme"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
"github.com/sirupsen/logrus"
|
||||
"google.golang.org/protobuf/types/known/anypb"
|
||||
)
|
||||
|
||||
type appMonitor struct {
|
||||
appAdapter
|
||||
|
||||
obs observer.Observer
|
||||
logPanel *widget.Entry
|
||||
monitorHeader *widget.List
|
||||
monitorList *widget.List
|
||||
monitorBinding binding.UntypedList
|
||||
monitorData *model.PushModelList
|
||||
}
|
||||
|
||||
func (this *appMonitor) LazyInit(obs observer.Observer) error {
|
||||
this.obs = obs
|
||||
this.tabItem = container.NewTabItemWithIcon(common.TOOLBAR_MONITOR, theme.ComputerIcon(), nil)
|
||||
|
||||
content := container.NewMax()
|
||||
content.Objects = []fyne.CanvasObject{}
|
||||
|
||||
// panel for output log
|
||||
this.logPanel = widget.NewMultiLineEntry()
|
||||
this.logPanel.Wrapping = fyne.TextWrapWord
|
||||
//clear button
|
||||
clearBtn := widget.NewButtonWithIcon(common.APP_TESTCASE_BTN_CLEARLOG, theme.DeleteIcon(), func() {
|
||||
this.logPanel.SetText("")
|
||||
this.monitorBinding.Set([]interface{}{})
|
||||
})
|
||||
|
||||
resPanel := container.NewBorder(container.NewHBox(clearBtn, layout.NewSpacer()), nil, nil, nil, this.logPanel)
|
||||
|
||||
this.monitorBinding = binding.NewUntypedList()
|
||||
this.monitorData = model.NewPushModelList()
|
||||
this.createMonitorList()
|
||||
|
||||
// layout
|
||||
panel := container.NewVSplit(container.NewBorder(this.monitorHeader, nil, nil, nil, this.monitorList), resPanel)
|
||||
content.Objects = append(content.Objects, panel)
|
||||
this.tabItem.Content = content
|
||||
this.Run()
|
||||
return nil
|
||||
}
|
||||
|
||||
func (a *appMonitor) OpenDefault() bool {
|
||||
return true
|
||||
}
|
||||
|
||||
func (a *appMonitor) GetAppName() string {
|
||||
return common.TOOLBAR_MONITOR
|
||||
}
|
||||
|
||||
func (a appMonitor) OnClose() bool {
|
||||
return false
|
||||
}
|
||||
|
||||
// monitor list data
|
||||
func (this *appMonitor) Run() {
|
||||
this.obs.AddListener(observer.EVENT_APP_PUSH, observer.Listener{
|
||||
OnNotify: func(d interface{}, args ...interface{}) {
|
||||
data := d.(*model.PushModel)
|
||||
this.monitorData.DataList = append(this.monitorData.DataList, data)
|
||||
this.reloadMonitorData()
|
||||
},
|
||||
})
|
||||
}
|
||||
|
||||
func (this *appMonitor) reloadMonitorData() {
|
||||
if this.monitorData != nil {
|
||||
d := this.monitorData.AsInterfaceArray()
|
||||
this.monitorBinding.Set(d)
|
||||
}
|
||||
}
|
||||
|
||||
func (this *appMonitor) createMonitorList() {
|
||||
// header
|
||||
this.monitorHeader = widget.NewList(
|
||||
func() int {
|
||||
return 1
|
||||
},
|
||||
func() fyne.CanvasObject {
|
||||
return container.NewGridWithColumns(3,
|
||||
widget.NewLabelWithStyle("", fyne.TextAlignLeading, fyne.TextStyle{}),
|
||||
widget.NewLabelWithStyle("", fyne.TextAlignCenter, fyne.TextStyle{}),
|
||||
widget.NewLabelWithStyle("", fyne.TextAlignCenter, fyne.TextStyle{}))
|
||||
},
|
||||
func(id widget.ListItemID, item fyne.CanvasObject) {
|
||||
item.(*fyne.Container).Objects[0].(*widget.Label).SetText(common.APP_MONITOR_TITLE_ID)
|
||||
item.(*fyne.Container).Objects[1].(*widget.Label).SetText(common.APP_MONITOR_TITLE_DATA)
|
||||
item.(*fyne.Container).Objects[2].(*widget.Label).SetText(common.APP_MONITOR_TITLE_DATE)
|
||||
},
|
||||
)
|
||||
|
||||
// data
|
||||
this.monitorList = widget.NewListWithData(this.monitorBinding,
|
||||
func() fyne.CanvasObject {
|
||||
return container.NewGridWithColumns(3,
|
||||
widget.NewLabelWithStyle("", fyne.TextAlignLeading, fyne.TextStyle{}),
|
||||
widget.NewLabelWithStyle("", fyne.TextAlignCenter, fyne.TextStyle{}),
|
||||
widget.NewLabelWithStyle("", fyne.TextAlignCenter, fyne.TextStyle{}),
|
||||
)
|
||||
},
|
||||
func(data binding.DataItem, item fyne.CanvasObject) {
|
||||
o, _ := data.(binding.Untyped).Get()
|
||||
pd := o.(*model.PushModel)
|
||||
item.(*fyne.Container).Objects[0].(*widget.Label).SetText(fmt.Sprintf("%s.%s", pd.Msg.MainType, pd.Msg.SubType))
|
||||
item.(*fyne.Container).Objects[1].(*widget.Label).SetText(pd.MethodName)
|
||||
item.(*fyne.Container).Objects[2].(*widget.Label).SetText(pd.DataTime)
|
||||
},
|
||||
)
|
||||
|
||||
this.monitorList.OnSelected = func(id widget.ListItemID) {
|
||||
if di, err := this.monitorBinding.GetItem(id); err != nil {
|
||||
logrus.Error(err)
|
||||
} else {
|
||||
o, _ := di.(binding.Untyped).Get()
|
||||
pd := o.(*model.PushModel)
|
||||
if res, err := anypb.New(pd.Msg.Data); err == nil {
|
||||
this.logPanel.Text = res.String()
|
||||
this.logPanel.Refresh()
|
||||
} else {
|
||||
logrus.WithField("err", err).Error("view detail")
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
137
cmd/v2/ui/app_testcase.go
Normal file
137
cmd/v2/ui/app_testcase.go
Normal file
@ -0,0 +1,137 @@
|
||||
package ui
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"go_dreamfactory/cmd/v2/lib/common"
|
||||
"go_dreamfactory/cmd/v2/model"
|
||||
"go_dreamfactory/cmd/v2/service/observer"
|
||||
"go_dreamfactory/pb"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/container"
|
||||
"fyne.io/fyne/v2/layout"
|
||||
"fyne.io/fyne/v2/theme"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
"github.com/sirupsen/logrus"
|
||||
)
|
||||
|
||||
type appTester struct {
|
||||
appAdapter
|
||||
}
|
||||
|
||||
func (a *appTester) GetAppName() string {
|
||||
return common.TOOLBAR_TESTER
|
||||
}
|
||||
|
||||
func (a *appTester) disEnabled(t *model.TestCase) bool {
|
||||
return !t.Enabled
|
||||
}
|
||||
|
||||
func (a *appTester) LazyInit(obs observer.Observer) error {
|
||||
a.tabItem = container.NewTabItemWithIcon(common.TOOLBAR_TESTER, theme.AccountIcon(), nil)
|
||||
|
||||
content := container.NewMax()
|
||||
title := widget.NewLabel(common.APP_TESTCASE_TITLE)
|
||||
intro := widget.NewLabel("")
|
||||
intro.Wrapping = fyne.TextWrapWord
|
||||
caseContent := container.NewBorder(
|
||||
container.NewVBox(title, widget.NewSeparator(), intro), nil, nil, nil, content)
|
||||
|
||||
setNav := func(t *model.TestCase) {
|
||||
viewKey := fmt.Sprintf("%s.%s", t.MainType, t.SubType)
|
||||
title.SetText(fmt.Sprintf("%s : %s", common.APP_TESTCASE_LABEL_PATH, viewKey))
|
||||
intro.SetText(t.Desc)
|
||||
content.Objects = []fyne.CanvasObject{}
|
||||
|
||||
if view, ok := viewRegister[viewKey]; ok {
|
||||
view.Init(obs, globalWin.w)
|
||||
resLog := widget.NewMultiLineEntry()
|
||||
obs.AddListener(observer.EVENT_CASE_RSP, observer.Listener{
|
||||
OnNotify: func(data interface{}, args ...interface{}) {
|
||||
if data == nil {
|
||||
return
|
||||
}
|
||||
msg := data.(*pb.UserMessage)
|
||||
resLog.SetText(msg.Data.String())
|
||||
},
|
||||
})
|
||||
|
||||
resLog.Wrapping = fyne.TextWrapBreak
|
||||
formReq := view.CreateView(t)
|
||||
// required! Refresh updates the widget
|
||||
formReq.Refresh()
|
||||
formCard := widget.NewCard("", "", formReq)
|
||||
|
||||
clearBtn := widget.NewButtonWithIcon(common.APP_TESTCASE_BTN_CLEARLOG, theme.DeleteIcon(), func() {
|
||||
resLog.SetText("")
|
||||
})
|
||||
resPanel := container.NewBorder(container.NewHBox(clearBtn, layout.NewSpacer()), nil, nil, nil, resLog)
|
||||
|
||||
panel := container.NewVSplit(
|
||||
formCard,
|
||||
resPanel,
|
||||
)
|
||||
content.Objects = append(content.Objects, panel)
|
||||
} else {
|
||||
logrus.WithFields(logrus.Fields{"mainType": t.MainType, "subType": t.SubType}).Warn("no view")
|
||||
}
|
||||
|
||||
content.Refresh()
|
||||
}
|
||||
split := container.NewHSplit(a.makeNav(setNav), caseContent)
|
||||
split.Offset = 0.2
|
||||
a.tabItem.Content = split
|
||||
return nil
|
||||
}
|
||||
|
||||
func (a *appTester) makeNav(setNav func(testCase *model.TestCase)) fyne.CanvasObject {
|
||||
tree := &widget.Tree{
|
||||
ChildUIDs: func(uid string) (c []widget.TreeNodeID) {
|
||||
return CaseIndex[uid]
|
||||
},
|
||||
IsBranch: func(uid string) bool {
|
||||
children, ok := CaseIndex[uid]
|
||||
return ok && len(children) > 0
|
||||
},
|
||||
CreateNode: func(branch bool) fyne.CanvasObject {
|
||||
return widget.NewLabel("(empty)")
|
||||
},
|
||||
UpdateNode: func(uid string, branch bool, obj fyne.CanvasObject) {
|
||||
t, ok := CaseNav[uid]
|
||||
if !ok {
|
||||
logrus.WithField("id", uid).Warnf("Missing tutorial panel")
|
||||
return
|
||||
}
|
||||
if a.disEnabled(t) {
|
||||
obj.(*widget.Label).TextStyle = fyne.TextStyle{Italic: true}
|
||||
if branch {
|
||||
obj.(*widget.Label).SetText(fmt.Sprintf("%s(dis)", t.MainType))
|
||||
} else {
|
||||
obj.(*widget.Label).SetText(fmt.Sprintf("%s(dis)", t.SubType))
|
||||
}
|
||||
} else {
|
||||
obj.(*widget.Label).TextStyle = fyne.TextStyle{}
|
||||
if branch {
|
||||
obj.(*widget.Label).SetText(t.MainType)
|
||||
} else {
|
||||
obj.(*widget.Label).SetText(t.SubType)
|
||||
}
|
||||
|
||||
}
|
||||
},
|
||||
OnSelected: func(uid string) {
|
||||
if t, ok := CaseNav[uid]; ok {
|
||||
logrus.WithFields(logrus.Fields{"mainType": t.MainType, "subType": t.SubType}).Debug("select")
|
||||
if a.disEnabled(t) {
|
||||
return
|
||||
}
|
||||
if t.SubType == "" {
|
||||
return
|
||||
}
|
||||
|
||||
setNav(t)
|
||||
}
|
||||
},
|
||||
}
|
||||
return container.NewBorder(nil, nil, nil, nil, tree)
|
||||
}
|
10
cmd/v2/ui/basewindow.go
Normal file
10
cmd/v2/ui/basewindow.go
Normal file
@ -0,0 +1,10 @@
|
||||
package ui
|
||||
|
||||
import "go_dreamfactory/cmd/v2/lib/common"
|
||||
|
||||
type WindowDefaultOptions struct {
|
||||
windowAction common.WindowAction
|
||||
windowMode common.WindowMode
|
||||
windowAspect common.WindowAspect
|
||||
windowVisible bool
|
||||
}
|
57
cmd/v2/ui/cz_box_layout.go
Normal file
57
cmd/v2/ui/cz_box_layout.go
Normal file
@ -0,0 +1,57 @@
|
||||
package ui
|
||||
|
||||
import (
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/theme"
|
||||
)
|
||||
|
||||
// Declare conformity with Layout interface
|
||||
var _ fyne.Layout = (*CZBoxLayout)(nil)
|
||||
|
||||
// CZBoxLayout is a grid layout that support custom size of object
|
||||
// Now only support vertical mode
|
||||
type CZBoxLayout struct {
|
||||
vertical bool
|
||||
}
|
||||
|
||||
func NewVCZBoxLayout() fyne.Layout {
|
||||
return &CZBoxLayout{vertical: true}
|
||||
}
|
||||
|
||||
func (c *CZBoxLayout) Layout(objects []fyne.CanvasObject, size fyne.Size) {
|
||||
pos := fyne.NewPos(0, 0)
|
||||
for _, child := range objects {
|
||||
if !child.Visible() {
|
||||
continue
|
||||
}
|
||||
|
||||
child.Move(pos)
|
||||
size := child.Size()
|
||||
if c.vertical {
|
||||
pos = pos.Add(fyne.NewPos(0, size.Height+theme.Padding()))
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func (c *CZBoxLayout) MinSize(objects []fyne.CanvasObject) fyne.Size {
|
||||
minSize := fyne.NewSize(0, 0)
|
||||
addPadding := false
|
||||
for _, child := range objects {
|
||||
if !child.Visible() {
|
||||
continue
|
||||
}
|
||||
|
||||
if c.vertical {
|
||||
size := child.Size()
|
||||
minSize.Width = fyne.Max(size.Width, minSize.Width)
|
||||
minSize.Height += size.Height
|
||||
if addPadding {
|
||||
minSize.Height += theme.Padding()
|
||||
}
|
||||
}
|
||||
|
||||
addPadding = true
|
||||
}
|
||||
|
||||
return minSize
|
||||
}
|
22
cmd/v2/ui/formview/baseformview.go
Normal file
22
cmd/v2/ui/formview/baseformview.go
Normal file
@ -0,0 +1,22 @@
|
||||
package formview
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/lib/common"
|
||||
"go_dreamfactory/cmd/v2/service/observer"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
)
|
||||
|
||||
type BaseformView struct {
|
||||
form *widget.Form
|
||||
obs observer.Observer
|
||||
w fyne.Window
|
||||
}
|
||||
|
||||
func (this *BaseformView) Init(obs observer.Observer, w fyne.Window) {
|
||||
this.obs = obs
|
||||
this.w = w
|
||||
this.form = widget.NewForm()
|
||||
this.form.SubmitText = common.BUTTON_OK
|
||||
}
|
35
cmd/v2/ui/formview/bingoview.go
Normal file
35
cmd/v2/ui/formview/bingoview.go
Normal file
@ -0,0 +1,35 @@
|
||||
package formview
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/lib/common"
|
||||
"go_dreamfactory/cmd/v2/model"
|
||||
"go_dreamfactory/cmd/v2/service"
|
||||
"go_dreamfactory/pb"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
"github.com/sirupsen/logrus"
|
||||
)
|
||||
|
||||
type BingoView struct {
|
||||
BaseformView
|
||||
}
|
||||
|
||||
func (this *BingoView) CreateView(t *model.TestCase) fyne.CanvasObject {
|
||||
bingo := widget.NewEntry()
|
||||
bingo.PlaceHolder = "eg. bingo:item,10001,1"
|
||||
this.form.AppendItem(widget.NewFormItem(common.APP_TESTCASE_FORM_BINGO, bingo))
|
||||
this.form.OnSubmit = func() {
|
||||
if err := service.GetPttService().SendToClient(
|
||||
t.MainType,
|
||||
t.SubType,
|
||||
&pb.GMCmdReq{Cmod: bingo.Text},
|
||||
); err != nil {
|
||||
logrus.Error(err)
|
||||
return
|
||||
}
|
||||
|
||||
// go service.GetConnService().RespHandle(t)
|
||||
}
|
||||
return this.form
|
||||
}
|
29
cmd/v2/ui/formview/common.go
Normal file
29
cmd/v2/ui/formview/common.go
Normal file
@ -0,0 +1,29 @@
|
||||
package formview
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/lib/common"
|
||||
|
||||
"fyne.io/fyne/v2/widget"
|
||||
)
|
||||
|
||||
func getTaskTagSelect() *widget.Select {
|
||||
var tagSelect *widget.Select
|
||||
tagSelect = widget.NewSelect([]string{
|
||||
common.AAP_TESTCASE_FORM_TASK_DAY,
|
||||
common.APP_TESTCASE_FORM_TASK_WEEK,
|
||||
common.APP_TESTCASE_FORM_TASK_ACHIEVE}, func(s string) {
|
||||
switch s {
|
||||
case common.AAP_TESTCASE_FORM_TASK_DAY:
|
||||
tagSelect.Selected = "1"
|
||||
case common.APP_TESTCASE_FORM_TASK_WEEK:
|
||||
tagSelect.Selected = "2"
|
||||
case common.APP_TESTCASE_FORM_TASK_ACHIEVE:
|
||||
tagSelect.Selected = "3"
|
||||
default:
|
||||
tagSelect.Selected = "0"
|
||||
}
|
||||
|
||||
})
|
||||
tagSelect.SetSelectedIndex(0)
|
||||
return tagSelect
|
||||
}
|
33
cmd/v2/ui/formview/friend_addblack.go
Normal file
33
cmd/v2/ui/formview/friend_addblack.go
Normal file
@ -0,0 +1,33 @@
|
||||
package formview
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/lib/common"
|
||||
"go_dreamfactory/cmd/v2/model"
|
||||
"go_dreamfactory/cmd/v2/service"
|
||||
"go_dreamfactory/pb"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
"github.com/sirupsen/logrus"
|
||||
)
|
||||
|
||||
type FriendAddBlackView struct {
|
||||
BaseformView
|
||||
}
|
||||
|
||||
func (this *FriendAddBlackView) CreateView(t *model.TestCase) fyne.CanvasObject {
|
||||
friendId := widget.NewEntry()
|
||||
this.form.AppendItem(widget.NewFormItem(common.APP_TESTCASE_FORM_LABEL_FID, friendId))
|
||||
this.form.OnSubmit = func() {
|
||||
if err := service.GetPttService().SendToClient(
|
||||
t.MainType,
|
||||
t.SubType,
|
||||
&pb.FriendBlackAddReq{FriendId: friendId.Text},
|
||||
); err != nil {
|
||||
logrus.Error(err)
|
||||
return
|
||||
}
|
||||
|
||||
}
|
||||
return this.form
|
||||
}
|
91
cmd/v2/ui/formview/friend_agree.go
Normal file
91
cmd/v2/ui/formview/friend_agree.go
Normal file
@ -0,0 +1,91 @@
|
||||
package formview
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/model"
|
||||
"go_dreamfactory/cmd/v2/service"
|
||||
"go_dreamfactory/cmd/v2/service/observer"
|
||||
"go_dreamfactory/comm"
|
||||
"go_dreamfactory/modules/friend"
|
||||
"go_dreamfactory/pb"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/container"
|
||||
"fyne.io/fyne/v2/theme"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
"github.com/sirupsen/logrus"
|
||||
)
|
||||
|
||||
type FriendAgreeView struct {
|
||||
FriendListBaseView
|
||||
}
|
||||
|
||||
func (this *FriendAgreeView) CreateView(t *model.TestCase) fyne.CanvasObject {
|
||||
//init required
|
||||
this.initFriendList()
|
||||
|
||||
//同意提交
|
||||
agreeBtn := widget.NewButtonWithIcon("同意", theme.ConfirmIcon(), func() {
|
||||
if err := service.GetPttService().SendToClient(
|
||||
t.MainType,
|
||||
t.SubType,
|
||||
&pb.FriendAgreeReq{
|
||||
FriendIds: this.selFriendIds,
|
||||
},
|
||||
); err != nil {
|
||||
logrus.Error(err)
|
||||
return
|
||||
}
|
||||
this.applyListBtnFun()
|
||||
})
|
||||
|
||||
//拒绝
|
||||
refuseBtn := widget.NewButtonWithIcon("拒绝", theme.CancelIcon(), func() {
|
||||
if err := service.GetPttService().SendToClient(
|
||||
string(comm.ModuleFriend),
|
||||
friend.FriendSubTypeRefuse,
|
||||
&pb.FriendRefuseReq{
|
||||
FriendIds: this.selFriendIds,
|
||||
}); err != nil {
|
||||
logrus.Error(err)
|
||||
return
|
||||
}
|
||||
this.applyListBtnFun()
|
||||
})
|
||||
|
||||
this.createList()
|
||||
|
||||
applyListBtn := widget.NewButton("申请列表", this.applyListBtnFun())
|
||||
|
||||
split := container.NewHSplit(this.dataList, container.NewVBox(applyListBtn, agreeBtn, refuseBtn))
|
||||
split.Offset = 1
|
||||
|
||||
this.dataListener()
|
||||
return split
|
||||
}
|
||||
|
||||
// listener applyListdata
|
||||
func (this *FriendAgreeView) dataListener() {
|
||||
this.obs.AddListener(observer.EVENT_CASE_RSP, observer.Listener{
|
||||
OnNotify: func(d interface{}, args ...interface{}) {
|
||||
data := d.(*pb.UserMessage)
|
||||
if !(data.MainType == string(comm.ModuleFriend) &&
|
||||
data.SubType == friend.FriendSubTypeApplyList) {
|
||||
return
|
||||
}
|
||||
rsp := &pb.FriendApplyListResp{}
|
||||
|
||||
if !comm.ProtoUnmarshal(data, rsp) {
|
||||
logrus.Error("unmarshal err")
|
||||
}
|
||||
|
||||
for _, v := range rsp.List {
|
||||
fm := &model.FriendModel{
|
||||
Uid: v.UserId,
|
||||
Name: v.NickName,
|
||||
}
|
||||
this.friendData.DataList = append(this.friendData.DataList, fm)
|
||||
}
|
||||
this.reloadFriendData()
|
||||
},
|
||||
})
|
||||
}
|
31
cmd/v2/ui/formview/friend_apply.go
Normal file
31
cmd/v2/ui/formview/friend_apply.go
Normal file
@ -0,0 +1,31 @@
|
||||
package formview
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/lib/common"
|
||||
"go_dreamfactory/cmd/v2/model"
|
||||
"go_dreamfactory/cmd/v2/service"
|
||||
"go_dreamfactory/pb"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
"github.com/sirupsen/logrus"
|
||||
)
|
||||
|
||||
type FriendApplyView struct {
|
||||
BaseformView
|
||||
}
|
||||
|
||||
func (this *FriendApplyView) CreateView(t *model.TestCase) fyne.CanvasObject {
|
||||
friendId := widget.NewEntry()
|
||||
this.form.AppendItem(widget.NewFormItem(common.APP_TESTCASE_FORM_LABEL_FID, friendId))
|
||||
|
||||
this.form.OnSubmit = func() {
|
||||
if err := service.GetPttService().SendToClient(t.MainType, t.SubType, &pb.FriendApplyReq{
|
||||
FriendId: friendId.Text,
|
||||
}); err != nil {
|
||||
logrus.Error(err)
|
||||
}
|
||||
|
||||
}
|
||||
return this.form
|
||||
}
|
24
cmd/v2/ui/formview/friend_applylist.go
Normal file
24
cmd/v2/ui/formview/friend_applylist.go
Normal file
@ -0,0 +1,24 @@
|
||||
package formview
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/model"
|
||||
"go_dreamfactory/cmd/v2/service"
|
||||
"go_dreamfactory/pb"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"github.com/sirupsen/logrus"
|
||||
)
|
||||
|
||||
type FriendApplyListView struct {
|
||||
BaseformView
|
||||
}
|
||||
|
||||
func (this *FriendApplyListView) CreateView(t *model.TestCase) fyne.CanvasObject {
|
||||
this.form.OnSubmit = func() {
|
||||
if err := service.GetPttService().SendToClient(t.MainType, t.SubType, &pb.FriendApplyListReq{}); err != nil {
|
||||
logrus.Error(err)
|
||||
}
|
||||
|
||||
}
|
||||
return this.form
|
||||
}
|
75
cmd/v2/ui/formview/friend_base.go
Normal file
75
cmd/v2/ui/formview/friend_base.go
Normal file
@ -0,0 +1,75 @@
|
||||
package formview
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/model"
|
||||
"go_dreamfactory/cmd/v2/service"
|
||||
"go_dreamfactory/comm"
|
||||
"go_dreamfactory/modules/friend"
|
||||
"go_dreamfactory/pb"
|
||||
"go_dreamfactory/utils"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/container"
|
||||
"fyne.io/fyne/v2/data/binding"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
"github.com/sirupsen/logrus"
|
||||
)
|
||||
|
||||
type FriendListBaseView struct {
|
||||
BaseformView
|
||||
dataList *widget.List
|
||||
friendBinding binding.UntypedList
|
||||
selFriendIds []string //选择的UID
|
||||
friendData *model.FriendModelList
|
||||
}
|
||||
|
||||
// init data
|
||||
func (this *FriendListBaseView) initFriendList() {
|
||||
this.friendBinding = binding.NewUntypedList()
|
||||
this.friendData = model.NewFriendModelList()
|
||||
}
|
||||
|
||||
// create list view
|
||||
func (this *FriendListBaseView) createList() *widget.List {
|
||||
this.dataList = widget.NewListWithData(this.friendBinding,
|
||||
func() fyne.CanvasObject {
|
||||
return container.NewHBox(
|
||||
widget.NewCheck("", func(b bool) {}),
|
||||
widget.NewLabelWithStyle("", fyne.TextAlignCenter, fyne.TextStyle{}),
|
||||
)
|
||||
},
|
||||
func(data binding.DataItem, item fyne.CanvasObject) {
|
||||
o, _ := data.(binding.Untyped).Get()
|
||||
pd := o.(*model.FriendModel)
|
||||
item.(*fyne.Container).Objects[0].(*widget.Check).OnChanged = func(b bool) {
|
||||
if b {
|
||||
this.selFriendIds = append(this.selFriendIds, pd.Uid)
|
||||
} else {
|
||||
utils.DeleteString(this.selFriendIds, pd.Uid)
|
||||
}
|
||||
}
|
||||
item.(*fyne.Container).Objects[1].(*widget.Label).SetText(pd.Name)
|
||||
},
|
||||
)
|
||||
return this.dataList
|
||||
}
|
||||
|
||||
func (this *FriendListBaseView) applyListBtnFun() func() {
|
||||
return func() {
|
||||
if err := service.GetPttService().SendToClient(
|
||||
string(comm.ModuleFriend),
|
||||
friend.FriendSubTypeApplyList,
|
||||
&pb.FriendApplyListReq{}); err != nil {
|
||||
logrus.Error(err)
|
||||
}
|
||||
this.friendData = model.NewFriendModelList()
|
||||
}
|
||||
}
|
||||
|
||||
// set data
|
||||
func (this *FriendListBaseView) reloadFriendData() {
|
||||
if this.friendData != nil {
|
||||
d := this.friendData.AsInterfaceArray()
|
||||
this.friendBinding.Set(d)
|
||||
}
|
||||
}
|
72
cmd/v2/ui/formview/friend_blacklist.go
Normal file
72
cmd/v2/ui/formview/friend_blacklist.go
Normal file
@ -0,0 +1,72 @@
|
||||
package formview
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/model"
|
||||
"go_dreamfactory/cmd/v2/service"
|
||||
"go_dreamfactory/cmd/v2/service/observer"
|
||||
"go_dreamfactory/comm"
|
||||
"go_dreamfactory/modules/friend"
|
||||
"go_dreamfactory/pb"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/container"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
"github.com/sirupsen/logrus"
|
||||
)
|
||||
|
||||
type FriendBlacklistView struct {
|
||||
FriendListBaseView
|
||||
}
|
||||
|
||||
func (this *FriendBlacklistView) CreateView(t *model.TestCase) fyne.CanvasObject {
|
||||
// init required
|
||||
this.initFriendList()
|
||||
// create friend list view
|
||||
this.createList()
|
||||
|
||||
friendList := func() {
|
||||
if err := service.GetPttService().SendToClient(
|
||||
string(comm.ModuleFriend),
|
||||
friend.FriendSubTypeBlacklist,
|
||||
&pb.FriendBlackListReq{}); err != nil {
|
||||
logrus.Error(err)
|
||||
}
|
||||
this.friendData = model.NewFriendModelList()
|
||||
}
|
||||
friendListBtn := widget.NewButton("黑名单列表", friendList)
|
||||
|
||||
// layout
|
||||
split := container.NewHSplit(this.dataList, container.NewVBox(friendListBtn))
|
||||
split.Offset = 1
|
||||
|
||||
//data listener for
|
||||
this.dataListener()
|
||||
|
||||
return split
|
||||
}
|
||||
|
||||
func (this *FriendBlacklistView) dataListener() {
|
||||
this.obs.AddListener(observer.EVENT_CASE_RSP, observer.Listener{
|
||||
OnNotify: func(d interface{}, args ...interface{}) {
|
||||
data := d.(*pb.UserMessage)
|
||||
if !(data.MainType == string(comm.ModuleFriend) &&
|
||||
data.SubType == friend.FriendSubTypeBlacklist) {
|
||||
return
|
||||
}
|
||||
rsp := &pb.FriendBlackListResp{}
|
||||
|
||||
if !comm.ProtoUnmarshal(data, rsp) {
|
||||
logrus.Error("unmarshal err")
|
||||
}
|
||||
|
||||
for _, v := range rsp.Friends {
|
||||
fm := &model.FriendModel{
|
||||
Uid: v.UserId,
|
||||
Name: v.NickName,
|
||||
}
|
||||
this.friendData.DataList = append(this.friendData.DataList, fm)
|
||||
}
|
||||
this.reloadFriendData()
|
||||
},
|
||||
})
|
||||
}
|
33
cmd/v2/ui/formview/friend_delblack.go
Normal file
33
cmd/v2/ui/formview/friend_delblack.go
Normal file
@ -0,0 +1,33 @@
|
||||
package formview
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/lib/common"
|
||||
"go_dreamfactory/cmd/v2/model"
|
||||
"go_dreamfactory/cmd/v2/service"
|
||||
"go_dreamfactory/pb"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
"github.com/sirupsen/logrus"
|
||||
)
|
||||
|
||||
type FriendDelblackView struct {
|
||||
BaseformView
|
||||
}
|
||||
|
||||
func (this *FriendDelblackView) CreateView(t *model.TestCase) fyne.CanvasObject {
|
||||
friendId := widget.NewEntry()
|
||||
this.form.AppendItem(widget.NewFormItem(common.APP_TESTCASE_FORM_LABEL_FID, friendId))
|
||||
this.form.OnSubmit = func() {
|
||||
if err := service.GetPttService().SendToClient(
|
||||
t.MainType,
|
||||
t.SubType,
|
||||
&pb.FriendDelBlackReq{FriendId: friendId.Text},
|
||||
); err != nil {
|
||||
logrus.Error(err)
|
||||
return
|
||||
}
|
||||
|
||||
}
|
||||
return this.form
|
||||
}
|
74
cmd/v2/ui/formview/friend_list.go
Normal file
74
cmd/v2/ui/formview/friend_list.go
Normal file
@ -0,0 +1,74 @@
|
||||
package formview
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/model"
|
||||
"go_dreamfactory/cmd/v2/service"
|
||||
"go_dreamfactory/cmd/v2/service/observer"
|
||||
"go_dreamfactory/comm"
|
||||
"go_dreamfactory/modules/friend"
|
||||
"go_dreamfactory/pb"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/container"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
"github.com/sirupsen/logrus"
|
||||
)
|
||||
|
||||
//好友列表
|
||||
type FriendListView struct {
|
||||
FriendListBaseView //继承支持好友列表的基类
|
||||
}
|
||||
|
||||
func (this *FriendListView) CreateView(t *model.TestCase) fyne.CanvasObject {
|
||||
// init required
|
||||
this.initFriendList()
|
||||
|
||||
// create friend list view
|
||||
this.createList()
|
||||
|
||||
// new friendlist btn
|
||||
friendList := func() {
|
||||
if err := service.GetPttService().SendToClient(
|
||||
string(comm.ModuleFriend),
|
||||
friend.FriendSubTypeList,
|
||||
&pb.FriendListReq{}); err != nil {
|
||||
logrus.Error(err)
|
||||
}
|
||||
this.friendData = model.NewFriendModelList()
|
||||
}
|
||||
friendListBtn := widget.NewButton("好友列表", friendList)
|
||||
|
||||
// layout
|
||||
split := container.NewHSplit(this.dataList, container.NewVBox(friendListBtn))
|
||||
split.Offset = 1
|
||||
|
||||
//data listener for
|
||||
this.dataListener()
|
||||
return split
|
||||
}
|
||||
|
||||
func (this *FriendListView) dataListener() {
|
||||
this.obs.AddListener(observer.EVENT_CASE_RSP, observer.Listener{
|
||||
OnNotify: func(d interface{}, args ...interface{}) {
|
||||
data := d.(*pb.UserMessage)
|
||||
if !(data.MainType == string(comm.ModuleFriend) &&
|
||||
data.SubType == friend.FriendSubTypeList) {
|
||||
return
|
||||
}
|
||||
rsp := &pb.FriendListResp{}
|
||||
|
||||
if !comm.ProtoUnmarshal(data, rsp) {
|
||||
logrus.Error("unmarshal err")
|
||||
}
|
||||
|
||||
for _, v := range rsp.List {
|
||||
fm := &model.FriendModel{
|
||||
Uid: v.UserId,
|
||||
Name: v.NickName,
|
||||
}
|
||||
this.friendData.DataList = append(this.friendData.DataList, fm)
|
||||
}
|
||||
this.reloadFriendData()
|
||||
},
|
||||
})
|
||||
}
|
29
cmd/v2/ui/formview/friend_refuse.go
Normal file
29
cmd/v2/ui/formview/friend_refuse.go
Normal file
@ -0,0 +1,29 @@
|
||||
package formview
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/model"
|
||||
"go_dreamfactory/cmd/v2/service"
|
||||
"go_dreamfactory/pb"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"github.com/sirupsen/logrus"
|
||||
)
|
||||
|
||||
type FriendRefuseView struct {
|
||||
BaseformView
|
||||
}
|
||||
|
||||
func (this *FriendRefuseView) CreateView(t *model.TestCase) fyne.CanvasObject {
|
||||
this.form.OnSubmit = func() {
|
||||
if err := service.GetPttService().SendToClient(
|
||||
t.MainType,
|
||||
t.SubType,
|
||||
&pb.FriendRefuseReq{},
|
||||
); err != nil {
|
||||
logrus.Error(err)
|
||||
return
|
||||
}
|
||||
|
||||
}
|
||||
return this.form
|
||||
}
|
32
cmd/v2/ui/formview/friend_search.go
Normal file
32
cmd/v2/ui/formview/friend_search.go
Normal file
@ -0,0 +1,32 @@
|
||||
package formview
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/lib/common"
|
||||
"go_dreamfactory/cmd/v2/model"
|
||||
"go_dreamfactory/cmd/v2/service"
|
||||
"go_dreamfactory/pb"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
"github.com/sirupsen/logrus"
|
||||
)
|
||||
|
||||
type FriendSearchView struct {
|
||||
BaseformView
|
||||
}
|
||||
|
||||
func (this *FriendSearchView) CreateView(t *model.TestCase) fyne.CanvasObject {
|
||||
name := widget.NewEntry()
|
||||
this.form.AppendItem(widget.NewFormItem(common.APP_TESTCASE_FORM_NICKNAME, name))
|
||||
this.form.OnSubmit = func() {
|
||||
if err := service.GetPttService().SendToClient(
|
||||
t.MainType,
|
||||
t.SubType,
|
||||
&pb.FriendSearchReq{NickName: name.Text},
|
||||
); err != nil {
|
||||
logrus.Error(err)
|
||||
return
|
||||
}
|
||||
}
|
||||
return this.form
|
||||
}
|
24
cmd/v2/ui/formview/hero_list.go
Normal file
24
cmd/v2/ui/formview/hero_list.go
Normal file
@ -0,0 +1,24 @@
|
||||
package formview
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/model"
|
||||
"go_dreamfactory/cmd/v2/service"
|
||||
"go_dreamfactory/pb"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"github.com/sirupsen/logrus"
|
||||
)
|
||||
|
||||
type HeroListView struct {
|
||||
BaseformView
|
||||
}
|
||||
|
||||
func (this *HeroListView) CreateView(t *model.TestCase) fyne.CanvasObject {
|
||||
this.form.OnSubmit = func() {
|
||||
if err := service.GetPttService().SendToClient(t.MainType, t.SubType, &pb.HeroListReq{}); err != nil {
|
||||
logrus.Error(err)
|
||||
}
|
||||
|
||||
}
|
||||
return this.form
|
||||
}
|
96
cmd/v2/ui/formview/hero_strengthenUpStar.go
Normal file
96
cmd/v2/ui/formview/hero_strengthenUpStar.go
Normal file
@ -0,0 +1,96 @@
|
||||
package formview
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/lib/common"
|
||||
"go_dreamfactory/cmd/v2/model"
|
||||
"go_dreamfactory/cmd/v2/service"
|
||||
"go_dreamfactory/pb"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/container"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
"github.com/sirupsen/logrus"
|
||||
"github.com/spf13/cast"
|
||||
)
|
||||
|
||||
type HeroStrengthenUpStarView struct {
|
||||
BaseformView
|
||||
}
|
||||
|
||||
func (this *HeroStrengthenUpStarView) CreateView(t *model.TestCase) fyne.CanvasObject {
|
||||
heroObjID := widget.NewEntry()
|
||||
//HeroRace
|
||||
heroRaceId := widget.NewEntry()
|
||||
heroRaceId.PlaceHolder = common.APP_TESTCASE_FORM_LABEL_OID
|
||||
heroRaceAmount := widget.NewEntry()
|
||||
heroRaceAmount.PlaceHolder = common.APP_TESTCASE_FORM_LABEL_NUM
|
||||
|
||||
heroRaceId2 := widget.NewEntry()
|
||||
heroRaceId2.PlaceHolder = common.APP_TESTCASE_OPTIONS
|
||||
heroRaceAmount2 := widget.NewEntry()
|
||||
heroRaceAmount2.PlaceHolder = common.APP_TESTCASE_OPTIONS
|
||||
|
||||
//Hero
|
||||
heroId := widget.NewEntry()
|
||||
heroId.PlaceHolder = common.APP_TESTCASE_FORM_LABEL_OID
|
||||
heroAmount := widget.NewEntry()
|
||||
heroAmount.PlaceHolder = common.APP_TESTCASE_FORM_LABEL_NUM
|
||||
|
||||
heroId2 := widget.NewEntry()
|
||||
heroId2.PlaceHolder = common.APP_TESTCASE_OPTIONS
|
||||
heroAmount2 := widget.NewEntry()
|
||||
heroAmount2.PlaceHolder = common.APP_TESTCASE_OPTIONS
|
||||
|
||||
heroRace := container.NewGridWithColumns(2, heroRaceId, heroRaceAmount, heroRaceId2, heroRaceAmount2)
|
||||
hero := container.NewGridWithColumns(2, heroId, heroAmount, heroId2, heroAmount2)
|
||||
|
||||
this.form.AppendItem(widget.NewFormItem(common.APP_TESTCASE_FORM_LABEL_HEROOBJID, heroObjID))
|
||||
this.form.AppendItem(widget.NewFormItem(common.APP_TESTCASE_FORM_LABEL_RACECARD, heroRace))
|
||||
this.form.AppendItem(widget.NewFormItem(common.APP_TESTCASE_FORM_LABEL_CARD, hero))
|
||||
|
||||
this.form.OnSubmit = func() {
|
||||
// heroRace
|
||||
var heroRace []*pb.CostCardData
|
||||
if heroRaceId.Text != "" && heroRaceAmount.Text != "" {
|
||||
heroRace = append(heroRace, &pb.CostCardData{
|
||||
CostCardObj: heroRaceId.Text,
|
||||
Amount: cast.ToInt32(heroRaceAmount.Text),
|
||||
})
|
||||
}
|
||||
|
||||
if heroRaceId2.Text != "" && heroRaceAmount2.Text != "" {
|
||||
heroRace = append(heroRace, &pb.CostCardData{
|
||||
CostCardObj: heroRaceId2.Text,
|
||||
Amount: cast.ToInt32(heroRaceAmount2.Text),
|
||||
})
|
||||
}
|
||||
|
||||
//hero
|
||||
var hero []*pb.CostCardData
|
||||
if heroId.Text != "" && heroAmount.Text != "" {
|
||||
hero = append(hero, &pb.CostCardData{
|
||||
CostCardObj: heroId.Text,
|
||||
Amount: cast.ToInt32(heroAmount.Text),
|
||||
})
|
||||
}
|
||||
|
||||
if heroId2.Text != "" && heroAmount2.Text != "" {
|
||||
hero = append(hero, &pb.CostCardData{
|
||||
CostCardObj: heroId2.Text,
|
||||
Amount: cast.ToInt32(heroAmount2.Text),
|
||||
})
|
||||
}
|
||||
|
||||
if err := service.GetPttService().SendToClient(t.MainType, t.SubType,
|
||||
&pb.HeroStrengthenUpStarReq{
|
||||
HeroObjID: heroObjID.Text,
|
||||
HeroRace: heroRace,
|
||||
Hero: hero,
|
||||
}); err != nil {
|
||||
logrus.Error(err)
|
||||
return
|
||||
}
|
||||
|
||||
}
|
||||
return this.form
|
||||
}
|
66
cmd/v2/ui/formview/hero_strengthenUplv.go
Normal file
66
cmd/v2/ui/formview/hero_strengthenUplv.go
Normal file
@ -0,0 +1,66 @@
|
||||
package formview
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/lib/common"
|
||||
"go_dreamfactory/cmd/v2/model"
|
||||
"go_dreamfactory/cmd/v2/service"
|
||||
"go_dreamfactory/pb"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/container"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
"github.com/sirupsen/logrus"
|
||||
"github.com/spf13/cast"
|
||||
)
|
||||
|
||||
type HeroStrengthenUplvView struct {
|
||||
BaseformView
|
||||
}
|
||||
|
||||
func (this *HeroStrengthenUplvView) CreateView(t *model.TestCase) fyne.CanvasObject {
|
||||
|
||||
heroObjID := widget.NewEntry()
|
||||
|
||||
key := widget.NewEntry()
|
||||
key.PlaceHolder = common.APP_TESTCASE_FORM_LABEL_OID
|
||||
val := widget.NewEntry()
|
||||
val.PlaceHolder = common.APP_TESTCASE_FORM_LABEL_NUM
|
||||
|
||||
key2 := widget.NewEntry()
|
||||
key2.PlaceHolder = common.APP_TESTCASE_OPTIONS
|
||||
val2 := widget.NewEntry()
|
||||
val2.PlaceHolder = common.APP_TESTCASE_OPTIONS
|
||||
|
||||
expCards := container.NewGridWithColumns(2, key, val, key2, val2)
|
||||
|
||||
this.form.AppendItem(widget.NewFormItem(common.APP_TESTCASE_FORM_LABEL_HEROOBJID, heroObjID))
|
||||
this.form.AppendItem(widget.NewFormItem(common.APP_TESTCASE_FORM_LABEL_EXPCARDS, expCards))
|
||||
|
||||
this.form.OnSubmit = func() {
|
||||
var cards []*pb.MapStringInt32
|
||||
|
||||
if key.Text != "" && val.Text != "" {
|
||||
cards = append(cards, &pb.MapStringInt32{
|
||||
Key: key.Text,
|
||||
Value: cast.ToInt32(val.Text),
|
||||
})
|
||||
}
|
||||
|
||||
if key2.Text != "" && val2.Text != "" {
|
||||
cards = append(cards, &pb.MapStringInt32{
|
||||
Key: key2.Text,
|
||||
Value: cast.ToInt32(val2.Text),
|
||||
})
|
||||
}
|
||||
|
||||
if err := service.GetPttService().SendToClient(t.MainType, t.SubType,
|
||||
&pb.HeroStrengthenUplvReq{
|
||||
HeroObjID: heroObjID.Text,
|
||||
ExpCards: cards}); err != nil {
|
||||
logrus.Error(err)
|
||||
return
|
||||
}
|
||||
|
||||
}
|
||||
return this.form
|
||||
}
|
32
cmd/v2/ui/formview/task_activelist.go
Normal file
32
cmd/v2/ui/formview/task_activelist.go
Normal file
@ -0,0 +1,32 @@
|
||||
package formview
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/lib/common"
|
||||
"go_dreamfactory/cmd/v2/model"
|
||||
"go_dreamfactory/cmd/v2/service"
|
||||
"go_dreamfactory/pb"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
"github.com/sirupsen/logrus"
|
||||
"github.com/spf13/cast"
|
||||
)
|
||||
|
||||
type TaskActiveListView struct {
|
||||
BaseformView
|
||||
}
|
||||
|
||||
func (this *TaskActiveListView) CreateView(t *model.TestCase) fyne.CanvasObject {
|
||||
tagSelect := getTaskTagSelect()
|
||||
this.form.AppendItem(widget.NewFormItem(common.APP_TESTCASE_FORM_TASKTAG, tagSelect))
|
||||
|
||||
this.form.OnSubmit = func() {
|
||||
if err := service.GetPttService().SendToClient(t.MainType, t.SubType, &pb.TaskActiveListReq{
|
||||
|
||||
TaskTag: cast.ToInt32(tagSelect.Selected),
|
||||
}); err != nil {
|
||||
logrus.Error(err)
|
||||
}
|
||||
}
|
||||
return this.form
|
||||
}
|
36
cmd/v2/ui/formview/task_activereceive.go
Normal file
36
cmd/v2/ui/formview/task_activereceive.go
Normal file
@ -0,0 +1,36 @@
|
||||
package formview
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/lib/common"
|
||||
"go_dreamfactory/cmd/v2/model"
|
||||
"go_dreamfactory/cmd/v2/service"
|
||||
"go_dreamfactory/pb"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
"github.com/sirupsen/logrus"
|
||||
"github.com/spf13/cast"
|
||||
)
|
||||
|
||||
type TaskActiveReceiveView struct {
|
||||
BaseformView
|
||||
}
|
||||
|
||||
func (this *TaskActiveReceiveView) CreateView(t *model.TestCase) fyne.CanvasObject {
|
||||
id := widget.NewEntry()
|
||||
tagSelect := getTaskTagSelect()
|
||||
|
||||
this.form.AppendItem(widget.NewFormItem(common.APP_TESTCASE_FORM_TASK_OID, id))
|
||||
this.form.AppendItem(widget.NewFormItem(common.APP_TESTCASE_FORM_TASKTAG, tagSelect))
|
||||
|
||||
this.form.OnSubmit = func() {
|
||||
if err := service.GetPttService().SendToClient(t.MainType, t.SubType, &pb.TaskActiveReceiveReq{
|
||||
Id: id.Text,
|
||||
TaskTag: cast.ToInt32(tagSelect.Selected),
|
||||
}); err != nil {
|
||||
logrus.Error(err)
|
||||
}
|
||||
|
||||
}
|
||||
return this.form
|
||||
}
|
31
cmd/v2/ui/formview/task_list.go
Normal file
31
cmd/v2/ui/formview/task_list.go
Normal file
@ -0,0 +1,31 @@
|
||||
package formview
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/lib/common"
|
||||
"go_dreamfactory/cmd/v2/model"
|
||||
"go_dreamfactory/cmd/v2/service"
|
||||
"go_dreamfactory/pb"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
"github.com/sirupsen/logrus"
|
||||
"github.com/spf13/cast"
|
||||
)
|
||||
|
||||
type TaskListView struct {
|
||||
BaseformView
|
||||
}
|
||||
|
||||
func (this *TaskListView) CreateView(t *model.TestCase) fyne.CanvasObject {
|
||||
tagSelect := getTaskTagSelect()
|
||||
this.form.AppendItem(widget.NewFormItem(common.APP_TESTCASE_FORM_TASKTAG, tagSelect))
|
||||
|
||||
this.form.OnSubmit = func() {
|
||||
if err := service.GetPttService().SendToClient(t.MainType, t.SubType, &pb.TaskListReq{
|
||||
TaskTag: cast.ToInt32(tagSelect.Selected),
|
||||
}); err != nil {
|
||||
logrus.Error(err)
|
||||
}
|
||||
}
|
||||
return this.form
|
||||
}
|
40
cmd/v2/ui/formview/task_receive.go
Normal file
40
cmd/v2/ui/formview/task_receive.go
Normal file
@ -0,0 +1,40 @@
|
||||
package formview
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/lib/common"
|
||||
"go_dreamfactory/cmd/v2/model"
|
||||
"go_dreamfactory/cmd/v2/service"
|
||||
"go_dreamfactory/comm"
|
||||
"go_dreamfactory/modules/task"
|
||||
"go_dreamfactory/pb"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
"github.com/sirupsen/logrus"
|
||||
"github.com/spf13/cast"
|
||||
)
|
||||
|
||||
type TaskReceiveView struct {
|
||||
BaseformView
|
||||
}
|
||||
|
||||
func (this *TaskReceiveView) CreateView(t *model.TestCase) fyne.CanvasObject {
|
||||
|
||||
if t.MainType == string(comm.ModuleTask) && t.SubType == task.TaskSubTypeReceive {
|
||||
id := widget.NewEntry()
|
||||
tagSelect := getTaskTagSelect()
|
||||
this.form.AppendItem(widget.NewFormItem(common.APP_TESTCASE_FORM_TASK_OID, id))
|
||||
this.form.AppendItem(widget.NewFormItem(common.APP_TESTCASE_FORM_TASKTAG, tagSelect))
|
||||
|
||||
this.form.OnSubmit = func() {
|
||||
if err := service.GetPttService().SendToClient(t.MainType, t.SubType,
|
||||
&pb.TaskReceiveReq{Id: id.Text, TaskTag: cast.ToInt32(tagSelect.Selected)}); err != nil {
|
||||
logrus.Error(err)
|
||||
return
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
return this.form
|
||||
}
|
35
cmd/v2/ui/formview/user_modifyname.go
Normal file
35
cmd/v2/ui/formview/user_modifyname.go
Normal file
@ -0,0 +1,35 @@
|
||||
package formview
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/lib/common"
|
||||
"go_dreamfactory/cmd/v2/model"
|
||||
"go_dreamfactory/cmd/v2/service"
|
||||
"go_dreamfactory/pb"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
"github.com/sirupsen/logrus"
|
||||
)
|
||||
|
||||
type UserModifynameView struct {
|
||||
BaseformView
|
||||
}
|
||||
|
||||
func (this *UserModifynameView) CreateView(t *model.TestCase) fyne.CanvasObject {
|
||||
name := widget.NewEntry()
|
||||
this.form.AppendItem(widget.NewFormItem(common.APP_TESTCASE_FORM_NICKNAME, name))
|
||||
|
||||
this.form.OnSubmit = func() {
|
||||
if err := service.GetPttService().SendToClient(
|
||||
t.MainType,
|
||||
t.SubType,
|
||||
&pb.UserModifynameReq{Name: name.Text},
|
||||
); err != nil {
|
||||
logrus.Error(err)
|
||||
return
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
return this.form
|
||||
}
|
49
cmd/v2/ui/log_viewer.go
Normal file
49
cmd/v2/ui/log_viewer.go
Normal file
@ -0,0 +1,49 @@
|
||||
package ui
|
||||
|
||||
import (
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/container"
|
||||
"fyne.io/fyne/v2/layout"
|
||||
"fyne.io/fyne/v2/theme"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
)
|
||||
|
||||
type logViewer struct {
|
||||
logArea *widget.Entry
|
||||
refresh *widget.Button
|
||||
|
||||
Win fyne.Window
|
||||
}
|
||||
|
||||
func newLogViewer() *logViewer {
|
||||
var lv logViewer
|
||||
|
||||
lv.logArea = widget.NewMultiLineEntry()
|
||||
lv.logArea.Disable()
|
||||
lv.logArea.Wrapping = fyne.TextWrapBreak
|
||||
|
||||
// lv.initLogContent()
|
||||
|
||||
lv.refresh = widget.NewButtonWithIcon(string(theme.ColorNameFocus), theme.ViewRefreshIcon(), func() {
|
||||
// lv.initLogContent()
|
||||
})
|
||||
|
||||
lv.Win = fyne.CurrentApp().NewWindow("Show Log")
|
||||
lv.Win.SetContent(container.NewBorder(
|
||||
container.NewHBox(layout.NewSpacer(), lv.refresh), nil, nil, nil,
|
||||
lv.logArea))
|
||||
lv.Win.Resize(fyne.NewSize(800, 600))
|
||||
lv.Win.CenterOnScreen()
|
||||
|
||||
return &lv
|
||||
}
|
||||
|
||||
// func (lv *logViewer) initLogContent() {
|
||||
// cont := ""
|
||||
// globalLogWriter.Traversal(func(s string) {
|
||||
// cont += s
|
||||
// })
|
||||
|
||||
// lv.logArea.CursorRow = globalLogWriter.Size()
|
||||
// lv.logArea.SetText(cont)
|
||||
// }
|
31
cmd/v2/ui/main_menu.go
Normal file
31
cmd/v2/ui/main_menu.go
Normal file
@ -0,0 +1,31 @@
|
||||
package ui
|
||||
|
||||
import (
|
||||
"fyne.io/fyne/v2"
|
||||
)
|
||||
|
||||
type mainMenu struct {
|
||||
*fyne.MainMenu
|
||||
|
||||
helpMenu *fyne.Menu
|
||||
sysLog *fyne.MenuItem
|
||||
// aboutSelf *fyne.MenuItem
|
||||
}
|
||||
|
||||
func newMainMenu() *mainMenu {
|
||||
var mm mainMenu
|
||||
|
||||
// help
|
||||
mm.sysLog = fyne.NewMenuItem("Show Log", func() {
|
||||
newLogViewer().Win.Show()
|
||||
})
|
||||
mm.helpMenu = fyne.NewMenu("Help",
|
||||
mm.sysLog,
|
||||
// mm.aboutSelf,
|
||||
)
|
||||
|
||||
mm.MainMenu = fyne.NewMainMenu(
|
||||
mm.helpMenu,
|
||||
)
|
||||
return &mm
|
||||
}
|
310
cmd/v2/ui/mainwindow.go
Normal file
310
cmd/v2/ui/mainwindow.go
Normal file
@ -0,0 +1,310 @@
|
||||
package ui
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"go_dreamfactory/cmd/v2/lib/common"
|
||||
"go_dreamfactory/cmd/v2/service"
|
||||
"go_dreamfactory/cmd/v2/service/observer"
|
||||
"go_dreamfactory/pb"
|
||||
"strings"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/container"
|
||||
"fyne.io/fyne/v2/dialog"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
"github.com/BabySid/gobase"
|
||||
"github.com/Pallinder/go-randomdata"
|
||||
"github.com/sirupsen/logrus"
|
||||
"github.com/spf13/cast"
|
||||
)
|
||||
|
||||
var (
|
||||
globalWin *MainWindowImpl
|
||||
)
|
||||
|
||||
type MainWindow interface {
|
||||
WindowInterface
|
||||
}
|
||||
|
||||
type MainWindowImpl struct {
|
||||
UIImpl
|
||||
WindowDefaultOptions
|
||||
w fyne.Window
|
||||
mm *mainMenu
|
||||
tb *toolBar //工具条
|
||||
toys *toys // side
|
||||
sb *statusBar //状态栏
|
||||
at *appContainer //tabs
|
||||
}
|
||||
|
||||
func NewMainWindow(ui *UIImpl) MainWindow {
|
||||
gobase.NewScheduler().Start()
|
||||
gobase.RegisterAtExit(gobase.GlobalScheduler.Stop)
|
||||
mw := &MainWindowImpl{
|
||||
UIImpl: *ui,
|
||||
}
|
||||
|
||||
// main menu
|
||||
// mw.mm = newMainMenu()
|
||||
// mw.w.SetMainMenu(mw.mm.MainMenu)
|
||||
|
||||
// status bar
|
||||
mw.sb = newStatusBar()
|
||||
|
||||
// tool bar
|
||||
mw.tb = newToolBar()
|
||||
|
||||
// main app tabs
|
||||
mw.at = newAppContainer(ui.obs)
|
||||
|
||||
globalWin = mw
|
||||
|
||||
ui.obs.AddListener(observer.EVENT_PING, observer.Listener{
|
||||
OnNotify: func(data interface{}, args ...interface{}) {
|
||||
dialog.NewConfirm("链接中断", data.(error).Error(), func(
|
||||
b bool) {
|
||||
if b {
|
||||
globalWin.w.Close()
|
||||
} else {
|
||||
dialog.NewInformation("提示", "重启登录", globalWin.w)
|
||||
return
|
||||
}
|
||||
}, globalWin.w).Show()
|
||||
},
|
||||
})
|
||||
return mw
|
||||
}
|
||||
|
||||
func GetGlobalWin() *MainWindowImpl {
|
||||
return globalWin
|
||||
}
|
||||
|
||||
// createWindowContainer create a container with the window content
|
||||
func (ui *MainWindowImpl) createWindowContainer() {
|
||||
// create main layout
|
||||
|
||||
// status bar
|
||||
ui.sb = newStatusBar()
|
||||
|
||||
// tool bar
|
||||
ui.tb = newToolBar()
|
||||
|
||||
// Fun Toys
|
||||
ui.toys = newToys(ui.obs)
|
||||
|
||||
// main app tabs
|
||||
ui.at = newAppContainer(ui.obs)
|
||||
content := container.NewBorder(ui.tb.toolbar, ui.sb.widget, nil, ui.toys.widget, ui.at)
|
||||
ui.w.SetContent(content)
|
||||
ui.w.SetCloseIntercept(ui.quiteHandle)
|
||||
}
|
||||
|
||||
func (ui *MainWindowImpl) SetStatusMsg(msg string) {
|
||||
ui.sb.setMessage(fmt.Sprintf("err:%s", msg))
|
||||
}
|
||||
|
||||
func (ui *MainWindowImpl) quiteHandle() {
|
||||
ui.w.Close()
|
||||
}
|
||||
|
||||
// CreateWindow ....
|
||||
func (ui *MainWindowImpl) CreateWindow(title string, width, height float32, _ bool) {
|
||||
// init window
|
||||
w := ui.app.NewWindow(title)
|
||||
ui.AddWindow("main", w)
|
||||
ui.w = w
|
||||
|
||||
if ui.windowAspect == common.WindowAspect_FullScreen {
|
||||
w.SetFullScreen(true)
|
||||
} else {
|
||||
w.Resize(fyne.NewSize(width, height))
|
||||
}
|
||||
|
||||
// create main window menu
|
||||
// ui.mm = newMainMenu()
|
||||
// w.SetMainMenu(ui.mm.MainMenu)
|
||||
|
||||
// create window container
|
||||
// mainLayout := ui.createWindowContainer()
|
||||
|
||||
w.SetMaster()
|
||||
// w.Show()
|
||||
// w.SetContent(mainLayout)
|
||||
w.CenterOnScreen()
|
||||
_ = ui.createChooseServerPopUp(w)
|
||||
}
|
||||
|
||||
// createChooseServerPopUp
|
||||
func (ui *MainWindowImpl) createChooseServerPopUp(w fyne.Window) error {
|
||||
ch := make(chan string)
|
||||
|
||||
selServerWin := ui.createChooseServerWindow("选服", ch)
|
||||
go func() {
|
||||
data := <-ch
|
||||
selServerWin.Hide()
|
||||
ui.NewWelcomeLabel(data)
|
||||
ui.w.Show()
|
||||
}()
|
||||
return nil
|
||||
}
|
||||
|
||||
// createChooseServerWindow
|
||||
func (ui *MainWindowImpl) createChooseServerWindow(
|
||||
title string,
|
||||
ch chan string) fyne.Window {
|
||||
|
||||
makeButton := func(s *service.ServiceConf, parent fyne.Window) *widget.Button {
|
||||
btn := widget.NewButton(s.Name, func() {
|
||||
d := dialog.NewInformation("", common.INFO_WAIT, parent)
|
||||
d.SetDismissText(common.BUTTON_CANCEL)
|
||||
d.Show()
|
||||
|
||||
logrus.WithField("server", s.Name).Debug("choose server")
|
||||
//conn server
|
||||
if err := ui.connService.Connect(s.Url); err != nil {
|
||||
d.Hide()
|
||||
dialog.ShowError(err, parent)
|
||||
} else {
|
||||
ch <- fmt.Sprintf("%d:%s", s.SId, s.Name)
|
||||
}
|
||||
})
|
||||
return btn
|
||||
}
|
||||
w := fyne.CurrentApp().NewWindow(title)
|
||||
sGrid := container.NewGridWithColumns(2)
|
||||
config := ui.configService.GetConfig()
|
||||
if config != nil {
|
||||
for _, s := range config.Services {
|
||||
box := makeButton(s.Service, w)
|
||||
sGrid.Add(box)
|
||||
}
|
||||
}
|
||||
|
||||
w.SetContent(sGrid)
|
||||
w.SetFixedSize(true)
|
||||
w.Resize(fyne.NewSize(500, 200))
|
||||
w.Show()
|
||||
w.CenterOnScreen()
|
||||
return w
|
||||
}
|
||||
|
||||
// createLoginWin
|
||||
func (ui *MainWindowImpl) createLoginWin(sid int32, sname string) {
|
||||
//form
|
||||
account := widget.NewEntry()
|
||||
account.Text = "user8120" //default account
|
||||
// account.Validator = validation.NewRegexp(`^(\s*)$`, "account required")
|
||||
// password := widget.NewPasswordEntry()
|
||||
items := []*widget.FormItem{
|
||||
widget.NewFormItem(common.LABEL_ACCOUNT, account),
|
||||
// widget.NewFormItem("password", password),
|
||||
}
|
||||
|
||||
dialog.ShowForm(common.FORM_TITLE_LOGIN, common.BUTTON_LOGIN, common.BUTTON_CANCEL, items, func(b bool) {
|
||||
if !b {
|
||||
logrus.Debug("cancel login")
|
||||
} else {
|
||||
if account.Text != "" {
|
||||
logrus.WithField("account", account.Text).Debug("submit login")
|
||||
if code, rsp := ui.pttService.Login(sid, account.Text); code != pb.ErrorCode_Success {
|
||||
err := fmt.Errorf("login err: %v[%d]", code, int32(code))
|
||||
dialog.ShowError(err, ui.w)
|
||||
|
||||
} else {
|
||||
ui.w.SetTitle(fmt.Sprintf("%s[%d]", sname, sid))
|
||||
ui.connService.ListenerPush()
|
||||
//show mainwindow
|
||||
// logrus.Debug(rsp)
|
||||
ui.pttService.SetUser(rsp.Data, rsp.Ex)
|
||||
// isCreateRole
|
||||
if rsp.Data.Created {
|
||||
// ui.renderUserContainer()
|
||||
ui.createWindowContainer()
|
||||
ui.sb.setMessage(common.LABEL_WELCOME + rsp.Data.Binduid)
|
||||
appName, err := ui.at.openDefaultApp()
|
||||
if err != nil {
|
||||
logrus.WithField("appName", appName).Error(err)
|
||||
}
|
||||
ui.obs.Notify(observer.EVENT_USERINFO, ui.pttService.GetUser())
|
||||
} else {
|
||||
ui.createRoleWindowPopUp()
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}, ui.w)
|
||||
}
|
||||
|
||||
// createMainWindowMenu create the main window menu
|
||||
func (ui *MainWindowImpl) createMainWindowMenu() *fyne.MainMenu {
|
||||
|
||||
menuItems := []*fyne.MenuItem{}
|
||||
|
||||
menu := fyne.Menu{
|
||||
Label: common.MENU_FILE,
|
||||
Items: menuItems,
|
||||
}
|
||||
|
||||
return fyne.NewMainMenu(&menu)
|
||||
}
|
||||
|
||||
// createRoleWindowPopUp
|
||||
func (ui *MainWindowImpl) createRoleWindowPopUp() {
|
||||
nickname := widget.NewEntry()
|
||||
c := container.NewHBox(
|
||||
nickname,
|
||||
widget.NewButton(common.BUTTON_RANDOM, func() {
|
||||
nickname.SetText(randomdata.SillyName())
|
||||
}),
|
||||
)
|
||||
items := []*widget.FormItem{
|
||||
widget.NewFormItem(common.LABEL_NICKNAME, c),
|
||||
}
|
||||
|
||||
dialog.ShowForm(common.FORM_TITLE_CREATEROLE, common.BUTTON_OK, common.BUTTON_CANCEL, items, func(b bool) {
|
||||
if !b {
|
||||
return
|
||||
} else {
|
||||
if nickname.Text != "" {
|
||||
logrus.WithField("nickname", nickname.Text).Debug("submit crete role")
|
||||
if code, _ := ui.pttService.CreateRole(nickname.Text); code != pb.ErrorCode_Success {
|
||||
err := fmt.Errorf("login err: %v[%d]", code, int32(code))
|
||||
dialog.ShowError(err, ui.w)
|
||||
} else {
|
||||
// if rsp.IsSucc {
|
||||
user := ui.pttService.GetUser()
|
||||
logrus.WithField("uid", user.DbUser.Uid).Debug("create role succ")
|
||||
ui.createWindowContainer()
|
||||
appName, err := ui.at.openDefaultApp()
|
||||
if err != nil {
|
||||
logrus.WithField("appName", appName).Error(err)
|
||||
}
|
||||
ui.obs.Notify(observer.EVENT_USERINFO, ui.pttService.GetUser())
|
||||
// }
|
||||
}
|
||||
}
|
||||
}
|
||||
}, ui.w)
|
||||
}
|
||||
|
||||
// NewWelcomeLabel
|
||||
func (ui *MainWindowImpl) NewWelcomeLabel(data string) {
|
||||
p := strings.Split(data, ":")
|
||||
if len(p) != 2 {
|
||||
logrus.WithField("param", p).Error("choose service")
|
||||
return
|
||||
}
|
||||
c := container.NewCenter(container.NewVBox(
|
||||
widget.NewLabelWithStyle(fmt.Sprintf(common.LABEL_CHOOSE, p[0], p[1]),
|
||||
fyne.TextAlignCenter,
|
||||
fyne.TextStyle{Bold: true}),
|
||||
container.NewCenter(container.NewHBox(
|
||||
widget.NewButton(common.BUTTON_LOGIN, func() {
|
||||
ui.createLoginWin(cast.ToInt32(p[0]), p[1])
|
||||
}),
|
||||
)),
|
||||
))
|
||||
ui.w.SetContent(c)
|
||||
}
|
278
cmd/v2/ui/protocol.go
Normal file
278
cmd/v2/ui/protocol.go
Normal file
@ -0,0 +1,278 @@
|
||||
package ui
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"go_dreamfactory/cmd/v2/model"
|
||||
"go_dreamfactory/cmd/v2/service/observer"
|
||||
"go_dreamfactory/cmd/v2/ui/formview"
|
||||
"go_dreamfactory/comm"
|
||||
"go_dreamfactory/lego/core"
|
||||
"go_dreamfactory/modules/friend"
|
||||
"go_dreamfactory/modules/hero"
|
||||
"go_dreamfactory/modules/task"
|
||||
"go_dreamfactory/modules/user"
|
||||
"go_dreamfactory/pb"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"google.golang.org/protobuf/proto"
|
||||
)
|
||||
|
||||
type MyCaseView interface {
|
||||
Init(obs observer.Observer, w fyne.Window)
|
||||
CreateView(t *model.TestCase) fyne.CanvasObject
|
||||
}
|
||||
|
||||
// 1 注册接口测试的表单试图
|
||||
var (
|
||||
viewRegister = map[string]MyCaseView{
|
||||
// gm
|
||||
ff(comm.ModuleGM, "cmd"): &formview.BingoView{},
|
||||
//user
|
||||
ff(comm.ModuleUser, user.UserSubTypeModifyName): &formview.UserModifynameView{},
|
||||
//task
|
||||
ff(comm.ModuleTask, task.TaskSubTypeList): &formview.TaskListView{},
|
||||
ff(comm.ModuleTask, task.TaskSubTypeReceive): &formview.TaskReceiveView{},
|
||||
ff(comm.ModuleTask, task.TaskSubTypeActiveList): &formview.TaskActiveListView{},
|
||||
ff(comm.ModuleTask, task.TaskSubTypeActiveReceive): &formview.TaskActiveReceiveView{},
|
||||
// hero
|
||||
ff(comm.ModuleHero, hero.HeroSubTypeList): &formview.HeroListView{},
|
||||
ff(comm.ModuleHero, hero.StrengthenUplv): &formview.HeroStrengthenUplvView{},
|
||||
ff(comm.ModuleHero, hero.StrengthenUpStar): &formview.HeroStrengthenUpStarView{},
|
||||
//friend
|
||||
ff(comm.ModuleFriend, friend.FriendSubTypeList): &formview.FriendListView{},
|
||||
ff(comm.ModuleFriend, friend.FriendSubTypeApply): &formview.FriendApplyView{},
|
||||
// ff(comm.ModuleFriend, friend.FriendSubTypeApplyList): &formview.FriendApplyListView{},
|
||||
ff(comm.ModuleFriend, friend.FriendSubTypeAgree): &formview.FriendAgreeView{},
|
||||
// ff(comm.ModuleFriend, friend.FriendSubTypeRefuse): &formview.FriendRefuseView{},
|
||||
ff(comm.ModuleFriend, friend.FriendSubTypeBlacklist): &formview.FriendBlacklistView{},
|
||||
ff(comm.ModuleFriend, friend.FriendSubTypeAddBlack): &formview.FriendAddBlackView{},
|
||||
ff(comm.ModuleFriend, friend.FriendSubTypeDelBlack): &formview.FriendDelblackView{},
|
||||
ff(comm.ModuleFriend, friend.FriendSubTypeSearch): &formview.FriendSearchView{},
|
||||
}
|
||||
)
|
||||
|
||||
// 2 添加导航菜单
|
||||
var (
|
||||
CaseIndex = map[string][]string{
|
||||
"": {
|
||||
string(comm.ModuleGM),
|
||||
string(comm.ModuleUser),
|
||||
string(comm.ModuleHero),
|
||||
string(comm.ModuleTask),
|
||||
string(comm.ModuleFriend),
|
||||
},
|
||||
"gm": {ff(comm.ModuleGM, "cmd")},
|
||||
"user": {
|
||||
ff(comm.ModuleUser, user.UserSubTypeModifyName),
|
||||
},
|
||||
"hero": {
|
||||
ff(comm.ModuleHero, hero.HeroSubTypeList),
|
||||
ff(comm.ModuleHero, hero.StrengthenUplv),
|
||||
ff(comm.ModuleHero, hero.StrengthenUpStar),
|
||||
},
|
||||
"task": {
|
||||
ff(comm.ModuleTask, task.TaskSubTypeList),
|
||||
ff(comm.ModuleTask, task.TaskSubTypeReceive),
|
||||
ff(comm.ModuleTask, task.TaskSubTypeActiveList),
|
||||
ff(comm.ModuleTask, task.TaskSubTypeActiveReceive),
|
||||
},
|
||||
"friend": {
|
||||
ff(comm.ModuleFriend, friend.FriendSubTypeList),
|
||||
ff(comm.ModuleFriend, friend.FriendSubTypeApply),
|
||||
// ff(comm.ModuleFriend, friend.FriendSubTypeApplyList),
|
||||
ff(comm.ModuleFriend, friend.FriendSubTypeAgree),
|
||||
// ff(comm.ModuleFriend, friend.FriendSubTypeRefuse),
|
||||
ff(comm.ModuleFriend, friend.FriendSubTypeBlacklist),
|
||||
ff(comm.ModuleFriend, friend.FriendSubTypeAddBlack),
|
||||
ff(comm.ModuleFriend, friend.FriendSubTypeDelBlack),
|
||||
ff(comm.ModuleFriend, friend.FriendSubTypeSearch),
|
||||
},
|
||||
}
|
||||
)
|
||||
|
||||
// 3 注册测试用例
|
||||
var (
|
||||
CaseNav = map[string]*model.TestCase{
|
||||
// gm
|
||||
"gm": {
|
||||
MainType: string(comm.ModuleGM),
|
||||
Enabled: true,
|
||||
},
|
||||
ff(comm.ModuleGM, "cmd"): {
|
||||
Desc: "eg. bingo:item,10001,1 bingo:attr,gold,1000000",
|
||||
MainType: string(comm.ModuleGM),
|
||||
SubType: "cmd",
|
||||
Req: &pb.GMCmdReq{},
|
||||
Rsp: &pb.GMCmdResp{},
|
||||
Enabled: true,
|
||||
},
|
||||
// user
|
||||
"user": {
|
||||
MainType: "user",
|
||||
Enabled: true,
|
||||
},
|
||||
"user.modifyname": {
|
||||
Desc: "用户昵称修改",
|
||||
MainType: "user",
|
||||
SubType: "modifyname",
|
||||
Req: &pb.UserModifynameReq{},
|
||||
Rsp: &pb.UserModifynameResp{},
|
||||
Print: func(rsp proto.Message) string {
|
||||
r := rsp.(*pb.UserModifynameResp)
|
||||
return fmt.Sprintf("Uid:%s count:%d", r.Uid, r.Count)
|
||||
},
|
||||
Enabled: true,
|
||||
},
|
||||
// task
|
||||
"task": {
|
||||
MainType: "task",
|
||||
Enabled: true,
|
||||
},
|
||||
"task.list": {
|
||||
Desc: "用户任务列表",
|
||||
MainType: "task",
|
||||
SubType: "list",
|
||||
Req: &pb.TaskListReq{},
|
||||
Rsp: &pb.TaskListResp{},
|
||||
Enabled: true,
|
||||
},
|
||||
"task.receive": {
|
||||
Desc: "用户任务领取",
|
||||
MainType: "task",
|
||||
SubType: "receive",
|
||||
Enabled: true,
|
||||
},
|
||||
ff(comm.ModuleTask, task.TaskSubTypeActiveList): {
|
||||
Desc: "用户活跃度列表",
|
||||
MainType: string(comm.ModuleTask),
|
||||
SubType: task.TaskSubTypeActiveList,
|
||||
Req: &pb.TaskActiveListReq{},
|
||||
Rsp: &pb.TaskActiveListResp{},
|
||||
Enabled: true,
|
||||
},
|
||||
ff(comm.ModuleTask, task.TaskSubTypeActiveReceive): {
|
||||
Desc: "用户活跃度领取",
|
||||
MainType: string(comm.ModuleTask),
|
||||
SubType: task.TaskSubTypeActiveReceive,
|
||||
Req: &pb.TaskActiveReceiveReq{},
|
||||
Rsp: &pb.TaskActiveReceiveResp{},
|
||||
Enabled: true,
|
||||
},
|
||||
// hero
|
||||
string(comm.ModuleHero): {
|
||||
MainType: string(comm.ModuleHero),
|
||||
Enabled: true,
|
||||
},
|
||||
ff(comm.ModuleHero, hero.HeroSubTypeList): {
|
||||
Desc: "英雄列表",
|
||||
MainType: string(comm.ModuleHero),
|
||||
SubType: hero.HeroSubTypeList,
|
||||
Req: &pb.HeroListReq{},
|
||||
Rsp: &pb.HeroListResp{},
|
||||
// Print: func(rsp proto.Message) string{
|
||||
// out := rsp.(*pb.HeroListResp)
|
||||
// for i, v := range out.List {
|
||||
// fmt.Printf("%d- %v\n", (i + 1), v)
|
||||
// }
|
||||
// },
|
||||
Enabled: true,
|
||||
},
|
||||
ff(comm.ModuleHero, hero.StrengthenUplv): {
|
||||
Desc: "英雄等级升级",
|
||||
MainType: string(comm.ModuleHero),
|
||||
SubType: hero.StrengthenUplv,
|
||||
Req: &pb.HeroStrengthenUplvReq{},
|
||||
Rsp: &pb.HeroStrengthenUplvResp{},
|
||||
Enabled: true,
|
||||
},
|
||||
ff(comm.ModuleHero, hero.StrengthenUpStar): {
|
||||
Desc: "英雄星级升级",
|
||||
MainType: string(comm.ModuleHero),
|
||||
SubType: hero.StrengthenUpStar,
|
||||
Req: &pb.HeroStrengthenUpStarReq{},
|
||||
Rsp: &pb.HeroStrengthenUpStarResp{},
|
||||
Enabled: true,
|
||||
},
|
||||
//friend
|
||||
string(comm.ModuleFriend): {
|
||||
MainType: string(comm.ModuleFriend),
|
||||
Enabled: true,
|
||||
},
|
||||
ff(comm.ModuleFriend, friend.FriendSubTypeList): {
|
||||
Desc: "好友列表",
|
||||
MainType: string(comm.ModuleFriend),
|
||||
SubType: friend.FriendSubTypeList,
|
||||
Req: &pb.FriendListReq{},
|
||||
Rsp: &pb.FriendListResp{},
|
||||
Enabled: true,
|
||||
},
|
||||
ff(comm.ModuleFriend, friend.FriendSubTypeApply): {
|
||||
Desc: "好友申请",
|
||||
MainType: string(comm.ModuleFriend),
|
||||
SubType: friend.FriendSubTypeApply,
|
||||
Req: &pb.FriendApplyReq{},
|
||||
Rsp: &pb.FriendApplyResp{},
|
||||
Enabled: true,
|
||||
},
|
||||
// ff(comm.ModuleFriend, friend.FriendSubTypeApplyList): {
|
||||
// Desc: "申请列表",
|
||||
// MainType: string(comm.ModuleFriend),
|
||||
// SubType: friend.FriendSubTypeApplyList,
|
||||
// Req: &pb.FriendApplyListReq{},
|
||||
// Rsp: &pb.FriendApplyListResp{},
|
||||
// Enabled: true,
|
||||
// },
|
||||
ff(comm.ModuleFriend, friend.FriendSubTypeBlacklist): {
|
||||
Desc: "黑名单列表",
|
||||
MainType: string(comm.ModuleFriend),
|
||||
SubType: friend.FriendSubTypeBlacklist,
|
||||
Req: &pb.FriendBlackListReq{},
|
||||
Rsp: &pb.FriendBlackListResp{},
|
||||
Enabled: true,
|
||||
},
|
||||
ff(comm.ModuleFriend, friend.FriendSubTypeAddBlack): {
|
||||
Desc: "添加黑名单",
|
||||
MainType: string(comm.ModuleFriend),
|
||||
SubType: friend.FriendSubTypeAddBlack,
|
||||
Req: &pb.FriendBlackAddReq{},
|
||||
Rsp: &pb.FriendBlackAddResp{},
|
||||
Enabled: true,
|
||||
},
|
||||
ff(comm.ModuleFriend, friend.FriendSubTypeDelBlack): {
|
||||
Desc: "删除黑名单",
|
||||
MainType: string(comm.ModuleFriend),
|
||||
SubType: friend.FriendSubTypeDelBlack,
|
||||
Req: &pb.FriendDelBlackReq{},
|
||||
Rsp: &pb.FriendDelBlackResp{},
|
||||
Enabled: true,
|
||||
},
|
||||
ff(comm.ModuleFriend, friend.FriendSubTypeAgree): {
|
||||
Desc: "好友申请审批",
|
||||
MainType: string(comm.ModuleFriend),
|
||||
SubType: friend.FriendSubTypeAgree,
|
||||
Req: &pb.FriendAgreeReq{},
|
||||
Rsp: &pb.FriendAgreeResp{},
|
||||
Enabled: true,
|
||||
},
|
||||
// ff(comm.ModuleFriend, friend.FriendSubTypeRefuse): {
|
||||
// Desc: "拒绝",
|
||||
// MainType: string(comm.ModuleFriend),
|
||||
// SubType: friend.FriendSubTypeRefuse,
|
||||
// Req: &pb.FriendRefuseReq{},
|
||||
// Rsp: &pb.FriendRefuseResp{},
|
||||
// Enabled: true,
|
||||
// },
|
||||
ff(comm.ModuleFriend, friend.FriendSubTypeSearch): {
|
||||
Desc: "搜索好友",
|
||||
MainType: string(comm.ModuleFriend),
|
||||
SubType: friend.FriendSubTypeSearch,
|
||||
Req: &pb.FriendSearchReq{},
|
||||
Rsp: &pb.FriendSearchResp{},
|
||||
Enabled: true,
|
||||
},
|
||||
}
|
||||
)
|
||||
|
||||
func ff(s1 core.M_Modules, s2 string) string {
|
||||
return fmt.Sprintf("%s.%s", s1, s2)
|
||||
}
|
26
cmd/v2/ui/status_bar.go
Normal file
26
cmd/v2/ui/status_bar.go
Normal file
@ -0,0 +1,26 @@
|
||||
package ui
|
||||
|
||||
import (
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/container"
|
||||
"fyne.io/fyne/v2/layout"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
)
|
||||
|
||||
type statusBar struct {
|
||||
msgLabel *widget.Label
|
||||
widget *fyne.Container
|
||||
}
|
||||
|
||||
func newStatusBar() *statusBar {
|
||||
var sb statusBar
|
||||
sb.msgLabel = widget.NewLabel("")
|
||||
sb.widget = container.New(layout.NewHBoxLayout(),
|
||||
sb.msgLabel,
|
||||
layout.NewSpacer())
|
||||
return &sb
|
||||
}
|
||||
|
||||
func (sb *statusBar) setMessage(msg string) {
|
||||
sb.msgLabel.SetText(msg)
|
||||
}
|
44
cmd/v2/ui/tool_bar.go
Normal file
44
cmd/v2/ui/tool_bar.go
Normal file
@ -0,0 +1,44 @@
|
||||
package ui
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"go_dreamfactory/cmd/v2/lib/common"
|
||||
|
||||
"fyne.io/fyne/v2/theme"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
"github.com/sirupsen/logrus"
|
||||
)
|
||||
|
||||
type toolBar struct {
|
||||
toolbar *widget.Toolbar
|
||||
}
|
||||
|
||||
func newToolBar() *toolBar {
|
||||
var tb toolBar
|
||||
|
||||
// mainwindow toolbar
|
||||
tb.toolbar = widget.NewToolbar(
|
||||
widget.NewToolbarAction(theme.ComputerIcon(), func() {
|
||||
openApp(common.TOOLBAR_MONITOR)
|
||||
}),
|
||||
widget.NewToolbarAction(theme.AccountIcon(), func() {
|
||||
openApp(common.TOOLBAR_TESTER)
|
||||
}),
|
||||
widget.NewToolbarSpacer(),
|
||||
widget.NewToolbarAction(theme.HelpIcon(), func() {
|
||||
showAbout()
|
||||
}),
|
||||
)
|
||||
return &tb
|
||||
}
|
||||
|
||||
func openApp(name string) {
|
||||
for _, app := range appRegister {
|
||||
if app.GetAppName() == name {
|
||||
err := globalWin.at.openApp(app)
|
||||
if err != nil {
|
||||
logrus.Error(fmt.Errorf("%s %v", app.GetAppName(), err))
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
73
cmd/v2/ui/toy_datetime.go
Normal file
73
cmd/v2/ui/toy_datetime.go
Normal file
@ -0,0 +1,73 @@
|
||||
package ui
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/lib/common"
|
||||
"go_dreamfactory/cmd/v2/service/observer"
|
||||
"time"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/canvas"
|
||||
"fyne.io/fyne/v2/container"
|
||||
"fyne.io/fyne/v2/layout"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
"github.com/BabySid/gobase"
|
||||
)
|
||||
|
||||
type toyDateTime struct {
|
||||
toyAdapter
|
||||
date *canvas.Text
|
||||
week *canvas.Text
|
||||
time *canvas.Text
|
||||
}
|
||||
|
||||
func (tdt *toyDateTime) Init(obs observer.Observer) error {
|
||||
tdt.date = canvas.NewText("", nil)
|
||||
tdt.date.TextSize = 15
|
||||
|
||||
tdt.week = canvas.NewText("", nil)
|
||||
tdt.week.TextSize = 15
|
||||
|
||||
tdt.time = canvas.NewText("", nil)
|
||||
tdt.time.TextSize = 42
|
||||
|
||||
tdt.widget = widget.NewCard("", common.DATETIME,
|
||||
container.NewVBox(
|
||||
container.NewHBox(layout.NewSpacer(), tdt.date, tdt.week, layout.NewSpacer()),
|
||||
container.NewCenter(tdt.time),
|
||||
),
|
||||
)
|
||||
|
||||
tdt.widget.Resize(fyne.NewSize(ToyWidth, 130))
|
||||
|
||||
// for init
|
||||
tdt.Run()
|
||||
|
||||
_ = gobase.GlobalScheduler.AddJob("toy_datetime", "*/1 * * * * *", tdt)
|
||||
// todo assert(err == nil)
|
||||
return nil
|
||||
}
|
||||
|
||||
var (
|
||||
weekStr = [...]string{
|
||||
"Sunday",
|
||||
"Monday",
|
||||
"Tuesday",
|
||||
"Wednesday",
|
||||
"Thursday",
|
||||
"Friday",
|
||||
"Saturday",
|
||||
}
|
||||
)
|
||||
|
||||
func (tdt *toyDateTime) Run() {
|
||||
now := time.Now()
|
||||
|
||||
tdt.date.Text = gobase.FormatTimeStampWithFormat(now.Unix(), gobase.DateFormat)
|
||||
tdt.date.Refresh()
|
||||
|
||||
tdt.week.Text = weekStr[now.Weekday()]
|
||||
tdt.week.Refresh()
|
||||
|
||||
tdt.time.Text = gobase.FormatTimeStampWithFormat(now.Unix(), gobase.TimeFormat)
|
||||
tdt.time.Refresh()
|
||||
}
|
35
cmd/v2/ui/toy_interface.go
Normal file
35
cmd/v2/ui/toy_interface.go
Normal file
@ -0,0 +1,35 @@
|
||||
package ui
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/service/observer"
|
||||
|
||||
"fyne.io/fyne/v2/widget"
|
||||
)
|
||||
|
||||
type toyInterface interface {
|
||||
Init(obs observer.Observer) error
|
||||
GetToyCard() *widget.Card
|
||||
}
|
||||
|
||||
var (
|
||||
toyRegister = []toyInterface{
|
||||
&toyDateTime{},
|
||||
&toyUserInfo{},
|
||||
}
|
||||
)
|
||||
|
||||
const (
|
||||
ToyWidth = 250
|
||||
)
|
||||
|
||||
type toyAdapter struct {
|
||||
widget *widget.Card
|
||||
}
|
||||
|
||||
func (t toyAdapter) Init(obs observer.Observer) error {
|
||||
panic("implement Init")
|
||||
}
|
||||
|
||||
func (t toyAdapter) GetToyCard() *widget.Card {
|
||||
return t.widget
|
||||
}
|
125
cmd/v2/ui/toy_userinfo.go
Normal file
125
cmd/v2/ui/toy_userinfo.go
Normal file
@ -0,0 +1,125 @@
|
||||
package ui
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"go_dreamfactory/cmd/v2/lib/common"
|
||||
"go_dreamfactory/cmd/v2/model"
|
||||
"go_dreamfactory/cmd/v2/service"
|
||||
"go_dreamfactory/cmd/v2/service/observer"
|
||||
"go_dreamfactory/comm"
|
||||
"go_dreamfactory/modules/user"
|
||||
"go_dreamfactory/pb"
|
||||
"time"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/container"
|
||||
"fyne.io/fyne/v2/data/binding"
|
||||
"fyne.io/fyne/v2/layout"
|
||||
"fyne.io/fyne/v2/widget"
|
||||
"github.com/atotto/clipboard"
|
||||
"github.com/sirupsen/logrus"
|
||||
"github.com/spf13/cast"
|
||||
)
|
||||
|
||||
type toyUserInfo struct {
|
||||
toyAdapter
|
||||
|
||||
dataList *widget.List
|
||||
titleLabel *widget.Label
|
||||
|
||||
userInfo *service.UserInfo
|
||||
|
||||
data binding.ExternalStringList
|
||||
obs observer.Observer
|
||||
copyBtn *widget.Button
|
||||
}
|
||||
|
||||
func (this *toyUserInfo) Init(obs observer.Observer) error {
|
||||
this.obs = obs
|
||||
this.titleLabel = widget.NewLabel(common.USERINFO_TITLE)
|
||||
this.data = binding.BindStringList(&[]string{})
|
||||
this.copyBtn = widget.NewButton(common.USERINFO_BTN_COPY, func() {
|
||||
if this.userInfo != nil && this.userInfo.DbUser != nil {
|
||||
_ = clipboard.WriteAll(this.userInfo.DbUser.Uid)
|
||||
}
|
||||
})
|
||||
this.copyBtn.Disable()
|
||||
|
||||
this.dataList = widget.NewListWithData(this.data,
|
||||
func() fyne.CanvasObject {
|
||||
return widget.NewLabel("template")
|
||||
},
|
||||
func(i binding.DataItem, o fyne.CanvasObject) {
|
||||
o.(*widget.Label).Bind(i.(binding.String))
|
||||
},
|
||||
)
|
||||
|
||||
this.widget = widget.NewCard("", "",
|
||||
container.NewBorder(container.NewHBox(this.titleLabel, layout.NewSpacer(), this.copyBtn),
|
||||
nil, nil, nil, container.NewVScroll(this.dataList)))
|
||||
this.widget.Resize(fyne.NewSize(ToyWidth, 600))
|
||||
|
||||
this.dataListener()
|
||||
return nil
|
||||
}
|
||||
|
||||
func (this *toyUserInfo) dataListener() {
|
||||
this.obs.AddListener(observer.EVENT_USERINFO, observer.Listener{
|
||||
OnNotify: func(d interface{}, args ...interface{}) {
|
||||
time.Sleep(time.Millisecond * 50)
|
||||
_ = this.data.Set([]string{})
|
||||
if this.copyBtn.Disabled() {
|
||||
this.copyBtn.Enable()
|
||||
}
|
||||
this.userInfo = d.(*service.UserInfo)
|
||||
if this.userInfo == nil {
|
||||
return
|
||||
}
|
||||
|
||||
// _ = this.data.Append(fmt.Sprintf("%-3s\t: %s", common.USERINFO_UID, this.userInfo.DbUser.Uid))
|
||||
_ = this.data.Append(fmt.Sprintf("%-3s\t: %s", common.USERINFO_ACC, this.userInfo.DbUser.Binduid))
|
||||
_ = this.data.Append(fmt.Sprintf("%-3s\t: %s", common.USERINFO_NAME, this.userInfo.DbUser.Name))
|
||||
_ = this.data.Append(fmt.Sprintf("%-3s\t: %s", common.USERINFO_AVATAR, cast.ToString(this.userInfo.DbUser.Avatar)))
|
||||
_ = this.data.Append(fmt.Sprintf("%-3s\t: %s", common.USERINFO_VIP, cast.ToString(this.userInfo.DbUser.Vip)))
|
||||
_ = this.data.Append(fmt.Sprintf("%-3s\t: %s", common.USERINFO_LV, cast.ToString(this.userInfo.DbUser.Lv)))
|
||||
_ = this.data.Append(fmt.Sprintf("%-3s\t: %s", common.USERINFO_GOLD, cast.ToString(this.userInfo.DbUser.Gold)))
|
||||
_ = this.data.Append(fmt.Sprintf("%-3s\t: %s", common.USERINFO_EXP, cast.ToString(this.userInfo.DbUser.Exp)))
|
||||
},
|
||||
})
|
||||
|
||||
this.obs.AddListener(observer.EVENT_CASE_RSP, observer.Listener{
|
||||
OnNotify: func(d interface{}, args ...interface{}) {
|
||||
data := d.(*pb.UserMessage)
|
||||
//change name
|
||||
if data.MainType == string(comm.ModuleUser) &&
|
||||
data.SubType == user.UserSubTypeModifyName {
|
||||
rsp := &pb.UserModifynameResp{}
|
||||
if !comm.ProtoUnmarshal(data, rsp) {
|
||||
logrus.Error("unmarshal err")
|
||||
}
|
||||
//TODO 改此协议 返回昵称
|
||||
// _=this.data.SetValue(1, fmt.Sprintf("%-3s\t: %s", common.USERINFO_NAME, rsp.Uid))
|
||||
}
|
||||
},
|
||||
})
|
||||
|
||||
this.obs.AddListener(observer.EVENT_APP_PUSH, observer.Listener{
|
||||
OnNotify: func(d interface{}, args ...interface{}) {
|
||||
data := d.(*model.PushModel)
|
||||
// listener gold
|
||||
if data.Msg.MainType == string(comm.ModuleUser) &&
|
||||
data.Msg.SubType == "reschange" {
|
||||
rsp := &pb.UserResChangePush{}
|
||||
if !comm.ProtoUnmarshal(data.Msg, rsp) {
|
||||
logrus.Error("unmarshal err")
|
||||
}
|
||||
_ = this.data.SetValue(5, fmt.Sprintf("%-3s\t: %s", common.USERINFO_GOLD, cast.ToString(rsp.Gold)))
|
||||
}
|
||||
// listener exp
|
||||
if data.Msg.MainType == string(comm.ModuleUser) &&
|
||||
data.Msg.SubType == "" {
|
||||
//TODO change exp
|
||||
}
|
||||
},
|
||||
})
|
||||
}
|
31
cmd/v2/ui/toys.go
Normal file
31
cmd/v2/ui/toys.go
Normal file
@ -0,0 +1,31 @@
|
||||
package ui
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/service/observer"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/container"
|
||||
)
|
||||
|
||||
type toys struct {
|
||||
widget *fyne.Container
|
||||
}
|
||||
|
||||
func newToys(obs observer.Observer) *toys {
|
||||
var t toys
|
||||
|
||||
cards := make([]fyne.CanvasObject, len(toyRegister))
|
||||
for i, toy := range toyRegister {
|
||||
toy := toy
|
||||
err := toy.Init(obs)
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
||||
cards[i] = toy.GetToyCard()
|
||||
}
|
||||
|
||||
t.widget = container.New(NewVCZBoxLayout(),
|
||||
cards...)
|
||||
return &t
|
||||
}
|
60
cmd/v2/ui/ui.go
Normal file
60
cmd/v2/ui/ui.go
Normal file
@ -0,0 +1,60 @@
|
||||
package ui
|
||||
|
||||
import (
|
||||
"go_dreamfactory/cmd/v2/service"
|
||||
"go_dreamfactory/cmd/v2/service/observer"
|
||||
"sync"
|
||||
|
||||
"go_dreamfactory/cmd/v2/theme"
|
||||
|
||||
"fyne.io/fyne/v2"
|
||||
)
|
||||
|
||||
type UI interface {
|
||||
AddWindow(name string, w fyne.Window)
|
||||
Run()
|
||||
Stop()
|
||||
}
|
||||
|
||||
type UIImpl struct {
|
||||
app fyne.App
|
||||
windows map[string]fyne.Window
|
||||
winMux *sync.Mutex
|
||||
connService service.ConnService
|
||||
pttService service.PttService
|
||||
configService service.ConfigService
|
||||
obs observer.Observer
|
||||
}
|
||||
|
||||
func NewUI(
|
||||
app fyne.App,
|
||||
configService service.ConfigService,
|
||||
connService service.ConnService,
|
||||
pttService service.PttService,
|
||||
obs observer.Observer,
|
||||
) *UIImpl {
|
||||
app.Settings().SetTheme(&theme.MyTheme{})
|
||||
return &UIImpl{
|
||||
app: app,
|
||||
windows: make(map[string]fyne.Window),
|
||||
winMux: &sync.Mutex{},
|
||||
configService: configService,
|
||||
connService: connService,
|
||||
pttService: pttService,
|
||||
obs: obs,
|
||||
}
|
||||
}
|
||||
|
||||
func (ui *UIImpl) AddWindow(name string, w fyne.Window) {
|
||||
ui.winMux.Lock()
|
||||
defer ui.winMux.Unlock()
|
||||
ui.windows[name] = w
|
||||
}
|
||||
|
||||
func (ui *UIImpl) Run() {
|
||||
ui.app.Run()
|
||||
}
|
||||
|
||||
func (ui *UIImpl) Stop() {
|
||||
ui.app.Quit()
|
||||
}
|
5
cmd/v2/ui/windowInterface.go
Normal file
5
cmd/v2/ui/windowInterface.go
Normal file
@ -0,0 +1,5 @@
|
||||
package ui
|
||||
|
||||
type WindowInterface interface {
|
||||
CreateWindow(title string,width,height float32, visible bool)
|
||||
}
|
@ -45,6 +45,7 @@ const (
|
||||
ModuleNotify core.M_Modules = "notify" //公告模块
|
||||
ModuleChat core.M_Modules = "chat" //装备模块
|
||||
ModuleGM core.M_Modules = "gm" //gm模块
|
||||
ModulePagoda core.M_Modules = "pagoda" //魔塔模块
|
||||
)
|
||||
|
||||
//数据表名定义处
|
||||
|
@ -2,11 +2,11 @@ package comm
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"go_dreamfactory/pb"
|
||||
"reflect"
|
||||
|
||||
"go_dreamfactory/lego/core"
|
||||
"go_dreamfactory/lego/sys/log"
|
||||
|
||||
"google.golang.org/protobuf/proto"
|
||||
"google.golang.org/protobuf/types/known/anypb"
|
||||
@ -69,7 +69,7 @@ type IUserSession interface {
|
||||
func ProtoUnmarshal(msg *pb.UserMessage, req proto.Message) (ok bool) {
|
||||
err := msg.Data.UnmarshalTo(req)
|
||||
if err != nil {
|
||||
log.Errorf("UnmarshalTo %s.%s %v", msg.MainType, msg.SubType, err)
|
||||
fmt.Printf("UnmarshalTo %s.%s %v\n", msg.MainType, msg.SubType, err)
|
||||
return
|
||||
}
|
||||
return true
|
||||
@ -79,7 +79,7 @@ func ProtoUnmarshal(msg *pb.UserMessage, req proto.Message) (ok bool) {
|
||||
func ProtoMarshal(rsp proto.Message, msg *pb.UserMessage) (ok bool) {
|
||||
any, err := anypb.New(rsp)
|
||||
if err != nil {
|
||||
log.Errorf("Any New %s.%s %v", msg.MainType, msg.SubType, err)
|
||||
fmt.Printf("Any New %s.%s %v", msg.MainType, msg.SubType, err)
|
||||
return
|
||||
}
|
||||
msg.Data = any
|
||||
|
@ -86,7 +86,7 @@ type (
|
||||
// 修改章节信息
|
||||
ModifyMainlineData(uid string, objId string, data interface{}) (code pb.ErrorCode)
|
||||
// 检查能不能挑战该关卡
|
||||
CheckChallengeChapter(stroyId int32, uid string, zhangjieID int32) (code pb.ErrorCode)
|
||||
CheckChallengeChapter(storyObjId string, uid string, zhangjieID int32) (code pb.ErrorCode)
|
||||
}
|
||||
//任务
|
||||
ITask interface {
|
||||
|
46
go.mod
46
go.mod
@ -4,7 +4,10 @@ go 1.18
|
||||
|
||||
require (
|
||||
bright v0.0.0
|
||||
fyne.io/fyne/v2 v2.2.3
|
||||
github.com/BabySid/gobase v0.0.0-20220614103908-39ac0a583c02
|
||||
github.com/Pallinder/go-randomdata v1.2.0
|
||||
github.com/atotto/clipboard v0.1.4
|
||||
github.com/axgle/mahonia v0.0.0-20180208002826-3358181d7394
|
||||
github.com/dengsgo/math-engine v0.0.0-20220213125415-0351c3c75eca
|
||||
github.com/go-playground/validator/v10 v10.10.1
|
||||
@ -24,6 +27,7 @@ require (
|
||||
github.com/spf13/cast v1.3.1
|
||||
github.com/spf13/cobra v1.2.1
|
||||
github.com/spf13/pflag v1.0.5
|
||||
github.com/spf13/viper v1.8.1
|
||||
github.com/tidwall/gjson v1.14.1
|
||||
github.com/ugorji/go/codec v1.2.7
|
||||
github.com/valyala/fastrand v1.1.0
|
||||
@ -35,7 +39,10 @@ require (
|
||||
)
|
||||
|
||||
require (
|
||||
fyne.io/systray v1.10.1-0.20220621085403-9a2652634e93 // indirect
|
||||
github.com/PuerkitoBio/goquery v1.8.0 // indirect
|
||||
github.com/akutz/memconn v0.1.0 // indirect
|
||||
github.com/andybalholm/cascadia v1.3.1 // indirect
|
||||
github.com/apache/thrift v0.16.0 // indirect
|
||||
github.com/armon/go-metrics v0.3.10 // indirect
|
||||
github.com/aws/aws-sdk-go v1.34.28 // indirect
|
||||
@ -43,23 +50,35 @@ require (
|
||||
github.com/cenkalti/backoff v2.2.1+incompatible // indirect
|
||||
github.com/cespare/xxhash/v2 v2.1.2 // indirect
|
||||
github.com/cheekybits/genny v1.0.0 // indirect
|
||||
github.com/davecgh/go-spew v1.1.1 // indirect
|
||||
github.com/dgryski/go-jump v0.0.0-20211018200510-ba001c3ffce0 // indirect
|
||||
github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f // indirect
|
||||
github.com/edwingeng/doublejump v0.0.0-20210724020454-c82f1bcb3280 // indirect
|
||||
github.com/facebookgo/clock v0.0.0-20150410010913-600d898af40a // indirect
|
||||
github.com/fatih/color v1.13.0 // indirect
|
||||
github.com/fsnotify/fsnotify v1.5.1 // indirect
|
||||
github.com/fredbi/uri v0.0.0-20181227131451-3dcfdacbaaf3 // indirect
|
||||
github.com/fsnotify/fsnotify v1.5.4 // indirect
|
||||
github.com/fyne-io/gl-js v0.0.0-20220119005834-d2da28d9ccfe // indirect
|
||||
github.com/fyne-io/glfw-js v0.0.0-20220120001248-ee7290d23504 // indirect
|
||||
github.com/fyne-io/image v0.0.0-20220602074514-4956b0afb3d2 // indirect
|
||||
github.com/go-cmd/cmd v1.4.0 // indirect
|
||||
github.com/go-gl/gl v0.0.0-20211210172815-726fda9656d6 // indirect
|
||||
github.com/go-gl/glfw/v3.3/glfw v0.0.0-20211213063430-748e38ca8aec // indirect
|
||||
github.com/go-logr/logr v1.2.3 // indirect
|
||||
github.com/go-logr/stdr v1.2.2 // indirect
|
||||
github.com/go-ole/go-ole v1.2.6 // indirect
|
||||
github.com/go-ping/ping v0.0.0-20211130115550-779d1e919534 // indirect
|
||||
github.com/go-playground/locales v0.14.0 // indirect
|
||||
github.com/go-playground/universal-translator v0.18.0 // indirect
|
||||
github.com/go-redis/redis_rate/v9 v9.1.2 // indirect
|
||||
github.com/go-stack/stack v1.8.0 // indirect
|
||||
github.com/go-task/slim-sprig v0.0.0-20210107165309-348f09dbbbc0 // indirect
|
||||
github.com/godbus/dbus/v5 v5.1.0 // indirect
|
||||
github.com/gogo/protobuf v1.3.2 // indirect
|
||||
github.com/goki/freetype v0.0.0-20181231101311-fa8a33aabaff // indirect
|
||||
github.com/golang/snappy v0.0.4 // indirect
|
||||
github.com/google/uuid v1.3.0 // indirect
|
||||
github.com/gopherjs/gopherjs v1.17.2 // indirect
|
||||
github.com/grandcat/zeroconf v1.0.0 // indirect
|
||||
github.com/hashicorp/consul/api v1.12.0 // indirect
|
||||
github.com/hashicorp/errwrap v1.1.0 // indirect
|
||||
@ -69,10 +88,12 @@ require (
|
||||
github.com/hashicorp/go-multierror v1.1.1 // indirect
|
||||
github.com/hashicorp/go-rootcerts v1.0.2 // indirect
|
||||
github.com/hashicorp/golang-lru v0.5.4 // indirect
|
||||
github.com/hashicorp/hcl v1.0.0 // indirect
|
||||
github.com/hashicorp/serf v0.9.7 // indirect
|
||||
github.com/inconshreveable/mousetrap v1.0.0 // indirect
|
||||
github.com/influxdata/influxdb1-client v0.0.0-20220302092344-a9ab5670611c // indirect
|
||||
github.com/jmespath/go-jmespath v0.4.0 // indirect
|
||||
github.com/jsummers/gobmp v0.0.0-20151104160322-e2ba15ffa76e // indirect
|
||||
github.com/juju/ratelimit v1.0.1 // indirect
|
||||
github.com/julienschmidt/httprouter v1.3.0 // indirect
|
||||
github.com/kavu/go_reuseport v1.5.0 // indirect
|
||||
@ -83,31 +104,47 @@ require (
|
||||
github.com/lestrrat/go-file-rotatelogs v0.0.0-20180223000712-d3151e2a480f // indirect
|
||||
github.com/lestrrat/go-strftime v0.0.0-20180220042222-ba3bf9c1d042 // indirect
|
||||
github.com/lucas-clemente/quic-go v0.27.0 // indirect
|
||||
github.com/lufia/plan9stats v0.0.0-20211012122336-39d0f177ccd0 // indirect
|
||||
github.com/magiconair/properties v1.8.5 // indirect
|
||||
github.com/marten-seemann/qtls-go1-16 v0.1.5 // indirect
|
||||
github.com/marten-seemann/qtls-go1-17 v0.1.1 // indirect
|
||||
github.com/marten-seemann/qtls-go1-18 v0.1.1 // indirect
|
||||
github.com/mattn/go-colorable v0.1.12 // indirect
|
||||
github.com/mattn/go-isatty v0.0.14 // indirect
|
||||
github.com/mattn/go-sqlite3 v1.14.12 // indirect
|
||||
github.com/miekg/dns v1.1.48 // indirect
|
||||
github.com/mitchellh/go-homedir v1.1.0 // indirect
|
||||
github.com/mitchellh/mapstructure v1.4.3 // indirect
|
||||
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
|
||||
github.com/nxadm/tail v1.4.8 // indirect
|
||||
github.com/onsi/ginkgo v1.16.5 // indirect
|
||||
github.com/pelletier/go-toml v1.9.3 // indirect
|
||||
github.com/philhofer/fwd v1.1.1 // indirect
|
||||
github.com/pkg/errors v0.9.1 // indirect
|
||||
github.com/pmezard/go-difflib v1.0.0 // indirect
|
||||
github.com/power-devops/perfstat v0.0.0-20210106213030-5aafc221ea8c // indirect
|
||||
github.com/rpcxio/libkv v0.5.1-0.20210420120011-1fceaedca8a5 // indirect
|
||||
github.com/rs/cors v1.8.2 // indirect
|
||||
github.com/rubyist/circuitbreaker v2.2.1+incompatible // indirect
|
||||
github.com/samuel/go-zookeeper v0.0.0-20201211165307-7117e9ea2414 // indirect
|
||||
github.com/shirou/gopsutil/v3 v3.22.2 // indirect
|
||||
github.com/smallnest/quick v0.0.0-20220103065406-780def6371e6 // indirect
|
||||
github.com/soheilhy/cmux v0.1.5 // indirect
|
||||
github.com/spf13/afero v1.6.0 // indirect
|
||||
github.com/spf13/jwalterweatherman v1.1.0 // indirect
|
||||
github.com/srwiley/oksvg v0.0.0-20200311192757-870daf9aa564 // indirect
|
||||
github.com/srwiley/rasterx v0.0.0-20200120212402-85cb7272f5e9 // indirect
|
||||
github.com/stretchr/testify v1.7.2 // indirect
|
||||
github.com/subosito/gotenv v1.2.0 // indirect
|
||||
github.com/templexxx/cpufeat v0.0.0-20180724012125-cef66df7f161 // indirect
|
||||
github.com/templexxx/xor v0.0.0-20191217153810-f85b25db303b // indirect
|
||||
github.com/tevino/abool v1.2.0 // indirect
|
||||
github.com/tidwall/match v1.1.1 // indirect
|
||||
github.com/tidwall/pretty v1.2.0 // indirect
|
||||
github.com/tinylib/msgp v1.1.6 // indirect
|
||||
github.com/tjfoc/gmsm v1.4.1 // indirect
|
||||
github.com/tklauser/go-sysconf v0.3.9 // indirect
|
||||
github.com/tklauser/numcpus v0.3.0 // indirect
|
||||
github.com/valyala/bytebufferpool v1.0.0 // indirect
|
||||
github.com/vmihailenco/msgpack/v5 v5.3.5 // indirect
|
||||
github.com/vmihailenco/tagparser/v2 v2.0.0 // indirect
|
||||
@ -116,18 +153,25 @@ require (
|
||||
github.com/xdg-go/stringprep v1.0.2 // indirect
|
||||
github.com/xtaci/kcp-go v5.4.20+incompatible // indirect
|
||||
github.com/youmark/pkcs8 v0.0.0-20181117223130-1be2e3e5546d // indirect
|
||||
github.com/yuin/goldmark v1.4.1 // indirect
|
||||
github.com/yusufpapurcu/wmi v1.2.2 // indirect
|
||||
go.opentelemetry.io/otel v1.6.3 // indirect
|
||||
go.opentelemetry.io/otel/trace v1.6.3 // indirect
|
||||
go.uber.org/atomic v1.7.0 // indirect
|
||||
go.uber.org/zap v1.21.0 // indirect
|
||||
golang.org/x/crypto v0.0.0-20220408190544-5352b0902921 // indirect
|
||||
golang.org/x/image v0.0.0-20220601225756-64ec528b34cd // indirect
|
||||
golang.org/x/mobile v0.0.0-20211207041440-4e6c2922fdee // indirect
|
||||
golang.org/x/mod v0.6.0-dev.0.20220106191415-9b9b3d81d5e3 // indirect
|
||||
golang.org/x/sync v0.0.0-20210220032951-036812b2e83c // indirect
|
||||
golang.org/x/sys v0.0.0-20220712014510-0a85c31ab51e // indirect
|
||||
golang.org/x/text v0.3.7 // indirect
|
||||
golang.org/x/tools v0.1.10 // indirect
|
||||
golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1 // indirect
|
||||
gopkg.in/ini.v1 v1.62.0 // indirect
|
||||
gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 // indirect
|
||||
gopkg.in/yaml.v3 v3.0.1 // indirect
|
||||
honnef.co/go/js/dom v0.0.0-20210725211120-f030747120f2 // indirect
|
||||
)
|
||||
|
||||
replace bright => ./sys/configure/bright
|
||||
|
115
go.sum
115
go.sum
@ -43,13 +43,23 @@ dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7
|
||||
dmitri.shuralyov.com/html/belt v0.0.0-20180602232347-f7d459c86be0/go.mod h1:JLBrvjyP0v+ecvNYvCpyZgu5/xkfAUhi6wJj28eUfSU=
|
||||
dmitri.shuralyov.com/service/change v0.0.0-20181023043359-a85b471d5412/go.mod h1:a1inKt/atXimZ4Mv927x+r7UpyzRUf4emIoiiSC2TN4=
|
||||
dmitri.shuralyov.com/state v0.0.0-20180228185332-28bcc343414c/go.mod h1:0PRwlb0D6DFvNNtx+9ybjezNCa8XF0xaYcETyp6rHWU=
|
||||
fyne.io/fyne/v2 v2.2.3 h1:Umi3vVVW8XnWWPJmMkhIWQOMU/jxB1OqpWVUmjhODD0=
|
||||
fyne.io/fyne/v2 v2.2.3/go.mod h1:MBoGuHzLLSXdQOWFAwWhIhYTEMp33zqtGCReSWhaQTA=
|
||||
fyne.io/systray v1.10.1-0.20220621085403-9a2652634e93 h1:V2IC9t0Zj9Ur6qDbfhUuzVmIvXKFyxZXRJyigUvovs4=
|
||||
fyne.io/systray v1.10.1-0.20220621085403-9a2652634e93/go.mod h1:oM2AQqGJ1AMo4nNqZFYU8xYygSBZkW2hmdJ7n4yjedE=
|
||||
git.apache.org/thrift.git v0.0.0-20180902110319-2566ecd5d999/go.mod h1:fPE2ZNJGynbRyZ4dJvy6G277gSllfV2HJqblrnkyeyg=
|
||||
github.com/BabySid/gobase v0.0.0-20220614103908-39ac0a583c02 h1:4VkwDX+9araWz3MeAx/3EAWuQTu+dYnJqBlYrk86i4k=
|
||||
github.com/BabySid/gobase v0.0.0-20220614103908-39ac0a583c02/go.mod h1:psRlcjEywZdxNf9jp6IdYY7VcAsYPtcnLHYQ+dWG5uw=
|
||||
github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
|
||||
github.com/BurntSushi/toml v1.1.0/go.mod h1:CxXYINrC8qIiEnFrOxCa7Jy5BFHlXnUU2pbicEuybxQ=
|
||||
github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo=
|
||||
github.com/ChimeraCoder/gojson v1.1.0/go.mod h1:nYbTQlu6hv8PETM15J927yM0zGj3njIldp72UT1MqSw=
|
||||
github.com/DataDog/datadog-go v3.2.0+incompatible/go.mod h1:LButxg5PwREeZtORoXG3tL4fMGNddJ+vMq1mwgfaqoQ=
|
||||
github.com/Pallinder/go-randomdata v1.2.0 h1:DZ41wBchNRb/0GfsePLiSwb0PHZmT67XY00lCDlaYPg=
|
||||
github.com/Pallinder/go-randomdata v1.2.0/go.mod h1:yHmJgulpD2Nfrm0cR9tI/+oAgRqCQQixsA8HyRZfV9Y=
|
||||
github.com/PuerkitoBio/goquery v1.8.0 h1:PJTF7AmFCFKk1N6V6jmKfrNH9tV5pNE6lZMkG0gta/U=
|
||||
github.com/PuerkitoBio/goquery v1.8.0/go.mod h1:ypIiRMtY7COPGk+I/YbZLbxsxn9g5ejnI2HSMtkjZvI=
|
||||
github.com/akavel/rsrc v0.10.2/go.mod h1:uLoCtb9J+EyAqh+26kdrTgmzRBFPGOolLWKpdxkKq+c=
|
||||
github.com/akutz/memconn v0.1.0 h1:NawI0TORU4hcOMsMr11g7vwlCdkYeLKXBcxWu2W/P8A=
|
||||
github.com/akutz/memconn v0.1.0/go.mod h1:Jo8rI7m0NieZyLI5e2CDlRdRqRRB4S7Xp77ukDjH+Fw=
|
||||
github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc=
|
||||
@ -57,6 +67,8 @@ github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751/go.mod h1:LOuy
|
||||
github.com/alecthomas/units v0.0.0-20151022065526-2efee857e7cf/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0=
|
||||
github.com/alecthomas/units v0.0.0-20190717042225-c3de453c63f4/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0=
|
||||
github.com/aliyun/alibaba-cloud-sdk-go v1.61.18/go.mod h1:v8ESoHo4SyHmuB4b1tJqDHxfTGEciD+yhvOU/5s1Rfk=
|
||||
github.com/andybalholm/cascadia v1.3.1 h1:nhxRkql1kdYCc8Snf7D5/D3spOX+dBgjA6u8x004T2c=
|
||||
github.com/andybalholm/cascadia v1.3.1/go.mod h1:R4bJ1UQfqADjvDa4P6HZHLh/3OxWWEqc0Sk8XGwHqvA=
|
||||
github.com/anmitsu/go-shlex v0.0.0-20161002113705-648efa622239/go.mod h1:2FmKhYUyUczH0OGQWaF5ceTx0UBShxjsH6f8oGKYe2c=
|
||||
github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kdvxnR2qWY=
|
||||
github.com/apache/thrift v0.16.0 h1:qEy6UW60iVOlUy+b9ZR0d5WzUWYGOo4HfopoyBaNmoY=
|
||||
@ -68,6 +80,8 @@ github.com/armon/go-metrics v0.3.10 h1:FR+drcQStOe+32sYyJYyZ7FIdgoGGBnwLl+flodp8
|
||||
github.com/armon/go-metrics v0.3.10/go.mod h1:4O98XIr/9W0sxpJ8UaYkvjk10Iff7SnFrb4QAOwNTFc=
|
||||
github.com/armon/go-radix v0.0.0-20180808171621-7fddfc383310/go.mod h1:ufUuZ+zHj4x4TnLV4JWEpy2hxWSpsRywHrMgIH9cCH8=
|
||||
github.com/armon/go-radix v1.0.0/go.mod h1:ufUuZ+zHj4x4TnLV4JWEpy2hxWSpsRywHrMgIH9cCH8=
|
||||
github.com/atotto/clipboard v0.1.4 h1:EH0zSVneZPSuFR11BlR9YppQTVDbh5+16AmcJi4g1z4=
|
||||
github.com/atotto/clipboard v0.1.4/go.mod h1:ZY9tmq7sm5xIbd9bOK4onWV4S6X0u6GY7Vn0Yu86PYI=
|
||||
github.com/aws/aws-sdk-go v1.34.28 h1:sscPpn/Ns3i0F4HPEWAVcwdIRaZZCuL7llJ2/60yPIk=
|
||||
github.com/aws/aws-sdk-go v1.34.28/go.mod h1:H7NKnBqNVzoTJpGfLrQkkD+ytBA93eiDYi/+8rV9s48=
|
||||
github.com/axgle/mahonia v0.0.0-20180208002826-3358181d7394 h1:OYA+5W64v3OgClL+IrOD63t4i/RW7RqrAVl9LTZ9UqQ=
|
||||
@ -104,6 +118,7 @@ github.com/coreos/go-semver v0.3.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3Ee
|
||||
github.com/coreos/go-systemd v0.0.0-20181012123002-c6f51f82210d/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4=
|
||||
github.com/coreos/go-systemd/v22 v22.3.2/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc=
|
||||
github.com/cpuguy83/go-md2man/v2 v2.0.0/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU=
|
||||
github.com/cpuguy83/go-md2man/v2 v2.0.1/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o=
|
||||
github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E=
|
||||
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
|
||||
github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=
|
||||
@ -136,16 +151,31 @@ github.com/fatih/color v1.13.0 h1:8LOYc1KYPPmyKMuN8QV2DNRWNbLo6LZ0iLs8+mlH53w=
|
||||
github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYFFOfk=
|
||||
github.com/flynn/go-shlex v0.0.0-20150515145356-3f9db97f8568/go.mod h1:xEzjJPgXI435gkrCt3MPfRiAkVrwSbHsst4LCFVfpJc=
|
||||
github.com/francoispqt/gojay v1.2.13/go.mod h1:ehT5mTG4ua4581f1++1WLG0vPdaA9HaiDsoyrBGkyDY=
|
||||
github.com/fredbi/uri v0.0.0-20181227131451-3dcfdacbaaf3 h1:FDqhDm7pcsLhhWl1QtD8vlzI4mm59llRvNzrFg6/LAA=
|
||||
github.com/fredbi/uri v0.0.0-20181227131451-3dcfdacbaaf3/go.mod h1:CzM2G82Q9BDUvMTGHnXf/6OExw/Dz2ivDj48nVg7Lg8=
|
||||
github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo=
|
||||
github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ=
|
||||
github.com/fsnotify/fsnotify v1.5.1 h1:mZcQUHVQUQWoPXXtuf9yuEXKudkV2sx1E06UadKWpgI=
|
||||
github.com/fsnotify/fsnotify v1.5.1/go.mod h1:T3375wBYaZdLLcVNkcVbzGHY7f1l/uK5T5Ai1i3InKU=
|
||||
github.com/fsnotify/fsnotify v1.5.4 h1:jRbGcIw6P2Meqdwuo0H1p6JVLbL5DHKAKlYndzMwVZI=
|
||||
github.com/fsnotify/fsnotify v1.5.4/go.mod h1:OVB6XrOHzAwXMpEM7uPOzcehqUV2UqJxmVXmkdnm1bU=
|
||||
github.com/fyne-io/gl-js v0.0.0-20220119005834-d2da28d9ccfe h1:A/wiwvQ0CAjPkuJytaD+SsXkPU0asQ+guQEIg1BJGX4=
|
||||
github.com/fyne-io/gl-js v0.0.0-20220119005834-d2da28d9ccfe/go.mod h1:d4clgH0/GrRwWjRzJJQXxT/h1TyuNSfF/X64zb/3Ggg=
|
||||
github.com/fyne-io/glfw-js v0.0.0-20220120001248-ee7290d23504 h1:+31CdF/okdokeFNoy9L/2PccG3JFidQT3ev64/r4pYU=
|
||||
github.com/fyne-io/glfw-js v0.0.0-20220120001248-ee7290d23504/go.mod h1:gLRWYfYnMA9TONeppRSikMdXlHQ97xVsPojddUv3b/E=
|
||||
github.com/fyne-io/image v0.0.0-20220602074514-4956b0afb3d2 h1:hnLq+55b7Zh7/2IRzWCpiTcAvjv/P8ERF+N7+xXbZhk=
|
||||
github.com/fyne-io/image v0.0.0-20220602074514-4956b0afb3d2/go.mod h1:eO7W361vmlPOrykIg+Rsh1SZ3tQBaOsfzZhsIOb/Lm0=
|
||||
github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04=
|
||||
github.com/gliderlabs/ssh v0.1.1/go.mod h1:U7qILu1NlMHj9FlMhZLlkCdDnU1DBEAqr0aevW3Awn0=
|
||||
github.com/go-cmd/cmd v1.4.0 h1:dF+1JtZMlgCKAcsvstp2VNmVA/jXRjlRYFOF4/w7Bbo=
|
||||
github.com/go-cmd/cmd v1.4.0/go.mod h1:tbBenttXtZU4c5djS1o7PWL5pd2xAr5sIqH1kGdNiRc=
|
||||
github.com/go-errors/errors v1.0.1/go.mod h1:f4zRHt4oKfwPJE5k8C9vpYG+aDHdBFUsgrm6/TyX73Q=
|
||||
github.com/go-gl/gl v0.0.0-20211210172815-726fda9656d6 h1:zDw5v7qm4yH7N8C8uWd+8Ii9rROdgWxQuGoJ9WDXxfk=
|
||||
github.com/go-gl/gl v0.0.0-20211210172815-726fda9656d6/go.mod h1:9YTyiznxEY1fVinfM7RvRcjRHbw2xLBJ3AAGIT0I4Nw=
|
||||
github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU=
|
||||
github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8=
|
||||
github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8=
|
||||
github.com/go-gl/glfw/v3.3/glfw v0.0.0-20211213063430-748e38ca8aec h1:3FLiRYO6PlQFDpUU7OEFlWgjGD1jnBIVSJ5SYRWk+9c=
|
||||
github.com/go-gl/glfw/v3.3/glfw v0.0.0-20211213063430-748e38ca8aec/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8=
|
||||
github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as=
|
||||
github.com/go-kit/kit v0.9.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as=
|
||||
github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE=
|
||||
@ -155,6 +185,8 @@ github.com/go-logr/logr v1.2.3 h1:2DntVwHkVopvECVRSlL5PSo9eG+cAkDCuckLubN+rq0=
|
||||
github.com/go-logr/logr v1.2.3/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A=
|
||||
github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag=
|
||||
github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE=
|
||||
github.com/go-ole/go-ole v1.2.6 h1:/Fpf6oFPoeFik9ty7siob0G6Ke8QvQEuVcuChpwXzpY=
|
||||
github.com/go-ole/go-ole v1.2.6/go.mod h1:pprOEPIfldk/42T2oK7lQ4v4JSDwmV0As9GaiUsvbm0=
|
||||
github.com/go-ping/ping v0.0.0-20211130115550-779d1e919534 h1:dhy9OQKGBh4zVXbjwbxxHjRxMJtLXj3zfgpBYQaR4Q4=
|
||||
github.com/go-ping/ping v0.0.0-20211130115550-779d1e919534/go.mod h1:xIFjORFzTxqIV/tDVGO4eDy/bLuSyawEeojSm3GfRGk=
|
||||
github.com/go-playground/assert/v2 v2.0.1 h1:MsBgLAaY856+nPRTKrp3/OZK38U/wa0CcBYNjji3q3A=
|
||||
@ -176,6 +208,7 @@ github.com/go-stack/stack v1.8.0 h1:5SgMzNM5HxrEjV0ww2lTmX6E2Izsfxas4+YHWRs3Lsk=
|
||||
github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY=
|
||||
github.com/go-task/slim-sprig v0.0.0-20210107165309-348f09dbbbc0 h1:p104kn46Q8WdvHunIJ9dAyjPVtrBPhSr3KT2yUst43I=
|
||||
github.com/go-task/slim-sprig v0.0.0-20210107165309-348f09dbbbc0/go.mod h1:fyg7847qk6SyHyPtNmDHnmrv/HOrqktSC+C9fM+CJOE=
|
||||
github.com/go-test/deep v1.0.7 h1:/VSMRlnY/JSyqxQUzQLKVMAskpY/NZKFA5j2P+0pP2M=
|
||||
github.com/gobuffalo/attrs v0.0.0-20190224210810-a9411de4debd/go.mod h1:4duuawTqi2wkkpB4ePgWMaai6/Kc6WEz83bhFwpHzj0=
|
||||
github.com/gobuffalo/depgen v0.0.0-20190329151759-d478694a28d3/go.mod h1:3STtPUQYuzV0gBVOY3vy6CfMm/ljR4pABfrTeHNLHUY=
|
||||
github.com/gobuffalo/depgen v0.1.0/go.mod h1:+ifsuy7fhi15RWncXQQKjWS9JPkdah5sZvtHc2RXGlg=
|
||||
@ -201,10 +234,14 @@ github.com/gobuffalo/packr/v2 v2.0.9/go.mod h1:emmyGweYTm6Kdper+iywB6YK5YzuKchGt
|
||||
github.com/gobuffalo/packr/v2 v2.2.0/go.mod h1:CaAwI0GPIAv+5wKLtv8Afwl+Cm78K/I/VCm/3ptBN+0=
|
||||
github.com/gobuffalo/syncx v0.0.0-20190224160051-33c29581e754/go.mod h1:HhnNqWY95UYwwW3uSASeV7vtgYkT2t16hJgV3AEPUpw=
|
||||
github.com/godbus/dbus/v5 v5.0.4/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA=
|
||||
github.com/godbus/dbus/v5 v5.1.0 h1:4KLkAxT3aOY8Li4FRJe/KvhoNFFxo0m6fNuFUO8QJUk=
|
||||
github.com/godbus/dbus/v5 v5.1.0/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA=
|
||||
github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ=
|
||||
github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q=
|
||||
github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q=
|
||||
github.com/goji/httpauth v0.0.0-20160601135302-2da839ab0f4d/go.mod h1:nnjvkQ9ptGaCkuDUx6wNykzzlUixGxvkme+H/lnzb+A=
|
||||
github.com/goki/freetype v0.0.0-20181231101311-fa8a33aabaff h1:W71vTCKoxtdXgnm1ECDFkfQnpdqAO00zzGXLA5yaEX8=
|
||||
github.com/goki/freetype v0.0.0-20181231101311-fa8a33aabaff/go.mod h1:wfqRWLHRBsRgkp5dmbG56SA0DmVtwrF5N3oPdI8t+Aw=
|
||||
github.com/golang-jwt/jwt v3.2.2+incompatible h1:IfV12K8xAKAnZqdXVzCZ+TOjboZ2keLg81eXfW3O+oY=
|
||||
github.com/golang-jwt/jwt v3.2.2+incompatible/go.mod h1:8pz2t5EyA70fFQQSrl6XZXzqecmYZeUEB8OUGHkxJ+I=
|
||||
github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q=
|
||||
@ -288,8 +325,13 @@ github.com/googleapis/gax-go/v2 v2.0.3/go.mod h1:LLvjysVCY1JZeum8Z6l8qUty8fiNwE0
|
||||
github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg=
|
||||
github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk=
|
||||
github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY=
|
||||
github.com/gopherjs/gopherjs v0.0.0-20211219123610-ec9572f70e60/go.mod h1:cz9oNYuRUWGdHmLF2IodMLkAhcPtXeULvcBNagUrxTI=
|
||||
github.com/gopherjs/gopherjs v1.17.2 h1:fQnZVsXk8uxXIStYb0N4bGk7jeyTalG/wsZjQ25dO0g=
|
||||
github.com/gopherjs/gopherjs v1.17.2/go.mod h1:pRRIvn/QzFLrKfvEz3qUuEhtE/zLCWfreZ6J5gM2i+k=
|
||||
github.com/gorilla/websocket v1.4.2 h1:+/TMaTYc4QFitKJxsQ7Yye35DkWvkdLcvGKqM+x0Ufc=
|
||||
github.com/gorilla/websocket v1.4.2/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE=
|
||||
github.com/goxjs/gl v0.0.0-20210104184919-e3fafc6f8f2a/go.mod h1:dy/f2gjY09hwVfIyATps4G2ai7/hLwLkc5TrPqONuXY=
|
||||
github.com/goxjs/glfw v0.0.0-20191126052801-d2efb5f20838/go.mod h1:oS8P8gVOT4ywTcjV6wZlOU4GuVFQ8F5328KY3MJ79CY=
|
||||
github.com/grandcat/zeroconf v1.0.0 h1:uHhahLBKqwWBV6WZUDAT71044vwOTL+McW0mBJvo6kE=
|
||||
github.com/grandcat/zeroconf v1.0.0/go.mod h1:lTKmG1zh86XyCoUeIHSA4FJMBwCJiQmGfcP2PdzytEs=
|
||||
github.com/gregjones/httpcache v0.0.0-20180305231024-9cad4c3443a7/go.mod h1:FecbI9+v66THATjSRHfNgh1IVFe/9kFxbXtjV0ctIMA=
|
||||
@ -339,6 +381,7 @@ github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ
|
||||
github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8=
|
||||
github.com/hashicorp/golang-lru v0.5.4 h1:YDjusn29QI/Das2iO9M0BHnIbxPeyuCHsjMW+lJfyTc=
|
||||
github.com/hashicorp/golang-lru v0.5.4/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uGBxy+E8yxSoD4=
|
||||
github.com/hashicorp/hcl v1.0.0 h1:0Anlzjpi4vEasTeNFn2mLJgTSwt0+6sfsiTG8qcWGx4=
|
||||
github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ=
|
||||
github.com/hashicorp/logutils v1.0.0/go.mod h1:QIAnNjmIWmVIIkWDTG1z5v++HQmx9WQRO+LraFDTW64=
|
||||
github.com/hashicorp/mdns v1.0.0/go.mod h1:tL+uN++7HEJ6SQLQ2/p+z2pH24WQKWjBPkE0mNTz8vQ=
|
||||
@ -360,6 +403,7 @@ github.com/inconshreveable/mousetrap v1.0.0 h1:Z8tu5sraLXCXIcARxBp/8cbvlwVa7Z1NH
|
||||
github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8=
|
||||
github.com/influxdata/influxdb1-client v0.0.0-20220302092344-a9ab5670611c h1:qSHzRbhzK8RdXOsAdfDgO49TtqC1oZ+acxPrkfTxcCs=
|
||||
github.com/influxdata/influxdb1-client v0.0.0-20220302092344-a9ab5670611c/go.mod h1:qj24IKcXYK6Iy9ceXlo3Tc+vtHo9lIhSX5JddghvEPo=
|
||||
github.com/jackmordaunt/icns/v2 v2.2.1/go.mod h1:6aYIB9eSzyfHHMKqDf17Xrs1zetQPReAkiUSHzdw4cI=
|
||||
github.com/jehiah/go-strftime v0.0.0-20171201141054-1d33003b3869 h1:IPJ3dvxmJ4uczJe5YQdrYB16oTJlGSC/OyZDqUk9xX4=
|
||||
github.com/jehiah/go-strftime v0.0.0-20171201141054-1d33003b3869/go.mod h1:cJ6Cj7dQo+O6GJNiMx+Pa94qKj+TG8ONdKHgMNIyyag=
|
||||
github.com/jellevandenhooff/dkim v0.0.0-20150330215556-f50fe3d243e1/go.mod h1:E0B/fFc00Y+Rasa88328GlI/XbtyysCtTHZS8h7IrBU=
|
||||
@ -371,6 +415,7 @@ github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfC
|
||||
github.com/joho/godotenv v1.3.0/go.mod h1:7hK45KPybAkOC6peb+G5yklZfMxEjkZhHbwpqxOKXbg=
|
||||
github.com/jonboulle/clockwork v0.1.0 h1:VKV+ZcuP6l3yW9doeqz6ziZGgcynBVQO+obU0+0hcPo=
|
||||
github.com/jonboulle/clockwork v0.1.0/go.mod h1:Ii8DK3G1RaLaWxj9trq07+26W01tbo22gdxWY5EU2bo=
|
||||
github.com/josephspurrier/goversioninfo v1.4.0/go.mod h1:JWzv5rKQr+MmW+LvM412ToT/IkYDZjaclF2pKDss8IY=
|
||||
github.com/json-iterator/go v1.1.5/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU=
|
||||
github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU=
|
||||
github.com/json-iterator/go v1.1.9/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4=
|
||||
@ -379,6 +424,9 @@ github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnr
|
||||
github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo=
|
||||
github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU=
|
||||
github.com/jstemmer/go-junit-report v0.9.1/go.mod h1:Brl9GWCQeLvo8nXZwPNNblvFj/XSXhF0NWZEnDohbsk=
|
||||
github.com/jsummers/gobmp v0.0.0-20151104160322-e2ba15ffa76e h1:LvL4XsI70QxOGHed6yhQtAU34Kx3Qq2wwBzGFKY8zKk=
|
||||
github.com/jsummers/gobmp v0.0.0-20151104160322-e2ba15ffa76e/go.mod h1:kLgvv7o6UM+0QSf0QjAse3wReFDsb9qbZJdfexWlrQw=
|
||||
github.com/jtolds/gls v4.20.0+incompatible h1:xdiiI2gbIgH/gLH7ADydsJ1uDOEzR8yvV7C0MuV77Wo=
|
||||
github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU=
|
||||
github.com/juju/ratelimit v1.0.1 h1:+7AIFJVQ0EQgq/K9+0Krm7m530Du7tIz0METWzN0RgY=
|
||||
github.com/juju/ratelimit v1.0.1/go.mod h1:qapgC/Gy+xNh9UxzV13HGGl/6UXNN+ct+vwSgWNm/qk=
|
||||
@ -424,7 +472,11 @@ github.com/lestrrat/go-strftime v0.0.0-20180220042222-ba3bf9c1d042/go.mod h1:TPp
|
||||
github.com/lucas-clemente/quic-go v0.24.0/go.mod h1:paZuzjXCE5mj6sikVLMvqXk8lJV2AsqtJ6bDhjEfxx0=
|
||||
github.com/lucas-clemente/quic-go v0.27.0 h1:v6WY87q9zD4dKASbG8hy/LpzAVNzEQzw8sEIeloJsc4=
|
||||
github.com/lucas-clemente/quic-go v0.27.0/go.mod h1:AzgQoPda7N+3IqMMMkywBKggIFo2KT6pfnlrQ2QieeI=
|
||||
github.com/lucor/goinfo v0.0.0-20210802170112-c078a2b0f08b/go.mod h1:PRq09yoB+Q2OJReAmwzKivcYyremnibWGbK7WfftHzc=
|
||||
github.com/lufia/plan9stats v0.0.0-20211012122336-39d0f177ccd0 h1:6E+4a0GO5zZEnZ81pIr0yLvtUWk2if982qA3F3QD6H4=
|
||||
github.com/lufia/plan9stats v0.0.0-20211012122336-39d0f177ccd0/go.mod h1:zJYVVT2jmtg6P3p1VtQj7WsuWi/y4VnjVBn7F8KPB3I=
|
||||
github.com/lunixbochs/vtclean v1.0.0/go.mod h1:pHhQNgMf3btfWnGBVipUOjRYhoOsdGqdm/+2c2E2WMI=
|
||||
github.com/magiconair/properties v1.8.5 h1:b6kJs+EmPFMYGkow9GiUyCyOvIwYetYJ3fSaWak/Gls=
|
||||
github.com/magiconair/properties v1.8.5/go.mod h1:y3VJvCyxH9uVvJTWEGAELF3aiYNyPKd5NZ3oSwXrF60=
|
||||
github.com/mailru/easyjson v0.0.0-20190312143242-1de009706dbe/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc=
|
||||
github.com/markbates/oncer v0.0.0-20181203154359-bf2de49a0be2/go.mod h1:Ld9puTsIW75CHf65OeIOkyKbteujpZVXDpWK6YGZbxE=
|
||||
@ -453,7 +505,10 @@ github.com/mattn/go-isatty v0.0.11/go.mod h1:PhnuNfih5lzO57/f3n+odYbM4JtupLOxQOA
|
||||
github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU=
|
||||
github.com/mattn/go-isatty v0.0.14 h1:yVuAays6BHfxijgZPzw+3Zlu5yQgKGP2/hcQbHb7S9Y=
|
||||
github.com/mattn/go-isatty v0.0.14/go.mod h1:7GGIvUiUoEMVVmxf/4nioHXj79iQHKdU27kJ6hsGG94=
|
||||
github.com/mattn/go-sqlite3 v1.14.12 h1:TJ1bhYJPV44phC+IMu1u2K/i5RriLTPe+yc68XDJ1Z0=
|
||||
github.com/mattn/go-sqlite3 v1.14.12/go.mod h1:NyWgC/yNuGj7Q9rpYnZvas74GogHl5/Z4A/KQRfk6bU=
|
||||
github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0=
|
||||
github.com/mcuadros/go-version v0.0.0-20190830083331-035f6764e8d2/go.mod h1:76rfSfYPWj01Z85hUf/ituArm797mNKcvINh1OlsZKo=
|
||||
github.com/microcosm-cc/bluemonday v1.0.1/go.mod h1:hsXNsILzKxV+sX77C5b8FSuKF00vh2OMYv+xgHpAMF4=
|
||||
github.com/miekg/dns v1.0.14/go.mod h1:W1PPwlIAgtquWBMBEV9nkV9Cazfe8ScdGz/Lj7v3Nrg=
|
||||
github.com/miekg/dns v1.1.26/go.mod h1:bPDLeHnStXmXAq1m/Ch/hvfNHr14JKNPMBo3VZKjuso=
|
||||
@ -488,6 +543,9 @@ github.com/nacos-group/nacos-sdk-go v1.0.8 h1:8pEm05Cdav9sQgJSv5kyvlgfz0SzFUUGI3
|
||||
github.com/nacos-group/nacos-sdk-go v1.0.8/go.mod h1:hlAPn3UdzlxIlSILAyOXKxjFSvDJ9oLzTJ9hLAK1KzA=
|
||||
github.com/neelance/astrewrite v0.0.0-20160511093645-99348263ae86/go.mod h1:kHJEU3ofeGjhHklVoIGuVj85JJwZ6kWPaJwCIxgnFmo=
|
||||
github.com/neelance/sourcemap v0.0.0-20151028013722-8c68805598ab/go.mod h1:Qr6/a/Q4r9LP1IltGz7tA7iOK1WonHEYhu1HRBA7ZiM=
|
||||
github.com/neelance/sourcemap v0.0.0-20200213170602-2833bce08e4c/go.mod h1:Qr6/a/Q4r9LP1IltGz7tA7iOK1WonHEYhu1HRBA7ZiM=
|
||||
github.com/nfnt/resize v0.0.0-20180221191011-83c6a9932646/go.mod h1:jpp1/29i3P1S/RLdc7JQKbRpFeM1dOBd8T9ki5s+AY8=
|
||||
github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e/go.mod h1:zD1mROLANZcx1PVRCS0qkT7pwLkGfwJo4zjcN/Tysno=
|
||||
github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A=
|
||||
github.com/nxadm/tail v1.4.8 h1:nPr65rt6Y5JFSKQO7qToXr7pePgD6Gwiw05lkbyAQTE=
|
||||
github.com/nxadm/tail v1.4.8/go.mod h1:+ncqLTQzXmGhMZNUePPaPqPvBxHAIsmXswZKocGu+AU=
|
||||
@ -513,6 +571,7 @@ github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FI
|
||||
github.com/pascaldekloe/goe v0.1.0 h1:cBOtyMzM9HTpWjXfbbunk26uA6nG3a8n06Wieeh0MwY=
|
||||
github.com/pascaldekloe/goe v0.1.0/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc=
|
||||
github.com/pelletier/go-toml v1.7.0/go.mod h1:vwGMzjaWMwyfHwgIBhI2YUM4fB6nL6lVAvS1LBMMhTE=
|
||||
github.com/pelletier/go-toml v1.9.3 h1:zeC5b1GviRUyKYd6OJPvBU/mcVDVoL1OhT17FCt5dSQ=
|
||||
github.com/pelletier/go-toml v1.9.3/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c=
|
||||
github.com/peterbourgon/g2s v0.0.0-20140925154142-ec76db4c1ac1 h1:5Dl+ADmsGerAqHwWzyLqkNaUBQ+48DQwfDCaW1gHAQM=
|
||||
github.com/peterbourgon/g2s v0.0.0-20140925154142-ec76db4c1ac1/go.mod h1:1VcHEd3ro4QMoHfiNl/j7Jkln9+KQuorp0PItHMJYNg=
|
||||
@ -528,6 +587,8 @@ github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZb
|
||||
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
|
||||
github.com/posener/complete v1.1.1/go.mod h1:em0nMJCgc9GFtwrmVmEMR/ZL6WyhyjMBndrE9hABlRI=
|
||||
github.com/posener/complete v1.2.3/go.mod h1:WZIdtGGp+qx0sLrYKtIRAruyNpv6hFCicSgv7Sy7s/s=
|
||||
github.com/power-devops/perfstat v0.0.0-20210106213030-5aafc221ea8c h1:ncq/mPwQF4JjgDlrVEn3C11VoGHZN7m8qihwgMEtzYw=
|
||||
github.com/power-devops/perfstat v0.0.0-20210106213030-5aafc221ea8c/go.mod h1:OmDBASR4679mdNQnz2pUhc2G8CO2JrUAVFDRBDP/hJE=
|
||||
github.com/prometheus/client_golang v0.8.0/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw=
|
||||
github.com/prometheus/client_golang v0.9.1/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw=
|
||||
github.com/prometheus/client_golang v1.0.0/go.mod h1:db9x61etRT2tGnBNRi70OPL5FsnadC4Ky3P0J6CfImo=
|
||||
@ -564,6 +625,7 @@ github.com/rubyist/circuitbreaker v2.2.1+incompatible h1:KUKd/pV8Geg77+8LNDwdow6
|
||||
github.com/rubyist/circuitbreaker v2.2.1+incompatible/go.mod h1:Ycs3JgJADPuzJDwffe12k6BZT8hxVi6lFK+gWYJLN4A=
|
||||
github.com/russross/blackfriday v1.5.2/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR/rfWxYHBV53g=
|
||||
github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
|
||||
github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
|
||||
github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts=
|
||||
github.com/samuel/go-zookeeper v0.0.0-20201211165307-7117e9ea2414 h1:AJNDS0kP60X8wwWFvbLPwDuojxubj9pbfK7pjHw0vKg=
|
||||
github.com/samuel/go-zookeeper v0.0.0-20201211165307-7117e9ea2414/go.mod h1:gi+0XIa01GRL2eRQVjQkKGqKF3SF9vZR/HnPullcV2E=
|
||||
@ -573,10 +635,13 @@ github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529 h1:nn5Wsu0esKSJiIVhscUt
|
||||
github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc=
|
||||
github.com/sergi/go-diff v1.0.0/go.mod h1:0CfEIISq7TuYL3j771MWULgwwjU+GofnZX9QAmXWZgo=
|
||||
github.com/serialx/hashring v0.0.0-20200727003509-22c0c7ab6b1b/go.mod h1:/yeG0My1xr/u+HZrFQ1tOQQQQrOawfyMUH13ai5brBc=
|
||||
github.com/shirou/gopsutil/v3 v3.22.2 h1:wCrArWFkHYIdDxx/FSfF5RB4dpJYW6t7rcp3+zL8uks=
|
||||
github.com/shirou/gopsutil/v3 v3.22.2/go.mod h1:WapW1AOOPlHyXr+yOyw3uYx36enocrtSoSBy0L5vUHY=
|
||||
github.com/shurcooL/component v0.0.0-20170202220835-f88ec8f54cc4/go.mod h1:XhFIlyj5a1fBNx5aJTbKoIq0mNaPvOagO+HjB3EtxrY=
|
||||
github.com/shurcooL/events v0.0.0-20181021180414-410e4ca65f48/go.mod h1:5u70Mqkb5O5cxEA8nxTsgrgLehJeAw6Oc4Ab1c/P1HM=
|
||||
github.com/shurcooL/github_flavored_markdown v0.0.0-20181002035957-2122de532470/go.mod h1:2dOwnU2uBioM+SGy2aZoq1f/Sd1l9OkAeAUvjSyvgU0=
|
||||
github.com/shurcooL/go v0.0.0-20180423040247-9e1955d9fb6e/go.mod h1:TDJrrUr11Vxrven61rcy3hJMUqaf/CLWYhHNPmT14Lk=
|
||||
github.com/shurcooL/go v0.0.0-20200502201357-93f07166e636/go.mod h1:TDJrrUr11Vxrven61rcy3hJMUqaf/CLWYhHNPmT14Lk=
|
||||
github.com/shurcooL/go-goon v0.0.0-20170922171312-37c2f522c041/go.mod h1:N5mDOmsrJOB+vfqUK+7DmDyjhSLIIBnXo9lvZJj3MWQ=
|
||||
github.com/shurcooL/gofontwoff v0.0.0-20180329035133-29b52fc0a18d/go.mod h1:05UtEgK5zq39gLST6uB0cf3NEHjETfB4Fgr3Gx5R9Vw=
|
||||
github.com/shurcooL/gopherjslib v0.0.0-20160914041154-feb6d3990c2c/go.mod h1:8d3azKNyqcHP1GaQE/c6dDgjkgSx2BZ4IoEi4F1reUI=
|
||||
@ -586,6 +651,7 @@ github.com/shurcooL/home v0.0.0-20181020052607-80b7ffcb30f9/go.mod h1:+rgNQw2P9A
|
||||
github.com/shurcooL/htmlg v0.0.0-20170918183704-d01228ac9e50/go.mod h1:zPn1wHpTIePGnXSHpsVPWEktKXHr6+SS6x/IKRb7cpw=
|
||||
github.com/shurcooL/httperror v0.0.0-20170206035902-86b7830d14cc/go.mod h1:aYMfkZ6DWSJPJ6c4Wwz3QtW22G7mf/PEgaB9k/ik5+Y=
|
||||
github.com/shurcooL/httpfs v0.0.0-20171119174359-809beceb2371/go.mod h1:ZY1cvUeJuFPAdZ/B6v7RHavJWZn2YPVFQ1OSXhCGOkg=
|
||||
github.com/shurcooL/httpfs v0.0.0-20190707220628-8d4bc4ba7749/go.mod h1:ZY1cvUeJuFPAdZ/B6v7RHavJWZn2YPVFQ1OSXhCGOkg=
|
||||
github.com/shurcooL/httpgzip v0.0.0-20180522190206-b1c53ac65af9/go.mod h1:919LwcH0M7/W4fcZ0/jy0qGght1GIhqyS/EgWGH2j5Q=
|
||||
github.com/shurcooL/issues v0.0.0-20181008053335-6292fdc1e191/go.mod h1:e2qWDig5bLteJ4fwvDAc2NHzqFEthkqn7aOZAOpj+PQ=
|
||||
github.com/shurcooL/issuesapp v0.0.0-20180602232740-048589ce2241/go.mod h1:NPpHK2TI7iSaM0buivtFUc9offApnI0Alt/K8hcHy0I=
|
||||
@ -595,6 +661,7 @@ github.com/shurcooL/reactions v0.0.0-20181006231557-f2e0b4ca5b82/go.mod h1:TCR1l
|
||||
github.com/shurcooL/sanitized_anchor_name v0.0.0-20170918181015-86672fcb3f95/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc=
|
||||
github.com/shurcooL/sanitized_anchor_name v1.0.0/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc=
|
||||
github.com/shurcooL/users v0.0.0-20180125191416-49c67e49c537/go.mod h1:QJTqeLYEDaXHZDBsXlPCDqdhQuJkuw4NOtaxYe3xii4=
|
||||
github.com/shurcooL/vfsgen v0.0.0-20200824052919-0d455de96546/go.mod h1:TrYk7fJVaAttu97ZZKrO9UbRa8izdowaMIZcxYMbVaw=
|
||||
github.com/shurcooL/webdavfs v0.0.0-20170829043945-18c3829fa133/go.mod h1:hKmq5kWdCj2z2KEozexVbfEZIWiTjhE0+UjmZgPqehw=
|
||||
github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo=
|
||||
github.com/sirupsen/logrus v1.4.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo=
|
||||
@ -606,24 +673,33 @@ github.com/smallnest/quick v0.0.0-20220103065406-780def6371e6 h1:J8xk0QMMrqfDLqU
|
||||
github.com/smallnest/quick v0.0.0-20220103065406-780def6371e6/go.mod h1:h+J5yoLzf3XMKtM9l4vOaUtS4e+si6T3sKDtheJ15wc=
|
||||
github.com/smallnest/rpcx v1.7.4 h1:u6ADk/Ep8BqtAoJZO7LbniWsP+nqeAtcbaPm2D4eOXg=
|
||||
github.com/smallnest/rpcx v1.7.4/go.mod h1:TSciUoPlm8MYxnC7ErCz5ZymOFxOTbhN9cRgEI6Degs=
|
||||
github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d h1:zE9ykElWQ6/NYmHa3jpm/yHnI4xSofP+UP6SpjHcSeM=
|
||||
github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc=
|
||||
github.com/smartystreets/goconvey v0.0.0-20190330032615-68dc04aab96a/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9QV7WQ/tjFTllLA=
|
||||
github.com/smartystreets/goconvey v1.6.4 h1:fv0U8FUIMPNf1L9lnHLvLhgicrIVChEkdzIKYqbNC9s=
|
||||
github.com/smartystreets/goconvey v1.6.4/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9QV7WQ/tjFTllLA=
|
||||
github.com/soheilhy/cmux v0.1.5 h1:jjzc5WVemNEDTLwv9tlmemhC73tI08BNOIGwBOo10Js=
|
||||
github.com/soheilhy/cmux v0.1.5/go.mod h1:T7TcVDs9LWfQgPlPsdngu6I6QIoyIFZDDC6sNE1GqG0=
|
||||
github.com/sourcegraph/annotate v0.0.0-20160123013949-f4cad6c6324d/go.mod h1:UdhH50NIW0fCiwBSr0co2m7BnFLdv4fQTgdqdJTHFeE=
|
||||
github.com/sourcegraph/syntaxhighlight v0.0.0-20170531221838-bd320f5d308e/go.mod h1:HuIsMU8RRBOtsCgI77wP899iHVBQpCmg4ErYMZB+2IA=
|
||||
github.com/spf13/afero v1.6.0 h1:xoax2sJ2DT8S8xA2paPFjDCScCNeWsg75VG0DLRreiY=
|
||||
github.com/spf13/afero v1.6.0/go.mod h1:Ai8FlHk4v/PARR026UzYexafAt9roJ7LcLMAmO6Z93I=
|
||||
github.com/spf13/cast v1.3.1 h1:nFm6S0SMdyzrzcmThSipiEubIDy8WEXKNZ0UOgiRpng=
|
||||
github.com/spf13/cast v1.3.1/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE=
|
||||
github.com/spf13/cobra v0.0.3/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ=
|
||||
github.com/spf13/cobra v1.2.1 h1:+KmjbUw1hriSNMF55oPrkZcb27aECyrj8V2ytv7kWDw=
|
||||
github.com/spf13/cobra v1.2.1/go.mod h1:ExllRjgxM/piMAM+3tAZvg8fsklGAf3tPfi+i8t68Nk=
|
||||
github.com/spf13/jwalterweatherman v1.1.0 h1:ue6voC5bR5F8YxI5S67j9i582FU4Qvo2bmqnqMYADFk=
|
||||
github.com/spf13/jwalterweatherman v1.1.0/go.mod h1:aNWZUN0dPAAO/Ljvb5BEdw96iTZ0EXowPYD95IqWIGo=
|
||||
github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4=
|
||||
github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA=
|
||||
github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg=
|
||||
github.com/spf13/viper v1.8.1 h1:Kq1fyeebqsBfbjZj4EL7gj2IO0mMaiyjYUWcUsl2O44=
|
||||
github.com/spf13/viper v1.8.1/go.mod h1:o0Pch8wJ9BVSWGQMbra6iw0oQ5oktSIBaujf1rJH9Ns=
|
||||
github.com/srwiley/oksvg v0.0.0-20200311192757-870daf9aa564 h1:HunZiaEKNGVdhTRQOVpMmj5MQnGnv+e8uZNu3xFLgyM=
|
||||
github.com/srwiley/oksvg v0.0.0-20200311192757-870daf9aa564/go.mod h1:afMbS0qvv1m5tfENCwnOdZGOF8RGR/FsZ7bvBxQGZG4=
|
||||
github.com/srwiley/rasterx v0.0.0-20200120212402-85cb7272f5e9 h1:m59mIOBO4kfcNCEzJNy71UkeF4XIx2EVmL9KLwDQdmM=
|
||||
github.com/srwiley/rasterx v0.0.0-20200120212402-85cb7272f5e9/go.mod h1:mvWM0+15UqyrFKqdRjY6LuAVJR0HOVhJlEgZ5JWtSWU=
|
||||
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
|
||||
github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
|
||||
github.com/stretchr/objx v0.3.0 h1:NGXK3lHquSN08v5vWalVI/L8XU9hdzE/G6xsrze47As=
|
||||
@ -634,8 +710,10 @@ github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81P
|
||||
github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA=
|
||||
github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
|
||||
github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
|
||||
github.com/stretchr/testify v1.7.1 h1:5TQK59W5E3v0r2duFAb7P95B6hEeOyEnHRa8MjYSMTY=
|
||||
github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
|
||||
github.com/stretchr/testify v1.7.2 h1:4jaiDzPyXQvSd7D0EjG45355tLlV3VOECpq10pLC+8s=
|
||||
github.com/stretchr/testify v1.7.2/go.mod h1:R6va5+xMeoiuVRoj+gSkQ7d3FALtqAAGI1FQKckRals=
|
||||
github.com/subosito/gotenv v1.2.0 h1:Slr1R9HxAlEKefgq5jn9U+DnETlIUa6HfgEzj0g5d7s=
|
||||
github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69rRypqCw=
|
||||
github.com/tarm/serial v0.0.0-20180830185346-98f6abe2eb07/go.mod h1:kDXzergiv9cbyO7IOYJZWg1U88JhDg3PB6klq9Hg2pA=
|
||||
github.com/tebeka/strftime v0.1.3 h1:5HQXOqWKYRFfNyBMNVc9z5+QzuBtIXy03psIhtdJYto=
|
||||
@ -644,6 +722,8 @@ github.com/templexxx/cpufeat v0.0.0-20180724012125-cef66df7f161 h1:89CEmDvlq/F7S
|
||||
github.com/templexxx/cpufeat v0.0.0-20180724012125-cef66df7f161/go.mod h1:wM7WEvslTq+iOEAMDLSzhVuOt5BRZ05WirO+b09GHQU=
|
||||
github.com/templexxx/xor v0.0.0-20191217153810-f85b25db303b h1:fj5tQ8acgNUr6O8LEplsxDhUIe2573iLkJc+PqnzZTI=
|
||||
github.com/templexxx/xor v0.0.0-20191217153810-f85b25db303b/go.mod h1:5XA7W9S6mni3h5uvOC75dA3m9CCCaS83lltmc0ukdi4=
|
||||
github.com/tevino/abool v1.2.0 h1:heAkClL8H6w+mK5md9dzsuohKeXHUpY7Vw0ZCKW+huA=
|
||||
github.com/tevino/abool v1.2.0/go.mod h1:qc66Pna1RiIsPa7O4Egxxs9OqkuxDX55zznh9K07Tzg=
|
||||
github.com/tidwall/gjson v1.14.1 h1:iymTbGkQBhveq21bEvAQ81I0LEBork8BFe1CUZXdyuo=
|
||||
github.com/tidwall/gjson v1.14.1/go.mod h1:/wbyibRr2FHMks5tjHJ5F8dMZh3AcwJEMf5vlfC0lxk=
|
||||
github.com/tidwall/match v1.1.1 h1:+Ho715JplO36QYgwN9PGYNhgZvoUSc9X2c80KVTi+GA=
|
||||
@ -655,11 +735,16 @@ github.com/tinylib/msgp v1.1.6 h1:i+SbKraHhnrf9M5MYmvQhFnbLhAXSDWF8WWsuyRdocw=
|
||||
github.com/tinylib/msgp v1.1.6/go.mod h1:75BAfg2hauQhs3qedfdDZmWAPcFMAvJE5b9rGOMufyw=
|
||||
github.com/tjfoc/gmsm v1.4.1 h1:aMe1GlZb+0bLjn+cKTPEvvn9oUEBlJitaZiiBwsbgho=
|
||||
github.com/tjfoc/gmsm v1.4.1/go.mod h1:j4INPkHWMrhJb38G+J6W4Tw0AbuN8Thu3PbdVYhVcTE=
|
||||
github.com/tklauser/go-sysconf v0.3.9 h1:JeUVdAOWhhxVcU6Eqr/ATFHgXk/mmiItdKeJPev3vTo=
|
||||
github.com/tklauser/go-sysconf v0.3.9/go.mod h1:11DU/5sG7UexIrp/O6g35hrWzu0JxlwQ3LSFUzyeuhs=
|
||||
github.com/tklauser/numcpus v0.3.0 h1:ILuRUQBtssgnxw0XXIjKUC56fgnOrFoQQ/4+DeU2biQ=
|
||||
github.com/tklauser/numcpus v0.3.0/go.mod h1:yFGUr7TUHQRAhyqBcEg0Ge34zDBAsIvJJcyE6boqnA8=
|
||||
github.com/toolkits/concurrent v0.0.0-20150624120057-a4371d70e3e3/go.mod h1:QDlpd3qS71vYtakd2hmdpqhJ9nwv6mD6A30bQ1BPBFE=
|
||||
github.com/tv42/httpunix v0.0.0-20150427012821-b75d8614f926/go.mod h1:9ESjWnEqriFuLhtthL60Sar/7RFoluCcXsuvEwTV5KM=
|
||||
github.com/ugorji/go v1.2.7/go.mod h1:nF9osbDWLy6bDVv/Rtoh6QgnvNDpmCalQV5urGCCS6M=
|
||||
github.com/ugorji/go/codec v1.2.7 h1:YPXUKf7fYbp/y8xloBqZOw2qaVggbfwMlI8WM3wZUJ0=
|
||||
github.com/ugorji/go/codec v1.2.7/go.mod h1:WGN1fab3R1fzQlVQTkfxVtIBhWDRqOviHU95kRgeqEY=
|
||||
github.com/urfave/cli/v2 v2.4.0/go.mod h1:NX9W0zmTvedE5oDoOMs2RTC8RvdK98NTYZE5LbaEYPg=
|
||||
github.com/valyala/bytebufferpool v1.0.0 h1:GqA5TC/0021Y/b9FG4Oi9Mr3q7XYx6KllzawFIhcdPw=
|
||||
github.com/valyala/bytebufferpool v1.0.0/go.mod h1:6bBcMArwyJ5K/AmCkWv1jt77kVWyCJ6HpOuEn7z0Csc=
|
||||
github.com/valyala/fastrand v1.1.0 h1:f+5HkLW4rsgzdNoleUOB69hyT9IlD2ZQh9GyDMfb5G8=
|
||||
@ -687,7 +772,11 @@ github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9de
|
||||
github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
|
||||
github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
|
||||
github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k=
|
||||
github.com/yuin/goldmark v1.4.0/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k=
|
||||
github.com/yuin/goldmark v1.4.1 h1:/vn0k+RBvwlxEmP5E7SZMqNxPhfMVFEJiykr15/0XKM=
|
||||
github.com/yuin/goldmark v1.4.1/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k=
|
||||
github.com/yusufpapurcu/wmi v1.2.2 h1:KBNDSne4vP5mbSWnJbO+51IMOXJB67QiYCSBrubbPRg=
|
||||
github.com/yusufpapurcu/wmi v1.2.2/go.mod h1:SBZ9tNy3G9/m5Oi98Zks0QjeHVDvuK0qfxQmPyzfmi0=
|
||||
go.etcd.io/etcd/api/v3 v3.5.0/go.mod h1:cbVKeC6lCfl7j/8jBhAK6aIYO9XOjdptoxU/nLQcPvs=
|
||||
go.etcd.io/etcd/client/pkg/v3 v3.5.0/go.mod h1:IJHfcCEKxYu1Os13ZdwCwIUTUVGYTSAM3YSwc9/Ac1g=
|
||||
go.etcd.io/etcd/client/v2 v2.305.0/go.mod h1:h9puh54ZTgAKtEbut2oe9P4L/oqKCVB6xsXlzd7alYQ=
|
||||
@ -739,6 +828,7 @@ golang.org/x/crypto v0.0.0-20200221231518-2aa609cf4a9d/go.mod h1:LzIPMQfyMNhhGPh
|
||||
golang.org/x/crypto v0.0.0-20200302210943-78000ba7a073/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
|
||||
golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
|
||||
golang.org/x/crypto v0.0.0-20201012173705-84dcc777aaee/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
|
||||
golang.org/x/crypto v0.0.0-20210711020723-a769d52b0f97/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
|
||||
golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
|
||||
golang.org/x/crypto v0.0.0-20211215153901-e495a2d5b3d3/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4=
|
||||
golang.org/x/crypto v0.0.0-20220408190544-5352b0902921 h1:iU7T1X1J6yxDr0rda54sWGkHgOp5XJrqm79gcNlC2VM=
|
||||
@ -746,6 +836,7 @@ golang.org/x/crypto v0.0.0-20220408190544-5352b0902921/go.mod h1:IxCIyHEi3zRg3s0
|
||||
golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
|
||||
golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
|
||||
golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8=
|
||||
golang.org/x/exp v0.0.0-20190731235908-ec7cb31e5a56/go.mod h1:JhuoJpWY28nO4Vef9tZUw9qufEGTyX1+7lmHxV5q5G4=
|
||||
golang.org/x/exp v0.0.0-20190829153037-c13cbed26979/go.mod h1:86+5VVa7VpoJ4kLfm080zCjGlMRFzhUhsZKEZO7MGek=
|
||||
golang.org/x/exp v0.0.0-20191030013958-a1ab85dbe136/go.mod h1:JXzH8nQsPlswgeRAPE3MuO9GYsAcnJvJ4vnMwN/5qkY=
|
||||
golang.org/x/exp v0.0.0-20191129062945-2f5052295587/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4=
|
||||
@ -755,6 +846,8 @@ golang.org/x/exp v0.0.0-20200207192155-f17229e696bd/go.mod h1:J/WKrq2StrnmMY6+EH
|
||||
golang.org/x/exp v0.0.0-20200224162631-6cc2880d07d6/go.mod h1:3jZMyOhIsHpP37uCMkUooju7aAi5cS1Q23tOzKc+0MU=
|
||||
golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js=
|
||||
golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0=
|
||||
golang.org/x/image v0.0.0-20220601225756-64ec528b34cd h1:9NbNcTg//wfC5JskFW4Z3sqwVnjmJKHxLAol1bW2qgw=
|
||||
golang.org/x/image v0.0.0-20220601225756-64ec528b34cd/go.mod h1:doUCurBvlfPMKfmIpRIywoHmhN3VyhnoFDbvIEWF4hY=
|
||||
golang.org/x/lint v0.0.0-20180702182130-06c8688daad7/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
|
||||
golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
|
||||
golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU=
|
||||
@ -770,6 +863,8 @@ golang.org/x/lint v0.0.0-20201208152925-83fdc39ff7b5/go.mod h1:3xt1FjdF8hUf6vQPI
|
||||
golang.org/x/lint v0.0.0-20210508222113-6edffad5e616/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY=
|
||||
golang.org/x/mobile v0.0.0-20190312151609-d3739f865fa6/go.mod h1:z+o9i4GpDbdi3rU15maQ/Ox0txvL9dWGYEHz965HBQE=
|
||||
golang.org/x/mobile v0.0.0-20190719004257-d2bd2a29d028/go.mod h1:E/iHnbuqvinMTCcRqshq8CkpyQDoeVncDDYHnLhea+o=
|
||||
golang.org/x/mobile v0.0.0-20211207041440-4e6c2922fdee h1:/tShaw8UTf0XzI8DOZwQHzC7d6Vi3EtrBnftiZ4vAvU=
|
||||
golang.org/x/mobile v0.0.0-20211207041440-4e6c2922fdee/go.mod h1:pe2sM7Uk+2Su1y7u/6Z8KJ24D7lepUjFZbhFOrmDfuQ=
|
||||
golang.org/x/mod v0.0.0-20190513183733-4bf6d317e70e/go.mod h1:mXi4GBBbnImb6dmsKGUJ2LatrhH/nqhxcFungHvyanc=
|
||||
golang.org/x/mod v0.1.0/go.mod h1:0QHyrYULN0/3qlju5TqG8bIK38QM8yzMo5ekMj3DlcY=
|
||||
golang.org/x/mod v0.1.1-0.20191105210325-c90efee705ee/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg=
|
||||
@ -831,6 +926,8 @@ golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96b
|
||||
golang.org/x/net v0.0.0-20210410081132-afb366fc7cd1/go.mod h1:9tjilg8BloeKEkVJvy7fQ90B1CfIiPueXVOjqfkSzI8=
|
||||
golang.org/x/net v0.0.0-20210428140749-89ef3d95e781/go.mod h1:OJAsFXCWl8Ukc7SiCT/9KSuxbyM7479/AVlXFRxuMCk=
|
||||
golang.org/x/net v0.0.0-20210726213435-c6fcb2dbf985/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
|
||||
golang.org/x/net v0.0.0-20210805182204-aaa1db679c0d/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
|
||||
golang.org/x/net v0.0.0-20210916014120-12bc252f5db8/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
|
||||
golang.org/x/net v0.0.0-20211015210444-4f30a5c0130f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
|
||||
golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
|
||||
golang.org/x/net v0.0.0-20211216030914-fe4d6282115f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
|
||||
@ -886,6 +983,7 @@ golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7w
|
||||
golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190726091711-fc99dfbffb4e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190916202348-b4ddaad3f8a3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190922100055-0a153f010e69/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190924154521-2837fb4f24fe/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20191001151750-bb3f8db39f24/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
@ -915,6 +1013,7 @@ golang.org/x/sys v0.0.0-20200905004654-be1d3432aa8f/go.mod h1:h1NjWce9XRLGQEsW7w
|
||||
golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20201201145000-ef89a241ccb3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20201204225414-ed752295db88/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20210104204734-6f8348627aad/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20210112080510-489259a85091/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20210119212857-b64e53b001e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
@ -931,10 +1030,14 @@ golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBc
|
||||
golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20210806184541-e5e7981a1069/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20210809222454-d867a43fc93e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20210816074244-15123e1e1f71/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20211019181941-9d821ace8654/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20220111092808-5a964db01320/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20220408201424-a24fb2fb8a0f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20220412211240-33da011f77ad/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/sys v0.0.0-20220712014510-0a85c31ab51e h1:NHvCuwuS43lGnYhten69ZWqi2QOj/CiDNcKbVqwVoew=
|
||||
golang.org/x/sys v0.0.0-20220712014510-0a85c31ab51e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
|
||||
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
|
||||
@ -1019,6 +1122,7 @@ golang.org/x/tools v0.1.1/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
|
||||
golang.org/x/tools v0.1.2/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
|
||||
golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
|
||||
golang.org/x/tools v0.1.6-0.20210726203631-07bc1bf47fb2/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
|
||||
golang.org/x/tools v0.1.8-0.20211022200916-316ba0b74098/go.mod h1:LGqMHiF4EqQNHR1JncWGqT5BVaXmza+X+BDGol+dOxo=
|
||||
golang.org/x/tools v0.1.8/go.mod h1:nABZi5QlRsZVlzPpHl034qft6wpY4eDcsTt5AaioBiU=
|
||||
golang.org/x/tools v0.1.10 h1:QjFRCZxdOhBJ/UNgnBZLbNV13DlbnK0quyivTnXJM20=
|
||||
golang.org/x/tools v0.1.10/go.mod h1:Uh6Zz+xoGYZom868N8YTex3t7RhtHDBrE8Gzo9bV56E=
|
||||
@ -1147,12 +1251,14 @@ gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLks
|
||||
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk=
|
||||
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q=
|
||||
gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI=
|
||||
gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys=
|
||||
gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw=
|
||||
gopkg.in/ini.v1 v1.42.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k=
|
||||
gopkg.in/ini.v1 v1.62.0 h1:duBzk771uxoUuOlyRLkHsygud9+5lrlGjdFBb4mSKDU=
|
||||
gopkg.in/ini.v1 v1.62.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k=
|
||||
gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ=
|
||||
gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw=
|
||||
@ -1166,9 +1272,12 @@ gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
|
||||
gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY=
|
||||
gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ=
|
||||
gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
|
||||
gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b h1:h8qDotaEPuJATrMmW04NCwg7v22aHH28wwpauUhK9Oo=
|
||||
gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
|
||||
gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA=
|
||||
gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
|
||||
grpc.go4.org v0.0.0-20170609214715-11d0a25b4919/go.mod h1:77eQGdRu53HpSqPFJFmuJdjuHRquDANNeA4x7B8WQ9o=
|
||||
honnef.co/go/js/dom v0.0.0-20210725211120-f030747120f2 h1:oomkgU6VaQDsV6qZby2uz1Lap0eXmku8+2em3A/l700=
|
||||
honnef.co/go/js/dom v0.0.0-20210725211120-f030747120f2/go.mod h1:sUMDUKNB2ZcVjt92UnLy3cdGs+wDAcrPdV3JP6sVgA4=
|
||||
honnef.co/go/tools v0.0.0-20180728063816-88497007e858/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
|
||||
honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
|
||||
honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
|
||||
|
@ -55,7 +55,7 @@ func (this *MCompConfigure) GetConfigure(name string) (v interface{}, err error)
|
||||
|
||||
//全局配置
|
||||
func (this *MCompConfigure) GetGlobalConf(key string) string {
|
||||
if v, err := this.GetConfigure(game_initial); err != nil {
|
||||
if v, err := this.GetConfigure(game_global); err != nil {
|
||||
log.Errorf("get global conf err:%v", err)
|
||||
return ""
|
||||
} else {
|
||||
|
@ -29,11 +29,6 @@ func (this *apiComp) Apply(session comm.IUserSession, req *pb.FriendApplyReq) (c
|
||||
Resp *pb.FriendApplyResp
|
||||
)
|
||||
|
||||
defer func() {
|
||||
|
||||
// utils.TraceFunc(session.GetUserId(), string(this.module.GetType()), FriendSubTypeApply, req, Resp)
|
||||
}()
|
||||
|
||||
defer func() {
|
||||
if code == pb.ErrorCode_Success {
|
||||
Resp = &pb.FriendApplyResp{
|
||||
@ -41,8 +36,7 @@ func (this *apiComp) Apply(session comm.IUserSession, req *pb.FriendApplyReq) (c
|
||||
FriendId: req.FriendId,
|
||||
}
|
||||
}
|
||||
err := session.SendMsg(string(this.module.GetType()), FriendSubTypeApply, Resp)
|
||||
if err != nil {
|
||||
if err := session.SendMsg(string(this.module.GetType()), FriendSubTypeApply, Resp); err != nil {
|
||||
code = pb.ErrorCode_SystemError
|
||||
return
|
||||
}
|
||||
|
@ -37,9 +37,14 @@ func (this *apiComp) ApplyList(session comm.IUserSession, req *pb.FriendApplyLis
|
||||
}
|
||||
|
||||
for _, userId := range self.ApplyIds {
|
||||
user := this.module.ModuleUser.GetUser(userId)
|
||||
if user == nil {
|
||||
continue
|
||||
}
|
||||
//TODO 组装FriendBase明细数据
|
||||
list = append(list, &pb.FriendBase{
|
||||
UserId: userId,
|
||||
UserId: userId,
|
||||
NickName: user.Name,
|
||||
})
|
||||
}
|
||||
|
||||
|
@ -15,7 +15,7 @@ func (this *apiComp) BlacklistCheck(session comm.IUserSession, req *pb.FriendBla
|
||||
func (this *apiComp) Blacklist(session comm.IUserSession, req *pb.FriendBlackListReq) (code pb.ErrorCode, data proto.Message) {
|
||||
var (
|
||||
self *pb.DBFriend
|
||||
Resp *pb.FriendBlackListResp
|
||||
Resp *pb.FriendBlackListResp
|
||||
list []*pb.FriendBase
|
||||
)
|
||||
|
||||
@ -32,15 +32,20 @@ func (this *apiComp) Blacklist(session comm.IUserSession, req *pb.FriendBlackLis
|
||||
}()
|
||||
|
||||
self = this.module.modelFriend.GetFriend(session.GetUserId())
|
||||
if self == nil {
|
||||
if self == nil {
|
||||
code = pb.ErrorCode_FriendSelfNoData
|
||||
return
|
||||
}
|
||||
|
||||
for _, userId := range self.BlackIds {
|
||||
//TODO 完善FriendBase信息
|
||||
user := this.module.ModuleUser.GetUser(userId)
|
||||
if user == nil {
|
||||
continue
|
||||
}
|
||||
|
||||
list = append(list, &pb.FriendBase{
|
||||
UserId: userId,
|
||||
UserId: userId,
|
||||
NickName: user.Name,
|
||||
})
|
||||
}
|
||||
|
||||
|
@ -15,7 +15,7 @@ func (this *apiComp) ListCheck(session comm.IUserSession, req *pb.FriendListReq)
|
||||
func (this *apiComp) List(session comm.IUserSession, req *pb.FriendListReq) (code pb.ErrorCode, data proto.Message) {
|
||||
var (
|
||||
self *pb.DBFriend
|
||||
Resp *pb.FriendListResp
|
||||
Resp *pb.FriendListResp
|
||||
list []*pb.FriendBase
|
||||
)
|
||||
|
||||
@ -37,8 +37,13 @@ func (this *apiComp) List(session comm.IUserSession, req *pb.FriendListReq) (cod
|
||||
}
|
||||
|
||||
for _, userId := range self.FriendIds {
|
||||
user := this.module.ModuleUser.GetUser(userId)
|
||||
if user == nil {
|
||||
continue
|
||||
}
|
||||
list = append(list, &pb.FriendBase{
|
||||
UserId: userId,
|
||||
UserId: userId,
|
||||
NickName: user.Name,
|
||||
})
|
||||
}
|
||||
|
||||
|
@ -39,7 +39,7 @@ func (this *Friend) OnInstallComp() {
|
||||
|
||||
//获取最大好友数
|
||||
func (this *Friend) getFriendMax() int {
|
||||
if maxHy := this.configure.GetGlobalConf("max_hy"); maxHy != "" {
|
||||
if maxHy := this.configure.GetGlobalConf("friend_maxnum"); maxHy != "" {
|
||||
return cast.ToInt(maxHy)
|
||||
}
|
||||
return 0
|
||||
@ -47,7 +47,7 @@ func (this *Friend) getFriendMax() int {
|
||||
|
||||
//获取最大黑名单数
|
||||
func (this *Friend) getBlackMax() int {
|
||||
if maxHy := this.configure.GetGlobalConf("max_hmd"); maxHy != "" {
|
||||
if maxHy := this.configure.GetGlobalConf("friend_black"); maxHy != "" {
|
||||
return cast.ToInt(maxHy)
|
||||
}
|
||||
return 0
|
||||
|
@ -81,9 +81,8 @@ func (this *apiComp) DrawCard(session comm.IUserSession, req *pb.HeroDrawCardReq
|
||||
if config5Count <= 0 { // 小于等于零 表示没有保底
|
||||
config5Count = math.MaxInt32
|
||||
}
|
||||
sz := make([]*cfg.Game_atn, 0)
|
||||
sz = append(sz, _costConf.Cost)
|
||||
code = this.module.CheckRes(session, sz) // 消耗校验
|
||||
|
||||
code = this.module.CheckRes(session, []*cfg.Game_atn{_costConf.Cost}) // 消耗校验
|
||||
if code != pb.ErrorCode_Success {
|
||||
return
|
||||
}
|
||||
@ -134,9 +133,9 @@ func (this *apiComp) DrawCard(session comm.IUserSession, req *pb.HeroDrawCardReq
|
||||
update := map[string]interface{}{}
|
||||
|
||||
update["race"+strconv.Itoa(int(race)-1)] = raceData
|
||||
this.module.modelRecord.ChangeUserRecord(session.GetUserId(), update)
|
||||
this.module.modelRecord.ChangeHeroRecord(session.GetUserId(), update)
|
||||
// 消耗道具
|
||||
code = this.module.ConsumeRes(session, sz, true)
|
||||
code = this.module.ConsumeRes(session, []*cfg.Game_atn{_costConf.Cost}, true)
|
||||
if code != pb.ErrorCode_Success {
|
||||
return
|
||||
}
|
||||
|
@ -92,7 +92,7 @@ func (this *ModelHero) initHeroSkill(hero *pb.DBHero) []*pb.SkillData {
|
||||
func (this *ModelHero) createOneHero(uid string, heroCfgId string) (hero *pb.DBHero, err error) {
|
||||
hero = this.initHero(uid, heroCfgId)
|
||||
if hero != nil {
|
||||
if err = this.moduleHero.modelHero.AddList(uid, hero.Id, hero); err != nil {
|
||||
if err = this.AddList(uid, hero.Id, hero); err != nil {
|
||||
this.moduleHero.Errorf("%v", err)
|
||||
return
|
||||
}
|
||||
@ -131,7 +131,7 @@ func (this *ModelHero) initHeroOverlying(uid string, heroCfgId string, count int
|
||||
}(uid, heroCfgId)
|
||||
|
||||
hero.SameCount = count
|
||||
if err = this.moduleHero.modelHero.AddList(uid, hero.Id, hero); err != nil {
|
||||
if err = this.AddList(uid, hero.Id, hero); err != nil {
|
||||
this.moduleHero.Errorf("%v", err)
|
||||
return
|
||||
}
|
||||
@ -141,7 +141,7 @@ func (this *ModelHero) initHeroOverlying(uid string, heroCfgId string, count int
|
||||
|
||||
// 该方法适用创建初始英雄 叠加英雄 count叠加数量
|
||||
func (this *ModelHero) createHeroOverlying(uid string, heroCfgId string, count int32) (hero *pb.DBHero, err error) {
|
||||
heroes := this.moduleHero.modelHero.getHeroList(uid)
|
||||
heroes := this.getHeroList(uid)
|
||||
if len(heroes) == 0 {
|
||||
return this.initHeroOverlying(uid, heroCfgId, count)
|
||||
} else {
|
||||
@ -169,7 +169,7 @@ func (this *ModelHero) createHeroOverlying(uid string, heroCfgId string, count i
|
||||
|
||||
//创建多个指定的英雄 heroCfgIds可填入多个英雄ID
|
||||
func (this *ModelHero) createMultiHero(uid string, heroCfgIds ...string) error {
|
||||
heroes := this.moduleHero.modelHero.getHeroList(uid)
|
||||
heroes := this.getHeroList(uid)
|
||||
|
||||
if len(heroes) == 0 {
|
||||
for _, v := range heroCfgIds {
|
||||
@ -463,7 +463,7 @@ func (this *ModelHero) ChangeHeroProperty(session comm.IUserSession, hero *pb.DB
|
||||
func (this *ModelHero) cleanData(uid string) {
|
||||
userList := this.moduleHero.GetHeroList(uid)
|
||||
for _, v := range userList {
|
||||
if err := this.moduleHero.modelHero.DelListlds(uid, v.Id); err != nil {
|
||||
if err := this.DelListlds(uid, v.Id); err != nil {
|
||||
this.moduleHero.Errorf("cleanData err:%v", err)
|
||||
}
|
||||
}
|
||||
@ -534,14 +534,14 @@ func (this *ModelHero) AddCardExp(uid string, hero *pb.DBHero, exp int32) (newhe
|
||||
|
||||
// 玩家离线 清除缓存
|
||||
func (this *ModelHero) RemoveUserHeroInfo(session comm.IUserSession) (err error) {
|
||||
this.moduleHero.modelHero.BatchDelLists(session.GetUserId())
|
||||
this.BatchDelLists(session.GetUserId())
|
||||
return
|
||||
}
|
||||
|
||||
// 获取抽卡保底相关数据
|
||||
func (this *ModelHero) GetCurStarCount(uid string, drawType int32) (curStar4Count int32, curStar5Count int32) {
|
||||
var race int32
|
||||
rst, _ := this.moduleHero.modelRecord.GetUserRecord(uid)
|
||||
rst, _ := this.moduleHero.modelRecord.GetHeroRecord(uid)
|
||||
if drawType%2 == 0 { // 转成对应阵营信息 1~5
|
||||
race = int32((int(drawType)) / 2)
|
||||
} else {
|
||||
|
@ -31,8 +31,8 @@ func (this *ModelRecord) getUserSession(uid string) (cuser *pb.CacheUser) {
|
||||
}
|
||||
|
||||
//获取用户通过扩展表
|
||||
func (this *ModelRecord) GetUserRecord(uid string) (result *pb.DBUserRecord, err error) {
|
||||
result = &pb.DBUserRecord{}
|
||||
func (this *ModelRecord) GetHeroRecord(uid string) (result *pb.DBHeroRecord, err error) {
|
||||
result = &pb.DBHeroRecord{}
|
||||
if err = this.Get(uid, result); err != nil {
|
||||
return
|
||||
}
|
||||
@ -40,7 +40,7 @@ func (this *ModelRecord) GetUserRecord(uid string) (result *pb.DBUserRecord, err
|
||||
}
|
||||
|
||||
//修改用户扩展数据
|
||||
func (this *ModelRecord) ChangeUserRecord(uid string, value map[string]interface{}) (err error) {
|
||||
func (this *ModelRecord) ChangeHeroRecord(uid string, value map[string]interface{}) (err error) {
|
||||
if len(value) == 0 {
|
||||
return nil
|
||||
}
|
||||
|
@ -256,6 +256,7 @@ func (this *ModelItemsComp) addItemToUserPack(uid string, items []*pb.DB_UserIte
|
||||
return
|
||||
}
|
||||
if conf, err = this.module.configure.GetItemConfigure(itemId); err != nil {
|
||||
this.module.Errorln(err)
|
||||
return
|
||||
}
|
||||
if conf.UpperLimit == 0 {
|
||||
|
@ -5,7 +5,6 @@ import (
|
||||
"go_dreamfactory/lego/core"
|
||||
"go_dreamfactory/modules"
|
||||
"go_dreamfactory/pb"
|
||||
"sort"
|
||||
)
|
||||
|
||||
type Mainline struct {
|
||||
@ -46,25 +45,24 @@ func (this *Mainline) ModifyMainlineData(uid string, objId string, data map[stri
|
||||
}
|
||||
|
||||
// 校验是否能挑战该关卡
|
||||
func (this *Mainline) CheckChallengeChapter(stroyId int32, uid string, zhangjieID int32, Intensity string) (code pb.ErrorCode) {
|
||||
var (
|
||||
curChapter *pb.DBMainline
|
||||
)
|
||||
_szData, err := this.modelMainline.getMainlineList(uid)
|
||||
if err != nil {
|
||||
code = pb.ErrorCode_DBError
|
||||
return
|
||||
}
|
||||
sort.SliceStable(_szData, func(i, j int) bool { // 排序
|
||||
return _szData[i].ChapterId > _szData[j].ChapterId
|
||||
})
|
||||
func (this *Mainline) CheckChallengeChapter(storyObjId string, uid string, zhangjieID int32, Intensity string) (code pb.ErrorCode) {
|
||||
|
||||
// 取出最后一条数据
|
||||
curChapter = _szData[len(_szData)-1]
|
||||
// _szData, err := this.modelMainline.getMainlineList(uid)
|
||||
// if err != nil {
|
||||
// code = pb.ErrorCode_DBError
|
||||
// return
|
||||
// }
|
||||
// sort.SliceStable(_szData, func(i, j int) bool { // 排序
|
||||
// return _szData[i].ChapterId > _szData[j].ChapterId
|
||||
// })
|
||||
|
||||
// 获取当前关卡数据
|
||||
curChapter := this.modelMainline.getOneChapterInfo(uid, storyObjId)
|
||||
if curChapter == nil {
|
||||
code = pb.ErrorCode_MainlineNotFindChapter // 没有找到主线关卡信息
|
||||
return
|
||||
}
|
||||
stroyId := curChapter.ChapterId
|
||||
// 获取关卡难度用来取配置文件
|
||||
if Intensity == comm.MailLineEasy {
|
||||
configData := this.configure.GetMainlineEasyChapter(curChapter.MainlineId)
|
||||
|
33
modules/pagoda/api.go
Normal file
33
modules/pagoda/api.go
Normal file
@ -0,0 +1,33 @@
|
||||
package pagoda
|
||||
|
||||
import (
|
||||
"go_dreamfactory/lego/core"
|
||||
"go_dreamfactory/modules"
|
||||
)
|
||||
|
||||
const (
|
||||
MainlineGetListResp = "getlist"
|
||||
MainlineChallengeResp = "challenge"
|
||||
MainlineGetRewardResp = "getreward"
|
||||
MainlineNewChapterPush = "newchapter"
|
||||
)
|
||||
|
||||
type apiComp struct {
|
||||
modules.MCompGate
|
||||
service core.IService
|
||||
module *Pagoda
|
||||
}
|
||||
|
||||
//组件初始化接口
|
||||
func (this *apiComp) Init(service core.IService, module core.IModule, comp core.IModuleComp, options core.IModuleOptions) (err error) {
|
||||
err = this.MCompGate.Init(service, module, comp, options)
|
||||
this.module = module.(*Pagoda)
|
||||
this.service = service
|
||||
return
|
||||
}
|
||||
|
||||
func (this *apiComp) Start() (err error) {
|
||||
err = this.MCompGate.Start()
|
||||
|
||||
return
|
||||
}
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user