Skip to content

Commit

Permalink
minor fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
marcolazzara committed Feb 1, 2014
1 parent 9330800 commit 8229738
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 11 deletions.
13 changes: 3 additions & 10 deletions app/scripts/controllers/function-controller.js
Original file line number Diff line number Diff line change
Expand Up @@ -160,23 +160,16 @@ schemaModule.controller("FunctionController", ['$scope', '$routeParams', '$locat
$scope.inParams = $scope.functionToExecute['parameters'];
}


$scope.showInConsole = function (selectedFunction) {
$scope.consoleValue = selectedFunction['code'];
$scope.nameFunction = selectedFunction['name'];
$scope.selectedLanguage = selectedFunction['language'];
$scope.functionToExecute = selectedFunction;
$scope.inParams = $scope.functionToExecute['parameters'];
// $scope.inParams = new Array();
$scope.parametersToExecute = new Array;

$scope.showInConsoleAfterSave(selectedFunction);
$scope.parametersToExecute = new Array;

$scope.$watch('inParams.length', function (data) {
if (data) {
$scope.parametersToExecute = new Array(data);
}
else {

$scope.parametersToExecute = null;
}
});
Expand All @@ -185,7 +178,7 @@ schemaModule.controller("FunctionController", ['$scope', '$routeParams', '$locat
$scope.isNewFunction = false;
}

$scope.modificataLang = function (lang) {
$scope.modifiedLanguage = function (lang) {
$scope.functionToExecute['language'] = lang;
}
$scope.createNewFunction = function () {
Expand Down
2 changes: 1 addition & 1 deletion app/views/database/functions.html
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
Name : <input type="text" required ng-model="functionToExecute['name']">
Language:
<select ng-options="lang for lang in languages" ng-model="selectedLanguage"
ng-change="modificataLang(selectedLanguage)">
ng-change="modifiedLanguage(selectedLanguage)">

</select>
Idempotent: <input type="checkbox" ng-model="functionToExecute['idempotent']">
Expand Down

0 comments on commit 8229738

Please sign in to comment.