Skip to content
This repository has been archived by the owner on Apr 12, 2021. It is now read-only.

Commit

Permalink
http://luc.lino-framework.org/blog/2019/1108.html
Browse files Browse the repository at this point in the history
  • Loading branch information
lsaffre committed Nov 8, 2019
1 parent 8f05a2e commit 7e3cfb3
Show file tree
Hide file tree
Showing 5 changed files with 236 additions and 83 deletions.
12 changes: 6 additions & 6 deletions docs/index.rst
Expand Up @@ -6,12 +6,12 @@ Welcome to the Lino Book, the technical documentation about the :term:`Lino
framework`. For non-technical documentation about Lino see the :ref:`cg`.

This website is meant to be read like a book, in sequence. Use the "next" and
"previous" links for navigation.

This book should be interesting and understandable for any motivated developer
with at least basic knowledge. But it is also *work in progress* and we count
on you as a reader to help us. Please let us know whenever you stumble over a
section that does not seem to satisfy the goal of this book.
"previous" links for navigation. Feel free to jump to linked pages, but don't
get lost into details. The Lino Book should be interesting and understandable
for any motivated Python developer with at least basic knowledge. But it is
only **work in progress** and we count on you as a reader to help us. Please let
us know whenever you stumble over a section that does not satisfy the goal of
this book.


.. toctree::
Expand Down
72 changes: 2 additions & 70 deletions docs/specs/noi/general.rst
Expand Up @@ -35,7 +35,7 @@ But :mod:`lino_xl.lib.tickets` is an independent plugin which might be
reused by other applicaton that have no worktime tracking. Lino Noi
uses them both and extends the "library" version of tickets:

- :mod:`lino_noi.lib.tickets`
- :mod:`lino_noi.lib.tickets`

>>> dd.plugins.working
lino_xl.lib.working
Expand All @@ -51,74 +51,6 @@ lino_noi.lib.tickets (extends_models=['Ticket', 'Site'])



User types
==========

A default Lino Noi site has the following user types:

>>> rt.show(users.UserTypes)
======= ============ ==================
value name text
------- ------------ ------------------
000 anonymous Anonymous
100 user User
200 consultant Consultant
300 hoster Hoster
400 developer Developer
490 senior Senior developer
900 admin Administrator
======= ============ ==================
<BLANKLINE>


A **user** is somebody who uses some part of the software being
developed by the team. This is usually the contact person of a
customer.

A **consultant** is an intermediate agent between end-users and the
team.

A **hoster** is a special kind of customer who installs and maintains
servers where Lino applications run.

A **developer** is somebody who works on tickets by doing code
changes.

A **senior** is a developer who additionaly can triage tickets.

Here is a list of user types of those who can work on tickets:

>>> from lino_xl.lib.working.roles import Worker
>>> UserTypes = rt.models.users.UserTypes
>>> [p.name for p in UserTypes.items()
... if p.has_required_roles([Worker])]
['consultant', 'hoster', 'developer', 'senior', 'admin']

And here are those who don't work:

>>> [p.name for p in UserTypes.items()
... if not p.has_required_roles([Worker])]
['anonymous', 'user']


Users
=====

>>> rt.show('users.UsersOverview')
========== ======================== ==========
Username User type Language
---------- ------------------------ ----------
jean 490 (Senior developer) en
luc 400 (Developer) en
marc 100 (User) en
mathieu 200 (Consultant) en
robin 900 (Administrator) en
rolf 900 (Administrator) de
romain 900 (Administrator) fr
========== ======================== ==========
<BLANKLINE>


Countries
=========

Expand Down Expand Up @@ -153,7 +85,7 @@ Lino Noi and Scrum
- Usually there is at least one ticket per site for planning and
discussion.
- Every backlog item is registered as a ticket on that site
- The detail view of a site is the equivalent of a backlog
- The detail view of a site is the equivalent of a backlog

>>> show_fields(system.SiteConfig)
... #doctest: +REPORT_UDIFF
Expand Down
9 changes: 4 additions & 5 deletions docs/specs/noi/index.rst
Expand Up @@ -25,7 +25,7 @@ This section contains specs for :ref:`noi`.
bs3
export_excel
mailbox

projects
faculties
votes
Expand All @@ -35,17 +35,16 @@ This section contains specs for :ref:`noi`.
sql
cal
suggesters

users



.. currentmodule:: lino_noi.lib.noi

.. module:: lino_noi.lib.noi.workflows

The default :attr:`workflows_module
<lino.core.site.Site.workflows_module>` for :ref:`noi` applications.

This workflow requires that both :mod:`lino_xl.lib.tickets` and
:mod:`lino_xl.lib.votes` are installed.


224 changes: 224 additions & 0 deletions docs/specs/noi/users.rst
@@ -0,0 +1,224 @@
.. doctest docs/specs/noi/users.rst
.. _noi.specs.user:

======================================
``users`` (User management in Noi)
======================================

