added support for initializing from execution

This commit is contained in:
dcore94 2024-02-02 17:45:04 +01:00
parent a087e4904f
commit 4f3a892eeb
1 changed files with 8 additions and 4 deletions

View File

@ -16,14 +16,18 @@ class CCPExecutionForm extends HTMLElement{
this.connectNewExecutionRequest() this.connectNewExecutionRequest()
this.render()
const params = new URLSearchParams(window.location.search) const params = new URLSearchParams(window.location.search)
if(params.get('method')){ if(params.get('execution')){
const execution = { id : params.get('execution') }
this.prepareFromExecution(execution)
} else if(params.get('method')){
this.#method = params.get('method') this.#method = params.get('method')
this.loadMethod() this.loadMethod()
} else {
this.showMethod()
} }
this.render()
this.showMethod()
} }
static get observedAttributes() { static get observedAttributes() {