Hi, is there a way to attach two different client ...
# suitescript
b
Hi, is there a way to attach two different client scripts to a suitelet?
For context, old one is attached using
form.clientScriptModulePath
n
You want to add modules or you want to add the versions of the client script that typically has the events in it (i.e. pageInit etc)?
b
@NElliott I want to add another module Btw, old module has those events like
fieldChanged
and a custom method.
n
If you have the events in more than one file you will want to merge them, I do not believe you can have more than one. If you want to add additional functions away from those you include them as modules in the define, note the last entry UI_LIB and how I include it.
Copy code
define(['N/record', 'N/runtime', 'N/search','N/currentRecord','N/ui/message','./3EN_ui_lib',],
/**
 * @param{record} record
 * @param{runtime} runtime
 * @param{search} search
 * @param{currentRecord} currentRecord
 * @param{uimessage} uimessage
 * @param{ui_lib} ui_lib
 */
function(record, runtime, search,currentRecord, uimessage, UI_LIB) {
b
that could work for my case too, thanks