pulkit

Grails

Traits Provided by Grails 3

The Core API's in Grails 3 are based on Groovy Traits. Following are the few of the examples which shows the way you can use these traits in Groovy classes. ResponseRenderer With the help of ResponseRenderer traits we can provide render method to a Groovy class in the following way : [java] import...

by pulkit
03-Jun-2015

Gradle, Grails

Run Gradle tasks from Grails 3 custom scripts

In Grails 3 each script extends from GroovyScriptCommand. One of the property which GroovyScriptCommand provides is "gradle". With the help of this property you can invoke gradle tasks. When you write : [java] grails create-scipt demo [/java] A script file will be generated in src/main/scripts folder with the name demo.groovy ...

by pulkit
03-Jun-2015

Grails

OAuth 2.0 using Grails Part – 2

Obtain accessToken from refreshToken In the previous article OAuth 2.0 using Grails Part – 1 I have given a detailed explanation regarding user authentication using OAuth 2.0. In this article i will explain how you can obtain access_token from the refresh_token. Please refer to step(3) of part - 1 of this article where we obtained a...

by pulkit
22-Jun-2014

Grails

OAuth 2.0 using Grails Part – 1

Following steps need to be followed for OAuth 2.0 authentication : (1) Obtain OAuth 2.0 credentials from the Google Developers Console: First you need to have a google account. create a project at Google Developers Console after logging into your Google account. Click on the project name go to "APIs and auth" click on credentianls and...

by pulkit
13-May-2014

Grails, Javascript/Ajax/JQuery

FusionCharts Part – 2

Using Fusion charts you can create different variety of charts two of them are single series chart and multiple series chart . As the name implies in case of single series chart you can only display single chart and in case of multiple series chart you can display multiple charts. Now lets take an example to have better understanding of...

by pulkit
08-May-2014

Grails, Javascript/Ajax/JQuery

FusionCharts Part – 1

Stunning fusion charts will wow your audience . You can download javascript files for free trail of fusion chart from here . Following Javascript files are required to create fusion charts : [js] <script src="../js/jquery.min.js"></script> <script...

by pulkit
05-Apr-2014

Grails, Javascript/Ajax/JQuery

jQuery dataTables plugin for pagination of HTML tables

In my project on Angular.js I came across a use case where I needed to paginate the HTML tables . DataTable jQuery plugin is a perfect choice in order to accomplish this task. Let us take a simple example to illustrate the use of dataTable plugin: [js] <html> <head> <style> <link rel="stylesheet"...

by pulkit
25-Mar-2014