GithubHelp home page GithubHelp logo

aldryn-people's Introduction

Deprecated

This project is no longer supported.

Divio will undertake no further development or maintenance of this project. If you are interested in continuing to develop it, use the fork functionality from GitHub. We are not able to transfer ownership of the repository to another party.

Aldryn People for django CMS

PyPI Version Build Status Coverage Status Code Climate Requirements Status

Aldryn People allows you to:

  • add people and groups of people to your website
  • display them on CMS pages
  • download vCards

Please see the Aldryn People documentation, which includes information on installation and getting started.

It also contains documentation for content editors and end-users.

Contributing

Aldryn People is a an open-source project. We'll be delighted to receive your feedback in the form of issues and pull requests. Before submitting your pull request, please review our guidelines for Aldryn Addons.

We're grateful to all contributors who have helped create and maintain this package.

Contributors are listed at contributions page.

Requirements

  • Python 2.7, 3.4, 3.5, 3.6
  • django CMS 3.4.5, 3.5, 3.6
  • Django 1.11, 2.0, 2.1

aldryn-people's People

Contributors

astagi avatar beniwohli avatar bogdal avatar bplociennik avatar braess avatar chaosk avatar chive avatar chronossc avatar chrumalo avatar czpython avatar daisylb avatar dhorelik avatar evildmp avatar filwaitman avatar finalangel avatar glasnt avatar lory87 avatar lukebanana avatar marketionist avatar mikek avatar mkoistinen avatar mociepka avatar simonsmiley avatar stefanfoulis avatar vthaian avatar vxsx avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

aldryn-people's Issues

Python 3 supported already?

The docs state that Python 3 isn't supported because of a dependency on vobject.
But that is removed a long time ago in this PR.

Is there any other reason why Python 3 isn't supported?

don't break if person has no slug

People don't require a slug. The view already handles this correctly by trying to get the object by slug or id.

But in the template you need to be able to reverse the url for both cases.

so something like {% url 'detail' person.slug_or_id %} should be possible.

allow putting people in multiple groups

proposed implementation:

  • A sortedm2m on Person to Group called groups.
  • In admin only show the sortedm2m field. Hide the group, but keep the group field on the model (this is the "primary" group). Always save the first selected item from the sortedm2m as the primary group (backwards compatibility and easier queries for the primary group).

Several Usability Updates

  • People List, the user should be able to edit a team member within the plugins list, not only within the admin
  • Rename "Comment" to "Description"
  • Check that everything works as expected

add cms toolbar integration

design decision needed: where/when do we display the menu item? (there is no person detail view or typical apphook)

Unicode Fail if Umlauts in title

Hi there,

I encountered unicode errors while trying to download a vcard of someone with umlauts in their title/function.

I am running the current version of django-cms with python 2.7.

However 2 little changes fixed this issue.

Social connections

We should add fields for the several social networks and IM-Messengers, e.g.

  • linkedin
  • xing
  • twitter
  • facebook
  • skype
  • Google+

.

.

Language switching needs a tidy-up

  • When switching between languages, you can lose entered data without warning - django CMS warns you "Are you sure you want to change tabs without saving the page first?"
  • the language switch tabs are differently-styled from django CMS's
  • the name and slug fields are not translated but appear in all language tabs, whereas the function field in-between them is translated - but there's nothing to indicate these different behaviours

Maybe names should be translatable - after all a name in Hebrew or Arabic is not the same as in English or German.

Missing installed app in documentation

Documentation states you only need to add:
INSTALLED_APPS = [

'aldryn_people',
'hvad',
'sortedm2m',
…

]
To your installed apps. However 'filer' needs to be added as well. e.g

INSTALLED_APPS = [

'aldryn_people',
'hvad',
'sortedm2m',
'filer',
…

]

latest migration is missing

When I use your model (i.e. People) in a different app and want to create migrations (./manage makemigrations another_people_app) this migration creates the missing migration for aldryn_people as well.

If I then want to deploy to Aldryn I get an error from the system:

django.db.migrations.graph.NodeNotFoundError: Migration aldryn_people_person_plugin.0001_initial dependencies reference nonexistent parent node ('aldryn_people', '0018_auto_20160725_1342')

Of course this is kind of easy to fix by referring to an older migration file but it has happened quite often with Aldryn / djangocms apps and it's annoying, because it breaks an automatic process (as the content of the migration files is created automatically).

Cleanups and renamings

might be renamed to aldryn-team

rename groups to "Departements" as this makes more sense for a website rather than "Companies"

Selecting people in the people list plugin broken?

I am trying to select only some people in the people list plugin (djangocms edit mode), however multiple choices get reduced to one choice upon saving.

