42d9b8d7d23e2960b68609f731ba701f743cb831.php 2.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. <?php if(!$holdAll): ?>
  2. <div class="btn-group <?php echo e($all, false); ?>-btn" style="display:none;margin-right: 5px;">
  3. <a class="btn btn-sm btn-default hidden-xs"><span class="selected"></span></a>
  4. <button type="button" class="btn btn-sm btn-default dropdown-toggle" data-toggle="dropdown">
  5. <span class="caret"></span>
  6. <span class="sr-only">Toggle Dropdown</span>
  7. </button>
  8. <?php if(!$actions->isEmpty()): ?>
  9. <ul class="dropdown-menu" role="menu">
  10. <?php $__currentLoopData = $actions; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $action): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
  11. <?php if($action instanceof \Encore\Admin\Actions\BatchAction): ?>
  12. <li><?php echo $action->render(); ?></li>
  13. <?php else: ?>
  14. <li><a href="#" class="<?php echo e($action->getElementClass(false), false); ?>"><?php echo $action->render(); ?> </a></li>
  15. <?php endif; ?>
  16. <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
  17. </ul>
  18. <?php endif; ?>
  19. </div>
  20. <?php endif; ?>
  21. <script>
  22. $('.<?php echo e($all, false); ?>').iCheck({checkboxClass:'icheckbox_minimal-blue'});
  23. $('.<?php echo e($all, false); ?>').on('ifChanged', function(event) {
  24. if (this.checked) {
  25. $('.<?php echo e($row, false); ?>-checkbox').iCheck('check');
  26. } else {
  27. $('.<?php echo e($row, false); ?>-checkbox').iCheck('uncheck');
  28. }
  29. }).on('ifClicked', function () {
  30. if (this.checked) {
  31. $.admin.grid.selects = {};
  32. } else {
  33. $('.<?php echo e($row, false); ?>-checkbox').each(function () {
  34. var id = $(this).data('id');
  35. $.admin.grid.select(id);
  36. });
  37. }
  38. var selected = $.admin.grid.selected().length;
  39. if (selected > 0) {
  40. $('.<?php echo e($all, false); ?>-btn').show();
  41. } else {
  42. $('.<?php echo e($all, false); ?>-btn').hide();
  43. }
  44. $('.<?php echo e($all, false); ?>-btn .selected')
  45. .html("<?php echo e(trans('admin.grid_items_selected'), false); ?>".replace('{n}', selected));
  46. });
  47. </script>
  48. <?php /**PATH C:\phpstudy_pro\WWW\cydsyy-api\vendor\encore\laravel-admin\src/../resources/views/grid/batch-actions.blade.php ENDPATH**/ ?>