From 947fcd89cbf1637f90d54d37d83c6b8fd1783c25 Mon Sep 17 00:00:00 2001 From: dcore94 Date: Wed, 24 May 2023 14:49:40 +0200 Subject: [PATCH 1/4] added button for ccpannotation input --- ccp/js/methodeditorcontroller.js | 40 ++++++++++++++++++++++++++++++-- 1 file changed, 38 insertions(+), 2 deletions(-) diff --git a/ccp/js/methodeditorcontroller.js b/ccp/js/methodeditorcontroller.js index afd066a..6508459 100644 --- a/ccp/js/methodeditorcontroller.js +++ b/ccp/js/methodeditorcontroller.js @@ -142,6 +142,12 @@ class CCPMethodEditorController extends HTMLElement{ ` + + #annotation_input_icon = ` + + + + ` constructor(){ super(); @@ -443,6 +449,7 @@ class CCPMethodEditorController extends HTMLElement{ Inputs
+ ${this.renderStandardInputButtons()} ${this.renderPlusButton("add-input")}
@@ -653,6 +660,27 @@ class CCPMethodEditorController extends HTMLElement{ this.renderInputs() }) + this.#rootdoc.querySelector("button[name=add-ccpannotation]").addEventListener("click", ev=>{ + ev.preventDefault() + ev.stopPropagation() + this.#tmp_inputs.push( + { + id : "new_input", + title : "New input", + description : "A new input field", + minOccurs : 1, + maxOccurs : 1, + schema : { + type : "string", + format : null, + contentMediaType : "text/plain", + default : "" + } + } + ) + this.renderInputs() + }) + this.#rootdoc.querySelector("div[name=input-list]").addEventListener("click", ev=>{ const evname = ev.target.getAttribute('name') if(evname === "delete-input"){ @@ -840,12 +868,20 @@ class CCPMethodEditorController extends HTMLElement{ ` } + renderStandardInputButtons(){ + return ` + + ` + } + renderStandardOutputButtons(){ return ` - - ` From 043c151bb4884a0b6dcd589af402d3fcbe0073b7 Mon Sep 17 00:00:00 2001 From: dcore94 Date: Wed, 24 May 2023 14:56:56 +0200 Subject: [PATCH 2/4] added button for ccpannotation input --- ccp/js/methodeditorcontroller.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ccp/js/methodeditorcontroller.js b/ccp/js/methodeditorcontroller.js index 6508459..00aa386 100644 --- a/ccp/js/methodeditorcontroller.js +++ b/ccp/js/methodeditorcontroller.js @@ -665,9 +665,9 @@ class CCPMethodEditorController extends HTMLElement{ ev.stopPropagation() this.#tmp_inputs.push( { - id : "new_input", - title : "New input", - description : "A new input field", + id : "ccpannotation", + title : "Annotations for execution", + description : "The value of this parameter will be associated as annotation to the execution", minOccurs : 1, maxOccurs : 1, schema : { From e032eb3e102a60985a6525f7eb81f3670511d516 Mon Sep 17 00:00:00 2001 From: dcore94 Date: Wed, 24 May 2023 17:25:27 +0200 Subject: [PATCH 3/4] consider ccpnote --- ccp/js/executionhistorycontroller.js | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/ccp/js/executionhistorycontroller.js b/ccp/js/executionhistorycontroller.js index 01e6b12..c129cd2 100644 --- a/ccp/js/executionhistorycontroller.js +++ b/ccp/js/executionhistorycontroller.js @@ -62,7 +62,7 @@ class CCPExecutionHistory extends HTMLElement {
  • -
    +
    Z Y @@ -527,7 +527,11 @@ class CCPExecutionHistory extends HTMLElement { { target : "span[name=version]", apply : (e,d)=>{ - e.textContent = `${d.methodversion}` + if(d.ccpnote){ + e.textContent = `${d.ccpnote} (${d.methodversion})` + }else{ + e.textContent = `${d.methodversion}` + } } }, { From c86dc476da2f75cc5222b089ca417184a64b6528 Mon Sep 17 00:00:00 2001 From: dcore94 Date: Thu, 25 May 2023 09:10:12 +0200 Subject: [PATCH 4/4] correctly renamed ccpnote input --- ccp/js/methodeditorcontroller.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ccp/js/methodeditorcontroller.js b/ccp/js/methodeditorcontroller.js index 00aa386..a2970ef 100644 --- a/ccp/js/methodeditorcontroller.js +++ b/ccp/js/methodeditorcontroller.js @@ -665,7 +665,7 @@ class CCPMethodEditorController extends HTMLElement{ ev.stopPropagation() this.#tmp_inputs.push( { - id : "ccpannotation", + id : "ccpnote", title : "Annotations for execution", description : "The value of this parameter will be associated as annotation to the execution", minOccurs : 1,