Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.
 
 
 
 
 
 

346 строки
16 KiB

  1. <?php
  2. /**
  3. *
  4. * ============================================================================
  5. * * 版权所有 蜘蛛出行 * *
  6. * 网站地址:
  7. * ----------------------------------------------------------------------------
  8. * 这不是一个自由软件!您只能在不用于商业目的的前提下对程序代码进行修改和
  9. * 使用;不允许对程序代码以任何形式任何目的的再发布。
  10. * ============================================================================
  11. * Author By: 娄梦宁
  12. * PhpStorm cost-list.php
  13. * Create By 2017/2/22 10:16 $
  14. */
  15. use backend\modules\zzcs\assets\ZzcsAsset;
  16. use yii\widgets\Pjax;
  17. use yii\helpers\Url;
  18. ZzcsAsset::addCss($this, '/prod/css/prod_list.css?version=20170824');
  19. ZzcsAsset::addCss($this, '/plug/My97DatePicker/skin/WdatePicker.css');
  20. ZzcsAsset::addCss($this, '/global/css/combo.select.css');
  21. ZzcsAsset::addScript($this, '/global/js/jquery.combo.select.js');
  22. ZzcsAsset::addScript($this, '/prod/js/prod_list.js?version=20171110');
  23. ZzcsAsset::addScript($this, '/plug/My97DatePicker/WdatePicker.js');
  24. ZzcsAsset::addScript($this, '/plug/layer/layer.js');
  25. ?>
  26. <div class="search_cost">
  27. <ul id="search_cost">
  28. <li class="search2">
  29. <span class="name_span">名称:</span>
  30. <input id="prod_text" placeholder="门票编号/门票名称" type="text">
  31. </li>
  32. <li class="search3" style="margin-right: 30px">
  33. <span>状态:</span>
  34. <select id="isOnsale">
  35. <option value="">请选择</option>
  36. <option value="1">上架</option>
  37. <option value="0">下架</option>
  38. </select>
  39. </li>
  40. <li class="search2" style="margin-right: 50px">
  41. <span>运营负责人:</span>
  42. <select id="runDuty">
  43. <option value="">请选择</option>
  44. <?php foreach ($run_duty_list as $v):?>
  45. <option value="<?= $v['id']?>"><?= $v['true_name']?></option>
  46. <?php endforeach;?>
  47. </select>
  48. </li>
  49. <li class="search7">
  50. <span class="btn-primary" id="search_btn" onclick='searchInfo()'>查询</span>
  51. </li>
  52. </ul>
  53. </div>
  54. <div class="add_cost">
  55. <span class="btn-primary" id="add_prod" onclick="addProd()">+ 添加门票</span>
  56. <span class="btn-primary" id="batch_add" onclick="onsale()">上架</span>
  57. <span class="btn-primary" id="batch_affirm" style="" onclick="offsale()">下架</span>
  58. </div>
  59. <?php Pjax::begin(['id' => 'main_table', 'timeout' => 30000000]) ?>
  60. <div class="table_list">
  61. <table id="table_list">
  62. <thead>
  63. <tr>
  64. <th style="width: 5%"><input type="checkbox" name="select_check" class="select_all" onclick="selectAll(this)">
  65. </th>
  66. <th class="td10">门票编号</th>
  67. <th class="td20">门票名称</th>
  68. <th class="td20">供应商</th>
  69. <th class="td15">运营负责人</th>
  70. <th class="td10">创建时间</th>
  71. <th class="td10">状态</th>
  72. <th class="td10">操作</th>
  73. </tr>
  74. </thead>
  75. <tbody>
  76. <?php foreach ($prod_list as $key => $vel) { ?>
  77. <tr data-json="<?php echo str_replace('"', '&#34;', json_encode($vel)); ?>">
  78. <td style="width: 5%"><input type="checkbox" name="select_check" class="select_one" data-id="<?php echo $vel['prod_id'] ?>"></td>
  79. <td class="td10"><?php echo $vel['prod_code'] ?></td>
  80. <td class="td20"><?php echo $vel['prod_name'] ?></td>
  81. <td class="td20"><?php echo $vel['org_name']; ?></td>
  82. <td class="td15" <?php echo $vel['true_name']==''?'style="color:#ccc"':''?>><?php echo $vel['true_name']==''?'未设置':$vel['true_name']; ?></td>
  83. <td class="td10"><?php echo $vel['create_time'] ?></td>
  84. <td class="td10"> <?php echo $vel['is_onsale'] == 1 ? '上架' : '下架' ?></td>
  85. <td class="td10">
  86. <span class="update_bus_cost" prod_id="<?php echo $vel['prod_id'] ?>" onclick="open_new_path(this)" go_path="<?= Url::to(['/zzcs/prod/get-calendar?prod_id='.$vel['prod_id']]) ?>">价格设置</span>
  87. <span class="submit_bus_cost" prod_id="<?php echo $vel['prod_id'] ?>" onclick="upt_prod(<?php echo $vel['prod_id'] ?>)">修改</span>
  88. </td>
  89. </tr>
  90. <?php } ?>
  91. </tbody>
  92. </table>
  93. </div>
  94. <!--页码信息-->
  95. <div id="page_size_d" total_row="<?php echo $page['total_row']; ?>" total_page="<?php echo $page['total_page']; ?>">
  96. <span class="page_size">每页条数</span>
  97. <select id="page_size" onchange="changePageSize(this)">
  98. <?php foreach ($page_size_arr as $key => $vel) {
  99. if ($vel == $page['page_size']) {
  100. echo '<option value="' . $vel . '" selected=selected>' . $vel . '</option>';
  101. } else {
  102. echo '<option value="' . $vel . '">' . $vel . '</option>';
  103. }
  104. } ?>
  105. </select>
  106. </div>
  107. <div id="page_list">
  108. <?php
  109. if (count($page_arr) > 0) {
  110. foreach ($page_arr as $key => $vel) {
  111. if ($page['current_page'] == 1 && ($vel == '首页' || $vel == '<上一页')) {
  112. $class = 'not_click';
  113. } elseif ($page['current_page'] == $vel) {
  114. $class = 'click';
  115. } elseif ($page['current_page'] == $page['total_page'] && ($vel == '末页' || $vel == '下一页>')) {
  116. $class = 'not_click';
  117. } elseif ($vel == '...') {
  118. $class = 'not_click';
  119. } else {
  120. $class = 'clickable';
  121. }
  122. if ($vel != '首页' && $vel != '<上一页' && $vel != '下一页>' && $vel != '末页') {
  123. $class = 'page_num ' . $class;
  124. }
  125. if ($class == 'clickable' || $class == 'page_num clickable') {
  126. echo '<span class="' . $class . '" onclick="pageSearchInfo(this,' . $page['total_page'] . ')">' . $vel . '</span>';
  127. } else {
  128. echo '<span class="' . $class . '">' . $vel . '</span>';
  129. }
  130. }
  131. }
  132. ?>
  133. <span class="total_row">共<?php echo $page['total_row']; ?>条</span>
  134. </div>
  135. <?php Pjax::end() ?>
  136. <div class="modal-content" id="pop">
  137. <div class="newpro_top">新增产品</div>
  138. <div class="newpro_center" >
  139. <div class="form-inline mar_b">
  140. <span id="">门票名称:</span>
  141. <div class="form-group">
  142. <input class="form-control" id="prod_cate_name" data-id="" type="text">
  143. </div>
  144. </div>
  145. <div class="form-inline mar_b">
  146. <span id="">产品编码:</span>
  147. <div class="form-group">
  148. <input class="form-control" id="prod_code" type="text">
  149. </div>
  150. </div>
  151. <div class="form-inline mar_b">
  152. <span id="">运营负责人:</span>
  153. <div class="form-group">
  154. <select id="add_run_duty">
  155. <option value="">请选择</option>
  156. <?php foreach ($run_duty_list as $v):?>
  157. <option value="<?= $v['id']?>"><?= $v['true_name']?></option>
  158. <?php endforeach;?>
  159. </select>
  160. </div>
  161. </div>
  162. <div class="form-inline mar_b">
  163. <span style="vertical-align: top;margin-top: 7px;display: inline-block;">价格类型:</span>
  164. <div id="add_price_type" class="price_type" style="width: 300px;display: inline-block;">
  165. <button id="new_prod" style="margin-bottom: 10px;padding: 0;" type="button" class="btn btn-info" onclick="addPrice()">添加</button>
  166. <div class="price">
  167. <div style="margin-bottom: 5px;" class="form-group">
  168. <input type="text" class="form-control prod_id" name="prod_id" style="margin-left:-60px;width:80px;margin-right:20px" data-id="0" >
  169. <input class="form-control prod_price_type" data-id="0" type="text">
  170. </div>
  171. <button type="button" style="margin-bottom: 5px;" class="btn btn-danger btn-xs del_price" onclick="delPrice(this)">删除</button>
  172. </div>
  173. </div>
  174. </div>
  175. <div class="form-inline mar_b">
  176. <span id="">退款支持:</span>
  177. <div class="form-group">
  178. <input type="radio" value="1" name="is_refund" checked="checked" /> 是
  179. <input type="radio" value="0" name="is_refund"/> 否
  180. </div>
  181. </div>
  182. <div class="form-inline mar_b">
  183. <span id="">退票截止日期:</span>
  184. <div class="form-group">
  185. 提前
  186. <input type="text" value="0" id="refund_limit_day" size="5"/> 天
  187. <select id="refund_limit_time">
  188. <option value="23:59" >请选择</option>
  189. <option value="01:00">01:00</option>
  190. <option value="02:00">02:00</option>
  191. <option value="03:00">03:00</option>
  192. <option value="04:00">04:00</option>
  193. <option value="05:00">05:00</option>
  194. <option value="06:00">06:00</option>
  195. <option value="07:00">07:00</option>
  196. <option value="08:00">08:00</option>
  197. <option value="09:00">09:00</option>
  198. <option value="10:00">10:00</option>
  199. <option value="11:00">11:00</option>
  200. <option value="12:00">12:00</option>
  201. <option value="13:00">13:00</option>
  202. <option value="14:00">14:00</option>
  203. <option value="15:00">15:00</option>
  204. <option value="16:00">16:00</option>
  205. <option value="17:00">17:00</option>
  206. <option value="18:00">18:00</option>
  207. <option value="19:00">19:00</option>
  208. <option value="20:00">20:00</option>
  209. <option value="21:00">21:00</option>
  210. <option value="22:00">22:00</option>
  211. <option value="23:00">23:00</option>
  212. </select>前
  213. </div>
  214. </div>
  215. <div class="form-inline mar_b">
  216. <span id="">供应商:</span>
  217. <div class="form-group">
  218. <select id="top_org_id">
  219. <?php
  220. foreach( $supplier_list as $supplier_info ) {
  221. echo "<option value=\"{$supplier_info["org_id"]}\">{$supplier_info["org_name"]}</option>";
  222. }
  223. ?>
  224. </select>
  225. </div>
  226. </div>
  227. <div class="form-inline mar_b">
  228. <span style="vertical-align: top;">门票说明:</span>
  229. <textarea id="remark" style="width: 400px;" class="form-control" rows="5"></textarea>
  230. </div>
  231. </div>
  232. </div>
  233. <div class="modal-content" id="pop1">
  234. <div class="newpro_top">修改产品</div>
  235. <div class="newpro_center" >
  236. <div class="form-inline mar_b">
  237. <span id="">门票名称:</span>
  238. <div class="form-group">
  239. <input class="form-control" id="prod_cate_name1" data-id="" type="text">
  240. </div>
  241. </div>
  242. <div class="form-inline mar_b">
  243. <span id="">产品编码:</span>
  244. <div class="form-group">
  245. <input class="form-control" id="prod_code1" type="text">
  246. </div>
  247. </div>
  248. <div class="form-inline mar_b">
  249. <span id="">运营负责人:</span>
  250. <div class="form-group">
  251. <select class="upt_run_duty">
  252. <option value="0">请选择</option>
  253. <?php foreach ($run_duty_list as $v):?>
  254. <option value="<?= $v['id']?>"><?= $v['true_name']?></option>
  255. <?php endforeach;?>
  256. </select>
  257. </div>
  258. </div>
  259. <div class="form-inline mar_b">
  260. <span style="vertical-align: top;margin-top: 7px;display: inline-block;">价格类型:</span>
  261. <div id="add_price_type1" class="price_type1" style="width: 300px;display: inline-block;">
  262. <button id="new_prod1" style="margin-bottom: 10px;padding: 0;" type="button" class="btn btn-info" onclick="addPrice1()">添加</button>
  263. <div class="price">
  264. <div style="margin-bottom: 5px;" class="form-group">
  265. <input class="form-control prod_price_type1" data-id="0" type="text">
  266. </div>
  267. <button type="button" style="margin-bottom: 5px;" class="btn btn-danger btn-xs del_price" onclick="delPrice(this)">删除</button>
  268. </div>
  269. </div>
  270. </div>
  271. <div class="form-inline mar_b">
  272. <span id="">退款支持:</span>
  273. <div class="form-group">
  274. <input type="radio" value="1" name="is_refund1" checked="checked" /> 是
  275. <input type="radio" value="0" name="is_refund1"/> 否
  276. </div>
  277. </div>
  278. <div class="form-inline mar_b">
  279. <span id="">退票截止日期:</span>
  280. <div class="form-group">
  281. 提前
  282. <input type="text" value="0" id="refund_limit_day1" size="5"/> 天
  283. <select id="refund_limit_time1">
  284. <option value="23:59" >请选择</option
  285. <option value="02:00">02:00</option>>
  286. <option value="01:00">01:00</option>
  287. <option value="03:00">03:00</option>
  288. <option value="04:00">04:00</option>
  289. <option value="05:00">05:00</option>
  290. <option value="06:00">06:00</option>
  291. <option value="07:00">07:00</option>
  292. <option value="08:00">08:00</option>
  293. <option value="09:00">09:00</option>
  294. <option value="10:00">10:00</option>
  295. <option value="11:00">11:00</option>
  296. <option value="12:00">12:00</option>
  297. <option value="13:00">13:00</option>
  298. <option value="14:00">14:00</option>
  299. <option value="15:00">15:00</option>
  300. <option value="16:00">16:00</option>
  301. <option value="17:00">17:00</option>
  302. <option value="18:00">18:00</option>
  303. <option value="19:00">19:00</option>
  304. <option value="20:00">20:00</option>
  305. <option value="21:00">21:00</option>
  306. <option value="22:00">22:00</option>
  307. <option value="23:00">23:00</option>
  308. </select>前
  309. </div>
  310. </div>
  311. <div class="form-inline mar_b">
  312. <span id="">供应商:</span>
  313. <div class="form-group">
  314. <select id="top_org_id1" autocomplete="off" >
  315. <option value="0">请选择</option>
  316. <?php
  317. foreach( $supplier_list as $supplier_info ) {
  318. echo "<option value=\"{$supplier_info["org_id"]}\">{$supplier_info["org_name"]}</option>";
  319. }
  320. ?>
  321. </select>
  322. </div>
  323. </div>
  324. <div class="form-inline mar_b">
  325. <span style="vertical-align: top;">门票说明:</span>
  326. <textarea id="remark1" style="width: 400px;" class="form-control" rows="5"></textarea>
  327. </div>
  328. </div>
  329. </div>