Skip to content

Commit

Permalink
Merge pull request #150 from colab/mailinglist_page_permissions
Browse files Browse the repository at this point in the history
Mailinglist page permissions
  • Loading branch information
MatheusFaria committed Jan 19, 2016
2 parents 5a7abc1 + d6b3a1f commit 0f5bb53
Show file tree
Hide file tree
Showing 6 changed files with 398 additions and 47 deletions.
273 changes: 273 additions & 0 deletions colab/super_archives/fixtures/mailinglistviewdata.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,273 @@
[
{
"fields": {
"last_name": "Jar",
"webpage": null,
"twitter": null,
"is_staff": false,
"user_permissions": [

],
"date_joined": "2015-02-24T21:10:35.004Z",
"google_talk": null,
"first_name": "John",
"is_superuser": false,
"last_login": "2015-02-26T17:56:13.378Z",
"verification_hash": null,
"role": null,
"email": "johndoe@example.com",
"username": "johndoe",
"bio": null,
"needs_update": false,
"is_active": true,
"facebook": null,
"groups": [

],
"password": "pbkdf2_sha256$12000$ez83ccNOUQZk$vYT/QcYMukXZ7D7L1qQPyYlzCUEEEF20J7/Xjef0Rqg=",
"institution": null,
"github": null,
"modified": "2015-02-24T21:11:22.323Z"
},
"model": "accounts.user",
"pk": 1
},
{
"fields": {
"real_name": "",
"user": 1,
"md5": "ed8f47ae6048f8d4456c0554578f53ff",
"address": "johndoe@example.com"
},
"model": "super_archives.emailaddress",
"pk": 1
},
{
"fields": {
"description": "",
"email": "",
"logo": "",
"last_imported_index": 0,
"is_private": true,
"name": "mailman"
},
"model": "super_archives.mailinglist",
"pk": 1
},
{
"fields": {
"description": "",
"email": "",
"logo": "",
"last_imported_index": 0,
"is_private": false,
"name": "lista"
},
"model": "super_archives.mailinglist",
"pk": 2
},
{
"fields": {
"description": "",
"email": "",
"logo": "",
"last_imported_index": 0,
"is_private": true,
"name": "privatelist"
},
"model": "super_archives.mailinglist",
"pk": 3
},
{
"fields": {
"description": "",
"email": "",
"logo": "",
"last_imported_index": 0,
"is_private": false,
"name": "publiclist"
},
"model": "super_archives.mailinglist",
"pk": 4
},
{
"fields": {
"spam": false,
"subject_token": "Subject1",
"mailinglist": 1,
"score": 34,
"latest_message": 1
},
"model": "super_archives.thread",
"pk": 1
},
{
"fields": {
"spam": false,
"subject_token": "Subject2",
"mailinglist": 2,
"score": 34,
"latest_message": 2
},
"model": "super_archives.thread",
"pk": 2
},
{
"fields": {
"spam": false,
"subject_token": "Subject3",
"mailinglist": 3,
"score": 33,
"latest_message": 3
},
"model": "super_archives.thread",
"pk": 3
},
{
"fields": {
"spam": false,
"subject_token": "Subject4",
"mailinglist": 4,
"score": 33,
"latest_message": 4
},
"model": "super_archives.thread",
"pk": 4
},
{
"fields": {
"spam": false,
"subject_token": "Subject5",
"mailinglist": 4,
"score": 22,
"latest_message": 5
},
"model": "super_archives.thread",
"pk": 5
},
{
"fields": {
"spam": false,
"subject_token": "Subject6",
"mailinglist": 4,
"score": 11,
"latest_message": 6
},
"model": "super_archives.thread",
"pk": 6
},
{
"fields": {
"body": "lista Mailman email",
"received_time": "2015-02-24T14:23:42Z",
"from_address": 1,
"thread": 1,
"spam": false,
"subject_clean": "(no subject)",
"message_id": "<20150224142347.9ED2419A5B0@localhost.localdomain>",
"subject": "[Mailman] (no subject)"
},
"model": "super_archives.message",
"pk": 1
},
{
"fields": {
"body": "nada",
"received_time": "2015-02-24T14:15:39Z",
"from_address": 1,
"thread": 2,
"spam": false,
"subject_clean": "(no subject)",
"message_id": "<20150224141545.1AECA19A5A0@localhost.localdomain>",
"subject": "Subject2"
},
"model": "super_archives.message",
"pk": 2
},
{
"fields": {
"body": "Mensagem da lista privada nada",
"received_time": "2015-03-24T14:15:39Z",
"from_address": 1,
"thread": 3,
"spam": false,
"subject_clean": "(no subject)",
"message_id": "<20150324141545.1AECA19A5A0@localhost.localdomain>",
"subject": "Message3"
},
"model": "super_archives.message",
"pk": 3
},
{
"fields": {
"body": "Mensagem da lista privada nada",
"received_time": "2015-04-24T14:15:39Z",
"from_address": 1,
"thread": 4,
"spam": false,
"subject_clean": "(no subject)",
"message_id": "<20150424141545.1AECA19A5A0@localhost.localdomain>",
"subject": "Message4"
},
"model": "super_archives.message",
"pk": 4
},
{
"fields": {
"body": "Mensagem da lista privada nada",
"received_time": "2015-05-24T14:15:39Z",
"from_address": 1,
"thread": 5,
"spam": false,
"subject_clean": "(no subject)",
"message_id": "<20150524141545.1AECA19A5A0@localhost.localdomain>",
"subject": "Message5"
},
"model": "super_archives.message",
"pk": 5
},
{
"fields": {
"body": "Mensagem da lista privada nada",
"received_time": "2015-06-24T14:15:39Z",
"from_address": 1,
"thread": 6,
"spam": false,
"subject_clean": "(no subject)",
"message_id": "<20150323141545.1AECA19A5A0@localhost.localdomain>",
"subject": "Message6"
},
"model": "super_archives.message",
"pk": 6
},
{
"fields": {
"text": "lista Mailman email\n",
"message": 1,
"is_reply": false,
"order": 0
},
"model": "super_archives.messageblock",
"pk": 1
},
{
"fields": {
"text": "nada\n",
"message": 2,
"is_reply": false,
"order": 0
},
"model": "super_archives.messageblock",
"pk": 2
},
{
"fields": {
"text": "Mensagem da lista privada nada\n",
"message": 3,
"is_reply": false,
"order": 0
},
"model": "super_archives.messageblock",
"pk": 3
}
]
2 changes: 1 addition & 1 deletion colab/super_archives/fixtures/test_user.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
"is_active": true,
"facebook": "",
"groups": [],
"password": "123colab4",
"password": "pbkdf2_sha256$12000$iiKCMnLZnFJw$UTx89LB8oYTiw9UqkcglzFLmIaZtbr+ZzF1cG3vfcyo=",
"institution": "",
"github": "",
"modified": "2015-01-28T12:45:27.375Z"
Expand Down
41 changes: 25 additions & 16 deletions colab/super_archives/locale/pt_BR/LC_MESSAGES/django.po
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: colab\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2016-01-06 16:28-0200\n"
"POT-Creation-Date: 2016-01-15 19:18+0000\n"
"PO-Revision-Date: 2014-11-21 17:38+0000\n"
"Last-Translator: Sergio Oliveira <seocam@seocam.com>\n"
"Language-Team: Portuguese (Brazil) (http://www.transifex.com/projects/p/"
Expand All @@ -20,7 +20,6 @@ msgstr ""
"Plural-Forms: nplurals=2; plural=(n > 1);\n"

