This commit is contained in:
wh_zcy 2023-06-14 11:50:42 +08:00
parent c350ccba90
commit 9577fa1346
6 changed files with 36 additions and 51 deletions

1
.gitignore vendored Normal file
View File

@ -0,0 +1 @@
*.log

View File

@ -132,12 +132,12 @@ var (
// common.MF(comm.ModuleGourmet, "getranduser"),
},
"sociaty": {
// common.MF(comm.ModuleSociaty, sociaty.SociatySubTypeList),
// common.MF(comm.ModuleSociaty, sociaty.SociatySubTypeCreate),
common.MF("sociaty", "list"),
common.MF("sociaty", "create"),
common.MF("sociaty", "mine"),
common.MF("sociaty", "tasklist"),
// common.MF(comm.ModuleSociaty, sociaty.SociatySubTypeRank),
// common.MF(comm.ModuleSociaty, "boss"),
// common.MF("sociaty", sociaty.SociatySubTypeRank),
// common.MF("sociaty", "boss"),
},
"troll": {
// common.MF(comm.ModuleTroll, "getlist"),
@ -713,16 +713,13 @@ var (
SubType: "create",
Enabled: true,
},
// common.MF(comm.ModuleSociaty, sociaty.SociatySubTypeList): {
// NavLabel: "公会推荐",
// Desc: "公会列表",
// MainType: string(comm.ModuleSociaty),
// SubType: sociaty.SociatySubTypeList,
// Enabled: true,
// Print: func(rsp proto.Message) string {
// return "不打印"
// },
// },
common.MF("sociaty", "list"): {
NavLabel: "公会推荐",
Desc: "公会列表",
MainType: "sociaty",
SubType: "list",
Enabled: true,
},
common.MF("sociaty", "mine"): {
NavLabel: "我的公会",
Desc: "我的公会",
@ -737,17 +734,17 @@ var (
SubType: "tasklist",
Enabled: true,
},
// common.MF(comm.ModuleSociaty, sociaty.SociatySubTypeRank): {
// common.MF("sociaty", sociaty.SociatySubTypeRank): {
// NavLabel: "排行榜",
// Desc: "排行榜",
// MainType: string(comm.ModuleSociaty),
// MainType: string("sociaty"),
// SubType: sociaty.SociatySubTypeRank,
// Enabled: true,
// },
// common.MF(comm.ModuleSociaty, "boss"): {
// common.MF("sociaty", "boss"): {
// NavLabel: "BOSS",
// Desc: "BOSS",
// MainType: string(comm.ModuleSociaty),
// MainType: string("sociaty"),
// SubType: "boss",
// Enabled: true,
// },

View File

@ -1,14 +1 @@
{"level":"debug","msg":"app starting","time":"2023-06-09 21:54:05","version":"0.0.1"}
{"level":"debug","msg":"choose server","server":"01区","sid":"dfz01","time":"2023-06-09 21:54:08"}
{"account":"6911","level":"debug","msg":"submit login","time":"2023-06-09 21:54:12"}
{"level":"info","mainType":"user","msg":"登录","params":{"account":"6911","sid":"dfz01","area":0,"channel":0,"vcode":0,"vname":""},"subType":"login","time":"2023-06-09 21:54:12"}
{"idx":2,"lbl":"昵称","level":"debug","msg":"更新Prop","time":"2023-06-09 21:54:12","val":"Piratemountain"}
{"id":"worldtask","level":"warning","msg":"Missing tutorial panel","time":"2023-06-09 21:54:14"}
{"id":"worldtask","level":"warning","msg":"Missing tutorial panel","time":"2023-06-09 21:54:14"}
{"id":"worldtask","level":"warning","msg":"Missing tutorial panel","time":"2023-06-09 21:54:14"}
{"id":"worldtask","level":"warning","msg":"Missing tutorial panel","time":"2023-06-09 21:54:14"}
{"id":"worldtask","level":"warning","msg":"Missing tutorial panel","time":"2023-06-09 21:54:14"}
{"id":"worldtask","level":"warning","msg":"Missing tutorial panel","time":"2023-06-09 21:54:15"}
{"level":"debug","mainType":"smithy","msg":"select","subType":"tasklist","time":"2023-06-09 21:54:15"}
{"level":"error","msg":"readMessage err:read tcp 10.0.0.238:14482-\u003e10.0.0.238:7891: wsarecv: An existing connection was forcibly closed by the remote host.","time":"2023-06-09 21:54:31"}
{"level":"debug","msg":"即将与服务器断开链接","time":"2023-06-09 21:54:32"}
{"level":"debug","msg":"app starting","time":"2023-06-14 11:17:53","version":"0.0.1"}

View File

@ -100,8 +100,8 @@ var (
// gourmet
// common.MF(comm.ModuleGourmet, "getranduser"): &formview.GourmentGetRandView{},
// sociaty
// common.MF(comm.ModuleSociaty, sociaty.SociatySubTypeList): &formview.SociatyListView{},
// common.MF(comm.ModuleSociaty, sociaty.SociatySubTypeCreate): &formview.SociatyCreateView{},
common.MF("sociaty", "list"): &formview.SociatyListView{},
common.MF("sociaty", "create"): &formview.SociatyCreateView{},
common.MF("sociaty", "mine"): &formview.SociatyMineView{},
common.MF("sociaty", "tasklist"): &formview.SociatyTasklistView{},
// common.MF(comm.ModuleSociaty, sociaty.SociatySubTypeRank): &formview.SociatyRankView{},

View File

@ -41,8 +41,8 @@ func (app *SociatyCreateView) CreateView(t *model.TestCase) fyne.CanvasObject {
ApplyLv: cast.ToInt32(applyLv.Text),
}
if err := service.GetPttService().SendToClient(
string("sociaty"),
"",
"sociaty",
"create",
req,
); err != nil {
logrus.Error(err)

View File

@ -45,8 +45,8 @@ func (this *SociatyListView) CreateView(t *model.TestCase) fyne.CanvasObject {
this.sociatyList = func() {
this.itemList.Reset()
if err := service.GetPttService().SendToClient(
string("sociaty"),
"",
"sociaty",
"list",
&pb.SociatyListReq{}); err != nil {
logrus.Error(err)
}
@ -68,7 +68,7 @@ func (this *SociatyListView) CreateView(t *model.TestCase) fyne.CanvasObject {
logrus.Debugf("%s", selId)
if err := service.GetPttService().SendToClient(
t.MainType,
"",
"apply",
&pb.SociatyApplyReq{
SociatyId: selId,
},
@ -85,8 +85,8 @@ func (this *SociatyListView) CreateView(t *model.TestCase) fyne.CanvasObject {
return
}
if err := service.GetPttService().SendToClient(
string("sociaty"),
"",
"sociaty",
"applycancel",
&pb.SociatyApplyCancelReq{
SociatyId: selId,
}); err != nil {
@ -108,8 +108,8 @@ func (this *SociatyListView) CreateView(t *model.TestCase) fyne.CanvasObject {
filter = pb.SociatyListFilter_APPLYING
}
if err := service.GetPttService().SendToClient(
string("sociaty"),
"",
"sociaty",
"list",
&pb.SociatyListReq{
Filter: filter,
}); err != nil {
@ -128,8 +128,8 @@ func (this *SociatyListView) CreateView(t *model.TestCase) fyne.CanvasObject {
}
this.itemList.Reset()
if err := service.GetPttService().SendToClient(
string("sociaty"),
"",
"sociaty",
"search",
&pb.SociatySearchReq{
Name: searchEntry.Text,
}); err != nil {
@ -153,8 +153,8 @@ func (this *SociatyListView) dataListener() {
this.obs.AddListener(observer.EVENT_REQ_RSP, observer.Listener{
OnNotify: func(d interface{}, args ...interface{}) {
data := d.(*pb.UserMessage)
if data.MainType == string("sociaty") &&
data.SubType == "" {
if data.MainType == "sociaty" &&
data.SubType == "list" {
rsp := &pb.SociatyListResp{}
if !comm.ProtoUnmarshal(data, rsp) {
@ -181,8 +181,8 @@ func (this *SociatyListView) dataListener() {
}
this.itemList.AddItem(item)
}
} else if data.MainType == string("sociaty") &&
data.SubType == "" {
} else if data.MainType == "sociaty" &&
data.SubType == "search" {
rsp := &pb.SociatySearchResp{}
if !comm.ProtoUnmarshal(data, rsp) {
@ -222,8 +222,8 @@ func (this *SociatyListView) formdataListen(item *entryItem) {
this.obs.AddListener(observer.EVENT_REQ_RSP, observer.Listener{
OnNotify: func(d interface{}, args ...interface{}) {
data := d.(*pb.UserMessage)
if !(data.MainType == string("sociaty") &&
data.SubType == "") {
if !(data.MainType == "sociaty" &&
data.SubType == "mine") {
return
}
rsp := &pb.SociatyMineResp{}