|
@@ -26,8 +26,8 @@ var Version = "1.0.0"
|
|
|
var NatsPort int
|
|
|
|
|
|
type Config struct {
|
|
|
- Version string
|
|
|
- ExePath string
|
|
|
+ Version string `json:"version"`
|
|
|
+ ExePath string `json:"exePath"`
|
|
|
}
|
|
|
|
|
|
func RegApi(event *cef.BrowserEvent, window cef.IBrowserWindow, bw *cef.LCLBrowserWindow) {
|
|
@@ -383,7 +383,7 @@ func RegApi(event *cef.BrowserEvent, window cef.IBrowserWindow, bw *cef.LCLBrows
|
|
|
})
|
|
|
if err != nil {
|
|
|
// socket.BroadMsgObj(&entity.NormMsg{Sub: eventName, Type: "error", Error: err.Error()})
|
|
|
- unzipErrorJsFunc := fmt.Sprintf("UnzipErrorJsFunc('%s','%s')", sid, "error")
|
|
|
+ unzipErrorJsFunc := fmt.Sprintf("UnzipErrorJsFunc('%s','%s')", sid, err.Error())
|
|
|
fmt.Println("UnzipErrorJsFunc:", unzipErrorJsFunc)
|
|
|
window.Chromium().ExecuteJavaScript(unzipErrorJsFunc, "", 0)
|
|
|
return
|