#: colab/super_archives/filters.py:8
#: colab/super_archives/templates/search/thread_search_preview.html:30
msgid "Discussion"
msgstr ""

Expand Down Expand Up @@ -110,29 +109,35 @@ msgstr "por"
msgid "ago"
msgstr "atrás"

#: colab/super_archives/templates/mailinglist-summary.html:7
#: colab/super_archives/templates/mailinglist-summary.html:8
#: colab/super_archives/templates/superarchives/thread-dashboard.html:4
#: colab/super_archives/templates/superarchives/thread-dashboard.html:7
msgid "Groups"
msgstr "Grupos"

#: colab/super_archives/templates/mailinglist-summary.html:13
#: colab/super_archives/templates/mailinglist-summary.html:14
#, fuzzy
#| msgid "Message body"
msgid "messages found"
msgstr "mensagens encontradas"

#: colab/super_archives/templates/mailinglist-summary.html:24
#: colab/super_archives/templates/mailinglist-summary.html:25
#: colab/super_archives/templates/superarchives/thread-dashboard.html:13
#, python-format
msgid "%(number_of_users)s members"
msgstr "%(number_of_users)s membros"

#: colab/super_archives/templates/mailinglist-summary.html:28
#: colab/super_archives/templates/mailinglist-summary.html:29
#: colab/super_archives/templates/message-thread.html:132
msgid "Order by"
msgstr "Ordenar por"

#: colab/super_archives/templates/mailinglist-summary.html:50
#, fuzzy
#| msgid "Date"
msgid "at"
msgstr "Data"

#: colab/super_archives/templates/message-thread.html:35
msgid "You must login before voting."
msgstr "Você deve logar antes de votar."
Expand Down Expand Up @@ -179,16 +184,6 @@ msgstr "votada"
msgid "Tags:"
msgstr "Tags:"

#: colab/super_archives/templates/search/thread_search_preview.html:5
#, fuzzy
#| msgid "Date"
msgid "at"
msgstr "Data"

#: colab/super_archives/templates/search/thread_search_preview.html:30
msgid "Registred in"
msgstr ""

#: colab/super_archives/templates/superarchives/emails/email_blank_subject.txt:2
msgid "Hello"
msgstr "Olá"
Expand Down Expand Up @@ -272,6 +267,12 @@ msgstr "mais..."
msgid "most relevant"
msgstr "Mais relevante"

#: colab/super_archives/templates/widgets/dashboard_most_relevant_threads.html:8
#, fuzzy
#| msgid "most relevant"
msgid "Most Relevant Threads"
msgstr "Mais relevante"

#: colab/super_archives/utils/email.py:14
msgid "Please verify your email "
msgstr "Por favor verifique seu email"
Expand Down Expand Up @@ -332,6 +333,14 @@ msgstr ""
msgid "Rating"
msgstr "Avaliação"

#: colab/super_archives/views.py:357
msgid "You are not logged in"
msgstr "Você não esta logado"

#: colab/super_archives/views.py:399
msgid "You don't have permission to access this list"
msgstr "Você não tem permissão para acessar esta lista"

#, fuzzy
#~| msgid "Order by"
#~ msgid "Order by:"
Expand Down

0 comments on commit 0f5bb53

Please sign in to comment.