File tree Expand file tree Collapse file tree 1 file changed +10
-9
lines changed Expand file tree Collapse file tree 1 file changed +10
-9
lines changed Original file line number Diff line number Diff line change @@ -1039,15 +1039,16 @@ public function getDatatable($status = null)
10391039
10401040 });
10411041
1042- $ inout = new \Chumper \Datatable \Columns \FunctionColumn ('inout ' , function ($ assets )
1043- {
1044- if (($ assets ->assigned_to !='' ) && ($ assets ->assigned_to > 0 )) {
1045- return '<a href=" ' .route ('checkin/hardware ' , $ assets ->id ).'" class="btn btn-primary btn-sm"> ' .Lang::get ('general.checkin ' ).'</a> ' ;
1046- } else {
1047- return '<a href=" ' .route ('checkout/hardware ' , $ assets ->id ).'" class="btn btn-info btn-sm"> ' .Lang::get ('general.checkout ' ).'</a> ' ;
1048- }
1049- });
1050-
1042+ $ inout = new \Chumper \Datatable \Columns \FunctionColumn ('inout ' , function ($ assets )
1043+ {
1044+ if ($ assets ->assetstatus ->deployable != 0 ) {
1045+ if (($ assets ->assigned_to !='' ) && ($ assets ->assigned_to > 0 )) {
1046+ return '<a href=" ' .route ('checkin/hardware ' , $ assets ->id ).'" class="btn btn-primary btn-sm"> ' .Lang::get ('general.checkin ' ).'</a> ' ;
1047+ } else {
1048+ return '<a href=" ' .route ('checkout/hardware ' , $ assets ->id ).'" class="btn btn-info btn-sm"> ' .Lang::get ('general.checkout ' ).'</a> ' ;
1049+ }
1050+ }
1051+ });
10511052
10521053
10531054 return Datatable::collection ($ assets )
You can’t perform that action at this time.
0 commit comments