0

When i want to create the onGet event code for a calculated attribute the proposed destination folder is "methods" where it should be "model" as described in the on-line documentation;

Strange enough, both files "<..>.events.js" and "<..>.methods.js" already exist under the model/<..> folders (where <..> stands for each datastore class in my model) but seem to be ignored by Wakanda Studio.

I did not find where i could change that destination.

Is it possible and where?

Tim Penner
  • 3,551
  • 21
  • 36
Richard
  • 31
  • 2

1 Answers1

0

<..>-events.js and <..>-methods.js are recognized by model only when they are included in model.js, which can be found next to model.

Do you see code like this in model.js?

include("./methods/<..>/<..>-events.js");
include("./methods/<..>/<..>-methods.js");
Xiang Liu
  • 393
  • 1
  • 7
  • No, i just see the following lines: // converted from guided model include("./Model/Moulin/Moulin-events.js"); include("./Model/Moulin/Moulin-methods.js"); include("./Model/Riviere/Riviere-events.js"); include("./Model/Riviere/Riviere-methods.js"); – Richard Mar 31 '16 at 09:29
  • but when i add event code i get the line "include("./methods/Moulin/Moulin-events.js");" in the Model.js file, and a folder "Moulin" is added under methods, with the file Moulin-events.js in it. I expected the attribute-related event code to be created in the existing js files (under Model/<..>) – Richard Mar 31 '16 at 09:37