- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-15-2016 10:50 AM
- I am getting some strange behavior and I am out of ideas. I have a record producer with a ui page that has a button which opens a custom form to submit a related record type. After this ui_page popup is closed I would expect to be back on the original record producer.
Record Producer URL:
I am rendering the UI page in a standard GlideDialogWindow on button click:
function openPopup(){
var gDialog = new GlideDialogWindow("x_snc_vms_new_guest_popup");
gDialog.setTitle("New Guest");
gDialog.setSize(500,500);
gDialog.render();
}
After submit the new record is created with a GlideAjax call then the UI page runs out of code, it does not matter whether I use GlideDialogWindow.get().destroy(); or not, I get a very brief flash of the record I should end up on then get redirected to the following url which displays Not authorized.
Any help or thoughts on what to check would be appreciated.
Note: This is in a scoped app if it makes a difference.
Edit: It looks like I am getting the following two evaluater errors after submitting the ui_page:
org.mozilla.javascript.EcmaError: Cannot convert null to an object. Caused by error in Phase 2 Jelly: ftp://gsft_database_form/sys_ui_page.770cc7830a0a0b08005abd85abf0b547.html.2 at line -1 |
org.mozilla.javascript.EcmaError: Cannot convert null to an object. Caused by error in Phase 2 Jelly: ftp://gsft_database_form/sys_ui_page.770cc7830a0a0b08005abd85abf0b547.html.2 at line 2 1: var item = GlideappCatalogItem.get(jelly.sysparm_id); ==> 2: var cat = item.getFirstAccessibleCategoryForSearch(); 3: var sysparm_catalog = GlideappCategory.get(cat).getCatalog(); 4: sysparm_catalog; |
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-15-2016 11:15 AM
If the error message is coming from an OOTB version, then it sounds like a call to customer support is in order.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-16-2016 07:02 AM
I was pressed for time and found a work around by using the OOB jelly dialog_buttons_ok_cancel ui macro for the submit instead of the bootstrap buttons.
Thanks for the help.
<form class="form-horizontal">
<div class="form-group">
<label for="email" class="col-sm-3 control-label">* Email</label>
<div class="col-sm-9">
<input type="email" class="form-control" id="email" placeholder="Email Address"></input>
</div>
</div>
<div class="form-group">
<label for="phone" class="col-sm-3 control-label">Phone</label>
<div class="col-sm-9">
<input type="tel" class="form-control" id="phone" placeholder="Phone Number"></input>
</div>
</div>
<!-- <div class="btn-group pull-right">
<button type="cancel" class="btn btn-default">Cancel</button>
<button type="done" class="btn btn-primary" onclick="return validateForm();">Done</button>
</div> -->
<div class='pull-right'>
<j:jelly trim="false" xmlns:j="jelly:core" xmlns:g="glide" xmlns:j2="null" xmlns:g2="null">
<g:dialog_buttons_ok_cancel ok="return continueOK()" cancel="return continueCancel()" ok_type="button" cancel_type="button"/>
</j:jelly>
</div>
</form>