diff --git a/docs/.mdlrc b/docs/.mdlrc index 5071bdb6d..7382d1c37 100644 --- a/docs/.mdlrc +++ b/docs/.mdlrc @@ -1 +1 @@ -rules "MD001", "MD002", "MD003", "MD004", "MD005", "MD006", "MD007", "MD008", "MD009", "MD010", "MD011", "MD012", "MD014", "MD015", "MD016", "MD017", "MD018", "MD019", "MD020", "MD021", "MD022", "MD023", "MD024", "MD025", "MD026", "MD027", "MD028", "MD029", "MD030", "MD031", "MD032", "MD033", "MD034", "MD035", "MD036", "MD037", "MD038", "MD039", "MD040", "MD041" +rules "MD001", "MD002", "MD003", "MD004", "MD005", "MD006", "MD007", "MD008", "MD009", "MD010", "MD011", "MD012", "MD014", "MD015", "MD016", "MD017", "MD018", "MD019", "MD020", "MD021", "MD022", "MD023", "MD025", "MD026", "MD027", "MD028", "MD030", "MD031", "MD032", "MD033", "MD034", "MD035", "MD036", "MD037", "MD038", "MD039", "MD040", "MD041" diff --git a/docs/README.md b/docs/README.md index 8a11b3a5b..1bec96ace 100644 --- a/docs/README.md +++ b/docs/README.md @@ -67,7 +67,7 @@ But for some actions like voting, you will need a verified user, the seeds file ## Documentation -You can find this project documentation at https://github.com/consul/docs. +You can find this project documentation at . ## License diff --git a/docs/SUMMARY.md b/docs/SUMMARY.md index 04645768d..98c1e88bb 100644 --- a/docs/SUMMARY.md +++ b/docs/SUMMARY.md @@ -30,9 +30,9 @@ * [Customization](en/customization/customization.md) * [Introduction](en/customization/introduction.md) - * [Texts & Translations](en/customization/translations.md) + * [Translations and Texts](en/customization/translations.md) * [Images](en/customization/images.md) - * [Views & Styles](en/customization/views_and_styles.md) + * [Views and Styles](en/customization/views_and_styles.md) * [Javascript](en/customization/javascript.md) * [Models](en/customization/models.md) * [Components](en/customization/components.md) @@ -83,9 +83,9 @@ * [Personalización](es/customization/customization.md) * [Introducción](es/customization/introduction.md) - * [Textos & Traducciones](es/customization/translations.md) + * [Traducciones y Textos](es/customization/translations.md) * [Imágenes](es/customization/images.md) - * [Vistas & Estilos](es/customization/views_and_styles.md) + * [Vistas y Estilos](es/customization/views_and_styles.md) * [Javascript](es/customization/javascript.md) * [Modelos](es/customization/models.md) * [Componentes](es/customization/components.md) diff --git a/docs/en/README.md b/docs/en/README.md index 3adc60370..52b51392b 100644 --- a/docs/en/README.md +++ b/docs/en/README.md @@ -67,7 +67,7 @@ But for some actions like voting, you will need a verified user, the seeds file ## Documentation -You can find this project documentation at https://github.com/consul/docs. +You can find this project documentation at . ## License diff --git a/docs/en/customization/customization.md b/docs/en/customization/customization.md index 06b5984b7..92871e7a7 100644 --- a/docs/en/customization/customization.md +++ b/docs/en/customization/customization.md @@ -1,9 +1,9 @@ # Customization * [Introduction](introduction.md) -* [Texts & Translations](translations.md) +* [Translations and Texts](translations.md) * [Images](images.md) -* [Views & Styles](views_and_styles.md) +* [Views and Styles](views_and_styles.md) * [Javascript](javascript.md) * [Models](models.md) * [Components](components.md) diff --git a/docs/en/customization/images.md b/docs/en/customization/images.md index b3b297edc..94c977189 100644 --- a/docs/en/customization/images.md +++ b/docs/en/customization/images.md @@ -14,4 +14,4 @@ If you want to overwrite any image, firstly you need to find out the filename, a You'll find the city map at [`/app/assets/images/map.jpg`](https://github.com/consul/consul/blob/master/app/assets/images/map.jpg), just replace it with an image of your cities districts ([example](https://github.com/ayuntamientomadrid/consul/blob/master/app/assets/images/map.jpg)). -Afterwards we recommend you to use an online tool like http://imagemap-generator.dariodomi.de/ or https://www.image-map.net/ to generate the html coordinates to be able to generate a [image-map](https://www.w3schools.com/tags/tag_map.asp) for each of the districts. Those coordinates should be introduced on the respective Geozones at the admin geozones panel (`/admin/geozones`). +Afterwards we recommend you to use an online tool like or to generate the html coordinates to be able to generate a [image-map](https://www.w3schools.com/tags/tag_map.asp) for each of the districts. Those coordinates should be introduced on the respective Geozones at the admin geozones panel (`/admin/geozones`). diff --git a/docs/en/customization/introduction.md b/docs/en/customization/introduction.md index cf54b6db1..f1b847909 100644 --- a/docs/en/customization/introduction.md +++ b/docs/en/customization/introduction.md @@ -28,67 +28,80 @@ The aim of this service is to be able to offer all the dynamic contents of the a When a user visits a page with a language where there is untranslated content, they will have a button to request the translation of all the content. This content will be sent to an automatic translator (in this case [Microsoft TranslatorText](https://azure.microsoft.com/en-us/products/cognitive-services/translator/)) and as soon as the response is obtained, all these translations will be available to any user. -#### Getting started +### Getting started + In order to use this functionality, the following steps are necessary: + 1. Have an api key to connect to the translation service. For this we need an [Azure account](https://azure.microsoft.com/en-us/) 1. Once you are logged into the Azure portal, subscribe to the Translator in Cognitive Service. 1. Once you have subscribed to the Translator Text service, you will have access to 2 api keys in the section **Resource Management > Keys and Endpoint** that will be necessary for the configuration of the translation service in your application. -#### Configuration +### Configuration + To activate the translation service in your application you must complete the following steps: -##### Add api key in the application +#### Add api key in the application + In the previous section we have commented that once subscribed to the translation service we have 2 api keys. To configure the service correctly in our application we must add one of the two api keys in the file `secrets.yml` in section `apis:` with the key `microsoft_api_key` as we can see in the following image: ![Add api key to secrets](../../img/translations/remote_translations/add-api-key-to-secrets.png) -##### Activate module +#### Activate module + Once we have the new key in the `secrets.yml` we can now proceed to activate the module. To activate the functionality you must follow 2 steps: + 1. Execute the following command `bin/rake settings:create_remote_translations_setting RAILS_ENV=production` 1. Accessing through the administration panel of your application to the section **Configuración > Funcionalidades** and activate module **Traducciones Remotas** as shown below: -![Active remote translations](../../img/translations/remote_translations/active-remote-translations-en.png) + ![Active remote translations](../../img/translations/remote_translations/active-remote-translations-en.png) + +### Use Cases -#### Use Cases Once we have the api key in our `secrets.yml` and the activated module, users will already be able to use the functionality. We attach some screenshots of how the application interacts with our users: + * When a user visits a page in a language without translated content, an informative text will appear at the top of the page and a button to request the translation. (**Note:** *If user visit page with a language not supported by the translation service, no text or translation button will be displayed. See section: Available languages for remote translation*) -![Display text and button](../../img/translations/remote_translations/display-text-and-button-en.png) + ![Display text and button](../../img/translations/remote_translations/display-text-and-button-en.png) * Once the user click the `Translate page` button, the translations are enqueued and the page is reloaded with a notice (*Informing that the translations have been requested correctly*) and an informative text in the header (*explaining when you will be able to see these translations*). -![Display notice and text after enqueued translations](../../img/translations/remote_translations/display-notice-and-text-after-enqueued-en.png) + ![Display notice and text after enqueued translations](../../img/translations/remote_translations/display-notice-and-text-after-enqueued-en.png) * If an user visit a page that does not have translations but have already been requested by another user. The application will not show you the translate button, but an informative text in the header (*explaining when you will be able to see these translations*). -![Display text explaining that translations are pending](../../img/translations/remote_translations/display-text-translations-pending-en.png) + ![Display text explaining that translations are pending](../../img/translations/remote_translations/display-text-translations-pending-en.png) * The translation request, response processing and data saving are delegated to `Delayed Jobs` and as soon as they are processed, the user will be able to read them after page refresh. -![Display translated content](../../img/translations/remote_translations/display-translated-content-en.png) + ![Display translated content](../../img/translations/remote_translations/display-translated-content-en.png) +### Available languages for remote translation -#### Available languages for remote translation Currently these are all the [available languages](https://api.cognitive.microsofttranslator.com/languages?api-version=3.0) in the translation service: + ```yml ["af", "am", "ar", "as", "az", "ba", "bg", "bn", "bo", "bs", "ca", "cs", "cy", "da", "de", "dv", "el", "en", "es", "et", "eu", "fa", "fi", "fil", "fj", "fo", "fr", "fr-CA", "ga", "gl", "gu", "ha", "he", "hi", "hr", "hsb", "ht", "hu", "hy", "id", "ig", "ikt", "is", "it", "iu", "iu-Latn", "ja", "ka", "kk", "km", "kmr", "kn", "ko", "ku", "ky", "ln", "lo", "lt", "lug", "lv", "lzh", "mg", "mi", "mk", "ml", "mn-Cyrl", "mn-Mong", "mr", "ms", "mt", "mww", "my", "nb", "ne", "nl", "nso", "nya", "or", "otq", "pa", "pl", "prs", "ps", "pt", "pt-PT", "ro", "ru", "run", "rw", "sk", "sl", "sm", "sn", "so", "sq", "sr-Cyrl", "sr-Latn", "st", "sv", "sw", "ta", "te", "th", "ti", "tk", "tlh-Latn", "tlh-Piqd", "tn", "to", "tr", "tt", "ty", "ug", "uk", "ur", "uz", "vi", "xh", "yo", "yua", "yue", "zh-Hans", "zh-Hant", "zu"] ``` + Of all the languages that Consul currently has defined (`available_locales`) in `config/application.rb` the only one that is not listed above and therefore no translation service is offered is Valencian `["val"]`. -#### Pricing +### Pricing + The translation service used has the most competitive [pricing](https://azure.microsoft.com/en-us/pricing/details/cognitive-services/translator/). The price for each 1 Million characters translated is $10 and there is no fixed cost per month. Although technical measures have been taken to prevent misuse of this service, we recommend the creation of Alerts offered by Azure so that an Administrator can be notified in the event of detecting unusual use of the service. This service has a cost of $0.10 per month. To create an Alert in Azure we must follow the following steps: + 1. Sign in to the **Azure Portal**. 1. Access the **Translator** service created earlier. 1. Go to **Monitoring > Alerts** in the side menu: - 1. Go to **Create alert rule**. - 1. In **Select a signal** select `Text Characters Translated`. - 1. Once selected we must define the logic of the Alert to suit our needs. Ex: Fill "Operator" field with "Greater than" option, fill "Aggregation type" field with "Total" option and fill "Threshold value" field with the number of characters we consider should be translated before being notified. In this section you can also set the time period and frequency of evaluation. - 1. In order to be notified we have to create an **Action Group** and associate it with this Alert we're creating. To do this, access the button **Create** and fill out the form. As you can see there are different types of actions, we must select **Email/SMS/Push/Voice** and configure the option that we consider convenient according to our needs. - 1. Once this group of actions has been created, it is directly associated with the rule we are creating. - 1. Finally, all you have to do is add a name and click on the **Review + create** + 1. Go to **Create alert rule**. + 1. In **Select a signal** select `Text Characters Translated`. + 1. Once selected we must define the logic of the Alert to suit our needs. Ex: Fill "Operator" field with "Greater than" option, fill "Aggregation type" field with "Total" option and fill "Threshold value" field with the number of characters we consider should be translated before being notified. In this section you can also set the time period and frequency of evaluation. + 1. In order to be notified we have to create an **Action Group** and associate it with this Alert we're creating. To do this, access the button **Create** and fill out the form. As you can see there are different types of actions, we must select **Email/SMS/Push/Voice** and configure the option that we consider convenient according to our needs. + 1. Once this group of actions has been created, it is directly associated with the rule we are creating. + 1. Finally, all you have to do is add a name and click on the **Review + create** + +### Add a new translation service -#### Add a new translation service If you want to integrate more translation services for any reason (new translation service appears, you want to change to include languages that are currently not supported, etc.) the code is ready to be added. This is made possible by the `RemoteTranslations::Caller` class which is an intermediate layer between untranslated content management and the currently used Microsoft Translation Client. A good solution for adding another translation service would be to replace the call to the `MicrosoftTranslateClient` in the `translations` method of `RemoteTranslations::Caller` with the new service implemented. @@ -106,25 +119,27 @@ class RemoteTranslationsCaller ... end -``` +``` ## Translation interface The aim of this feature is to allow users the introduction of dynamic contents in many languages at the same time. From the administration panel you can activate or deactivate it. If you deactivate this feature (default configuration) users will be able to enter one single translation. -#### Enable module +### Enable module + To activate this feature you must follow 2 steps: + 1. Execute the following command `bin/rake settings:create_translation_interface_setting RAILS_ENV=production` (This is only required for already existing intallations, for new consul installations this step is not needed). 2. Accessing as administrator user to the administration panel of your Consul application to the section **Configuration > Features** and activating the feature called **Translation Interface** as you can see next: -![Active interface translations](../../img/translations/interface_translations/active-interface-translations-en.png) + ![Active interface translations](../../img/translations/interface_translations/active-interface-translations-en.png) -#### Use Cases +### Use Cases * When the translation interface is active: -As you can see in the image below translation interface has two selectors, the first one "Select language" is to switch between enabled languages and the second one "Add language" is to add new languages to the form. Translatable fields appears with a blue background to facilitate users to distinguish between translatable and not translatable fields. Additionally interface provides a link `Remove language` to delete the current language shown at "Select language". If a user accidentally removes a translation he can recover it re-adding it to the form. -This feature is visible during creation and edition of translatable resources. -![Translations interface enabled](../../img/translations/interface_translations/translations-interface-enabled-en.png) + As you can see in the image below translation interface has two selectors, the firt one "Select language" is to switch between enabled languages and the second one "Add language" is to add new languages to the form. Translatable fields appears with a blue background to facilitate users to distinguish between translatable and not translatable fields. Additionally interface provides a link `Remove language` to delete the current language shown at "Select language". If a user accidentally removes a translation he can recover it re-adding it to the form. + This feature is visible during creation and edition of translatable resources. + ![Translations inteface enabled](../../img/translations/interface_translations/translations-interface-enabled-en.png) * When the translation interface is disabled: -When this feature is deactivated users will see standard forms without translation interface and without translation highlight. -![Translations interface enabled](../../img/translations/interface_translations/translations-interface-disabled-en.png) + When this feature is deactivated users will see standard forms without translation interface and without translation highlight. + ![Translations inteface enabled](../../img/translations/interface_translations/translations-interface-disabled-en.png) diff --git a/docs/en/customization/translations.md b/docs/en/customization/translations.md index 63ac402af..971dc40b7 100644 --- a/docs/en/customization/translations.md +++ b/docs/en/customization/translations.md @@ -1,4 +1,6 @@ -# Translations +# Translations and Texts + +## Translations Currently, CONSUL is totally or partially translated to multiple languages. You can find the translations at the [Crowdin project](https://crowdin.com/project/consul). @@ -8,7 +10,7 @@ If your language isn't already present in the Crowdin project, please [open an i If you want to check existing translations of the user-facing texts you can find them organized in YML files under `config/locales/` folder. Take a look at the official Ruby on Rails [internationalization guide](http://guides.rubyonrails.org/i18n.html) to better understand the translations system. -# Custom Texts +## Custom Texts Since CONSUL is always evolving with new features, and in order to make your fork easier to be updated, we strongly recommend translation files not to be modified, but instead "overwritten" with custom translation files in case a text needs to be customized for you. @@ -29,7 +31,7 @@ es: In order to customize it, you should create a new file `config/locales/custom/es/general.yml` with just that content, and change "Ayuntamiento de Madrid" with our organization name. We strongly recommend to make copies from `config/locales/` and modify or delete the lines as needed to keep the indentation structure and avoid issues. -# Maintaining your Custom Texts & Languages +## Maintaining your Custom Texts & Languages CONSUL has the [i18n-tasks](https://github.com/glebm/i18n-tasks) gem, it's an awesome helping tool to manage i18n translations. Just check `i18n-tasks health` for a nice report. diff --git a/docs/en/customization/views_and_styles.md b/docs/en/customization/views_and_styles.md index 08e570421..2072d38b1 100644 --- a/docs/en/customization/views_and_styles.md +++ b/docs/en/customization/views_and_styles.md @@ -1,8 +1,10 @@ -# Views (HTML) +# Views and Styles + +## Views (HTML) If you want to change any page HTML you can just find the correct file under the `app/views` folder and put a copy at `app/views/custom` keeping as well any sub-folder structure, and then apply your customizations. For example if you want to customize `app/views/pages/conditions.html` you'll have to make a copy at `app/views/custom/pages/conditions.html.erb` (note the `pages` subdirectory). -# CSS Styles with SASS +## CSS Styles with SASS In order to make changes to any CSS selector (custom style sheets), you can add them directly at `app/assets/stylesheets/custom.scss`. For example to change the header color (`.top-links`) you can just add: diff --git a/docs/en/features/census_configuration.md b/docs/en/features/census_configuration.md index 2dada6832..b060f5b2b 100644 --- a/docs/en/features/census_configuration.md +++ b/docs/en/features/census_configuration.md @@ -1,4 +1,4 @@ -## Configure connection to the Census: +# Configure connection to the Census The objective of this service is to be able to configure the connection with the Town Hall Census through the Administration panel without having to modify the application code. @@ -6,18 +6,20 @@ It should be noted that to properly configure this connection will require a tec Currently the application was designed to send only the **document number** and **document type**. With this new feature is enabled the possibility of sending if necessary the fields **date of birth** and **postal code**. +## Activate feature -#### Activate feature In the section **Configuration > Global Configuration** a new tab **Remote Census Configuration** has been added. If we have the feature deactivated we will see an informative text that will indicate us how to activate it: ![Feature disabled](../../img/remote_census/feature-disabled-en.png) To activate the feature you must follow the instructions of the previous image: -1. Access through the administration panel of your application to the section **Settings > Features** and activate the module **Configure connection to the remote census (SOAP)** as shown below: -![Feature enabled](../../img/remote_census/feature-enabled-en.png) -#### Configuration +1. Access through the administration panel of your application to the section **Settings > Features** and activate the module **Configure connection to the remote census (SOAP)** as shown below: + ![Feature enabled](../../img/remote_census/feature-enabled-en.png) + +## Configuration + Once the feature is activated, we can access the section **Settings > Global Settings** and click on the tab **Remote Census Configuration**. In this screen you will be able to fill in all the necessary information to be able to configure the connection with the Census of each Town Hall. @@ -35,6 +37,7 @@ The information to be filled in is divided into three sections: ![Request Data](../../img/remote_census/request-data-en.png) To help you understand how to fill in each of the fields, we will rely on a supposed WebService that receives a method called `:get_habita_datos` with the following structure: + ``` { request: { @@ -49,32 +52,27 @@ The information to be filled in is divided into three sections: ``` Required fields for the request: - - **Request method name**: Request method name accepted by the City Census WebService. Example: ![Request Data - Method name](../../img/remote_census/request-data-method-name-en.png) - - **Request Structure**: Structure of the request received by the WebService of the Census of the City Council. The "static" values of this request should be reported. The "dynamic" values related to Document Type, Document Number, Date of Birth and Postal Code should be filled with null value. Example: ![Request Data - Structure](../../img/remote_census/request-data-structure-en.png) ![Request Data - Structure](../../img/remote_census/request-data-structure-info-en.png) - - **Path for document type**: Path in the request structure that sends the Document Type. *NOTE: DO NOT FILL IN if the WebService does not require the Document Type to verify a user.* Example: ![Request Data - Path document type](../../img/remote_census/request-data-path-document-type-en.png) - - **Path for document number**: Path in the request structure that sends the Document Number. *NOTE: DO NOT FILL IN if the WebService does not require the Document Number to verify a user.* Example: ![Request Data - Path document number](../../img/remote_census/request-data-path-document-number-en.png) - - **Path for date of birth**: Path in the request structure that sends the Date of Birth. *NOTE: DO NOT FILL IN if the WebService does not require the Date of Birth to verify a user.* @@ -83,7 +81,6 @@ The information to be filled in is divided into three sections: Example: ![Request Data - Path date of birth](../../img/remote_census/request-data-path-date-of-birth-en.png) - - **Path for Postal Code**: Path in the request structure that sends the Postal Code. *NOTE: DO NOT FILL IN if the WebService does not require the Postal Code to verify a user.* @@ -126,41 +123,33 @@ The information to be filled in is divided into three sections: ``` Required fields to parse the response: - - **Path for Date of Birth**: In what path of the response is the user's Date of Birth?. Example: ![Response Data - Path date of birth](../../img/remote_census/response-data-path-date-of-birth-en.png) - - **Path for Postal Code**: In what path of the response is the user's Postal Code?. Example: ![Response Data - Path postal code](../../img/remote_census/response-data-path-postal-code-en.png) - - **Path for District**: In what path of the response is the user's District?. Example: ![Response Data - Path district](../../img/remote_census/response-data-path-district-en.png) - - **Path for Gender**: In what path of response is the user's Gender?. Example: ![Response Data - Path Gender](../../img/remote_census/response-data-path-gender-en.png) - - **Path for Name**: In what path of the response is the user's Name?. Example: ![Response Data - Path Name](../../img/remote_census/response-data-path-name-en.png) - - **Path for the Last Name**: In what path of the response is the user's Last Name?. Example: ![Response Data - Path Last Name](../../img/remote_census/response-data-path-last-name-en.png) - - **Condition for detecting a valid response**: What response path has to come informed to be considered a valid response and user verified. Example: ![Response Data - Path valid response](../../img/remote_census/response-data-path-valid-response-en.png) - Once the general data, the necessary fields of the request and "all" fields to validate the response have been filled in correctly, the application will be able to verify any user through the defined WebService. diff --git a/docs/en/features/local_census.md b/docs/en/features/local_census.md index bcd7bc39a..e248d9f33 100644 --- a/docs/en/features/local_census.md +++ b/docs/en/features/local_census.md @@ -1,30 +1,33 @@ -##Local Census +# Local Census To provide to administrator users a way to manage the local census database through the administration panel **Settings > Manage local census**. Currently the only way to manipulate this table records is through the rails console. Allow administrators users to manage this table in two different ways: - - **Manually**: one by one through a CRUD interface. - - **Automatically**: through an importation process. +- **Manually**: one by one through a CRUD interface. +- **Automatically**: through an importation process. + +## Manually -#### Manually Provide a way to manage local census records to administrator users through administration interface. - Local Census Page -![Manage local census](../../img/local_census/manage-local-census-en.png) + ![Manage local census](../../img/local_census/manage-local-census-en.png) + - Add new record -![Create local census record](../../img/local_census/add-local-census-record-en.png) + ![Create local census record](../../img/local_census/add-local-census-record-en.png) Features: 1. Search by document_number: As local_census_records could contain a lot of records we have added a search feature to allow administrators to find existing records by document_number. 1. Avoid the introduction of duplicated records: A model validation has been added to the following attributes pair [:document_number, :document_type] -#### Automatically +## Automatically + Allow administrator users to import local census records though CSV file. - Local Census Page -![Manage local census csv](../../img/local_census/manage-local-census-csv-en.png) + ![Manage local census csv](../../img/local_census/manage-local-census-csv-en.png) - Import CSV -![Create local census records csv](../../img/local_census/add-local-census-records-csv-en.png) + ![Create local census records csv](../../img/local_census/add-local-census-records-csv-en.png) diff --git a/docs/en/features/oauth.md b/docs/en/features/oauth.md index 4b7e37355..097571a2f 100644 --- a/docs/en/features/oauth.md +++ b/docs/en/features/oauth.md @@ -2,13 +2,15 @@ You can configure authentication services with external OAuth suppliers, right now Twitter, Facebook and Google are supported. -## 1. Create an App on the platform +## 1. Create an App on the platform + For each platform, go to their developers section and follow their guides to create an app. ## 2. Set your CONSUL's url They'll ask you for your CONSUL's auth URL, and as you can see running `rake routes` at your CONSUL repo locally: - ```bash + +```bash user_omniauth_authorize GET|POST /users/auth/:provider(.:format) users/omniauth_callbacks#passthru {:provider=>/twitter|facebook|google_oauth2/} ``` diff --git a/docs/en/features/recommendations.md b/docs/en/features/recommendations.md index 495fe24e0..f3ee1e0e1 100644 --- a/docs/en/features/recommendations.md +++ b/docs/en/features/recommendations.md @@ -3,17 +3,18 @@ Logged in users can see recommended Debates or Proposals listed with the ordering option "recommendations". The list shows, ordered by votes descending, those elements that: + 1. Have tags that interests the user. Being those tags the ones on the proposals that the user follows. 2. The user isn't the author. 3. In the case of proposals: only those that haven't reached the required threshold of votes, hiding as well those that the user is already following. ## How to try it -In our local installation, if we haven't logged in, we can check at http://localhost:3000/proposals that the "recommendations" ordering isn't present: +In our local installation, if we haven't logged in, we can check at that the "recommendations" ordering isn't present: ![Recommendations not logged in](../../img/recommendations/recommendations_not_logged_in.jpg) -Once we log in we see the menu, but because we don't aren't following any proposals we get the message "Follow proposals so we can give you recommendations" at http://localhost:3000/proposals?locale=en&order=recommendations&page=1 +Once we log in we see the menu, but because we don't aren't following any proposals we get the message "Follow proposals so we can give you recommendations" at ![Recommendations no follows](../../img/recommendations/recommendations_no_follows.jpg) diff --git a/docs/en/getting_started/configuration.md b/docs/en/getting_started/configuration.md index 585919b38..63381a0ed 100644 --- a/docs/en/getting_started/configuration.md +++ b/docs/en/getting_started/configuration.md @@ -4,7 +4,7 @@ [Travis](https://travis-ci.org/) is a Continuous Integration service, free for OpenSource projects (like Consul and it's forks). It will help you check on each Pull Request if the test suite is alright. -1. Visit https://github.com/marketplace/travis-ci and click the "**Install it for free**" green button at the bottom of the page. +1. Visit and click the "**Install it for free**" green button at the bottom of the page. 2. Click on the "**Complete order and begin installation**" green button. diff --git a/docs/en/getting_started/create.md b/docs/en/getting_started/create.md index 2019e857b..c6e12b67e 100644 --- a/docs/en/getting_started/create.md +++ b/docs/en/getting_started/create.md @@ -6,7 +6,7 @@ Consul git repo is hosted at Github.com, we recommend using it for your fork's r 2. [Create an Organization](https://help.github.com/articles/creating-a-new-organization-from-scratch/) on Github with the name of your city or the organization that's going to use Consul. **This is not mandatory**, but it will help understand the fork's purpose and future contributions by other users. -3. [Fork Consul](https://help.github.com/articles/fork-a-repo/) using the **fork** button on the top right corner at https://github.com/consul/consul. +3. [Fork Consul](https://help.github.com/articles/fork-a-repo/) using the **fork** button on the top right corner at 4. [Clone your fork repository](https://help.github.com/articles/cloning-a-repository/) on to your computer. @@ -15,6 +15,7 @@ Consul git repo is hosted at Github.com, we recommend using it for your fork's r ## Why make code public? We strongly recommend making code public for multiple reasons: + - **Transparency**: It should be part of the culture of public entities that adopt Consul, as well as any organization or group. - **Support**: If you need technical help, both community and Consul core team will be able to understand and advice by easily seeing involved code. - **Collaboration**: By other professionals, citizens, etc... diff --git a/docs/en/getting_started/update.md b/docs/en/getting_started/update.md index 1c312dd7a..cede402f7 100644 --- a/docs/en/getting_started/update.md +++ b/docs/en/getting_started/update.md @@ -3,13 +3,14 @@ ## Configuring your git remotes If you created your fork correctly and cloned it locally, running: + ```bash git remote -v ``` it should output something alike: -> origin git@github.com:your_user_name/consul.git (fetch)
+> origin git@github.com:your_user_name/consul.git (fetch)\ > origin git@github.com:your_user_name/consul.git (push) Now we have to add CONSUL's github as upstream remote with: @@ -26,9 +27,9 @@ git remote -v again you should get: -> upstream git@github.com:consul/consul.git (fetch)
-> upstream git@github.com:consul/consul.git (push)
-> origin git@github.com:your_user_name/consul.git (fetch)
+> upstream git@github.com:consul/consul.git (fetch)\ +> upstream git@github.com:consul/consul.git (push)\ +> origin git@github.com:your_user_name/consul.git (fetch)\ > origin git@github.com:your_user_name/consul.git (push) ## Pulling changes from CONSUL @@ -42,6 +43,7 @@ git checkout -b upstream ``` Then we can fetch all changes from **consul** remote server with: + ```bash git fetch upstream ``` @@ -64,4 +66,4 @@ C. You get some git errors along with a `Automatic merge failed; fix conflicts a Now you can just simply push your **upstream** branch to github and create a Pull Request so you can easily check all changes going into your repo, and see your tests suite runs. -Remember you can always quickly check changes that will come from CONSUL to your fork by replacing **your_org_name** on the url: https://github.com/your_org_name/consul/compare/master...consul:master. +Remember you can always quickly check changes that will come from CONSUL to your fork by replacing **your_org_name** on the url: . diff --git a/docs/en/installation/basic_configuration.md b/docs/en/installation/basic_configuration.md index e6ecd3865..3c91c7439 100644 --- a/docs/en/installation/basic_configuration.md +++ b/docs/en/installation/basic_configuration.md @@ -32,7 +32,7 @@ If you activate the geozones you can also display an image that represents the a ## Map to geolocate proposals -You can allow users to place proposals on a map when creating proposals. To do this you have to define which map you want to show. +You can allow users to place proposals on a map when creating proposals. To do this you have to define which map you want to show. First go to the "Settings" menu and to the "Global Settings" submenu. There you will find three parameters that you will have to fill in: * Latitude. Latitude to show the map position diff --git a/docs/en/installation/create_deploy_user.md b/docs/en/installation/create_deploy_user.md index 2f079273f..48fd6c4db 100644 --- a/docs/en/installation/create_deploy_user.md +++ b/docs/en/installation/create_deploy_user.md @@ -20,11 +20,13 @@ Let's create a `wheel` group and add the user `jupiter` to this group. Now let's give sudo privileges to the `wheel` group and allow it to not use a password, this is important so that the installer doesn't get stalled waiting for a password. First we open the sudoers file: + ``` sudo visudo -f /etc/sudoers ``` And we add this line at the end: + ``` %wheel ALL=(ALL) NOPASSWD: ALL ``` @@ -32,6 +34,7 @@ And we add this line at the end: Now we need to give the keys of the server to the new user. Don’t close the server terminal window, because you can lock yourself out of your server if there is a mistake. Let's create the necessary directory in the server to upload the public key: + ``` su jupiter cd ~ @@ -40,7 +43,6 @@ cd .ssh nano authorized_keys ``` - Make sure you have [generated a public key](generating_ssh_key.md) in your local terminal. Open another local terminal window (not in the server) and type: diff --git a/docs/en/installation/debian.md b/docs/en/installation/debian.md index fbfc03dc5..4e6b249e8 100644 --- a/docs/en/installation/debian.md +++ b/docs/en/installation/debian.md @@ -1,4 +1,4 @@ -## Configuration for development and test environments (Debian GNU/Linux 9.8) +# Configuration for development and test environments (Debian GNU/Linux 9.8) ## Superuser @@ -8,7 +8,6 @@ Note that 'sudo' is not installed by default in Debian. It's possible to install su ``` - > For [Vagrant](/en/installation/vagrant.md) run: > ``` > sudo su - diff --git a/docs/en/installation/deploying-on-heroku.md b/docs/en/installation/deploying-on-heroku.md index 957d710b7..e04efb507 100644 --- a/docs/en/installation/deploying-on-heroku.md +++ b/docs/en/installation/deploying-on-heroku.md @@ -127,7 +127,7 @@ Add this to `config/secrets.yml`, under the `production:` section: Important: Turn on one worker dyno so that emails get sent. -## Optional but recommended: +## Optional but recommended ### Install rails\_12factor and specify the Ruby version @@ -179,6 +179,7 @@ heroku config:set RAILS_MAX_THREADS=3 ``` I also recommend to set the following: + ```bash heroku config:set RAILS_SERVE_STATIC_FILES=enabled heroku config:set RAILS_ENV=production diff --git a/docs/en/installation/documentation_and_guides.md b/docs/en/installation/documentation_and_guides.md index 5b1319183..142ecf5a0 100644 --- a/docs/en/installation/documentation_and_guides.md +++ b/docs/en/installation/documentation_and_guides.md @@ -1,6 +1,6 @@ # CONSUL Documentation and guides -There are several guides where you can read very detailed information about CONSUL and its possibilities. You can find them all at: http://consulproject.org/en/#documentation +There are several guides where you can read very detailed information about CONSUL and its possibilities. You can find them all at: - **CONSUL Use Guide**. In this guide you can see different ways to use CONSUL and examples of participation processes. - **CONSUL Administration Guide**. This guide contains detailed information on the administration and management of CONSUL. diff --git a/docs/en/installation/servers.md b/docs/en/installation/servers.md index 483d6a1fe..ad077cd36 100644 --- a/docs/en/installation/servers.md +++ b/docs/en/installation/servers.md @@ -1,19 +1,21 @@ # Production and Staging servers -## Recommended Minimum System Requirements: +## Recommended Minimum System Requirements -### 1. Production Server: - - Distribution: Ubuntu 16.04.X - - RAM: 32GB - - Processor: Quad core - - Hard Drive: 20 GB - - Database: Postgres +### 1. Production Server -### 2. Staging Server: - - Distribution: Ubuntu 16.04.X - - RAM: 16GB - - Processor: Dual core - - Hard Drive: 20 GB - - Database: Postgres +- Distribution: Ubuntu 16.04.X +- RAM: 32GB +- Processor: Quad core +- Hard Drive: 20 GB +- Database: Postgres + +### 2. Staging Server + +- Distribution: Ubuntu 16.04.X +- RAM: 16GB +- Processor: Dual core +- Hard Drive: 20 GB +- Database: Postgres If your city has a population of over 1.000.000, consider balancing your load using 2-3 production servers and a separate server for the database. diff --git a/docs/en/installation/ubuntu.md b/docs/en/installation/ubuntu.md index 526a7955e..5d6cf0d40 100644 --- a/docs/en/installation/ubuntu.md +++ b/docs/en/installation/ubuntu.md @@ -1,4 +1,4 @@ -## Configuration for development and test environments (Ubuntu 18.04) +# Configuration for development and test environments (Ubuntu 18.04) ## System update diff --git a/docs/en/installation/using-aws-s3-as-storage.md b/docs/en/installation/using-aws-s3-as-storage.md index 356e51d03..f0223f885 100644 --- a/docs/en/installation/using-aws-s3-as-storage.md +++ b/docs/en/installation/using-aws-s3-as-storage.md @@ -29,6 +29,7 @@ Run `bundle install` to apply your changes. This guide will assume that you have an Amazon account configured to use S3 and that you created a bucket for your instance of CONSUL. It is highly recommended to use a different bucket for each instance (production, preproduction, staging). You will need the following information: + - the **name** of the S3 bucket - the **region** of the S3 bucket (`eu-central-1` for UE-Francfort for example) - the **hostname** of the S3 bucket (`s3.eu-central-1.amazonaws.com` for Francfort, for example) diff --git a/docs/en/installation/vagrant.md b/docs/en/installation/vagrant.md index 5114fad5d..c4a2d6b71 100644 --- a/docs/en/installation/vagrant.md +++ b/docs/en/installation/vagrant.md @@ -9,6 +9,7 @@ Vagrant is compatible for [Debian](/en/installation/debian.md) and [Ubuntu](/en/ To access the application through the browser at `localhost:3000` we must forward a port and run the rails server with a binding option: ## Port forwarding + Open the Vagrant configuration file: ``` @@ -33,7 +34,7 @@ Reload your virtual machine: vagrant reload ``` -# Running the rails server +## Running the rails server In your virtual machine, run the application server, binding to your local ip address: diff --git a/docs/en/open_source/contributing.md b/docs/en/open_source/contributing.md index 80492952f..73e7694ef 100644 --- a/docs/en/open_source/contributing.md +++ b/docs/en/open_source/contributing.md @@ -9,6 +9,7 @@ If you have seen anything wrong in the platform performance or directly in the c Before doing it, **please take some time to check the [existing issues](https://github.com/consul/consul/issues) and make sure what you are about to report isn't already reported** by another person. In case someone else reported the same problem before, if you have more details about it you can write a comment in the issue page -a little more help can make a huge difference! In order to write a new issue, take into account these few tips to make it easy to read and comprehend: + - Try to use a descriptive and to-the-point title. - It's a good idea to include some sections -in case they're needed- such as: steps to reproduce the bug, expected behaviour/response, actual response or screenshots. - Also it could be helpful to provide your operating system, browser version and installed plugins. diff --git a/docs/es/README.md b/docs/es/README.md index 952a89461..f0c5567e3 100644 --- a/docs/es/README.md +++ b/docs/es/README.md @@ -68,7 +68,7 @@ Pero para ciertas acciones, como apoyar, necesitarás un usuario verificado, el ## Documentación -La documentación de este proyecto se encuentra en https://github.com/consul/docs +La documentación de este proyecto se encuentra en ## Licencia diff --git a/docs/es/customization/customization.md b/docs/es/customization/customization.md index 1ff6afb9b..9584a5d33 100644 --- a/docs/es/customization/customization.md +++ b/docs/es/customization/customization.md @@ -1,9 +1,9 @@ # Customization * [Introducción](introduction.md) -* [Textos & Traducciones](translations.md) +* [Traducciones y Textos](translations.md) * [Imágenes](images.md) -* [Vistas & Estilos](views_and_styles.md) +* [Vistas y Estilos](views_and_styles.md) * [Javascript](javascript.md) * [Modelos](models.md) * [Componentes](components.md) diff --git a/docs/es/customization/images.md b/docs/es/customization/images.md index 9e5d163e8..2fa72e4f2 100644 --- a/docs/es/customization/images.md +++ b/docs/es/customization/images.md @@ -14,4 +14,4 @@ Si quieres sobreescribir alguna imagen debes primero fijarte el nombre que tiene Puedes encontrar el mapa de la ciudad en [`/app/assets/images/map.jpg`](https://github.com/consul/consul/blob/master/app/assets/images/map.jpg), simplemente reemplazalo con una imagen de los distritos de tu ciudad ([ejemplo](https://github.com/ayuntamientomadrid/consul/blob/master/app/assets/images/map.jpg)). -Después te recomendamos utilizar una herramienta online como http://imagemap-generator.dariodomi.de/ o https://www.image-map.net/ para generar las coordenadas para poder establecer un [image-map](https://www.w3schools.com/tags/tag_map.asp) sobre cada distrito. Estas coordenadas deben ser introducidas en la respectiva Geozona creada en el panel de administración (`/admin/geozones`) +Después te recomendamos utilizar una herramienta online como o para generar las coordenadas para poder establecer un [image-map](https://www.w3schools.com/tags/tag_map.asp) sobre cada distrito. Estas coordenadas deben ser introducidas en la respectiva Geozona creada en el panel de administración (`/admin/geozones`) diff --git a/docs/es/customization/introduction.md b/docs/es/customization/introduction.md index 4cc703f26..704ae0642 100644 --- a/docs/es/customization/introduction.md +++ b/docs/es/customization/introduction.md @@ -28,67 +28,80 @@ Este servicio tiene como objetivo poder ofrecer todos los contenidos dinámicos Cuando un usuario accede a una pantalla con un idioma donde parte del contenido dinámico que esta visualizando no tiene traducciones, dispondrá de un botón para solicitar la traducción de todo el contenido. Este contenido se enviará a un traductor automático (en este caso [Microsoft TranslatorText](https://azure.microsoft.com/es-es/products/cognitive-services/translator/)) y en cuanto se obtenga la respuesta, todas estas traducciones estarán disponibles para cualquier usuario. -#### Como empezar +### Como empezar + Para poder utilizar esta funcionalidad es necesario realizar los siguientes pasos: + 1. Disponer de una api key para conectarse con el servicio de traducción. Para ello necesitamos una [cuenta en Azure](https://azure.microsoft.com/es-es/) 1. Una vez que haya iniciado sesión en el portal de Azure, subscríbase a Traductor en Cognitive Services. 1. Una vez subscrito al servicio de Translator Text, tendrá accesibles 2 api keys en la sección **Administración de recursos > Claves y punto de conexión** que serán necesarias para la configuración del servicio de traducciones en su aplicación. -#### Configuración +### Configuración + Para activar el servicio de traducciones en su aplicación debe completar los siguientes pasos -##### Añadir api key en la aplicación +#### Añadir api key en la aplicación + En el apartado anterior hemos comentado que una vez subscritos al servicio de traducciones disponemos de 2 api keys. Para configurar el servicio correctamente en nuestra aplicación deberemos añadir una de las dos api keys en el archivo `secrets.yml` en la sección `apis:` con la key `microsoft_api_key` como podemos ver en la siguiente imágen: ![Add api key to secrets](../../img/translations/remote_translations/add-api-key-to-secrets.png) -##### Activar funcionalidad +#### Activar funcionalidad + Una vez disponemos de la nueva key en el `secrets.yml` ya podemos proceder a activar la funcionalidad. Para activar la funcionalidad deberá realizar 2 pasos: + 1. Ejecutar el siguiente comando `bin/rake settings:create_remote_translations_setting RAILS_ENV=production` 1. Acceder a través del panel de administración de su aplicación a la sección **Configuración > Funcionalidades** y activar el módulo de **Traducciones Remotas** como se puede ver a continuación: -![Active remote translations](../../img/translations/remote_translations/active-remote-translations-es.png) + ![Active remote translations](../../img/translations/remote_translations/active-remote-translations-es.png) + +### Funcionalidad -#### Funcionalidad Una vez tenemos la api key en nuestro `secrets.yml` y el módulo activado, los usuarios ya podrán utilizar la funcionalidad. Para aclarar el funcionamiento, se adjuntan unos pantallazos de como interactua la aplicación con nuestros usuarios: + * Cuando un usuario accede a una pantalla en un idioma en el que no están disponibles todas las traducciones, le aparecerá un texto en la parte superior de la pantalla y un botón para poder solicitar la traducción. (**Nota:** *En el caso de acceder con un idioma no soportado por el servicio de traducción no se mostrará ningún texto ni botón de traducción. Ver sección: Idiomas disponibles para la traducción remota*) -![Display text and button](../../img/translations/remote_translations/display-text-and-button-es.png) + ![Display text and button](../../img/translations/remote_translations/display-text-and-button-es.png) * Una vez el usuario pulsa el botón de `Traducir página` se encolan las traducciones y se recarga la pantalla con un notice (*informando que se han solicitado correctamente las traducciones*) y un texto informativo en la cabecera (*explicando cuando podrá ver estas traducciones*). -![Display notice and text after enqueued translations](../../img/translations/remote_translations/display-notice-and-text-after-enqueued-es.png) + ![Display notice and text after enqueued translations](../../img/translations/remote_translations/display-notice-and-text-after-enqueued-es.png) * Si un usuario accede a una pantalla que no dispone de traducciones pero ya han sido solicitadas por otro usuario. La aplicación no le mostrará el botón de traducir, pero si un texto informativo en la cabecera (*explicando cuando podrá ver estas traducciones*). -![Display text explaining that translations are pending](../../img/translations/remote_translations/display-text-translations-pending-es.png) + ![Display text explaining that translations are pending](../../img/translations/remote_translations/display-text-translations-pending-es.png) * Las peticiones de traducción se delegan a `Delayed Job` y en cuanto haya sido procesada, el usuario después de refrescar su página podrá ver el contenido traducido. -![Display translated content](../../img/translations/remote_translations/display-translated-content-es.png) + ![Display translated content](../../img/translations/remote_translations/display-translated-content-es.png) +### Idiomas disponibles para la traducción remota -#### Idiomas disponibles para la traducción remota Actualmente estos son todos los [idiomas disponibles](https://api.cognitive.microsofttranslator.com/languages?api-version=3.0) en el servicio de traducción: + ```yml ["af", "am", "ar", "as", "az", "ba", "bg", "bn", "bo", "bs", "ca", "cs", "cy", "da", "de", "dv", "el", "en", "es", "et", "eu", "fa", "fi", "fil", "fj", "fo", "fr", "fr-CA", "ga", "gl", "gu", "ha", "he", "hi", "hr", "hsb", "ht", "hu", "hy", "id", "ig", "ikt", "is", "it", "iu", "iu-Latn", "ja", "ka", "kk", "km", "kmr", "kn", "ko", "ku", "ky", "ln", "lo", "lt", "lug", "lv", "lzh", "mg", "mi", "mk", "ml", "mn-Cyrl", "mn-Mong", "mr", "ms", "mt", "mww", "my", "nb", "ne", "nl", "nso", "nya", "or", "otq", "pa", "pl", "prs", "ps", "pt", "pt-PT", "ro", "ru", "run", "rw", "sk", "sl", "sm", "sn", "so", "sq", "sr-Cyrl", "sr-Latn", "st", "sv", "sw", "ta", "te", "th", "ti", "tk", "tlh-Latn", "tlh-Piqd", "tn", "to", "tr", "tt", "ty", "ug", "uk", "ur", "uz", "vi", "xh", "yo", "yua", "yue", "zh-Hans", "zh-Hant", "zu"] ``` + De todos los idiomas que actualmente tiene Consul definidos (`available_locales`) en `config/application.rb` el único que no está en la lista anterior y por lo tanto no se ofrece servicio de traducción es el valenciano `["val"]`. -#### Costes +### Costes + El servicio de traducción utilizado tiene los [precios](https://azure.microsoft.com/es-es/pricing/details/cognitive-services/translator/) más competitivos del mercado. El precio por cada 1 Millón de caracteres traducidos asciende a 10 $ y sin ningún tipo de coste fijo al mes. Aunque se han tomado medidas técnicas para evitar un mal uso de este servicio, recomendamos la creación de Alertas que ofrece Azure para que un Administrador pueda ser notificado en el caso de detectar un uso fuera de lo común del servicio. Este servicio tiene un coste de 0,10 $ al mes. Para crear una Alerta en Azure debemos seguir los siguientes pasos: + 1. Inicie sesión en **Azure Portal**. 1. Accede al servicio **Traductor** creado anteriormente. 1. Accede en el menu lateral a **Supervisión > Alertas**: - 1. Accedemos a **Crear regla de alertas** - 1. En **Selección de una señal** seleccionamos `Text Characters Translated` - 1. Una vez seleccionada debemos definir la lógica de la Alerta para que se ajuste a nuestras necesidades. Ej: Rellene el campo "Operador" con el valor "Mayor que", rellene el campo "Tipo de Agregación" con el valor "Total" y por último rellene el campo "Valor del umbral" por el número de caracteres que consideramos que deben traducirse antes de ser notificados. En esta sección también se puede configurar el periodo de tiempo y la frecuencia de evaluación. - 1. Para poder ser notificados tenemos que crear un **Grupo de Acciones** y asociarla a esta Alerta que estamos creando. Para ello accedemos al botón de **Crear** y rellenamos el formulario. Como se puede observar hay diferentes tipos de acciones, debemos seleccionar **Correo electrónico/SMS/Insertar/Voz** y configurar la opción que consideremos conveniente según nuestras necesidades. - 1. Una vez creado este grupo de acciones, ya queda directamente asociado a la regla que estamos creando. - 1. Por último ya solo queda añadir un nombre y clicar sobre el botón **Revisar y crear** + 1. Accedemos a **Crear regla de alertas** + 1. En **Selección de una señal** seleccionamos `Text Characters Translated` + 1. Una vez seleccionada debemos definir la lógica de la Alerta para que se ajuste a nuestras necesidades. Ej: Rellene el campo "Operador" con el valor "Mayor que", rellene el campo "Tipo de Agregación" con el valor "Total" y por último rellene el campo "Valor del umbral" por el número de caracteres que consideramos que deben traducirse antes de ser notificados. En esta sección también se puede configurar el periodo de tiempo y la frecuencia de evaluación. + 1. Para poder ser notificados tenemos que crear un **Grupo de Acciones** y asociarla a esta Alerta que estamos creando. Para ello accedemos al botón de **Crear** y rellenamos el formulario. Como se puede observar hay diferentes tipos de acciones, debemos seleccionar **Correo electrónico/SMS/Insertar/Voz** y configurar la opción que consideremos conveniente según nuestras necesidades. + 1. Una vez creado este grupo de acciones, ya queda directamente asociado a la regla que estamos creando. + 1. Por último ya solo queda añadir un nombre y clicar sobre el botón **Revisar y crear** + +### Añadir un nuevo servicio de traducción -#### Añadir un nuevo servicio de traducción En el caso de que se quieran integrar más servicios de traducción por cualquier motivo (aparece un nuevo en el mercado más competitivo, se quiere cambiar para contemplar los idiomas que actualmente no tienen soporte, etc) se ha dejado preparado el código para poder añadirlo con las mínimas modificaciones posibles. Esto es posible gracias a la class `RemoteTranslations::Caller` que es una capa intermedia entre la gestión de los contenidos sin traducir y el Cliente de traducción de Microsoft utilizado actualmente. Una buena solución para añadir otro servicio de traducción sería sustituir la llamada al `MicrosoftTranslateClient` dentro del método `translations` del `RemoteTranslations::Caller` por el nuevo servicio implementado. @@ -106,26 +119,29 @@ class RemoteTranslationsCaller ... end -``` +``` ## Interfaz de traducción Esta funcionalidad permite a los usuarios introducir contenidos dinámicos en diferentes idiomas a la vez. Cualquier usuario administrador de Consul puede activar o desactivar esta funcionalidad a través del panel de administración de la aplicación. Si desactivas esta funcionalidad (configuración de la funcionalidad por defecto) los usuarios sólo podrán introducir un idioma. -#### Activar funcionalidad +### Activar funcionalidad + Para activar la funcionalidad deberá realizar 2 pasos: + 1. Ejecutar el siguiente comando `bin/rake settings:create_translation_interface_setting RAILS_ENV=production` (Este paso sólo es necesario para instalaciones de Consul existentes que incorporan esta funcionalidad, para nuevas instalaciones no es necesario) 1. Accedediendo como usuario administrador a través del panel de administración de su aplicación a la sección **Configuración > Funcionalidades** y activando el módulo de **Interfaz de traducción** como se puede ver a continuación: -![Active interface translations](../../img/translations/interface_translations/active-interface-translations-es.png) + ![Active interface translations](../../img/translations/interface_translations/active-interface-translations-es.png) + +### Casos de uso -#### Casos de uso Dependiendo de si activamos o desactivamos el módulo de **Interfaz de traducción** veremos los formularios accesibles por el usuario de la siguiente manera: * Cuando la interfaz de traducción esta activa: -Como podemos ver en la imagen a continuación la interfaz de traducción tiene 2 selectores, el primero "Seleccionar idioma" permite cambiar entre los lenguajes activos y el segundo selector "Añadir idioma" permite añadir nuevos idiomas al formulario. Los campos traducibles se pueden distinguir fácilmente mediante un fondo azul de los que no lo son. También disponemos de un botón `Eliminar idioma` para eliminar un idioma en caso de necesitarlo. Si un usuario elimina accidentalmente un idioma puede recuperarlo añadiendo dicho idioma otra vez al formulario. -Esta funcionalidad está visible tanto para las páginas de creación como para las páginas de edición. -![Translations inteface enabled](../../img/translations/interface_translations/translations-interface-enabled-es.png) + Como podemos ver en la imagen a continuación la interfaz de traducción tiene 2 selectores, el primero "Seleccionar idioma" permite cambiar entre los lenguajes activos y el segundo selector "Añadir idioma" permite añadir nuevos idiomas al formulario. Los campos traducibles se pueden distinguir fácilmente mediante un fondo azul de los que no lo son. También disponemos de un botón `Eliminar idioma` para eliminar un idioma en caso de necesitarlo. Si un usuario elimina accidentalmente un idioma puede recuperarlo añadiendo dicho idioma otra vez al formulario. + Esta funcionalidad está visible tanto para las páginas de creación como para las páginas de edición. + ![Translations inteface enabled](../../img/translations/interface_translations/translations-interface-enabled-es.png) * Cuando la interfaz de traducción esta desactivada: -Cuando esta funcionalidad está desactivada los formularios se renderizan sin la interfaz de traducción y sin resaltar los campos traducibles con fondo azul. -![Translations inteface enabled](../../img/translations/interface_translations/translations-interface-disabled-es.png) + Cuando esta funcionalidad está desactivada los formularios se renderizan sin la interfaz de traducción y sin resaltar los campos traducibles con fondo azul. + ![Translations inteface enabled](../../img/translations/interface_translations/translations-interface-disabled-es.png) diff --git a/docs/es/customization/translations.md b/docs/es/customization/translations.md index a53398a5e..c18f48d37 100644 --- a/docs/es/customization/translations.md +++ b/docs/es/customization/translations.md @@ -1,4 +1,6 @@ -# Traducciones +# Traducciones y Textos + +## Traducciones Actualmente Consul esta traducido total o parcialmente a multiples idiomas, visita el proyecto en [Crowdin](https://crowdin.com/project/consul) @@ -8,7 +10,7 @@ En el caso de que tu lenguage no este presente en el proyecto de Crowdin, por fa Si quieres ver las traducciones de los textos de la web, puedes encontrarlos en los ficheros formato YML disponibles en `config/locales/`. Puedes leer la [guía de internacionalización](http://guides.rubyonrails.org/i18n.html) de Ruby on Rails sobre como funciona este sistema. -# Textos personalizados +## Textos personalizados Dado que CONSUL está en evolución continua con nuevas funcionalidades, y para que mantener tu fork actualizado sea más sencillo, recomendamos no modificar los ficheros de traducciones, es una mejor idea "sobreescribirlos" usando ficheros personalizados en caso de necesidad de alterar un texto. @@ -30,7 +32,7 @@ es: Si creamos el fichero `config/locales/custom/es/general.yml` y modificamos "Ayuntamiento de Madrid" por el nombre de la organización que se este haciendo la modificación. Recomendamos directamente copiar los ficheros `config/locales/` e ir revisando y corrigiendo las que querramos, borrando las líneas que no querramos traducir. -# Mantener tus Textos Personalizados y Lenguajes +## Mantener tus Textos Personalizados y Lenguajes CONSUL tiene la gema [i18n-tasks](https://github.com/glebm/i18n-tasks), es una herramienta estupenda para gestionar textos i18n. Prueba en tu consola `i18n-tasks health` para ver un reporte de estado. diff --git a/docs/es/customization/views_and_styles.md b/docs/es/customization/views_and_styles.md index 210bd2a58..7bde4ffa5 100644 --- a/docs/es/customization/views_and_styles.md +++ b/docs/es/customization/views_and_styles.md @@ -1,8 +1,10 @@ -# Vistas (HTML) +# Vistas y Estilos + +## Vistas (HTML) Si quieres modificar el HTML de alguna página puedes hacerlo copiando el HTML de `app/views` y poniendolo en `app/views/custom` respetando los subdirectorios que encuentres ahí. Por ejemplo si quieres modificar `app/views/pages/conditions.html` debes copiarlo y modificarla en `app/views/custom/pages/conditions.html.erb` -# Estilos CSS con SASS +## Estilos CSS con SASS Si quieres cambiar algun selector CSS (de las hojas de estilo) puedes hacerlo en el fichero `app/assets/stylesheets/custom.scss`. Por ejemplo si quieres cambiar el color del header (`.top-links`) puedes hacerlo agregando: diff --git a/docs/es/features/census_configuration.md b/docs/es/features/census_configuration.md index ba6dc600a..8e72df2fb 100644 --- a/docs/es/features/census_configuration.md +++ b/docs/es/features/census_configuration.md @@ -1,4 +1,4 @@ -## Configurar conexión con el Censo: +# Configurar conexión con el Censo Este servicio tiene como objetivo poder configurar la conexión con el Censo de Ayuntamiento a través del panel de Administración sin necesidad de modificar el código de la aplicación. @@ -6,18 +6,20 @@ Cabe destacar que para configurar correctamente esta conexión se requerirá de Actualmente la aplicación estaba pensada para enviar solo el **numero de documento** y el **tipo de documento**. Con esta nueva funcionalidad se habilita la posibilidad de enviar en caso de ser necesario los campos **fecha de nacimiento** y **código postal** +## Activar la funcionalidad -#### Activar la funcionalidad En la sección **Configuración > Configuración Global** se ha añadido una nueva pestaña **Configuración del Censo Remoto**. Si tenemos la funcionalidad desactivada veremos un texto informativo que nos indicará como activarla: ![Feature disabled](../../img/remote_census/feature-disabled-es.png) Para activar la funcionalidad deberá seguir las instrucciones de la imagen anterior: -1. Acceder a través del panel de administración de su aplicación a la sección **Configuración > Funcionalidades** y activar el módulo de **Configurar conexión al censo remoto (SOAP)** como se puede ver a continuación: -![Feature enabled](../../img/remote_census/feature-enabled-es.png) -#### Configuración +1. Acceder a través del panel de administración de su aplicación a la sección **Configuración > Funcionalidades** y activar el módulo de **Configurar conexión al censo remoto (SOAP)** como se puede ver a continuación: + ![Feature enabled](../../img/remote_census/feature-enabled-es.png) + +## Configuración + Una vez activada la funcionalidad, podremos acceder a la sección **Configuración > Configuración Global** y clicar en la pestaña **Configuración del Censo Remoto**. En esta pantalla se podrá rellenar toda la información necesaria para poder configurar la conexión con el Censo de cada Ayuntamiento. @@ -35,6 +37,7 @@ La información a rellenar esta dividida en tres apartados: ![Request Data](../../img/remote_census/request-data-es.png) Para ayudar a entender como rellenar cada uno de los campos, nos basaremos en un supuesto WebService que recibe un método llamado `:get_habita_datos` con la siguiente estructura: + ``` { request: { @@ -50,32 +53,27 @@ La información a rellenar esta dividida en tres apartados: ``` Campos necesarios para la petición: - - **Nombre del método de la petición**: Nombre del método que acepta el WebService del Censo del Ayuntamiento. Ejemplo: ![Request Data - Method name](../../img/remote_census/request-data-method-name-es.png) - - **Estructura de la petición**: Estructura de la petición que recibe el WebService del Censo del Ayuntamiento. Los valores "fijos" de esta petición deberán informarse. Los valores "dinámicos" relacionados con Tipo de Documento, Número de Documento, Fecha de Nacimiento y Código Postal deberán dejarse con valor null. Ejemplo: ![Request Data - Structure](../../img/remote_census/request-data-structure-es.png) ![Request Data - Structure](../../img/remote_census/request-data-structure-info-es.png) - - **Ruta para Tipo de Documento**: Ruta donde se encuentra el campo en la estructura de la petición que envía el Tipo de Documento. *NOTA: NO RELLENAR en caso de que el WebService no requiera el Tipo de Documento para verificar un usuario.* Ejemplo: ![Request Data - Path document type](../../img/remote_census/request-data-path-document-type-es.png) - - **Ruta para Número de Documento**: Ruta donde se encuentra campo en la estructura de la petición que envía el Número de Documento. *NOTA: NO RELLENAR en caso de que el WebService no requiera el Número de Documento para verificar un usuario.* Ejemplo: ![Request Data - Path document number](../../img/remote_census/request-data-path-document-number-es.png) - - **Ruta para Fecha de Nacimiento**: Ruta donde se encuentra campo en la estructura de la petición que envía la Fecha de Nacimiento. *NOTA: NO RELLENAR en caso de que el WebService no requiera la Fecha de Nacimiento para verificar un usuario.* @@ -84,7 +82,6 @@ La información a rellenar esta dividida en tres apartados: Ejemplo: ![Request Data - Path date of birth](../../img/remote_census/request-data-path-date-of-birth-es.png) - - **Ruta para Código Postal**: Ruta donde se encuentra campo en la estructura de la petición que envía el Código Postal. *NOTA: NO RELLENAR en caso de que el WebService no requiera el Código Postal para verificar un usuario.* @@ -127,41 +124,33 @@ La información a rellenar esta dividida en tres apartados: ``` Campos necesarios para parsear la respuesta: - - **Ruta para la Fecha de Nacimiento**: En que ruta de la respuesta se encuentra la Fecha de Nacimiento. Ejemplo: ![Response Data - Path date of birth](../../img/remote_census/response-data-path-date-of-birth-es.png) - - **Ruta para el Código Postal**: En que ruta de la respuesta se encuentra el Código Postal. Ejemplo: ![Response Data - Path postal code](../../img/remote_census/response-data-path-postal-code-es.png) - - **Ruta para el Distrito**: En que ruta de la respuesta se encuentra el Distrito. Ejemplo: ![Response Data - Path district](../../img/remote_census/response-data-path-district-es.png) - - **Ruta para el Género**: En que ruta de la respuesta se encuentra el Género. Ejemplo: ![Response Data - Path Gender](../../img/remote_census/response-data-path-gender-es.png) - - **Ruta para el Nombre**: En que ruta de la respuesta se encuentra Nombre. Ejemplo: ![Response Data - Path Name](../../img/remote_census/response-data-path-name-es.png) - - **Ruta para el Apellido**: En que ruta de la respuesta se encuentra el Apellido Ejemplo: ![Response Data - Path Last Name](../../img/remote_census/response-data-path-last-name-es.png) - - **Condición para detectar una respuesta válida**: Que ruta de la respuesta tiene que venir informado para considerarse una respuesta válida. Ejemplo: ![Response Data - Path valid response](../../img/remote_census/response-data-path-valid-response-es.png) - Una vez rellenados correctamente los datos generales, los campos necesarios de la petición y "todos" los campos para validar la respuesta, la aplicación podrá verificar cualquier usuario contra el WebService definido. diff --git a/docs/es/features/local_census.md b/docs/es/features/local_census.md index 77eebbda6..53e4a584e 100644 --- a/docs/es/features/local_census.md +++ b/docs/es/features/local_census.md @@ -1,30 +1,33 @@ -##Censo Local +# Censo Local Proporcionar a los usuarios administradores una forma de gestionar la base de datos del censo local a través del panel de administración **Configuración > Gestionar censo local**. Actualmente la única manera de manipular los registros de esta tabla es a través de la consola de rails. Permitir a los usuarios de administradores gestionar esta tabla de dos maneras diferentes: - - **Manualmente**: uno por uno a través de una interfaz CRUD. - - **Automáticamente**: a través de un proceso de importación. +- **Manualmente**: uno por uno a través de una interfaz CRUD. +- **Automáticamente**: a través de un proceso de importación. + +## Manualmente -#### Manualmente Provide a way to manage local census records to administrator users through administration interface. - Página de censo local -![Manage local census](../../img/local_census/manage-local-census-es.png) + ![Manage local census](../../img/local_census/manage-local-census-es.png) + - Añadir un nuevo registro -![Create local census record](../../img/local_census/add-local-census-record-es.png) + ![Create local census record](../../img/local_census/add-local-census-record-es.png) Funcionalidades: 1. Búsqueda por número_de_documento: Como local_census_records podría contener muchos registros, hemos añadido una función de búsqueda para permitir a los administradores encontrar los registros existentes por número de documento. 1. Evitar la introducción de registros duplicados: Se ha añadido una validación de modelo al siguiente par de atributos [:número_de_documento, :tipo_de_documento] -#### Automáticamente +## Automáticamente + Permite a los usuarios administradores importar registros del censo local a través de un archivo CSV. - Página de censo local -![Manage local census csv](../../img/local_census/manage-local-census-csv-en.png) + ![Manage local census csv](../../img/local_census/manage-local-census-csv-en.png) - Página para importar un CSV -![Create local census records csv](../../img/local_census/add-local-census-records-csv-en.png) + ![Create local census records csv](../../img/local_census/add-local-census-records-csv-en.png) diff --git a/docs/es/features/oauth.md b/docs/es/features/oauth.md index d45ec607f..849c1e1ba 100644 --- a/docs/es/features/oauth.md +++ b/docs/es/features/oauth.md @@ -3,6 +3,7 @@ Puedes configurar la autenticación con servicios externos usando OAuth, por ahora están soportados Twitter, Facebook y Google. ## 1. Crea una aplicación en la plataforma + Para cada plataforma, sigue las instrucciones en la sección de desarrolladores de su página web. ## 2. Establece la url de tu CONSUL diff --git a/docs/es/features/recommendations.md b/docs/es/features/recommendations.md index e17635ac4..8f657f8ef 100644 --- a/docs/es/features/recommendations.md +++ b/docs/es/features/recommendations.md @@ -3,17 +3,18 @@ Para Debates y Propuestas los usuarios logueados pueden encontrar elementos recomendados usando el filtro de ordenación "Recomendaciones". En este listado se muestran, ordenados por votos de forma descendiente, aquellos elementos que: + 1. Tengan etiquetas que interesen al usuario. Siendo las etiquetas de su interés aquellas usadas en propuestas que ha seguido. 2. El usuario no sea el autor de los mismos. 3. Sólo en el caso de las propuestas: únicamente se muestran aquellas que aún no hayan llegado al umbral de votos requerido, ocultándose además aquellas que el usuario este siguiendo. ## Cómo probar la funcionalidad -En nuestra instalación en local, si no hemos iniciado sesión, podemos comprobar visitando http://localhost:3000/proposals que no aparece la opción de ordenación "Recomendaciones" +En nuestra instalación en local, si no hemos iniciado sesión, podemos comprobar visitando que no aparece la opción de ordenación "Recomendaciones" ![Recommendations not logged in](../../img/recommendations/recommendations_not_logged_in.jpg) -Una vez iniciada sesión aparece el menú de ordenación, pero al no tener intereses nos muestra un mensaje "Sigue propuestas para que podamos darte recomendaciones" si lo visitamos en http://localhost:3000/proposals?locale=en&order=recommendations&page=1 +Una vez iniciada sesión aparece el menú de ordenación, pero al no tener intereses nos muestra un mensaje "Sigue propuestas para que podamos darte recomendaciones" si lo visitamos en ![Recommendations no follows](../../img/recommendations/recommendations_no_follows.jpg) diff --git a/docs/es/getting_started/configuration.md b/docs/es/getting_started/configuration.md index 608fafafc..0df5b551d 100644 --- a/docs/es/getting_started/configuration.md +++ b/docs/es/getting_started/configuration.md @@ -4,7 +4,7 @@ [Travis](https://travis-ci.org/) es un servicio de Integración Contínua, gratuito para proyectos OpenSource (como Consul y sus forks). Te ayudará a vigilar que en las Pull Requests no se rompan los tests. -1. Visita https://github.com/marketplace/travis-ci y haz click en el botón verde "**Install it for free**"" al pie de la página. +1. Visita y haz click en el botón verde "**Install it for free**"" al pie de la página. 2. Haz click en el botón verde "**Complete order and begin installation**" diff --git a/docs/es/getting_started/create.md b/docs/es/getting_started/create.md index 00f0efedd..abac3c6e8 100644 --- a/docs/es/getting_started/create.md +++ b/docs/es/getting_started/create.md @@ -6,7 +6,7 @@ El repositorio git de Consul está hospedado en Github.com, recomendamos lo uses 2. [Crea una Organización](https://help.github.com/articles/creating-a-new-organization-from-scratch/) en Github con el nombre de la ciudad u organización que usará Consul. **Esto no es obligatorio**, pero ayudará a entender el propósito del fork y la colaboración de otros usuarios. -3. [Forkea Consul](https://help.github.com/articles/fork-a-repo/) usando el botón de **fork** en la esquina superior derecha de https://github.com/consul/consul +3. [Forkea Consul](https://help.github.com/articles/fork-a-repo/) usando el botón de **fork** en la esquina superior derecha de 4. [Clona el repositorio de tu fork](https://help.github.com/articles/cloning-a-repository/) en tu ordenador @@ -15,6 +15,7 @@ El repositorio git de Consul está hospedado en Github.com, recomendamos lo uses ## ¿Porqué hacer el código público? Recomendamos publicar el código por varias razones: + - **Transparencia**: Debería ser parte de la cultura de aquellas entidades públicas que adopten Consul, así como cualquier organización o grupo. - **Soporte**: Si necesitas ayuda técnica, el resto de la comunidad o el equipo de Consul podrán entender y aconsejar mas fácilmente al ver el código implicado. - **Colaboración**: Por parte de otros profesionales, ciudadanos, etc... diff --git a/docs/es/getting_started/update.md b/docs/es/getting_started/update.md index 209e80978..cb7484221 100644 --- a/docs/es/getting_started/update.md +++ b/docs/es/getting_started/update.md @@ -10,7 +10,7 @@ git remote -v deberías ver algo como: -> origin git@github.com:your_user_name/consul.git (fetch)
+> origin git@github.com:your_user_name/consul.git (fetch)\ > origin git@github.com:your_user_name/consul.git (push) Ahora debes añadir el repositorio git de CONSUL como servidor remoto con: @@ -27,9 +27,9 @@ git remote -v deberías recibir algo como: -> upstream git@github.com:consul/consul.git (fetch)
-> upstream git@github.com:consul/consul.git (push)
-> origin git@github.com:your_user_name/consul.git (fetch)
+> upstream git@github.com:consul/consul.git (fetch)\ +> upstream git@github.com:consul/consul.git (push)\ +> origin git@github.com:your_user_name/consul.git (fetch)\ > origin git@github.com:your_user_name/consul.git (push) ## Obteniendo cambios de consul @@ -43,6 +43,7 @@ git checkout -b upstream ``` Y actualiza la información del repositorio de consul con las referencias a las ramas, tags, etc..: + ```bash git fetch upstream ``` @@ -65,4 +66,4 @@ C. Recibes mensajes de error de git junto con un `Automatic merge failed; fix co Ahora simplemente sube la rama **upstream** a github y crea un Pull Request, así podrás ver de manera sencilla todos los cambios que se han realizado en el repositorio y verás también como arranca la suite de tests. -Recuerda que siempre puedes comprobar rápidamente los cambios que tienes pendientes de integrar de CONSUL a tu fork sustituyendo **your_org_name** en la url: https://github.com/your_org_name/consul/compare/master...consul:master +Recuerda que siempre puedes comprobar rápidamente los cambios que tienes pendientes de integrar de CONSUL a tu fork sustituyendo **your_org_name** en la url: diff --git a/docs/es/installation/basic_configuration.md b/docs/es/installation/basic_configuration.md index 33539416a..aef36784f 100644 --- a/docs/es/installation/basic_configuration.md +++ b/docs/es/installation/basic_configuration.md @@ -5,6 +5,7 @@ Una vez que tengas CONSUL funcionando en el servidor, hay algunas opciones bási Para ello deberás acceder a tu instalación de CONSUL a través de cualquier navegador de internet e identificarte con el usuario de administración (inicialmente es el usuario `admin@consul.dev` con la contraseña `12345678`). Una vez identificado verás en la parte superior derecha de la pantalla el enlace "Admin" que te llevará a la interfaz de administración. Desde esta interfaz puedes configurar las siguientes opciones básicas: ## Parámetros de la configuración global + En el menú lateral encontrarás la opción "Configuración" y posteriormente el submenú "Configuración global". Aquí encontrarás muchos parámetros interesantes, pero por el momento te recomendamos definir algunos de los más básicos. Más adelante cuando estés más familiarizado con la herramienta podrás volver a configurar otros parámetros: - Nombre del sitio. Este nombre aparecerá en el asunto de emails, páginas de ayuda... @@ -16,9 +17,11 @@ En el menú lateral encontrarás la opción "Configuración" y posteriormente el - Cargos públicos de nivel x. CONSUL permite que algunas cuentas de usuario se marquen como "cuentas oficiales" apareciendo más resaltadas sus intervenciones en la plataforma. Esto por ejemplo se usa en una ciudad si se quieren definir cuentas para el Alcalde, los Concejales, etc. Esta opción de cargos públicos te permitirá definir la etiqueta oficial que aparece al lado de los nombres de usuario de estas cuentas de mayor importancia (nivel 1) a menor (nivel 5). ## Categorías de las propuestas + Cuando los usuarios crean propuestas en la plataforma se sugieren unas categorías generales, para ayudar a organizar las propuestas. Para definir estas categorías puedes entrar en el menú "Configuración global" y luego en el submenú "Temas de propuestas". En la parte superior puedes escribir temas y crearlos con el botón que aparece a continuación. -## Definición de geozonas +## Definición de geozonas + Las geozonas son áreas territoriales más pequeñas que la zona en la que usas CONSUL (por ejemplo los distritos en una ciudad en la que se use CONSUL). Si las activas permitirá por ejemplo que las propuestas ciudadanas se asignen a una zona concreta, o que las votaciones estén restringidas a la gente que viva en alguna zona. En el menú lateral encontrarás la opción "Configuración" y posteriormente el submenú "Gestionar distritos". A la derecha el botón "Crear distrito" te permitirá crear nuevas geozonas. Solo el nombre es necesario para definirlas, pero podrás agregar otros datos que son útiles en ciertas secciones. Inicialmente te recomendamos que empieces definiendo sólo los nombres de las zonas. @@ -27,7 +30,8 @@ Una vez definidas si creas una propuesta ciudadana verás como una de las opcion Si activas las geozonas puedes también mostrar una imagen que represente el área con las zonas. Esta imagen puedes cambiarla en el menú "Configuración global" en el submenú "Personalizar imágenes". La imagen por defecto que podrás cambiar es la titulada "map". -## Mapa para geolocalizar propuestas +## Mapa para geolocalizar propuestas + Puedes permitir que al crear propuestas los usuarios puedan situarlas en un mapa. Para ello tienes que definir qué mapa quieres mostrar. Accede en primer lugar al menú "Configuración" y posteriormente al submenú "Configuración global". Allí encontrarás tres parámetros que tendrás que rellenar: @@ -42,30 +46,36 @@ En esta página encontrarás una de las funcionalidades titulada como "Geolocali A continuación, en la parte superior de esta página accede a la pestaña "Configuración del Mapa". Si todo ha sido configurado correctamente verás aquí el mapa centrado en la latitud y longitud que introdujiste antes. Puedes centrar correctamente el mapa y cambiar el nivel de zoom directamente sobre el mapa, pulsando luego el botón "Actualizar" que hay debajo de él. -## Emails a usuarios +## Emails a usuarios + CONSUL envía por defecto una serie de correos electrónicos a los usuarios. Por ejemplo al crear una cuenta de usuario, al intentar recuperar la contraseña, al recibir un mensaje de otro usuario, etc. Todos los correos que se envían puedes visualizarlos en el menú "Mensajes a usuarios" en el submenú "Emails del sistema". Ahí podrás previsualizar cada correo electrónico y ver el archivo donde está el contenido del correo por si quieres cambiarlo. ## Páginas básicas de información + CONSUL cuenta con una serie de páginas básicas de información que se mostrarán a los usuarios. Por ejemplo "Política de Privacidad", "Preguntas Frecuentes", "Felicidades acabas de crear tu cuenta de usuario", etc. Puedes ver las páginas que existen por defecto y modificarlas en el menú "Contenido del sitio" en el submenú "Personalizar Páginas". ## Página principal del sitio + Al acceder a tu instalación de CONSUL los usuarios verán la página principal de la plataforma. Esta página es totalmente configurable, para que muestres el contenido que te parezca más relevante. Puedes modificarla desde el menú "Contenido del sitio" en el submenú "Homepage". Prueba a crear "Encabezados" y "Tarjetas" y a activar las diferentes funcionalidades que encontrarás debajo para ver el efecto que producen en tu página principal. ## Textos de la plataforma + Si accedes al menú "Contenido del sitio" y al submenú "Personalizar textos" verás diferentes pestañas con una serie de textos. Estos son todos los textos que se muestran en la plataforma. Por defecto puedes utilizar los que existen, pero en cualquier momento puedes acceder a esta sección para modificar cualquiera de los textos. Para tener más información sobre cómo añadir nuevas traducciones a tu versión de CONSUL accede a la sección "Textos y traducciones" de esta documentación. ## Canales de participación + Por defecto encontrarás en CONSUL diferentes formas de participación para los usuarios. Para empezar y familiarizarte con la plataforma te recomendamos tenerlos todos activados, pero puedes desactivar todos los que no te parezcan necesarios. Para ello accede al menú "Configuración" y posteriormente al submenú "Configuración global". En la parte superior de esta página encontrarás tres pestañas: "Configuración Global", "Funcionalidades" y "Configuración del Mapa". Accede a la segunda pestaña "Funcionalidades". Encontrarás diversas funcionalidades con los nombres de los diferentes canales de participación "Debates", "Propuestas", "Votaciones", "Legislación Colaborativa" y "Presupuestos Participativos". Puedes desactivar cualquiera de las funcionalidades y dejará de mostrarse en tu instalación de CONSUL. -### Más información y documentación detallada +### Más información y documentación detallada + Estas opciones anteriores te permitirán tener una versión básica de CONSUL que empezar a usar. Te recomendamos acceder a la sección [Documentación y guías sobre CONSUL](documentation_and_guides.md) donde podrás encontrar más documentación detallada. diff --git a/docs/es/installation/create_deploy_user.md b/docs/es/installation/create_deploy_user.md index 6abaa5165..c72d51b23 100644 --- a/docs/es/installation/create_deploy_user.md +++ b/docs/es/installation/create_deploy_user.md @@ -1,6 +1,6 @@ # Crear un usuario para hacer la instalación -[El instalador](https://github.com/consul/installer) de forma predeterminada se conecta como el usuario `root` sólo para crear un usuario` deploy`. Este usuario `deploy` es el que instala todas las librerías. Si no tiene acceso `root`, por favor pídale a su administrador de sistemas que siga estas instrucciones para crear un usuario manualmente. +[El instalador](https://github.com/consul/installer) de forma predeterminada se conecta como el usuario `root` sólo para crear un usuario `deploy`. Este usuario `deploy` es el que instala todas las librerías. Si no tiene acceso `root`, por favor pídale a su administrador de sistemas que siga estas instrucciones para crear un usuario manualmente. Puede crear un usuario llamado `deploy` o utilizar cualquier otro nombre. Como ejemplo, vamos a crear un usuario llamado `jupiter`. @@ -22,11 +22,13 @@ Creemos un grupo `wheel` y añadamos al usuario `jupiter` al grupo. Ahora démosle al grupo `wheel` derechos de superadministración sin necesidad de usar contraseña, esto es importante para que el instalador no se quede parado esperando una contraseña. Primero debemos abrir el archivo `sudoers`: + ``` sudo visudo -f /etc/sudoers ``` Y añadimos esta línea al final del archivo: + ``` %wheel ALL=(ALL) NOPASSWD: ALL ``` @@ -34,6 +36,7 @@ Y añadimos esta línea al final del archivo: Ahora tenemos que dar las claves del servidor al nuevo usuario. No cierre la ventana de la terminal del servidor, porque puede bloquearse si hay un error. Y escriba los siguientes comandos para crear el archivo necesario donde subir la clave pública: + ``` su jupiter cd ~ diff --git a/docs/es/installation/debian.md b/docs/es/installation/debian.md index 7f6464ba5..25602c811 100644 --- a/docs/es/installation/debian.md +++ b/docs/es/installation/debian.md @@ -1,4 +1,4 @@ -## Configuración para los entornos de desarrollo y pruebas (Debian GNU/Linux 9.8) +# Configuración para los entornos de desarrollo y pruebas (Debian GNU/Linux 9.8) ## Super usuario diff --git a/docs/es/installation/deploying-on-heroku.md b/docs/es/installation/deploying-on-heroku.md index 01bfbcd68..6f839234f 100644 --- a/docs/es/installation/deploying-on-heroku.md +++ b/docs/es/installation/deploying-on-heroku.md @@ -127,7 +127,7 @@ Añade el siguiente código a `config/secrets.yml`, en la sección `production:` Importante: Activa un "worker dyno" para que se envíen los correos electrónicos. -### Opcional (pero recomendado): +### Opcional (pero recomendado) ### Instalar rails\_12factor y especificar la versión de Ruby @@ -179,6 +179,7 @@ heroku config:set RAILS_MAX_THREADS=3 ``` También es recomendable configurar las siguientes variables: + ```bash heroku config:set RAILS_SERVE_STATIC_FILES=enabled heroku config:set RAILS_ENV=production diff --git a/docs/es/installation/documentation_and_guides.md b/docs/es/installation/documentation_and_guides.md index d95e32849..d5628e022 100644 --- a/docs/es/installation/documentation_and_guides.md +++ b/docs/es/installation/documentation_and_guides.md @@ -1,6 +1,6 @@ # Documentación y guías sonbre CONSUL -Hay diversas guías donde puedes leer información muy detallada sobre CONSUL y sus posibilidades. Puedes encontrarlas todas en: http://consulproject.org/es/#documentation +Hay diversas guías donde puedes leer información muy detallada sobre CONSUL y sus posibilidades. Puedes encontrarlas todas en: - **Guía de uso de CONSUL**. En esta guía puedes ver las diferentes maneras de usar CONSUL y ejemplos de procesos de participación. - **Guía de administración de CONSUL**. Esta guía contiene información detallada sobre la administración y gestión de CONSUL. diff --git a/docs/es/installation/servers.md b/docs/es/installation/servers.md index b8a88d848..ed00fe1c5 100644 --- a/docs/es/installation/servers.md +++ b/docs/es/installation/servers.md @@ -1,19 +1,21 @@ # Servidores de producción y pruebas -## Requisitos de sistema mínimos recomendados: +## Requisitos de sistema mínimos recomendados -### 1. Production Server: - - Distrubution: Ubuntu 16.04.X - - RAM: 32GB - - Processor: Quad core - - Hard Drive: 20 GB - - Database: Postgres +### 1. Production Server -### 2. Staging Server: - - Distrubution: Ubuntu 16.04.X - - RAM: 16GB - - Processor: Dual core - - Hard Drive: 20 GB - - Database: Postgres +- Distrubution: Ubuntu 16.04.X +- RAM: 32GB +- Processor: Quad core +- Hard Drive: 20 GB +- Database: Postgres + +### 2. Staging Server + +- Distrubution: Ubuntu 16.04.X +- RAM: 16GB +- Processor: Dual core +- Hard Drive: 20 GB +- Database: Postgres Si tu ciudad tiene una población superior a 1.000.000, considera añadir un balanceador de carga y usar 2-3 servidores de producción, además de un servidor de base de datos dedicado. diff --git a/docs/es/installation/ubuntu.md b/docs/es/installation/ubuntu.md index 3e72cca6c..00b148367 100644 --- a/docs/es/installation/ubuntu.md +++ b/docs/es/installation/ubuntu.md @@ -1,4 +1,4 @@ -## Configuración para los entornos de desarrollo y pruebas (Ubuntu 18.04) +# Configuración para los entornos de desarrollo y pruebas (Ubuntu 18.04) ## Actualización de sistema @@ -37,7 +37,7 @@ source ~/.bashrc ## Node.js -Para compilar los archivos estáticos (JS, CSS, imágenes, etc.), es necesario un _runtime_ de JavaScript. Node.js es la opción recomendada. +Para compilar los archivos estáticos (JS, CSS, imágenes, etc.), es necesario un _runtime_ de JavaScript. Node.js es la opción recomendada. Ejecuta en tu terminal: diff --git a/docs/es/installation/vagrant.md b/docs/es/installation/vagrant.md index d47c00fef..b37e9ec71 100644 --- a/docs/es/installation/vagrant.md +++ b/docs/es/installation/vagrant.md @@ -9,6 +9,7 @@ Vagrant es compatible para [Debian](/es/installation/debian.md) y [Ubuntu](/es/i Para acceder a la aplicación a través del navegador en la url `localhost:3000` debe enrutar el puerto de la aplicación y ejectuar el servidor de la aplicación con la opción `-b`: ## Enrutar el puerto de la aplicación + Abra el archivo de configuración de Vagrant: ``` @@ -33,7 +34,7 @@ Recargue la máquina virtual: vagrant reload ``` -# Ejecutar el servidor +## Ejecutar el servidor En su máquina virtual, debe ejecutar la aplicación enlanzándola a su IP local: diff --git a/docs/es/open_source/contributing.md b/docs/es/open_source/contributing.md index 92fe1bbdc..a298655d1 100644 --- a/docs/es/open_source/contributing.md +++ b/docs/es/open_source/contributing.md @@ -9,6 +9,7 @@ Si has visto algún error en la plataforma o directamente en el código, te anim Antes de hacerlo, **por favor tómate un tiempo para comprobar los [issues ya existentes](https://github.com/consul/consul/issues) y asegúrate de que lo que estás a punto de reportar no ha sido reportado previamente** por otra persona. De ser así, si tienes más detalles acerca de la incidencia puedes escribir un comentario en la página del issue ‑¡un poco de ayuda puede marcar una gran diferencia! Para escribir un nuevo issue, ten en cuenta estas recomendaciones para hacerlo más fácil de leer y comprender: + - Intenta usar un título descriptivo. - Es buena idea incluir algunas secciones -en caso de que sean necesarias- como los pasos para reproducir el error, el comportamiento o respuesta que cabría esperar, la respuesta que devuelve o capturas de pantalla. - También puede ser de ayuda incluir en la descripción tu sistema operativo, versión del navegador que usaste y posibles plugins instalados. @@ -18,6 +19,7 @@ Para escribir un nuevo issue, ten en cuenta estas recomendaciones para hacerlo m [Los issues en Consul](https://github.com/consul/consul/issues) con la etiqueta `PRs-welcome` son funcionalidades bien definidas que están listas para ser implementadas por cualquiera que se ofrezca a ello. Por otra parte, la etiqueta `not-ready` indica las funcionalidades o cambios que aún están pendientes de concretar, por lo que recomendamos no intentar resolverlos hasta que los/as administradores/as lleguen a una resolución. Te sugerimos seguir los siguientes pasos para facilitar el seguimiento de los cambios que vayas a hacer: + - Primero, añade un comentario en el issue para notificar que vas resolverlo. Si el issue tiene a alguien asignado significa que ya hay alguien encargado de él. - Crea un fork del proyecto. - Crea una rama de funcionalidad basada en la rama `master`. Para identificarla más fácilmente, puedes nombrarla con el número del issue seguido de un nombre conciso y descriptivo (por ejemplo: `123-fix_proposals_link`).