|
|
@@ -557,7 +557,16 @@ define([ 'angularAMD', 'ui.router', 'ui-bootstrap', 'ngLocal', 'ngTable', 'commo
|
|
|
$modal.open({
|
|
|
templateUrl : $rootScope.rootPath + '/static/view/usercenter/modal/collectModel.html',
|
|
|
controller : 'CollectModelCtrl',
|
|
|
- size : 'sm'
|
|
|
+ size : 'sm',
|
|
|
+ resolve : {
|
|
|
+ haveAdd : function(){
|
|
|
+ if (data == "success"){
|
|
|
+ return true;
|
|
|
+ } else{
|
|
|
+ return false;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
});
|
|
|
$rootScope.componentCount++;
|
|
|
}, function(error) {
|
|
|
@@ -567,7 +576,8 @@ define([ 'angularAMD', 'ui.router', 'ui-bootstrap', 'ngLocal', 'ngTable', 'commo
|
|
|
|
|
|
}]);
|
|
|
|
|
|
- app.controller('CollectModelCtrl', ['$scope', '$modalInstance', function($scope, $modalInstance){
|
|
|
+ app.controller('CollectModelCtrl', ['$scope', '$modalInstance', 'haveAdd', function($scope, $modalInstance, haveAdd){
|
|
|
+ $scope.haveAdd = haveAdd;
|
|
|
$scope.cancel = function() {
|
|
|
$modalInstance.dismiss();
|
|
|
};
|