agiamas / export-opportunities

UK - Great.gov - Export Opportunities - Find and apply for overseas opportunities from businesses looking for products or services like yours.

Home Page:https://opportunities.export.great.gov.uk/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

CircleCI Dependency Status

DIT Exporting is GREAT

NOTE The name of the organisation has changed from UKTI to DIT. In all user-facing pages this change has been made, but some existing entities like databases may continue to be called ukti.

We aim to follow GDS service standards and GDS design principles.

Installation

  • Copy the application configuration
$ cp config/application.example.yml config/application.yml
  • Have an instance of redis-server running and configured in your application.yml

  • Have an instance of elasticsearch running (can be default localhost:9200) and configured in your application.yml

  • After setting up your database with rake db:migrate, you need to run the 2 elasticsearch rake tasks to setup the elasticsearch indexes:

    • rake elasticsearch:import_opportunities
    • rake elasticsearc:import_subscriptions

Running tests

Install PhantomJS, then run tests with bundle exec rspec

Style checking

Run style checks with bundle exec rubocop. This checks code against the Ruby Style Guide, with a couple of customisations.

Configure your editor's syntax checker to flag up rubocop rules.

Concepts

Users / Editors

  • There was originally a model called User which stored details of people who could access the admin site. This has been renamed to Editor, so User can be instead used for end-users who subscribe and apply for opportunities.

  • Editors can be one of four roles: Uploader, Previewer, Publisher or Administrator:

    • Uploaders can add new opportunities and edit ones they created. Can view only opportunities and enquiries of his own or that belong to the service provider he belongs to.
    • Previewers can view all opportunities, edit none. Can view all opportunities and enquiries.
    • Publishers can additionally publish opportunities so they appear on the site. Can view all opportunities and enquiries.
    • Administrators can also manage editor accounts. Can view all opportunities and enquiries.

License

MIT licensed. See the bundled LICENSE file for more details.

Deployment

  • You can deploy the project on Heroku or CF Gov PaaS with minimum effort as long as you setup environmental variables like you would do in localhost.

Contribution

You are welcome to contribute, please get in touch with Alex Giamas, Steven Burnell or Mateusz Lapsa Malawski.

About

UK - Great.gov - Export Opportunities - Find and apply for overseas opportunities from businesses looking for products or services like yours.

https://opportunities.export.great.gov.uk/

License:MIT License


Languages

Language:Ruby 48.2%Language:HTML 27.2%Language:CSS 16.7%Language:JavaScript 7.7%Language:PHP 0.1%Language:Shell 0.0%