admin_boxes.php 7.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131
  1. <?php include 'admin_header.php'; ?>
  2. <div class="content-wrapper">
  3. <section class="content-header">
  4. <h1>
  5. <?=lang::_('Slideshow')?>
  6. <small><?=lang::_('Slideshow')?></small>
  7. <button type="button" class="btn btn-success pull-right" onclick="window.location='/admin/boxes/show/'"><i class="fa fa-plus"></i> <?=lang::_('Add new slideshow')?></button>
  8. </h1>
  9. <ol class="breadcrumb">
  10. <li><a href="/admin"><i class="fa fa-gears"></i> <?=lang::_('Admin')?></a></li>
  11. <li class="active"><?=lang::_('Slideshow manager')?></li>
  12. </ol>
  13. </section>
  14. <section class="content">
  15. <div class="box box-info">
  16. <div class="box-header with-border">
  17. <h3 class="box-title"><?=lang::_('List of slideshows')?></h3>
  18. </div>
  19. <div class="box-body">
  20. <div class="row"><div class="col-lg-12" style="overflow-x: auto;">
  21. <table class="table table-bordered table-hover dataTable table-striped data-list">
  22. <thead>
  23. <tr>
  24. <th><?=lang::_('Name')?></th>
  25. <th><?=lang::_('Date of create')?></th>
  26. <th>&nbsp;</th>
  27. </tr>
  28. </thead>
  29. <tbody>
  30. <?php foreach ($boxes as $page) : ?>
  31. <tr>
  32. <td><?=$page->box_title?></td>
  33. <td><?=$page->box_date?></td>
  34. <td>
  35. <button type="button" onclick="window.location='/admin/boxes/show/?id=<?=$page->box_id?>';" class="btn btn-flat btn-xs btn-warning"><i class="fa fa-pencil"></i></button>
  36. <button type="button" onclick="window.location='/admin/boxes/delete/?id=<?=$page->box_id?>';" class="btn btn-flat btn-xs btn-danger"><i class="fa fa-trash-o"></i></button>
  37. </td>
  38. </tr>
  39. <?php endforeach; ?>
  40. </tbody>
  41. <tfoot>
  42. <tr>
  43. <th><?=lang::_('Name')?></th>
  44. <th><?=lang::_('Date of create')?></th>
  45. <th>&nbsp;</th>
  46. </tr>
  47. </tfoot>
  48. </table>
  49. </div></div>
  50. </div>
  51. </div>
  52. <div class="callout callout-success<?php if (!$error) echo ' message-hide';?>">
  53. <button type="button" class="close" onclick="javascript: $(this).parent('div').fadeOut('fast');">×</button>
  54. <h4><i class="fa fa-check"></i>&nbsp;&nbsp;<?=lang::_('Yep, successfully saved!')?></h4>
  55. <p><?=lang::_('The given informations stored in database')?></p>
  56. </div>
  57. <div id="editor"></div>
  58. <form role="form" id="slideEditor" action="/admin/boxes/save/" method="post" enctype="multipart/form-data">
  59. <input type="hidden" name="MAX_FILE_SIZE" value="9000000000" />
  60. <input type="hidden" name="box_id" value="<?=$active->box_id?>" />
  61. <div class="box box-info">
  62. <div class="box-header with-border">
  63. <h3 class="box-title"><?=lang::_('Slideshow editor')?></h3>
  64. <div class="box-tools pull-right">
  65. <button class="btn btn-box-tool" data-widget="collapse"><i class="fa fa-minus"></i></button>
  66. </div>
  67. </div>
  68. <div class="box-body">
  69. <div class="row">
  70. <div class="col-lg-12">
  71. <div class="nav-tabs-custom">
  72. <ul class="nav nav-tabs">
  73. <li class="active"><a href="#eng" data-toggle="tab" onclick="javascript: $('.tab-pane').removeClass('active'); var hash = $(this).attr('href'); $(hash).addClass('active');">English</a></li>
  74. <!--<li><a href="#eng" data-toggle="tab" onclick="javascript: $('.tab-pane').removeClass('active'); var hash = $(this).attr('href'); $(hash).addClass('active');">English</a></li>-->
  75. <!-- <li><a href="#deu" data-toggle="tab">Deutsch</a></li>-->
  76. </ul>
  77. </div>
  78. <div class="tab-content">
  79. <div class="tab-pane active" id="hun">
  80. <div class="form-group">
  81. <label for="box_title"><?=lang::_('Title')?>: </label>
  82. <input type="text" name="box_title" value="<?=$active->box_title?>" class="form-control" id="box_title" data-validate="true" />
  83. </div>
  84. <div class="form-group">
  85. <label for="box_subtitle"><?=lang::_('Subtitle 1')?>: </label>
  86. <input type="text" name="box_subtitle" value="<?=$active->box_subtitle?>" class="form-control" id="box_subtitle" data-validate="true" />
  87. </div>
  88. <div class="form-group">
  89. <label for="box_subtitle_en"><?=lang::_('Subtitle 2')?>: </label>
  90. <input type="text" name="box_subtitle_en" value="<?=$active->box_subtitle_en?>" class="form-control" id="box_subtitle_en" data-validate="true" />
  91. </div>
  92. <div class="form-group">
  93. <label for="box_button_text"><?=lang::_('Button text')?>: </label>
  94. <input type="text" name="box_button_text" value="<?=$active->box_button_text?>" class="form-control" id="box_button_text" data-validate="true" />
  95. </div>
  96. <div class="form-group">
  97. <label for="box_url"><?=lang::_('Button URL')?>: </label>
  98. <input type="text" name="box_url" value="<?=$active->box_url?>" class="form-control" id="box_url" data-validate="true" />
  99. </div>
  100. <div class="form-group">
  101. <label for="box_banner"><?=lang::_('Image')?>: </label>
  102. <input type="file" name="box_banner" class="form-control" id="box_banner" />
  103. </div>
  104. <div class="form-group">
  105. <label for="box_image"><?=lang::_('Preview')?>: </label><br>
  106. <section style="display: block;width: 100%;height: 650px;background-image: url(/<?=$active->box_banner?>);background-position: center;background-size: cover;background-repeat: no-repeat;">
  107. </section>
  108. </div>
  109. </div>
  110. </div>
  111. </div>
  112. </div>
  113. <div class="row">
  114. <div class="col-lg-12">
  115. <button type="submit" class="btn btn-success"><?=lang::_('Save');?></button>
  116. </div>
  117. </div>
  118. </div>
  119. </div>
  120. </form>
  121. </section>
  122. </div>
  123. <?php include 'admin_footer.php'; ?>