fleet-contractor/Site/Maintenance/AlertAutomationManagement.aspx
2024-03-26 15:56:31 +08:00

698 lines
30 KiB
Plaintext

<%@ Page Title="" Language="C#" MasterPageFile="~/Maintenance/MaintenanceBase.master" AutoEventWireup="true" CodeFile="AlertAutomationManagement.aspx.cs" Inherits="AlertAutomationManagement" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
<style type="text/css">
::-ms-clear, ::-ms-reveal {
display: none;
}
.label { /*cover tab.css*/
display: table-cell;
}
.sbutton {
font-weight: 200;
}
.dialog, .data-column-header-filter-panel, .data-column-header-filter-bg {
z-index: 700;
}
.dialog-content table td.label {
width: 120px;
}
.dialog-content table td input[type="text"], .dialog-content table td textarea {
width: 320px;
}
</style>
<link href="<%=GetFileUrlWithVersion("../css/tabcontrol.css")%>" rel="stylesheet" />
<link href="<%=GetFileUrlWithVersion("../css/spectrum.css")%>" rel="stylesheet" type="text/css" />
<script src="../js/spectrum.js?v=1" type="text/javascript"></script>
<script src="<%=GetFileUrlWithVersion("../js/controls.js")%>" type="text/javascript"></script>
<script src="<%=GetFileUrlWithVersion("../js/utility.js")%>" type="text/javascript"></script>
<script src="<%=GetFileUrlWithVersion("../js/language.js")%>" type="text/javascript"></script>
<script src="<%=GetFileUrlWithVersion("../js/modulelang.js")%>" type="text/javascript"></script>
<script type="text/javascript">
function alertrequest(method, param, callback, error) {
_network.request("Maintenance/AlertAutomationManagement.aspx", -1, method, param, callback, error || function (e) {
console.log(e);
showmaskbg(false, true);
showAlert(GetTextByKey('P_UM_PAGEERROR', 'An unknown error occurred. Please refresh page.'), GetTextByKey('P_UM_QUERY', 'Query'));
});
}
function worequest(method, param, callback, error) {
_network.request("Maintenance/WorkOrderMaintenance.aspx", -1, method, param, callback, error || function (e) {
console.log(e);
showmaskbg(false, true);
showAlert(GetTextByKey('P_UM_PAGEERROR', 'An unknown error occurred. Please refresh page.'), GetTextByKey('P_UM_QUERY', 'Query'));
});
}
function showstatusmask(flag) {
if (flag) {
$('#statusmask').fadeIn(100);
} else {
$('#statusmask').fadeOut(100);
}
}
function OnExit() {
window.parent.CloseAlertAutomationDialog();
}
//******************************Begin Auto Acknowledge**********************************//
function showAutoAcknowledge(data) {
var rows = [];
for (var i = 0; i < data.length; i++) {
var r = data[i];
rows.push(r);
}
autoacknowledge_dt.setData(rows);
}
var autoacknowledge_dt;
function InitAutoAcknowledgeGridData() {
autoacknowledge_dt = createGridView('#div_autoacknowledgelist');
var list_columns = [
{ name: 'Selected', caption: "", valueIndex: 'Selected', type: 3, css: { 'width': 45, 'text-align': 'center' } },
{ name: 'Value', caption: GetTextByKey("P_AM_ALERTTYPE", "Alert Type"), valueIndex: 'Value', css: { 'width': 300, 'text-align': 'left' } }
];
var columns = [];
// head
for (var hd in list_columns) {
var col = {};
col.name = list_columns[hd].name;
col.caption = list_columns[hd].caption;
col.visible = true;
col.sortable = true;
col.width = list_columns[hd].css.width;
col.align = list_columns[hd].css["text-align"]
col.key = list_columns[hd].valueIndex;
col.allowFilter = list_columns[hd].allowFilter;
if (list_columns[hd].type) {
col.type = list_columns[hd].type;
}
columns.push(col);
}
autoacknowledge_dt.multiSelect = false;
autoacknowledge_dt.columns = columns;
autoacknowledge_dt.init();
}
var alerttypesdata;
function GetAlertTypes() {
alertrequest('GetAlertTypes', '', function (data) {
if (typeof (data) === "string") {
showAlert(data, GetTextByKey("P_AM_ERROR", 'Error'));
return;
}
data.splice(0, 0, { Key: "", Value: GetTextByKey("P_AM_BLANK", '(Blank)') });
alerttypesdata = data;
$("#div_alerttype").dropdownSource(alerttypesdata);
GetAutoAcknowledgeAlertTypes();
});
}
function GetAssetGroups() {
alertrequest('GetAssetGroups', '', function (data) {
if (typeof (data) === "string") {
showAlert(data, GetTextByKey("P_AM_ERROR", 'Error'));
return;
}
$("#div_assetgroup").dropdownSource(data);
});
}
function GetJobsites() {
alertrequest('GetJobsites', '', function (data) {
if (typeof (data) === "string") {
showAlert(data, GetTextByKey("P_AM_ERROR", 'Error'));
return;
}
$("#div_jobsites").dropdownSource(data);
});
}
function GetAssigntos() {
alertrequest('GetAssignTos', '', function (data) {
if (typeof (data) === "string") {
showAlert(data, GetTextByKey("P_AM_ERROR", 'Error'));
return;
}
$("#div_assigntos").dropdownSource(data);
});
}
function GetWorkOrderStatuses() {
worequest('GetWorkOrderStatuses', '', function (data) {
if (typeof (data) === "string") {
showAlert(data, GetTextByKey("P_AM_ERROR", 'Error'));
return;
}
if (data && data.length > 0) {
$("#dialog_wostatus").empty();
for (var i = 0; i < data.length; i++) {
var kv = data[i];
var op = $("<option></option>").val(kv.Id).text(kv.Name);
$("#dialog_wostatus").append(op);
}
}
});
}
function GetAutoAcknowledgeAlertTypes() {
alertrequest('GetAutoAcknowledgeAlertTypes', '', function (data) {
if (typeof (data) === "string") {
showAlert(data, GetTextByKey("P_AM_ERROR", 'Error'));
return;
}
var types = [];
for (var i = 0; i < alerttypesdata.length; i++) {
var t = alerttypesdata[i];
if (t.Key === "Preventative Maintenance" || t.Key === "Yellow-Inspect" || t.Key === "Red-Inspect")
continue;
t.Selected = false;
if (data.indexOf(alerttypesdata[i].Key) >= 0)
t.Selected = true;
types.push(t);
}
showAutoAcknowledge(types);
});
}
function OnViewAutoAcknowledChangeHistory() {
window.open("AutoAcknowledChangeHistory.aspx");
}
function onSaveAutoAcknowledgeAlertTypes() {
var alerttypes = [];
var tempsource = autoacknowledge_dt.source;
for (var i = 0; i < tempsource.length; i++) {
var ct = tempsource[i];
if (ct.Selected)
alerttypes.push(ct.Key);
}
alertrequest('SaveAutoAcknowledgeAlertTypes', htmlencode(JSON.stringify(alerttypes)), function (data) {
if (data !== "OK") {
showAlert(data, GetTextByKey("P_MV_ERROR", 'Error'));
}
else {
showAlert(GetTextByKey('P_WO_SAVSUCCESSFULLY', 'Saved successfully.'), GetTextByKey("P_AM_AUTOACKNOWLEDGE", 'Auto-Acknowledge'));
}
});
}
//******************************End Auto Acknowledge**********************************//
//******************************Begin Work Order Generator**********************************//
var wogeneratorgrid_dt;
function InitWOGeneratorGridData() {
wogeneratorgrid_dt = createGridView('#wogeneratorlist');
var list_columns = [
{ name: 'AlertTypesStr', caption: GetTextByKey("P_AM_ALERTTYPE", "Alert Type"), valueIndex: 'AlertTypesStr', allowFilter: true, css: { 'width': 200, 'text-align': 'left' } },
{ name: 'AssetGroupsStr', caption: GetTextByKey("P_AM_ASSETGROUP", "Asset Group"), valueIndex: 'AssetGroupsStr', css: { 'width': 200, 'text-align': 'left' } },
{ name: 'JobSitesStr', caption: GetTextByKey("P_UM_JOBSITES", "Jobsite(s)"), valueIndex: 'JobSitesStr', css: { 'width': 200, 'text-align': 'left' } },
{ name: 'AssignTosStr', caption: GetTextByKey("P_JS_ASSIGNEDTO", "Assigned To"), valueIndex: 'AssignTosStr', css: { 'width': 200, 'text-align': 'left' } },
{ name: 'StatusAssignmentName', caption: GetTextByKey("P_AM_STATUSASSIGNMENT", "Status Assignment"), valueIndex: 'StatusAssignmentName', allowFilter: true, css: { 'width': 150, 'text-align': 'left' } },
{ name: 'IncludeAllAlerts', caption: GetTextByKey("P_AM_INCLUDEALLALERTS", "Include All Alerts"), valueIndex: 'IncludeAllAlerts', allowFilter: true, css: { 'width': 150, 'text-align': 'left' } },
{ name: 'EmailWorkorder', caption: GetTextByKey("P_AM_EMAILWORKORDER", "Email Work Order"), valueIndex: 'EmailWorkorder', allowFilter: true, css: { 'width': 150, 'text-align': 'left' } },
{ name: 'EmailFrom', caption: GetTextByKey("P_AM_EMAILFROM", "Email From"), valueIndex: 'EmailFrom', allowFilter: true, css: { 'width': 150, 'text-align': 'left' } },
{ name: 'Description', caption: GetTextByKey("P_AM_DESCRIPTION", "Description"), valueIndex: 'Description', css: { 'width': 150, 'text-align': 'left' } },
{ name: 'Edit', caption: "", css: { 'width': 30, 'text-align': 'center' } },
{ name: 'Delete', caption: "", css: { 'width': 30, 'text-align': 'center' } }
];
var columns = [];
// head
for (var hd in list_columns) {
var col = {};
col.name = list_columns[hd].name;
col.caption = list_columns[hd].caption;
col.visible = true;
col.sortable = true;
col.width = list_columns[hd].css.width;
col.align = list_columns[hd].css["text-align"]
col.key = list_columns[hd].valueIndex;
col.allowFilter = list_columns[hd].allowFilter;
col.type = list_columns[hd].type;
if (col.name === "Edit") {
col.sortable = false;
col.resizable = false;
col.type = GridView.ColumnTypes.Icon;
col.text = "edit";
col.events = {
onclick: function () {
OnEditWOGenerator();
}
};
col.classFilter = function (e) {
return "icon-col";
}
col.attrs = { 'title': GetTextByKey("P_UM_EDIT", 'Edit') };
}
else if (col.name === "Delete") {
col.sortable = false;
col.resizable = false;
col.type = GridView.ColumnTypes.Icon;
col.text = "times";
col.events = {
onclick: function () {
OnDeleteWOGenerator(this);
}
};
col.classFilter = function (e) {
return "icon-col";
};
col.styleFilter = function (e) {
if (e.Id == 100)
return { "display": "none" };
};
col.attrs = { 'title': GetTextByKey("P_UM_DELETE", 'Delete') };
}
columns.push(col);
}
wogeneratorgrid_dt.multiSelect = false;
wogeneratorgrid_dt.columns = columns;
wogeneratorgrid_dt.init();
wogeneratorgrid_dt.onRowDblClicked = OnEditWOGenerator;
}
function GetWorkOrderGenerators() {
alertrequest('GetWorkOrderGenerators', '', function (data) {
if (typeof (data) === "string") {
showAlert(data, GetTextByKey('P_AM_ALERTAUTOMATION', "Alert Automation"));
showstatusmask(false);
return;
}
showWorkOrderGenerators(data);
}, function (err) {
});
}
function showWorkOrderGenerators(data) {
var rows = [];
for (var i = 0; i < data.length; i++) {
var r = data[i];
var desctype = parseInt(r.DescType);
var desc = "";
if (desctype === 0)
desc = 'Trigger Alerts';
else if (desctype === 1)
desc = 'All Alerts';
else if (desctype === 10)
desc = r.Description;
for (var j in r) {
if (j === "IncludeAllAlerts") {
r[j] = { DisplayValue: r.IncludeAllAlerts ? GetTextByKey("P_UTILITY_YES", "Yes") : GetTextByKey("P_UTILITY_NO", "No"), Value: r[j] };
}
if (j === "EmailWorkorder") {
r[j] = { DisplayValue: r.EmailWorkorder ? GetTextByKey("P_UTILITY_YES", "Yes") : GetTextByKey("P_UTILITY_NO", "No"), Value: r[j] };
}
if (j === "AlertTypesStr") {
r[j] = { DisplayValue: r.AlertTypesStr === "" ? "All" : r.AlertTypesStr, Value: r[j] };
}
if (j === "AssetGroupsStr") {
r[j] = { DisplayValue: r.AssetGroupsStr === "" ? "All" : r.AssetGroupsStr, Value: r[j] };
}
if (j === "JobSitesStr") {
r[j] = { DisplayValue: r.JobSitesStr === "" ? "All" : r.JobSitesStr, Value: r[j] };
}
if (j === "AssignTosStr") {
r[j] = { DisplayValue: r.AssignTosStr === "" ? "All" : r.AssignTosStr, Value: r[j] };
}
if (j === "Description") {
r[j] = { DisplayValue: desc, Value: r[j] };
}
}
rows.push(r);
}
wogeneratorgrid_dt.setData(rows);
}
function OnAddWOGenerator() {
$('#tr_desc').hide();
generatorid = undefined;
var alerttitle = GetTextByKey("P_AM_ADDWORKORDERGENERATOR", 'Add Work Order Generator');
$('#div_alerttype').dropdownVals([]);
$('#div_assetgroup').dropdownVals([]);
$('#div_jobsites').dropdownVals([]);
$('#div_assigntos').dropdownVals([]);
$('#dialog_wostatus').val("");
$('#dialog_includeallalerts').prop('checked', false);
$('#dialog_emailworkorder').prop('checked', false);
$('#dialog_emailfrom').val("");
$('#dialog_desctype').val("");
$('#dialog_desc').val("");
$('#dialog_wogenerator .dialog-title span.title').text(alerttitle);
showmaskbg(true);
$('#dialog_wogenerator')
.css({
'top': (document.documentElement.clientHeight - $('#dialog_wogenerator').height()) / 3,
'left': (document.documentElement.clientWidth - $('#dialog_wogenerator').width()) / 3
}).showDialogfixed();
}
var generatorid;
function OnEditWOGenerator() {
var index = wogeneratorgrid_dt.selectedIndex;
if (index < 0) return;
var generator = wogeneratorgrid_dt.source[index];
generatorid = generator.Id;
$('#div_alerttype').dropdownVals(generator.AlertTypes || []);
$('#div_assetgroup').dropdownVals(generator.AssetGroups || []);
$('#div_jobsites').dropdownVals(generator.JobSites || []);
$('#div_assigntos').dropdownVals(generator.AssignTos || []);
$('#dialog_wostatus').val(generator.StatusAssignment);
$('#dialog_includeallalerts').prop('checked', generator.IncludeAllAlerts.Value);
$('#dialog_emailworkorder').prop('checked', generator.EmailWorkorder.Value);
$('#dialog_emailfrom').val(generator.EmailFrom);
$('#dialog_desctype').val(generator.DescType);
if (parseInt(generator.DescType) === 10) {
$('#tr_desc').show();
$('#dialog_desc').val(generator.Description.Value);
}
else {
$('#tr_desc').hide();
$('#dialog_desc').val("");
}
$('#dialog_wogenerator .dialog-title span.title').text(GetTextByKey("P_AM_EDITWORKORDERGENERATOR", 'Edit Work Order Generator'));
showmaskbg(true);
$('#dialog_wogenerator')
.css({
'top': (document.documentElement.clientHeight - $('#dialog_wogenerator').height()) / 3,
'left': (document.documentElement.clientWidth - $('#dialog_wogenerator').width()) / 3
}).showDialogfixed();
}
function onSaveWorkOrderGenerator() {
showstatusmask(true);
var alerttypes = $('#div_alerttype').dropdownVals();
var assetgroups = $('#div_assetgroup').dropdownVals();
var jobsites = $('#div_jobsites').dropdownVals();
var assigntos = $('#div_assigntos').dropdownVals();
var item = {
'StatusAssignment': $('#dialog_wostatus').val(),
'AlertTypes': alerttypes,
'AssetGroups': assetgroups,
'JobSites': jobsites,
'AssignTos': assigntos,
'IncludeAllAlerts': $('#dialog_includeallalerts').prop('checked'),
'EmailWorkorder': $('#dialog_emailworkorder').prop('checked'),
'EmailFrom': $('#dialog_emailfrom').val(),
'DescType': $('#dialog_desctype').val(),
'Description': $('#dialog_desc').val()
};
var alerttitle;
if (generatorid || generatorid == 0) {
item.Id = generatorid;
alerttitle = GetTextByKey("P_AM_EDITWORKORDERGENERATOR", "Edit Work Order Generator");
} else {
item.Id = -1;
alerttitle = GetTextByKey("P_AM_ADDWORKORDERGENERATOR", "Add Work Order Generator");
}
if (item.AssignTos.length == 0) {
showAlert(GetTextByKey("P_AM_ASSIGNEDTOCANNOTBEEMPTY", 'Assigned to cannot be empty.'), alerttitle, undefined, function () {
showstatusmask(false);
});
return;
}
if (!item.StatusAssignment) {
showAlert(GetTextByKey("P_AM_STATUSASSIGNMENTCANNOTBEEMPTY", 'Status assignment cannot be empty.'), alerttitle, undefined, function () {
showstatusmask(false);
});
return;
}
if (item.EmailFrom !== "" && !isEmail(item.EmailFrom)) {
showAlert(GetTextByKey("P_AM_EMAILFROMISNOTAVALID", 'Email from is not a valid.'), alerttitle, undefined, function () {
showstatusmask(false);
});
return;
}
if (!item.DescType)
item.DescType = -1;
param = htmlencode(JSON.stringify(item));
alertrequest("SaveWorkOrderGenerator", param, function (data) {
if (typeof (data) === "string") {
showAlert(data, alerttitle, undefined, function () {
showstatusmask(false);
});
} else {
$('#dialog_wogenerator').hideDialog();
showstatusmask(false);
showmaskbg(false);
GetWorkOrderGenerators();
}
}, function (err) {
showAlert(GetTextByKey("P_AM_FAILEDTOSAVEWORKORDERGENERATOR", 'Failed to save work order generator.'), alerttitle);
});
}
function OnDeleteWOGenerator(c) {
if (!c) {
return;
}
var alerttitle = GetTextByKey("P_AM_DELETEWORKORDERGENERATOR", 'Delete Work Order Generator');
showConfirm(GetTextByKey("P_AM_DOYOUWANTTODELETETHISWORKORDERGENERATOR", 'Do you want to delete this work order generator?'), alerttitle, function () {
alertrequest('DeleteWorkOrderGenerator', c.Id, function (data) {
if (typeof (data) === "string") {
showAlert(data, alerttitle);
} else {
GetWorkOrderGenerators();
}
}, function (err) {
showAlert(GetTextByKey('P_AM_FAILEDTODELETEWORKORDERGENERATOR', 'Failed to delete this work order generator.'), alerttitle);
});
});
}
//******************************End Work Order Generator**********************************//
$(function () {
InitAutoAcknowledgeGridData();
InitWOGeneratorGridData();
$("#div_alerttype").css('width', 324).dropdown([], {
search: true,
multiselect: true,
allowselectall: true,
textKey: 'Value',
valueKey: 'Key'
});
$("#div_assetgroup").css('width', 324).dropdown([], {
search: true,
multiselect: true,
allowselectall: true,
textKey: 'Value',
valueKey: 'Key'
});
$("#div_jobsites").css('width', 324).dropdown([], {
search: true,
multiselect: true,
allowselectall: true,
textKey: 'Value',
valueKey: 'Key'
});
$("#div_assigntos").css('width', 324).dropdown([], {
search: true,
multiselect: true,
allowselectall: true,
textKey: 'Value',
valueKey: 'Key'
});
GetAlertTypes();
GetWorkOrderGenerators();
GetAssetGroups();
GetJobsites();
GetAssigntos();
GetWorkOrderStatuses();
$('#dialog_wogenerator').dialog(function () {
showmaskbg(false);
});
$('#div_container').tab();
$("#dialog_desctype").change(function () {
var desctype = $('#dialog_desctype').val();
if (parseInt(desctype) === 10) {
$('#tr_desc').show();
}
else {
$('#tr_desc').hide();
}
});
$(window).resize(function () {
$("#div_autoacknowledgelist").css("height", $(window).height() - $("#div_autoacknowledgelist").offset().top - 4);
autoacknowledge_dt && autoacknowledge_dt.resize();
$("#wogeneratorlist").css("height", $(window).height() - $("#wogeneratorlist").offset().top - 4);
wogeneratorgrid_dt && wogeneratorgrid_dt.resize();
}).resize();
});
function reshowgrid() {
setTimeout(function () {
$("#div_autoacknowledgelist").css("height", $(window).height() - $("#div_autoacknowledgelist").offset().top - 4);
autoacknowledge_dt && autoacknowledge_dt.resize();
$("#wogeneratorlist").css("height", $(window).height() - $("#wogeneratorlist").offset().top - 4);
wogeneratorgrid_dt && wogeneratorgrid_dt.resize();
});
}
</script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">
<div id="div_container">
<ul id="ul_container" class="tab_header">
<li id="li_autoacknowledge" data-href="tab_autoacknowledge" onclick="reshowgrid();" class="selected" data-lgid="P_AM_AUTOACKNOWLEDGE">Auto-Acknowledge</li>
<%if (AllowWorkOrderGenerator)
{ %>
<li data-href="tab_workordergenerator" onclick="reshowgrid();" data-lgid="P_AM_WORKORDERGENERATOR">Work Order Generator</li>
<%} %>
</ul>
<div id="tab_autoacknowledge" data-page="tab_autoacknowledge">
<div class="function_title">
<span class="sbutton iconsave" onclick="onSaveAutoAcknowledgeAlertTypes();" data-lgid="P_WO_SAVE">Save</span>
<span class="sbutton iconview" onclick="OnViewAutoAcknowledChangeHistory();" data-lgid="P_AM_VIEWCHANGEHIS">View Change History</span>
<span class="sbutton iconexit" onclick="OnExit(0);" data-lgid="P_WO_SAVE2">Exit Without Saving</span>
</div>
<div class="clear"></div>
<div id="div_autoacknowledgelist"></div>
</div>
<div id="tab_workordergenerator" data-page="tab_workordergenerator">
<div class="function_title">
<span class="sbutton iconadd" onclick="OnAddWOGenerator();" data-lgid="P_AM_ADDWORKORDERGENERATOR">Add Work Order Generator</span>
<span class="sbutton iconexit" onclick="OnExit(0);" data-lgid="P_WO_SAVE2">Exit Without Saving</span>
</div>
<div class="clear"></div>
<div id="wogeneratorlist">
</div>
</div>
</div>
<div id="mask_bg" style="display: none;">
<div class="loading_holder">
</div>
</div>
<div class="dialog" id="dialog_wogenerator" style="display: none;">
<div class="dialog-title"><span class="title" data-lgid="P_AM_ADDWORKORDERGENERATOR">Add Work Order Generator</span><em class="dialog-close"></em></div>
<div class="dialog-content">
<table style="line-height: 30px; table-layout: fixed; width: 500px;">
<tr>
<td class="label"><span data-lgid="P_AM_ALERTTYPE_COLON">Alert Type:</span></td>
<td>
<div id="div_alerttype"></div>
</td>
</tr>
<tr>
<td class="label"><span data-lgid="P_AM_ASSETGROUP_COLON">Asset Group:</span></td>
<td>
<div id="div_assetgroup"></div>
</td>
</tr>
<tr>
<td class="label"><span data-lgid="P_AM_JOBSITES_COLON">Jobsites:</span></td>
<td>
<div id="div_jobsites"></div>
</td>
</tr>
<tr>
<td class="label"><span data-lgid="P_WO_ASSIGNEDTO_COLON">Assign To:</span></td>
<td>
<div id="div_assigntos"></div>
</td>
</tr>
<tr>
<td class="label"><span data-lgid="P_AM_STATUSASSIGNMENT_COLON">Status Assignment:</span></td>
<td>
<select id="dialog_wostatus" tabindex="1" style="width: 322px; height: 24px;"></select>
</td>
</tr>
<tr>
<td class="label"><span data-lgid="P_AM_INCLUDEALLALERTS_COLON">Include All Alerts:</span></td>
<td>
<input type="checkbox" id="dialog_includeallalerts" style="width: auto;" tabindex="1" />
</td>
</tr>
<tr>
<td class="label"><span data-lgid="P_AM_EMAILWORKORDER_COLON">Email Work Order:</span></td>
<td>
<input type="checkbox" id="dialog_emailworkorder" style="width: auto;" tabindex="1" />
</td>
</tr>
<tr>
<td class="label"><span data-lgid="P_AM_EMAILFROM_COLON">Email From:</span></td>
<td>
<input type="text" id="dialog_emailfrom" maxlength="200" tabindex="1" style="height: 24px;" />
</td>
</tr>
<tr>
<td class="label"><span data-lgid="P_AM_DESCRIPTION_COLON">Description:</span></td>
<td>
<select id="dialog_desctype" tabindex="1" style="width: 324px; height: 24px;">
<option value="-1"></option>
<option value="0">Trigger Alerts</option>
<option value="1">All Alerts</option>
<option value="10">Other</option>
</select>
</td>
</tr>
<tr id="tr_desc" style="display: none;">
<td class="label"></td>
<td>
<textarea id="dialog_desc" maxlength="2000" tabindex="1" style="height: 80px;"></textarea>
</td>
</tr>
</table>
</div>
<div class="dialog-func">
<input type="button" value="Cancel" data-lgid="P_UM_CANCEL" class="dialog-close" tabindex="18" style="height: unset;" />
<input type="button" onclick="onSaveWorkOrderGenerator();" value="OK" data-lgid="P_UM_OK" tabindex="17" />
<div style="clear: both;"></div>
</div>
<div class="maskbg" id="statusmask" style="display: none;"></div>
</div>
</asp:Content>