WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
Skip to content

danutc/apollo-react-form-builder

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

30 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

apollo-react-form-builder

extends mantra-react-form-builder to handle forms linked to multiple datasources over apollostack

One form instance is linked to multiple datasources:

  • n x mongodb documents (in one or several collections)
  • m x SQL tables
  • k x REST endpoints

For example some fields on a form are loaded / posted to a mongodb document and the rest are loaded / posted to a REST endpoint.

##How does it work? Each datasource has schema describing data objects. At design time JSONSchema formData fields are mapped to datasource schemas.

At design time form builder generates and saves in mongodb FormDefinitions collection:

  • JSONSchema (what to render on the form)
  • UISchema (how to render on the form)
  • n x mongodb document formData mapping schemas (mongodb datasources)
  • m x SQL table formData mapping schemas (SQL datasources)
  • k x REST endpoint formData mapping schemas (REST datasources)

Each form type is identified by a formKey so the schemas can be found and loaded from FormDefinitions collection.

At runtime:

  • form engine loads JSONSchema and UISchema to present the form to user
  • user submits the form: formData is generated and submited to datasources over apollostack
  • apollostack loads mongodb / SQL / REST schemas by formKey
  • using schemas apollostack splits formData and sends the relevant fields to appropriate datasource.

##How to run?

About

extends mantra-react-form-builder to handle forms linked to multiple datasources over apollostack

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •