27 views

Description

Catalog client script (onChange) is running twice on the SC Catalog Item widget

Steps to Reproduce

  1. Hop in to a Kingston instance.
  2. Find the sample item catalog item: 
    https://<instancename>.service-now.com/nav_to.do?uri=sc_cat_item.do?sys_id=1e01f08ac0a801070187b08d81c0845c
  3. Add a catalog client script: 
    Name: test alert
    UI type: all
    Type: onChange
    Variable name: single_text
    Script: 
    function onChange(control, oldValue, newValue, isLoading) {
       if (isLoading || newValue == '') {
          return;
       }
     
       //Type appropriate comment here, and begin script below
       if(newValue) {
       alert("Called-oldvalue:"+oldValue+";newvalue="+newValue);
       }
    }
  4. Open the SP page of this item: https://<instancename>.service-now.com/sp?id=sc_cat_item&sys_id=1e01f08ac0a801070187b08d81c0845c

Workaround

There is no known workaround for this issue. If you are able to upgrade, review the Fixed In field to determine the versions that have a permanent fix to this issue. You can subscribe to this known error article (click the Subscribe button at the top of the article) to receive notifications when more information is available about this issue.


Related Problem: PRB1247349

Seen In

Kingston

Intended Fix Version

London

Fixed In

Kingston Patch 3

Safe Harbor Statement

This "Intended Fix Version" information is meant to outline ServiceNow's general product direction and should not be relied upon in making a purchasing decision. The information provided here is for information purposes only and may not be incorporated into any contract. It is not a commitment, promise, or legal obligation to deliver any material, code, or functionality. The development, release, and timing of any features or functionality described for our products remains at ServiceNow's sole discretion.

Associated Community Threads

There is no data to report.

Article Information

Last Updated:2018-04-17 11:20:52
Published:2018-03-28