Also, I am unable to sort people.

There are no errors in the javascript console.

Cannot add a new group properly when there are none to start with

When there are no, existing groups, attempting to create a group with the ➕ in the Person change form doesn't work. Well, technically, it works (the group is created), but the pop-up window turns blank and doesn't refresh the Person change form.

On investigation, there is a JS error in the popup as shown here:

image

It is not clear why, but there seems to be an interaction between sortedm2m's and Django's own JS that only happens when there are no existing objects in the m2m widget.

Aldryn Haystack: Error updating aldryn_people

it seems there is an incompatibility with django-haystack using the elastic search beta on Aldryn:

When I run ./manage.py rebuild_index on the docker container (with the production env vars set in .env-local). I am using Aldryn with Docker for Mac.

I run django-parler version: 1.6.5

POST https://search-aldryn-whatdigital-es-7tayzqk3v7g44dz7avjkq5kfje.eu-central-1.es.amazonaws.com:443/local_en/_refresh [status:200 request:0.053s]
Indexing 29 People
Error updating aldryn_people using de 
Traceback (most recent call last):
  File "/virtualenv/lib/python3.5/site-packages/haystack/management/commands/update_index.py", line 188, in handle_label
    self.update_backend(label, using)
  File "/virtualenv/lib/python3.5/site-packages/haystack/management/commands/update_index.py", line 233, in update_backend
    do_update(backend, index, qs, start, end, total, verbosity=self.verbosity, commit=self.commit)
  File "/virtualenv/lib/python3.5/site-packages/haystack/management/commands/update_index.py", line 96, in do_update
    backend.update(index, current_qs, commit=commit)
  File "/virtualenv/lib/python3.5/site-packages/haystack/backends/elasticsearch_backend.py", line 166, in update
    prepped_data = index.full_prepare(obj)
  File "/virtualenv/lib/python3.5/site-packages/haystack/indexes.py", line 212, in full_prepare
    self.prepared_data = self.prepare(obj)
  File "/virtualenv/lib/python3.5/site-packages/aldryn_search/base.py", line 42, in prepare
    self.prepared_data['text'] = self.get_search_data(obj, current_language, request)
  File "/virtualenv/lib/python3.5/site-packages/aldryn_people/search_indexes.py", line 34, in get_search_data
    return strip_tags(self.get_description(obj)).strip()
  File "/virtualenv/lib/python3.5/site-packages/aldryn_people/search_indexes.py", line 21, in get_description
    return obj.description
  File "/virtualenv/lib/python3.5/site-packages/parler/fields.py", line 92, in __get__
    translation = instance._get_translated_model(use_fallback=True, meta=meta)
  File "/virtualenv/lib/python3.5/site-packages/parler/models.py", line 471, in _get_translated_model
    lang_dict = get_language_settings(language_code)
  File "/virtualenv/lib/python3.5/site-packages/parler/utils/i18n.py", line 80, in get_language_settings
    return appsettings.PARLER_LANGUAGES.get_language(language_code, site_id)
  File "/virtualenv/lib/python3.5/site-packages/parler/utils/conf.py", line 114, in get_language
    if lang_dict['code'].split('-')[0] == language_code.split('-')[0]:
