1+ <!-- begin redirect submit options -->
2+ @props ([
3+ ' filepath' ,
4+ ' object' ,
5+ ' showfile_routename' ,
6+ ' deletefile_routename' ,
7+ ] )
8+
9+ <!-- begin non-ajaxed file listing table -->
10+ <div class =" table-responsive" >
11+ <table
12+ data-cookie-id-table =" {{ $object } } UploadsTable"
13+ data-id-table =" {{ $object } } UploadsTable"
14+ id =" {{ $object } } UploadsTable"
15+ data-search =" true"
16+ data-pagination =" true"
17+ data-side-pagination =" client"
18+ data-show-columns =" true"
19+ data-show-fullscreen =" true"
20+ data-show-export =" true"
21+ data-show-footer =" true"
22+ data-toolbar =" #upload-toolbar"
23+ data-show-refresh =" true"
24+ data-sort-order =" asc"
25+ data-sort-name =" name"
26+ class =" table table-striped snipe-table"
27+ data-export-options =' {
28+ "fileName": "export-license-uploads-{{ str_slug ($object -> name ) } } -{{ date (' Y-m-d' ) } } ",
29+ "ignoreColumn": ["actions","image","change","checkbox","checkincheckout","delete","download","icon"]
30+ }' >
31+
32+ <thead >
33+ <tr >
34+ <th data-visible =" false" data-field =" id" data-sortable =" true" >
35+ {{ trans (' general.id' )} }
36+ </th >
37+ <th data-visible =" true" data-field =" type" data-sortable =" true" >
38+ {{ trans (' general.file_type' )} }
39+ </th >
40+ <th class =" col-md-2" data-searchable =" true" data-visible =" true" data-field =" image" >
41+ {{ trans (' general.image' ) } }
42+ </th >
43+ <th class =" col-md-2" data-searchable =" true" data-visible =" true" data-field =" filename" data-sortable =" true" >
44+ {{ trans (' general.file_name' ) } }
45+ </th >
46+ <th class =" col-md-1" data-searchable =" true" data-visible =" true" data-field =" filesize" >
47+ {{ trans (' general.filesize' ) } }
48+ </th >
49+ <th class =" col-md-2" data-searchable =" true" data-visible =" true" data-field =" notes" data-sortable =" true" >
50+ {{ trans (' general.notes' ) } }
51+ </th >
52+ <th class =" col-md-1" data-searchable =" true" data-visible =" true" data-field =" download" >
53+ {{ trans (' general.download' ) } }
54+ </th >
55+ <th class =" col-md-2" data-searchable =" true" data-visible =" true" data-field =" created_at" data-sortable =" true" >
56+ {{ trans (' general.created_at' ) } }
57+ </th >
58+ <th class =" col-md-2" data-searchable =" true" data-visible =" true" data-field =" created_by" data-sortable =" true" >
59+ {{ trans (' general.created_by' ) } }
60+ </th >
61+ <th class =" col-md-1" data-searchable =" true" data-visible =" true" data-field =" actions" >
62+ {{ trans (' table.actions' ) } }
63+ </th >
64+ </tr >
65+ </thead >
66+ <tbody >
67+ @foreach ($object -> uploads as $file )
68+ <tr >
69+ <td >
70+ {{ $file -> id } }
71+ </td >
72+ <td data-sort-value =" {{ pathinfo ($filepath . $file -> filename , PATHINFO_EXTENSION ) } }" >
73+ @if (Storage:: exists ($filepath . $file -> filename ) )
74+ <span class =" sr-only" >{{ pathinfo ($filepath . $file -> filename , PATHINFO_EXTENSION ) } } </span >
75+ <i class =" {{ Helper:: filetype_icon ($file -> filename ) } } icon-med" aria-hidden =" true" data-tooltip =" true" data-title =" {{ pathinfo ($filepath . $file -> filename , PATHINFO_EXTENSION ) } }" ></i >
76+ @endif
77+ </td >
78+ <td >
79+ @if (($file -> filename ) && (Storage:: exists ($filepath . $file -> filename )) )
80+ @if (Helper:: checkUploadIsImage ($file -> get_src ($object )) )
81+ <a href =" {{ route ($showfile_routename , [$object -> id , $file -> id , ' inline' => ' true' ]) } }" data-toggle =" lightbox" data-type =" image" >
82+ <img src =" {{ route ($showfile_routename , [$object -> id , $file -> id , ' inline' => ' true' ]) } }" class =" img-thumbnail" style =" max-width : 50px ;" >
83+ </a >
84+ @else
85+ {{ trans (' general.preview_not_available' ) } }
86+ @endif
87+ @else
88+ <x-icon type =" x" class =" text-danger" />
89+ {{ trans (' general.file_not_found' ) } }
90+ @endif
91+ </td >
92+ <td >
93+ {{ $file -> filename } }
94+ </td >
95+ <td data-value =" {{ (Storage:: exists ($filepath . $file -> filename )) ? Storage:: size ($filepath . $file -> filename ) : ' ' } }" >
96+ {{ (Storage:: exists ($filepath . $file -> filename )) ? Helper:: formatFilesizeUnits (Storage:: size ($filepath . $file -> filename )) : ' ' } }
97+ </td >
98+
99+ <td >
100+ @if ($file -> note )
101+ {{ $file -> note } }
102+ @endif
103+ </td >
104+ <td style =" white-space : nowrap ;" >
105+ @if ($file -> filename )
106+ @if (Storage:: exists ($filepath . $file -> filename ) )
107+ <a href =" {{ route ($showfile_routename , [$object -> id , $file -> id ]) } }" class =" btn btn-sm btn-default" >
108+ <x-icon type =" download" />
109+ <span class =" sr-only" >
110+ {{ trans (' general.download' ) } }
111+ </span >
112+ </a >
113+
114+ <a href =" {{ StorageHelper:: allowSafeInline ($filepath . $file -> filename ) ? route ($showfile_routename , [$object -> id , $file -> id , ' inline' => ' true' ]) : ' #' } }" class =" btn btn-sm btn-default{{ StorageHelper:: allowSafeInline ($filepath . $file -> filename ) ? ' ' : ' disabled' } }" target =" _blank" >
115+ <x-icon type =" external-link" />
116+ </a >
117+ @endif
118+ @endif
119+ </td >
120+ <td >
121+ {{ $file -> created_at } }
122+ </td >
123+ <td >
124+ {{ $file -> created_by } }
125+ </td >
126+ <td >
127+ <a class =" btn delete-asset btn-danger btn-sm hidden-print" href =" {{ route ($deletefile_routename , [$object -> id , $file -> id ]) } }" data-content =" Are you sure you wish to delete this file?" data-title =" {{ trans (' general.delete' ) } } {{ $file -> filename } } ?" >
128+ <x-icon type =" delete" />
129+ <span class =" sr-only" >{{ trans (' general.delete' ) } } </span >
130+ </a >
131+ </td >
132+
133+
134+ </tr >
135+ @endforeach
136+
137+ </tbody >
138+ </table >
139+ </div >
140+ <!-- end non-ajaxed file listing table -->
0 commit comments