Sha256: a0947e1e4207e92e91dca8372c4cea7f07ab279446f8fed0638eb30ed9d78d26

Contents?: true

Size: 979 Bytes

Versions: 12

Compression:

Stored size: 979 Bytes

Contents

({
  setActionModes(a) {
    this.actions.apply.setDisabled(!a["save"]);
    // style input field text based on whether it is editable
    this.getForm()
      .findField("body")
      .editor.setOption("readOnly", !a["save"]);
  },

  getScriptId() {
    return this.getForm()
      .findField("id")
      .getValue();
  },

  setLineError(idx) {
    idx -= 1;
    const editor = this.getForm().findField("body").editor;

    if (idx > -1) {
      const line = editor.getLine(idx);
      editor.markText(
        {
          line: idx,
          ch: 0
        },
        {
          line: idx,
          ch: line.length
        },
        {
          className: "errorline"
        }
      );
    }
    editor.refresh();
  },

  refreshParent(script_name) {
    this.netzkeGetParentComponent().scriptRefresh(script_name);
  },

  netzkeOnDoPrint(_params) {
    this.server.doPrint(this.getScriptId());
  },

  getReport(report_path) {
    window.location = report_path;
  }
});

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
marty-14.3.0 app/components/marty/script_form/client/script_form.js
marty-14.0.0 app/components/marty/script_form/client/script_form.js
marty-13.0.2 app/components/marty/script_form/client/script_form.js
marty-11.0.0 app/components/marty/script_form/client/script_form.js
marty-10.0.3 app/components/marty/script_form/client/script_form.js
marty-10.0.2 app/components/marty/script_form/client/script_form.js
marty-10.0.0 app/components/marty/script_form/client/script_form.js
marty-9.5.1 app/components/marty/script_form/client/script_form.js
marty-9.5.0 app/components/marty/script_form/client/script_form.js
marty-9.3.3 app/components/marty/script_form/client/script_form.js
marty-9.3.2 app/components/marty/script_form/client/script_form.js
marty-9.3.0 app/components/marty/script_form/client/script_form.js