autowisp.browser_interface.home.create_project_view module
Class Inheritance Diagram

Define the view for creating new AutoWISP projects.
- class autowisp.browser_interface.home.create_project_view.CreateProjectView(**kwargs)[source]
Bases:
WalkFSView
View to create a new AutoWISP project.
- _get_context(config, search_dir)[source]
Return the context required by the home selection template.
- cancel_url_name = 'home:new_project'
The URL name to redirect to when the cancel button is pressed.
- db_fname = 'autowisp.db'
The base filename of the SQLite database tracking all projects.
- get(request, dirname=None)[source]
Display the appropriate project cretion page per the current mode.
The expected arguments depend on the mode:
- mode = 'create_project'
What mode this view is in.
- Possible values:
"select_home": Display the project home director selection page."create_dir": Allow specifying name of directory to create."create_project": Create a new project in the specified directory."change_master_usage": Toggle the
- post(request, *_args, **_kwargs)[source]
Handle POST request to create a new directory.
- Parameters:
request – The HTTP request object.
- template = 'home/create_project.html'
The template used to display the project creation page.
- url_name = 'home:new_project'
The URL name for this view.
- class autowisp.browser_interface.home.create_project_view.MasterConfigView(**kwargs)[source]
Bases:
CreateProjectView
Handle master configuration part of the project creation view.
- get(request, master_type, **kwargs)[source]
Handle a change to the master configuration by the user.
If kwargs is empty, the master is toggled between enabled and disabled. Otherwise, it should contain a single key (
"split"or"match") with a value a single tuple specifying the change:(old expression, new expression). If old expression is None, the corresponding list is extended.