not_online_reason.blade.php 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323
  1. @extends('admin/layout')
  2. @section('header')
  3. <link rel="stylesheet" href="{{asset('js/plugins/jquery-pretty-radio-checkbox/css/jquery-labelauty.css')}}"
  4. rel="stylesheet">
  5. {{--<link href="{{asset('js/plugins/jquery-pretty-radio-checkbox/js/jquery-labelauty.js')}}" rel="stylesheet">--}}
  6. @endsection
  7. <style type="text/css">
  8. ul {
  9. list-style-type: none;
  10. }
  11. li {
  12. display: inline-block;
  13. }
  14. input.labelauty + label {
  15. font: 12px "Microsoft Yahei";
  16. display: inline-block !important;
  17. }
  18. table.tftable {
  19. font-size: 12px;
  20. color: #333333;
  21. width: 100%;
  22. border-width: 1px;
  23. border-color: #9dcc7a;
  24. border-collapse: collapse;
  25. }
  26. table.tftable th {
  27. font-size: 12px;
  28. background-color: #abd28e;
  29. border-width: 1px;
  30. padding: 8px;
  31. border-style: solid;
  32. border-color: #9dcc7a;
  33. text-align: left;
  34. }
  35. table.tftable tr {
  36. background-color: #ffffff;
  37. }
  38. table.tftable td {
  39. font-size: 12px;
  40. border-width: 1px;
  41. padding: 8px;
  42. border-style: solid;
  43. border-color: #9dcc7a;
  44. }
  45. .fenish {
  46. background: #1D976C;
  47. color: #fff;
  48. }
  49. .blue {
  50. background: #6DD5FA;
  51. color: #fff;
  52. }
  53. #tfhover tbody tr td:nth-child(2) {
  54. position: relative;
  55. padding-left: 35px;
  56. }
  57. .fa {
  58. position: absolute;
  59. left: 10px;
  60. top: 0;
  61. color: #ddd;
  62. transform: translateY(-50%);
  63. top: 50%;
  64. font-size: 18px !important;
  65. cursor: pointer;
  66. }
  67. .first-numb {
  68. color: palevioletred;
  69. }
  70. </style>
  71. <div style="margin-left: 10px">
  72. <form action="{{url('/admin/flow/notOnlineReason')}}" method="post" id="form1">
  73. <div style="display: flex;padding: 10px 0;">
  74. <input type="text" placeholder="请输入域名或项目名称" class="input-md form-control" name="keyword" id="keyword"
  75. style="width: 260px;" value="{{$result['keyword']??''}}">
  76. <select name="manageHelperId" id="manageHelperId" title="" class="form-control"
  77. style="width: 150px;float: right"
  78. onchange="units.selectPage();">
  79. <option value="">请选择项目经理</option>
  80. @foreach($userList as $item)
  81. @if($item->role_id==25)
  82. <option
  83. value="{{$item->id}}"
  84. @if(!empty($result['manageHelperId']) && $result['manageHelperId']==$item->id) selected @endif>{{$item->nickname}}</option>
  85. @endif
  86. @endforeach
  87. </select>
  88. <select name="editorId" id="editorId" title="" class="form-control"
  89. style="width: 150px;float: right" onchange="units.selectPage();">
  90. <option value="">请选择采编</option>
  91. @foreach($userList as $item)
  92. @if($item->role_id==2)
  93. <option
  94. value="{{$item->id}}" @if(!empty($result['editorId']) && $result['editorId']==$item->id) selected @endif>{{$item->nickname}}</option>
  95. @endif
  96. @endforeach
  97. </select>
  98. <select name="webId" id="webId" title="" class="form-control"
  99. style="width: 150px;float: right" onchange="units.selectPage();">
  100. <option value="">请选择前端</option>
  101. @foreach($userList as $item)
  102. @if($item->role_id==14)
  103. <option value="{{$item->id}}"
  104. @if(!empty($result['webId']) && $result['webId']==$item->id) selected @endif>{{$item->nickname}}</option>
  105. @endif
  106. @endforeach
  107. </select>
  108. <select name="plannerId" id="plannerId" title="" class="form-control"
  109. style="width: 150px;float: right" onchange="units.selectPage();">
  110. <option value="">请选择策划师</option>
  111. @foreach($userList as $item)
  112. @if($item->role_id==29)
  113. <option value="{{$item->id}}"
  114. @if(!empty($result['plannerId']) && $result['plannerId']==$item->id) selected @endif>{{$item->nickname}}</option>
  115. @endif
  116. @endforeach
  117. </select>
  118. <select name="schedule" id="schedule" title="" class="form-control"
  119. style="width: 150px;float: right" onchange="units.selectPage();">
  120. <option value="">请选择进度</option>
  121. <option value="1" @if(!empty($result['schedule']) && $result['schedule']==1) selected @endif>网站修改-前端配合</option>
  122. <option value="2" @if(!empty($result['schedule']) && $result['schedule']==2) selected @endif>资料情况-客服部协调</option>
  123. <option value="3" @if(!empty($result['schedule']) && $result['schedule']==3) selected @endif>关键词地图-策划师</option>
  124. <option value="4" @if(!empty($result['schedule']) && $result['schedule']==4) selected @endif>TDK布局-策划师</option>
  125. <option value="5" @if(!empty($result['schedule']) && $result['schedule']==5) selected @endif>网站上线前质检-HINA&质检部</option>
  126. <option value="6" @if(!empty($result['schedule']) && $result['schedule']==6) selected @endif>网站客户体验-设计配合</option>
  127. </select>
  128. <input style="margin-left: 10px" type="submit" class="btn btn-primary" value="搜索">
  129. <button style="margin-left: 10px" type="button" class="btn btn-primary reset"> 重置</button>
  130. <button style="margin-left: 10px" type="button" class=" btn btn-primary button"> 保存</button>
  131. </div>
  132. </form>
  133. </div>
  134. <table id="tfhover" class="tftable" border="1">
  135. <thead>
  136. <tr>
  137. <th colspan="11" style="text-align: center">
  138. 未上线原因统计
  139. </th>
  140. </tr>
  141. <tr>
  142. <th style="width: 3%;text-align: center">序号</th>
  143. <th style="width: 10%;text-align: center">项目名称</th>
  144. <th style="width: 5%;text-align: center">测试站网址</th>
  145. <th style="width: 5%;text-align: center">项目经理</th>
  146. <th style="width: 10%;text-align: center">当月截止时间</th>
  147. <th style="width: 40%;text-align: center">项目进度</th>
  148. <th style="width: 10%;text-align: center">备注</th>
  149. </tr>
  150. </thead>
  151. <tbody>
  152. @foreach($siteList as $key=>$value)
  153. <tr>
  154. <td>
  155. {{$key+1}}
  156. </td>
  157. <td data-a="{{$value['id']}}" data-rank="{{$value['rank']??''}}">
  158. <i @if($value['rank']==1)class="fa fa-heart first-numb" @else class="fa fa-heart" @endif></i>
  159. <a onclick="units.openDetail('{{$value['id']}}','{{$value['cn_title']}}')">{{$value['cn_title']}}</a>
  160. </td>
  161. <td>{{$value['domain']??''}}</td>
  162. <td>{{$value['manage_helper_title']??''}}</td>
  163. <td>{{$value['current_month_online_date']??''}}</td>
  164. <td>
  165. <ul class="dowebok">
  166. <li><input type="checkbox" name="checkbox" value="1" @if(in_array(1,$value['type'])) checked
  167. @endif data-labelauty="网站修改-前端配合"></li>
  168. <li><input type="checkbox" name="checkbox" value="2" @if(in_array(2,$value['type'])) checked
  169. @endif data-labelauty="资料情况-客服部协调"></li>
  170. <li><input type="checkbox" name="checkbox" value="3" @if(in_array(3,$value['type'])) checked
  171. @endif data-labelauty="关键词地图-策划师"></li>
  172. <li><input type="checkbox" name="checkbox" value="4" @if(in_array(4,$value['type'])) checked
  173. @endif data-labelauty="TDK布局-策划师"></li>
  174. <li><input type="checkbox" name="checkbox" value="5" @if(in_array(5,$value['type'])) checked
  175. @endif data-labelauty="网站上线前质检-HINA&质检部"></li>
  176. <li><input type="checkbox" name="checkbox" value="6" @if(in_array(6,$value['type'])) checked
  177. @endif data-labelauty="网站客户体验-设计配合"></li>
  178. <li><input type="checkbox" name="checkbox" value="7" @if(in_array(7,$value['type'])) checked
  179. @endif data-labelauty="客户自建站"></li>
  180. <li><input type="checkbox" name="checkbox" value="8" @if(in_array(8,$value['type'])) checked
  181. @endif data-labelauty="重庆资料问题"></li>
  182. </ul>
  183. </td>
  184. <td><textarea style="border: none;width: 100%;height: 100px">{{$value['memo']??''}}</textarea></td>
  185. </tr>
  186. @endforeach
  187. </tbody>
  188. </table>
  189. @section('footer')
  190. <script src="{{asset('js/plugins/jquery-pretty-radio-checkbox/js/jquery-labelauty.js')}}"></script>
  191. <script>
  192. $(function () {
  193. $(':input').labelauty();
  194. });
  195. window.onload = function () {
  196. var tfrow = document.getElementById('tfhover').rows.length;
  197. var tbRow = [];
  198. for (var i = 1; i < tfrow; i++) {
  199. tbRow[i] = document.getElementById('tfhover').rows[i];
  200. tbRow[i].onmouseover = function () {
  201. this.style.backgroundColor = '#f3f8aa';
  202. };
  203. tbRow[i].onmouseout = function () {
  204. this.style.backgroundColor = '#ffffff';
  205. };
  206. }
  207. };
  208. $('#tfhover tbody tr td:nth-child(2) i').click(function () {
  209. var rank = 0;
  210. if ($(this).hasClass('first-numb')) {
  211. $(this).removeClass('first-numb');
  212. } else {
  213. rank = 1;
  214. $(this).addClass('first-numb');
  215. }
  216. var siteId = $(this).parent().attr('data-a');
  217. var ajaxConfig = {
  218. url: '/admin/flow/setSiteIdByRankId',
  219. type: 'post',
  220. data: {siteId: siteId, type: 7, rank: rank},
  221. success: function (result) {
  222. layer.msg(result.message, {icon: 6, time: 1000}, function () {
  223. window.location.reload();
  224. });
  225. }
  226. };
  227. tips.ajax(ajaxConfig);
  228. });
  229. var units = {
  230. openDetail: function (id, title) {
  231. tips.page('/admin/sites/' + id + '/overview', title);
  232. },
  233. };
  234. //重置
  235. $(function () {
  236. $('.reset').click(function () {
  237. $('#keyword').val('');
  238. $('#manageHelperId').val('');
  239. $('#editorId').val('');
  240. $('#webId').val('');
  241. $('#plannerId').val('');
  242. $('#schedule').val('');
  243. $('#form1').submit();
  244. });
  245. });
  246. $('#tfhover tbody tr td').click(function () {
  247. $(this).toggleClass("fenish");
  248. if ($(this).hasClass("fenish")) {
  249. $(this).attr("data-a", "1");
  250. } else {
  251. $(this).attr("data-a", "0");
  252. }
  253. });
  254. $('#tfhover tbody tr td:first-child').unbind('click');
  255. $('#tfhover tbody tr td:nth-child(2)').unbind('click');
  256. $('#tfhover tbody tr td:nth-child(3)').unbind('click');
  257. $('#tfhover tbody tr td:nth-child(4)').unbind('click');
  258. $('#tfhover tbody tr td:nth-child(5)').unbind('click');
  259. $('#tfhover tbody tr td:nth-child(6)').unbind('click');
  260. $('#tfhover tbody tr td:nth-child(7)').unbind('click');
  261. $(".button").click(function () {
  262. var list = [];
  263. $("#tfhover tbody").find("tr").each(function () {
  264. var tdArr = $(this).children();
  265. var site_id = tdArr.eq(1).attr('data-a');
  266. var rank = tdArr.eq(1).attr('data-rank');
  267. var memo = tdArr.eq(6).find('textarea').val();
  268. var checkbox = tdArr.eq(5).find("input[type='checkbox']");
  269. var arr = [];
  270. checkbox.each(function () {
  271. if ($(this).is(":checked")) {
  272. arr.push($(this).val())
  273. }
  274. });
  275. var array = {};
  276. array.site_id = site_id;
  277. array.rank = rank;
  278. array.memo = memo;
  279. array.type = arr;
  280. list.push(array);
  281. });
  282. var ajaxConfig = {
  283. url: '/admin/flow/notOnlineReason',
  284. type: 'post',
  285. data: {list: JSON.stringify(list)},
  286. success: function (result) {
  287. layer.msg(result.message, {icon: 6, time: 1000}, function () {
  288. window.location.reload();
  289. });
  290. }
  291. };
  292. tips.ajax(ajaxConfig);
  293. });
  294. </script>
  295. @endsection