[
    {
      "name": "Just a Sample Form Group",
      "entity_name": "sample_form_group",
      "entity_type": "form_builder_module",
      "primary_table": "users",
      "form_information": {
        "model": {
          "users": {
            "role": "admin",
            "email": null,
            "user_id": [null],
            "username": null,
            "status_id": 1
          },
          "user_details": [
            null
          ]
        },
        "fields": [
          {
            "key": "users",
            "wrappers": [
              "form-field"
            ],
            "fieldGroup": [
              {
                "key": "username",
                "type": "input",
                "props": {
                  "label": "Username",
                  "required": true,
                  "placeholder": "Enter username"
                }
              },
              {
                "key": "email",
                "type": "input",
                "props": {
                  "type": "email",
                  "label": "Email",
                  "required": true,
                  "placeholder": "Enter email"
                }
              },
              {
                "key": "user_id",
                "type": "repeat",
                "props": {
                  "label": "TODO LIST"
                },
                "fieldArray": {
                  "type": "select",
                  "hooks": {
                    "onInit": true
                  },
                  "props": {
                    "label": "User",
                    "placeholder": "Please select",
                    "required": true
                  }
                }
              },
              {
                "type": "#status"
              }
            ],
            "fieldGroupClassName": "grid grid-cols-2 gap-4 md:grid-cols-2"
          },
          {
            "key": "user_details",
            "type": "repeat",
            "props": {
              "label": "UserDetail",
              "limit": 5,
              "addText": "Add",
              "removeText": "Remove"
            },
            "wrappers": [
              "form-field"
            ],
            "fieldArray": {
              "fieldGroup": [
                {
                  "key": "user_id",
                  "type": "select",
                  "hooks": {
                    "onInit": true
                  },
                  "props": {
                    "label": "User",
                    "placeholder": "Please select",
                    "required": true
                  }
                },
                {
                  "key": "name",
                  "type": "input",
                  "props": {
                    "label": "Name",
                    "required": true,
                    "placeholder": "Name"
                  }
                },
                {
                  "key": "code",
                  "type": "input",
                  "props": {
                    "label": "Code",
                    "required": true,
                    "placeholder": "Code"
                  }
                },
                {
                  "key": "profile_pic",
                  "type": "input",
                  "props": {
                    "type": "hidden"
                  },
                  "className": "hidden"
                },
                {
                  "key": "profile_pic_file",
                  "type": "image",
                  "props": {
                    "label": "Profile Picture"
                  }
                }
              ]
            },
            "fieldGroupClassName": "grid grid-cols-1 gap-2 md:grid-cols-2"
          }
        ],
        "options": {}
      },
      "query_information": {
        "user_id": {
          "company_id": 1,
          "print_query": false,
          "primary_table": "users",
          "start_index": 0,
          "limit_range": 1000,
          "sort_columns": [
            [
              "users.id",
              "asc"
            ]
          ],
          "select_columns": [
            [
              "id", "value"
            ],
            [
              "email", "label"
            ]
          ],
          "search_all": [
            {
              "column_name": "users.status_id",
              "operator": "!=",
              "value": "3"
            }
          ]
        }
      },
      "add_query_information": {
        "table": [
          "users",
          "user_details"
        ],
        "action": [
          "insert",
          "insert"
        ],
        "table_mapping": [
          "table1",
          "table2"
        ],
        "data": {
          "table1": [
            {
              "email": "$users.email",
              "username": "$users.username",
              "role": "$users.role",
              "created_at": true,
              "created_by": true,
              "updated_at": true,
              "updated_by": true,
              "status_id": "$users.status_id"
            }
          ],
          "table2": [
            {
              "code": "$user_details.code",
              "first_name": "$user_details.name",
              "profile_pic": "$user_details.profile_pic",
              "created_at": true,
              "created_by": true,
              "updated_at": true,
              "updated_by": true,
              "user_id": "@table1.id"
            }
          ]
        }
      },
      "edit_query_information": {
        "table": [
          "users",
          "user_details"
        ],
        "action": [
          "update",
          "update"
        ],
        "table_mapping": [
          "table1",
          "table2"
        ],
        "conditions": {
          "table1": [
            {
              "uuid": "$unique_id"
            }
          ],
          "table2": [
            {
              "user_id": "@table1.id"
            }
          ]
        },
        "data": {
          "table1": [
            {
              "email": "$users.email",
              "username": "$users.username",
              "updated_at": true,
              "updated_by": true,
              "status_id": "$users.status_id"
            }
          ],
          "table2": [
            {
              "code": "$user_details.code",
              "first_name": "$user_details.name",
              "profile_pic": "$user_details.profile_pic",
              "updated_at": true,
              "updated_by": true
            }
          ]
        }
      },
      "preset_query_information": {
        "users": {
          "company_id": 1,
          "print_query": false,
          "primary_table": "users",
          "start_index": 0,
          "limit_range": 1,
          "sort_columns": [
            [
              "users.id",
              "asc"
            ]
          ],
          "select_columns": [
            [
              "id", "user_id"
            ],
            [
              "email"
            ],
            [
              "username"
            ],
            [
              "role"
            ],
            [
              "status_id"
            ]
          ],
          "search_all": [
            {
              "column_name": "users.uuid",
              "operator": "=",
              "value": "$unique_id"
            },
            {
              "column_name": "users.status_id",
              "operator": "!=",
              "value": "3"
            }
          ]
        },
        "user_details": {
          "company_id": 1,
          "print_query": false,
          "primary_table": "users",
          "start_index": 0,
          "limit_range": 1000,
          "sort_columns": [
            [
              "users.id",
              "asc"
            ]
          ],
          "select_columns": [
            [
              "user_details.code"
            ],
            [
              "user_details.user_id"
            ],
            [
              "user_details.first_name", "name"
            ],
            [
              "user_details.profile_pic"
            ]
          ],
          "search_all": [
            {
              "column_name": "users.uuid",
              "operator": "=",
              "value": "$unique_id"
            },
            {
              "column_name": "users.status_id",
              "operator": "!=",
              "value": "3"
            }
          ],
          "includes": [
            {
              "table_name": "user_details",
              "join_type": "INNER",
              "join_condition": "users.id = user_details.user_id"
            }
          ]
        }
      }
    },
    {
      "name": "Update Role",
      "entity_name": "role_form",
      "entity_type": "form_builder_module",
      "primary_table": "roles",
      "form_information": {
        "options": {},
        "model": {
          "roles": {
            "name": "",
            "description": "",
            "status_id": 1
          }
        },
        "fields": [
          {
            "key": "roles",
            "wrappers": [
              "form-field"
            ],
            "fieldGroupClassName": "grid grid-cols-1 gap-2 md:grid-cols-2",
            "fieldGroup": [
              {
                "key": "name",
                "type": "input",
                "hooks": {
                  "uniqueKey": "unique_role_name"
                },
                "props": {
                  "label": "Name",
                  "placeholder": "Enter role name",
                  "required": true
                }
              },
              {
                "key": "description",
                "type": "textarea",
                "props": {
                  "label": "Description",
                  "placeholder": "Enter role description",
                  "required": false,
                  "rows": 2
                }
              },
              {
                "type": "#status"
              }
            ]
          }
        ]
      },
      "query_information": {
        "unique_role_name": {
          "company_id": 1,
          "search_all": [
            {
              "value": "3",
              "operator": "!=",
              "column_name": "roles.status_id"
            },
            {
              "value": "this.label",
              "operator": "=",
              "column_name": "roles.name"
            },
            {
              "value": "$unique_id",
              "operator": "!=",
              "column_name": "roles.uuid"
            }
          ],
          "limit_range": 1000,
          "print_query": false,
          "start_index": 0,
          "sort_columns": [
            [
              "roles.name",
              "asc"
            ]
          ],
          "primary_table": "roles",
          "select_columns": [
            [
              "id",
              "value"
            ],
            [
              "name",
              "label"
            ]
          ]
        }
      },
      "add_query_information": {
        "data": {
          "table1": [
            {
              "name": "$roles.name",
              "status_id": "$roles.status_id",
              "created_at": true,
              "created_by": true,
              "updated_at": true,
              "updated_by": true,
              "description": "$roles.description"
            }
          ]
        },
        "table": [
          "roles"
        ],
        "action": [
          "insert"
        ],
        "table_mapping": [
          "table1"
        ]
      },
      "edit_query_information": {
        "data": {
          "table1": [
            {
              "name": "$roles.name",
              "status_id": "$roles.status_id",
              "updated_at": true,
              "updated_by": true,
              "description": "$roles.description"
            }
          ]
        },
        "conditions": {
          "table1": [
            {
              "uuid": "$unique_id"
            }
          ]
        },
        "table": [
          "roles"
        ],
        "action": [
          "update"
        ],
        "table_mapping": [
          "table1"
        ]
      },
      "preset_query_information": {
        "roles": {
          "company_id": 1,
          "print_query": false,
          "primary_table": "roles",
          "start_index": 0,
          "limit_range": 1,
          "sort_columns": [
            [
              "roles.id",
              "asc"
            ]
          ],
          "select_columns": [
            [
              "name"
            ],
            [
              "status_id"
            ],
            [
              "description"
            ]
          ],
          "search_all": [
            {
              "column_name": "roles.uuid",
              "operator": "=",
              "value": "$unique_id"
            },
            {
              "column_name": "roles.status_id",
              "operator": "!=",
              "value": "3"
            }
          ]
        }
      }
    },
  {
    "name": "Update User",
    "entity_name": "user_form",
    "entity_type": "form_builder_module",
    "primary_table": "users",
    "form_information": {
      "model": {
        "users": {
          "role": "admin",
          "email": null,
          "role_id": null,
          "username": null,
          "status_id": 1,
          "is_drafted": false,
          "process_status": "submitted",
          "allow_login_web": 0,
          "allow_login_mobile": 0
        },
        "user_roles": {
          "role_id": []
        },
        "user_details": {
          "dob": null,
          "code": null,
          "gender": "male",
          "address": null,
          "last_name": null,
          "first_name": null,
          "profile_pic": null,
          "country_code": null,
          "phone_number": null,
          "department_id": null,
          "designation_id": null
        }
      },
      "fields": [
        {
          "key": "users",
          "wrappers": [
            "form-field"
          ],
          "fieldGroup": [
            {
              "key": "username",
              "type": "input",
              "props": {
                "label": "form_label_name",
                "required": true,
                "placeholder": "form_label_name_placeholder"
              }
            },
            {
              "key": "email",
              "type": "input",
              "props": {
                "type": "email",
                "label": "email",
                "required": true,
                "placeholder": "email_placeholder"
              }
            },
            {
              "type": "#status"
            },
            {
              "key": "is_drafted",
              "type": "input",
              "props": {
                "type": "hidden"
              },
              "className": "hidden"
            },
            {
              "key": "process_status",
              "type": "input",
              "props": {
                "type": "hidden"
              },
              "className": "hidden"
            },
            {
              "key": "allow_login_web",
              "type": "radio",
              "props": {
                "label": "allow_login_web",
                "options": [
                  {
                    "label": "Yes",
                    "value": 1
                  },
                  {
                    "label": "No",
                    "value": 0
                  }
                ],
                "required": true
              }
            },
            {
              "key": "allow_login_mobile",
              "type": "radio",
              "props": {
                "label": "allow_login_mobile",
                "options": [
                  {
                    "label": "Yes",
                    "value": 1
                  },
                  {
                    "label": "No",
                    "value": 0
                  }
                ],
                "required": true
              }
            }
          ],
          "fieldGroupClassName": "grid grid-cols-1 gap-2 md:grid-cols-3"
        },
        {
          "key": "user_details",
          "wrappers": [
            "form-field"
          ],
          "fieldGroup": [
            {
              "key": "code",
              "type": "input",
              "props": {
                "label": "code",
                "required": true,
                "placeholder": "code_placeholder"
              }
            },
            {
              "key": "first_name",
              "type": "input",
              "props": {
                "label": "profile_form_first_name",
                "required": true,
                "placeholder": "profile_form_first_name_placeholder"
              }
            },
            {
              "key": "last_name",
              "type": "input",
              "props": {
                "label": "profile_form_last_name",
                "placeholder": "profile_form_last_name_placeholder"
              }
            },
            {
              "key": "department_id",
              "type": "select-from-db",
              "templateOptions": {
                "label": "department",
                "table": "departments",
                "search_all": [
                  {
                    "value": "1",
                    "operator": "=",
                    "column_name": "departments.status_id"
                  }
                ],
                "labelColumn": "name",
                "placeholder": "please_select",
                "valueColumn": "id",
                "sort_columns": [
                  [
                    "departments.name",
                    "asc"
                  ]
                ]
              },
              "attached_policies": [
                "filterdepartmentstartswithe"
              ]
            },
            {
              "key": "designation_id",
              "type": "select-from-db",
              "templateOptions": {
                "label": "designation",
                "table": "designations",
                "search_all": [
                  {
                    "value": "1",
                    "operator": "=",
                    "column_name": "designations.status_id"
                  }
                ],
                "labelColumn": "name",
                "placeholder": "please_select",
                "valueColumn": "id",
                "sort_columns": [
                  [
                    "designations.name",
                    "asc"
                  ]
                ]
              }
            },
            {
              "key": "dob",
              "type": "input",
              "props": {
                "type": "date",
                "label": "profile_form_dob",
                "placeholder": "profile_form_dob_placeholder"
              }
            },
            {
              "key": "country_code",
              "type": "select-from-db",
              "templateOptions": {
                "label": "country_code",
                "table": "phone_country_codes",
                "search_all": [
                  {
                    "value": "1",
                    "operator": "=",
                    "column_name": "phone_country_codes.status_id"
                  }
                ],
                "labelColumn": "CONCAT(country_code, ' - ', country_name , '(', iso_code ,')')",
                "placeholder": "please_select",
                "print_query": true,
                "valueColumn": "country_code",
                "sort_columns": [
                  [
                    "phone_country_codes.id",
                    "asc"
                  ]
                ]
              }
            },
            {
              "key": "phone_number",
              "type": "input",
              "props": {
                "label": "profile_form_phnum",
                "placeholder": "profile_form_phnum_placeholder"
              }
            },
            {
              "key": "gender",
              "type": "radio",
              "props": {
                "label": "profile_form_gender",
                "options": [
                  {
                    "label": "Male",
                    "value": "male"
                  },
                  {
                    "label": "Female",
                    "value": "female"
                  },
                  {
                    "label": "Others",
                    "value": "others"
                  }
                ],
                "required": true
              }
            },
            {
              "key": "address",
              "type": "textarea",
              "props": {
                "rows": 3,
                "label": "profile_form_address",
                "placeholder": "profile_form_address_placeholder"
              }
            },
            {
              "key": "profile_pic",
              "type": "input",
              "props": {
                "type": "hidden"
              },
              "className": "hidden"
            },
            {
              "key": "profile_pic_file",
              "type": "file",
              "props": {
                "label": "profile_picture",
                "accept": "png",
                "max_size": "1mb"
              }
            }
          ],
          "fieldGroupClassName": "grid grid-cols-1 gap-2 md:grid-cols-3"
        },
        {
          "key": "user_roles",
          "modal": {
            "title": "",
            "width": "400px",
            "showClose": true,
            "entityName": "role_form"
          },
          "wrappers": [
            "form-field"
          ],
          "fieldGroup": [
            {
              "key": "role_id",
              "type": "select-from-db",
              "enable_edit": true,
              "templateOptions": {
                "label": "role",
                "table": "roles",
                "multiple": true,
                "required": true,
                "enable_edit": true,
                "labelColumn": "CONCAT(name,'___',created_at)",
                "placeholder": "please_select",
                "valueColumn": "id",
                "additionalColumns": [
                  [
                    "description",
                    "description"
                  ]
                ]
              },
              "attached_policies": [
                "filterrolesstartswiths"
              ]
            }
          ],
          "fieldGroupClassName": "grid grid-cols-1 gap-2 md:grid-cols-3"
        }
      ],
      "options": {}
    },
    "query_information": {},
    "add_query_information": {
      "data": {
        "table1": [
          {
            "role": "$users.role",
            "email": "$users.email",
            "username": "$users.username",
            "status_id": "$users.status_id",
            "created_at": true,
            "created_by": true,
            "is_drafted": "$users.is_drafted",
            "updated_at": true,
            "updated_by": true,
            "allow_login_web": "$users.allow_login_web",
            "allow_login_mobile": "$users.allow_login_mobile"
          }
        ],
        "table2": [
          {
            "dob": "[#[CASE WHEN COALESCE($user_details.dob, '') <> '' THEN ($user_details.dob)::timestamptz ELSE NULL END]#]",
            "code": "$user_details.code",
            "gender": "$user_details.gender",
            "address": "$user_details.address",
            "user_id": "@table1.id",
            "last_name": "$user_details.last_name",
            "created_at": true,
            "created_by": true,
            "first_name": "$user_details.first_name",
            "updated_at": true,
            "updated_by": true,
            "profile_pic": "$user_details.profile_pic",
            "country_code": "$user_details.country_code",
            "phone_number": "$user_details.phone_number",
            "department_id": "$user_details.department_id",
            "designation_id": "$user_details.designation_id"
          }
        ],
        "table3": [
          {
            "role_id": "$user_roles.role_id",
            "user_id": "@table1.id"
          }
        ],
        "table4": [
          {
            "user_id": "@table1.id",
            "unique_id": "@table1.id",
            "created_at": true,
            "created_by": true,
            "prefill_data": "$model",
            "notification_template_process_slug": "user-created"
          }
        ]
      },
      "table": [
        "users",
        "user_details",
        "user_roles",
        "notification_process_jobs"
      ],
      "action": [
        "insert",
        "insert",
        "insert",
        "insert"
      ],
      "table_mapping": [
        "table1",
        "table2",
        "table3",
        "table4"
      ]
    },
    "edit_query_information": {
      "data": {
        "table1": [
          {
            "email": "$users.email",
            "username": "$users.username",
            "status_id": "$users.status_id",
            "is_drafted": "$users.is_drafted",
            "updated_at": true,
            "updated_by": true,
            "allow_login_web": "$users.allow_login_web",
            "allow_login_mobile": "$users.allow_login_mobile"
          }
        ],
        "table2": [
          {
            "dob": "[#[CASE WHEN COALESCE($user_details.dob, '') <> '' THEN ($user_details.dob)::timestamptz ELSE NULL END]#]",
            "code": "$user_details.code",
            "gender": "$user_details.gender",
            "address": "$user_details.address",
            "last_name": "$user_details.last_name",
            "first_name": "$user_details.first_name",
            "updated_at": true,
            "updated_by": true,
            "profile_pic": "$user_details.profile_pic",
            "country_code": "$user_details.country_code",
            "phone_number": "$user_details.phone_number",
            "department_id": "$user_details.department_id",
            "designation_id": "$user_details.designation_id"
          }
        ],
        "table4": [
          {
            "role_id": "$user_roles.role_id",
            "user_id": "@table1.id"
          }
        ],
        "table5": [
          {
            "details": "name_starts_with_mukesh",
            "user_id": "$user_id",
            "screen_id": "@table1.uuid",
            "unique_id": "@table1.id",
            "sequence_no": "{{{ get_sequence_no('approval_sequence', true, false) }}}",
            "prefill_data": "$model",
            "primary_table": "users",
            "approval_workflow_slug": "name_starts_with_mukesh"
          }
        ]
      },
      "table": [
        "users",
        "user_details",
        "user_roles",
        "user_roles",
        "approval_process_jobs"
      ],
      "action": [
        "update",
        "update",
        "hard_delete",
        "insert",
        "insert"
      ],
      "conditions": {
        "table1": [
          {
            "uuid": "$unique_id"
          }
        ],
        "table2": [
          {
            "user_id": "@table1.id"
          }
        ],
        "table3": [
          {
            "user_id": "@table1.id"
          }
        ]
      },
      "table_mapping": [
        "table1",
        "table2",
        "table3",
        "table4",
        "table5"
      ]
    },
    "preset_query_information": {
      "users": {
        "company_id": 1,
        "search_all": [
          {
            "value": "$unique_id",
            "operator": "=",
            "column_name": "users.uuid"
          },
          {
            "value": "3",
            "operator": "!=",
            "column_name": "users.status_id"
          }
        ],
        "limit_range": 1,
        "print_query": true,
        "start_index": 0,
        "sort_columns": [
          [
            "users.id",
            "asc"
          ]
        ],
        "primary_table": "users",
        "select_columns": [
          [
            "email"
          ],
          [
            "username"
          ],
          [
            "role"
          ],
          [
            "status_id"
          ],
          [
            "process_status"
          ],
          [
            "is_drafted"
          ],
          [
            "users.allow_login_mobile"
          ],
          [
            "users.allow_login_web"
          ]
        ]
      },
      "user_roles": {
        "group_by": [
          "user_roles.user_id"
        ],
        "includes": [
          {
            "join_type": "INNER",
            "table_name": "users",
            "join_condition": "users.id = user_roles.user_id"
          }
        ],
        "company_id": 1,
        "search_all": [
          {
            "value": "$unique_id",
            "operator": "=",
            "column_name": "users.uuid"
          },
          {
            "value": "3",
            "operator": "!=",
            "column_name": "users.status_id"
          }
        ],
        "limit_range": 15,
        "print_query": false,
        "start_index": 0,
        "sort_columns": [
          [
            "user_roles.user_id",
            "desc"
          ]
        ],
        "primary_table": "user_roles",
        "select_columns": [
          [
            "json_agg(user_roles.role_id::int)",
            "role_id"
          ]
        ]
      },
      "user_details": {
        "includes": [
          {
            "join_type": "INNER",
            "table_name": "user_details",
            "join_condition": "users.id = user_details.user_id"
          }
        ],
        "company_id": 1,
        "search_all": [
          {
            "value": "$unique_id",
            "operator": "=",
            "column_name": "users.uuid"
          },
          {
            "value": "3",
            "operator": "!=",
            "column_name": "users.status_id"
          }
        ],
        "limit_range": 1,
        "print_query": true,
        "start_index": 0,
        "sort_columns": [
          [
            "users.id",
            "asc"
          ]
        ],
        "primary_table": "users",
        "select_columns": [
          [
            "user_details.code"
          ],
          [
            "user_details.first_name"
          ],
          [
            "user_details.last_name"
          ],
          [
            "user_details.designation_id"
          ],
          [
            "user_details.department_id"
          ],
          [
            "user_details.dob"
          ],
          [
            "user_details.phone_number"
          ],
          [
            "user_details.country_code"
          ],
          [
            "user_details.gender"
          ],
          [
            "user_details.user_time_zone"
          ],
          [
            "user_details.address"
          ],
          [
            "user_details.profile_pic"
          ]
        ]
      }
    }
  },
    {
      "name": "Email Template Recipient Tag Form",
      "entity_name": "email_template_recipient_tag_form",
      "entity_type": "form_builder_module",
      "primary_table": "email_template_recipient_tags",
      "form_information": {
        "options": {},
        "model": {
          "email_template_recipient_tags": {
            "name": "",
            "slug": "",
            "description": "",
            "query_information": "",
            "status_id": 1
          }
        },
        "fields": [
          {
            "key": "email_template_recipient_tags",
            "wrappers": [
              "form-field"
            ],
            "fieldGroupClassName": "grid grid-cols-1 gap-2 md:grid-cols-2",
            "fieldGroup": [
              {
                "key": "name",
                "type": "input",
                "props": {
                  "label": "Name",
                  "placeholder": "Enter name",
                  "required": true
                }
              },
              {
                "key": "slug",
                "type": "input",
                "props": {
                  "label": "Slug",
                  "placeholder": "Enter slug",
                  "required": true
                }
              },
              {
                "key": "description",
                "type": "textarea",
                "props": {
                  "rows": 2,
                  "label": "Description",
                  "required": false,
                  "placeholder": "Enter description"
                }
              },
              {
                "type": "#status"
              },
              {
                "key": "query_information",
                "type": "vs-code",
                "props": {
                  "rows": 6,
                  "label": "Query Information",
                  "language": "json",
                  "required": false,
                  "placeholder": "Query Information"
                }
              }
            ]
          }
        ]
      },
      "query_information": null,
      "add_query_information": {
        "data": {
          "table1": [
            {
              "name": "$email_template_recipient_tags.name",
              "status_id": "$email_template_recipient_tags.status_id",
              "description": "$email_template_recipient_tags.description",
              "slug": "$email_template_recipient_tags.slug",
              "query_information": "$email_template_recipient_tags.query_information"
            }
          ]
        },
        "table": [
          "email_template_recipient_tags"
        ],
        "action": [
          "insert"
        ],
        "table_mapping": [
          "table1"
        ]
      },
      "edit_query_information": {
        "data": {
          "table1": [
            {
              "name": "$email_template_recipient_tags.name",
              "status_id": "$email_template_recipient_tags.status_id",
              "description": "$email_template_recipient_tags.description",
              "slug": "$email_template_recipient_tags.slug",
              "query_information": "$email_template_recipient_tags.query_information"
            }
          ]
        },
        "conditions": {
          "table1": [
            {
              "uuid": "$unique_id"
            }
          ]
        },
        "table": [
          "email_template_recipient_tags"
        ],
        "action": [
          "update"
        ],
        "table_mapping": [
          "table1"
        ]
      },
      "preset_query_information": {
        "email_template_recipient_tags": {
          "company_id": 1,
          "print_query": false,
          "primary_table": "email_template_recipient_tags",
          "start_index": 0,
          "limit_range": 1,
          "sort_columns": [
            [
              "email_template_recipient_tags.id",
              "asc"
            ]
          ],
          "select_columns": [
            [
              "name"
            ],
            ["description"],
            [
              "status_id"
            ],
            [
              "slug"
            ],
            [
              "query_information"
            ]
          ],
          "search_all": [
            {
              "column_name": "email_template_recipient_tags.uuid",
              "operator": "=",
              "value": "$unique_id"
            },
            {
              "column_name": "email_template_recipient_tags.status_id",
              "operator": "!=",
              "value": "3"
            }
          ]
        }
      }
    },
    {
      "name": "Email Template Tag Form",
      "entity_name": "email_template_tag_form",
      "entity_type": "form_builder_module",
      "primary_table": "email_template_tags",
      "form_information": {
        "options": {},
        "model": {
          "email_template_tags": {
            "name": "",
            "slug": "",
            "description": "",
            "status_id": 1
          }
        },
        "fields": [
          {
            "key": "email_template_tags",
            "wrappers": [
              "form-field"
            ],
            "fieldGroupClassName": "grid grid-cols-1 gap-2 md:grid-cols-2",
            "fieldGroup": [
              {
                "key": "name",
                "type": "input",
                "props": {
                  "label": "Name",
                  "placeholder": "Enter name",
                  "required": true
                }
              },
              {
                "key": "slug",
                "type": "input",
                "props": {
                  "label": "Slug",
                  "placeholder": "Enter slug",
                  "required": true
                }
              },
              {
                "key": "description",
                "type": "textarea",
                "props": {
                  "rows": 2,
                  "label": "Description",
                  "required": false,
                  "placeholder": "Enter description"
                }
              },
              {
                "type": "#status"
              }
            ]
          }
        ]
      },
      "query_information": null,
      "add_query_information": {
        "data": {
          "table1": [
            {
              "name": "$email_template_tags.name",
              "status_id": "$email_template_tags.status_id",
              "description": "$email_template_tags.description",
              "slug": "$email_template_tags.slug"
            }
          ]
        },
        "table": [
          "email_template_tags"
        ],
        "action": [
          "insert"
        ],
        "table_mapping": [
          "table1"
        ]
      },
      "edit_query_information": {
        "data": {
          "table1": [
            {
              "name": "$email_template_tags.name",
              "status_id": "$email_template_tags.status_id",
              "description": "$email_template_tags.description",
              "slug": "$email_template_tags.slug"
            }
          ]
        },
        "conditions": {
          "table1": [
            {
              "uuid": "$unique_id"
            }
          ]
        },
        "table": [
          "email_template_tags"
        ],
        "action": [
          "update"
        ],
        "table_mapping": [
          "table1"
        ]
      },
      "preset_query_information": {
        "email_template_tags": {
          "company_id": 1,
          "print_query": false,
          "primary_table": "email_template_tags",
          "start_index": 0,
          "limit_range": 1,
          "sort_columns": [
            [
              "email_template_tags.id",
              "asc"
            ]
          ],
          "select_columns": [
            [
              "name"
            ],
            ["description"],
            [
              "status_id"
            ],
            [
              "slug"
            ]
          ],
          "search_all": [
            {
              "column_name": "email_template_tags.uuid",
              "operator": "=",
              "value": "$unique_id"
            },
            {
              "column_name": "email_template_tags.status_id",
              "operator": "!=",
              "value": "3"
            }
          ]
        }
      }
    },
    {
      "name": "Email Template Process Form",
      "entity_name": "email_template_process_form",
      "entity_type": "form_builder_module",
      "primary_table": "email_template_process",
      "form_information": {
        "options": {},
        "model": {
          "email_template_process": {
            "name": "",
            "slug": "",
            "query_information": "",
            "status_id": 1
          },
          "email_template_process_tags_mapping": {
            "email_template_tag_id": []
          }
        },
        "fields": [
          {
            "key": "email_template_process",
            "wrappers": [
              "form-field"
            ],
            "fieldGroupClassName": "grid grid-cols-1 gap-2 md:grid-cols-2",
            "fieldGroup": [
              {
                "key": "name",
                "type": "input",
                "props": {
                  "label": "Name",
                  "placeholder": "Enter name",
                  "required": true
                }
              },
              {
                "key": "slug",
                "type": "input",
                "props": {
                  "label": "Slug",
                  "placeholder": "Enter slug",
                  "required": true
                }
              },
              {
                "key": "query_information",
                "type": "vs-code",
                "props": {
                  "rows": 6,
                  "label": "Query Information",
                  "language": "json",
                  "required": false,
                  "placeholder": "Query Information"
                }
              },
              {
                "type": "#status"
              }
            ]
          },
          {
            "key": "email_template_process_tags_mapping",
            "wrappers": [
              "form-field"
            ],
            "fieldGroup": [
              {
                "key": "email_template_tag_id",
                "type": "select-from-db",
                "templateOptions": {
                  "label": "Email Template Tags",
                  "table": "email_template_tags",
                  "multiple": true,
                  "required": true,
                  "labelColumn": "name",
                  "placeholder": "Please select",
                  "valueColumn": "id"
                }
              }
            ],
            "fieldGroupClassName": "grid grid-cols-1 gap-2 md:grid-cols-3"
          }
        ]
      },
      "query_information": null,
      "add_query_information": {
        "data": {
          "table1": [
            {
              "name": "$email_template_process.name",
              "status_id": "$email_template_process.status_id",
              "slug": "$email_template_process.slug",
              "query_information": "$email_template_process.query_information"
            }
          ],
          "table2": [
            {
              "email_template_tag_id": "$email_template_process_tags_mapping.email_template_tag_id",
              "email_template_process_id": "@table1.id"
            }
          ]
        },
        "table": [
          "email_template_process",
          "email_template_process_tags_mapping"
        ],
        "action": [
          "insert",
          "insert"
        ],
        "table_mapping": [
          "table1",
          "table2"
        ]
      },
      "edit_query_information": {
        "data": {
          "table1": [
            {
              "name": "$email_template_process.name",
              "status_id": "$email_template_process.status_id",
              "slug": "$email_template_process.slug",
              "query_information": "$email_template_process.query_information"
            }
          ],
          "table3": [
            {
              "email_template_tag_id": "$email_template_process_tags_mapping.email_template_tag_id",
              "email_template_process_id": "@table1.id"
            }
          ]
        },
        "conditions": {
          "table1": [
            {
              "uuid": "$unique_id"
            }
          ],
          "table2": [
            {
              "email_template_process_id": "@table1.id"
            }
          ]
        },
        "table": [
          "email_template_process",
          "email_template_process_tags_mapping",
          "email_template_process_tags_mapping"
        ],
        "action": [
          "update",
          "hard_delete",
          "insert"
        ],
        "table_mapping": [
          "table1",
          "table2",
          "table3"
        ]
      },
      "preset_query_information": {
        "email_template_process": {
          "company_id": 1,
          "print_query": false,
          "primary_table": "email_template_process",
          "start_index": 0,
          "limit_range": 1,
          "sort_columns": [
            [
              "email_template_process.id",
              "asc"
            ]
          ],
          "select_columns": [
            [
              "name"
            ],
            [
              "status_id"
            ],
            [
              "slug"
            ],
            [
              "query_information"
            ]
          ],
          "search_all": [
            {
              "column_name": "email_template_process.uuid",
              "operator": "=",
              "value": "$unique_id"
            },
            {
              "column_name": "email_template_process.status_id",
              "operator": "!=",
              "value": "3"
            }
          ]
        },
        "email_template_process_tags_mapping": {
          "group_by": [
            "email_template_process_tags_mapping.email_template_process_id"
          ],
          "includes": [
            {
              "join_type": "INNER",
              "table_name": "email_template_process",
              "join_condition": "email_template_process.id = email_template_process_tags_mapping.email_template_process_id"
            }
          ],
          "company_id": 1,
          "search_all": [
            {
              "value": "$unique_id",
              "operator": "=",
              "column_name": "email_template_process.uuid"
            },
            {
              "value": "3",
              "operator": "!=",
              "column_name": "email_template_process.status_id"
            }
          ],
          "limit_range": 15,
          "print_query": false,
          "start_index": 0,
          "sort_columns": [
            [
              "email_template_process_tags_mapping.email_template_process_id",
              "desc"
            ]
          ],
          "primary_table": "email_template_process_tags_mapping",
          "select_columns": [
            [
              "json_agg(email_template_process_tags_mapping.email_template_tag_id::int)",
              "email_template_tag_id"
            ]
          ]
        }
      }
    },
    {
      "name": "Email Template Form",
      "entity_name": "email_template_form",
      "entity_type": "form_builder_module",
      "primary_table": "email_templates",
      "form_information": {
        "model": {
          "email_templates": {
            "name": "",
            "slug": "",
            "subject": "",
            "status_id": 1,
            "template_body": "",
            "email_template_process_id": null
          }
        },
        "fields": [
          {
            "key": "email_templates",
            "wrappers": [
              "form-field"
            ],
            "fieldGroup": [
              {
                "key": "name",
                "type": "input",
                "props": {
                  "label": "Name",
                  "required": true,
                  "placeholder": "Enter name"
                }
              },
              {
                "key": "slug",
                "type": "input",
                "props": {
                  "label": "Slug",
                  "required": true,
                  "placeholder": "Enter slug"
                }
              },
              {
                "key": "subject",
                "type": "input",
                "props": {
                  "label": "Subject",
                  "required": true,
                  "placeholder": "Enter subject"
                }
              },
              {
                "key": "email_template_process_id",
                "type": "select-from-db",
                "templateOptions": {
                  "label": "Email Template Process",
                  "table": "email_template_process",
                  "required": true,
                  "labelColumn": "name",
                  "placeholder": "Please select",
                  "valueColumn": "id"
                }
              },
              {
                "key": "template_body",
                "type": "rich-editor",
                "props": {
                  "rows": 10,
                  "label": "Template",
                  "required": true,
                  "html-editor": true,
                  "placeholder": "Enter template body"
                }
              },
              {
                "key": "tags",
                "type": "email-tags",
                "props": {
                  "label": "Tags"
                }
              },
              {
                "type": "#status"
              }
            ],
            "fieldGroupClassName": "grid grid-cols-1 gap-2 md:grid-cols-2"
          }
        ],
        "options": {}
      },
      "query_information": null,
      "add_query_information": {
        "data": {
          "table1": [
            {
              "name": "$email_templates.name",
              "slug": "$email_templates.slug",
              "subject": "$email_templates.subject",
              "template_body": "$email_templates.template_body",
              "email_template_process_id": "$email_templates.email_template_process_id",
              "status_id": "$email_templates.status_id",
              "created_at": true,
              "created_by": true,
              "updated_at": true,
              "updated_by": true
            }
          ]
        },
        "table": [
          "email_templates"
        ],
        "action": [
          "insert"
        ],
        "table_mapping": [
          "table1"
        ]
      },
      "edit_query_information": {
        "data": {
          "table1": [
            {
              "name": "$email_templates.name",
              "slug": "$email_templates.slug",
              "subject": "$email_templates.subject",
              "template_body": "$email_templates.template_body",
              "email_template_process_id": "$email_templates.email_template_process_id",
              "status_id": "$email_templates.status_id",
              "updated_at": true,
              "updated_by": true
            }
          ]
        },
        "conditions": {
          "table1": [
            {
              "uuid": "$unique_id"
            }
          ]
        },
        "table": [
          "email_templates"
        ],
        "action": [
          "update"
        ],
        "table_mapping": [
          "table1"
        ]
      },
      "preset_query_information": {
        "email_templates": {
          "company_id": 1,
          "print_query": false,
          "primary_table": "email_templates",
          "start_index": 0,
          "limit_range": 1,
          "sort_columns": [
            [
              "email_templates.id",
              "asc"
            ]
          ],
          "select_columns": [
            ["name"],
            ["slug"],
            ["subject"],
            ["template_body"],
            ["email_template_process_id"],
            ["status_id"]
          ],
          "search_all": [
            {
              "column_name": "email_templates.uuid",
              "operator": "=",
              "value": "$unique_id"
            },
            {
              "column_name": "email_templates.status_id",
              "operator": "!=",
              "value": "3"
            }
          ]
        }
      }
    },
    {
      "name": "Email Template Assignment Form",
      "entity_name": "email_template_assignment_form",
      "entity_type": "form_builder_module",
      "primary_table": "email_template_assignments",
      "form_information": {
        "model": {
          "email_template_process": {
            "email_template_process_id": null
          },
          "email_template_assignments": [
            null
          ]
        },
        "fields": [
          {
            "key": "email_template_process",
            "wrappers": [
              "form-field"
            ],
            "fieldGroup": [
              {
                "key": "email_template_process_id",
                "type": "select-from-db",
                "templateOptions": {
                  "label": "Email template process",
                  "table": "email_template_process",
                  "readonly": true,
                  "required": true,
                  "labelColumn": "name",
                  "placeholder": "Please select",
                  "valueColumn": "id"
                }
              }
            ],
            "fieldGroupClassName": "grid grid-cols-1 gap-2 md:grid-cols-2"
          },
          {
            "key": "email_template_assignments",
            "type": "repeat",
            "props": {
              "limit": 3,
              "addText": "Add",
              "removeText": "Remove"
            },
            "wrappers": [
              "form-field"
            ],
            "fieldArray": {
              "fieldGroup": [
                {
                  "key": "recipient_type",
                  "type": "select",
                  "props": {
                    "label": "Recipient Type",
                    "options": [
                      {
                        "label": "Tag",
                        "value": "tag"
                      },
                      {
                        "label": "User",
                        "value": "user_id"
                      },
                      {
                        "label": "Custom Mail",
                        "value": "custom"
                      }
                    ],
                    "required": true,
                    "placeholder": "Please select"
                  }
                },
                {
                  "key": "email_to",
                  "type": "select",
                  "hooks": {
                    "onInit": true
                  },
                  "props": {
                    "label": "Email Tag",
                    "required": true,
                    "placeholder": "Please select tag"
                  },
                  "className": "hidden",
                  "expressionProperties": {
                    "className": "(!model?.recipient_type || model?.recipient_type === 'tag') ? 'visible-class' : 'hidden'",
                    "templateOptions.required": "model?.recipient_type === 'tag'"
                  }
                },
                {
                  "key": "email_to",
                  "type": "async-select-from-db",
                  "props": {
                    "label": "User Email",
                    "table": "users",
                    "required": true,
                    "labelColumn": "email",
                    "placeholder": "Search user email",
                    "valueColumn": "email"
                  },
                  "expressionProperties": {
                    "className": "model?.recipient_type !== 'user_id' ? 'hidden' : 'visible-class'",
                    "templateOptions.required": "model?.recipient_type === 'user_id'"
                  }
                },
                {
                  "key": "email_to",
                  "type": "input",
                  "props": {
                    "type": "email",
                    "label": "Email",
                    "required": true,
                    "placeholder": "Enter email address"
                  },
                  "expressionProperties": {
                    "className": "model?.recipient_type === 'custom' ? 'visible-class' : 'hidden'",
                    "templateOptions.required": "model?.recipient_type === 'custom'"
                  }
                },
                {
                  "key": "template_id",
                  "type": "select-from-db",
                  "hooks": {
                    "onInit": true
                  },
                  "props": {
                    "label": "Email Template",
                    "required": true,
                    "placeholder": "Select template"
                  }
                }
              ]
            },
            "fieldGroupClassName": "grid grid-cols-1 gap-2 md:grid-cols-2"
          }
        ],
        "options": {}
      },
      "query_information": {
        "email_to": {
          "company_id": 1,
          "search_all": [
            {
              "value": "1",
              "operator": "=",
              "column_name": "status_id"
            }
          ],
          "limit_range": 1000,
          "print_query": false,
          "start_index": 0,
          "sort_columns": [
            [
              "name",
              "asc"
            ]
          ],
          "primary_table": "email_template_recipient_tags",
          "select_columns": [
            [
              "id::text",
              "value"
            ],
            [
              "name",
              "label"
            ]
          ]
        },
        "template_id": {
          "includes": [
            {
              "join_type": "INNER",
              "table_name": "email_template_process",
              "join_condition": "email_template_process.id = email_templates.email_template_process_id"
            }
          ],
          "company_id": 1,
          "search_all": [
            {
              "value": "1",
              "operator": "=",
              "column_name": "email_templates.status_id"
            },
            {
              "value": "$unique_id",
              "operator": "=",
              "column_name": "email_template_process.uuid"
            }
          ],
          "limit_range": 1000,
          "print_query": false,
          "start_index": 0,
          "sort_columns": [
            [
              "email_templates.name",
              "asc"
            ]
          ],
          "primary_table": "email_templates",
          "select_columns": [
            [
              "email_templates.id",
              "value"
            ],
            [
              "email_templates.name",
              "label"
            ]
          ]
        }
      },
      "add_query_information": null,
      "edit_query_information": {
        "data": {
          "table3": [
            {
              "email_to": "$email_template_assignments.email_to",
              "created_at": true,
              "created_by": true,
              "template_id": "$email_template_assignments.template_id",
              "recipient_type": "$email_template_assignments.recipient_type",
              "email_template_process_id": "@table1.id"
            }
          ]
        },
        "table": [
          "email_template_process",
          "email_template_assignments",
          "email_template_assignments"
        ],
        "action": [
          "select",
          "hard_delete",
          "insert"
        ],
        "columns": {
          "table1": [
            "id"
          ]
        },
        "conditions": {
          "table1": [
            {
              "uuid": "$unique_id"
            }
          ],
          "table2": [
            {
              "email_template_process_id": "@table1.id"
            }
          ]
        },
        "table_mapping": [
          "table1",
          "table2",
          "table3"
        ]
      },
      "preset_query_information": {
        "email_template_process": {
          "company_id": 1,
          "search_all": [
            {
              "value": "$unique_id",
              "operator": "=",
              "column_name": "email_template_process.uuid"
            },
            {
              "value": "3",
              "operator": "!=",
              "column_name": "email_template_process.status_id"
            }
          ],
          "limit_range": 1,
          "print_query": false,
          "start_index": 0,
          "sort_columns": [
            [
              "email_template_process.id",
              "asc"
            ]
          ],
          "primary_table": "email_template_process",
          "select_columns": [
            [
              "id",
              "email_template_process_id"
            ]
          ]
        },
        "email_template_assignments": {
          "includes": [
            {
              "join_type": "INNER",
              "table_name": "email_template_process",
              "join_condition": "email_template_process.id = email_template_assignments.email_template_process_id"
            }
          ],
          "company_id": 1,
          "search_all": [
            {
              "value": "$unique_id",
              "operator": "=",
              "column_name": "email_template_process.uuid"
            },
            {
              "value": "3",
              "operator": "!=",
              "column_name": "email_template_process.status_id"
            }
          ],
          "limit_range": 1000,
          "print_query": false,
          "start_index": 0,
          "sort_columns": [
            [
              "email_template_assignments.id",
              "asc"
            ]
          ],
          "primary_table": "email_template_assignments",
          "select_columns": [
            [
              "email_template_assignments.recipient_type"
            ],
            [
              "email_template_assignments.email_to"
            ],
            [
              "email_template_assignments.template_id"
            ]
          ]
        }
      }
    },
    {
      "name": "wizard_group_form",
      "entity_name": "wizard_group_form",
      "entity_type": "form_builder_module",
      "primary_table": "wizard_group",
      "form_information": {
          "model": {
            "wizard_group": {
              "name": null,
              "slug": null,
              "description":null,
              "status_id": 1
            }
          },
          "fields": [
          {
            "key": "wizard_group",
            "wrappers": [
              "form-field"
            ],
            "fieldGroup": [
            {
              "key": "name",
              "type": "input",
              "props": {
                "label": "Wizard group name",
                "required": true,
                "placeholder": "Enter wizard group name"
              }
            },
            {
              "key": "slug",
              "type": "input",
              "props": {
                "label": "Wizard group slug",
                "required": true,
                "placeholder": "Enter wizard group slug"
              }
            },
            {
              "key": "description",
              "type": "textarea",
              "props": {
                "rows": 3,
                "label": "Description",
                "placeholder": "Enter description"
              }
            },
            {
              "type": "#status"
            }
            ],
            "fieldGroupClassName": "grid grid-cols-1 gap-2 md:grid-cols-3"
          }
          ],
          "options": {}
      },
      "query_information": null,
      "static_page_content": null,
        "add_query_information": {
          "data": {
            "table1": [
              {
                "name": "$wizard_group.name",
                "slug": "$wizard_group.slug",
                "description": "$wizard_group.description",
                "status_id": "$wizard_group.status_id",
                "created_at": true
              }
            ]
          },
          "table": [
            "wizard_group"
          ],
          "action": [
            "insert"
          ],
          "table_mapping": [
            "table1"
          ]
      },
      "edit_query_information": {
          "data": {
            "table1": [
              {
                "name": "$wizard_group.name",
                "slug": "$wizard_group.slug",
                "description": "$wizard_group.description",
                "status_id": "$wizard_group.status_id"
              }
            ]
          },
          "table": [
            "wizard_group"
          ],
          "action": [
            "update"
          ],
          "conditions": {
            "table1": [
              {
                "uuid": "$unique_id"
              }
            ]
          },
          "table_mapping": [
            "table1"
          ]
      },
      "preset_query_information": {
          "wizard_group": {
            "company_id": 1,
            "search_all": [
              {
                "value": "$unique_id",
                "operator": "=",
                "column_name": "wizard_group.uuid"
              },
              {
                "value": "3",
                "operator": "!=",
                "column_name": "wizard_group.status_id"
              }
            ],
            "limit_range": 1,
            "print_query": false,
            "start_index": 0,
            "sort_columns": [
              [
                "wizard_group.id",
                "asc"
              ]
            ],
            "primary_table": "wizard_group",
            "select_columns": [
              [
                "name"
              ],
              [
                "slug"
              ],
              [
                "description"
              ],
              [
                "status_id"
              ]
            ]
          }
        }
    },
    {
      "name": "data_transfer_queries_form",
      "entity_name": "data_transfer_queries_form",
      "entity_type": "form_builder_module",
      "primary_table": "wizard_group",
      "form_information": {
        "model": {
          "data_transfer_queries": {
            "select_query": null,
            "insert_query": null,
            "transfer_type": null,
            "job_name": null,
            "destination_table": null,
            "clear_destination_table": 0,
            "execution_order": null,
            "command_type": null,
            "status_id": 1,
            "slug": null,
            "description": null
          }
        },
        "fields": [
          {
            "key": "data_transfer_queries",
            "wrappers": ["form-field"],
            "fieldGroup": [
              {
                "key": "select_query",
                "type": "textarea",
                "props": {
                  "rows": 3,
                  "label": "Select Query",
                  "required": true,
                  "placeholder": "Enter Select Query"
                }
              },
              {
                "key": "insert_query",
                "type": "textarea",
                "props": {
                  "rows": 3,
                  "label": "Insert Query",
                  "required": true,
                  "placeholder": "Enter Insert Query"
                }
              },
              {
                "key": "transfer_type",
                "type": "select",
                "props": {
                    "label": "Transfer Type",
                    "options": [
                      {
                        "label": "Push",
                        "value": "Push"
                      },
                      {
                        "label": "Pull",
                        "value": "Pull"
                      }
                    ],
                    "required": true,
                    "placeholder": "Please select"
                  }
              },
              {
                "key": "job_name",
                "type": "input",
                "props": {
                  "label": "Job Name",
                  "required": true,
                  "placeholder": "Enter Job Name"
                }
              },
              {
                "key": "destination_table",
                "type": "input",
                "props": {
                  "label": "Destination Table",
                  "required": true,
                  "placeholder": "Enter Destination Table"
                }
              },
              {
                "key": "clear_destination_table",
                "type": "checkbox",
                "props": {
                  "label": "Clear Destination Table",
                  "required": false
                }
              },
              {
                "key": "execution_order",
                "type": "input",
                "props": {
                  "type":"number",
                  "label": "Execution Order",
                  "required": true,
                  "placeholder": "Enter Execution Order"
                }
              },
              {
                "key": "command_type",
                "type": "input",
                "props": {
                  "label": "Command Type",
                  "required": true,
                  "placeholder": "Enter Command Type"
                }
              },
              
              {
                "type": "#status" 
              }
            ],
            "fieldGroupClassName": "grid grid-cols-1 gap-2 md:grid-cols-3"
          }
        ],
        "options": {}
      }
      ,
      "query_information": null,
      "static_page_content": null,
        "add_query_information": {
          "data": {
            "table1": [
              {
                "select_query": "$data_transfer_queries.select_query",
                "insert_query": "$data_transfer_queries.insert_query",
                "transfer_type": "$data_transfer_queries.transfer_type",
                "job_name": "$data_transfer_queries.job_name",
                "destination_table": "$data_transfer_queries.destination_table",
                "clear_destination_table": "$data_transfer_queries.clear_destination_table",
                "execution_order": "$data_transfer_queries.execution_order",
                "command_type": "$data_transfer_queries.command_type",
                "status_id": "$data_transfer_queries.status_id"
              }
            ]
          },
          "table": [
            "data_transfer_queries"
          ],
          "action": [
            "insert"
          ],
          "table_mapping": [
            "table1"
          ]
        }
        ,
      "edit_query_information": {
        "data": {
          "table1": [
            {
              "select_query": "$data_transfer_queries.select_query",
              "insert_query": "$data_transfer_queries.insert_query",
              "transfer_type": "$data_transfer_queries.transfer_type",
              "job_name": "$data_transfer_queries.job_name",
              "destination_table": "$data_transfer_queries.destination_table",
              "clear_destination_table": "$data_transfer_queries.clear_destination_table",
              "execution_order": "$data_transfer_queries.execution_order",
              "command_type": "$data_transfer_queries.command_type",
              "status_id": "$data_transfer_queries.status_id"
            }
          ]
        },
        "table": [
          "data_transfer_queries"
        ],
        "action": [
          "update"
        ],
        "conditions": {
          "table1": [
            {
              "uuid": "$unique_id"
            }
          ]
        },
        "table_mapping": [
          "table1"
        ]
      }
      ,
      "preset_query_information": {
        "data_transfer_queries": {
          "company_id": 1,
          "search_all": [
            {
              "value": "$unique_id",
              "operator": "=",
              "column_name": "data_transfer_queries.uuid"
            },
            {
              "value": "3",
              "operator": "!=",
              "column_name": "data_transfer_queries.status_id"
            }
          ],
          "limit_range": 1,
          "print_query": false,
          "start_index": 0,
          "sort_columns": [
            [
              "data_transfer_queries.id",
              "asc"
            ]
          ],
          "primary_table": "data_transfer_queries",
          "select_columns": [
            [
              "select_query"
            ],
            [
              "insert_query"
            ],
            [
              "transfer_type"
            ],
            [
              "job_name"
            ],
            [
              "destination_table"
            ],
            [
              "clear_destination_table"
            ],
            [
              "execution_order"
            ],
            [
              "command_type"
            ],
            [
              "status_id"
            ]
          ]
        }
      }
      
    },
    {
      "name": "menu_mangement_form",
      "entity_name": "menu_mangement_form",
      "entity_type": "form_builder_module",
      "primary_table": "menu",
      "form_information": {
        "model": {
          "menu": {
            "name": null,
            "slug": null,
            "description":null,
            "status_id": 1,
            "menu_type_id": null
          }
        },
        "fields": [
          {
            "key": "menu",
            "wrappers": [
              "form-field"
            ],
            "fieldGroup": [
            {
              "key": "name",
              "type": "input",
              "props": {
              "label": "Menu name",
              "required": true,
              "placeholder": "Enter menu name"
              }
            },
            {
              "key": "slug",
              "type": "input",
              "props": {
              "label": "Menu slug",
              "required": true,
              "placeholder": "Enter menu slug"
              }
            },
            {
              "key": "menu_type_id",
              "type": "select",
              "hooks": {
              "onInit": true
              },
              "props": {
              "label": "Menu type"
              }
            },
            {
              "key": "description",
              "type": "textarea",
              "props": {
                "rows": 3,
                "label": "Description",
                "placeholder": "Enter description"
              }
            },
            {
              "type": "#status"
            }
            ],
            "fieldGroupClassName": "grid grid-cols-1 gap-2 md:grid-cols-3"
          }
        ],
        "options": {}
      },
      "query_information": {
        "menu_type_id": {
          "company_id": 1,
          "search_all": [
            {
              "value": "1",
              "operator": "=",
              "column_name": "menu_types.status_id"
            }
          ],
          "limit_range": 1000,
          "print_query": false,
          "start_index": 0,
          "sort_columns": [
            [
              "menu_types.name",
              "asc"
            ]
          ],
          "primary_table": "menu_types",
          "select_columns": [
            [
              "id",
              "value"
            ],
            [
              "name",
              "label"
            ]
          ]
        }
      },
      "static_page_content": null,
      "add_query_information": {
        "data": {
          "table1": [
            {
              "name": "$menu.name",
              "slug": "$menu.slug",
              "menu_type": "$menu.menu_type_id",
              "description": "$menu.description",
              "status_id": "$menu.status_id",
              "created_at": true,
              "created_by": true,
              "updated_at": true,
              "updated_by": true
            }
          ]
        },
        "table": [
          "menu"
        ],
        "action": [
          "insert"
        ],
        "table_mapping": [
          "table1"
        ]
      },
      "edit_query_information": {
        "data": {
          "table1": [
            {
              "name": "$menu.name",
              "slug": "$menu.slug",
              "menu_type": "$menu.menu_type_id",
              "description": "$menu.description",
              "status_id": "$menu.status_id",
              "updated_at": true,
              "updated_by": true
            }
          ]
        },
        "table": [
          "menu"
        ],
        "action": [
          "update"
        ],
        "conditions": {
          "table1": [
            {
              "uuid": "$unique_id"
            }
          ]
        },
        "table_mapping": [
          "table1"
        ]
      },
      "preset_query_information": {
        "menu": {
          "company_id": 1,
          "search_all": [
            {
              "value": "$unique_id",
              "operator": "=",
              "column_name": "menu.uuid"
            },
            {
            "value": "3",
            "operator": "!=",
            "column_name": "menu.status_id"
            }
          ],
          "limit_range": 1,
          "print_query": false,
          "start_index": 0,
          "sort_columns": [
            [
              "menu.id",
              "asc"
            ]
          ],
          "primary_table": "menu",
          "select_columns": [
            [
              "name"
            ],
            [
              "slug"
            ],
            [
              "description"
            ],
            [
              "menu_type",
              "menu_type_id"
            ],
            [
              "status_id"
            ]
          ]
        }
      }
    },
    {
      "name": "document_sequences_form",
      "entity_name": "document_sequences_form",
      "entity_type": "form_builder_module",
      "primary_table": "document_sequences",
      "form_information": {
        "options": {},
        "model": {
          "document_sequences": {
            "module_name": "",
            "financial_year_id": null,
            "current_sequence_no": "",
            "start_sequence_no": "",
            "end_sequence_no": "",
            "sequence_length": "",
            "code_format": "TEST{{current_sequence}}",
            "status_id": 1
          }
        },
        "fields": [
          {
            "key": "document_sequences",
            "wrappers": [
              "form-field"
            ],
            "fieldGroupClassName": "grid grid-cols-1 gap-2 md:grid-cols-2",
            "fieldGroup": [
              {
                "key": "module_name",
                "type": "input",
                "props": {
                  "label": "Module Name",
                  "placeholder": "Enter module_name",
                  "required": true
                }
              },
              {
                "key": "financial_year_id",
                "type": "select-from-db",
                "templateOptions": {
                  "label": "Financial year",
                  "table": "financial_years",
                  "required": false,
                  "labelColumn": "code",
                  "placeholder": "Please select",
                  "valueColumn": "id",
                  "search_all": [
                    {
                      "value": "3",
                      "operator": "!=",
                      "column_name": "status_id"
                    }
                  ]
                }
              },
              {
                "key": "current_sequence_no",
                "type": "input",
                "props": {
                  "label": "Current Sequence No",
                  "placeholder": "Enter Current Sequence No",
                  "type": "number",
                  "min": 0,
                  "required": true
                }
              },     
              {
                "key": "start_sequence_no",
                "type": "input",
                "props": {
                  "label": "Start Sequence No",
                  "placeholder": "Enter Start Sequence No",
                  "type": "number",
                  "min": 0,
                  "required": true
                }
              },  
              {
                "key": "end_sequence_no",
                "type": "input",
                "props": {
                  "label": "End Sequence No",
                  "placeholder": "Enter End Sequence No",
                  "type": "number",
                  "min": 0,
                  "required": true
                }
              },  
              {
                "key": "sequence_length",
                "type": "input",
                "props": {
                  "label": "Sequence Length",
                  "placeholder": "Enter Sequence Length",
                  "type": "number",
                  "min": 6,
                  "required": true
                }
              },           
              {
                "key": "code_format",
                "type": "input",
                "props": {
                  "label": "Code Format",
                  "placeholder": "Enter Code Format",
                  "required": true
                }
              },
              {
                "type": "#status"
              }
            ]
          }
        ]
      },
      "query_information": null,
      "add_query_information": {
        "data": {
          "table1": [
            {
              "module_name": "$document_sequences.module_name",
              "current_sequence_no": "$document_sequences.current_sequence_no",
              "end_sequence_no": "$document_sequences.end_sequence_no",
              "sequence_length": "$document_sequences.sequence_length",
              "code_format": "$document_sequences.code_format",
              "financial_year_id": "$document_sequences.financial_year_id",
              "start_sequence_no": "$document_sequences.start_sequence_no",
              "status_id": "$document_sequences.status_id",
              "created_at": true,
              "created_by": true,
              "updated_at": true,
              "updated_by": true
            }
          ]
        },
        "table": [
          "document_sequences"
        ],
        "action": [
          "insert"
        ],
        "table_mapping": [
          "table1"
        ]
      },
      "edit_query_information": {
        "data": {
          "table1": [
            {
              "module_name": "$document_sequences.module_name",
              "current_sequence_no": "$document_sequences.current_sequence_no",
              "end_sequence_no": "$document_sequences.end_sequence_no",
              "sequence_length": "$document_sequences.sequence_length",
              "code_format": "$document_sequences.code_format",
              "financial_year_id": "$document_sequences.financial_year_id",
              "start_sequence_no": "$document_sequences.start_sequence_no",
              "status_id": "$document_sequences.status_id",
              "updated_at": true,
              "updated_by": true
            }
          ]
        },
        "conditions": {
          "table1": [
            {
              "uuid": "$unique_id"
            }
          ]
        },
        "table": [
          "document_sequences"
        ],
        "action": [
          "update"
        ],
        "table_mapping": [
          "table1"
        ]
      },
      "preset_query_information": {
        "document_sequences": {
          "company_id": 1,
          "print_query": false,
          "primary_table": "document_sequences",
          "start_index": 0,
          "limit_range": 1,
          "sort_columns": [
            [
              "document_sequences.id",
              "asc"
            ]
          ],
          "select_columns": [
            [
              "module_name"
            ],
            [
              "current_sequence_no"
            ],
            [
              "end_sequence_no"
            ],
            [
              "sequence_length"
            ],
            [
              "code_format"
            ],
            [
              "financial_year_id"
            ],
            [
              "start_sequence_no"
            ],
            [
              "status_id"
            ]
          ],
          "search_all": [
            {
              "column_name": "document_sequences.uuid",
              "operator": "=",
              "value": "$unique_id"
            },
            {
              "column_name": "document_sequences.status_id",
              "operator": "!=",
              "value": "3"
            }
          ]
        }
      }
    },
    {
      "name": "financial_years_form",
      "entity_name": "financial_years_form",
      "entity_type": "form_builder_module",
      "primary_table": "financial_years",
      "form_information": {
        "options": {},
        "model": {
          "financial_years": {
            "name": "",
            "code": "",
            "is_freezed": false,
            "start_date": "",
            "end_date": "",
            "status_id": 1
          }
        },
        "fields": [
          {
            "key": "financial_years",
            "wrappers": [
              "form-field"
            ],
            "fieldGroupClassName": "grid grid-cols-1 gap-2 md:grid-cols-2",
            "fieldGroup": [
              {
                "key": "name",
                "type": "input",
                "props": {
                  "label": "Name",
                  "placeholder": "Enter name",
                  "required": true
                }
              },
              {
                "key": "code",
                "type": "input",
                "props": {
                  "label": "Code",
                  "placeholder": "Enter code",
                  "required": true
                }
              },
              {
                "key": "start_date",
                "type": "input",
                "props": {
                  "label": "Start Date",
                  "placeholder": "Enter start date",
                  "type": "datetime-local",
                  "required": true
                }
              },
              {
                "key": "end_date",
                "type": "input",
                "props": {
                  "label": "End Date",
                  "placeholder": "Enter start date",
                  "type": "datetime-local",
                  "required": true
                }
              },
              {
                "key": "is_freezed",
                "type": "checkbox",
                "props": {
                  "label": "Is Freezed",
                  "required": false
                }
              },
              {
                "type": "#status"
              }
            ]
          }
        ]
      },
      "query_information": null,
      "add_query_information": {
        "data": {
          "table1": [
            {
              "name": "$financial_years.name",
              "code": "$financial_years.code",
              "is_freezed": "$financial_years.is_freezed",
              "start_date": "$financial_years.start_date",
              "end_date": "$financial_years.end_date",
              "status_id": "$financial_years.status_id",
              "created_at": true,
              "created_by": true,
              "updated_at": true,
              "updated_by": true
            }
          ]
        },
        "table": [
          "financial_years"
        ],
        "action": [
          "insert"
        ],
        "table_mapping": [
          "table1"
        ]
      },
      "edit_query_information": {
        "data": {
          "table1": [
            {
              "name": "$financial_years.name",
              "code": "$financial_years.code",
              "is_freezed": "$financial_years.is_freezed",
              "start_date": "$financial_years.start_date",
              "end_date": "$financial_years.end_date",
              "status_id": "$financial_years.status_id",
              "updated_at": true,
              "updated_by": true
            }
          ]
        },
        "conditions": {
          "table1": [
            {
              "uuid": "$unique_id"
            }
          ]
        },
        "table": [
          "financial_years"
        ],
        "action": [
          "update"
        ],
        "table_mapping": [
          "table1"
        ]
      },
      "preset_query_information": {
        "financial_years": {
          "company_id": 1,
          "print_query": false,
          "primary_table": "financial_years",
          "start_index": 0,
          "limit_range": 1,
          "sort_columns": [
            [
              "financial_years.id",
              "asc"
            ]
          ],
          "select_columns": [
            [
              "name"
            ],
            [
              "status_id"
            ],
            [
              "code"
            ],
            [
              "is_freezed"
            ],
            [
              "TO_CHAR(start_date, 'YYYY-MM-DD\"T\"HH24:MI')", "start_date"
            ],
            [
              "TO_CHAR(end_date, 'YYYY-MM-DD\"T\"HH24:MI')", "end_date"
            ]
          ],
          "search_all": [
            {
              "column_name": "financial_years.uuid",
              "operator": "=",
              "value": "$unique_id"
            },
            {
              "column_name": "financial_years.status_id",
              "operator": "!=",
              "value": "3"
            }
          ]
        }
      }
    }
]
