[fix] fixing pubish default topic issue

improve browser cache
imporve call payload bytes type base64
main
Johnson C 2 years ago
parent e44401e2e3
commit d9a10d225f

@ -1,2 +1 @@
docs
frontend
**

@ -197,7 +197,11 @@ export class ClientCallComponent implements OnInit {
break;
default:
if (v.type.startsWith('[]')) {
value = [];
if (v.type.endsWith('byte') || v.type.endsWith('int8')) {
value = 'base64';
} else {
value = [];
}
} else {
console.log(v.type);
value = v.type;

@ -27,7 +27,7 @@
</nz-select>
</nz-form-control>
</nz-form-item>
<nz-form-item *ngIf="selectedService">
<nz-form-item *ngIf="selectedService&&selectedService.versions">
<nz-form-control>
<nz-select nzShowSearch name="version" nzPlaceHolder="Select version" [(ngModel)]="version"
(ngModelChange)="versionChanged($event)">

@ -52,9 +52,9 @@ export class ServiceDetailComponent implements OnInit {
this.router.navigate(['/client/call'], navigationExtras);
}
gotoPublish(service: string, version: string, endpoint: string) {
gotoPublish(service: string, version: string, topic: string) {
let navigationExtras: NavigationExtras = {
queryParams: { 'service': service, 'version': version, 'endpoint': endpoint }
queryParams: { 'service': service, 'version': version, 'topic': topic }
};
this.router.navigate(['/client/publish'], navigationExtras);
}

@ -1,5 +1,5 @@
// Code generated by fileb0x at "2021-12-02 10:03:04.6115997 +0800 CST m=+0.057062001" from config file "b0x.yaml" DO NOT EDIT.
// modification hash(c71255f8c39564687acdced2f2c06267.8be3f833d63e3c844663716446e13a42)
// Code generated by fileb0x at "2021-12-06 16:07:20.7620288 +0800 CST m=+0.057977901" from config file "b0x.yaml" DO NOT EDIT.
// modification hash(c5c686d71f073ae93607fbb8175a0459.8be3f833d63e3c844663716446e13a42)
package web

@ -1,5 +1,5 @@
// Code generaTed by fileb0x at "2021-12-02 10:03:04.6170147 +0800 CST m=+0.062477001" from config file "b0x.yaml" DO NOT EDIT.
// modified(2021-12-02 09:58:47.9180366 +0800 CST)
// Code generaTed by fileb0x at "2021-12-06 16:07:20.9364284 +0800 CST m=+0.232377501" from config file "b0x.yaml" DO NOT EDIT.
// modified(2021-12-06 16:07:15.9565685 +0800 CST)
// original path: frontend\dist\449.ea3505f8c3a78bc5ec51.js
package web

File diff suppressed because one or more lines are too long

@ -1,5 +1,5 @@
// Code generaTed by fileb0x at "2021-12-02 10:03:04.7626995 +0800 CST m=+0.208161801" from config file "b0x.yaml" DO NOT EDIT.
// modified(2021-12-02 09:58:47.9180366 +0800 CST)
// Code generaTed by fileb0x at "2021-12-06 16:07:20.8928978 +0800 CST m=+0.188846901" from config file "b0x.yaml" DO NOT EDIT.
// modified(2021-12-06 16:07:15.9555753 +0800 CST)
// original path: frontend\dist\polyfills.d3127c390f57a23419e1.js
package web

@ -1,5 +1,5 @@
// Code generaTed by fileb0x at "2021-12-02 10:03:04.7764137 +0800 CST m=+0.221876001" from config file "b0x.yaml" DO NOT EDIT.
// modified(2021-12-02 09:58:47.9180366 +0800 CST)
// Code generaTed by fileb0x at "2021-12-06 16:07:20.8966333 +0800 CST m=+0.192582401" from config file "b0x.yaml" DO NOT EDIT.
// modified(2021-12-06 16:07:15.9555753 +0800 CST)
// original path: frontend\dist\runtime.0edec77bcc0e6f764d02.js
package web

@ -1,5 +1,5 @@
// Code generaTed by fileb0x at "2021-12-02 10:03:04.7788 +0800 CST m=+0.224262301" from config file "b0x.yaml" DO NOT EDIT.
// modified(2021-12-02 09:58:47.9190359 +0800 CST)
// Code generaTed by fileb0x at "2021-12-06 16:07:20.8977526 +0800 CST m=+0.193701701" from config file "b0x.yaml" DO NOT EDIT.
// modified(2021-12-06 16:07:15.9565685 +0800 CST)
// original path: frontend\dist\styles.40a72a43f1959e5b9ccc.css
package web

@ -1,6 +1,8 @@
package web
import (
"os"
"os/exec"
"path/filepath"
"github.com/gin-gonic/gin"
@ -25,10 +27,15 @@ func RegisterRoute(router *gin.Engine) error {
case ".css":
c.Header("Content-Type", "text/css; charset=utf-8")
case ".js":
c.Header("Content-Type", "application/javascript")
c.Header("Content-Type", "text/javascript")
case ".svg":
c.Header("Content-Type", "image/svg+xml")
}
if path, err := exec.LookPath(os.Args[0]); err == nil {
if file, err := os.Stat(path); err == nil {
c.Header("Last-Modified", file.ModTime().UTC().Format("Mon, 02 Jan 2006 15:04:05 GMT"))
}
}
if _, err := c.Writer.Write(data); err != nil {
c.AbortWithError(500, err)
return

Loading…
Cancel
Save