/column_renderer_list.do It is based on ui_macro.
...
this.getParameter('x-referer');
The value is a URL the request is coming from.
GlideTableDescriptor - mostly closed.
SNC.TableEditor
SncTableEditor
TableDrop SI?
GlideDBObjectManager (TableUtils wraps it).
GlideTableCleanupAPI.cleanupHierarchicalData(tableName);
GlideDBUtil
GlideDBUtil.promoteColumn(sourceTable, targetTable, column, promoteCheck)
/**
Moves (promotes) a column from one table to another in the table hierarchy, optionally verifying the relationship between source and target tables.
If the move is a promotion, this will move all columns from the child tables that have the same column name as the target column name.
Otherwise, it will only move the column from the source table to the target table.
* @param sourceTable (string) - The table currently containing the column to be promoted.
* @param targetTable (string) - The table that will have the column after promotion.
* @param column (string) - The column to be promoted.
* @param promoteCheck (boolean) - This method should verify that the source table is a child of the target table.
*/
/styles/retina_icons/retina_icons.html
This syntax is allowed to supply JOIN condtion for a query. Source is AssociateCIToTask script include.
existingCI.addQuery('JOINtask.sys_id=task_ci.task');
onAfterClose onAfterLoad
/* URL composition
var url = new GlideURL("task_add_affected_cis.do");
url.set("sysparm_crSysId", chgReqId);
url.set("sysparm_view", "associate_ci");
url.set("sysparm_add_to", addToTable);
url.set("sysparm_stack", "no");
url.set("sysparm_table", latestClassAdded);
url.set("sysparm_parent_class", parentClass);
*/
///-----
var cmdbciOverlay = new GlideOverlay({
id : "cm_add_affected_cis",
title : getMessage("Add Affected Configuration Items"),
iframe : url,
closeOnEscape : true,
showClose : true,
onAfterClose: refreshAffectedCIs,
onAfterLoad: resizeIframe, //Once PRB632264 is fixed by platform we can comment this line
height : "90%",
width : "90%"
});
There is no need to instantiate a separate GlideDateTime
object using constructor. Use GlideElement
reference and getGlideObject()
method.
current.opened_on.getGlideObject().addYearsUTC(1);
Yes, it's true. Most probably, because notifications trigger based on events (event Insert/Update notification). Even processing doesn't consider table hierarchy.
This trick works. I define a utility class in one onload script and use it in others.
/* Client script on order 10. */
function onLoad() {
/* Loading utility client functions for Change request */
}
function ChangeClientUtils() {
this.isInPast = function(dt) {
if(!dt) {
// no field value
return false;
}
var x = getDateFromFormat(dt, g_user_date_time_format);
var now = Date.now();
return x < now;
};
this.isGoLiveStartInPast = function() {
return this.isInPast(g_form.getValue('start_date'));
};
this.isGoLiveEndInPast = function() {
return this.isInPast(g_form.getValue('end_date'));
};
this.isStartEndInSequence = function() {
var s = getDateFromFormat(g_form.getValue('start_date'), g_user_date_time_format);
var e = getDateFromFormat(g_form.getValue('end_date'), g_user_date_time_format);
return s < e;
};
this.isRetrospective = function() {
return g_form.getBooleanValue('u_retrospective');
};
this.isEmergency = function() {
return g_form.getValue('type') == 'Emergency';
};
}
Noticed in OOTB: sp_widget.do?sys_id=cb6631d39f2003002899d4b4232e7030
var x = new GlideChoiceListGenerator('incident', 'state');
var c = x.get();
gs.print(c);
>> [New : 1, In Progress : 2, On Hold : 3, Resolved : 6, Closed : 7, Canceled : 8]
And here is the list of remarkable attributes:
- activeOnly
- setActiveOnly
- inactiveOnly
- setInactiveOnly
- dependentValue
- setDependentValue
- recordList
- getRecordList
- none
- setNone
- cache
- setCache
- get
- scripted
- isScripted
- all
- setAll
- extensions
- setExtensions
- choiceList
- getChoiceList
...and, for example, Update Set retrieval is queued forever
a. Go to /v_cluster_transaction_list.do, refresh (UI Action link), locate the oldest job and kill it.
Dictionary attribute: is_multi_text=true|false
Credits to Cris L.