From 13d7da0c07706cffc025c4bee5949b5656e5c0a1 Mon Sep 17 00:00:00 2001 From: rpm-mcarman <65228808+rpm-mcarman@users.noreply.github.com> Date: Mon, 18 Mar 2024 11:27:50 -0400 Subject: [PATCH] 3/18/2024 --- app/api/PartCodes/cmasters.json | 202 +++ app/api/PartCodes/masters.json | 586 ++++++++ app/api/PartCodes/parent.json | 164 +++ app/api/Parts/asynccalls/create_part.json | 1504 +++++++++++++++++++++ app/api/Parts/newpart.json | 27 +- app/api/Users/addtorole.json | 425 ++++++ app/api/Users/create.json | 22 +- app/api/Users/insert.json | 67 + app/api/roles/cnfrm_addroles.json | 555 ++++++++ app/api/security/confirm.json | 325 +---- app/api/security/defalutadminapi.json | 303 +++-- app/api/security/isauthenticated.json | 90 +- app/api/security/whoami.json | 276 +++- data/authdb.sqlite3 | Bin 28672 -> 28672 bytes public/css/style.css | 71 + public/dmxAppConnect/config.js | 366 +++++ views/cnfrm.ejs | 35 +- views/layouts/smain.ejs | 81 +- views/secure/dspec.ejs | 10 +- views/secure/dspecmotor.ejs | 2 +- views/secure/partinfo.ejs | 13 +- views/wadmin/usermanage.ejs | 2 +- 22 files changed, 4600 insertions(+), 526 deletions(-) create mode 100644 app/api/PartCodes/cmasters.json create mode 100644 app/api/PartCodes/masters.json create mode 100644 app/api/PartCodes/parent.json create mode 100644 app/api/Parts/asynccalls/create_part.json create mode 100644 app/api/Users/addtorole.json create mode 100644 app/api/Users/insert.json create mode 100644 app/api/roles/cnfrm_addroles.json diff --git a/app/api/PartCodes/cmasters.json b/app/api/PartCodes/cmasters.json new file mode 100644 index 0000000..55179ab --- /dev/null +++ b/app/api/PartCodes/cmasters.json @@ -0,0 +1,202 @@ +{ + "meta": { + "$_GET": [ + { + "type": "text", + "name": "code" + } + ] + }, + "exec": { + "steps": { + "name": "api", + "module": "api", + "action": "send", + "options": { + "url": "{{$_ENV.API_BASEURL+'partcodes/cmasters/'+$_GET.code}}", + "schema": [ + { + "type": "array", + "name": "data", + "sub": [ + { + "type": "number", + "name": "id" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "number", + "name": "createuserid" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "object", + "name": "parent", + "sub": [ + { + "type": "number", + "name": "id" + } + ] + }, + { + "type": "object", + "name": "parttype", + "sub": [ + { + "type": "number", + "name": "id" + } + ] + }, + { + "type": "text", + "name": "code" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "boolean", + "name": "isactive" + }, + { + "type": "boolean", + "name": "ispartcode" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "name" + } + ] + }, + { + "type": "object", + "name": "headers", + "sub": [ + { + "type": "text", + "name": "connection" + }, + { + "type": "text", + "name": "content-length" + }, + { + "type": "text", + "name": "content-type" + }, + { + "type": "text", + "name": "date" + } + ] + } + ] + }, + "output": true, + "meta": [ + { + "type": "array", + "name": "data", + "sub": [ + { + "type": "number", + "name": "id" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "number", + "name": "createuserid" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "object", + "name": "parent", + "sub": [ + { + "type": "number", + "name": "id" + } + ] + }, + { + "type": "object", + "name": "parttype", + "sub": [ + { + "type": "number", + "name": "id" + } + ] + }, + { + "type": "text", + "name": "code" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "boolean", + "name": "isactive" + }, + { + "type": "boolean", + "name": "ispartcode" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "name" + } + ] + }, + { + "type": "object", + "name": "headers", + "sub": [ + { + "type": "text", + "name": "connection" + }, + { + "type": "text", + "name": "content-length" + }, + { + "type": "text", + "name": "content-type" + }, + { + "type": "text", + "name": "date" + } + ] + } + ], + "outputType": "object" + } + } +} \ No newline at end of file diff --git a/app/api/PartCodes/masters.json b/app/api/PartCodes/masters.json new file mode 100644 index 0000000..0cad8ef --- /dev/null +++ b/app/api/PartCodes/masters.json @@ -0,0 +1,586 @@ +[ + { + "name": "list", + "module": "api", + "action": "send", + "options": { + "url": "http://localhost:8080/api/v1.0/partcodes/masters", + "schema": [ + { + "type": "array", + "name": "data", + "sub": [ + { + "type": "number", + "name": "id" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "number", + "name": "createuserid" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "object", + "name": "parent", + "sub": [ + { + "type": "text", + "name": "id" + } + ] + }, + { + "type": "object", + "name": "parttype", + "sub": [ + { + "type": "number", + "name": "id" + } + ] + }, + { + "type": "boolean", + "name": "ispartcode" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "boolean", + "name": "isactive" + }, + { + "type": "text", + "name": "code" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "name" + } + ] + }, + { + "type": "object", + "name": "headers", + "sub": [ + { + "type": "text", + "name": "connection" + }, + { + "type": "text", + "name": "content-length" + }, + { + "type": "text", + "name": "content-type" + }, + { + "type": "text", + "name": "date" + } + ] + } + ] + }, + "output": true, + "meta": [ + { + "type": "array", + "name": "data", + "sub": [ + { + "type": "number", + "name": "id" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "number", + "name": "createuserid" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "object", + "name": "parent", + "sub": [ + { + "type": "text", + "name": "id" + } + ] + }, + { + "type": "object", + "name": "parttype", + "sub": [ + { + "type": "number", + "name": "id" + } + ] + }, + { + "type": "boolean", + "name": "ispartcode" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "boolean", + "name": "isactive" + }, + { + "type": "text", + "name": "code" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "name" + } + ] + }, + { + "type": "object", + "name": "headers", + "sub": [ + { + "type": "text", + "name": "connection" + }, + { + "type": "text", + "name": "content-length" + }, + { + "type": "text", + "name": "content-type" + }, + { + "type": "text", + "name": "date" + } + ] + } + ], + "outputType": "object" + }, + { + "name": "allpartcodes", + "module": "api", + "action": "send", + "options": { + "url": "{{$_ENV.API_BASEURL+'partcodes/ispartcode'}}", + "schema": [ + { + "type": "array", + "name": "data", + "sub": [ + { + "type": "number", + "name": "id" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "number", + "name": "createuserid" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "object", + "name": "parent", + "sub": [ + { + "type": "text", + "name": "id" + } + ] + }, + { + "type": "object", + "name": "parttype", + "sub": [ + { + "type": "text", + "name": "updatedate" + }, + { + "type": "number", + "name": "ending" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "number", + "name": "starting" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "text", + "name": "name" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "boolean", + "name": "ispartcode" + }, + { + "type": "text", + "name": "code" + }, + { + "type": "boolean", + "name": "isactive" + }, + { + "type": "array", + "name": "children", + "sub": [ + { + "type": "number", + "name": "id" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "number", + "name": "createuserid" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "object", + "name": "parent", + "sub": [ + { + "type": "number", + "name": "id" + } + ] + }, + { + "type": "object", + "name": "parttype", + "sub": [ + { + "type": "number", + "name": "id" + } + ] + }, + { + "type": "boolean", + "name": "ispartcode" + }, + { + "type": "text", + "name": "code" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "array", + "name": "children" + }, + { + "type": "boolean", + "name": "isactive" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "name" + } + ] + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "name" + } + ] + }, + { + "type": "object", + "name": "headers", + "sub": [ + { + "type": "text", + "name": "connection" + }, + { + "type": "text", + "name": "content-length" + }, + { + "type": "text", + "name": "content-type" + }, + { + "type": "text", + "name": "date" + } + ] + } + ] + }, + "output": true, + "meta": [ + { + "type": "array", + "name": "data", + "sub": [ + { + "type": "number", + "name": "id" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "number", + "name": "createuserid" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "object", + "name": "parent", + "sub": [ + { + "type": "text", + "name": "id" + } + ] + }, + { + "type": "object", + "name": "parttype", + "sub": [ + { + "type": "text", + "name": "updatedate" + }, + { + "type": "number", + "name": "ending" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "number", + "name": "starting" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "text", + "name": "name" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "boolean", + "name": "ispartcode" + }, + { + "type": "text", + "name": "code" + }, + { + "type": "boolean", + "name": "isactive" + }, + { + "type": "array", + "name": "children", + "sub": [ + { + "type": "number", + "name": "id" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "number", + "name": "createuserid" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "object", + "name": "parent", + "sub": [ + { + "type": "number", + "name": "id" + } + ] + }, + { + "type": "object", + "name": "parttype", + "sub": [ + { + "type": "number", + "name": "id" + } + ] + }, + { + "type": "boolean", + "name": "ispartcode" + }, + { + "type": "text", + "name": "code" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "array", + "name": "children" + }, + { + "type": "boolean", + "name": "isactive" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "name" + } + ] + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "name" + } + ] + }, + { + "type": "object", + "name": "headers", + "sub": [ + { + "type": "text", + "name": "connection" + }, + { + "type": "text", + "name": "content-length" + }, + { + "type": "text", + "name": "content-type" + }, + { + "type": "text", + "name": "date" + } + ] + } + ], + "outputType": "object" + } +] \ No newline at end of file diff --git a/app/api/PartCodes/parent.json b/app/api/PartCodes/parent.json new file mode 100644 index 0000000..92dca29 --- /dev/null +++ b/app/api/PartCodes/parent.json @@ -0,0 +1,164 @@ +{ + "meta": { + "$_GET": [ + { + "type": "number", + "name": "id" + } + ] + }, + "exec": { + "steps": [ + { + "name": "api", + "module": "api", + "action": "send", + "options": { + "url": "{{$_ENV.API_BASEURL+'/partcodes/parent/'+$_GET.id}}", + "schema": [ + { + "type": "text", + "name": "data" + }, + { + "type": "object", + "name": "headers", + "sub": [ + { + "type": "text", + "name": "connection" + }, + { + "type": "text", + "name": "content-length" + }, + { + "type": "text", + "name": "content-type" + }, + { + "type": "text", + "name": "date" + } + ] + } + ] + }, + "output": true, + "meta": [ + { + "type": "text", + "name": "data" + }, + { + "type": "object", + "name": "headers", + "sub": [ + { + "type": "text", + "name": "connection" + }, + { + "type": "text", + "name": "content-length" + }, + { + "type": "text", + "name": "content-type" + }, + { + "type": "text", + "name": "date" + } + ] + } + ], + "outputType": "object" + }, + { + "name": "", + "module": "core", + "action": "condition", + "options": { + "if": "{{api.data==0}}", + "then": { + "steps": { + "name": "view", + "module": "core", + "action": "setvalue", + "options": { + "key": "g_view", + "value": "change" + }, + "meta": [], + "output": true, + "outputType": "text" + } + }, + "else": { + "steps": { + "name": "", + "module": "core", + "action": "condition", + "options": { + "if": "{{api.data==2}}", + "then": { + "steps": { + "name": "view", + "module": "core", + "action": "setvalue", + "options": { + "value": "dspecm" + }, + "meta": [], + "output": true, + "outputType": "text" + } + }, + "else": { + "steps": { + "name": "", + "module": "core", + "action": "condition", + "options": { + "if": "{{api.data==3}}", + "then": { + "steps": { + "name": "view", + "module": "core", + "action": "setvalue", + "options": { + "value": "dspec" + }, + "meta": [], + "output": true, + "outputType": "text" + } + }, + "else": { + "steps": { + "name": "view", + "module": "core", + "action": "setvalue", + "options": { + "value": "dspecg" + }, + "meta": [], + "output": true, + "outputType": "text" + } + } + }, + "outputType": "boolean" + } + } + }, + "outputType": "boolean" + } + } + }, + "outputType": "boolean" + } + ] + } +} \ No newline at end of file diff --git a/app/api/Parts/asynccalls/create_part.json b/app/api/Parts/asynccalls/create_part.json new file mode 100644 index 0000000..cfb0f7f --- /dev/null +++ b/app/api/Parts/asynccalls/create_part.json @@ -0,0 +1,1504 @@ +{ + "meta": { + "$_GET": [ + { + "type": "text", + "name": "partcodeid" + }, + { + "type": "text", + "name": "code" + }, + { + "type": "text", + "name": "creator" + } + ] + }, + "exec": { + "steps": [ + { + "name": "gen_partnumber", + "module": "api", + "action": "send", + "options": { + "url": "{{$_ENV.API_BASEURL+'pns/max'}}", + "schema": [ + { + "type": "object", + "name": "data", + "sub": [ + { + "type": "text", + "name": "id" + }, + { + "type": "number", + "name": "number" + } + ] + }, + { + "type": "object", + "name": "headers", + "sub": [ + { + "type": "text", + "name": "connection" + }, + { + "type": "text", + "name": "content-length" + }, + { + "type": "text", + "name": "content-type" + }, + { + "type": "text", + "name": "date" + } + ] + } + ] + }, + "output": true, + "meta": [ + { + "type": "object", + "name": "data", + "sub": [ + { + "type": "text", + "name": "id" + }, + { + "type": "number", + "name": "number" + } + ] + }, + { + "type": "object", + "name": "headers", + "sub": [ + { + "type": "text", + "name": "connection" + }, + { + "type": "text", + "name": "content-length" + }, + { + "type": "text", + "name": "content-type" + }, + { + "type": "text", + "name": "date" + } + ] + } + ], + "outputType": "object" + }, + { + "name": "partnumber", + "module": "core", + "action": "setvalue", + "options": { + "key": "g_partnumber", + "value": "{{$_GET.code.replace('-', '')+'-'+gen_partnumber.data.number}}" + }, + "meta": [], + "outputType": "text" + }, + { + "name": "increatepn", + "module": "api", + "action": "send", + "options": { + "url": "{{$_ENV.API_BASEURL+'pns/ainsert'}}", + "dataType": "json", + "data": { + "id": null, + "number": "{{gen_partnumber.data.number}}" + }, + "schema": [ + { + "type": "array", + "name": "data", + "sub": [ + { + "type": "number", + "name": "id" + }, + { + "type": "number", + "name": "number" + } + ] + }, + { + "type": "object", + "name": "headers", + "sub": [ + { + "type": "text", + "name": "connection" + }, + { + "type": "text", + "name": "content-length" + }, + { + "type": "text", + "name": "content-type" + }, + { + "type": "text", + "name": "date" + } + ] + } + ], + "method": "POST" + }, + "output": true, + "meta": [ + { + "type": "array", + "name": "data", + "sub": [ + { + "type": "number", + "name": "id" + }, + { + "type": "number", + "name": "number" + } + ] + }, + { + "type": "object", + "name": "headers", + "sub": [ + { + "type": "text", + "name": "connection" + }, + { + "type": "text", + "name": "content-length" + }, + { + "type": "text", + "name": "content-type" + }, + { + "type": "text", + "name": "date" + } + ] + } + ], + "outputType": "object" + }, + { + "name": "createpartnumber", + "module": "api", + "action": "send", + "options": { + "url": "http://localhost:8080/api/v1.0/partnumbers/async", + "dataType": "json", + "schema": [ + { + "type": "object", + "name": "data", + "sub": [ + { + "type": "object", + "name": "packinglocation", + "sub": [ + { + "type": "text", + "name": "updatedate" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "text", + "name": "name" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "text", + "name": "weight" + }, + { + "type": "object", + "name": "status", + "sub": [ + { + "type": "text", + "name": "createuserid" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "text", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "text", + "name": "name" + } + ] + }, + { + "type": "number", + "name": "createuserid" + }, + { + "type": "text", + "name": "file" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "secondaryvendorpartnumber" + }, + { + "type": "text", + "name": "primarycustomerpartnumber" + }, + { + "type": "object", + "name": "secondaryvendor", + "sub": [ + { + "type": "text", + "name": "id" + } + ] + }, + { + "type": "object", + "name": "replaces", + "sub": [ + { + "type": "text", + "name": "id" + } + ] + }, + { + "type": "object", + "name": "replacedby", + "sub": [ + { + "type": "text", + "name": "id" + } + ] + }, + { + "type": "object", + "name": "partcode", + "sub": [ + { + "type": "number", + "name": "id" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "number", + "name": "createuserid" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "object", + "name": "parent", + "sub": [ + { + "type": "number", + "name": "id" + } + ] + }, + { + "type": "object", + "name": "parttype", + "sub": [ + { + "type": "number", + "name": "ending" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "number", + "name": "starting" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "text", + "name": "name" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "text", + "name": "code" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "boolean", + "name": "isactive" + }, + { + "type": "boolean", + "name": "ispartcode" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "name" + } + ] + }, + { + "type": "number", + "name": "listprice" + }, + { + "type": "number", + "name": "stdcost" + }, + { + "type": "text", + "name": "number" + }, + { + "type": "text", + "name": "ppap" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "array", + "name": "designspecs", + "sub": [ + { + "type": "text", + "name": "metaltag" + }, + { + "type": "text", + "name": "remarks" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "boolean", + "name": "facrequired" + }, + { + "type": "text", + "name": "weight" + }, + { + "type": "text", + "name": "swtch" + }, + { + "type": "text", + "name": "terminalposition" + }, + { + "type": "text", + "name": "treatment" + }, + { + "type": "text", + "name": "note" + }, + { + "type": "text", + "name": "voltage" + }, + { + "type": "boolean", + "name": "faccompleted" + }, + { + "type": "object", + "name": "status", + "sub": [ + { + "type": "number", + "name": "id" + } + ] + }, + { + "type": "text", + "name": "signed" + }, + { + "type": "text", + "name": "plrv" + }, + { + "type": "text", + "name": "except" + }, + { + "type": "text", + "name": "approveuserid" + }, + { + "type": "text", + "name": "makefrom" + }, + { + "type": "text", + "name": "pinion" + }, + { + "type": "text", + "name": "signedDate" + }, + { + "type": "text", + "name": "box" + }, + { + "type": "text", + "name": "ho" + }, + { + "type": "text", + "name": "gasket" + }, + { + "type": "text", + "name": "bracket" + }, + { + "type": "text", + "name": "suctionfitting" + }, + { + "type": "text", + "name": "rotation" + }, + { + "type": "object", + "name": "partnumber", + "sub": [ + { + "type": "number", + "name": "id" + } + ] + }, + { + "type": "text", + "name": "oereman" + }, + { + "type": "text", + "name": "tagnumber" + }, + { + "type": "text", + "name": "pressureport" + }, + { + "type": "text", + "name": "reasonforchange" + }, + { + "type": "text", + "name": "checked" + }, + { + "type": "text", + "name": "revisionlevel" + }, + { + "type": "text", + "name": "switchposition" + }, + { + "type": "text", + "name": "suctionport" + }, + { + "type": "text", + "name": "rtv" + }, + { + "type": "text", + "name": "validation" + }, + { + "type": "text", + "name": "approvedate" + }, + { + "type": "text", + "name": "floatstock" + }, + { + "type": "text", + "name": "workinstruction" + }, + { + "type": "text", + "name": "frequency" + }, + { + "type": "text", + "name": "papertag" + }, + { + "type": "text", + "name": "drive" + }, + { + "type": "boolean", + "name": "customernotification" + }, + { + "type": "text", + "name": "curve" + }, + { + "type": "text", + "name": "servicereplacementref" + }, + { + "type": "text", + "name": "built" + }, + { + "type": "text", + "name": "ftf" + }, + { + "type": "text", + "name": "opening" + }, + { + "type": "text", + "name": "jsp" + }, + { + "type": "text", + "name": "application" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "text", + "name": "pitch" + }, + { + "type": "text", + "name": "createuserid" + }, + { + "type": "text", + "name": "mtgh" + }, + { + "type": "text", + "name": "sae" + }, + { + "type": "array", + "name": "boms" + }, + { + "type": "text", + "name": "othertag" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "effectivedate" + }, + { + "type": "text", + "name": "checkedDate" + }, + { + "type": "text", + "name": "updateuserid" + }, + { + "type": "text", + "name": "additionalparts" + }, + { + "type": "text", + "name": "basicclass" + }, + { + "type": "text", + "name": "pressurefitting" + } + ] + }, + { + "type": "object", + "name": "primaryvendor", + "sub": [ + { + "type": "text", + "name": "id" + } + ] + }, + { + "type": "text", + "name": "comments" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "object", + "name": "primarycustomer", + "sub": [ + { + "type": "text", + "name": "updatedate" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "text", + "name": "name" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "object", + "name": "pickinglocation", + "sub": [ + { + "type": "text", + "name": "updatedate" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "text", + "name": "name" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "text", + "name": "primaryvendorpartnumber" + }, + { + "type": "text", + "name": "description" + } + ] + }, + { + "type": "object", + "name": "headers", + "sub": [ + { + "type": "text", + "name": "connection" + }, + { + "type": "text", + "name": "content-length" + }, + { + "type": "text", + "name": "content-type" + }, + { + "type": "text", + "name": "date" + } + ] + } + ], + "data": { + "number": "{{partnumber}}", + "partcodeid": "{{$_GET.partcodeid}}", + "statusid": "4" + }, + "method": "POST" + }, + "output": true, + "meta": [ + { + "type": "object", + "name": "data", + "sub": [ + { + "type": "object", + "name": "packinglocation", + "sub": [ + { + "type": "text", + "name": "updatedate" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "text", + "name": "name" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "text", + "name": "weight" + }, + { + "type": "object", + "name": "status", + "sub": [ + { + "type": "text", + "name": "createuserid" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "text", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "text", + "name": "name" + } + ] + }, + { + "type": "number", + "name": "createuserid" + }, + { + "type": "text", + "name": "file" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "secondaryvendorpartnumber" + }, + { + "type": "text", + "name": "primarycustomerpartnumber" + }, + { + "type": "object", + "name": "secondaryvendor", + "sub": [ + { + "type": "text", + "name": "id" + } + ] + }, + { + "type": "object", + "name": "replaces", + "sub": [ + { + "type": "text", + "name": "id" + } + ] + }, + { + "type": "object", + "name": "replacedby", + "sub": [ + { + "type": "text", + "name": "id" + } + ] + }, + { + "type": "object", + "name": "partcode", + "sub": [ + { + "type": "number", + "name": "id" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "number", + "name": "createuserid" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "object", + "name": "parent", + "sub": [ + { + "type": "number", + "name": "id" + } + ] + }, + { + "type": "object", + "name": "parttype", + "sub": [ + { + "type": "number", + "name": "ending" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "number", + "name": "starting" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "text", + "name": "name" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "text", + "name": "code" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "boolean", + "name": "isactive" + }, + { + "type": "boolean", + "name": "ispartcode" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "name" + } + ] + }, + { + "type": "number", + "name": "listprice" + }, + { + "type": "number", + "name": "stdcost" + }, + { + "type": "text", + "name": "number" + }, + { + "type": "text", + "name": "ppap" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "array", + "name": "designspecs", + "sub": [ + { + "type": "text", + "name": "metaltag" + }, + { + "type": "text", + "name": "remarks" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "boolean", + "name": "facrequired" + }, + { + "type": "text", + "name": "weight" + }, + { + "type": "text", + "name": "swtch" + }, + { + "type": "text", + "name": "terminalposition" + }, + { + "type": "text", + "name": "treatment" + }, + { + "type": "text", + "name": "note" + }, + { + "type": "text", + "name": "voltage" + }, + { + "type": "boolean", + "name": "faccompleted" + }, + { + "type": "object", + "name": "status", + "sub": [ + { + "type": "number", + "name": "id" + } + ] + }, + { + "type": "text", + "name": "signed" + }, + { + "type": "text", + "name": "plrv" + }, + { + "type": "text", + "name": "except" + }, + { + "type": "text", + "name": "approveuserid" + }, + { + "type": "text", + "name": "makefrom" + }, + { + "type": "text", + "name": "pinion" + }, + { + "type": "text", + "name": "signedDate" + }, + { + "type": "text", + "name": "box" + }, + { + "type": "text", + "name": "ho" + }, + { + "type": "text", + "name": "gasket" + }, + { + "type": "text", + "name": "bracket" + }, + { + "type": "text", + "name": "suctionfitting" + }, + { + "type": "text", + "name": "rotation" + }, + { + "type": "object", + "name": "partnumber", + "sub": [ + { + "type": "number", + "name": "id" + } + ] + }, + { + "type": "text", + "name": "oereman" + }, + { + "type": "text", + "name": "tagnumber" + }, + { + "type": "text", + "name": "pressureport" + }, + { + "type": "text", + "name": "reasonforchange" + }, + { + "type": "text", + "name": "checked" + }, + { + "type": "text", + "name": "revisionlevel" + }, + { + "type": "text", + "name": "switchposition" + }, + { + "type": "text", + "name": "suctionport" + }, + { + "type": "text", + "name": "rtv" + }, + { + "type": "text", + "name": "validation" + }, + { + "type": "text", + "name": "approvedate" + }, + { + "type": "text", + "name": "floatstock" + }, + { + "type": "text", + "name": "workinstruction" + }, + { + "type": "text", + "name": "frequency" + }, + { + "type": "text", + "name": "papertag" + }, + { + "type": "text", + "name": "drive" + }, + { + "type": "boolean", + "name": "customernotification" + }, + { + "type": "text", + "name": "curve" + }, + { + "type": "text", + "name": "servicereplacementref" + }, + { + "type": "text", + "name": "built" + }, + { + "type": "text", + "name": "ftf" + }, + { + "type": "text", + "name": "opening" + }, + { + "type": "text", + "name": "jsp" + }, + { + "type": "text", + "name": "application" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "text", + "name": "pitch" + }, + { + "type": "text", + "name": "createuserid" + }, + { + "type": "text", + "name": "mtgh" + }, + { + "type": "text", + "name": "sae" + }, + { + "type": "array", + "name": "boms" + }, + { + "type": "text", + "name": "othertag" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "effectivedate" + }, + { + "type": "text", + "name": "checkedDate" + }, + { + "type": "text", + "name": "updateuserid" + }, + { + "type": "text", + "name": "additionalparts" + }, + { + "type": "text", + "name": "basicclass" + }, + { + "type": "text", + "name": "pressurefitting" + } + ] + }, + { + "type": "object", + "name": "primaryvendor", + "sub": [ + { + "type": "text", + "name": "id" + } + ] + }, + { + "type": "text", + "name": "comments" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "object", + "name": "primarycustomer", + "sub": [ + { + "type": "text", + "name": "updatedate" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "text", + "name": "name" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "object", + "name": "pickinglocation", + "sub": [ + { + "type": "text", + "name": "updatedate" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "text", + "name": "name" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "text", + "name": "primaryvendorpartnumber" + }, + { + "type": "text", + "name": "description" + } + ] + }, + { + "type": "object", + "name": "headers", + "sub": [ + { + "type": "text", + "name": "connection" + }, + { + "type": "text", + "name": "content-length" + }, + { + "type": "text", + "name": "content-type" + }, + { + "type": "text", + "name": "date" + } + ] + } + ], + "outputType": "object" + } + ] + } +} \ No newline at end of file diff --git a/app/api/Parts/newpart.json b/app/api/Parts/newpart.json index 5cc9eb1..c70d4d9 100644 --- a/app/api/Parts/newpart.json +++ b/app/api/Parts/newpart.json @@ -109,13 +109,7 @@ ] } ], - "outputType": "object", - "metaData": { - "apiUrl": { - "name": "API_BASEURL", - "type": "text" - } - } + "outputType": "object" }, { "name": "partnumber", @@ -126,8 +120,7 @@ "value": "{{$_GET.parttypeid+'-'+$_GET.partcodeid+'-'+api.data.number}}" }, "meta": [], - "outputType": "text", - "metaData": {} + "outputType": "text" }, { "name": "insertpn", @@ -175,13 +168,7 @@ ] } ], - "outputType": "object", - "metaData": { - "apiUrl": { - "name": "API_BASEURL", - "type": "text" - } - } + "outputType": "object" }, { "name": "insertpart", @@ -251,13 +238,7 @@ ] } ], - "outputType": "object", - "metaData": { - "apiUrl": { - "name": "API_BASEURL", - "type": "text" - } - } + "outputType": "object" } ] } diff --git a/app/api/Users/addtorole.json b/app/api/Users/addtorole.json new file mode 100644 index 0000000..bfa183a --- /dev/null +++ b/app/api/Users/addtorole.json @@ -0,0 +1,425 @@ +{ + "meta": { + "$_GET": [ + { + "type": "text", + "name": "roleid" + }, + { + "type": "text", + "name": "userid" + }, + { + "type": "text", + "name": "sort" + }, + { + "type": "text", + "name": "dir" + } + ] + }, + "exec": { + "steps": [ + { + "name": "identity", + "module": "auth", + "action": "identify", + "options": { + "provider": "auth" + }, + "output": true, + "meta": [] + }, + { + "name": "query", + "module": "dbconnector", + "action": "select", + "options": { + "connection": "authdb", + "sql": { + "type": "select", + "columns": [ + { + "table": "xuserrole", + "column": "roleid" + } + ], + "params": [ + { + "operator": "equal", + "type": "expression", + "name": ":P1", + "value": "{{identity}}", + "test": "" + } + ], + "table": { + "name": "xuserrole" + }, + "primary": "id", + "joins": [], + "wheres": { + "condition": "AND", + "rules": [ + { + "id": "xuserrole.userid", + "field": "xuserrole.userid", + "type": "double", + "operator": "equal", + "value": "{{identity}}", + "data": { + "table": "xuserrole", + "column": "userid", + "type": "number", + "columnObj": { + "type": "integer", + "primary": false, + "unique": false, + "nullable": true, + "name": "userid" + } + }, + "operation": "=" + } + ], + "conditional": null, + "valid": true + }, + "query": "select `roleid` from `xuserrole` where `xuserrole`.`userid` = ?" + } + }, + "output": true, + "meta": [ + { + "type": "number", + "name": "roleid" + } + ], + "outputType": "array" + }, + { + "name": "repeat", + "module": "core", + "action": "repeat", + "options": { + "repeat": "{{query}}", + "outputFields": [], + "exec": { + "steps": { + "name": "api", + "module": "api", + "action": "send", + "options": { + "url": "{{$_ENV.API_BASEURL+'/xuserroles/add/'+query[$index].roleid+'/'+identity}}", + "schema": [ + { + "type": "array", + "name": "data", + "sub": [ + { + "type": "text", + "name": "updatedate" + }, + { + "type": "object", + "name": "user", + "sub": [ + { + "type": "text", + "name": "updatedate" + }, + { + "type": "boolean", + "name": "isactive" + }, + { + "type": "text", + "name": "password" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "text", + "name": "lastname" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "firstname" + }, + { + "type": "text", + "name": "email" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "username" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "number", + "name": "id" + }, + { + "type": "object", + "name": "role", + "sub": [ + { + "type": "text", + "name": "updatedate" + }, + { + "type": "number", + "name": "createuserid" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "text", + "name": "name" + }, + { + "type": "boolean", + "name": "isdepartment" + } + ] + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "object", + "name": "headers", + "sub": [ + { + "type": "text", + "name": "connection" + }, + { + "type": "text", + "name": "content-length" + }, + { + "type": "text", + "name": "content-type" + }, + { + "type": "text", + "name": "date" + } + ] + } + ], + "method": "POST" + }, + "output": true, + "meta": [ + { + "type": "array", + "name": "data", + "sub": [ + { + "type": "text", + "name": "updatedate" + }, + { + "type": "object", + "name": "user", + "sub": [ + { + "type": "text", + "name": "updatedate" + }, + { + "type": "boolean", + "name": "isactive" + }, + { + "type": "text", + "name": "password" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "text", + "name": "lastname" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "firstname" + }, + { + "type": "text", + "name": "email" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "username" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "number", + "name": "id" + }, + { + "type": "object", + "name": "role", + "sub": [ + { + "type": "text", + "name": "updatedate" + }, + { + "type": "number", + "name": "createuserid" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "text", + "name": "name" + }, + { + "type": "boolean", + "name": "isdepartment" + } + ] + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "object", + "name": "headers", + "sub": [ + { + "type": "text", + "name": "connection" + }, + { + "type": "text", + "name": "content-length" + }, + { + "type": "text", + "name": "content-type" + }, + { + "type": "text", + "name": "date" + } + ] + } + ], + "outputType": "object" + } + } + }, + "output": true, + "meta": [ + { + "name": "$index", + "type": "number" + }, + { + "name": "$number", + "type": "number" + }, + { + "name": "$name", + "type": "text" + }, + { + "name": "$value", + "type": "object" + }, + { + "name": "roleid", + "type": "number" + } + ], + "outputType": "array" + } + ] + } +} \ No newline at end of file diff --git a/app/api/Users/create.json b/app/api/Users/create.json index 581790f..a911e21 100644 --- a/app/api/Users/create.json +++ b/app/api/Users/create.json @@ -32,13 +32,7 @@ "options": { "password": "{{strpwd}}" }, - "outputType": "text", - "metaData": { - "hashPassword": { - "name": "strpwd", - "type": "text" - } - } + "outputType": "text" }, { "name": "regcode", @@ -49,13 +43,7 @@ "value": "{{UUID}}" }, "meta": [], - "outputType": "text", - "metaData": { - "setValueExpression": { - "name": "UUID", - "type": "object" - } - } + "outputType": "text" }, { "name": "insert", @@ -233,12 +221,6 @@ "toEmail": "{{$_POST.email}}", "body": "

\nHere are your credentials to login for the first time and your registration code to validate your account.\nYour username is: {{$_POST.email}}\nYour password is: P@$$w0rd\nYour validation code is: {{regcode}}\n


\n

Click here to be directed to the website.\n Then click the account menu and login.\n Once you login you will be prompted for the validation code.\n

\n\n\n\n", "contentType": "html" - }, - "metaData": { - "sendToEmail": { - "name": "email", - "type": "text" - } } } ] diff --git a/app/api/Users/insert.json b/app/api/Users/insert.json new file mode 100644 index 0000000..51fd793 --- /dev/null +++ b/app/api/Users/insert.json @@ -0,0 +1,67 @@ +{ + "meta": { + "$_GET": [ + { + "type": "text", + "name": "firstname" + }, + { + "type": "text", + "name": "lastname" + }, + { + "type": "text", + "name": "email" + } + ] + }, + "exec": { + "steps": [ + { + "name": "identity", + "module": "auth", + "action": "identify", + "options": { + "provider": "auth" + }, + "output": true, + "meta": [] + }, + { + "name": "strId", + "module": "core", + "action": "setvalue", + "options": { + "key": "g_strId", + "value": "{{identity.toString()}}" + }, + "meta": [], + "outputType": "text" + }, + { + "name": "api", + "module": "api", + "action": "send", + "options": { + "url": "{{$_ENV.API_BASEURL+'users/insert'}}", + "method": "POST", + "dataType": "json", + "data": { + "id": "{{strId}}", + "createuserid": -1, + "updatedate": "{{NOW}}", + "lastname": "{{$_GET.lastname}}", + "firstname": "{{$_GET.firstname}}", + "updateuserid": -1, + "password": null, + "isactive": true, + "username": null, + "createdate": "{{NOW}}", + "email": "{{$_GET.email}}" + } + }, + "output": true + } + ] + } +} \ No newline at end of file diff --git a/app/api/roles/cnfrm_addroles.json b/app/api/roles/cnfrm_addroles.json new file mode 100644 index 0000000..0e393b3 --- /dev/null +++ b/app/api/roles/cnfrm_addroles.json @@ -0,0 +1,555 @@ +{ + "meta": { + "$_GET": [ + { + "type": "text", + "name": "sort" + }, + { + "type": "text", + "name": "dir" + }, + { + "type": "text", + "name": "userid" + } + ] + }, + "exec": { + "steps": [ + { + "name": "query", + "module": "dbconnector", + "action": "select", + "options": { + "connection": "authdb", + "sql": { + "type": "select", + "columns": [ + { + "table": "xuserrole", + "column": "roleid", + "recid": 1 + } + ], + "params": [ + { + "operator": "equal", + "type": "expression", + "name": ":P1", + "value": "{{$_GET.userid}}", + "test": "" + } + ], + "table": { + "name": "xuserrole" + }, + "primary": "id", + "joins": [], + "wheres": { + "condition": "AND", + "rules": [ + { + "id": "xuserrole.userid", + "field": "xuserrole.userid", + "type": "double", + "operator": "equal", + "value": "{{$_GET.userid}}", + "data": { + "table": "xuserrole", + "column": "userid", + "type": "number", + "columnObj": { + "type": "integer", + "primary": false, + "unique": false, + "nullable": true, + "name": "userid" + } + }, + "operation": "=", + "table": "xuserrole" + } + ], + "conditional": null, + "valid": true + }, + "query": "select `roleid` from `xuserrole` where `xuserrole`.`userid` = ?" + } + }, + "output": true, + "meta": [ + { + "type": "number", + "name": "roleid" + } + ], + "outputType": "array" + }, + { + "name": "repeat", + "module": "core", + "action": "repeat", + "options": { + "repeat": "{{query}}", + "outputFields": [], + "exec": { + "steps": { + "name": "api", + "module": "api", + "action": "send", + "options": { + "url": "{{$_ENV.API_BASEURL+'xuserroles/add/'+$_GET.userid+'/'+roleid}}", + "schema": [ + { + "type": "object", + "name": "data", + "sub": [ + { + "type": "object", + "name": "userid", + "sub": [ + { + "type": "boolean", + "name": "isactive" + }, + { + "type": "text", + "name": "password" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "text", + "name": "lastname" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "firstname" + }, + { + "type": "text", + "name": "username" + }, + { + "type": "text", + "name": "email" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "object", + "name": "roleid", + "sub": [ + { + "type": "text", + "name": "name" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "boolean", + "name": "isdepartment" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "object", + "name": "headers", + "sub": [ + { + "type": "text", + "name": "connection" + }, + { + "type": "text", + "name": "content-length" + }, + { + "type": "text", + "name": "content-type" + }, + { + "type": "text", + "name": "date" + } + ] + } + ], + "method": "POST" + }, + "output": true, + "meta": [ + { + "type": "object", + "name": "data", + "sub": [ + { + "type": "object", + "name": "userid", + "sub": [ + { + "type": "boolean", + "name": "isactive" + }, + { + "type": "text", + "name": "password" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "text", + "name": "lastname" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "firstname" + }, + { + "type": "text", + "name": "username" + }, + { + "type": "text", + "name": "email" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "object", + "name": "roleid", + "sub": [ + { + "type": "text", + "name": "name" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "boolean", + "name": "isdepartment" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "object", + "name": "headers", + "sub": [ + { + "type": "text", + "name": "connection" + }, + { + "type": "text", + "name": "content-length" + }, + { + "type": "text", + "name": "content-type" + }, + { + "type": "text", + "name": "date" + } + ] + } + ], + "outputType": "object" + } + } + }, + "output": true, + "meta": [ + { + "name": "$index", + "type": "number" + }, + { + "name": "$number", + "type": "number" + }, + { + "name": "$name", + "type": "text" + }, + { + "name": "$value", + "type": "object" + }, + { + "name": "roleid", + "type": "number" + }, + { + "name": "api", + "type": "object", + "sub": [ + { + "type": "object", + "name": "data", + "sub": [ + { + "type": "object", + "name": "userid", + "sub": [ + { + "type": "boolean", + "name": "isactive" + }, + { + "type": "text", + "name": "password" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "text", + "name": "lastname" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "firstname" + }, + { + "type": "text", + "name": "username" + }, + { + "type": "text", + "name": "email" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "object", + "name": "roleid", + "sub": [ + { + "type": "text", + "name": "name" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "boolean", + "name": "isdepartment" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "object", + "name": "headers", + "sub": [ + { + "type": "text", + "name": "connection" + }, + { + "type": "text", + "name": "content-length" + }, + { + "type": "text", + "name": "content-type" + }, + { + "type": "text", + "name": "date" + } + ] + } + ] + } + ], + "outputType": "array" + } + ] + } +} \ No newline at end of file diff --git a/app/api/security/confirm.json b/app/api/security/confirm.json index d783f85..c501b0d 100644 --- a/app/api/security/confirm.json +++ b/app/api/security/confirm.json @@ -23,27 +23,77 @@ { "type": "text", "fieldName": "confirmation", + "options": { + "rules": { + "core:required": { + "param": "" + } + } + }, "name": "confirmation" }, { "type": "text", "fieldName": "firstname", + "options": { + "rules": { + "core:required": { + "param": "" + } + } + }, "name": "firstname" }, { "type": "text", "fieldName": "lastname1", + "options": { + "rules": { + "core:required": { + "param": "" + } + } + }, "name": "lastname1" }, { "type": "text", "fieldName": "email", + "options": { + "rules": { + "core:required": { + "param": "" + } + } + }, "name": "email" }, { "type": "text", "fieldName": "password", + "options": { + "rules": { + "core:required": { + "param": "" + } + } + }, "name": "password" + }, + { + "type": "text", + "fieldName": "pwd2", + "options": { + "rules": { + "core:required": { + "param": "" + }, + "core:equalTo": { + "param": "password" + } + } + }, + "name": "pwd2" } ] }, @@ -197,13 +247,11 @@ "columns": [ { "table": "xuserrole", - "column": "userid", - "recid": 1 + "column": "userid" }, { "table": "xuserrole", - "column": "roleid", - "recid": 2 + "column": "roleid" } ], "params": [ @@ -211,7 +259,7 @@ "operator": "equal", "type": "expression", "name": ":P1", - "value": "{{$_POST.id}}", + "value": "{{identity}}", "test": "" } ], @@ -228,7 +276,7 @@ "field": "xuserrole.userid", "type": "double", "operator": "equal", - "value": "{{$_POST.id}}", + "value": "{{identity}}", "data": { "table": "xuserrole", "column": "userid", @@ -241,8 +289,7 @@ "name": "userid" } }, - "operation": "=", - "table": "xuserrole" + "operation": "=" } ], "conditional": null, @@ -263,268 +310,6 @@ } ], "outputType": "array" - }, - { - "name": "api", - "module": "api", - "action": "send", - "options": { - "url": "{{$_ENV.API_BASEURL+'users/insert'}}", - "dataType": "json", - "schema": [ - { - "type": "object", - "name": "data", - "sub": [ - { - "type": "boolean", - "name": "isactive" - }, - { - "type": "array", - "name": "roles", - "sub": [ - { - "type": "text", - "name": "description" - }, - { - "type": "text", - "name": "updateuserid" - }, - { - "type": "text", - "name": "updatedate" - }, - { - "type": "text", - "name": "createdate" - }, - { - "type": "text", - "name": "createuserid" - }, - { - "type": "number", - "name": "id" - }, - { - "type": "text", - "name": "name" - } - ] - }, - { - "type": "number", - "name": "id" - }, - { - "type": "text", - "name": "firstname" - }, - { - "type": "text", - "name": "email" - }, - { - "type": "text", - "name": "lastname" - }, - { - "type": "text", - "name": "username" - }, - { - "type": "text", - "name": "password" - } - ] - }, - { - "type": "object", - "name": "headers", - "sub": [ - { - "type": "text", - "name": "connection" - }, - { - "type": "text", - "name": "content-length" - }, - { - "type": "text", - "name": "content-type" - }, - { - "type": "text", - "name": "date" - } - ] - } - ], - "method": "POST", - "data": { - "isactive": true, - "id": "{{$_POST.id.toString()}}", - "firstname": "{{$_POST.firstname}}", - "email": "{{$_POST.email}}", - "lastname": "{{$_POST.lastname1}}", - "username": null, - "password": "{{hash}}", - "updateuserid": "{{identity}}", - "createuserid": "{{identity}}" - } - }, - "output": true, - "meta": [ - { - "type": "object", - "name": "data", - "sub": [ - { - "type": "boolean", - "name": "isactive" - }, - { - "type": "array", - "name": "roles", - "sub": [ - { - "type": "text", - "name": "description" - }, - { - "type": "text", - "name": "updateuserid" - }, - { - "type": "text", - "name": "updatedate" - }, - { - "type": "text", - "name": "createdate" - }, - { - "type": "text", - "name": "createuserid" - }, - { - "type": "number", - "name": "id" - }, - { - "type": "text", - "name": "name" - } - ] - }, - { - "type": "number", - "name": "id" - }, - { - "type": "text", - "name": "firstname" - }, - { - "type": "text", - "name": "email" - }, - { - "type": "text", - "name": "lastname" - }, - { - "type": "text", - "name": "username" - }, - { - "type": "text", - "name": "password" - } - ] - }, - { - "type": "object", - "name": "headers", - "sub": [ - { - "type": "text", - "name": "connection" - }, - { - "type": "text", - "name": "content-length" - }, - { - "type": "text", - "name": "content-type" - }, - { - "type": "text", - "name": "date" - } - ] - } - ], - "outputType": "object", - "disabled": true - }, - { - "name": "repeat", - "module": "core", - "action": "repeat", - "options": { - "repeat": "{{query.count()}}", - "outputFields": [], - "exec": { - "steps": { - "name": "addroles", - "module": "api", - "action": "send", - "options": { - "url": "{{$_ENV.API_BASEURL+'xuserroles/add/'+$_POST.id+'/'+roleid}}", - "method": "POST" - }, - "output": true - } - } - }, - "output": true, - "meta": [ - { - "name": "$index", - "type": "number" - }, - { - "name": "$number", - "type": "number" - }, - { - "name": "$name", - "type": "text" - }, - { - "name": "$value", - "type": "object" - }, - { - "name": "userid", - "type": "number" - }, - { - "name": "roleid", - "type": "number" - }, - { - "name": "addroles", - "type": "text" - } - ], - "outputType": "array", - "disabled": true } ] }, diff --git a/app/api/security/defalutadminapi.json b/app/api/security/defalutadminapi.json index cf11c0c..df5f36b 100644 --- a/app/api/security/defalutadminapi.json +++ b/app/api/security/defalutadminapi.json @@ -39,15 +39,7 @@ "column": "lastname" } ], - "params": [ - { - "operator": "equal", - "type": "expression", - "name": ":P1", - "value": "{{$_GET.id}}", - "test": "" - } - ], + "params": [], "table": { "name": "users" }, @@ -57,21 +49,22 @@ "condition": "AND", "rules": [ { - "id": "users.id", - "field": "users.id", - "type": "double", + "id": "users.email", + "field": "users.email", + "type": "string", "operator": "equal", - "value": "{{$_GET.id}}", + "value": "admin@prelub.com", "data": { "table": "users", - "column": "id", - "type": "number", + "column": "email", + "type": "text", "columnObj": { - "type": "increments", - "primary": true, + "type": "string", + "maxLength": 255, + "primary": false, "unique": false, - "nullable": false, - "name": "id" + "nullable": true, + "name": "email" } }, "operation": "=" @@ -80,7 +73,7 @@ "conditional": null, "valid": true }, - "query": "select `id`, `email`, `pwd`, `firstname`, `lastname` from `users` where `users`.`id` = ?" + "query": "select `id`, `email`, `pwd`, `firstname`, `lastname` from `users` where `users`.`email` = ?" } }, "output": true, @@ -109,143 +102,155 @@ "outputType": "object" }, { - "name": "insertuser", - "module": "api", - "action": "send", + "name": "", + "module": "core", + "action": "condition", "options": { - "url": "{{$_ENV.API_BASEURL+'users/insert'}}", - "method": "POST", - "schema": [ - { - "type": "object", - "name": "data", - "sub": [ - { - "type": "text", - "name": "updatedate" - }, - { - "type": "text", - "name": "password" - }, - { - "type": "boolean", - "name": "isactive" - }, - { - "type": "number", - "name": "id" - }, - { - "type": "text", - "name": "lastname" - }, - { - "type": "number", - "name": "updateuserid" - }, - { - "type": "text", - "name": "firstname" - }, - { - "type": "text", - "name": "username" - }, - { - "type": "text", - "name": "email" - }, - { - "type": "text", - "name": "createdate" - }, - { - "type": "number", - "name": "createuserid" - } - ] - } - ], - "dataType": "json", - "data": { - "id": "{{gettheuser.id.toString()}}", - "firstname": "{{gettheuser.firstname}}", - "lastname": "{{gettheuser.lastname}}", - "email": "{{gettheuser.email}}", - "password": "{{gettheuser.password}}", - "isactive": true, - "createuserid": -1, - "updateuserid": -1, - "username": null - } - }, - "output": true, - "meta": [ - { - "type": "object", - "name": "data", - "sub": [ - { - "type": "text", - "name": "updatedate" - }, - { - "type": "text", - "name": "password" - }, - { - "type": "boolean", - "name": "isactive" - }, - { - "type": "number", - "name": "id" - }, - { - "type": "text", - "name": "lastname" - }, - { - "type": "number", - "name": "updateuserid" - }, - { - "type": "text", - "name": "firstname" - }, + "if": "{{!gettheuser}}", + "then": { + "steps": [ { - "type": "text", - "name": "username" - }, - { - "type": "text", - "name": "email" - }, - { - "type": "text", - "name": "createdate" + "name": "insertuser", + "module": "api", + "action": "send", + "options": { + "url": "{{$_ENV.API_BASEURL+'users/insert'}}", + "method": "POST", + "schema": [ + { + "type": "object", + "name": "data", + "sub": [ + { + "type": "text", + "name": "updatedate" + }, + { + "type": "text", + "name": "password" + }, + { + "type": "boolean", + "name": "isactive" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "text", + "name": "lastname" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "firstname" + }, + { + "type": "text", + "name": "username" + }, + { + "type": "text", + "name": "email" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "number", + "name": "createuserid" + } + ] + } + ], + "dataType": "json", + "data": { + "id": "{{gettheuser.id.toString()}}", + "firstname": "{{gettheuser.firstname}}", + "lastname": "{{gettheuser.lastname}}", + "email": "{{gettheuser.email}}", + "password": "{{gettheuser.password}}", + "isactive": true, + "createuserid": -1, + "updateuserid": -1, + "username": null + } + }, + "output": true, + "meta": [ + { + "type": "object", + "name": "data", + "sub": [ + { + "type": "text", + "name": "updatedate" + }, + { + "type": "text", + "name": "password" + }, + { + "type": "boolean", + "name": "isactive" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "text", + "name": "lastname" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "firstname" + }, + { + "type": "text", + "name": "username" + }, + { + "type": "text", + "name": "email" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "number", + "name": "createuserid" + } + ] + } + ], + "outputType": "object" }, { - "type": "number", - "name": "createuserid" + "name": "addrole", + "module": "api", + "action": "send", + "options": { + "url": "{{$_ENV.API_BASEURL+'xuserroles/add/'+gettheuser.id+'/1'}}", + "method": "POST", + "dataType": "json" + }, + "output": true } ] } - ], - "outputType": "object" - }, - { - "name": "addrole", - "module": "api", - "action": "send", - "options": { - "url": "{{$_ENV.API_BASEURL+'xuserroles/add/'+gettheuser.id+'/1'}}", - "method": "POST", - "dataType": "json" }, - "output": true, - "metaData": {} + "outputType": "boolean" } ] } diff --git a/app/api/security/isauthenticated.json b/app/api/security/isauthenticated.json index f1b88b8..c99b4d4 100644 --- a/app/api/security/isauthenticated.json +++ b/app/api/security/isauthenticated.json @@ -232,6 +232,82 @@ "name": "isDepartment" } ], + "outputType": "array", + "output": true + }, + { + "name": "xuserroles", + "module": "dbconnector", + "action": "select", + "options": { + "connection": "authdb", + "sql": { + "type": "select", + "columns": [ + { + "table": "xuserrole", + "column": "userid" + }, + { + "table": "xuserrole", + "column": "roleid" + } + ], + "params": [ + { + "operator": "equal", + "type": "expression", + "name": ":P1", + "value": "{{identity}}", + "test": "" + } + ], + "table": { + "name": "xuserrole" + }, + "primary": "id", + "joins": [], + "wheres": { + "condition": "AND", + "rules": [ + { + "id": "xuserrole.userid", + "field": "xuserrole.userid", + "type": "double", + "operator": "equal", + "value": "{{identity}}", + "data": { + "table": "xuserrole", + "column": "userid", + "type": "number", + "columnObj": { + "type": "integer", + "primary": false, + "unique": false, + "nullable": true, + "name": "userid" + } + }, + "operation": "=" + } + ], + "conditional": null, + "valid": true + }, + "query": "select `userid`, `roleid` from `xuserrole` where `xuserrole`.`userid` = ?" + } + }, + "output": true, + "meta": [ + { + "type": "number", + "name": "userid" + }, + { + "type": "number", + "name": "roleid" + } + ], "outputType": "array" }, { @@ -269,7 +345,6 @@ } ], "outputType": "text", - "metaData": {}, "output": true }, { @@ -295,12 +370,6 @@ } ], "outputType": "text", - "metaData": { - "setValueExpression": { - "name": "roles", - "type": "array" - } - }, "output": true }, { @@ -326,7 +395,6 @@ } ], "outputType": "text", - "metaData": {}, "output": true }, { @@ -522,8 +590,7 @@ } } }, - "outputType": "boolean", - "metaData": {} + "outputType": "boolean" }, { "name": "", @@ -543,8 +610,7 @@ } } }, - "outputType": "boolean", - "metaData": {} + "outputType": "boolean" } ] } diff --git a/app/api/security/whoami.json b/app/api/security/whoami.json index 87f0858..944ec3d 100644 --- a/app/api/security/whoami.json +++ b/app/api/security/whoami.json @@ -130,7 +130,12 @@ "connection": "authdb", "sql": { "type": "select", - "columns": [], + "columns": [ + { + "table": "xuserrole", + "column": "roleid" + } + ], "params": [ { "operator": "equal", @@ -141,32 +146,10 @@ } ], "table": { - "name": "roles" + "name": "xuserrole" }, "primary": "id", - "joins": [ - { - "table": "xuserrole", - "column": "*", - "type": "INNER", - "clauses": { - "condition": "AND", - "rules": [ - { - "table": "xuserrole", - "column": "roleid", - "operator": "equal", - "operation": "=", - "value": { - "table": "roles", - "column": "id" - } - } - ] - }, - "primary": "id" - } - ], + "joins": [], "wheres": { "condition": "AND", "rules": [ @@ -194,25 +177,252 @@ "conditional": null, "valid": true }, - "query": "select * from `roles` inner join `xuserrole` on `xuserrole`.`roleid` = `roles`.`id` where `xuserrole`.`userid` = ?" + "query": "select `roleid` from `xuserrole` where `xuserrole`.`userid` = ?" } }, "output": true, "meta": [ { "type": "number", - "name": "id" - }, + "name": "roleid" + } + ], + "outputType": "array" + }, + { + "name": "api_userinfo", + "module": "api", + "action": "send", + "options": { + "url": "{{$_ENV.API_BASEURL+'users/'+identity}}", + "schema": [ + { + "type": "object", + "name": "data", + "sub": [ + { + "type": "number", + "name": "id" + }, + { + "type": "array", + "name": "roles", + "sub": [ + { + "type": "text", + "name": "updatedate" + }, + { + "type": "text", + "name": "name" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "boolean", + "name": "isdepartment" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "number", + "name": "createuserid" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "text", + "name": "lastname" + }, + { + "type": "text", + "name": "firstname" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "password" + }, + { + "type": "boolean", + "name": "isactive" + }, + { + "type": "text", + "name": "username" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "email" + } + ] + }, + { + "type": "object", + "name": "headers", + "sub": [ + { + "type": "text", + "name": "connection" + }, + { + "type": "text", + "name": "content-length" + }, + { + "type": "text", + "name": "content-type" + }, + { + "type": "text", + "name": "date" + } + ] + } + ] + }, + "output": true, + "meta": [ { - "type": "text", - "name": "name" + "type": "object", + "name": "data", + "sub": [ + { + "type": "number", + "name": "id" + }, + { + "type": "array", + "name": "roles", + "sub": [ + { + "type": "text", + "name": "updatedate" + }, + { + "type": "text", + "name": "name" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "boolean", + "name": "isdepartment" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "number", + "name": "createuserid" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "text", + "name": "lastname" + }, + { + "type": "text", + "name": "firstname" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "password" + }, + { + "type": "boolean", + "name": "isactive" + }, + { + "type": "text", + "name": "username" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "email" + } + ] }, { - "type": "boolean", - "name": "isDepartment" + "type": "object", + "name": "headers", + "sub": [ + { + "type": "text", + "name": "connection" + }, + { + "type": "text", + "name": "content-length" + }, + { + "type": "text", + "name": "content-type" + }, + { + "type": "text", + "name": "date" + } + ] } ], - "outputType": "array" + "outputType": "object", + "disabled": true } ] } diff --git a/data/authdb.sqlite3 b/data/authdb.sqlite3 index 71a421c3d091f213a84d06d02c7c1e200cfb03c7..94e39c05c0c866be4e22484ff1a0892b78badbd8 100644 GIT binary patch delta 226 zcmZp8z}WDBae@>RBf~@)CpJa~2EDYG8&d-H#e+Fnn8g{3@^ey)IXRhu%+li2qGFBB zXY?=0X*9Y>axvI9`WlBeT4_L83=9mp$%#d|iFpo11-Y4dK>p&%$NU`Pk{tv5tD+1{ zBTE8{1A>EGymQ=KGaXejvnw54479@xLbJ27+@q38iv3Oe^xgauO^kdhwT+Upl1;Kp zd>vCm3LT9Mj7)S5jCBny6bucmfXLX~H#0lc8D!h$6#wM{%rE(0ZstpP$SR!_uAz~Fp^25Lsg<#%Z)SF?Gtjoe%_;uN1(;9rpWMus Y@Q`0noCW9(4n{_CW>#$$21ZUX02mWM&Hw-a diff --git a/public/css/style.css b/public/css/style.css index e69de29..7de9346 100644 --- a/public/css/style.css +++ b/public/css/style.css @@ -0,0 +1,71 @@ +.:active { + background-color: #000; + border-width: 4px; + border-top-left-radius: 4px; + border-top-right-radius: 4px; + border-bottom-left-radius: 3px; + border-bottom-right-radius: 4px; + background-size: cover; + background-image: -webkit-gradient( + linear, + left bottom, + left top, + color-stop(33%, black), + to(white) + ); + background-image: -webkit-gradient( + linear, + left bottom, + left top, + color-stop(33%, black), + to(white) + ); + background-image: -webkit-gradient( + linear, + left bottom, + left top, + color-stop(33%, black), + to(white) + ); + background-image: linear-gradient(0deg, black 33%, white 100%); +} +.:hover { + background-color: #f70808; +} +.:focus { + background-color: #ffc107; +} +.:visited { + background-color: #084298; +} +.wappler-temp { +} +.wappler-temp { +} +.wappler-temp { +} +.wappler-temp { +} +.wappler-temp { +} +.wappler-temp { +} +.wappler-temp { +} +.wappler-temp { +} +.wappler-temp { +} +.wappler-temp { +} +.wappler-temp { +} +.wappler-temp { +} +.tab { +} +.tab:active { + font-size: large; + line-height: normal; + color: #fff; +} diff --git a/public/dmxAppConnect/config.js b/public/dmxAppConnect/config.js index 14c2ec2..9d08798 100644 --- a/public/dmxAppConnect/config.js +++ b/public/dmxAppConnect/config.js @@ -14413,6 +14413,340 @@ dmx.config({ "pg_apiurl": { "meta": [], "outputType": "text" + }, + "arr_childpcs": { + "meta": [ + { + "type": "number", + "name": "id" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "number", + "name": "createuserid" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "object", + "name": "parent", + "sub": [ + { + "type": "text", + "name": "id" + } + ] + }, + { + "type": "object", + "name": "parttype", + "sub": [ + { + "type": "text", + "name": "updatedate" + }, + { + "type": "number", + "name": "ending" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "number", + "name": "starting" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "text", + "name": "name" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "boolean", + "name": "ispartcode" + }, + { + "type": "text", + "name": "code" + }, + { + "type": "boolean", + "name": "isactive" + }, + { + "type": "array", + "name": "children", + "sub": [ + { + "type": "number", + "name": "id" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "number", + "name": "createuserid" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "object", + "name": "parent", + "sub": [ + { + "type": "number", + "name": "id" + } + ] + }, + { + "type": "object", + "name": "parttype", + "sub": [ + { + "type": "number", + "name": "id" + } + ] + }, + { + "type": "boolean", + "name": "ispartcode" + }, + { + "type": "text", + "name": "code" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "array", + "name": "children" + }, + { + "type": "boolean", + "name": "isactive" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "name" + } + ] + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "name" + } + ], + "outputType": "array" + }, + "arr_partcodes": { + "meta": [ + { + "type": "number", + "name": "id" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "number", + "name": "createuserid" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "object", + "name": "parent", + "sub": [ + { + "type": "text", + "name": "id" + } + ] + }, + { + "type": "object", + "name": "parttype", + "sub": [ + { + "type": "text", + "name": "updatedate" + }, + { + "type": "number", + "name": "ending" + }, + { + "type": "number", + "name": "id" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "number", + "name": "starting" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "text", + "name": "name" + }, + { + "type": "number", + "name": "createuserid" + } + ] + }, + { + "type": "boolean", + "name": "ispartcode" + }, + { + "type": "text", + "name": "code" + }, + { + "type": "boolean", + "name": "isactive" + }, + { + "type": "array", + "name": "children", + "sub": [ + { + "type": "number", + "name": "id" + }, + { + "type": "text", + "name": "description" + }, + { + "type": "number", + "name": "createuserid" + }, + { + "type": "text", + "name": "updatedate" + }, + { + "type": "object", + "name": "parent", + "sub": [ + { + "type": "number", + "name": "id" + } + ] + }, + { + "type": "object", + "name": "parttype", + "sub": [ + { + "type": "number", + "name": "id" + } + ] + }, + { + "type": "boolean", + "name": "ispartcode" + }, + { + "type": "text", + "name": "code" + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "array", + "name": "children" + }, + { + "type": "boolean", + "name": "isactive" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "name" + } + ] + }, + { + "type": "number", + "name": "updateuserid" + }, + { + "type": "text", + "name": "createdate" + }, + { + "type": "text", + "name": "name" + } + ], + "outputType": "array" } }, "partinfo": { @@ -15390,5 +15724,37 @@ dmx.config({ ], "outputType": "array" } + }, + "cnfrm": { + "tableRepeat1": { + "meta": [ + { + "type": "number", + "name": "id" + }, + { + "type": "text", + "name": "name" + }, + { + "type": "boolean", + "name": "isDepartment" + } + ], + "outputType": "array" + }, + "tableRepeat2": { + "meta": [ + { + "type": "number", + "name": "userid" + }, + { + "type": "number", + "name": "roleid" + } + ], + "outputType": "array" + } } }); diff --git a/views/cnfrm.ejs b/views/cnfrm.ejs index a7e4cd1..7014416 100644 --- a/views/cnfrm.ejs +++ b/views/cnfrm.ejs @@ -1,6 +1,9 @@ - + + - + + +
@@ -10,7 +13,7 @@
-
+

@@ -24,4 +27,30 @@
+
+
+
+ + + + + + + + + + + + + + + + + + + +
UseridRoleid
  
+
+
+
\ No newline at end of file diff --git a/views/layouts/smain.ejs b/views/layouts/smain.ejs index fd54536..037ed7a 100644 --- a/views/layouts/smain.ejs +++ b/views/layouts/smain.ejs @@ -54,15 +54,88 @@ + - + + +
+ +
@@ -78,7 +151,7 @@ \ No newline at end of file diff --git a/views/wadmin/usermanage.ejs b/views/wadmin/usermanage.ejs index 1dc736b..184673b 100644 --- a/views/wadmin/usermanage.ejs +++ b/views/wadmin/usermanage.ejs @@ -165,7 +165,7 @@
- +