Show selected file + Nav folder and files active class + Add difference ratio on versions

This commit is contained in:
brunosimon
2016-06-07 00:37:20 +02:00
parent e4ccca4fb6
commit f659020706
6 changed files with 157 additions and 35 deletions
+20 -2
View File
@@ -7,12 +7,28 @@ angular_module.controller(
{
$scope.folder_click = function( folder )
{
console.log( folder );
project.each_folder( function( folder )
{
folder.active = false;
} );
folder.active = true;
};
$scope.file_click = function( file )
{
console.log( file );
project.each_file( function( file )
{
file.active = false;
} );
file.active = true;
$scope.file = file;
};
$scope.version_click = function( version )
{
$scope.version = version;
};
$scope.init = function( project_slug )
@@ -29,6 +45,8 @@ angular_module.controller(
} );
$scope.project = project.data;
$scope.file = null;
$scope.version = null;
}
]
);