Author: Kelvin Hui

noSQL Search Query No ratings yet.

Besides using _ID to do searching, you can also use other fields or multiple fields to do searching. For example: Examples JavaScript Codes By username   db.collection(“comments”).find( {username: “Peter”} , {limit: 1000}).asArray()   It will search all comments with username = “Peter”   By Date   db.collection(“comments”).find( { date: “01/01/2018”} , {limit: 1000}).asArray()   It

Bulk Operations No ratings yet.

After the simple CRUD sample, we will show you the bulk operations from this sample, please click on this URL to play with Blogs CRUD sample. Please see the below bulk operations with related JavaScript codes: Features JavaScript Codes Bulk Insert   db.collection(“comments”).insertMany(                [                                                             { owner_id : client.auth.user.id, date: “01/01/2018”, username: “Peter”,

How to create application, database and collection? No ratings yet.

Login https://cloud.mongodb.com/user#/atlas/login with your registered account, select “Stitch Apps” on the left menu. Click “Create New Application” to create a new application, input “it-blogs” into Application Name, and then click “Create” button to create. After a few minutes, it will create the new application, and show you: On the is page, you can find “Turn

Example 5: Client Login / Logout With $http.post() No ratings yet.

This example will show you how to post data to Restful server by using $http.post() in order to demonstrate login and logout functions. Besides, it will use window.localStorage to store the login information. Please follow below steps: Update C:\workspace_ionic\itBlogsApp\www\templates\menu.html by changing: <ion-item menu-close ng-click=”login()”>Login</ion-item> to <ion-item menu-close ng-click=”login()”>{{loginout}}</ion-item>   Update C:\workspace_ionic\itBlogsApp\www\templates\login.html by changing: <h1 class=”title”>Login</h1>

Example 3: Products Show Room With Searching and Sorting No ratings yet.

For this example, we will show you how to list the records in table format with header sorting and keyword auto-complete searching functions. Please follow below steps: Update C:\workspace_ionic\itBlogsApp\www\js\app.js , add below code after .state(‘app.shop’   .state(‘app.productlists’,             { url: ‘/productlists’,                                         views: { ‘menuContent’: { templateUrl: ‘templates/productlists.html’,         controller: ‘ProductListsController’ } } })  

Example 2: Listing Shop Integrating With Google Map No ratings yet.

After the first example, you know how to $http.get() data from Restful server. This example will show you how to list your records in listing format and show with Google Map. Please follow below steps: Under C:\workspace_ionic\itBlogsApp\www\index.html , add: <!– Google map js –> <script src=”http://maps.googleapis.com/maps/api/js”></script> after <!– cordova script (this will be a 404

Example 1: Show Company Background With Simple $http.get() No ratings yet.

This example will show you how to get JSON data from Restful server by using $http.get(), you can download the ionic workspace here. Let’s create a new app by “ionic start itBlogsApp sidemenu” under C:/workspace_ionic/ , it will generate the new project – itBlogsApp. Enter “Y” to create the ionic.io account and please register, because we