PageRenderTime 45ms CodeModel.GetById 17ms RepoModel.GetById 1ms app.codeStats 0ms

/resources/views/admin/lists/list_colleges.blade.php

https://gitlab.com/ehubnepal/educationhubnepal
PHP | 88 lines | 78 code | 5 blank | 5 comment | 2 complexity | 7d6706edf5c555334308384d854e7482 MD5 | raw file
  1. @extends('admin.adminmaster')
  2. @section('maincontent')
  3. <?php
  4. //echo '<pre>';
  5. //print_r($brands);
  6. //echo '</pre>';
  7. ?>
  8. <section class="content actionbuttonbox">
  9. <div class="row">
  10. <div class="col-xs-12">
  11. <div class="box text-right actionbutton clearfix padding">
  12. <div class="col-sm-4">
  13. {!! Form::open(['url'=>'admin/college/search','files'=>'true','method'=>'get']) !!}
  14. <input type="search" placeholder="search" name="search" value="<?php isset($query)?print $query:'';?>" class="form-control">
  15. {!!Form::close()!!}
  16. </div>
  17. <div class="col-sm-8">
  18. <a class="btn btn-success" href="{{ url('admin/college/create')}}"> <i class="fa fa-plus"></i> Add new </a>
  19. <a class="btn text-success" id="publishMenu"><i class="fa fa-circle"></i> Publish</a>
  20. <a class="btn text-danger" id="unpublishMenu"><i class="fa fa-circle-o"></i> Unpublish</a>
  21. </div>
  22. </div>
  23. </div>
  24. </div>
  25. </section>
  26. <!-- Main content -->
  27. <section class="content">
  28. <div class="row">
  29. <div class="col-xs-12">
  30. <div class="box">
  31. <div class="box-header">
  32. <h3 class="box-title">All Colleges</h3>
  33. </div>
  34. <!-- /.box-header -->
  35. <div class="box-body table-responsive no-padding">
  36. <table class="table table-hover">
  37. <tbody>
  38. <tr>
  39. <th><input class="checkall" type="checkbox" onclick="checkAll(this)"></th>
  40. <th>ID</th>
  41. <th>College</th>
  42. <th>Logo</th>
  43. <th>Address</th>
  44. <th>Status</th>
  45. <th>Action</th>
  46. </tr>
  47. @foreach($colleges as $college)
  48. <tr>
  49. <td><input class="checksingle" type="checkbox" data-id="{{$college->id}}"></td>
  50. <td> <a href="{{ url('admin/college/'.$college->id)}}">{{$college->id}}</a></td>
  51. <td> <a href="{{ url('admin/college/'.$college->id)}}">{{$college->cname}} </a></td>
  52. <td>
  53. <?php
  54. // if (getimagesize(url($college->logo))) {
  55. echo '<img src="' . url($college->full_url) . '" style="max-height:40px;max-width:100px"/>';
  56. // }
  57. ?>
  58. </td>
  59. <td>{{$college->address}}</td>
  60. <?php
  61. if ($college->published == 0):
  62. $publishLink = '<a href="' . url('admin/college/publish/' . $college->id) . '" class="text-danger" ><i class="fa fa-circle"></i> Unublished</a>';
  63. else:
  64. $publishLink = '<a href="' . url('admin/college/unpublish/' . $college->id) . '" class="text-success" ><i class="fa fa-circle"></i> Published</a>';
  65. endif;
  66. ?>
  67. <td>{!! $publishLink !!}</td>
  68. <td><a href="{{url('admin/college/'.$college->id.'/edit')}}" class="text-info"><i class="fa fa-pencil"></i> Edit</a> |
  69. <a href="{{url('admin/college/'.$college->id.'/delete')}}" class="text-danger"><i class="fa fa-trash"></i> Delete</a></td>
  70. </tr>
  71. @endforeach
  72. </tbody>
  73. </table>
  74. {!! $colleges->links() !!}
  75. </div>
  76. <!-- /.box-body -->
  77. </div>
  78. <!-- /.box -->
  79. </div>
  80. </div>
  81. </section>
  82. <!-- /.content -->
  83. @stop