Protevus is a highly versatile and extensible application server platform for the Dart programming language. Inspired by the Laravel framework, Protevus aims to provide a familiar and Laravel-compatible API, allowing developers to leverage their existing Laravel knowledge and experience in the Dart ecosystem. https://protevus.com
Find a file
thomashii@dukefirehawk.com 4f6c6caeb2 Upgraded to version 7
2022-08-31 00:10:33 +08:00
.vscode ANGEL_ENV -> production in launch.json 2019-04-18 12:04:54 -04:00
bin Upgrade to SDK 2.16.x 2022-04-26 08:02:17 +08:00
config Merge pull request #5 from dukefirehawk/v6/angel3-orm 2022-04-26 09:17:47 +08:00
lib Update to support v6.0.0 2022-03-15 13:25:51 +08:00
test Updated angel3-orm 2021-06-14 08:08:25 +08:00
views Update to support v6.0.0 2022-03-15 13:25:51 +08:00
web 1.1.0-alpha 2017-10-19 17:53:33 -04:00
.dockerignore Update to support v6.0.0 2022-03-15 13:25:51 +08:00
.gitignore Updated the ORM example 2021-07-25 17:11:58 +08:00
analysis_options.yaml Updated ORM template 2021-09-25 18:45:23 +08:00
CHANGELOG.md Update to support v6.0.0 2022-03-15 13:25:51 +08:00
Dockerfile Update to support v6.0.0 2022-03-15 13:25:51 +08:00
LICENSE Updated ORM template 2021-09-25 18:45:23 +08:00
pubspec.yaml Upgraded to version 7 2022-08-31 00:10:33 +08:00
README.md Upgrade to SDK 2.16.x 2022-04-26 08:02:17 +08:00

ORM Starter Application for Angel3 framework

This is an ORM starter application for Angel3 framework which is a full-stack Web framework in Dart. The default database is postgresql. mysql support is still in active development.

Installation & Setup

  1. Download and install Dart.

  2. Install postgresql version 10, 11, 12 and 13

  3. Create a new user and database in postgres using psql cli. For example:

     postgres=# create database appdb;
     postgres=# create user appuser with encrypted password 'App1970#';
     postgres=# grant all privileges on database appdb to appuser;
    
  4. Update the postgres section in the config/default.yaml file with the newly created user and database name.

     postgres:
         host: localhost
         port: 5432
         database_name: appdb
         username: appuser
         password: App1970#
         useSSL: false
         time_zone: UTC
    
  5. Run the migration to generate migrations and greetings tables in the database.

    dart bin/migrate.dart up
    

Development

  1. Run the following command to start Angel3 server in dev mode to hot-reloaded on file changes:

    dart --observe bin/dev.dart
    
  2. Modify the code and watch the changes applied to the application

  3. Insert a message into DB:

    curl -H "Content-Type: application/json" -X POST -d '{"message":"OK_Message" }' "http://localhost:3000/greetings/"
    

    or

    curl -X POST -d 'message=OK_Message2' "http://localhost:3000/greetings/"
    
  4. Query DB:

    http://localhost:3000/greetings/
    

Production

  1. Run the following command:

    dart bin/prod.dart
    
  2. Run as docker. Edit and run the provided Dockerfile to build the image.

Resources

Visit the Developer Guide for dozens of guides and resources, including video tutorials, to get up and running as quickly as possible with Angel3.

Examples and complete projects can be found here.

You can also view the API Documentation.