{
	"name": "form/nc/nc-document/query/4d/query_init_orig.json",
	"info": "code uses this: form/nc/nc-document/document-type-permission.json",
	"data_query": [
		{
			"tag": "sales_order_row_qry",
			"query": "form/nc/nc-document/query/4d/document_query_sales_order_row.json"
		},
		{
			"run": [["parameter.product2", "=", ["reduce", ["arrayFirstKey", "data.sales_order_row_qry.data", "pr.product_id", ""]]]]
		},
		{
			"run": [["if", ["parameter.product2", "<>", ""], [["parameter.product", "=", "parameter.product2"]]]]
		},
		{
			"run": [["parameter.link1", "=", ["map", ["documentLink1", "data.sales_order_row_qry.data", "ordr.record_id", "sor_"]]]]
		},
		{
			"tag": "sales_order_row",
			"column": "form/nc/nc-document/query/4d/document_column.json",
			"query": "form/nc/nc-document/query/4d/document_query_link1.json"
		},
		{
			"run": [["parameter.link1", "=", ["map", ["documentLink1", "data.sales_order_row_qry.data", "ord.record_id", "so_"]]]]
		},
		{
			"tag": "sales_order",
			"column": "form/nc/nc-document/query/4d/document_column.json",
			"query": "form/nc/nc-document/query/4d/document_query_link1.json"
		},
		{
			"run": [["parameter.link1", "=", ["map", ["documentLink1", "data.sales_order_row_qry.data", "co.record_id", "co_"]]]]
		},
		{
			"tag": "company_so",
			"column": "form/nc/nc-document/query/4d/document_column.json",
			"query": "form/nc/nc-document/query/4d/document_query_link1.json"
		},
		{
			"tag": "sales_order_qry",
			"query": "form/nc/nc-document/query/4d/document_query_sales_order.json"
		},
		{
			"run": [["parameter.link1", "=", ["map", ["documentLink1", "data.sales_order_qry.data", "ord.record_id", "so_"]]]]
		},
		{
			"tag": "sales_order2",
			"column": "form/nc/nc-document/query/4d/document_column.json",
			"query": "form/nc/nc-document/query/4d/document_query_link1.json"
		},
		{
			"run": [["parameter.link1", "=", ["map", ["documentLink1", "data.sales_order_qry.data", "co.record_id", "co_"]]]]
		},
		{
			"tag": "company_so2",
			"column": "form/nc/nc-document/query/4d/document_column.json",
			"query": "form/nc/nc-document/query/4d/document_query_link1.json"
		},
		{
			"tag": "product_name_qry",
			"query": "query/local/product/product/product/product_id.json"
		},
		{
			"run": [["parameter.link1", "=", ["map", ["documentLink1", "data.product_name_qry.data", "co.record_id", "co_"]]]]
		},
		{
			"tag": "company_pr",
			"column": "form/nc/nc-document/query/4d/document_column.json",
			"query": "form/nc/nc-document/query/4d/document_query_link1.json"
		},
		{
			"run": [["parameter.link1", "=", ["map", ["documentLink1", "data.product_name_qry.data", "pr.record_id", "w_"]]]]
		},
		{
			"tag": "work_pr",
			"column": "form/nc/nc-document/query/4d/document_column.json",
			"query": "form/nc/nc-document/query/4d/document_query_link1.json"
		},
		{
			"tag": "work_order_qry",
			"query": "form/nc/nc-document/query/4d/document_query_work_order.json"
		},
		{
			"run": [["parameter.link1", "=", ["map", ["documentLink1", "data.work_order_qry.data", "pro.record_id", "wo_"]]]]
		},
		{
			"tag": "work_order",
			"column": "form/nc/nc-document/query/4d/document_column.json",
			"query": "form/nc/nc-document/query/4d/document_query_link1.json"
		},
		{
			"run": [["parameter.link1", "=", ["map", ["documentLink1", "data.work_order_qry.data", "ord.record_id", "so_"]]]]
		},
		{
			"tag": "sales_order_wo",
			"column": "form/nc/nc-document/query/4d/document_column.json",
			"query": "form/nc/nc-document/query/4d/document_query_link1.json"
		},
		{
			"run": [["parameter.link1", "=", ["map", ["documentLink1", "data.work_order_qry.data", "co.record_id", "co_"]]]]
		},
		{
			"tag": "company_wo",
			"column": "form/nc/nc-document/query/4d/document_column.json",
			"query": "form/nc/nc-document/query/4d/document_query_link1.json"
		},
		{
			"tag": "reclamation_wo_qry",
			"query": "form/nc/nc-document/query/4d/document_query_reclamation_wo.json"
		},
		{
			"run": [["parameter.link1", "=", ["map", ["documentLink1", "data.reclamation_wo_qry.data", "rcl.record_id", "rcl_"]]]]
		},
		{
			"tag": "reclamation_wo",
			"column": "form/nc/nc-document/query/4d/document_column.json",
			"query": "form/nc/nc-document/query/4d/document_query_link1.json"
		},
		{
			"run": [["parameter.link1", "=", ["map", ["documentLink1", "data.product_name_qry.data", "pr.record_id", "pr_"]]]]
		}
	],
	"data_query_future": [
		{
			"run": [["parameter.link1", "=", ["map", ["documentLink1", "data.work_order_so.data", "ord.record_id", "so_"]]]]
		},
		{
			"tag": "work_order_so_wo",
			"column": "form/nc/nc-document/query/4d/document_column.json",
			"query": "form/nc/nc-document/query/4d/document_query_link1.json"
		},
		{
			"run": [["parameter.link1", "=", ["map", ["documentLink1", "data.work_order_so.data", "co.record_id", "co_"]]]]
		},
		{
			"tag": "work_order_so_wo",
			"column": "form/nc/nc-document/query/4d/document_column.json",
			"query": "form/nc/nc-document/query/4d/document_query_link1.json"
		},
		{
			"run": [["parameter.link1", "=", ["concat", ["'sor_", "parameter.sales_order_row", "'"]]]]
		},
		{
			"tag": "reclamation_wo",
			"column": "form/nc/nc-document/query/4d/document_column.json",
			"query": "form/nc/nc-document/query/4d/document_query_link1.json"
		},
		{
			"tag": "reclamation_so",
			"query": "form/nc/nc-document/query/4d/document_query_reclamation_so.json"
		},
		{
			"run": [["parameter.link1", "=", ["map", ["documentLink1", "data.reclamation_so.data", "rcl.record_id", "rcl_"]]]]
		},
		{
			"tag": "reclamation_so",
			"column": "form/nc/nc-document/query/4d/document_column.json",
			"query": "form/nc/nc-document/query/4d/document_query_link1.json"
		},
		{
			"tag": "work_order_so",
			"query": "form/nc/nc-document/query/4d/document_query_work_order_so.json"
		},
		{
			"run": [["parameter.link1", "=", ["map", ["documentLink1", "data.work_order_so.data", "pro.record_id", "wo_"]]]]
		},
		{
			"tag": "work_order_so",
			"column": "form/nc/nc-document/query/4d/document_column.json",
			"query": "form/nc/nc-document/query/4d/document_query_link1.json"
		},
		{
			"run": [["parameter.link1", "=", ["map", ["documentLink1", "data.work_order_so.data", "pr.record_id", "w_"]]]]
		},
		{
			"tag": "work_so",
			"column": "form/nc/nc-document/query/4d/document_column.json",
			"query": "form/nc/nc-document/query/4d/document_query_link1.json"
		},
		{
			"run": [["parameter.link1", "=", ["map", ["documentLink1", "data.work_order_qry.data", "pr.record_id", "w_"]]]]
		},
		{
			"tag": "work_wo",
			"column": "form/nc/nc-document/query/4d/document_column.json",
			"query": "form/nc/nc-document/query/4d/document_query_link1.json"
		}
	],
	"grid": [
		{
			"name": "document",
			"column": "form/nc/nc-document/query/4d/document_column.json",
			"query": "form/nc/nc-document/query/4d/document_query_link1.json"
		}
	],
	"rec": "form/nc/nc-document/rec.json"
}
