JSON Components and Omnis on Github

JSON Components - Omnis on Github

Omnis Studio 8.1 allows you to define your own JavaScript controls using JSON and JavaScript, and use them on Remote forms in your web and mobile applications. Using this technique, you can create your own controls from scratch or wrap ready-made JavaScript components and libraries obtained from a third-party, such as one of the millions of developers on Github.

Omnis Studio 8.1 also introduced the ability to export the contents of an Omnis library to a set of JSON and JavaScript files, including all the classes, controls and methods in your library. In addition, you can create (import) a library from such a JSON tree in Studio 8.1. Being able to export and import Omnis libraries in JSON format allows you to share Omnis libraries and code in a third-party version control system such as GIT or SVN, either in a development team or the wider Omnis community.

Omnis Studio on Github

We are excited to announce that we have created a repository on Github and have placed a new JSON defined JavaScript component and sample library for you to test this new feature and to use in your web and mobile applications. You will find our new repo here:
https://github.com/OmnisStudio

Omnis on Github

A Signature JS Component

The Omnis JS Signature component allows an end user to input their signature straight into an edit box on a remote form using touch or the pointer. The signature is captured as an image and can be stored as a JPG in a database. The source code we used is by Szymon Nowak from his github repo, called ‘Signature Pad’ which is a JavaScript library for drawing signatures with smooth curves (please credit the author if you use this component yourself).

Visit the Omnis Github page, download the Signature component source files and follow the installation instructions, including how to import the library from the JSON tree, after which you should have a working JSON component and sample Omnis library: note you must have Omnis Studio 8.1.1 to import the JSON tree. The new JS Signature component will appear in the Component Store under the JSON Components tab. You can open the jsSignature remote form (which is the new responsive type) and add your signature in the edit box: you can click on Download to save a JPG of the signature.

Omnis JS Signature

Roll Your own JS components

For more information about creating the new JSON defined JavaScript components, refer to the ‘JSON Components’ chapter in the ‘Creating Web & Mobile Apps’ manual here:
http://www.omnis.net/documentation/webdev/index.jsp?detail=04jsoncomps.html#chapter-4json-components

There is a tech note on the Omnis website that describes the process of using a ready-made JS component, in this case, to create a Star-rating component:

  • TNJC0009: Adding Ready-made JavaScript components to Omnis

If you are building your own components, you will also need to refer to the JavaScript Control Reference in the JS SDK docs which you can find here:

http://sdkdocs.omnis.net/jssdk

In order to try all these new features you’ll need a copy of the latest Omnis Studio version 8.1.1 which you can download here:
http://www.omnis.net/download

0 Comments

Leave a reply

© Omnis Software Ltd 2017 - Help with setup and design by Ädelfors Consult ABSweden Disclaimer: Omnis Software disclaims any responsibility for or liability related to Software, or any content or advice, obtained through this site. IN NO EVENT WILL OMNIS SOFTWARE BE LIABLE FOR ANY INDIRECT, PUNITIVE, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES HOWEVER THEY MAY ARISE AND EVEN IF OMNIS SOFTWARE HAS BEEN PREVIOUSLY ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.

Log in with your credentials

or    

Forgot your details?

Create Account