Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
const view = this.getDetailView();
let options = {
descriptor: entry.description || desc, // keep for backwards compat
title: entry.description || desc,
key,
fromContext: this,
offlineContext: {
entityId: this._model.getEntityId(entry),
entityName: this._model.entityName,
viewId: this._model.detailViewId,
offlineDate: entry.$offlineDate,
source: entry,
},
};
if (additionalOptions) {
options = lang.mixin(options, additionalOptions);
}
// Ensure we have a valid offline detail view and the
// entity has a detail view that it can use for layout.
const modelDetailView = this._model.detailViewId;
const impliedDetailView = `${this._model.entityName.toLowerCase()}_detail`;
if (view && App.getView(modelDetailView || impliedDetailView)) {
view.show(options);
}
},
getDetailView: function getDetailView() {
navigateToOfflineDetailView: function navigateToOfflineDetailView(entry, additionalOptions) {
const view = this.getDetailView(entry.entityName);
let options = {
descriptor: entry.description, // keep for backwards compat
title: entry.description,
key: entry.entityId,
fromContext: this,
offlineContext: {
entityId: entry.entityId,
entityName: entry.entityName,
viewId: entry.viewId,
source: entry,
},
};
if (additionalOptions) {
options = lang.mixin(options, additionalOptions);
}
if (view) {
view.show(options);
}
},
getDetailView: function getDetailView(entityName) {
define("dojo/tests/_base/loader/modules/idFactoryArityExports", function(require, exports, module){
var impliedDep = require("./impliedDep4");
require("dojo/_base/lang").mixin(exports, {
module:module,
id:"idFactoryArityExports",
impliedDep:impliedDep.id
});
});
define("dojo/testsDOH/_base/loader/modules/idFactoryArityExports", function(require, exports, module){
var impliedDep = require("./impliedDep4");
require("dojo/_base/lang").mixin(exports, {
module:module,
id:"idFactoryArityExports",
impliedDep:impliedDep.id
});
});
}
if (params.SafeMode && params.SafeMode !== "false") {
this.main.depth.set("value", 1);
var dotAttrs = this.global.getDotMetaAttributes();
dotAttrs = dotAttrs.replace("\n//graph[splines=\"line\"];", "\ngraph[splines=\"line\"];");
this.global.setDotMetaAttributes(dotAttrs);
} else {
var dotAttrs = this.global.getDotMetaAttributes();
dotAttrs = dotAttrs.replace("\ngraph[splines=\"line\"];", "\n//graph[splines=\"line\"];");
this.global.setDotMetaAttributes(dotAttrs);
}
this.graphName = params.GraphName;
this.subGraphId = params.SubGraphId;
this.widget.TimingsTreeMap.init(lang.mixin({
query: {
graphsOnly: true,
graphName: this.graphName,
subGraphId: "*"
},
hideHelp: true
}, params));
this.widget.ActivitiesTreeMap.init(lang.mixin({
query: {
activitiesOnly: true,
graphName: this.graphName,
subGraphId: "*"
},
hideHelp: true
}, params));
arrayUtil.forEach(response.BasednsResponse.Basedns.Basedn, function (item, idx) {
data.push(lang.mixin(item, {
__hpcc_type: "Permission",
__hpcc_id: item.basedn,
DisplayName: item.name,
children: lang.mixin(CreateResourcesStore(this.groupname, this.username, item.basedn), {
parent: this,
parentRow: item
})
}));
}, this);
}
setupRightDrawer: function setupRightDrawer() {
const drawer = App.getView('right_drawer');
if (drawer) {
lang.mixin(drawer, this._createActions());
drawer.setLayout(this.createRightDrawerLayout());
drawer.getGroupForEntry = lang.hitch(this, function getGroupForRightDrawerEntry(entry) {
return this.getGroupForRightDrawerEntry(entry);
});
App.viewSettingsModal.element.on('close', () => {
if (this._hasChangedEntityPrefs) {
this.clear();
this.refreshRequired = true;
this.refresh();
this._hasChangedEntityPrefs = false;
this._hasChangedKPIPrefs = false;
}
if (this._hasChangedKPIPrefs && this.rebuildWidgets) {
this.destroyWidgets();
_TimersSetter: function (Timers) {
var timers = [];
for (var i = 0; i < Timers.ECLTimer.length; ++i) {
var secs = Utility.espTime2Seconds(Timers.ECLTimer[i].Value);
timers.push(lang.mixin(Timers.ECLTimer[i], {
__hpcc_id: i + 1,
Seconds: Math.round(secs * 1000) / 1000,
HasSubGraphId: Timers.ECLTimer[i].SubGraphId && Timers.ECLTimer[i].SubGraphId !== "" ? true : false
}));
}
this.set("timers", timers);
},
_ResourceURLCountSetter: function (ResourceURLCount) {
copy: function (params) {
lang.mixin(params.request, {
sourceLogicalName: this.Name
});
return FileSpray.Copy(params);
},
rename: function (params) {
put: ESPUtil.override(function (inherited, row) {
this.get(row.__hpcc_id);
var retVal = inherited(arguments);
var request = {
account_name: this.groupname ? this.groupname : this.username,
account_type: this.groupname ? 1 : 0,
basedn: row.__hpcc_parent.basedn,
rtitle: row.__hpcc_parent.rtitle,
rtype: row.__hpcc_parent.rtype,
rname: row.name,
action: "update"
};
lang.mixin(request, row);
delete request['__hpcc_parent'];
PermissionAction({
request: request
});
return retVal;
}),