poster_qrcode.html 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="utf-8">
  5. <?php $shoname_name = D('Home/Front')->get_config_by_name('shoname'); ?>
  6. <title><?php echo $shoname; ?></title>
  7. <link rel="shortcut icon" href="" />
  8. <meta name="renderer" content="webkit">
  9. <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
  10. <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
  11. <link rel="stylesheet" href="/layuiadmin/style/admin.css" media="all">
  12. <!-- 让IE8/9支持媒体查询,从而兼容栅格 -->
  13. <!--[if lt IE 9]>
  14. <script src="https://cdn.staticfile.org/html5shiv/r29/html5.min.js"></script>
  15. <script src="https://cdn.staticfile.org/respond.js/1.4.2/respond.min.js"></script>
  16. <![endif]-->
  17. <link href="./resource/css/bootstrap.min.css?v=201903260001" rel="stylesheet">
  18. <link href="./resource/css/common.css?v=201903260001" rel="stylesheet">
  19. <script type="text/javascript">
  20. window.sysinfo = {
  21. <?php if (!empty($_W['uniacid']) ){ ?>'uniacid': '{$_W['uniacid']}',<?php } ?>
  22. <?php if( !empty($_W['acid']) ){ ?>'acid': '{$_W['acid']}',<?php } ?>
  23. <?php if (!empty($_W['openid']) ) { ?>'openid': '{$_W['openid']}',<?php } ?>
  24. <?php if( !empty($_W['uid']) ) { ?>'uid': '{$_W['uid']}',<?php } ?>
  25. 'isfounder': <?php if (!empty($_W['isfounder']) ) { ?>1<?php }else{ ?>0<?php } ?>,
  26. 'siteroot': '{$_W['siteroot']}',
  27. 'siteurl': '{$_W['siteurl']}',
  28. 'attachurl': '{$_W['attachurl']}',
  29. 'attachurl_local': '{$_W['attachurl_local']}',
  30. 'attachurl_remote': '{$_W['attachurl_remote']}',
  31. 'module' : {'url' : '<?php if( defined('MODULE_URL') ) { ?>{MODULE_URL}<?php } ?>', 'name' : '<?php if (defined('IN_MODULE') ) { ?>{IN_MODULE}<?php } ?>'},
  32. 'cookie' : {'pre': ''},
  33. 'account' : {:json_encode($_W['account'])},
  34. };
  35. </script>
  36. <script type="text/javascript" src="./resource/js/lib/jquery-1.11.1.min.js"></script>
  37. <script type="text/javascript" src="./resource/js/lib/bootstrap.min.js"></script>
  38. <script type="text/javascript" src="./resource/js/app/util.js?v=201903260001"></script>
  39. <script type="text/javascript" src="./resource/js/app/common.min.js?v=201903260001"></script>
  40. <script type="text/javascript" src="./resource/js/require.js?v=201903260001"></script>
  41. <script type="text/javascript" src="./resource/js/lib/jquery.nice-select.js?v=201903260001"></script>
  42. <script type="text/javascript" src="./resource/components/colpick/colpick.js"></script>
  43. <link rel="stylesheet" href="/layuiadmin/layui/css/layui.css" media="all">
  44. <link href="/static/css/snailfish.css" rel="stylesheet">
  45. <link href="./resource/components/colpick/colpick.css" rel="stylesheet">
  46. <style>
  47. .layadmin-name {background-color: #009688;color: #fff;width: 90px;text-align: center;height: 22px;margin-bottom:2px;}
  48. a {color: #333;text-decoration: none;cursor: pointer;}
  49. a:hover{color: #333;text-decoration: none;}
  50. a:active{color: #333;text-decoration: none;}
  51. a:focus {color:#999;text-decoration: none;}
  52. .half {width: 50%;float: left;font-size: 15px;}
  53. .back_pimu{width: 300px;text-align: center;margin: 0 auto;}
  54. .back_pimu img{width: 100%;}
  55. .resetBtn{color: #3276b1;}
  56. a.resetBtn:hover{color: #3276b1;}
  57. </style>
  58. </head>
  59. <body layadmin-themealias="default">
  60. <div class="layui-fluid" style="min-width: 1000px;">
  61. <div class="layui-card">
  62. <div class="layui-card-header layui-elem-quote">当前位置:<span class="line-text">邀新海报</span></div>
  63. <div class="layui-card-body" style="padding:15px;">
  64. <div class="layui-tab layui-tab-brief" lay-filter="docDemoTabBrief">
  65. <ul class="layui-tab-title">
  66. <li><a href="{:U('invitegift/poster_background')}">背景</a></li>
  67. <li class="layui-this">二维码</li>
  68. </ul>
  69. <div class="layui-tba-content" style="height: 100%;">
  70. <form action="" method="post" class="layui-form" lay-filter="component-layui-form-item" enctype="multipart/form-data">
  71. <input type="hidden" name="invite_poster_qrcode_img" value="{$data['invite_poster_qrcode_img_yuan']}"/>
  72. <div class="layui-form-item" style="height: 750px;">
  73. <div class="half" style="background: #f1f1f1;padding: 5px;height: auto;min-height: 100%;">
  74. <div class="back_pimu" style="position: relative;background: #fff;width: 375px;height: auto;min-height: 100%;">
  75. <div class="phone_top" style="position: relative;width: 375px;height: 64px;">
  76. <img class="img" src="/static/images/diy/poster_1.png" style="width: 375px;height: 20px;position: absolute;top: 0px;left: 0px;z-index: 100;">
  77. <img class="img" src="/static/images/diy/poster_2.png" style="position: absolute;right: 7px;width: 87px;height: 32px;bottom: 6px;">
  78. </div>
  79. <div class="back_body" style="width:375px;height: 667px;<?php if($data['invite_poster_back_type'] == 0){?>background: <?php echo $data['invite_poster_back_color'];?>;<?php }else{ ?>background: url('<?php echo tomedia($data['invite_poster_back_img']);?>') no-repeat;background-size:100% 100%;<?php } ?>">
  80. <div class="qrcode" style="width: <?php echo $data['qrcode_width'];?>px;height: <?php echo $data['qrcode_width'];?>px;display: inline-block;
  81. <?php if( isset($data['invite_poster_qrcode_corner_type']) && $data['invite_poster_qrcode_corner_type'] == 1){ ?>border-radius: 0px;<?php }else{ ?>border-radius: 10px;<?php } ?>
  82. <?php if(isset($data['invite_poster_qrcode_border_status']) && $data['invite_poster_qrcode_border_status'] == 1){?>border: 1px solid <?php echo $data['invite_poster_qrcode_bordercolor']; ?>;<?php } ?>
  83. ">
  84. <img src="{$data['invite_poster_qrcode_img']}" style="width: 100%;height: 100%;
  85. <?php if( isset($data['invite_poster_qrcode_corner_type']) && $data['invite_poster_qrcode_corner_type'] == 1){ ?>border-radius: 0px;<?php }else{ ?>border-radius: 10px;<?php } ?>
  86. "></div>
  87. </div>
  88. </div>
  89. </div>
  90. <div class="half">
  91. <div class="layui-form-item">
  92. <label class="layui-form-label">二维码背景色</label>
  93. <div class="layui-input-block">
  94. <div class="layui-input-inline" style="width: 120px;">
  95. <input type="text" name="invite_poster_qrcode_backcolor" value="{$data['invite_poster_qrcode_backcolor']}" placeholder="请选择颜色" class="layui-input" id="invite_poster_qrcode_backcolor-input">
  96. </div>
  97. <div class="layui-inline" style="left: -11px;margin-right: 0px;">
  98. <div id="invitePosterQrcodeBackColors" class="layui-inline">
  99. <div class="layui-unselect layui-colorpicker"><span><span class="layui-colorpicker-trigger-span" lay-type="" style="background: {$data['invite_poster_qrcode_backcolor']}"><i class="layui-icon layui-colorpicker-trigger-i layui-icon-down"></i></span></span></div>
  100. </div>
  101. </div>
  102. <div class="layui-inline" style="vertical-align:top;line-height: 35px;">
  103. <a class="resetBtn resetQrcodeBackColor">重置</a>
  104. </div>
  105. </div>
  106. </div>
  107. <div class="layui-form-item">
  108. <label class="layui-form-label">二维码线条颜色</label>
  109. <div class="layui-input-block">
  110. <div class="layui-input-inline" style="width: 120px;">
  111. <input type="text" name="invite_poster_qrcode_linecolor" value="{$data['invite_poster_qrcode_linecolor']}" placeholder="请选择颜色" class="layui-input" id="invite_poster_qrcode_linecolor-input">
  112. </div>
  113. <div class="layui-inline" style="left: -11px;margin-right: 0px;">
  114. <div id="invitePosterQrcodeLineColors" class="layui-inline">
  115. <div class="layui-unselect layui-colorpicker"><span><span class="layui-colorpicker-trigger-span" lay-type="" style="background: {$data['invite_poster_qrcode_linecolor']}"><i class="layui-icon layui-colorpicker-trigger-i layui-icon-down"></i></span></span></div>
  116. </div>
  117. </div>
  118. <div class="layui-inline" style="vertical-align:top;line-height: 35px;">
  119. <a class="resetBtn resetQrcodeLineColor">重置</a>
  120. </div>
  121. </div>
  122. </div>
  123. <div class="layui-form-item">
  124. <label class="layui-form-label">二维码边角</label>
  125. <div class="layui-input-block">
  126. <label class='radio-inline'>
  127. <input type='radio' name='invite_poster_qrcode_corner_type' lay-filter="invite_poster_qrcode_corner_type" value='0' <?php if( !isset($data['invite_poster_qrcode_corner_type']) || $data['invite_poster_qrcode_corner_type'] == 0){ ?>checked<?php } ?> title="圆角" />
  128. </label>
  129. <label class='radio-inline'>
  130. <input type='radio' name='invite_poster_qrcode_corner_type' lay-filter="invite_poster_qrcode_corner_type" value='1' <?php if( isset($data['invite_poster_qrcode_corner_type']) && $data['invite_poster_qrcode_corner_type'] == 1){ ?>checked<?php } ?> title="直角" />
  131. </label>
  132. </div>
  133. </div>
  134. <div class="layui-form-item">
  135. <label class="layui-form-label">二维码大小</label>
  136. <div class="layui-input-block">
  137. <div class="input-group" style="width: 200px;">
  138. <input class="form-control" name="invite_poster_qrcode_size" type="text" placeholder="" value="{$data['invite_poster_qrcode_size']}" maxlength="10">
  139. <div class="input-group-addon">PX</div>
  140. </div>
  141. </div>
  142. </div>
  143. <div class="layui-form-item">
  144. <label class="layui-form-label">二维码边框</label>
  145. <div class="layui-input-block">
  146. <label class='radio-inline'>
  147. <input type='radio' name='invite_poster_qrcode_border_status' lay-filter="invite_poster_qrcode_border_status" value='1' <?php if( isset($data['invite_poster_qrcode_border_status']) && $data['invite_poster_qrcode_border_status'] == 1){ ?>checked<?php } ?> title="开启" />
  148. </label>
  149. <label class='radio-inline'>
  150. <input type='radio' name='invite_poster_qrcode_border_status' lay-filter="invite_poster_qrcode_border_status" value='0' <?php if( !isset($data['invite_poster_qrcode_border_status']) || $data['invite_poster_qrcode_border_status'] == 0){ ?>checked<?php } ?> title="关闭" />
  151. </label>
  152. </div>
  153. </div>
  154. <div class="layui-form-item">
  155. <label class="layui-form-label">二维码边框颜色</label>
  156. <div class="layui-input-block">
  157. <div class="layui-input-inline" style="width: 120px;">
  158. <input type="text" name="invite_poster_qrcode_bordercolor" value="{$data['invite_poster_qrcode_bordercolor']}" placeholder="请选择颜色" class="layui-input" id="invite_poster_qrcode_bordercolor-input">
  159. </div>
  160. <div class="layui-inline" style="left: -11px;margin-right: 0px;">
  161. <div id="invitePosterQrcodeBorderColors" class="layui-inline">
  162. <div class="layui-unselect layui-colorpicker"><span><span class="layui-colorpicker-trigger-span" lay-type="" style="background: {$data['invite_poster_qrcode_bordercolor']}"><i class="layui-icon layui-colorpicker-trigger-i layui-icon-down"></i></span></span></div>
  163. </div>
  164. </div>
  165. <div class="layui-inline" style="vertical-align:top;line-height: 35px;">
  166. <a class="resetBtn resetQrcodeBorderColor">重置</a>
  167. </div>
  168. </div>
  169. </div>
  170. <div class="layui-form-item">
  171. <label class="layui-form-label">距画布顶部</label>
  172. <div class="layui-input-block">
  173. <div class="input-group" style="width: 200px;">
  174. <input class="form-control" name="invite_poster_qrcode_top" type="text" placeholder="" value="{$data['invite_poster_qrcode_top']}" maxlength="10">
  175. <div class="input-group-addon">PX</div>
  176. </div>
  177. </div>
  178. </div>
  179. <div class="layui-form-item">
  180. <label class="layui-form-label">距画布左侧</label>
  181. <div class="layui-input-block">
  182. <div class="input-group" style="width: 200px;">
  183. <input class="form-control" name="invite_poster_qrcode_left" type="text" placeholder="" value="{$data['invite_poster_qrcode_left']}" maxlength="10">
  184. <div class="input-group-addon">PX</div>
  185. </div>
  186. </div>
  187. </div>
  188. <div class="layui-form-item">
  189. <label class="layui-form-label"> </label>
  190. <div class="layui-input-block">
  191. <input type="submit" value="提交" lay-submit lay-filter="formDemo" class="btn btn-primary" />
  192. </div>
  193. </div>
  194. </div>
  195. </div>
  196. </form>
  197. </div>
  198. </div>
  199. </div>
  200. </div>
  201. </div>
  202. <script src="/layuiadmin/layui/layui.js"></script>
  203. <script src="/static/js/drag.js"></script>
  204. <script>
  205. var invite_poster_qrcode_backcolor = "{$data['invite_poster_qrcode_backcolor']}";
  206. var invite_poster_qrcode_linecolor = "{$data['invite_poster_qrcode_linecolor']}";
  207. var invite_poster_qrcode_bordercolor = "{$data['invite_poster_qrcode_bordercolor']}";
  208. var qrcode_top = "{$data['qrcode_top']}";
  209. var qrcode_left = "{$data['qrcode_left']}";
  210. var change_url = "{:U('invitegift/changeQrcodeBackground')}";
  211. </script>
  212. <script src="/static/js/postcode/posterqrcode.js"></script>
  213. </body>