.. currentmodule:: lino_noi.lib.users

The :mod:`lino_noi.lib.users` plugin extends :mod:`lino_xl.lib.online.users` for
Lino Noi.


.. contents::
:local:

.. include:: /../docs/shared/include/tested.rst

>>> import lino
>>> lino.startup('lino_book.projects.team.settings.demo')
>>> from lino.api.doctest import *


User types
==========

A default Lino Noi site has the following user types:

>>> rt.show(users.UserTypes)
======= ============ ==================
value name text
------- ------------ ------------------
000 anonymous Anonymous
100 user User
200 consultant Consultant
300 hoster Hoster
400 developer Developer
490 senior Senior developer
900 admin Administrator
======= ============ ==================
<BLANKLINE>


A **user** is somebody who uses some part of the software being
developed by the team. This is usually the contact person of a
customer.

A **consultant** is an intermediate agent between end-users and the
team.

A **hoster** is a special kind of customer who installs and maintains
servers where Lino applications run.

A **developer** is somebody who works on tickets by doing code
changes.

A **senior** is a developer who additionaly can triage tickets.

Here is a list of user types of those who can work on tickets:

>>> from lino_xl.lib.working.roles import Worker
>>> UserTypes = rt.models.users.UserTypes
>>> [p.name for p in UserTypes.items()
... if p.has_required_roles([Worker])]
['consultant', 'hoster', 'developer', 'senior', 'admin']

And here are those who don't work:

>>> [p.name for p in UserTypes.items()
... if not p.has_required_roles([Worker])]
['anonymous', 'user']


Users
=====

>>> rt.show('users.UsersOverview')
========== ======================== ==========
Username User type Language
---------- ------------------------ ----------
jean 490 (Senior developer) en
luc 400 (Developer) en
marc 100 (User) en
mathieu 200 (Consultant) en
robin 900 (Administrator) en
rolf 900 (Administrator) de
romain 900 (Administrator) fr
========== ======================== ==========
<BLANKLINE>




User roles and permissions
==========================

Here is the :class:`lino.modlib.users.UserRoles` table for :ref:`noi`:

>>> rt.show(users.UserRoles)
======================== ===== ===== ===== ===== ===== ===== =====
Name 000 100 200 300 400 490 900
------------------------ ----- ----- ----- ----- ----- ----- -----
cal.CalendarReader ☑
comments.CommentsStaff ☑ ☑
comments.CommentsUser ☑ ☑ ☑ ☑ ☑ ☑
contacts.ContactsStaff ☑
contacts.ContactsUser ☑ ☑ ☑ ☑ ☑
core.SiteUser ☑ ☑ ☑ ☑ ☑ ☑
courses.CoursesUser ☑ ☑ ☑ ☑ ☑
excerpts.ExcerptsStaff ☑ ☑
excerpts.ExcerptsUser ☑ ☑ ☑ ☑ ☑
office.OfficeStaff ☑
office.OfficeUser ☑ ☑ ☑ ☑ ☑ ☑
tickets.Reporter ☑ ☑ ☑ ☑ ☑ ☑
tickets.Searcher ☑ ☑ ☑ ☑ ☑ ☑ ☑
tickets.TicketsStaff ☑
tickets.Triager ☑ ☑
users.Helper ☑ ☑ ☑ ☑ ☑
votes.VotesStaff ☑
votes.VotesUser ☑ ☑ ☑ ☑ ☑ ☑
working.Worker ☑ ☑ ☑ ☑ ☑
======================== ===== ===== ===== ===== ===== ===== =====
<BLANKLINE>

The following shows a list of all windows in :ref:`noi` and who can see them:

