View Reference¶
The views.security
Module¶
Security view callables.
-
publiforge.views.security.
login
(request)[source]¶ This view renders a login form and processes the post checking credentials.
The views.maintenance
Module¶
Maintenance view callables.
-
publiforge.views.maintenance.
mainatenance_view
(request)[source]¶ Maintenance view.
Parameters: request (pyramid.request.Request) – Current request.
The views.home
Module¶
Home view callables.
The views.user
Module¶
User view callables.
The views.selection
Module¶
Selection view callables.
-
class
publiforge.views.selection.
Selection
(request)[source]¶ User selection management.
The views.group
Module¶
Group view callables.
The views.storage
Module¶
Storage view callables.
The views.indexer
Module¶
Indexer view callables.
The views.file
Module¶
File view callables.
-
class
publiforge.views.file.
FileView
(request)[source]¶ Class to manage files in a storage.
-
search
()[source]¶ Search files in storages.
session['search']
is a dictionary with the following keys:scope
,inputs
,columns
andresult
.
Display the next or previous file of the same type in the same directory.
Display the next or previous file in the search results.
-
The views.project
Module¶
Project view callables.
The views.processing
Module¶
Processing view callables.
The views.role
Module¶
Role view callables.
The views.task
Module¶
Task view callables.
The views.pack
Module¶
Pack view callables.
The views.site
Module¶
Site view callables.
The views.build
Module¶
Build view callables.
The views.maestro
Module¶
These XML-RPC functions are called by Maestro client.
-
publiforge.views.maestro.
storages
(request, context, with_index=True)[source]¶ Return a list of available storages.
Parameters: - request – (
pyramid.request.Request
instance) Current request. - context – (dictionary) A context for authentication.
- with_index – (boolean, default=True)
If
True
select only storages with indexed files.
Returns: (tuple)
(error, result)
- request – (
-
publiforge.views.maestro.
indexes
(request, context)[source]¶ Return a list of available indexes.
Parameters: - request – (
pyramid.request.Request
instance) Current request. - context – (dictionary) A context for authentication.
Returns: (tuple)
(error, result)
- request – (
-
publiforge.views.maestro.
search
(request, context, scope, query, limit)[source]¶ Return the result of a search limited to
limit
lines.Parameters: - request – (
pyramid.request.Request
instance) Current request. - context – (dictionary) A context for authentication.
Returns: (tuple)
(error, result)
- request – (
-
publiforge.views.maestro.
file_info
(request, context, filename)[source]¶ Return date and size of file
filename
.Parameters: - request – (
pyramid.request.Request
instance) Current request. - context – (dictionary) A context for authentication.
- filename – (string) Relative path of file to search.
Returns: (tuple)
(error, result)
where result is a tuple like(file_mtime, file_size)
.- request – (
-
publiforge.views.maestro.
file_download
(request, context, filename)[source]¶ Download file
filename
.Parameters: - request – (
pyramid.request.Request
instance) Current request. - context – (dictionary) A context for authentication.
- filename – (string) Relative path of file to search.
Returns: (tuple)
(error, result)
- request – (
-
publiforge.views.maestro.
pack_info
(request, context, content, project_label)[source]¶ Return date and size of all files of a pack.
Parameters: - request – (
pyramid.request.Request
instance) Current request. - context – (dictionary) A context for authentication.
- content – (
xmlrpclib.Binary
instance) Content of pack settings. - project_label – (string) Label of the project to use.
Returns: (tuple)
(error, result)
whereresult
is a tuple like(pack_exists, info_list)
.info_list
is a list such as[(file_path, file_mtime, file_size),...]
.- request – (
-
publiforge.views.maestro.
pack_upload
(request, context, content, project_label, message)[source]¶ Upload a pack inot the project
project
.Parameters: - request – (
pyramid.request.Request
instance) Current request. - context – (dictionary) A context for authentication.
- content – (
xmlrpclib.Binary
instance) Content of the pack. - project_label – (string) Label of the project to use.
- message – (string) Message for commit operation.
Returns: (tuple)
(error, result)
- request – (
-
publiforge.views.maestro.
build
(request, context, project_label, pack_label, processing_label)[source]¶ Upload a pack inot the project
project
.Parameters: - request – (
pyramid.request.Request
instance) Current request. - context – (dictionary) A context for authentication.
- project_label – (string) Label of the project to use.
- pack_label – (string) Label of the pack to use.
- processing_label – (string) Label of the processing to use.
Returns: (tuple)
(error, result)
- request – (
-
publiforge.views.maestro.
build_log
(request, context, build_id)[source]¶ Send log of build
build_id
.Parameters: - request – (
pyramid.request.Request
instance) Current request. - context – (dictionary) A context for authentication.
- build_id – (string) ID of build to retrieve.
Returns: (tuple)
(error, result)
- request – (
-
publiforge.views.maestro.
results
(request, context, project_label)[source]¶ Upload a pack inot the project
project
.Parameters: - request – (
pyramid.request.Request
instance) Current request. - context – (dictionary) A context for authentication.
- project_label – (string) Label of the project to use.
Returns: (tuple)
(error, (working, results))
- request – (
-
publiforge.views.maestro.
result_download
(request, context, build_id)[source]¶ Download result of build
build_id
.Parameters: - request – (
pyramid.request.Request
instance) Current request. - context – (dictionary) A context for authentication.
- build_id – (string) ID of build to retrieve.
Returns: (tuple)
(error, result)
- request – (