AttributeError: 'NoneType' object has no attribute 'split'
Traceback (most recent call last):
  File "manage.py", line 7, in <module>
    startup.manage(path=os.path.dirname(os.path.abspath(__file__)))
  File "/virtualenv/lib/python3.5/site-packages/aldryn_django/startup.py", line 11, in manage
    utility.execute()
  File "/virtualenv/lib/python3.5/site-packages/django/core/management/__init__.py", line 346, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
  File "/virtualenv/lib/python3.5/site-packages/django/core/management/base.py", line 394, in run_from_argv
    self.execute(*args, **cmd_options)
  File "/virtualenv/lib/python3.5/site-packages/django/core/management/base.py", line 445, in execute
    output = self.handle(*args, **options)
  File "/virtualenv/lib/python3.5/site-packages/haystack/management/commands/rebuild_index.py", line 26, in handle
    call_command('update_index', **options)
  File "/virtualenv/lib/python3.5/site-packages/django/core/management/__init__.py", line 120, in call_command
    return command.execute(*args, **defaults)
  File "/virtualenv/lib/python3.5/site-packages/django/core/management/base.py", line 445, in execute
    output = self.handle(*args, **options)
  File "/virtualenv/lib/python3.5/site-packages/haystack/management/commands/update_index.py", line 183, in handle
    return super(Command, self).handle(*items, **options)
  File "/virtualenv/lib/python3.5/site-packages/django/core/management/base.py", line 623, in handle
    label_output = self.handle_label(label, **options)
  File "/virtualenv/lib/python3.5/site-packages/haystack/management/commands/update_index.py", line 188, in handle_label
    self.update_backend(label, using)
  File "/virtualenv/lib/python3.5/site-packages/haystack/management/commands/update_index.py", line 233, in update_backend
    do_update(backend, index, qs, start, end, total, verbosity=self.verbosity, commit=self.commit)
  File "/virtualenv/lib/python3.5/site-packages/haystack/management/commands/update_index.py", line 96, in do_update
    backend.update(index, current_qs, commit=commit)
  File "/virtualenv/lib/python3.5/site-packages/haystack/backends/elasticsearch_backend.py", line 166, in update
    prepped_data = index.full_prepare(obj)
  File "/virtualenv/lib/python3.5/site-packages/haystack/indexes.py", line 212, in full_prepare
    self.prepared_data = self.prepare(obj)
  File "/virtualenv/lib/python3.5/site-packages/aldryn_search/base.py", line 42, in prepare
    self.prepared_data['text'] = self.get_search_data(obj, current_language, request)
  File "/virtualenv/lib/python3.5/site-packages/aldryn_people/search_indexes.py", line 34, in get_search_data
    return strip_tags(self.get_description(obj)).strip()
  File "/virtualenv/lib/python3.5/site-packages/aldryn_people/search_indexes.py", line 21, in get_description
    return obj.description
  File "/virtualenv/lib/python3.5/site-packages/parler/fields.py", line 92, in __get__
    translation = instance._get_translated_model(use_fallback=True, meta=meta)
  File "/virtualenv/lib/python3.5/site-packages/parler/models.py", line 471, in _get_translated_model
    lang_dict = get_language_settings(language_code)
  File "/virtualenv/lib/python3.5/site-packages/parler/utils/i18n.py", line 80, in get_language_settings
    return appsettings.PARLER_LANGUAGES.get_language(language_code, site_id)
  File "/virtualenv/lib/python3.5/site-packages/parler/utils/conf.py", line 114, in get_language
    if lang_dict['code'].split('-')[0] == language_code.split('-')[0]:
AttributeError: 'NoneType' object has no attribute 'split'

Person should have a placeholder for additional content on the details page

Currently, the detailed view of a person shows exactly the same information as the overview. IMHO, it would be a good idea to add a placeholder to the Person model, such that additional content (text, images, whatever) can be added to the detailed view of a person, similar to a news entry in aldryn-newsblog.

I think this is quite a typical use case, see for example this "people" page of a university institute. The overview shows some well-structured data (name, e-mail, phone number) and if you click on a person, the detailed view shows additional text.

Group Company

Depending on the added people, the person.group should be grouped per loop like:

Group

  • People
  • People
  • People

Group

  • People
    ...

The html is uncommented currently.

System check failed

When I execute "python manage.py check", I got following error:

CommandError: System check identified some issues:

ERRORS:
aldryn_people.Person.visual: (fields.E300) Field defines a relation with model 'Image', which is either not installed, or is abstract.

OS: Ubuntu 14.04LTS 64bit
Python: 2.7.6
Django: 1.7.4
Django-cms: 3.0.10
aldryn-people: 0.4.6

Python3 support pip install fails

Hi!

I'm having the following log problem while installing aldryn-newsblog on python3.4 for django cms (3.0.12),
is there any support available for this?

Thanks

Downloading/unpacking vobject (from aldryn-people>=0.4.6->aldryn-newsblog)
  Downloading vobject-0.6.6.tar.gz (53kB): 53kB downloaded
  Running setup.py (path:/Users/davidetruffo/Projects/venvs/mentor/build/vobject/setup.py) egg_info for package vobject
    Traceback (most recent call last):
      File "<string>", line 17, in <module>
      File "/Users/davidetruffo/Projects/venvs/mentor/build/vobject/setup.py", line 31, in <module>
        from ez_setup import use_setuptools
      File "/Users/davidetruffo/Projects/venvs/mentor/build/vobject/ez_setup/__init__.py", line 94
        except pkg_resources.VersionConflict, e:
                                            ^
    SyntaxError: invalid syntax
    Complete output from command python setup.py egg_info:
    Traceback (most recent call last):

  File "<string>", line 17, in <module>

  File "/Users/davidetruffo/Projects/venvs/mentor/build/vobject/setup.py", line 31, in <module>

    from ez_setup import use_setuptools

  File "/Users/davidetruffo/Projects/venvs/mentor/build/vobject/ez_setup/__init__.py", line 94

    except pkg_resources.VersionConflict, e:

                                        ^

SyntaxError: invalid syntax

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.