123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185 |
- <!DOCTYPE html>
- <html>
- <head>
- <meta charset="utf-8">
- <title>核销活动</title>
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
- <meta name="apple-mobile-web-app-status-bar-style" content="black">
- <meta name="apple-mobile-web-app-capable" content="yes">
- <meta name="format-detection" content="telephone=no">
- <link rel="stylesheet" type="text/css" href="../script/lib/layui/css/layui.css" />
- <script src="../script/lib/jquery/jquery.min.js"></script>
- <script src="../script/lib/layui/layui.js"></script>
- <script src="../script/lib/echarts/echarts.common.min.js"></script>
- <script><{Dever::script()}></script>
- <script src="../script/dever/core.js?1"></script>
- <style>
- .dever-upload-pic
- {
- width:100px;
- }
- h5 {
- margin-bottom: 10px;
- }
- td {
- color: black;
- }
- .layui-card-body {
- /*position: relative;*/
- /*padding: 50px 15px;*/
- line-height: 20px;
- margin-left: -20px;
- }
- .layui-input {
- /*position: relative;*/
- /*padding: 30px;*/
- margin-top: 20px;
- /*line-height: 24px;*/
- }
- .container{
- max-width: 1024px;
- margin: auto;
- }
- .layui-span{
- color: blue;
- margin-left: 80px;
- }
- .layui-col-xs4{
- font-size: 18px;
- }
- .layui-col-xs6{
- margin-top: 15px;
- font-size: 15px;
- }
- </style>
- </head>
- <body>
- <div class="layui-card">
- <div class="layui-container">
- <fieldset class="layui-elem-field layui-field-title" style="margin-top: 10px;"> </fieldset>
- <div class="layui-row">
- <div class="layui-col-xs4">
- <div class="grid-demo grid-demo-bg1"><{$active_name}></div>
- </div>
- <div class="layui-col-xs4">
- <div class="grid-demo"><span class = 'layui-span'><{$status}></span></div>
- </div>
- </div>
- <div class="layui-row">
- <div class="layui-col-xs6">
- <div class="grid-demo">活动时间:<{$act_time}></div>
- </div>
- </div>
- <input type="text" value="" autocomplete="off" id="content" autofocus="autofocus" class="layui-input" style="width: auto;display: inline;" placeholder="输入核销码">
- <div class="layui-card-body">
- <{if(isset($write_code)):}>
- <table class="table layui-table layui-table-body" id="table">
- <col width="100">
- <col width="100">
- <thead>
- <tr>
- <th>参会人</th>
- <th>邀请人</th>
- </tr>
- </thead>
- <tbody>
- <tr>
- <td>姓名:<{$join_name}></td>
- <td><{$buy_name}></td>
- </tr>
- <tr>
- <td>电话:<{$join_mobile}></td>
- <td><{$buy_mobile}></td>
- </tr>
- <tr>
- <td>核销码:<{$write_code}><br/>座位号:<{$seat_num}></td>
- <td><{$role_name}><br/><{$title_name}></td>
- </tr>
- </tbody>
- </table>
- <div><a href="javascript:;" class="layui-btn" id="hexiao" onclick="hexiao();">确认核销</a></div>
- <{endif}>
- </div>
- </div>
- </div>
- </div>
- <!-- <button data-method="offset" data-type="auto" type='hidden' class="layui-btn layui-btn-normal">居中弹出</button> -->
- <input id="id" name="id" value="<{$id}>" type='hidden'/>
- </div>
- <script>
- var layer;
- layui.use('layer', function(){
- layer = layui.layer;
- });
- // function search()
- // {
- // var date = $('#date').val();
-
- // location.href = config.host + 'lib/manage.code&code=' + date +'&id=<{$active_id}>';
- // }
- // $('#search').click(function() {
- // search();
- // })
- $('#content').focus();
- var id = '<{$active_id}>';
- $('#content').bind('keydown',function(event){
- if(event.keyCode == "13")
- {
- $.ajax({
- type:"GET",
- url:config.host + 'lib/manage.code',
- data: {
- id : id,
- code : $('#content').val(),
- },
- dataType: "json",
- success: function (data) {
- if (data.msg == 'success'){
- location.href = config.host + 'lib/manage.code&type=1&code=' + $('#content').val() +'&id=<{$active_id}>';
- } else {
- layer.alert('填写错误');
- }
- },
- error: function(data){
- $('#content').val('');
- alert('核销码不存在或已核销');
- }
- });
- }
- });
- var code_id = $('#id').val();
- function hexiao() {
- $.ajax({
- type: "GET",
- url: config.host + "home.confirm",
- data: {
- code_id: code_id,
- // json : 1
- },
- dataType: "json",
- success: function (data) {
- location.href = config.host + "lib/manage.code&id=<{$active_id}>";
- /*
- layer.alert(data.data.msg, function(){
- location.href = config.host + "lib/manage.code&id=<{$active_id}>";
- layer.close();
- */
- },
- error: function(data){
- alert('核销失败');
- }
- });
- }
- </script>
- </body>
- </html>
|