Skip to content

gw_fct_admin_manage_visit

Edgar Fuste edited this page Nov 2, 2021 · 1 revision

Description

Create new visit class with parameters and form configuration

Input example

SELECT gw_fct_admin_manage_visit($${
"client":{"lang":"ES"}, 
"feature":{"feature_type":"NODE"},
"data":{"action":"CREATE", "action_type":"class", "parameters":{"class_name":"LEAK_ARC","parameter_id":"param_leak_arc", "active":"True","ismultifeature":"false","ismultievent":"False",
"visit_type":1,  "parameter_type":"INSPECTION", "data_type":"integer", "code":"123", 
"v_param_options":null, "form_type":"event_standard","vdefault":null, "short_descript":null, "viewname":"param_leak_arc"}}}$$);


SELECT gw_fct_admin_manage_visit($${
"client":{"lang":"ES"}, 
"feature":{"feature_type":"ARC"},
"data":{"action":"CREATE", "action_type":"parameter", 
"parameters":{"class_name":"LEAK_ARC","parameter_id":"param_leak_arc", "active":"True",
"ismultifeature":"true","ismultievent":"False","visit_type":1,  
"parameter_type":"INSPECTION", "data_type":"integer", "code":"123", 
"v_param_options":null, "form_type":"event_standard","vdefault":1, "short_descript":null, 
"viewname":"aaa_v_visit_leak_arc","isenabled":"True","widgettype":"text", 
"iseditable":"True", "ismandatory":"True", "dv_querytext":null}}}$$);

Output example

{
  "status": "Accepted",
  "message": {
    "level": 3,
    "text": "Process done successfully"
  },
  "version": "3.5.002",
  "body": {
    "form": {},
    "data": {
      "info": {
        "geometryType": "",
        "values": [
          {
            "id": 2793,
            "message": "CREATE VISIT"
          },
          {
            "id": 2794,
            "message": "-------------------------------------------------------------"
          },
          {
            "id": 2795,
            "message": "Update class 10 - LEAK_ARC."
          },
          {
            "id": 2796,
            "message": "Insert parameter param_leak_arc into config_visit_parameter and relate it with class 10 in config_visit_class_x_parameter."
          }
        ]
      },
      "point": {
        "geometryType": "",
        "features": []
      },
      "line": {
        "geometryType": "",
        "features": []
      },
      "polygon": {
        "geometryType": "",
        "features": []
      }
    },
    "actions": {
      "hideForm": false
    }
  }
}
Clone this wiki locally