PreviewImage.Controller.js 449 Bytes
Newer Older
Thitichaipun Wutthisak committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
'use strict'

angular.module('Empview').controller('PreviewImage', ['$scope', '$http', 'images', '$sce', '$mdDialog', function($scope, $http, images, $sce, $mdDialog){
  console.log(images)
  $scope.myimg = images
  $scope.imageSource = function(p_img){
    let img = '/hr/FileDownload.jsp?uploadfield=mcom_profile_file.attac&filename='+p_img
    return $sce.trustAsResourceUrl(img)
  }

  $scope.close = function(){
    $mdDialog.cancel()
  }

}])