text = {||'<A HREF="/ibapps/index.htm">[Home]</A> <A HREF="/svr/intrasrv.isv?apps/phone/phoneemp.jrp">[List by Employee]</A> <A HREF="/svr/intrasrv.isv?apps/phone/phonedep.jrp">[List by Department]</A>'};
pageno = 0;
}
with (this.GeneratedHTML1 = new GeneratedHTML(this)){
height = 1;
top = 23;
width = 70;
pageno = 0;
}
this.rowset = this.employee1.rowset;
function Form_onServerLoad()
{
var form = this;
form.updateDeptList = false;
// check for error conditions
var error = new Exception();
error.code = 0;
try {
// move to the requested record
if (form.argv.length == 1) {
if (!form.rowset.applyLocate('"Employee ID"=' + form.argv[0])){
error.message = "Invalid Employee ID - " + form.argv[0];
throw error;
}
}
if (form.security.hasAccessTo("Phone Update")) {
form.navImage.visible = true;
form.editImage.visible = true;
form.deptButton.visible = true;
form.saveButton.visible = false;
form.securityIDText.visible = true;
form.securityIDHTML.visible = false;
}
else {
var name = form.security.getUserName();
if (form.rowset.applyLocate('"Security ID"=' + "'" + escapeChar(name,"'") + "'")){
form.navImage.visible = false;
form.editImage.visible = false;
form.deptButton.visible = false;
form.saveButton.visible = true;
form.securityIDText.visible = false;
form.securityIDHTML.visible = true;
}
else {
error.message = "Insufficient rights to update data";