|
530 | 530 | <span class="help-block"> 触发流量异常导致用户被封禁的时长,到期后自动解封 </span> |
531 | 531 | </div> |
532 | 532 | </div> |
533 | | - <div class="col-md-6"></div> |
534 | | - </div> |
535 | | - |
536 | | - </div> |
537 | | - </form> |
538 | | - </div> |
539 | | - <!-- |
540 | | - <div class="tab-pane" id="tab_7"> |
541 | | - <form action="{{url('admin/setQrcode')}}" method="post" enctype="multipart/form-data" class="form-horizontal"> |
542 | | - <div class="form-body"> |
543 | | - <div class="portlet-body"> |
544 | | - <div class="form-group"> |
545 | | - <div class="col-md-6"> |
546 | | - <label class="control-label col-md-3">微信</label> |
547 | | - <div class="col-md-9"> |
548 | | - <div class="fileinput fileinput-new" data-provides="fileinput"> |
549 | | - <div class="fileinput-new thumbnail" style="width: 200px; height: 150px;"> |
550 | | - @if ($wechat_qrcode) |
551 | | - <img src="{{$wechat_qrcode}}" alt="" /> |
552 | | - @else |
553 | | - <img src="/assets/images/noimage.png" alt="" /> |
554 | | - @endif |
555 | | - </div> |
556 | | - <div class="fileinput-preview fileinput-exists thumbnail" style="max-width: 200px; max-height: 150px;"> </div> |
557 | | - <div> |
558 | | - <span class="btn default btn-file"> |
559 | | - <span class="fileinput-new"> 选择 </span> |
560 | | - <span class="fileinput-exists"> 更换 </span> |
561 | | - <input type="file" name="wechat_qrcode" id="wechat_qrcode"> |
562 | | - </span> |
563 | | - <a href="javascript:;" class="btn red fileinput-exists" data-dismiss="fileinput"> 移除 </a> |
564 | | - </div> |
565 | | - </div> |
566 | | - </div> |
567 | | - </div> |
568 | | - <div class="col-md-6"> |
569 | | - <label class="control-label col-md-3">支付宝</label> |
570 | | - <div class="col-md-9"> |
571 | | - <div class="fileinput fileinput-new" data-provides="fileinput"> |
572 | | - <div class="fileinput-new thumbnail" style="width: 200px; height: 150px;"> |
573 | | - @if ($alipay_qrcode) |
574 | | - <img src="{{$alipay_qrcode}}" alt="" /> |
575 | | - @else |
576 | | - <img src="/assets/images/noimage.png" alt="" /> |
577 | | - @endif |
578 | | - </div> |
579 | | - <div class="fileinput-preview fileinput-exists thumbnail" style="max-width: 200px; max-height: 150px;"> </div> |
580 | | - <div> |
581 | | - <span class="btn default btn-file"> |
582 | | - <span class="fileinput-new"> 选择 </span> |
583 | | - <span class="fileinput-exists"> 更换 </span> |
584 | | - <input type="file" name="alipay_qrcode" id="alipay_qrcode"> |
585 | | - </span> |
586 | | - <a href="javascript:;" class="btn red fileinput-exists" data-dismiss="fileinput"> 移除 </a> |
587 | | - </div> |
588 | | - </div> |
589 | | - </div> |
| 533 | + <div class="col-md-6"> |
| 534 | + <label for="auto_release_port" class="col-md-3 control-label">端口释放</label> |
| 535 | + <div class="col-md-9"> |
| 536 | + <input type="checkbox" class="make-switch" @if($auto_release_port) checked @endif id="auto_release_port" data-on-color="success" data-off-color="danger" data-on-text="启用" data-off-text="关闭"> |
| 537 | + <span class="help-block"> (推荐)被禁用的用户端口自动释放,重新启用则需要手动分配端口 </span> |
590 | 538 | </div> |
591 | 539 | </div> |
592 | 540 | </div> |
593 | | - </div> |
594 | | - <div class="form-actions"> |
595 | | - <div class="row"> |
596 | | - <div class="col-md-offset-6"> |
597 | | - <input type="hidden" name="_token" value="{{csrf_token()}}" /> |
598 | | - <button type="submit" class="btn green">提 交</button> |
599 | | - </div> |
600 | | - </div> |
| 541 | + |
601 | 542 | </div> |
602 | 543 | </form> |
603 | 544 | </div> |
604 | | - --> |
605 | 545 | <div class="tab-pane" id="tab_8"> |
606 | 546 | <form action="#" method="post" class="form-horizontal"> |
607 | 547 | <div class="portlet-body"> |
|
946 | 886 | } |
947 | 887 | }); |
948 | 888 |
|
| 889 | + // 启用、禁用端口自动释放 |
| 890 | + $('#auto_release_port').on({ |
| 891 | + 'switchChange.bootstrapSwitch': function(event, state) { |
| 892 | + var auto_release_port = state ? 1 : 0; |
| 893 | +
|
| 894 | + $.post("{{url('admin/setConfig')}}", {_token:'{{csrf_token()}}', name:'auto_release_port', value:auto_release_port}, function (ret) { |
| 895 | + layer.msg(ret.message, {time:1000}, function() { |
| 896 | + if (ret.status == 'fail') { |
| 897 | + window.location.reload(); |
| 898 | + } |
| 899 | + }); |
| 900 | + }); |
| 901 | + } |
| 902 | + }); |
| 903 | +
|
949 | 904 | // 启用、禁用PayPal支付接口 |
950 | 905 | $('#paypal_status').on({ |
951 | 906 | 'switchChange.bootstrapSwitch': function(event, state) { |
|
0 commit comments