UNPKG

ionic-cordova-gulp-seed

Version:

Ionic & Cordova & Gulp seed with organized code, tests, bower support and some other stuff. Originated from ionic-angular-cordova-seed.

34 lines (27 loc) 611 B
angular.module('ionicApp', ['ionic']) .controller('AppCtrl', function ($scope, $ionicModal) { $scope.contacts = [ { name: 'Gordon Freeman' }, { name: 'Barney Calhoun' }, { name: 'Lamarr the Headcrab' }, ]; $ionicModal.fromTemplateUrl('modal.html', function (modal) { $scope.modal = modal; }, { animation: 'slide-in-up', focusFirstInput: true }); }) .controller('ModalCtrl', function ($scope) { $scope.newUser = {}; $scope.createContact = function () { console.log('Create Contact', $scope.newUser); $scope.modal.hide(); }; });