index.js 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. /**
  2. * Created by Administrator on 2017/8/25.
  3. */
  4. // 配置扩展方法路径
  5. layui.config({
  6. base: '{{ URL::asset("admin/frame/static/js/")}}' // 模块目录
  7. }).extend({ // 模块别名
  8. vip_nav: 'vip_nav'
  9. , vip_tab: 'vip_tab'
  10. , vip_table: 'vip_table'
  11. });
  12. function SetTwoPwd() {
  13. layer.prompt({
  14. title: '二级密码',
  15. formType: 1,
  16. },function(value){
  17. $.ajax({
  18. type: 'POST',
  19. url: '/admin/game/setSettings?game=' + game,
  20. data: {password:value,data: obj},
  21. dataType: 'json',
  22. success: function (json) {
  23. if (json.status === 1) {
  24. layer.open({
  25. title: '系统提示',
  26. type: 0,
  27. id: 'layerDemo',
  28. btnAlign: 'c',//按钮居中
  29. content: '<div style="padding: 20px 100px;font-size: 22px;">' + json.msg + '</div>'
  30. });
  31. } else {
  32. layer.msg(json.msg)
  33. }
  34. }
  35. });
  36. });
  37. }