index.html 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990
  1. {extend name="default/base/base_seller" /}
  2. {block name="seller_btn"}<a class="dssc-btn dssc-btn-green" href="{:url('Sellertransport/add',['type'=>$Request.get.type])}">{$Think.lang.transport_tpl_add} </a>{/block}
  3. {block name="seller_main"}
  4. <div class="alert alert-block mt10">
  5. <ul class="mt5">
  6. <li>{$Think.lang.instructions_sale_area}</li>
  7. </ul>
  8. </div>
  9. {notempty name="transport_list"}
  10. <table class="dssc-default-table order">
  11. <thead>
  12. <tr>
  13. <th class="w20"></th>
  14. <th class="cell-area tl">{$Think.lang.transport_to}</th>
  15. <th class="w150">{$Think.lang.transport_price}</th>
  16. </tr>
  17. </thead>
  18. {foreach name="transport_list" item="v"}
  19. <tbody>
  20. <tr>
  21. <td colspan="20" class="sep-row"></td>
  22. </tr>
  23. <tr>
  24. <th colspan="20">
  25. {if $Request.param.type == 'select'}
  26. <a class="ml5 dssc-btn-mini dssc-btn-orange" data-param="{name:'{$v.transport_title}',id:'{$v.transport_id}',price:'{$v.transport_id.price}'}" href="javascript:void(0)"><i class="iconfont">&#xe6f1;</i>{$Think.lang.transport_applay}</span></a>
  27. {/if}
  28. <h3>{$v.transport_title}</h3>
  29. <span class="fr mr5">
  30. <time title="{$Think.lang.transport_tpl_edit_time}"><i class="iconfont">&#xe736;</i>{:date('Y-m-d H:i:s',$v.transport_updatetime)}</time>
  31. <a class="J_Clone dssc-btn-mini" href="javascript:void(0)" data-id="{$v.transport_id}"><i class="iconfont">&#xe756;</i>{$Think.lang.transport_tpl_copy}</a>
  32. <a class="J_Modify dssc-btn-mini" href="javascript:void(0)" data-id="{$v.transport_id}"><i class="iconfont">&#xe731;</i>{$Think.lang.transport_tpl_edit}</a>
  33. <a class="J_Delete dssc-btn-mini" href="javascript:void(0)" data-id="{$v.transport_id}"><i class="iconfont">&#xe725;</i>{$Think.lang.transport_tpl_del}</a>
  34. </span>
  35. </th>
  36. </tr>
  37. {notempty name="extend[$v.transport_id]['data']"}
  38. {foreach name="extend[$v.transport_id]['data']" item="value"}
  39. <tr>
  40. <td></td>
  41. <td class="cell-area tl">{$value.transportext_area_name}</td>
  42. <td>{$value.transportext_sprice}</td>
  43. </tr>
  44. {/foreach}
  45. {/notempty}
  46. </tbody>
  47. {/foreach}
  48. </table>
  49. {else}
  50. <div class="warning-option"><i class="iconfont">&#xe64c;</i><span>{$Think.lang.no_record}</span></div>
  51. {/notempty}
  52. {notempty name="transport_list"}
  53. <div class="pagination">{$show_page|raw}</div>
  54. {/notempty}
  55. <script>
  56. $(function(){
  57. $('a[class="J_Delete dssc-btn-mini"]').click(function(){
  58. var id = $(this).attr('data-id');
  59. if(typeof(id) == 'undefined') return false;
  60. ds_get_confirm('{$Think.lang.transport_del_confirm}',"{:url('Sellertransport/delete',['type'=>$Request.param.type])}&id="+id);
  61. });
  62. $('a[class="J_Modify dssc-btn-mini"]').click(function(){
  63. var id = $(this).attr('data-id');
  64. if(typeof(id) == 'undefined') return false;
  65. $(this).attr('href',"{:url('Sellertransport/edit',['type'=>$Request.param.type])}&id="+id);
  66. return true;
  67. });
  68. $('a[class="J_Clone dssc-btn-mini"]').click(function(){
  69. var id = $(this).attr('data-id');
  70. if(typeof(id) == 'undefined') return false;
  71. $(this).attr('href','{:url('Sellertransport/cloned',['type'=>$Request.param.type])}&id='+id);
  72. return true;
  73. });
  74. $('a[class="ml5 dssc-btn-mini dssc-btn-orange"]').click(function(){
  75. var data_str = '';
  76. eval('data_str = ' + $(this).attr('data-param'));
  77. $("#postageName", opener.document).css('display','inline-block').html(data_str.name);
  78. $("#transport_title", opener.document).val(data_str.name);
  79. $("#transport_id", opener.document).val(data_str.id);
  80. $("#g_freight", opener.document).val(data_str.price);
  81. window.close();
  82. });
  83. });
  84. </script>
  85. {/block}