mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-11-07 15:07:13 +08:00
Fixed #74
This commit is contained in:
8
dist/js/ionic-angular.js
vendored
8
dist/js/ionic-angular.js
vendored
@ -39,8 +39,8 @@ angular.module('ionic.service.actionSheet', ['ionic.service.templateLoad', 'ioni
|
|||||||
*
|
*
|
||||||
* @param {object} opts the options for this ActionSheet (see docs)
|
* @param {object} opts the options for this ActionSheet (see docs)
|
||||||
*/
|
*/
|
||||||
show: function(opts) {
|
show: function(opts, $scope) {
|
||||||
var scope = $rootScope.$new(true);
|
var scope = $scope && $scope.$new() || $rootScope.$new(true);
|
||||||
|
|
||||||
angular.extend(scope, opts);
|
angular.extend(scope, opts);
|
||||||
|
|
||||||
@ -209,7 +209,7 @@ angular.module('ionic.service.popup', ['ionic.service.templateLoad'])
|
|||||||
};
|
};
|
||||||
|
|
||||||
return {
|
return {
|
||||||
alert: function(message) {
|
alert: function(message, $scope) {
|
||||||
|
|
||||||
// If there is an existing popup, just show that one
|
// If there is an existing popup, just show that one
|
||||||
var existing = getPopup();
|
var existing = getPopup();
|
||||||
@ -224,7 +224,7 @@ angular.module('ionic.service.popup', ['ionic.service.templateLoad'])
|
|||||||
|
|
||||||
opts = angular.extend(defaults, opts);
|
opts = angular.extend(defaults, opts);
|
||||||
|
|
||||||
var scope = $rootScope.$new(true);
|
var scope = $scope && $scope.$new() || $rootScope.$new(true);
|
||||||
angular.extend(scope, opts);
|
angular.extend(scope, opts);
|
||||||
|
|
||||||
// Compile the template
|
// Compile the template
|
||||||
|
|||||||
@ -10,8 +10,8 @@ angular.module('ionic.service.actionSheet', ['ionic.service.templateLoad', 'ioni
|
|||||||
*
|
*
|
||||||
* @param {object} opts the options for this ActionSheet (see docs)
|
* @param {object} opts the options for this ActionSheet (see docs)
|
||||||
*/
|
*/
|
||||||
show: function(opts) {
|
show: function(opts, $scope) {
|
||||||
var scope = $rootScope.$new(true);
|
var scope = $scope && $scope.$new() || $rootScope.$new(true);
|
||||||
|
|
||||||
angular.extend(scope, opts);
|
angular.extend(scope, opts);
|
||||||
|
|
||||||
|
|||||||
4
js/ext/angular/src/service/ionicPopup.js
vendored
4
js/ext/angular/src/service/ionicPopup.js
vendored
@ -15,7 +15,7 @@ angular.module('ionic.service.popup', ['ionic.service.templateLoad'])
|
|||||||
};
|
};
|
||||||
|
|
||||||
return {
|
return {
|
||||||
alert: function(message) {
|
alert: function(message, $scope) {
|
||||||
|
|
||||||
// If there is an existing popup, just show that one
|
// If there is an existing popup, just show that one
|
||||||
var existing = getPopup();
|
var existing = getPopup();
|
||||||
@ -30,7 +30,7 @@ angular.module('ionic.service.popup', ['ionic.service.templateLoad'])
|
|||||||
|
|
||||||
opts = angular.extend(defaults, opts);
|
opts = angular.extend(defaults, opts);
|
||||||
|
|
||||||
var scope = $rootScope.$new(true);
|
var scope = $scope && $scope.$new() || $rootScope.$new(true);
|
||||||
angular.extend(scope, opts);
|
angular.extend(scope, opts);
|
||||||
|
|
||||||
// Compile the template
|
// Compile the template
|
||||||
|
|||||||
Reference in New Issue
Block a user