source: main/trunk/docs/devel/publication.rst @ 1188

Revision 1188, 3.2 KB checked in by pcosquer, 7 years ago (diff)

docs: publications

Publication

System Message: ERROR/3 (<string>, line 7)

Unknown directive type "versionadded".

.. versionadded:: 1.1

This document describes how the :doc:`Publication specification </specs/publication>` is implemented.

System Message: ERROR/3 (<string>, line 9); backlink

Unknown interpreted text role "doc".

Publishers

A new boolean field :attr:`.UserProfile.can_publish` is added to each :class:`.UserProfile`. By default, this field is set to False. If this field is set to True, the user can publish an object (if all other rules are respected).

System Message: ERROR/3 (<string>, line 15); backlink

Unknown interpreted text role "attr".

System Message: ERROR/3 (<string>, line 15); backlink

Unknown interpreted text role "class".

The migration :file:`plmapp/migrations/0014_auto__add_field_userprofile_can_publish.py` adds this field (set to False) to all existing users.

System Message: ERROR/3 (<string>, line 20); backlink

Unknown interpreted text role "file".

This field is neither a creation field nor a modification field. Only an admin can modify this field via the admin interface.

Model

PLMObject

A new boolean field :attr:`.PLMObject.published` is added to each :class:`.PLMObject`. By default, this field is set to False. If this field is set to True, it means the object has been published and is accessible to anonymous users.

System Message: ERROR/3 (<string>, line 32); backlink

Unknown interpreted text role "attr".

System Message: ERROR/3 (<string>, line 32); backlink

Unknown interpreted text role "class".

The migration :file:`plmapp/migrations/0015_auto__add_field_plmobject_published.py` adds this field (set to False) to all existing plmobjects.

System Message: ERROR/3 (<string>, line 37); backlink

Unknown interpreted text role "file".

A new property named :attr:`.PLMObject.published_attributes` returns the list of published attributes. By default, it returns the following attributes:

System Message: ERROR/3 (<string>, line 41); backlink

Unknown interpreted text role "attr".
  1. type
  2. reference
  3. revision
  4. name

This property can be overriden by a custom model to add more attributes.

History

All publication and unpublication are stored in the :class:`.History` table.

System Message: ERROR/3 (<string>, line 55); backlink

Unknown interpreted text role "class".

A publication is stored with the :attr:`.AbstractHistory.action` field set to Publish.

System Message: ERROR/3 (<string>, line 57); backlink

Unknown interpreted text role "attr".

A unpublication is stored with the :attr:`.AbstractHistory.action` field set to Unpublish.

System Message: ERROR/3 (<string>, line 60); backlink

Unknown interpreted text role "attr".

Controller

Publishing a document

Methods

The following methods are available to publish a PLMObject and test if a PLMObject can be published:

Tests

Unpublishing a document

Methods

The following methods are available to unpublish a PLMObject and test if a PLMObject can be unpublished:

Tests

Views

Lifecycle

Tests

Public

Tests

Public download

Browse

Templates

public.html

browse.html

Note: See TracBrowser for help on using the repository browser.