backupApp.directive('fdInput', function () {
    return {
      scope: {
        fileName: '='
      },
      link: function(scope, element, attrs) {
        element.on('change', function(evt) {
            const files = evt.target.files;

            if (files.length > 0)
                scope.fileName = files[0].name;
            else 
                scope.fileName = null
            scope.$apply();
        });
      }
    }
})