Copropiedad Integral | Integrated Django translations system - Activated English Site - Leaseholders formset

in #utopian-io6 years ago

Repository

Copropiedad Integral repository

Copropiedad Integral has been created to provide co-properties (condominiums, horizontal property) managers with the necessary tools to manage administration and communication with co-owners in a simple and safe way.

New Features

Integrated i18n

I have integrated the Django translations system With it we are providing internationalization tools to the application. We are able to offer the application to the final user in different languages.

Django allows us to decide which texts must be translated in html templates and in Python files. By adding some hooks (translation strings) to the html files and the Python code, we are indicating which texts must be translated to the languages that we want to make available in the web site.

In order ti indicate to the "Django translations system" that a text must be translated in the html files, we must use the trans and the blocktrans template tags. We must load the i18n template tags by adding it into the load template tag at the beginning of the files:


{% load i18n %}

The trans template tag is used to translate constant strings:


{% trans "Text to translate" %}

To translate complex sentences consisting of literals and variable content, we can use the blocktrans template tag:


{% blocktrans %}Text to translate with a {{ variable }}{% endblocktrans %}

In Python files, we must use the ugettext function. It’s convention to import this as a shorter alias:

from django.utils.translation import gettext as _

We must use the following convention to designate that a string must be translated:

_("Translate this string")

Detailed code changes related to this new feature can be found in these commits: 51a83, 76cc6, cd06c.

English translation has been added. Details in the this commit.

Spanish site
English site

Leaseholders formset.

Now, when a condo administrator is creating a new unit (Apartment house or office), there is available a Django formset to register multiple leaseholders and create a new instance of the Leaseholder model by each one. The Leaseholder model has the unit attribute. This is to way to relate a leaseholder with a unit.


Screen Shot 2018-06-19 at 5.18.08 PM.png

I have integrated the django-formset-js. It's a simple way to add animations to our formset. We just must to add an id to the formset and add the following js lines:


Screen Shot 2018-06-19 at 5.20.42 PM.png

In this way, by clicking the green button "Add leaseholder", a new form to add an extra leaseholder will be displayed:


Screen Shot 2018-06-19 at 5.22.35 PM.png

And by checking the checkbox "Delete", the forms will be removed:


Screen Shot 2018-06-19 at 5.23.57 PM.png

An unit must have at least one registered owner, but it is not necessary to register leaseholders. For this reason this form can be sent with the leaseholders formset empty.

Leaseholders are visible in the unit detail:


Screen Shot 2018-06-19 at 5.32.48 PM.png

In the unit edit form, previously implemented, is available too the option to edit leaseholders:


Screen Shot 2018-06-19 at 5.34.57 PM.png

Add a new leaseholder to an unit is visible in the unit detail page:


Screen Shot 2018-06-19 at 5.35.59 PM.png

Detailed code changes related to these new features can be found in these commits: be1b7, 41093, 9c86a.

Roadmap

With the help of the company http://www.servisolucionesph.com/, we have designed a group of basic functionalities to implement in next days:

  1. parking information.
  2. Owner and leaseholders data update.
  3. Make a reservation for rent Social Hall or Auditoriums.
  4. Generate financial and administrative reports for consultation at the Ordinary or Extraordinary Assembly.
  5. Information Documents (Cleaning Awareness, Recycling Campaigns, Portfolio Collection, documents of Coexistence).
  6. Attach fixed documents of the co-ownership for permanent consultation (Coexistence Manual, Horizontal Property Regulation, Administration Attention Schedules, Rental Schedules, Rental Costs ...).
  7. Providers database.
  8. Online voting.
  9. Sending of Mass Collection Accounts through e-mail.

These activities has been added to our public trello board.

How to contribute?

Copropiedad Integral has been developed using the Django framework. You can fork the project, and run it locally is very easy. Follow the steps described in the open source repository installation guide. The project has been configured using Docker. you only need to install Docker and follow these steps.

If you want to contribute, please join my Discord

GitHub Account

https://github.com/aaquirogal

PR


Have happy days ✌

Sort:  

this is the economy of the future!

Get a free Bible for your phone, tablet, and computer. bible.com

Thanks for the contribution, @kit.andres - great quality as always! Would be even better if you added some comments to your code, as I couldn't find any in the PR you linked ;).

Your contribution has been evaluated according to Utopian policies and guidelines, as well as a predefined set of questions pertaining to the category.

To view those questions and the relevant answers related to your post, click here.


Need help? Write a ticket on https://support.utopian.io/.
Chat with us on Discord.
[utopian-moderator]

Congratulations @kit.andres! You have completed some achievement on Steemit and have been rewarded with new badge(s) :

Award for the number of posts published

Click on the badge to view your Board of Honor.
If you no longer want to receive notifications, reply to this comment with the word STOP

To support your work, I also upvoted your post!

Do not miss the last post from @steemitboard!


Participate in the SteemitBoard World Cup Contest!
Collect World Cup badges and win free SBD
Support the Gold Sponsors of the contest: @good-karma and @lukestokes


Do you like SteemitBoard's project? Then Vote for its witness and get one more award!

Hey @kit.andres
Thanks for contributing on Utopian.
We’re already looking forward to your next contribution!

Contributing on Utopian
Learn how to contribute on our website or by watching this tutorial on Youtube.

Want to chat? Join us on Discord https://discord.gg/h52nFrV.

Vote for Utopian Witness!

Coin Marketplace

STEEM 0.18
TRX 0.15
JST 0.029
BTC 62837.64
ETH 2542.11
USDT 1.00
SBD 2.65