QueryJane | Platform administrators can share new companies and job offers from the "Admin dashboard" page on QueryJane Twitter account

View this thread on: d.buzz | hive.blog | peakd.com | ecency.com
·@kit.andres·
0.000 HBD
QueryJane | Platform administrators can share new companies and job offers from the "Admin dashboard" page on QueryJane Twitter account
QueryJane is a web application developed with Django that allows to connect with companies and experts in different sectors of the cannabis industry. Beta version is available [here](https://queryjane.net/).

<center>
![queryjanefull.png](https://res.cloudinary.com/hpiynhbhq/image/upload/v1519153400/im3sltvl4euph3a1fpbm.png)
</center>

In order to promote  registered companies and  created job offers, I have added a new functionality that allows to platform administrators to share companies profiles and job offers on the [official Qjane Twitter](https://twitter.com/queryjane) account.   Let me show you how it works:

## New Features
### Platform administrators dashboard.
Some users have administration permissions on the platform. For these users, there is now available a new section called "administrators dashboard". They can access to this new view by clicking the button `Qjane Admin` in the main menu dropdown. This link is available only for users with administration role.

<center>
![Screen Shot 2018-03-06 at 10.45.19 AM.png](https://res.cloudinary.com/hpiynhbhq/image/upload/v1520351151/jgoz73nxvdwqbfkz8yll.png)
</center>

By clicking this link, users will be redirected to the *admin dashboard* view. In this view there are available two lists. A list with active companies that have not been shared on the Qjane twitter account, and a list with active job offers that have not been shared on the Qjane tiwitter account.

<center>
![Screen Shot 2018-03-06 at 10.48.59 AM.png](https://res.cloudinary.com/hpiynhbhq/image/upload/v1520351393/a7ctl9ed4rqplxv9lgbb.png)
</center>

#### Share to Twitter account.

Per each company and per each job offer in this view, there is available a button that allows administrators to share the selected element in the Qjane Twitter account.

<center>
![Screen Shot 2018-03-06 at 10.52.48 AM.png](https://res.cloudinary.com/hpiynhbhq/image/upload/v1520351585/a8rxmn3duvatduacpjok.png)
</center>

By clicking this button, the company profile or the job offer detail will be shared in the Qjane Twitter account.

<center>
![Screen Shot 2018-03-06 at 10.54.04 AM.png](https://res.cloudinary.com/hpiynhbhq/image/upload/v1520351671/eyrafta7zcytybu1rewv.png)
</center>

Once a company or a job offer has been shared, the shared element will not be available on this the Administrators dashboard page again. Each company and each job offer can be shared only once.

***
I have integrated [twython](https://twython.readthedocs.io/en/latest/) to the project, a pure Python wrapper for the Twitter API. this library allows an easy integration with the official [Qjane Twitter account](https://twitter.com/queryjane).

To share a company profile or a job offer detail, I have created a function that runs as a second level task using [huey](https://github.com/coleifer/huey). *Why?* So as not to interfere with the normal flow of the page, because connecting with Twitter API could take some extra time. Take a look to these functions in the [code source](https://github.com/roadhousestudio/queryjane_app/blob/master/corporative/tasks.py). These tasks are executed by an Ajax request to a view launched when users click the `Share` button.

When a company profile is shared, the tweet looks like this:

<center>
![Screen Shot 2018-03-06 at 11.23.00 AM.png](https://res.cloudinary.com/hpiynhbhq/image/upload/v1520353418/xiwu2kyul3ginmuykiwp.png)
</center>

When a job offer is shared, the tweet looks like this:

<center>
![Screen Shot 2018-03-06 at 11.26.10 AM.png](https://res.cloudinary.com/hpiynhbhq/image/upload/v1520353615/g6yxki7v316s9digspfn.png)
</center>


***
*Commits from [ad0ed58](https://github.com/roadhousestudio/queryjane_app/commit/ad0ed58a9ca7ba7f38f43b3a99e63e92694c4823) to [d9ae32e](https://github.com/roadhousestudio/queryjane_app/commit/d9ae32ef685ec2a9ce628d7451175d4f46fbb132)*.

<center>
![Screen Shot 2018-02-03 at 10.23.10 PM.png](https://res.cloudinary.com/hpiynhbhq/image/upload/v1517714734/buanjqlm7hnwn4zoy4rq.png)
</center>

***

### How to contribute?
[QueryJane](https://queryjane.net/) has been developed using the [Django framework](https://www.djangoproject.com/). You can fork the project, and run it locally is very easy. Follow the steps described in the [open source repository](https://github.com/roadhousestudio/queryjane_app) installation guide. The project has been configured using Docker. you only need to install [Docker](http://docker.com/) and follow these steps.

### Future work.

Take a look to our [public trello board](https://trello.com/b/7fkft2vf/queryjane). This is the easiest way to know our roadmap.

* Activate  Spanish site.
* SEO optimization.
* Advertising campaign.

A Very complete application to boost the growth of a specific industry has been developing here. With a large number of tools to facilitate alliances and contacts within the cannabis industry, we are only a few design and SEO adjustments to be able to launch an advertising campaign on social networks  soon. Next days I will we working in the activation of the Spanish site by integrating  [i18n](https://docs.djangoproject.com/en/2.0/topics/i18n/translation/) to promote it in some South American countries in which there are legislations around the medicinal use of cannabis that allow entrepreneurship in this sector. Also, I will be working too on some strategies to promote the application in Canada and  USA.

If you want to contribute, please join my [Discord](https://discord.gg/hAmBYg).
***
Have happy days ✌

<br /><hr/><em>Posted on <a href="https://utopian.io/utopian-io/@kit.andres/queryjane-or-platform-administrators-can-share-new-companies-and-job-offers-from-the-admin-dashboard-page-to-queryjane-twitter">Utopian.io -  Rewarding Open Source Contributors</a></em><hr/>
👍 , , , , , , , , , , , , , , , , , , , , , , ,