index.html 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172
  1. {// 引入标签库 }
  2. <tagLib name="html" />
  3. <include file="Public:header" />
  4. <php>
  5. function is_animated($animated){
  6. if($animated==0){
  7. return "普通礼物";
  8. }
  9. if($animated==1){
  10. return "gif礼物";
  11. }
  12. if($animated==2){
  13. return "大型动画礼物";
  14. }
  15. }
  16. function is_red_envelope($is_red_envelope){
  17. return $is_red_envelope?"是":"否";
  18. }
  19. function animated_item($id,$prop)
  20. {
  21. if($prop['is_animated']==1&&$id!='')
  22. {
  23. return "<a href=\"javascript:prop_item('".$id."')\">动画列表</a>";
  24. }
  25. }
  26. </php>
  27. <script>
  28. //编辑跳转
  29. function prop_item(id)
  30. {
  31. location.href = ROOT+"?"+VAR_MODULE+"="+MODULE_NAME+"&"+VAR_ACTION+"=prop_item&id="+id;
  32. }
  33. </script>
  34. <div class="main">
  35. <div class="main_title_list"><div class="list-line-ico"></div>道具列表</div>
  36. <div class="search_row">
  37. <form name="search" action="__APP__" method="get">
  38. 名称:<input type="text" class="textbox" name="name" value="{:trim($_REQUEST['name'])}" />
  39. 展示动画:<select style="width: 100px;margin:0" name="is_animated">
  40. <option value="-1" <if condition="intval($_REQUEST['is_animated']) eq -1 || !isset($_REQUEST['is_animated'])">selected="selected"</if>>{%ALL}</option>
  41. <option value="0" <if condition="intval($_REQUEST['is_animated']) eq 0 && isset($_REQUEST['is_animated'])">selected="selected"</if>>普通礼物</option>
  42. <option value="1" <if condition="intval($_REQUEST['is_animated']) eq 1">selected="selected"</if>>gif礼物</option>
  43. <option value="2" <if condition="intval($_REQUEST['is_animated']) eq 2">selected="selected"</if>>大型动画礼物</option>
  44. </select>
  45. <input type="hidden" value="Prop" name="m" />
  46. <input type="hidden" value="index" name="a" />
  47. <input type="submit" class="button" value="{%SEARCH}" />
  48. </form>
  49. </div>
  50. <html:list
  51. id="dataTable"
  52. style="dataTable"
  53. name="prop"
  54. checkbox="true"
  55. action="true"
  56. datasource="list"
  57. show="id:{%ID},name:名称,score:积分,diamonds:消费钻石,ticket:{%USER_TICKET}/钻石(是红包时表示钻石),is_red_envelope|is_red_envelope:红包,is_animated|is_animated:展示动画,is_effect|get_is_effect=$prop['id']:{%IS_EFFECT},sort|get_sort=$prop['id']:{%SORT}"
  58. actionlist="id|animated_item=$prop,edit:编辑,foreverdel:删除" />
  59. <table class="dataTable">
  60. <tbody>
  61. <td colspan="9">
  62. <input type="button" class="button button-add" value="{%ADD}" onclick="add();" />
  63. <input type="button" class="button button-del" value="{%DEL}" onclick="foreverdel();" />
  64. </td>
  65. </tbody>
  66. </table>
  67. <div class="blank5"></div>
  68. <div class="page">{$page}</div>
  69. </div>
  70. <include file="Public:footer" />