{
	"name": "query/af/document/document_query_work_order.json",
	"database": "4d",
	"parameter": {
		"no_empty_parameter": ["production_order_id"],
		"state": 0,
		"production_order_id": "",
		"subquery": "SELECT SUBSTRING(link2, 4) FROM _link WHERE (link1 = (SELECT CONCAT('wo_', record_id) FROM work_order WHERE production_order_id = '{{production_order_id}}')) AND link2 LIKE 'af_%'"
	},
	"query": [["af_record_id", "in", "subquery"], "and", ["af_state", ">=", "state"]]
}
