client_data_add.blade.php 5.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113
  1. @extends('admin/layout')
  2. @section('header')
  3. <link href="{{asset('css/plugins/chosen/chosen.css')}}" rel="stylesheet">
  4. <link href="{{asset('css/plugins/switchery/switchery.css')}}" rel="stylesheet">
  5. {{--<link href="{{asset('js/plugins/bootstrap-select-1.13.5/css/bootstrap-select.min.css')}}" rel="stylesheet">--}}
  6. <link rel="stylesheet"
  7. href="https://cdn.jsdelivr.net/npm/bootstrap-select@1.13.9/dist/css/bootstrap-select.min.css">
  8. @endsection
  9. @section('content')
  10. <body class="gray-bg">
  11. <div class="wrapper wrapper-content animated fadeInRight">
  12. <div class="row">
  13. <div class="col-sm-12">
  14. <div class="ibox float-e-margins">
  15. <div class="ibox-content">
  16. <form method="get" class="form-horizontal" id="form">
  17. <input type="hidden" name="siteId" id="siteId" value="{{$siteId}}">
  18. <div class="form-group">
  19. <label class="col-sm-2 control-label" for="page"><span
  20. class="red">* </span>页面:</label>
  21. <div class="col-sm-6">
  22. <input type="text" class="form-control" id="page" name="page" autocomplete="off"
  23. value="{{$info->page??''}}">
  24. </div>
  25. </div>
  26. <div class="form-group">
  27. <label class="col-sm-2 control-label" for="style_path"><span class="red">* </span>
  28. 样式参考:</label>
  29. <div class="col-sm-6">
  30. <input type="text" class="form-control" id="style_path" name="style_path"
  31. value="{{$info->style_path??''}}" autocomplete="off">
  32. </div>
  33. </div>
  34. <div class="form-group">
  35. <label class="col-sm-2 control-label" for="data_memo"><span class="red">* </span>
  36. 替换资料要求:</label>
  37. <div class="col-sm-6">
  38. <textarea name="data_memo" id="data_memo"
  39. style="width: 100%;height: 100px ;border: 1px solid #e5e6e7;">{{$info->data_memo??''}}</textarea>
  40. </div>
  41. </div>
  42. <div class="form-group">
  43. <label class="col-sm-2 control-label" for="deadline"><span class="red">* </span>
  44. 提交资料deadline:</label>
  45. <div class="col-sm-6">
  46. <input type="text" style="width: 200px" class="form-control my-date deadline"
  47. name="deadline" id="deadline"
  48. value="{{$info->deadline??''}}" autocomplete="off">
  49. </div>
  50. </div>
  51. <div class="form-group">
  52. <div class="col-sm-4 col-sm-offset-2">
  53. <button class="btn btn-primary" type="button" data-id="{{$info->id??0}}"
  54. id="save">
  55. 保存
  56. </button>
  57. <button class="btn btn-white" type="button" id="cancel">取消</button>
  58. </div>
  59. </div>
  60. </form>
  61. </div>
  62. </div>
  63. </div>
  64. </div>
  65. </div>
  66. </body>
  67. @endsection
  68. @section('footer')
  69. <script src="{{asset('js/plugins/switchery/switchery.js')}}"></script>
  70. <script src="https://cdn.jsdelivr.net/npm/bootstrap-select@1.13.9/dist/js/bootstrap-select.min.js"></script>
  71. <script src="{{asset('js/plugins/layDate-v5.0.9/laydate/laydate.js')}}"></script>
  72. <script>
  73. //同时绑定多个
  74. lay('.deadline').each(function () {
  75. laydate.render({
  76. elem: this
  77. , trigger: 'click'
  78. });
  79. });
  80. $(document).on('click', '#cancel', function () {
  81. tips.closeParentLayer();
  82. });
  83. $(document).on('click', '#save', function () {
  84. var data = tips.getFormValues('#form');
  85. var id = $(this).data('id');
  86. var url = '/admin/flow/clientAdd/' + id + '/' + data.siteId;
  87. var type = 'post';
  88. var ajaxConfig = {
  89. url: url,
  90. type: type,
  91. data: data,
  92. success: function (result) {
  93. layer.msg(result.message, {icon: 6, time: 1500}, function () {
  94. tips.closeParentLayer();
  95. window.parent.tips.tableRefresh('#table');
  96. });
  97. }
  98. };
  99. tips.ajax(ajaxConfig);
  100. });
  101. </script>
  102. @endsection