Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
// tslint:disable
import { Table } from "@hpcc-js/dgrid";
import { FieldForm } from "@hpcc-js/form";
import * as marshaller from "@hpcc-js/marshaller";
// Dashboard Element Container (Model) ---
const ec = new marshaller.ElementContainer();
namespace data {
export const Ins002_dsOutput1 = new marshaller.WU(ec)
.url("http://10.173.147.1:8010/")
.wuid("W20190617-131840")
;
export const Ins002_dsOutput1_Ins002_dsOutput1_View_table1 = new marshaller.WUResult(ec)
.wu(Ins002_dsOutput1)
.resultName("Ins002_dsOutput1_View_table1")
.responseFields([{ id: "state", type: "string" }, { id: "id", type: "number64" }, { id: "first_name", type: "string" }, { id: "last_name", type: "string" }, { id: "gender", type: "string" }, { id: "lat", type: "number" }, { id: "lng", type: "number" }, { id: "whole_number", type: "number64" }, { id: "decimal_number", type: "number" }, { id: "created_time", type: "string" }, { id: "created_date", type: "string" }, { id: "vip", type: "string" }])
;
export const e_8 = new marshaller.Form()
.formFields([
new marshaller.FormField().fieldID("filter_state")
])
;
init(placeholder: string, urlStr, layoutJson?) {
const _url = new Comms.ESPUrl().url(urlStr);
if (!!_url.param("dashboard")) {
this._dashy = new Dashboard(new ElementContainer())
.target(placeholder)
.hideSingleTabs(true)
.titleVisible(false)
.render()
;
} else {
this._dashy = new Dashy()
.target(placeholder)
.render()
;
}
this._dashy.element()
.on("drop", () => this.dropHandler(this.event()))
.on("dragover", () => this.dragOverHandler(this.event()))
;
export function loadDashboard(target: string) {
const ec = new ElementContainer();
const dashboard = new Dashboard(ec);
dashboard
.target(target)
.titleVisible(false)
.hideSingleTabs(true)
.restore(sample as any)
.render(w => {
ec.refresh();
})
;
}