SCADA-LTS / Scada-LTS

Scada-LTS is an Open Source, web-based, multi-platform solution for building your own SCADA (Supervisory Control and Data Acquisition) system.
GNU General Public License v2.0
727 stars 292 forks source link

Fixed not recalculate Meta Data Point if Context is empty #2922

Closed Limraj closed 3 months ago

Limraj commented 3 months ago

Description If a Meta Data Point has an empty context, it should not be recalculated during initialization for Context Update and Change.

To Reproduce

  1. Login as admin;
  2. Created Meta Data Soruce as meta_1(enable) and two Meta Data Points:
    • dp_empty_change (settable, context: empty, enable, scirpt: "return 11;", Update event: Context change) ,
    • dp_empty_update (settable, context: empty, enable, script: "return 10;" Update event: Context update);
  3. Go to Watch Lists;
  4. Create Watch List as wl_1 with points:
    • meta_1 - dp_empty_change,
    • meta_1 - dp_empty_update;
  5. Set values:
    • meta_1 - dp_empty_change to 123;
    • meta_1 - dp_empty_update to 321;
  6. Restart tomcat;
  7. Login as admin;
  8. Go to Watch Lists and select wl_1 then values;
    • meta_1 - dp_empty_change is 11 -> error 1,
    • meta_1 - dp_empty_update is 10 -> error 2; The script was recalculated on initialization despite an empty context.

Spec: