Skip to content

Releases: materiahq/materia-designer-public

v0.7.0 - March Release 2017

11 Apr 23:00
Compare
Choose a tag to compare

I'm excited to announce the March Release v0.7 of Materia. A big step forward !

Some of the key highlights include:

  • Addons: You can install/uninstall addons within Materia Designer.

  • 3 new addons:

    • @materia/sengrid - Send emails in your application using Sendgrid
    • @materia/mailjet - Send emails in your application using Mailjet
    • @materia/users - Simple user management solution for Materia
  • Permissions management

  • UI Enhancements

Addons

An addon is a reusable and configurable component for your backend. It gives super power to your application. The goal behind addon is to write as less code as possible while being able to configure everything.
e.g. If you want User Management on your website, you can code it in your application, or you can install a user management addon which will automate all of this for you.

This release introduce an easy way to manage your addons in your Materia application.

Install

You can see the list of available addons directly in Materia Designer. You can install them in one click.

addons-install

You can do the same in your terminal using yarn or npm

e.g. for the addon of User Management

yarn add @materia/users

or

npm install @materia/users --save

Setup

Once an addon is installed, we enter in the setup phase to configure how the addon should work.

It may be a simple setup like for the Sendgrid Addon:

install-sendgrid

Or complex setup like for the User Management Addon (defined by the addon's developer)

install-user-management

Uninstall

Once you don't want an addon anymore, just remove it from Materia designer and everything associated with this addon will be removed (entities/queries/endpoints/data).

You can uninstall addons using yarn or npm

With Yarn:

yarn remove @materia/sendgrid

With NPM:
npm uninstall @materia/sendgrid --save

Addons Marketplace

The goal behind making addons is the desire to build a Marketplace of reusable and configurable backend component. It will soon be open to publish your npm/yarn package as a Materia addon.

We're working hard to bring a good documentation to explain how you can develop your own easily. In the meantime, you can browser official addons source code: @materia/users, @materia/sendgrid & @materia/mailjet

To share your addons with others, you can publish it on NPM so others will be able to install it easily using the terminal: npm install {your-addon} --save

Sendgrid & Mailjet Addon

Sendgrid/Mailjet addon has been released to send email with your Sendgrid/Mailjet account.

sendgrid-view

You can install these addons in Materia Designer in the Addons section or directly with npm or yarn

For Sendgrid:
npm install @materia/sendgrid --save
or
yarn add @materia/sendgrid

For Mailjet:
npm install @materia/mailjet --save
or
yarn add @materia/mailjet

To use this addon, you will need to setup your API Keys and your email address (used to send email). Once the setup completed, you'll be able to send email from your application endpoint using the query send in the entity sendgrid or mailjet depending which one you chose.

For the moment, both the Sendgrid and Mailjet addon are limited to send text email. Next step: use templates and HTML email and potentially create newsletter within Materia.

User Management Addon

One of the biggest step in this release is this addon. It enables you to quickly have your user management system up and running securely.

screen shot 2017-04-10 at 7 43 39 am

You can configure extra fields in the user entity to get exactly the data you need to know about your users.

You can enable at any time email verification to know if a user has its email verified. You can use this field to block unverified user on specific feature if you don't want to.
The email verification is done by communicating with the emailing addons (Mailjet and Sendgrid) to send lost password emails or signup emails.

This is an example of front which implement the User Management addon (thanks @GeoAstronaute !):

materia_user_management

This addon adds new endpoint permissions in your application to secure your data.

  • Authenticated => Only signed in user can access an endpoint with this permission
  • Connected User ID => Inject in the executed endpoint/query the parameter user_id with the id of the connected user.

You can define roles and user permission in the entity user_role and user_permission. Each time a role is created, a new endpoint permission is added with the role as name.

E.g. if you create the role "admin", a endpoint permission "Admin" will be created to authorize only authenticated user which have the user permission "admin"

Endpoint permissions Management

Addons were the only way to configure permissions. I thought it was really too limiting and was preventing users to secure their application correctly so we added some configuration files:

  • server/permissions.json - List of available permissions
  • server/permissions/*.js - Permission definition

A permission is just an Express middleware you can define yourself in the Permission Editor.

permissions-overview

The code to make a permission has this structure:

module.exports = function(req, res, next) => {
     //permission logic
     //call `next()` if the user is allowed
     //throw an error if the user is not allowed
}

UI Enhancement

Some work has been done in the UI:

  • (Global) Right sidenav animation (still a WIP for the left sidenav)
  • (Entities) Reduce zoom in entities (as the maximum zoom is still big)
  • (API) Endpoint information are better displayed
  • (Internal Editor) Enhance the title / action button display
  • (App Settings) Dark theme - In a more general way, all modal called within a dark sidenav will have a dark theme
  • (Database Settings) Loader animation while trying to connect the database

v0.6.0 - December release 2016

17 Jan 17:47
Compare
Choose a tag to compare

We wish you an happy new year with lots of success with your Materia application !

This new release is important for us as we consolidated lots of things in Materia Server thanks our new test suite.

File Treeview

This new version bring some enhancements with the file treeview to allow you to do the basic operations you usually do with your Finder (Mac) / Explorer (Windows) / Code editor :

  • Context menu to create / delete and rename files and folders

create-file

  • Move a file or a folder through drag & drop

move-file

Move server.json in .materia/ folder (#73)

In order to keep secret your production server password and production database password safe, we moved server.json in the .materia folder which is by default in the .gitignore to not add it accidentally on Github.

Tests suite

To prevent regression like #76, we've added lots of tests in our tests suite: https://travis-ci.org/webshell/materia-server

This point is still a work in progress and is intended to grow with the development to stay up to date with the source code.

Addons installation enhancement (#74)

Materia CLI now wrap the installation of an addon using materia install [addon-name]:

  • It makes sure the addons is listed in the package.json dependencies to help the discovery of addons.
  • It can ask for additional information needed for the installation of an addon (e.g. the API Keys of the email service in the emailing addon, or the mode of authentication in the user management addon). This configuration step is also available with materia setup [addon-name]

Other changes

  • Change: Endpoints now return data instead of rows in the result to get a more unified response. rows is still available for backward compatibility but is now deprecated
  • Fix: BelongsTo relationship in PostgreSQL (#76)
  • Fix: Required params in endpoints - Better checks has been implemented
  • Fix: Close the EndpointBuilder and the FileEditor when changing application
  • Fix: package.json was override when adding an existing app
  • Update dependencies

v0.5.0 - November release 2016

09 Dec 02:30
Compare
Choose a tag to compare

We're excited to announce Materia November Release which brings a new architecture for your application. It also adds nice features like the Field Components and Query Parameters Deduction.

New application architecture

This new architecture for Materia applications is more standard to what you usually see to develop a web application. All files & folders related to the database or to the server has been moved in the server/ folder.

materia.json has been moved in the package.json in the materia key.

The structure now looks like the following:

node_modules/
     ...
server/
    controllers/
        default.ctrl.js
        users.ctrl.js
        ...
    models/
        queries/
             entity1.js
        entity1.json
        entity2.json
        ...
    api.json
    server.json
web/
    index.html
package.json

Now It seems clear what is used by the server and what is used by the client to display the content.

If you want to expand your API or your entity's queries with code, it's now easier with controllers and models.

A controller regroup multiple endpoints in the same file (using ES6 classes):

// server/controllers/default.ctrl.js

module.exports = class DefaultController {
    constructor(app) {
        this.app = app;        // Materia Application Object (defined in Materia Server) => https://getmateria.com/docs/api-reference/app
    }

    // It uses the parameters of Express
    getUsers(req, res, next) {
         // endpoint logic here
    }
    someOtherMethod(req, res, next) {
         // endpoint logic here
    }
}

The same has been applied to the Javascript queries:

// server/models/queries/speaker.js

module.exports = class UserModel {
    constructor(app, entity) {
        this.app = app;        //Materia Application Object (defined in Materia Server => https://getmateria.com/docs/api-reference/app)
        this.entity = entity;  //Materia Entity Object (defined in Materia Server => https://getmateria.com/docs/api-reference/entity)
    }

    updateOrder(params) {
         // Define your query logic to reorder a speaker in an event
    }
}

Instead of writing one function per file, your can combine them logically per controller or per model. Then Materia Designer,

This release fixes #57 where there was an inconsistency in Query params where the params were not the same if the query was executed from an Endpoint or from the Javascript API (e.g. when Materia Designer execute an individual query in the UI).

Field Components

Blog's article

This release includes new components for your fields ! Components are useful to write data in the appropriate format in your database.

e.g. If you have a field type TEXT which should only contain emails, you can now use the component email to restrict the value in Materia Designer with a <input type="email"> instead of the traditional <input type="text">

this is not an email

This is the list of component available in this version:

Field type TEXT

  • Input (default)

input

- Password

password

- Email

screen shot 2016-12-08 at 1 07 55 am

- Color

color

color picker

- URL

url

- Textarea

textarea

- Markdown

markdown

Field type NUMBER

  • Input (default)

screen shot 2016-12-08 at 1 25 51 am

Field type DATE

  • Date Picker (default)

date

- Date Time Picker

date_time

- Time Picker

time

Field type BOOLEAN

  • Switch (default)

switch

Field type FLOAT

  • Input (default)

input

Some other components may be added on demand, just post a Github issue.

Parameters deduction

In the Query Builder (except on Javascript & SQL queries), you don't need anymore to enter your own parameters. They are deduced from how you use the params in the query builder.

e.g. if you set a condition title = with the parameter title, Materia will automatically add title in the list of parameters with the type and component of the field title. As it is used in a condition, the parameter is required.

Bug fixes and enhancements

  • Fix Update/Delete cascade - Better consistency between Cascade. SQLite now support cascade too. #47
  • Enhance conditions management in queries to not break when used on associated tables
  • Addons use npm. Our official addons can be installed using npm install @materia/{addon-name} directly / Use npm link for addons development
  • Fix conditions with no explicit entity (defaults to query's entity)
  • Finished the migration to Typescript in Materia Server (100% typescript !)
  • Set default configuration when server.json is missing.

v0.4.1

14 Nov 17:42
Compare
Choose a tag to compare

This release fixes some bugs introduced in the v0.4:

  • Major bug fix: the way we update query, it was deleted the current query
  • Renaming fields is disabled until the db synchronization also includes fields renaming. The deployment wasn’t detecting the rename and was deleting the old field name to create a new one (which implies data loss)
  • Fix the rename of an association table without breaking its relation.
  • Fix when the field created triggers some errors, it rollbacks to not display a broken field (and rollback its transaction for SQLite)
  • Remove some missing logs in the inspector.

v0.4.0 - October release 2016

08 Nov 23:59
Compare
Choose a tag to compare

Lots of core features has been released in v0.4 on the way to reach the v1.0 goal: Live mode, the beginning of Addons support, Integrated Git client, Instant reload & lots of UI enhancement & bug fixes ! We hope you'll like it !

Live mode

Once you've deployed your application, you can configure Materia Designer to access the live DB securely and execute registered queries to maintain your database.

live-mode

The live mode is closely coupled with Git to work on the version you have released and see a real view of what your production environment looks like.

We used heavily this feature as our backend for our API events Apidays ! (the main conference take place in Paris the 13th and 14th December, book your place now!)

This website of APIdays has been opensourced here, it can be a good Angular2/Semantic UI example to build website with dynamic content.

Be careful to test your queries before executing them in production ! Especially for Update and Delete queries ;)

Addons support

An addon is a reusable and configurable component for your backend which bring new functionalities to Materia.

An addon can define its own entities / queries / endpoints and new permissions to secure your endpoints. This feature is key to build secure SAAS Materia applications.

The documentation is coming really soon. Stay tuned on Twitter & Slack!

We've begun to make a new version of OAuth.io & oauthd from scratch using Materia. It's under heavy development and we're experimenting addons on it everyday. Take a look how addons is helping the development and later, once released, the management of the website:

addon

As you can see, an addon can define its own view to bring new functionalities to the interface without having to use 150 different tools. Some colors are added to your entities when they are created by an addon to see the impact of an addon instantly.

Lots of work still need to be done in this area and it's just a beginning:

  • Addons Marketplace: to let you publish and share your addons across the community.
  • Addons development: we expect to bring soon User management / Payment / API Documentation & SDK Generator & API Platform using Swagger and more !
  • Installation settings to configure an addon the way you want it

Integrated Git client

We developed for you a beautiful integrated Git client to make versioning easy in your Materia applications !

versionning

  • Staging
  • Commit
  • Sync (pull / push)
  • Commits history
  • Branches
  • Remotes

All your favorite Git features in a little box easy to access. This feature is especially important for our next big feature expected for the November release: the deployment.

Instant Reload

We've changed the way Materia Designer interact with Materia Server and it's really fast ! You were waiting 4-5 seconds after modifying a field or an endpoint? Now it's instant !

instant-reload

Did you see the red dot blinking (meaning that your server is off / restarting) ? No ?! It's the way we want it :)

UI Enhancements and bug fixes

  • Minimize the left main menu to get more place to edit your applications

minimized sidenav

  • materia start --prod is now synchronizing properly the database from your entities states.
  • Migrating database.json in server.json (+ auto migration at the launch of Materia designer)
  • Add inputs in the Endpoint Builder type Javascript
  • Migrating Materia Server to Typescript to ease the code maintainability.
  • Display a loading bar when Materia designer is auto-updating
  • Display current version of Materia.

Lot of little things has been enhanced visually to keep a clean UI (fonts, icons, search input and more).

v0.3.2

12 Oct 21:57
Compare
Choose a tag to compare

This release includes 2 bug fixes:

  • Fix logs error when database.json is missing
  • Fix conditions in queries on an included table (JOIN)

v0.3.1

11 Oct 18:47
Compare
Choose a tag to compare

This small release fixes few bugs from 0.3.0:

  • Fix Javascript/SQL query
  • Remove $$hashKey in entities json (query params)
  • Hide all fields options not compatible with another option

v0.3.0 - September release 2016

06 Oct 23:10
Compare
Choose a tag to compare

We're happy to introduce some core database features included in the September release :

MySQL Support

You can now connect your Materia application to a MySQL database.

image

We're excited to now handle these 3 Relational Database Management System which cover most use cases: MySQL, PostgreSQL and SQLite

New JSON display mode for inspect your query results

Sometimes the table display mode is not enough to really understand the result of a query, especially for queries containing lots of columns. For this very reason, we're excited to introduce a new JSON display mode which helps understand your data and how you will access them in your front-end.

json-display

Relation support in the query builder

Unleash the power of relational database using JOIN queries directly within the Query Builder !

Look how easy I can access my data :

relation

Relation support in the query builder is one of our greatest improvement this month and enable so many new things directly in the editor without having to write your own Javascript/SQL query.

Since this new version, you can select in your queries (bellow your fields) the entities associated to the selected entity to access their data and make complex queries.

Ordering queries

You can now order the results of the FindAll queries like the ORDER BY statement in SQL.

order-by2

The default query list is now ordered by the primary key.

We're stopping our support for the magic fields createdAt and updatedAt

As you could see in the previous animations, these 2 fields: createdAt and updatedAt are not present anymore !

We were adding magic fields behind the scene (createdAt and updatedAt) to know basic information like when the row was created and when the row has been updated for the last time. We felt it was a bit disturbing for new users and we stop supporting them anymore. When you'll upgrade to v0.3, Materia Designer will ask you to sync your application with the database to remove these fields.

Lots of bug fixes and little improvements

  • Fix - Windows: New files were not added to the file tree in Overview (#40)
  • Add: Ask for confirmation when leaving an edited file without save (#53)
  • Fix: rename field related to a relationship (#52)
  • Fix: New entity, query, endpoint and files are now indexed in the search engine (#44)
  • Fix: Lots of remove action wasn't asking for confirmation - now they do (#26)
  • Add: Files are now indexed in the search engine (#45)
  • Fix: Clean the console of warnings (#22)
  • Fix: Help menu (#41)
  • Fix: Windows 32bit version

We hope you'll enjoy the September release as we've enjoyed to release this version to you ! Be prepared, the next monthly release will be massive !

v0.2.2

06 Sep 20:19
Compare
Choose a tag to compare

This release adds a Windows 32 bits version.

There was still some ghost processes of Materia Server still running, so we have rewritten the service that spawns that process. The spawned Materia Server should be more robust and restart only when it's needed.

This release also adds sqlite on the Windows version, and some fixes about its files watcher.

  • Added Postgres JSON type as compatible with Materia's text type,
  • Rewritten the Materia Server service to avoid ghost processes
  • The errors when starting the app are visible and can disable the database instead of crashing
  • A file change in web/ refreshes only the web view (Windows)
  • Fixes the data view when running a code query or sql with juncture: the fields type are now correct
  • Added sqlite's binary for Windows
  • Fixes the watchers ignore list on Windows
  • Fixes the launch browser / external editor buttons on Windows.
  • Fixes some typo

v0.2.1

02 Sep 23:01
Compare
Choose a tag to compare

This version fixes some bugs that came with the previous release:

  • Add an existing app with prefilled informations.
  • Fix the defaultValue of fields with auto increment, when synchronizing with postgres.
  • Display the values input fields depending of its type when adding conditions in the query builder.
  • Stops the file watcher when removing all the apps.