level.html 3.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. {template '_header'}
  2. <div class="page-header">
  3. 当前位置:<span class="text-primary">分销商等级</span>
  4. </div>
  5. <div class="page-content">
  6. <div class="page-toolbar">
  7. <span class='pull-right'>
  8. <a class='btn btn-primary btn-sm' data-toggle='ajaxModal' href="{:U('distribution/addlevel')}"><i class="fa fa-plus"></i> 添加新等级</a>
  9. </span>
  10. </div>
  11. <div class='alert alert-primary'>
  12. 提示: 没有设置等级的分销商将按默认设置计算提成。商品指定的佣金金额的优先级仍是最高的,也就是说只要商品指定了佣金金额就按商品的佣金金额来计算,不受等级影响
  13. </div>
  14. <table class="table table-responsive table-hover">
  15. <thead>
  16. <tr>
  17. <th style='width:160px;'>等级名称</th>
  18. <?php if( $data['commiss_level']>=1){ ?><th>一级佣金比例</th><?php } ?>
  19. <?php if( $data['commiss_level']>=2){ ?><th>二级佣金比例</th><?php } ?>
  20. <?php if( $data['commiss_level']>=3){ ?><th>三级佣金比例</th><?php } ?>
  21. <th>升级条件</th>
  22. <th style="width: 65px;">操作</th>
  23. </tr>
  24. </thead>
  25. <tbody>
  26. <?php foreach( $list as $row ){ ?>
  27. <tr <?php if( $row['id']=='default'){ ?>style='background:#f2f2f2'<?php } ?>>
  28. <td>{$row['levelname']}<?php if( $row['id']=='default'){ ?>【默认等级】<?php } ?></td>
  29. <?php if( $data['commiss_level']>=1){ ?><td>{php echo number_format((float)$row['commission1'],2)}%</td><?php } ?>
  30. <?php if( $data['commiss_level']>=2){ ?><td>{php echo number_format((float)$row['commission2'],2)}%</td><?php } ?>
  31. <?php if( $data['commiss_level']>=3){ ?><td>{php echo number_format((float)$row['commission3'],2)}%</td><?php } ?>
  32. <td> <?php if( $row['id']!='default'){ ?>
  33. <?php if( $row['ordermoney']>0){ ?>分销订单金额满 {$row['ordermoney']} 元 <?php }else{ ?>不自动升级<?php } ?>
  34. <?php }else{ ?>
  35. 默认等级
  36. <?php } ?>
  37. </td>
  38. <td>
  39. <a class='btn btn-default btn-sm btn-op btn-operation' data-toggle='ajaxModal' href="{:U('distribution/editlevel', array('id' => $row['id']))}">
  40. <span data-toggle="tooltip" data-placement="top" title="" data-original-title="编辑">
  41. <i class='icow icow-bianji2'></i>
  42. </span>
  43. </a>
  44. <?php if( $row['id']!='default'){ ?>
  45. <a class='btn btn-default btn-sm btn-op btn-operation' data-toggle='ajaxRemove' href="{:U('distribution/deletelevel', array('id' => $row['id']))}" data-confirm="确认删除此等级吗?">
  46. <span data-toggle="tooltip" data-placement="top" title="" data-original-title="删除">
  47. <i class='icow icow-shanchu1'></i>
  48. </span>
  49. </a>
  50. </td>
  51. <?php } ?>
  52. </tr>
  53. <?php } ?>
  54. </tbody>
  55. </table>
  56. </div>
  57. {template '_footer'}