MCPcopy
hub / github.com/diffgram/diffgram / report_info_api

Function report_info_api

default/methods/report/report_view_api.py:48–71  ·  view source on GitHub ↗

Permissions handled by Report_Runner

(report_template_id)

Source from the content-addressed store, hash-verified

46 methods = ['GET'])
47@General_permissions.grant_permission_for(['normal_user'])
48def report_info_api(report_template_id):
49 """
50 Permissions handled by Report_Runner
51 """
52
53 with sessionMaker.session_scope() as session:
54 report_runner = Report_Runner(
55 session = session,
56 member = None,
57 report_template_id = report_template_id
58 )
59
60 if len(report_runner.log["error"].keys()) >= 1:
61 return jsonify(log = report_runner.log), 400
62
63 report_runner.get_existing_report_template(report_template_id)
64
65 report_runner.validate_existing_report_id_permissions()
66
67 report_runner.log['success'] = True
68
69 return jsonify(
70 log = report_runner.log,
71 report_template = report_runner.report_template.serialize()), 200
72

Callers

nothing calls this directly

Calls 4

Report_RunnerClass · 0.85
serializeMethod · 0.45

Tested by

no test coverage detected