>>> print(analyzer.show_window_permissions())
- about.About.show : visible for all
- cal.Calendars.detail : visible for admin
- cal.Calendars.insert : visible for admin
- cal.DailyView.detail : visible for user consultant hoster developer senior admin
- cal.EntriesByGuest.insert : visible for user consultant hoster developer senior admin
- cal.EventTypes.detail : visible for admin
- cal.EventTypes.insert : visible for admin
- cal.EventTypes.merge_row : visible for admin
- cal.Events.detail : visible for admin
- cal.Events.insert : visible for admin
- cal.GuestRoles.detail : visible for admin
- cal.GuestRoles.merge_row : visible for admin
- cal.Guests.detail : visible for nobody
- cal.Guests.insert : visible for nobody
- cal.MonthlyView.detail : visible for user consultant hoster developer senior admin
- cal.RecurrentEvents.detail : visible for admin
- cal.RecurrentEvents.insert : visible for admin
- cal.Rooms.detail : visible for admin
- cal.Rooms.insert : visible for admin
- cal.Tasks.detail : visible for admin
- cal.Tasks.insert : visible for admin
- cal.WeeklyView.detail : visible for user consultant hoster developer senior admin
- changes.Changes.detail : visible for admin
- checkdata.Checkers.detail : visible for admin
- checkdata.Problems.detail : visible for user consultant hoster developer senior admin
- comments.CommentTypes.detail : visible for senior admin
- comments.CommentTypes.insert : visible for senior admin
- comments.Comments.detail : visible for user consultant hoster developer senior admin
- comments.Comments.insert : visible for user consultant hoster developer senior admin
- comments.CommentsByRFC.insert : visible for user consultant hoster developer senior admin
- comments.Mentions.detail : visible for senior admin
- contacts.Companies.detail : visible for consultant hoster developer senior admin
- contacts.Companies.insert : visible for consultant hoster developer senior admin
- contacts.Companies.merge_row : visible for admin
- contacts.Partners.merge_row : visible for admin
- contacts.Persons.detail : visible for consultant hoster developer senior admin
- contacts.Persons.insert : visible for consultant hoster developer senior admin
- contacts.Persons.merge_row : visible for admin
- countries.Countries.detail : visible for admin
- countries.Countries.insert : visible for admin
- countries.Places.detail : visible for admin
- excerpts.ExcerptTypes.detail : visible for senior admin
- excerpts.ExcerptTypes.insert : visible for senior admin
- excerpts.Excerpts.detail : visible for consultant hoster developer senior admin
- gfks.ContentTypes.detail : visible for admin
- github.Commits.detail : visible for user consultant hoster developer senior admin
- github.Repositories.detail : visible for admin
- github.Repositories.insert : visible for admin
- groups.Groups.detail : visible for user consultant hoster developer senior admin
- groups.Groups.insert : visible for user consultant hoster developer senior admin
- groups.Groups.merge_row : visible for admin
- groups.Memberships.detail : visible for user consultant hoster developer senior admin
- groups.Memberships.insert : visible for user consultant hoster developer senior admin
- lists.Lists.detail : visible for consultant hoster developer senior admin
- lists.Lists.insert : visible for consultant hoster developer senior admin
- lists.Lists.merge_row : visible for admin
- mailbox.Mailboxes.detail : visible for user consultant hoster developer senior admin
- mailbox.Mailboxes.insert : visible for user consultant hoster developer senior admin
- mailbox.MessageAttachments.detail : visible for user consultant hoster developer senior admin
- mailbox.Messages.detail : visible for user consultant hoster developer senior admin
- system.SiteConfigs.detail : visible for admin
- tickets.Links.detail : visible for admin
- tickets.Sites.detail : visible for user consultant hoster developer senior admin
- tickets.Sites.insert : visible for user consultant hoster developer senior admin
- tickets.Sites.merge_row : visible for admin
- tickets.TicketTypes.detail : visible for admin
- tickets.Tickets.detail : visible for all
- tickets.Tickets.insert : visible for user consultant hoster developer senior admin
- tickets.Tickets.merge_row : visible for admin
- tinymce.TextFieldTemplates.detail : visible for admin
- tinymce.TextFieldTemplates.insert : visible for admin
- uploads.UploadTypes.detail : visible for admin
- uploads.UploadTypes.insert : visible for admin
- uploads.Uploads.detail : visible for user consultant hoster developer senior admin
- uploads.Uploads.insert : visible for user consultant hoster developer senior admin
- uploads.UploadsByController.insert : visible for user consultant hoster developer senior admin
- uploads.Volumes.detail : visible for admin
- uploads.Volumes.insert : visible for admin
- uploads.Volumes.merge_row : visible for admin
- users.AllUsers.send_welcome_email : visible for admin
- users.NewUsers.send_welcome_email : visible for admin
- users.OtherUsers.detail : visible for user consultant hoster developer senior admin
- users.Register.insert : visible for user consultant hoster developer senior admin
- users.Users.change_password : visible for user consultant hoster developer senior admin
- users.Users.detail : visible for user consultant hoster developer senior admin
- users.Users.insert : visible for user consultant hoster developer senior admin
- users.Users.merge_row : visible for admin
- users.Users.verify : visible for user consultant hoster developer senior admin
- users.UsersOverview.sign_in : visible for all
- working.ServiceReports.detail : visible for consultant hoster developer senior admin
- working.ServiceReports.insert : visible for consultant hoster developer senior admin
- working.Sessions.detail : visible for consultant hoster developer senior admin
- working.Sessions.insert : visible for consultant hoster developer senior admin
- working.SiteSummaries.detail : visible for user consultant hoster developer senior admin
- working.UserSummaries.detail : visible for user consultant hoster developer senior admin
- working.WorkedHours.detail : visible for user consultant hoster developer senior admin
<BLANKLINE>
2 changes: 0 additions & 2 deletions docs/welcome.rst
Expand Up @@ -2,8 +2,6 @@
Welcome
=======

This is the technical documentation about the :term:`Lino framework`.

The Lino community welcomes both experienced and newbie Python developers.

Volunteer contributors contact us because they want to
Expand Down

0 comments on commit 7e3cfb3

Please sign in to comment.