mirror of
https://github.com/antos-rde/antosdk-apps.git
synced 2024-11-17 10:48:23 +01:00
regen all archive using antos build system
This commit is contained in:
parent
7cbd4ce979
commit
0227f02ad6
@ -17,8 +17,10 @@
|
||||
"data": ["build","build/debug","build/release"]
|
||||
},
|
||||
{
|
||||
"name": "ts-import",
|
||||
"data": ["sdk://core/ts/core.d.ts", "sdk://core/ts/jquery.d.ts","sdk://core/ts/antos.d.ts"]
|
||||
"name": "ts-antos-sdk",
|
||||
"data": {
|
||||
"version": "2.0.x"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "ts-compile",
|
||||
|
Binary file not shown.
Binary file not shown.
@ -5,4 +5,7 @@ It's built on top of google-diff-match-patch library. That lib handles the hard
|
||||
|
||||
Github page: [https://github.com/ace-diff/ace-diff](https://github.com/ace-diff/ace-diff).
|
||||
|
||||
The ACE diff depends on the ACECore package.
|
||||
The ACE diff depends on the ACECore package.
|
||||
|
||||
## Change logs
|
||||
- v0.1.1-a: add dependencies
|
Binary file not shown.
Binary file not shown.
@ -27,8 +27,10 @@
|
||||
"require":["ts"],
|
||||
"jobs": [
|
||||
{
|
||||
"name": "ts-import",
|
||||
"data": ["sdk://core/ts/core.d.ts", "sdk://core/ts/jquery.d.ts","sdk://core/ts/antos.d.ts"]
|
||||
"name": "ts-antos-sdk",
|
||||
"data": {
|
||||
"version": "2.0.x"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "ts-compile",
|
||||
|
File diff suppressed because one or more lines are too long
Binary file not shown.
@ -59,8 +59,7 @@ namespace OS {
|
||||
});
|
||||
}
|
||||
|
||||
protected _wr(t: string, d: any): Promise<any> {
|
||||
this.cache = d;
|
||||
protected _wr(t: string): Promise<any> {
|
||||
return new Promise((resolve, reject) =>
|
||||
{
|
||||
resolve({
|
||||
|
@ -817,7 +817,7 @@ namespace OS {
|
||||
dataid: "recent",
|
||||
nodes: recent,
|
||||
onchildselect: (
|
||||
e: GUI.TagEventType<GUI.tag.MenuEventData>,
|
||||
e: GUI.TagEventType<GUI.tag.StackMenuEventData>,
|
||||
r: Antedit
|
||||
) => {
|
||||
const handle = e.data.item.data.text.asFileHandle();
|
||||
@ -849,7 +849,7 @@ namespace OS {
|
||||
},
|
||||
],
|
||||
onchildselect: (
|
||||
e: GUI.TagEventType<GUI.tag.MenuEventData>,
|
||||
e: GUI.TagEventType<GUI.tag.StackMenuEventData>,
|
||||
r: Antedit
|
||||
) => {
|
||||
return this.menuAction(e.data.item.data.dataid, r);
|
||||
@ -866,9 +866,9 @@ namespace OS {
|
||||
* @memberof Antedit
|
||||
*/
|
||||
private ctxFileMenuHandle(
|
||||
e: GUI.TagEventType<GUI.tag.MenuEventData>
|
||||
e: GUI.TagEventType<GUI.tag.StackMenuEventData>
|
||||
): void {
|
||||
const el = e.data.item as GUI.tag.MenuEntryTag;
|
||||
const el = e.data.item;
|
||||
if (!el) {
|
||||
return;
|
||||
}
|
||||
@ -1150,7 +1150,7 @@ namespace OS {
|
||||
}
|
||||
],
|
||||
onchildselect: (
|
||||
e: GUI.TagEventType<GUI.tag.MenuEventData>,
|
||||
e: GUI.TagEventType<GUI.tag.StackMenuEventData>,
|
||||
r: EditorFileHandle
|
||||
) => {
|
||||
switch (e.data.item.data.dataid) {
|
||||
|
Binary file not shown.
@ -17,8 +17,10 @@
|
||||
"data": ["build","build/debug","build/release"]
|
||||
},
|
||||
{
|
||||
"name": "ts-import",
|
||||
"data": ["sdk://core/ts/core.d.ts", "sdk://core/ts/jquery.d.ts","sdk://core/ts/antos.d.ts"]
|
||||
"name": "ts-antos-sdk",
|
||||
"data": {
|
||||
"version": "2.0.x"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "ts-compile",
|
||||
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -17,8 +17,10 @@
|
||||
"data": ["build","build/debug","build/release"]
|
||||
},
|
||||
{
|
||||
"name": "ts-import",
|
||||
"data": ["sdk://core/ts/core.d.ts", "sdk://core/ts/jquery.d.ts","sdk://core/ts/antos.d.ts"]
|
||||
"name": "ts-antos-sdk",
|
||||
"data": {
|
||||
"version": "2.0.x"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "ts-compile",
|
||||
|
Binary file not shown.
@ -244,7 +244,7 @@ namespace OS {
|
||||
{
|
||||
text: __("Change theme"),
|
||||
onmenuselect: async (
|
||||
e: GUI.TagEventType<GUI.tag.MenuEventData>
|
||||
e: GUI.TagEventType<GUI.tag.StackMenuEventData>
|
||||
) => {
|
||||
try{
|
||||
const themes = this.eum.active.getThemes();
|
||||
@ -263,7 +263,7 @@ namespace OS {
|
||||
{
|
||||
text: __("Change language mode"),
|
||||
onmenuselect: async (
|
||||
e: GUI.TagEventType<GUI.tag.MenuEventData>
|
||||
e: GUI.TagEventType<GUI.tag.StackMenuEventData>
|
||||
) => {
|
||||
try{
|
||||
const modes = this.eum.active.getModes().map(v => {
|
||||
@ -284,7 +284,7 @@ namespace OS {
|
||||
text: __("Build with AntOSDK"),
|
||||
shortcut: " (CTRL-ALT-B)",
|
||||
onmenuselect: async (
|
||||
e: GUI.TagEventType<GUI.tag.MenuEventData>
|
||||
e: GUI.TagEventType<GUI.tag.StackMenuEventData>
|
||||
) => {
|
||||
try{
|
||||
this.build();
|
||||
@ -542,7 +542,7 @@ namespace OS {
|
||||
dataid: "recent",
|
||||
nodes: recent,
|
||||
onchildselect: (
|
||||
e: GUI.TagEventType<GUI.tag.MenuEventData>,
|
||||
e: GUI.TagEventType<GUI.tag.StackMenuEventData>,
|
||||
r: CodePad
|
||||
) => {
|
||||
const handle = e.data.item.data.text.asFileHandle();
|
||||
@ -574,7 +574,7 @@ namespace OS {
|
||||
},
|
||||
],
|
||||
onchildselect: (
|
||||
e: GUI.TagEventType<GUI.tag.MenuEventData>,
|
||||
e: GUI.TagEventType<GUI.tag.StackMenuEventData>,
|
||||
r: CodePad
|
||||
) => {
|
||||
return this.menuAction(e.data.item.data.dataid, r);
|
||||
@ -591,9 +591,9 @@ namespace OS {
|
||||
* @memberof CodePad
|
||||
*/
|
||||
private ctxFileMenuHandle(
|
||||
e: GUI.TagEventType<GUI.tag.MenuEventData>
|
||||
e: GUI.TagEventType<GUI.tag.StackMenuEventData>
|
||||
): void {
|
||||
const el = e.data.item as GUI.tag.MenuEntryTag;
|
||||
const el = e.data.item;
|
||||
if (!el) {
|
||||
return;
|
||||
}
|
||||
@ -845,7 +845,7 @@ namespace OS {
|
||||
}
|
||||
],
|
||||
onchildselect: (
|
||||
e: GUI.TagEventType<GUI.tag.MenuEventData>,
|
||||
e: GUI.TagEventType<GUI.tag.StackMenuEventData>,
|
||||
r: EditorFileHandle
|
||||
) => {
|
||||
switch (e.data.item.data.dataid) {
|
||||
|
Binary file not shown.
@ -33,8 +33,10 @@
|
||||
],
|
||||
"jobs": [
|
||||
{
|
||||
"name": "ts-import",
|
||||
"data": ["sdk://core/ts/core.d.ts", "sdk://core/ts/jquery.d.ts","sdk://core/ts/antos.d.ts"]
|
||||
"name": "ts-antos-sdk",
|
||||
"data": {
|
||||
"version": "2.0.x"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "ts-compile",
|
||||
|
Binary file not shown.
Binary file not shown.
@ -17,8 +17,10 @@
|
||||
"data": ["build","build/debug","build/release"]
|
||||
},
|
||||
{
|
||||
"name": "ts-import",
|
||||
"data": ["sdk://core/ts/core.d.ts", "sdk://core/ts/jquery.d.ts","sdk://core/ts/antos.d.ts"]
|
||||
"name": "ts-antos-sdk",
|
||||
"data": {
|
||||
"version": "2.0.x"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "ts-compile",
|
||||
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -17,8 +17,10 @@
|
||||
"data": ["build","build/debug","build/release"]
|
||||
},
|
||||
{
|
||||
"name": "ts-import",
|
||||
"data": ["sdk://core/ts/core.d.ts", "sdk://core/ts/jquery.d.ts","sdk://core/ts/antos.d.ts"]
|
||||
"name": "ts-antos-sdk",
|
||||
"data": {
|
||||
"version": "2.0.x"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "ts-compile",
|
||||
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -17,8 +17,10 @@
|
||||
"data": ["build","build/debug","build/release"]
|
||||
},
|
||||
{
|
||||
"name": "ts-import",
|
||||
"data": ["sdk://core/ts/core.d.ts", "sdk://core/ts/jquery.d.ts","sdk://core/ts/antos.d.ts"]
|
||||
"name": "ts-antos-sdk",
|
||||
"data": {
|
||||
"version": "2.0.x"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "ts-compile",
|
||||
|
Binary file not shown.
@ -17,8 +17,10 @@
|
||||
"data": ["build","build/debug","build/release"]
|
||||
},
|
||||
{
|
||||
"name": "ts-import",
|
||||
"data": ["sdk://core/ts/core.d.ts", "sdk://core/ts/jquery.d.ts","sdk://core/ts/antos.d.ts"]
|
||||
"name": "ts-antos-sdk",
|
||||
"data": {
|
||||
"version": "2.0.x"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "ts-compile",
|
||||
|
@ -48,8 +48,4 @@ afx-app-window[data-id="ServerLogClient"] afx-hbox[data-id="top-header"] afx-lab
|
||||
text-align: right;
|
||||
padding-top: 5px;
|
||||
padding-right: 3px;
|
||||
}
|
||||
|
||||
afx-app-window[data-id="ServerLogClient"] afx-hbox[data-id="top-header"] afx-label.field-label i.label-text{
|
||||
font-weight: bold;
|
||||
}
|
@ -1 +1 @@
|
||||
var OS;!function(t){let e;!function(t){class e extends t.BaseApplication{constructor(t){super("ServerLogClient",t)}check(t){return!(!this.filter.record||!this.filter[t.severity_label]||this.filter.pattern&&!t.message.match(this.filter.pattern))}log(t){if(this.check(t)){if(this.logs.length>=this.filter.max_log){let t=this.logs.shift();$(t.el).remove()}t.el=$("<p />").addClass(t.severity_label),t.el.text(t.message),$(this.log_container).append(t.el),this.log_container.scrollTop=this.log_container.scrollHeight,this.logs.push(t)}}openSession(){this.sub=new Antunnel.Subscriber(this.setting.topic),this.sub.onopen=()=>{console.log("Subscribed")},this.sub.onerror=t=>{this.error(__("Unable to connect to: syslog"),t),this.sub=void 0},this.sub.onmessage=t=>{if(t.data){let e=JSON.parse(new TextDecoder("utf-8").decode(t.data));e.priority&&(e.priority=parseInt(e.priority)),e.severity&&(e.severity=parseInt(e.severity)),e.facility&&(e.facility=parseInt(e.facility)),this.log(e)}},this.sub.onclose=()=>{this.sub=void 0,this.notify(__("Connection closed")),this.quit(!0)},this.tunnel.subscribe(this.sub)}cleanup(){this.sub&&this.sub.close()}checklib(){Antunnel.tunnel?(this.tunnel=Antunnel.tunnel,this.openSession()):this._gui.pushService("Antunnel/AntunnelService").then(t=>{let e=this.systemsetting.system.tunnel_uri;e||(this.error(__("Unable to connect to the tunnel")),this.quit(!0)),Antunnel.init(e).then(t=>{this.notify(__("Tunnel now connected to the server at: {0}",e)),this.tunnel=Antunnel.tunnel,this.openSession()}).catch(t=>{Antunnel.tunnel&&(Antunnel.tunnel.close(),this.error(__("Unable to connect to the tunnel: {0}",t.toString()),t),this.quit(!0))})}).catch(t=>{this.error(__("Unable to run Antunnel service: {0}",t.toString()),t),this.quit(!0)})}main(){if(!Antunnel)return this.error(__("Antunnel library is not available")),void this.quit(!0);this.log_container=this.find("log-container"),this.logs=[],$(this.log_container).css("overflow-y","auto"),this.find("menu-level").items=[{text:__("Default level"),nodes:[{text:__("Debug"),switch:!0,checked:!0,severity:"debug"},{text:__("Notice"),switch:!0,checked:!0,severity:"notice"},{text:__("Info"),switch:!0,checked:!0,severity:"info"},{text:__("Warning"),switch:!0,checked:!0,severity:"warning"},{text:__("Error"),switch:!0,checked:!0,severity:"err"},{text:__("Critical"),switch:!0,checked:!0,severity:"crit"},{text:__("Alert"),switch:!0,checked:!0,severity:"alert"},{text:__("Emergency"),switch:!0,checked:!0,severity:"emerg"}],onchildselect:t=>{let e=t.data.item.data;this.filter[e.severity]=e.checked}}],this.filter={max_log:500,err:!0,emerg:!0,debug:!0,info:!0,notice:!0,warning:!0,crit:!0,alert:!0,pattern:void 0,record:!0};let t=this.find("txt-n-log");t.value=this.filter.max_log.toString(),$(t).on("keyup",e=>{if("Enter"===e.key){let e=parseInt(t.value);if(!isNaN(e))for(this.filter.max_log=e;this.logs.length>e;)this.logs.shift().el.remove();t.value=this.filter.max_log.toString()}}),this.find("btn-clear").onbtclick=()=>{this.logs=[],$(this.log_container).empty()};let e=this.find("txt-reg");$(e).on("keyup",t=>{if("Enter"===t.key){if(""===e.value.trim())return this.filter.pattern=void 0;try{this.filter.pattern=new RegExp(e.value,"g")}catch(t){this.error(__("Invalid regular expression: {0}",t.toString()),t),this.filter.pattern=void 0,e.value=""}}}),this.find("sw-record").onswchange=t=>{this.filter.record=t.data},this.setting.topic?this.checklib():this.openDialog("PromptDialog",{title:__("Enter topic name"),label:__("Please enter Antunnel topic name")}).then(t=>{this.setting.topic=t,this.checklib()})}}t.ServerLogClient=e,e.dependencies=["pkg://Antunnel/main.js"],e.singleton=!0}(e=t.application||(t.application={}))}(OS||(OS={}));
|
||||
var OS;!function(t){let e;!function(t){class e extends t.BaseApplication{constructor(t){super("ServerLogClient",t)}check(t){return!(!this.filter.record||!this.filter[t.severity_label]||this.filter.pattern&&!t.message.match(this.filter.pattern))}log(t){if(this.check(t)){if(this.logs.length>=this.filter.max_log){let t=this.logs.shift();$(t.el).remove()}t.el=$("<p />").addClass(t.severity_label),t.el.text(t.message),$(this.log_container).append(t.el),this.log_container.scrollTop=this.log_container.scrollHeight,this.logs.push(t)}}openSession(){this.sub=new Antunnel.Subscriber(this.setting.topic),this.sub.onopen=()=>{console.log("Subscribed")},this.sub.onerror=t=>{this.error(__("Unable to connect to: syslog"),t),this.sub=void 0},this.sub.onmessage=t=>{if(t.data){let e=JSON.parse(new TextDecoder("utf-8").decode(t.data));e.priority&&(e.priority=parseInt(e.priority)),e.severity&&(e.severity=parseInt(e.severity)),e.facility&&(e.facility=parseInt(e.facility)),this.log(e)}},this.sub.onclose=()=>{this.sub=void 0,this.notify(__("Connection closed")),this.quit(!0)},this.tunnel.subscribe(this.sub)}cleanup(){this.sub&&this.sub.close()}checklib(){Antunnel.tunnel?(this.tunnel=Antunnel.tunnel,this.openSession()):this._gui.pushService("Antunnel/AntunnelService").then(t=>{let e=this.systemsetting.system.tunnel_uri;e||(this.error(__("Unable to connect to the tunnel")),this.quit(!0)),Antunnel.init(e).then(t=>{this.notify(__("Tunnel now connected to the server at: {0}",e)),this.tunnel=Antunnel.tunnel,this.openSession()}).catch(t=>{Antunnel.tunnel&&(Antunnel.tunnel.close(),this.error(__("Unable to connect to the tunnel: {0}",t.toString()),t),this.quit(!0))})}).catch(t=>{this.error(__("Unable to run Antunnel service: {0}",t.toString()),t),this.quit(!0)})}main(){if(!Antunnel)return this.error(__("Antunnel library is not available")),void this.quit(!0);this.log_container=this.find("log-container"),this.logs=[],$(this.log_container).css("overflow-y","auto");let t=this.find("menu-level");t.onmenuselect=t=>{let e=t.data.item.data;this.filter[e.severity]=e.checked,console.log(this.filter)},t.items=[{text:__("Debug"),switch:!0,checked:!0,severity:"debug"},{text:__("Notice"),switch:!0,checked:!0,severity:"notice"},{text:__("Info"),switch:!0,checked:!0,severity:"info"},{text:__("Warning"),switch:!0,checked:!0,severity:"warning"},{text:__("Error"),switch:!0,checked:!0,severity:"err"},{text:__("Critical"),switch:!0,checked:!0,severity:"crit"},{text:__("Alert"),switch:!0,checked:!0,severity:"alert"},{text:__("Emergency"),switch:!0,checked:!0,severity:"emerg"}],this.filter={max_log:500,err:!0,emerg:!0,debug:!0,info:!0,notice:!0,warning:!0,crit:!0,alert:!0,pattern:void 0,record:!0};let e=this.find("txt-n-log");e.value=this.filter.max_log.toString(),$(e).on("keyup",t=>{if("Enter"===t.key){let t=parseInt(e.value);if(!isNaN(t))for(this.filter.max_log=t;this.logs.length>t;)this.logs.shift().el.remove();e.value=this.filter.max_log.toString()}}),this.find("btn-clear").onbtclick=()=>{this.logs=[],$(this.log_container).empty()};let i=this.find("txt-reg");$(i).on("keyup",t=>{if("Enter"===t.key){if(""===i.value.trim())return this.filter.pattern=void 0;try{this.filter.pattern=new RegExp(i.value,"g")}catch(t){this.error(__("Invalid regular expression: {0}",t.toString()),t),this.filter.pattern=void 0,i.value=""}}}),this.find("sw-record").onswchange=t=>{this.filter.record=t.data},this.setting.topic?this.checklib():this.openDialog("PromptDialog",{title:__("Enter topic name"),label:__("Please enter Antunnel topic name")}).then(t=>{this.setting.topic=t,this.checklib()})}}t.ServerLogClient=e,e.dependencies=["pkg://Antunnel/main.js"],e.singleton=!0}(e=t.application||(t.application={}))}(OS||(OS={}));
|
@ -1,17 +1,15 @@
|
||||
<afx-app-window apptitle="__(Server system log)" width="600" height="400" data-id="ServerLogClient">
|
||||
<afx-vbox >
|
||||
<afx-hbox data-height="35" data-id="top-header">
|
||||
<afx-button text="__(Clear)" data-id="btn-clear" data-width="content"></afx-button>
|
||||
<afx-menu data-id="menu-level" data-width="content"></afx-menu>
|
||||
<afx-label class="field-label" text="__(Filter)" data-width="content"></afx-label>
|
||||
<input type="text" data-id="txt-reg"></input>
|
||||
<afx-label class="field-label" text="__(Keep up to)" data-width="content"></afx-label>
|
||||
<input type="text" data-width="50" data-id="txt-n-log"></input>
|
||||
<afx-label class="field-label" text="__(Record)" data-width="content"></afx-label>
|
||||
<afx-switch swon="true" data-id="sw-record" data-width="content"></afx-switch>
|
||||
</afx-hbox>
|
||||
<div data-id="log-container">
|
||||
|
||||
</div>
|
||||
</afx-vbox>
|
||||
<afx-hbox padding="5">
|
||||
<afx-stack-menu data-id="menu-level" data-width="content"></afx-stack-menu>
|
||||
<afx-vbox>
|
||||
<afx-hbox data-height="45" data-id="top-header">
|
||||
<afx-button text="__(Clear)" data-id="btn-clear" data-width="content"></afx-button>
|
||||
<afx-input type="text" data-id="txt-reg"label = "__(Filter)" ></afx-input>
|
||||
<afx-input type="text" label="__(Keep)" data-width="50" data-id="txt-n-log"></afx-input>
|
||||
<afx-label class="field-label" text="__(Record)" data-width="content"></afx-label>
|
||||
<afx-switch swon="true" data-id="sw-record" data-width="content"></afx-switch>
|
||||
</afx-hbox>
|
||||
<div data-id="log-container"></div>
|
||||
</afx-vbox>
|
||||
</afx-hbox>
|
||||
</afx-app-window>
|
Binary file not shown.
@ -48,8 +48,4 @@ afx-app-window[data-id="ServerLogClient"] afx-hbox[data-id="top-header"] afx-lab
|
||||
text-align: right;
|
||||
padding-top: 5px;
|
||||
padding-right: 3px;
|
||||
}
|
||||
|
||||
afx-app-window[data-id="ServerLogClient"] afx-hbox[data-id="top-header"] afx-label.field-label i.label-text{
|
||||
font-weight: bold;
|
||||
}
|
@ -186,64 +186,60 @@ namespace OS {
|
||||
this.logs = [];
|
||||
$(this.log_container)
|
||||
.css("overflow-y", "auto");
|
||||
let menu = this.find("menu-level") as GUI.tag.MenuTag;
|
||||
let menu = this.find("menu-level") as GUI.tag.StackMenuTag;
|
||||
menu.onmenuselect = (e) => {
|
||||
let data = e.data.item.data;
|
||||
this.filter[data.severity] = data.checked;
|
||||
console.log(this.filter);
|
||||
}
|
||||
menu.items = [
|
||||
{
|
||||
text: __("Default level"),
|
||||
nodes: [
|
||||
{
|
||||
text: __("Debug"),
|
||||
switch: true,
|
||||
checked: true,
|
||||
severity: "debug"
|
||||
},
|
||||
{
|
||||
text: __("Notice"),
|
||||
switch: true,
|
||||
checked: true,
|
||||
severity: "notice"
|
||||
},
|
||||
{
|
||||
text: __("Info"),
|
||||
switch: true,
|
||||
checked: true,
|
||||
severity: "info"
|
||||
},
|
||||
{
|
||||
text: __("Warning"),
|
||||
switch: true,
|
||||
checked: true,
|
||||
severity: "warning"
|
||||
},
|
||||
{
|
||||
text: __("Error"),
|
||||
switch: true,
|
||||
checked: true,
|
||||
severity: "err"
|
||||
},
|
||||
{
|
||||
text: __("Critical"),
|
||||
switch: true,
|
||||
checked: true,
|
||||
severity: "crit"
|
||||
},
|
||||
{
|
||||
text: __("Alert"),
|
||||
switch: true,
|
||||
checked: true,
|
||||
severity: "alert"
|
||||
},
|
||||
{
|
||||
text: __("Emergency"),
|
||||
switch: true,
|
||||
checked: true,
|
||||
severity: "emerg"
|
||||
}
|
||||
],
|
||||
onchildselect: (e) => {
|
||||
let data = e.data.item.data;
|
||||
this.filter[data.severity] = data.checked;
|
||||
}
|
||||
text: __("Debug"),
|
||||
switch: true,
|
||||
checked: true,
|
||||
severity: "debug"
|
||||
},
|
||||
{
|
||||
text: __("Notice"),
|
||||
switch: true,
|
||||
checked: true,
|
||||
severity: "notice"
|
||||
},
|
||||
{
|
||||
text: __("Info"),
|
||||
switch: true,
|
||||
checked: true,
|
||||
severity: "info"
|
||||
},
|
||||
{
|
||||
text: __("Warning"),
|
||||
switch: true,
|
||||
checked: true,
|
||||
severity: "warning"
|
||||
},
|
||||
{
|
||||
text: __("Error"),
|
||||
switch: true,
|
||||
checked: true,
|
||||
severity: "err"
|
||||
},
|
||||
{
|
||||
text: __("Critical"),
|
||||
switch: true,
|
||||
checked: true,
|
||||
severity: "crit"
|
||||
},
|
||||
{
|
||||
text: __("Alert"),
|
||||
switch: true,
|
||||
checked: true,
|
||||
severity: "alert"
|
||||
},
|
||||
{
|
||||
text: __("Emergency"),
|
||||
switch: true,
|
||||
checked: true,
|
||||
severity: "emerg"
|
||||
}
|
||||
];
|
||||
|
||||
|
@ -1,17 +1,15 @@
|
||||
<afx-app-window apptitle="__(Server system log)" width="600" height="400" data-id="ServerLogClient">
|
||||
<afx-vbox >
|
||||
<afx-hbox data-height="35" data-id="top-header">
|
||||
<afx-button text="__(Clear)" data-id="btn-clear" data-width="content"></afx-button>
|
||||
<afx-menu data-id="menu-level" data-width="content"></afx-menu>
|
||||
<afx-label class="field-label" text="__(Filter)" data-width="content"></afx-label>
|
||||
<input type="text" data-id="txt-reg"></input>
|
||||
<afx-label class="field-label" text="__(Keep up to)" data-width="content"></afx-label>
|
||||
<input type="text" data-width="50" data-id="txt-n-log"></input>
|
||||
<afx-label class="field-label" text="__(Record)" data-width="content"></afx-label>
|
||||
<afx-switch swon="true" data-id="sw-record" data-width="content"></afx-switch>
|
||||
</afx-hbox>
|
||||
<div data-id="log-container">
|
||||
|
||||
</div>
|
||||
</afx-vbox>
|
||||
<afx-hbox padding="5">
|
||||
<afx-stack-menu data-id="menu-level" data-width="content"></afx-stack-menu>
|
||||
<afx-vbox>
|
||||
<afx-hbox data-height="45" data-id="top-header">
|
||||
<afx-button text="__(Clear)" data-id="btn-clear" data-width="content"></afx-button>
|
||||
<afx-input type="text" data-id="txt-reg"label = "__(Filter)" ></afx-input>
|
||||
<afx-input type="text" label="__(Keep)" data-width="50" data-id="txt-n-log"></afx-input>
|
||||
<afx-label class="field-label" text="__(Record)" data-width="content"></afx-label>
|
||||
<afx-switch swon="true" data-id="sw-record" data-width="content"></afx-switch>
|
||||
</afx-hbox>
|
||||
<div data-id="log-container"></div>
|
||||
</afx-vbox>
|
||||
</afx-hbox>
|
||||
</afx-app-window>
|
@ -17,8 +17,10 @@
|
||||
"require": ["ts"],
|
||||
"jobs":[
|
||||
{
|
||||
"name": "ts-import",
|
||||
"data": ["sdk://core/ts/core.d.ts", "sdk://core/ts/jquery.d.ts","sdk://core/ts/antos.d.ts"]
|
||||
"name": "ts-antos-sdk",
|
||||
"data": {
|
||||
"version": "2.0.x"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "ts-compile",
|
||||
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -2,6 +2,7 @@
|
||||
AntOSDK: development API for AntOS based applications/projects
|
||||
|
||||
## Change logs
|
||||
- 0.1.2: add batch building support
|
||||
- 0.1.1: linux worker is renamed to backend, linux-exec job re to cmd-exec, add lua-exec job for backend lua script execution
|
||||
- 0.1.0: antOS SDK is no longer delivered in this package, it will be fetched directly from AntOS release site
|
||||
- 0.0.18: Add some public API on grid view
|
||||
|
@ -2,6 +2,7 @@
|
||||
AntOSDK: development API for AntOS based applications/projects
|
||||
|
||||
## Change logs
|
||||
- 0.1.2: add batch building support
|
||||
- 0.1.1: linux worker is renamed to backend, linux-exec job re to cmd-exec, add lua-exec job for backend lua script execution
|
||||
- 0.1.0: antOS SDK is no longer delivered in this package, it will be fetched directly from AntOS release site
|
||||
- 0.0.18: Add some public API on grid view
|
||||
|
File diff suppressed because one or more lines are too long
@ -7,7 +7,7 @@
|
||||
"author": "Xuan Sang LE",
|
||||
"email": "mrsang@iohub.dev"
|
||||
},
|
||||
"version": "0.1.1-b",
|
||||
"version": "0.1.2-b",
|
||||
"category": "Development",
|
||||
"iconclass": "fa fa-cog",
|
||||
"mimes": [
|
||||
|
Binary file not shown.
@ -7,7 +7,7 @@
|
||||
"author": "Xuan Sang LE",
|
||||
"email": "mrsang@iohub.dev"
|
||||
},
|
||||
"version": "0.1.1-b",
|
||||
"version": "0.1.2-b",
|
||||
"category": "Development",
|
||||
"iconclass": "fa fa-cog",
|
||||
"mimes": [
|
||||
|
@ -139,7 +139,7 @@ namespace OS {
|
||||
const selected = this.targets.selectedItem;
|
||||
if(!selected)
|
||||
return;
|
||||
this.load(this.compile([selected.data.text]));
|
||||
this.load(this.compile([selected.data.text])).catch((e) => this.logger.error(__(e.stack)));
|
||||
}
|
||||
|
||||
(this.find("btnclear") as GUI.tag.ButtonTag).onbtclick = (e) => {
|
||||
|
@ -195,6 +195,58 @@ namespace OS {
|
||||
}
|
||||
});
|
||||
}
|
||||
else if(job === "batch")
|
||||
{
|
||||
return new Promise(async (resolve, reject) =>
|
||||
{
|
||||
try{
|
||||
if(!data || !data.target)
|
||||
{
|
||||
const err = __("No target provided for job: batch");
|
||||
this.logger.error(err);
|
||||
throw new Error(err.__());
|
||||
}
|
||||
let pwd = data.pwd;
|
||||
if(!pwd)
|
||||
{
|
||||
pwd = this.root;
|
||||
}
|
||||
const ret = await pwd.asFileHandle().read();
|
||||
if(ret.error)
|
||||
{
|
||||
this.logger.error(ret.error);
|
||||
throw new Error(ret.error);
|
||||
}
|
||||
const dirs = ret.result.filter(e => e.type === "dir");
|
||||
for(let entry of dirs)
|
||||
{
|
||||
const build_file = `${entry.path}/build.json`.asFileHandle();
|
||||
try {
|
||||
await build_file.onready();
|
||||
}
|
||||
catch(e)
|
||||
{
|
||||
this.logger.info(__("No build.json file found in {0}, ignore this file", entry.path));
|
||||
continue;
|
||||
}
|
||||
this.logger.info(__("########### BUILDING: {0} ###########", entry.path));
|
||||
const sdk = new AntOSDKBuilder(this.logger,entry.path);
|
||||
const options = await build_file.read("json");
|
||||
if(!options.root)
|
||||
{
|
||||
options.root = entry.path;
|
||||
}
|
||||
await sdk.batch([data.target], options);
|
||||
}
|
||||
this.logger.info(__("########### Batch building done ###########"));
|
||||
return resolve(undefined);
|
||||
}
|
||||
catch(error)
|
||||
{
|
||||
reject(error);
|
||||
}
|
||||
});
|
||||
}
|
||||
return AntOSDKBuilder.worker.submit(job,data, this.root, this.logger);
|
||||
}
|
||||
|
||||
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -17,8 +17,10 @@
|
||||
"data": ["build","build/debug","build/release"]
|
||||
},
|
||||
{
|
||||
"name": "ts-import",
|
||||
"data": ["sdk://core/ts/core.d.ts", "sdk://core/ts/jquery.d.ts","sdk://core/ts/antos.d.ts"]
|
||||
"name": "ts-antos-sdk",
|
||||
"data": {
|
||||
"version": "2.0.x"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "ts-compile",
|
||||
|
Binary file not shown.
Binary file not shown.
Loading…
Reference in New Issue
Block a user