def dg(uid, start, end): plan = graph.get_graph(uid) if start or end: errors = filters.filter(plan, start=start, end=end) if errors: raise click.ClickException('\n'.join(errors)) utils.write_graph(plan) click.echo('Created {name}.svg'.format(name=plan.graph['name']))
def dg(uid, start, end): plan = graph.get_graph(uid) if start or end: errors = filters.filter(plan, start=start, end=end) if errors: raise click.ClickException('\n'.join(errors)) utils.write_graph(plan) click.echo('Created {name}.png'.format(name=plan.graph['name']))
def filter(uid, start, end): graph.reset_filtered(uid) plan = graph.get_graph(uid) errors = filters.filter(plan, start=start, end=end) if errors: raise click.ClickException('\n'.join(errors)) graph.update_graph(plan) utils.write_graph(plan) click.echo('Created {name}.png'.format(name=plan.graph['name']))
def filter(uid, start, end): graph.reset_filtered(uid) plan = graph.get_graph(uid) errors = filters.filter(plan, start=start, end=end) if errors: raise click.ClickException('\n'.join(errors)) graph.save_graph(uid, plan) utils.write_graph(plan) click.echo('Created {name}.png'.format(name=plan.graph['name']))