MCPcopy Index your code
hub / github.com/WebODM/WebODM / app_mount_points

Method app_mount_points

coreplugins/test/plugin.py:33–48  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

31 return ['component.jsx']
32
33 def app_mount_points(self):
34 # Show script only if '?print=1' is set
35 def dynamic_cb(request):
36 if 'print' in request.GET:
37 return {'name': 'WebODM'} # Test template substitution
38 else:
39 return False
40
41 return [
42 MountPoint('/app_mountpoint/$', lambda request: render(request, self.template_path("app.html"), {
43 'title': 'Test',
44 'test_form': TestForm()
45 })),
46 MountPoint('task/(?P<pk>[^/.]+)/', TestTaskView.as_view()),
47 MountPoint('/app_dynamic_script.js$', self.get_dynamic_script('dynamic.js', dynamic_cb))
48 ]
49
50 def get_current_plugin_test(self):
51 return get_current_plugin()

Callers

nothing calls this directly

Calls 4

MountPointClass · 0.90
TestFormClass · 0.85
template_pathMethod · 0.80
get_dynamic_scriptMethod · 0.80

Tested by

no test coverage detected