env = env # noqa recipe = env['fusion.plating.process.node'].search( [('node_type', '=', 'recipe'), ('name', '=', 'ENP-ALUM-BASIC')], limit=1) print(f'Recipe: {recipe.name}') def walk(node, indent=0): pt = node.process_type_id.process_family if node.process_type_id else '(none)' wc = node.work_center_id.name if node.work_center_id else '(none)' print(f'{" "*indent}- [{node.node_type:9}] {node.name!r:35} pt_family={pt!r:18} wc={wc}') for c in node.child_ids.sorted('sequence'): walk(c, indent+1) walk(recipe)