title: Netsuite User Event Script: Not all user event types firing
body: <p>We have a user event script attached to a sales order in NetSuite, however we are noticing that only the <strong>context.UserEventType.CREATE</strong> is being called. <strong>EDIT</strong>, <strong>COPY</strong> and the others DO NOT catch the sales order manipulations as per spec. Can anyone please verify this. Ive attached a very simple UserEvent script that should throw the context type but it is not working.</p>
  
  <p>This UserEvent script is for a salesorder record:</p>
  
  <pre><code>/**
   *@NApiVersion 2.x
   *@NScriptType UserEventScript
   */
  define(["N/record", "N/search"],
      function (record, search) {
  
          function beforeSubmit(context) {
              throw "beforeSubmit:" + context.type;
          }
  
          function afterSubmit(context) {
              throw "afterSubmit:" + context.type;
          }
  
          function beforeLoad(context) {
              throw "beforeLoad:" + context.type;
          }
  
          return {
              beforeLoad: beforeLoad,
              beforeSubmit: beforeSubmit,
              afterSubmit: afterSubmit
          };
  
      });
  </code></pre>