ExploreConsulting / netsuite-fasttrack-toolkit-ss2

NFT for SuiteScript 2.X
74 stars 20 forks source link

add common fields for Custom Records #31

Closed ShawnTalbert closed 2 years ago

ShawnTalbert commented 4 years ago

Either generate fields such as isinactive and name for all Custom Records (codegen) or provide a base class that declares them.

steveklett commented 2 years ago

I plan to work on this, is anyone else already working on it?

ShawnTalbert commented 2 years ago

Not that I know of. I personally like the idea of augmenting the codegen utility to include these fields rather than introducing another layer to the inheritance hierarchy, if possible.

steveklett commented 2 years ago

@ShawnTalbert - tagging you because I'm unable to do a pull request for this new work.

This is done and committed, Extended CustomRecord.xsl to:

  1. support common fields
  2. Insert an underscore for the class name if the record name starts with a number (e.g., Record named "#PL Config" would generate class name "_3PLConfig", however the filename will remain unchanged
  3. Added Record name and description to class definition header comment
  4. Removed a couple superfluous bits and pieces

Note: I may have "git'ed" incorretly: I had an existing pull request on my "geo2" branch. I then did this NFT NSDAL work on the same branch (oops!) and now I can't create a new pull request. It seems pull requests are branch-based rather than commit based. I think if you accept my other pull request you'll get this NFT NSDAL work as well.

ShawnTalbert commented 2 years ago

Thanks Steve!