Nav apraksta
Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.

pack_index.htm 10KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225
  1. {include file="public/layout" /}
  2. <script type="text/javascript" src="__SKIN__/js/clipboard.min.js"></script>
  3. <body class="bodystyle" style="cursor: default; -moz-user-select: inherit;min-width:auto;">
  4. <div id="append_parent"></div>
  5. <div id="ajaxwaitid"></div>
  6. <div class="page min-hg-c-10">
  7. <div class="flexigrid">
  8. <div class="mDiv pt0">
  9. <div class="ftitle">
  10. {eq name="'Language@pack_add'|is_check_access" value="1"}
  11. <div class="fbutton">
  12. <a href="javascript:void(0);" data-href="{:url('Language/pack_add')}" onclick="openFullframe(this, '新增语言包变量', '600px', '480px');">
  13. <div class="add">
  14. <span><i class="layui-icon layui-icon-addition"></i>新增变量</span>
  15. </div>
  16. </a>
  17. </div>
  18. {/eq}
  19. {eq name="'Language@pack_batch_add'|is_check_access" value="1"}
  20. <div class="fbutton">
  21. <a href="javascript:void(0);" data-href="{:url('Language/pack_batch_add')}" onclick="openFullframe(this, '批量新增语言包变量', '600px', '550px');">
  22. <div class="adds">
  23. <span>批量新增</span>
  24. </div>
  25. </a>
  26. </div>
  27. {/eq}
  28. </div>
  29. <form class="navbar-form form-inline" action="{:url('Language/pack_index')}" method="get" onsubmit="layer_loading('正在处理');">
  30. {$searchform.hidden|default=''}
  31. <div class="sDiv">
  32. {eq name="'Language@pack_syn'|is_check_access" value="1"}
  33. <div class="fbutton check_pack_syn" style="float: none; display: none;">
  34. <a href="{:url("Language/pack_syn")}">
  35. <div class="adds">
  36. <span><i class="fa fa-download"></i>同步官方语言包</span>
  37. </div>
  38. </a>
  39. </div>
  40. {/eq}
  41. <div class="sDiv2">
  42. <input type="text" size="30" name="keywords" value="{$Request.param.keywords}" class="qsbox" placeholder="变量值搜索...">
  43. <input type="submit" class="btn" value="搜索">
  44. <i class="iconfont e-sousuo"></i>
  45. </div>
  46. </div>
  47. </form>
  48. </div>
  49. <div class="hDiv">
  50. <div class="hDivBox">
  51. <table cellspacing="0" cellpadding="0" style="width: 100%">
  52. <thead>
  53. <tr>
  54. <th class="sign w40" axis="col0">
  55. <div class="tc"><input type="checkbox" class="checkAll"></div>
  56. </th>
  57. <th abbr="article_time" axis="col6" class="w200">
  58. <div class="tl text-l10">变量名</div>
  59. </th>
  60. <th abbr="article_title" axis="col3" class="">
  61. <div class="tl text-l10">变量值</div>
  62. </th>
  63. <th abbr="article_time" axis="col6" class="w100">
  64. <div class="tc">更新时间</div>
  65. </th>
  66. <th axis="col1" class="w160">
  67. <div class="tc">操作</div>
  68. </th>
  69. </tr>
  70. </thead>
  71. </table>
  72. </div>
  73. </div>
  74. <div class="bDiv" style="height: auto;">
  75. <div id="flexigrid" cellpadding="0" cellspacing="0" border="0">
  76. <table style="width: 100%;">
  77. <tbody>
  78. {empty name="list"}
  79. <tr>
  80. <td class="no-data" align="center" axis="col0" colspan="50">
  81. <div class="no_row">
  82. <div class="no_pic"><img src="__SKIN__/images/null-data.png"></div>
  83. </div>
  84. </td>
  85. </tr>
  86. {else/}
  87. {foreach name="list" item="vo" key="k" }
  88. <tr>
  89. <td class="sign">
  90. <div class="tc w40">
  91. {neq name='$vo.is_syn' value='1'}
  92. <input type="checkbox" autocomplete="off" name="ids[]" value="{$vo.id}">
  93. {/neq}
  94. </div>
  95. </td>
  96. <td class="">
  97. <div class="w200 tl text-l10">
  98. <a href="{:url('Language/pack_edit',array('id'=>$vo['id']))}">{$vo.name}</a>
  99. </div>
  100. </td>
  101. <td class="" style="width: 100%;">
  102. <div class="tl text-l10">
  103. {$vo.value|htmlentities=###}
  104. </div>
  105. </td>
  106. <td>
  107. <div class="w100 tc">
  108. {$vo.update_time|date='Y-m-d',###}
  109. </div>
  110. </td>
  111. <td class="operation">
  112. <div class="w160 tc">
  113. {eq name="'Language@pack_edit'|is_check_access" value="1"}
  114. <a href="javascript:void(0);" data-href="{:url('Language/pack_edit',array('id'=>$vo['id']))}" onclick="openFullframe(this, '编辑模板语言变量', '600px', '480px');" class="btn blue">编辑</a>
  115. <i></i>
  116. {/eq}
  117. {eq name="'Language@pack_del'|is_check_access" value="1"}
  118. {neq name='$vo.is_syn' value='1'}
  119. <a class="btn red" href="javascript:void(0);" data-url="{:url('Language/pack_del')}" data-id="{$vo.id}" onClick="delfun(this);">删除</a>
  120. <i></i>
  121. {/neq}
  122. {/eq}
  123. <a href="javascript:void(0);" onclick="showtext('{$vo['name']}');" class="btn blue {$vo['name']}" data-clipboard-text="{{php} echo 'eyou:lang name=\'';{/php}{$vo['name']}{php} echo '\' /';{/php}}">复制标签</a>
  124. </div>
  125. </td>
  126. </tr>
  127. {/foreach}
  128. {/empty}
  129. </tbody>
  130. </table>
  131. </div>
  132. <div class="iDiv" style="display: none;"></div>
  133. </div>
  134. <div class="tDiv">
  135. <div class="tDiv2">
  136. <div class="fbutton checkboxall">
  137. <input type="checkbox" class="checkAll">
  138. </div>
  139. {eq name="'Language@pack_del'|is_check_access" value="1"}
  140. <div class="fbutton">
  141. <a onclick="batch_del(this, 'ids');" data-url="{:url('Language/pack_del')}">
  142. <div class="add">
  143. <span>批量删除</span>
  144. </div>
  145. </a>
  146. </div>
  147. {/eq}
  148. </div>
  149. <div style="clear:both"></div>
  150. </div>
  151. <!--分页位置-->
  152. {$pageStr}
  153. </div>
  154. </div>
  155. <script type="text/javascript">
  156. $(function(){
  157. $('input[name*=ids]').click(function(){
  158. if ($('input[name*=ids]').length == $('input[name*=ids]:checked').length) {
  159. $('.checkAll').prop('checked','checked');
  160. } else {
  161. $('.checkAll').prop('checked', false);
  162. }
  163. });
  164. $('input[type=checkbox].checkAll').click(function(){
  165. $('input[type=checkbox]:not(:disabled)').prop('checked',this.checked);
  166. });
  167. });
  168. $(document).ready(function(){
  169. // 表格行点击选中切换
  170. $('#flexigrid > table>tbody >tr').click(function(){
  171. $(this).toggleClass('trSelected');
  172. });
  173. // 点击刷新数据
  174. $('.fa-refresh').click(function(){
  175. location.href = location.href;
  176. });
  177. });
  178. // 复制标签
  179. function showtext(classname){
  180. var clipboard1 = new Clipboard("."+classname);clipboard1.on("success", function(e) {layer.msg("复制成功");});clipboard1.on("error", function(e) {layer.msg("复制失败!请手动复制", {icon:5});});
  181. }
  182. function delfun(obj){
  183. var title = $(obj).attr('data-typename');
  184. layer.confirm('<font color="#ff0000">将同步删除全部语言的该变量</font>,确认删除?', {
  185. shade: layer_shade,
  186. area: ['480px', '190px'],
  187. move: false,
  188. title: '提示',
  189. btnAlign:'r',
  190. closeBtn: 3,
  191. btn: ['确定', '取消'] ,//按钮
  192. success: function () {
  193. $(".layui-layer-content").css('text-align', 'left');
  194. }
  195. }, function(){
  196. layer_loading('正在处理');
  197. // 确定
  198. $.ajax({
  199. type : 'post',
  200. url : $(obj).attr('data-url'),
  201. data : {del_id:$(obj).attr('data-id'), _ajax:1},
  202. dataType : 'json',
  203. success : function(data){
  204. layer.closeAll();
  205. if(data.code == 1){
  206. layer.msg(data.msg, {icon: 1});
  207. window.location.reload();
  208. }else{
  209. layer.alert(data.msg, {icon: 2, title:false});
  210. }
  211. }
  212. })
  213. }, function(index){
  214. layer.close(index);
  215. }
  216. );
  217. return false;
  218. }
  219. </script>
  220. {include file="public/footer" /}