create.html.php 3.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. <?php include $app->getModuleRoot() . 'common/view/header.html.php'?>
  2. <div id="mainContent" class="main-content fade">
  3. <div class="center-block">
  4. <div class="main-header">
  5. <h2><?php echo $lang->reviewissue->create;?></h2>
  6. </div>
  7. <form class="load-indicator main-form form-ajax" method="post" enctype="multipart/form-data" id="dataform">
  8. <table class="table table-form">
  9. <tbody>
  10. <tr>
  11. <th class="w-120px"><?php echo $lang->reviewissue->review;?></th>
  12. <td><?php echo html::select('review', $reviewList, '', 'class="form-control chosen"');?></td>
  13. <td></td>
  14. </tr>
  15. <tr>
  16. <th class="w-120px"><?php echo $lang->reviewissue->injection;?></th>
  17. <td><?php echo html::select('injection', '', '', 'class="form-control chosen"');?></td>
  18. <td></td>
  19. </tr>
  20. <tr>
  21. <th class="w-120px"><?php echo $lang->reviewissue->listType;?></th>
  22. <td><?php echo html::select('category', $category, '', 'class="form-control chosen"');?></td>
  23. <td></td>
  24. </tr>
  25. <tr>
  26. <th class="w-120px"><?php echo $lang->reviewissue->checklist;?></th>
  27. <td><?php echo html::select('listID', '', '', 'class="form-control chosen"');?></td>
  28. <td></td>
  29. </tr>
  30. <tr>
  31. <th class="w-120px"><?php echo $lang->reviewissue->opinion;?></th>
  32. <td><?php echo html::input('opinion', '', 'class="form-control"');?></td>
  33. <td></td>
  34. </tr>
  35. <tr>
  36. <th class="w-120px"></th>
  37. <td colspan="2" class="form-actions">
  38. <?php echo html::submitButton($lang->save);?>
  39. <?php echo html::backButton();?>
  40. </td>
  41. </tr>
  42. </tbody>
  43. </table>
  44. </form>
  45. </div>
  46. </div>
  47. <script>
  48. $('#review').change(function()
  49. {
  50. var reviewID = $(this).val();
  51. var link = createLink('reviewissue', 'ajaxGetCategory','reviewID=' + reviewID);
  52. $.post(link, function(data)
  53. {
  54. $('#category').replaceWith(data);
  55. $('#category_chosen').remove();
  56. $('#category').chosen();
  57. $('#category').change();
  58. })
  59. var link = createLink('reviewissue', 'ajaxGetInjection','reviewID=' + reviewID);
  60. $.post(link, function(data)
  61. {
  62. $('#injection').replaceWith(data);
  63. $('#injection_chosen').remove();
  64. $('#injection').chosen();
  65. })
  66. });
  67. function findCheck()
  68. {
  69. var reviewID = $("#review").val();
  70. var category = $("#category").val();
  71. var link = createLink('reviewissue', 'ajaxGetCheck','reviewID=' + reviewID + '&category=' + category);
  72. $.post(link, function(data)
  73. {
  74. $('#listID').replaceWith(data);
  75. $('#listID_chosen').remove();
  76. $('#listID').chosen();
  77. })
  78. }
  79. $('#review').change();
  80. </script>
  81. <?php include $app->getModuleRoot() . 'common/view/footer.html.php'?>