lizhihui

更新本地SDK

Showing 71 changed files with 516 additions and 59 deletions
No preview for this file type
No preview for this file type
No preview for this file type

7.05 KB | W: | H:

7.05 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin

81 KB | W: | H:

81 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin
......@@ -34,7 +34,7 @@ function initMatching(){
Core.isWeixin = userAgent.indexOf('MicroMessenger') != -1;
var ratio = window.devicePixelRatio;
Core.ratio = ratio;
Core.isShowIdentity = true;
var lastServer = localStorage.getItem('last_server');
if(lastServer && lastServer.indexOf('http:')==0){
......@@ -89,10 +89,12 @@ function initMatching(){
if (!Core.sdk_w) Core.sdk_w = 600;
_scale = 1;
if(ratio == 2){//5、6、6s(2.4)
_scale = 2.4 / ratio;
_scale = 2.2 / ratio;
if(userAgent.indexOf('iPad') != -1){
_scale = 2 / ratio;
}
}else if(ratio ==3){//iphoneX
_scale = 3.1 / ratio;
}else if(ratio >2.5){//6s plus
_scale = 2.7 / ratio;
}else if (ratio < 1) {
......
This diff is collapsed. Click to expand it.
......@@ -52,7 +52,9 @@
that.$c.on("click",".js-enter-game",function(e){//强制进入实名认证界面
e.stopPropagation();
Core.showTips("根据政策规定,通过实名认证才能进入游戏哦!");
Core.isShowIdentity = false;
});
}
Home.prototype.logout_cb = function(data) {
......@@ -1021,6 +1023,9 @@
});
}
IdentityCard.prototype.show_after = function(){
if(!Core.isShowIdentity){
$(".js-return-game").attr("href","javascript:Core.finishLogin()");
}
}
Core.registerMod('identityCard', IdentityCard);
......@@ -1208,7 +1213,7 @@
if(Core.Data.is_guest == 1){
//游客帐号转正
localStorage.removeItem('guest_n');
Core.showTips('升级账号成功!请妥善保管正式账号!', true);
Core.showTips('绑定账号成功!请妥善保管正式账号!', true);
delete name_ary[Core.Data.nickname];
localStorage.setItem('user_names', JSON.stringify(name_ary));
}else{
......@@ -1254,6 +1259,7 @@
Core.Data.is_guest = msg.is_guest;
Core.Data.username = msg.username;
Core.Data.nickname = msg.nickname;
Core.Data.login_key = msg.login_key;
$("input[name='loginUserName']").val(Core.Data.username);
$("input[name='loginPassword']").val(Core.user_names[Core.Data.username]);
// 强制更新显示home模块,模块自刷新
......
......@@ -901,6 +901,59 @@
Core.registerMod('question_detail', Question_detail);
//实名认证
var IdentityCard = function(modId) {
Module.call(this, modId);
}
// 继承基础模块
Core.inherit(IdentityCard, Module);
IdentityCard.prototype.bind = function() {
var that = this;
this.$c.on('click', '.submit', function() {
var identityCard = that.$c.find("input[name='identity_card']").val(),//身份证
compellationName = that.$c.find("input[name='compellation_name']").val(),//姓名
compellationNameReg = /^[\u4e00-\u9fa5]{2,10}$/i;//2-10位汉字
if($.trim(identityCard) == ""){
Core.showTips("请输入身份证号码",false);
return false;
}else if(IsIdCard(identityCard) == false){
Core.showTips("请输入正确的身份证信息",false);
return false;
}else if($.trim(compellationName) == ""){
Core.showTips("请输入姓名",false);
return false;
}else if(!compellationNameReg.test(compellationName)){
Core.showTips("请输入正确的中文姓名",false);
return false;
}
Core.ajax({
type:"post",
url:"/user/bind_identity_card?identity_card="+identityCard+"&compellation_name="+compellationName,
data:{format:"json"},
dataType:"json",
success:function(res){
if(res.code === 0){
Core.showTips('认证成功!', true);
Core.Data.compellation_name = compellationName;
Core.Data.identity_card = identityCard;
setTimeout(function() {
Core.updateMod('channel_list');
}, 500);
}else{
Core.showTips(res.msg, true);
}
}
});
});
}
IdentityCard.prototype.show_after = function(){
if(Core.Data.force_auth == 1){
$(".js-return-game").attr("href","javascript:Core.finishLogin()");
}
}
Core.registerMod('identityCard', IdentityCard);
/**
* enter_game_amount 进入sdk的要购买的游戏币
* enter_amount 进入sdk要购买的游戏币转为平台币数量(换算)
......@@ -924,7 +977,15 @@
//} else
//if (Core.Data.enter_game_amount > 0) {
// 需要进入渠道充值页面
if(Core.Data.identity_card == ""){
//游客登录则先让其实名验证
Core.start_page = "identityCard";
}else{
//正式用户直接跳到充值界面
Core.start_page = "channel_list";
}
Core.Data.game_amount = Core.Data.enter_game_amount;
Core.Data.youai_star = Core.Data.enter_amount;
Core.Data.money = Core.Data.youai_star / Core.Data.rate;
......@@ -933,7 +994,7 @@
//}
}
function onBridgeReady() {
function onBridgeReady() {
var mainImgUrl = Core.Data.game_icon;
var mainURL = Core.Data.invite_url;//'http://www.9133.com/game/' + Core.Data.app_id + '.html';
var mainTitle= '一起玩' + Core.Data.game_name;
......
......@@ -13,7 +13,6 @@
<link href="skin/login.css?v=2016" type="text/css" rel="stylesheet" />
<link id="skin" data-v="20150923001" type="text/css" rel="stylesheet" />
<title>
平台登录
</title>
......@@ -38,7 +37,9 @@
<div class="new-container-box">
<div class="SDK-titlebox"></div>
<form action="/sdk/login" method="post" class="ajax align-left clearfix">
<div class="new-sdk-logo"><a href="#"><img src="images/new-sdk-logo.png"></a></div>
<div class="new-sdk-logo"><a href="#">
<!--<img src="images/new-sdk-logo.png">-->
</a></div>
<div class="new-sdk-main">
<div class="inputbox clearfix" style="position: relative;">
<div class="ileft">账号:</div>
......@@ -61,7 +62,7 @@
</div>
<div class="other-login clearfix">
<p class="other-login-bx hide">第三方登录
<a title="新浪微博号登录" data-replace="href" href="/user/auth2/sina/login/?next=/static/sdk/login.html&app_id={app_id}" class="sina hide">
<a title="新浪微博号登录" data-replace="href" href="/user/auth2/sina/login/?next=/static/sdk/login.html&app_id={app_id}" class="sina hide">
<i class=" iconfont icon-unie61d"></i>
</a>
......@@ -77,7 +78,7 @@
<label onclick="" class="input-control pull-left hide" >
<input type="checkbox" checked="checked" class="eg" ></input>
进入号管理界面
进入号管理界面
</label>
</div>
</div>
......@@ -103,12 +104,14 @@
<div class="new-sdk-container">
<div class="new-container-box">
<div class="SDK-titlebox"></div>
<div class="new-sdk-logo"><a href="#"><img src="images/new-sdk-logo.png"></a></div>
<div class="new-sdk-logo"><a href="#">
<!--<img src="images/new-sdk-logo.png">-->
</a></div>
<div class="login-third-list">
<div class="title">请选择快速登录</div>
<div class="third-list">
<ul>
<li class="login_case_qq"><a title="QQ号登录" class="qq qq iframe" data-replace="href" href="/user/auth2/qq/login/?next=/sdk/login?app_id={app_id}"><div class="third-icon third-qq"></div><p>QQ登陆</p></a></li>
<li class="login_case_qq"><a title="QQ号登录" class="qq qq iframe" data-replace="href" href="/user/auth2/qq/login/?next=/sdk/login?app_id={app_id}"><div class="third-icon third-qq"></div><p>QQ登陆</p></a></li>
<li><a href="#register"><div class="third-icon third-guest"></div><p>游客登录</p></a></li>
<div class="clear"></div>
</ul>
......@@ -128,13 +131,15 @@
<div class="new-sdk-container">
<div class="SDK-titlebox"></div>
<div class="new-sdk-logo"><a href="#"><img src="images/new-sdk-logo.png"></a></div>
<div class="new-sdk-logo"><a href="#">
<!--<img src="images/new-sdk-logo.png">-->
</a></div>
<form action="/sdk/register" class="ajax clearfix">
<div class="new-sdk-main">
<div class="inputbox clearfix">
<div class="ileft">账号:</div>
<div class="iright">
<input type="text" name="username" placeholder="号由3-18个英文、数字、点、减号、下划线组成" required>
<input type="text" name="username" placeholder="号由3-18个英文、数字、点、减号、下划线组成" required>
<!--<div class="bottom-icon drop-down">
<i class="iconfont icon-xiangxia"></i>
</div>-->
......@@ -169,7 +174,9 @@
<section id="agreement" class="hide">
<div class="new-sdk-container">
<div class="SDK-titlebox"></div>
<div class="new-sdk-logo"><a href="#"><img src="images/new-sdk-logo.png"></a></div>
<div class="new-sdk-logo"><a href="#">
<!--<img src="images/new-sdk-logo.png">-->
</a></div>
<div class="new-sdk-content" style="overflow: hidden;">
<h3>海豹游戏服务协议</h3>
<div class="content-main" style="height: 220px;">
......@@ -388,7 +395,9 @@
<div class="new-sdk-container">
<div class="SDK-titlebox"></div>
<div class="new-sdk-logo" style="position: relative; margin-bottom: 25px;">
<a href="#"><img src="images/new-sdk-logo.png"></a>
<a href="#">
<!--<img src="images/new-sdk-logo.png">-->
</a>
<a href="#login" class="lefticon" style="position: absolute; left: 37px; top: 20px;">
<i class="iconfont icon-fanhui"></i>
</a>
......@@ -428,13 +437,15 @@
</div>
<div class="bind-user">
<div class="w_50 txt" style="display: inline-block; vertical-align: middle;">
您当前还是游客,为保证账号安全,请升级账号!
您当前还是游客,为保证账号安全,请绑定账号!
</div>
<div class="inline-btn w_45" style="display: inline-block; vertical-align: ;">
<a class="btn btn-bind" href="#modify_pwd">马上升级</a>
<a class="btn btn-bind" href="#modify_pwd">绑定账号</a>
</div>
</div>
{{? Core.Data.kefu_info != ""}}
<p style="text-align: center;font-size: 20px; color: #ff0000; position: absolute; width: 100%; bottom: 10px;left:0;">{{=Core.Data.kefu_info[0]}}</p>
{{?}}
</div>
{{?? Core.Data.is_guest == 2}}<!--1:游客登录;2:第三方登录;0:正式用户登录-->
<div class="user-center-box">
......@@ -466,8 +477,10 @@
<li style="width:50%;"><a href="#modify_pwd">修改密码</a></li>
<li style="width:50%;"><a href="#identityCard">实名认证</a></li>
</ul>
{{? Core.Data.kefu_info != ""}}
<p style="text-align: center;font-size: 20px; color: #ff0000; position: absolute; width: 100%; bottom: 10px;left:0;">{{=Core.Data.kefu_info[0]}}</p>
{{?}}
{{?}}
</div>
{{?? Core.Data.is_guest == 0}}
<div class="user-center-box">
......@@ -504,7 +517,9 @@
</a></li>
{{?}}
</ul>
{{? Core.Data.kefu_info != ""}}
<p style="text-align: center;font-size: 20px; color: #ff0000; position: absolute; width: 100%; bottom: 10px;left:0;">{{=Core.Data.kefu_info[0]}}</p>
{{?}}
{{??}}
{{? Core.Data.bind_phone === ""}}
<ul class="list-item clearfix">
......@@ -512,7 +527,9 @@
<li><a href="#mibao">设置密保</a></li>
<li><a href="#modify_pwd">修改密码</a></li>
</ul>
{{? Core.Data.kefu_info != ""}}
<p style="text-align: center;font-size: 20px; color: #ff0000; position: absolute; width: 100%; bottom: 1em;left:0;">{{=Core.Data.kefu_info[0]}}</p>
{{?}}
{{??}}
<ul class="list-item clearfix">
<li style="width:50%;"><a href="#unbindMobile">解绑手机</a></li>
......@@ -528,9 +545,11 @@
</a></li>
{{?}}
</ul>
{{? Core.Data.kefu_info != ""}}
<p style="text-align: center;font-size: 20px; color: #ff0000; position: absolute; width: 100%; bottom: 10px;left:0;">{{=Core.Data.kefu_info[0]}}</p>
{{?}}
{{?}}
{{?}}
<!--<ul class="list-item clearfix">
{{? Core.Data.bind_phone === ""}}
<li style="position: relative;"><a href="#bindMobile">绑定手机</a><span class="redround"></span></li>
......@@ -634,15 +653,13 @@
</div>
</script>
<script id="modify_pwd_template" type="text/x-jquery-tmpl">
<div class="new-sdk-container">
<div class="SDK-titlebox"></div>
<div class="user-center">
<a href="#home" class="lefticon">
<i class="iconfont icon-fanhui"></i>
</a>
{{? Core.Data.is_guest == 1}}升级账号{{??}}修改密码{{?}}
{{? Core.Data.is_guest == 1}}绑定账号{{??}}修改密码{{?}}
</div>
<form action="/sdk/change_password" mthod="post" class="ajax " todo="modify_pwd_callback" >
<div class="new-sdk-box">
......@@ -662,7 +679,7 @@
</label>
</div>
{{? Core.Data.is_guest == 1}}<p>升级账号成功之后,<span class="red">游客账号作废</span>,请妥善保管正式账号</p>{{??}}{{?}}
{{? Core.Data.is_guest == 1}}<p>绑定账号成功之后,<span class="red">游客账号作废</span>,请妥善保管正式账号</p>{{??}}{{?}}
</div>
......@@ -681,15 +698,17 @@
<div class="new-sdk-container">
<div class="SDK-titlebox"></div>
<div class="user-center">
<a href="#home" class="lefticon">
<a href="#home" class="lefticon js-return-game">
<i class="iconfont icon-fanhui"></i>
</a>
实名认证
</div>
<form action="/user/bind_identity_card" method="post" class="ajax" onkeydown="if(event.keyCode==13) return false;" >
<div class="new-sdk-box">
<div class="input" style="padding:0 25px;"><input type="text" name="identity_card" required placeholder="请输入注册身份证号码" style="text-align: left;"></div>
<div class="input" style="padding:0 25px;"><input type="text" name="identity_card" required placeholder="请输入身份证号码" style="text-align: left;"></div>
<div class="input" style="padding:0 25px;"><input type="text" name="compellation_name" required placeholder="请输入姓名" style="text-align: left;"></div>
<p style="font-size: 24px; text-indent: 1em; color: #999;text-align: left;">根据国家规定,为了保障您的权益,请登记本人实名信息</p>
</div>
<ul class="inline-btn">
<li style="padding: 1em 0; float: none; margin: 0 auto;"><a class="submit btn larg btn-orange" autocomplete="off">提交</a></li>
......@@ -1040,7 +1059,8 @@ FastClick.attach(document.body);
<script type="text/javascript" src="js/login.min.js?2016111" ></script>
<script type="text/javascript" src="js/loader.min.js?20150923001"></script>
<script type="text/javascript" src="js/simpScroller-min.js"></script>
<script type="text/javascript" src="js/identity_id.js" ></script>
<!--身份证号码验证:2.0为没有限制年龄-->
<script type="text/javascript" src="js/identity_id_2.0.js" ></script>
<script type="text/javascript">
window.onload = window.onresize = initMatching;
(function(){
......
......@@ -34,6 +34,10 @@
<!-- 首页模块 -->
<section id="home" class="hide" data-attr="dot" data-auth="1"></section>
<!-- end -->
<!--实名验证模块-->
<section id="identityCard" class="hide" data-attr="dot">
</section>
<!--end-->
<!-- 兑换元宝列表模块 -->
<section id="exchange" class="hide" data-attr="dot" data-auth="1"></section>
<!-- end -->
......@@ -185,7 +189,27 @@
</div>
</div>
</script>
<script id="identityCard_template" type="text/x-jquery-tmpl" >
<div class="new-sdk-container">
<div class="SDK-titlebox"></div>
<div class="user-center">
<a href="#channel_list" class="lefticon js-return-game">
<i class="iconfont icon-fanhui"></i>
</a>
实名认证
</div>
<form action="/user/bind_identity_card" method="post" class="ajax" onkeydown="if(event.keyCode==13) return false;" >
<div class="new-sdk-box">
<div class="input" style="padding:0 25px;"><input type="text" name="identity_card" required placeholder="请输入身份证号码" style="text-align: left;"></div>
<div class="input" style="padding:0 25px;"><input type="text" name="compellation_name" required placeholder="请输入姓名" style="text-align: left;"></div>
<p style="font-size: 24px; text-indent: 1em; color: #999;text-align: left;">根据国家规定,为了保障您的权益,请登记本人实名信息</p>
</div>
<ul class="inline-btn">
<li style="padding: 1em 0; float: none; margin: 0 auto;"><a class="submit btn larg btn-orange" autocomplete="off">提交</a></li>
</ul>
</form>
</div>
</script>
<script id='modify_pwd_template' type='text/x-jquery-tmpl'>
<div class="header">
<a class="iconfont icon-iconfontxiangyou poslft" href="##home"></a>
......@@ -784,7 +808,8 @@ FastClick.attach(document.body);
<script type="text/javascript" src="js/core.min.js?201504218002" ></script>
<script type="text/javascript" src="js/pay.min.js?201504218001" ></script>
<script type="text/javascript" src="js/loader.min.js?201504218001"></script>
<!--身份证号码验证:2.0为没有限制年龄-->
<script type="text/javascript" src="js/identity_id_2.0.js" ></script>
<script type="text/javascript">
(function(){
getData('/sdk/pay/json');
......
......@@ -23,6 +23,7 @@ section{
a,input,textarea,select {
outline: 0;
}
input[type=button],input[type=text],input[type=password]{-webkit-appearance:none;outline:none}
a:focus {
outline:thin dotted; /* 处理“outline”在Chrome浏览器中和其它浏览器之间的不一致 */
}
......
......@@ -1325,3 +1325,116 @@ input:-webkit-autofill, textarea:-webkit-autofill, select:-webkit-autofill {
background-color: rgb(255, 255, 255) !important;
box-shadow: 0 0 0px 1000px white inset !important;
}
/**------实名验证--------*/
.SDK-titlebox{
height: 33px;
background: #00beef;
}
.user-center{
position: relative;
text-align: center;
padding: 26px 0 18px;
border-bottom: 2px solid #fff;
color: #00beef;
font-family: "Microsoft YaHei","微软雅黑";
font-size: 36px;
}
.new-sdk-container .new-sdk-box {
padding: 20px 37px;
border-top: 1px solid #c4c3c3;
box-sizing: border-box;
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box;
}
.new-sdk-container .new-sdk-box .input {
margin-bottom: 15px;
border: 1px solid #c0c0c0;
/* box-shadow: 1px 2px 2px #c2c2c2 inset; */
border-radius: 10px;
-moz-border-radius: 10px;
-webkit-border-radius: 10px;
padding: 25px 0;
background: #fff;
box-sizing: border-box;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
}
.new-sdk-container .new-sdk-box .input input {
display: inline-block;
width: 100%;
background: none;
border: none;
color: #000;
font-size: 30px;
font-family: "Microsoft YaHei","微软雅黑";
white-space: nowrap;
text-overflow: ellipsis;
overflow: hidden;
word-break: break-all;
height: 45px;
line-height: 45px;
vertical-align: middle;
margin: 20px 0;
box-shadow: none;
}
ol, ul {
list-style: none;
}
.new-sdk-container .inline-btn {
overflow: auto;
zoom: 1;
width: 88%;
margin: 0px auto 25px auto;
}
.new-sdk-container .inline-btn li {
float: left;
width: 45%;
text-align: center;
background: #ff9600;
border-radius: 20px;
padding: 26px 0;
}
.new-sdk-container .inline-btn .btn {
display: inline-block;
border: 0;
background: #00beef;
color: #fff;
font-size: 30px;
font-family: "Microsoft YaHei","微软雅黑";
letter-spacing: 2px;
cursor: pointer;
width: 100%;
vertical-align: middle;
border-radius: 20px;
-moz-border-radius: 20px;
-webkit-border-radius: 20px;
}
.new-sdk-container .inline-btn .btn-orange {
background: #ff9600;
}
/*字体图标*/
@font-face {font-family: "iconfont";
src: url('../font/iconfont.eot?t=1468997064'); /* IE9*/
src: url('../font/iconfont.eot?t=1468997064#iefix') format('embedded-opentype'), /* IE6-IE8 */
url('../font/iconfont.woff?t=1468997064') format('woff'), /* chrome, firefox */
url('../font/iconfont.ttf?t=1468997064') format('truetype'), /* chrome, firefox, opera, Safari, Android, iOS 4.2+*/
url('../font/iconfont.svg?t=1468997064#iconfont') format('svg'); /* iOS 4.1- */
}
.iconfont {
font-family:"iconfont" !important;
font-size:16px;
font-style:normal;
-webkit-font-smoothing: antialiased;
-webkit-text-stroke-width: 0.2px;
-moz-osx-font-smoothing: grayscale;
}
.icon-fanhui:before { content: "\e610"; color: #00beef; font-size: 36px;}
.user-center a {
position: absolute;
left: 37px;
bottom: 7px;
color: #ff9600;
font-size: 24px;
padding: 10px;
}
\ No newline at end of file
......
#!/bin/sh
#js css压缩,生成更新包打包
CDN_SERVER='http://cdn.9133.com/static'
CDN_SERVER='http://sdk.uuufish.com/static'
DIR_PATH="$( cd "$( dirname "$0" )" && pwd )"
......
......@@ -6,7 +6,7 @@
<uses-sdk
android:minSdkVersion="8"
android:targetSdkVersion="19" />
android:targetSdkVersion="20" />
<!-- SDK start -->
<uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" />
......
......@@ -2,11 +2,12 @@
<config>
<sdkconfig
YA_APPID="58fd78a9834e7246b8dc0eac"
YA_APPKEY="b06b86b79c25774ec758657a7203bae6"
gamesimplename="fytx_test"
YA_APPID="5a374e62f0d770280d72f021"
YA_APPKEY="181d78ad8378a2994f7f390b3f5bcd9c"
game_url="http://inter.fc65.cn/api/youai/login.php"
gamesimplename="hmwz_hb"
sdksimplename="youyu"
sdkversioncode="V1_1"
sdkversioncode="V1_0"
channelparameter1=""
channelparameter2=""
custom=""
......@@ -14,6 +15,6 @@
logincheckurl="http://login.public.sdk.gzyouai.com/logincheck/check"
paycheckurl="http://pay.public.sdk.gzyouai.com/paycheck/confirm"
payorderurl="http://pay.public.sdk.gzyouai.com/paycheck/create"
usertype="gssaXIIEiL0=" />
/>
</config>
\ No newline at end of file
......

7.05 KB | W: | H:

7.05 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin

81 KB | W: | H:

81 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin
......@@ -34,7 +34,7 @@ function initMatching(){
Core.isWeixin = userAgent.indexOf('MicroMessenger') != -1;
var ratio = window.devicePixelRatio;
Core.ratio = ratio;
Core.isShowIdentity = true;
var lastServer = localStorage.getItem('last_server');
if(lastServer && lastServer.indexOf('http:')==0){
......@@ -89,10 +89,12 @@ function initMatching(){
if (!Core.sdk_w) Core.sdk_w = 600;
_scale = 1;
if(ratio == 2){//5、6、6s(2.4)
_scale = 2.4 / ratio;
_scale = 2.2 / ratio;
if(userAgent.indexOf('iPad') != -1){
_scale = 2 / ratio;
}
}else if(ratio ==3){//iphoneX
_scale = 3.1 / ratio;
}else if(ratio >2.5){//6s plus
_scale = 2.7 / ratio;
}else if (ratio < 1) {
......
......@@ -52,7 +52,9 @@
that.$c.on("click",".js-enter-game",function(e){//强制进入实名认证界面
e.stopPropagation();
Core.showTips("根据政策规定,通过实名认证才能进入游戏哦!");
Core.isShowIdentity = false;
});
}
Home.prototype.logout_cb = function(data) {
......@@ -1021,6 +1023,9 @@
});
}
IdentityCard.prototype.show_after = function(){
if(!Core.isShowIdentity){
$(".js-return-game").attr("href","javascript:Core.finishLogin()");
}
}
Core.registerMod('identityCard', IdentityCard);
......@@ -1208,7 +1213,7 @@
if(Core.Data.is_guest == 1){
//游客帐号转正
localStorage.removeItem('guest_n');
Core.showTips('升级账号成功!请妥善保管正式账号!', true);
Core.showTips('绑定账号成功!请妥善保管正式账号!', true);
delete name_ary[Core.Data.nickname];
localStorage.setItem('user_names', JSON.stringify(name_ary));
}else{
......@@ -1254,6 +1259,7 @@
Core.Data.is_guest = msg.is_guest;
Core.Data.username = msg.username;
Core.Data.nickname = msg.nickname;
Core.Data.login_key = msg.login_key;
$("input[name='loginUserName']").val(Core.Data.username);
$("input[name='loginPassword']").val(Core.user_names[Core.Data.username]);
// 强制更新显示home模块,模块自刷新
......
......@@ -901,6 +901,59 @@
Core.registerMod('question_detail', Question_detail);
//实名认证
var IdentityCard = function(modId) {
Module.call(this, modId);
}
// 继承基础模块
Core.inherit(IdentityCard, Module);
IdentityCard.prototype.bind = function() {
var that = this;
this.$c.on('click', '.submit', function() {
var identityCard = that.$c.find("input[name='identity_card']").val(),//身份证
compellationName = that.$c.find("input[name='compellation_name']").val(),//姓名
compellationNameReg = /^[\u4e00-\u9fa5]{2,10}$/i;//2-10位汉字
if($.trim(identityCard) == ""){
Core.showTips("请输入身份证号码",false);
return false;
}else if(IsIdCard(identityCard) == false){
Core.showTips("请输入正确的身份证信息",false);
return false;
}else if($.trim(compellationName) == ""){
Core.showTips("请输入姓名",false);
return false;
}else if(!compellationNameReg.test(compellationName)){
Core.showTips("请输入正确的中文姓名",false);
return false;
}
Core.ajax({
type:"post",
url:"/user/bind_identity_card?identity_card="+identityCard+"&compellation_name="+compellationName,
data:{format:"json"},
dataType:"json",
success:function(res){
if(res.code === 0){
Core.showTips('认证成功!', true);
Core.Data.compellation_name = compellationName;
Core.Data.identity_card = identityCard;
setTimeout(function() {
Core.updateMod('channel_list');
}, 500);
}else{
Core.showTips(res.msg, true);
}
}
});
});
}
IdentityCard.prototype.show_after = function(){
if(Core.Data.force_auth == 1){
$(".js-return-game").attr("href","javascript:Core.finishLogin()");
}
}
Core.registerMod('identityCard', IdentityCard);
/**
* enter_game_amount 进入sdk的要购买的游戏币
* enter_amount 进入sdk要购买的游戏币转为平台币数量(换算)
......@@ -924,7 +977,15 @@
//} else
//if (Core.Data.enter_game_amount > 0) {
// 需要进入渠道充值页面
if(Core.Data.identity_card == ""){
//游客登录则先让其实名验证
Core.start_page = "identityCard";
}else{
//正式用户直接跳到充值界面
Core.start_page = "channel_list";
}
Core.Data.game_amount = Core.Data.enter_game_amount;
Core.Data.youai_star = Core.Data.enter_amount;
Core.Data.money = Core.Data.youai_star / Core.Data.rate;
......@@ -933,7 +994,7 @@
//}
}
function onBridgeReady() {
function onBridgeReady() {
var mainImgUrl = Core.Data.game_icon;
var mainURL = Core.Data.invite_url;//'http://www.9133.com/game/' + Core.Data.app_id + '.html';
var mainTitle= '一起玩' + Core.Data.game_name;
......
......@@ -13,7 +13,6 @@
<link href="skin/login.css?v=2016" type="text/css" rel="stylesheet" />
<link id="skin" data-v="20150923001" type="text/css" rel="stylesheet" />
<title>
平台登录
</title>
......@@ -38,7 +37,9 @@
<div class="new-container-box">
<div class="SDK-titlebox"></div>
<form action="/sdk/login" method="post" class="ajax align-left clearfix">
<div class="new-sdk-logo"><a href="#"><img src="images/new-sdk-logo.png"></a></div>
<div class="new-sdk-logo"><a href="#">
<!--<img src="images/new-sdk-logo.png">-->
</a></div>
<div class="new-sdk-main">
<div class="inputbox clearfix" style="position: relative;">
<div class="ileft">账号:</div>
......@@ -61,7 +62,7 @@
</div>
<div class="other-login clearfix">
<p class="other-login-bx hide">第三方登录
<a title="新浪微博号登录" data-replace="href" href="/user/auth2/sina/login/?next=/static/sdk/login.html&app_id={app_id}" class="sina hide">
<a title="新浪微博号登录" data-replace="href" href="/user/auth2/sina/login/?next=/static/sdk/login.html&app_id={app_id}" class="sina hide">
<i class=" iconfont icon-unie61d"></i>
</a>
......@@ -77,7 +78,7 @@
<label onclick="" class="input-control pull-left hide" >
<input type="checkbox" checked="checked" class="eg" ></input>
进入号管理界面
进入号管理界面
</label>
</div>
</div>
......@@ -103,12 +104,14 @@
<div class="new-sdk-container">
<div class="new-container-box">
<div class="SDK-titlebox"></div>
<div class="new-sdk-logo"><a href="#"><img src="images/new-sdk-logo.png"></a></div>
<div class="new-sdk-logo"><a href="#">
<!--<img src="images/new-sdk-logo.png">-->
</a></div>
<div class="login-third-list">
<div class="title">请选择快速登录</div>
<div class="third-list">
<ul>
<li class="login_case_qq"><a title="QQ号登录" class="qq qq iframe" data-replace="href" href="/user/auth2/qq/login/?next=/sdk/login?app_id={app_id}"><div class="third-icon third-qq"></div><p>QQ登陆</p></a></li>
<li class="login_case_qq"><a title="QQ号登录" class="qq qq iframe" data-replace="href" href="/user/auth2/qq/login/?next=/sdk/login?app_id={app_id}"><div class="third-icon third-qq"></div><p>QQ登陆</p></a></li>
<li><a href="#register"><div class="third-icon third-guest"></div><p>游客登录</p></a></li>
<div class="clear"></div>
</ul>
......@@ -128,13 +131,15 @@
<div class="new-sdk-container">
<div class="SDK-titlebox"></div>
<div class="new-sdk-logo"><a href="#"><img src="images/new-sdk-logo.png"></a></div>
<div class="new-sdk-logo"><a href="#">
<!--<img src="images/new-sdk-logo.png">-->
</a></div>
<form action="/sdk/register" class="ajax clearfix">
<div class="new-sdk-main">
<div class="inputbox clearfix">
<div class="ileft">账号:</div>
<div class="iright">
<input type="text" name="username" placeholder="号由3-18个英文、数字、点、减号、下划线组成" required>
<input type="text" name="username" placeholder="号由3-18个英文、数字、点、减号、下划线组成" required>
<!--<div class="bottom-icon drop-down">
<i class="iconfont icon-xiangxia"></i>
</div>-->
......@@ -169,7 +174,9 @@
<section id="agreement" class="hide">
<div class="new-sdk-container">
<div class="SDK-titlebox"></div>
<div class="new-sdk-logo"><a href="#"><img src="images/new-sdk-logo.png"></a></div>
<div class="new-sdk-logo"><a href="#">
<!--<img src="images/new-sdk-logo.png">-->
</a></div>
<div class="new-sdk-content" style="overflow: hidden;">
<h3>海豹游戏服务协议</h3>
<div class="content-main" style="height: 220px;">
......@@ -388,7 +395,9 @@
<div class="new-sdk-container">
<div class="SDK-titlebox"></div>
<div class="new-sdk-logo" style="position: relative; margin-bottom: 25px;">
<a href="#"><img src="images/new-sdk-logo.png"></a>
<a href="#">
<!--<img src="images/new-sdk-logo.png">-->
</a>
<a href="#login" class="lefticon" style="position: absolute; left: 37px; top: 20px;">
<i class="iconfont icon-fanhui"></i>
</a>
......@@ -428,13 +437,15 @@
</div>
<div class="bind-user">
<div class="w_50 txt" style="display: inline-block; vertical-align: middle;">
您当前还是游客,为保证账号安全,请升级账号!
您当前还是游客,为保证账号安全,请绑定账号!
</div>
<div class="inline-btn w_45" style="display: inline-block; vertical-align: ;">
<a class="btn btn-bind" href="#modify_pwd">马上升级</a>
<a class="btn btn-bind" href="#modify_pwd">绑定账号</a>
</div>
</div>
{{? Core.Data.kefu_info != ""}}
<p style="text-align: center;font-size: 20px; color: #ff0000; position: absolute; width: 100%; bottom: 10px;left:0;">{{=Core.Data.kefu_info[0]}}</p>
{{?}}
</div>
{{?? Core.Data.is_guest == 2}}<!--1:游客登录;2:第三方登录;0:正式用户登录-->
<div class="user-center-box">
......@@ -466,8 +477,10 @@
<li style="width:50%;"><a href="#modify_pwd">修改密码</a></li>
<li style="width:50%;"><a href="#identityCard">实名认证</a></li>
</ul>
{{? Core.Data.kefu_info != ""}}
<p style="text-align: center;font-size: 20px; color: #ff0000; position: absolute; width: 100%; bottom: 10px;left:0;">{{=Core.Data.kefu_info[0]}}</p>
{{?}}
{{?}}
</div>
{{?? Core.Data.is_guest == 0}}
<div class="user-center-box">
......@@ -504,7 +517,9 @@
</a></li>
{{?}}
</ul>
{{? Core.Data.kefu_info != ""}}
<p style="text-align: center;font-size: 20px; color: #ff0000; position: absolute; width: 100%; bottom: 10px;left:0;">{{=Core.Data.kefu_info[0]}}</p>
{{?}}
{{??}}
{{? Core.Data.bind_phone === ""}}
<ul class="list-item clearfix">
......@@ -512,7 +527,9 @@
<li><a href="#mibao">设置密保</a></li>
<li><a href="#modify_pwd">修改密码</a></li>
</ul>
{{? Core.Data.kefu_info != ""}}
<p style="text-align: center;font-size: 20px; color: #ff0000; position: absolute; width: 100%; bottom: 1em;left:0;">{{=Core.Data.kefu_info[0]}}</p>
{{?}}
{{??}}
<ul class="list-item clearfix">
<li style="width:50%;"><a href="#unbindMobile">解绑手机</a></li>
......@@ -528,9 +545,11 @@
</a></li>
{{?}}
</ul>
{{? Core.Data.kefu_info != ""}}
<p style="text-align: center;font-size: 20px; color: #ff0000; position: absolute; width: 100%; bottom: 10px;left:0;">{{=Core.Data.kefu_info[0]}}</p>
{{?}}
{{?}}
{{?}}
<!--<ul class="list-item clearfix">
{{? Core.Data.bind_phone === ""}}
<li style="position: relative;"><a href="#bindMobile">绑定手机</a><span class="redround"></span></li>
......@@ -634,15 +653,13 @@
</div>
</script>
<script id="modify_pwd_template" type="text/x-jquery-tmpl">
<div class="new-sdk-container">
<div class="SDK-titlebox"></div>
<div class="user-center">
<a href="#home" class="lefticon">
<i class="iconfont icon-fanhui"></i>
</a>
{{? Core.Data.is_guest == 1}}升级账号{{??}}修改密码{{?}}
{{? Core.Data.is_guest == 1}}绑定账号{{??}}修改密码{{?}}
</div>
<form action="/sdk/change_password" mthod="post" class="ajax " todo="modify_pwd_callback" >
<div class="new-sdk-box">
......@@ -662,7 +679,7 @@
</label>
</div>
{{? Core.Data.is_guest == 1}}<p>升级账号成功之后,<span class="red">游客账号作废</span>,请妥善保管正式账号</p>{{??}}{{?}}
{{? Core.Data.is_guest == 1}}<p>绑定账号成功之后,<span class="red">游客账号作废</span>,请妥善保管正式账号</p>{{??}}{{?}}
</div>
......@@ -681,15 +698,17 @@
<div class="new-sdk-container">
<div class="SDK-titlebox"></div>
<div class="user-center">
<a href="#home" class="lefticon">
<a href="#home" class="lefticon js-return-game">
<i class="iconfont icon-fanhui"></i>
</a>
实名认证
</div>
<form action="/user/bind_identity_card" method="post" class="ajax" onkeydown="if(event.keyCode==13) return false;" >
<div class="new-sdk-box">
<div class="input" style="padding:0 25px;"><input type="text" name="identity_card" required placeholder="请输入注册身份证号码" style="text-align: left;"></div>
<div class="input" style="padding:0 25px;"><input type="text" name="identity_card" required placeholder="请输入身份证号码" style="text-align: left;"></div>
<div class="input" style="padding:0 25px;"><input type="text" name="compellation_name" required placeholder="请输入姓名" style="text-align: left;"></div>
<p style="font-size: 24px; text-indent: 1em; color: #999;text-align: left;">根据国家规定,为了保障您的权益,请登记本人实名信息</p>
</div>
<ul class="inline-btn">
<li style="padding: 1em 0; float: none; margin: 0 auto;"><a class="submit btn larg btn-orange" autocomplete="off">提交</a></li>
......@@ -1040,7 +1059,8 @@ FastClick.attach(document.body);
<script type="text/javascript" src="js/login.min.js?2016111" ></script>
<script type="text/javascript" src="js/loader.min.js?20150923001"></script>
<script type="text/javascript" src="js/simpScroller-min.js"></script>
<script type="text/javascript" src="js/identity_id.js" ></script>
<!--身份证号码验证:2.0为没有限制年龄-->
<script type="text/javascript" src="js/identity_id_2.0.js" ></script>
<script type="text/javascript">
window.onload = window.onresize = initMatching;
(function(){
......
......@@ -34,6 +34,10 @@
<!-- 首页模块 -->
<section id="home" class="hide" data-attr="dot" data-auth="1"></section>
<!-- end -->
<!--实名验证模块-->
<section id="identityCard" class="hide" data-attr="dot">
</section>
<!--end-->
<!-- 兑换元宝列表模块 -->
<section id="exchange" class="hide" data-attr="dot" data-auth="1"></section>
<!-- end -->
......@@ -185,7 +189,27 @@
</div>
</div>
</script>
<script id="identityCard_template" type="text/x-jquery-tmpl" >
<div class="new-sdk-container">
<div class="SDK-titlebox"></div>
<div class="user-center">
<a href="#channel_list" class="lefticon js-return-game">
<i class="iconfont icon-fanhui"></i>
</a>
实名认证
</div>
<form action="/user/bind_identity_card" method="post" class="ajax" onkeydown="if(event.keyCode==13) return false;" >
<div class="new-sdk-box">
<div class="input" style="padding:0 25px;"><input type="text" name="identity_card" required placeholder="请输入身份证号码" style="text-align: left;"></div>
<div class="input" style="padding:0 25px;"><input type="text" name="compellation_name" required placeholder="请输入姓名" style="text-align: left;"></div>
<p style="font-size: 24px; text-indent: 1em; color: #999;text-align: left;">根据国家规定,为了保障您的权益,请登记本人实名信息</p>
</div>
<ul class="inline-btn">
<li style="padding: 1em 0; float: none; margin: 0 auto;"><a class="submit btn larg btn-orange" autocomplete="off">提交</a></li>
</ul>
</form>
</div>
</script>
<script id='modify_pwd_template' type='text/x-jquery-tmpl'>
<div class="header">
<a class="iconfont icon-iconfontxiangyou poslft" href="##home"></a>
......@@ -784,7 +808,8 @@ FastClick.attach(document.body);
<script type="text/javascript" src="js/core.min.js?201504218002" ></script>
<script type="text/javascript" src="js/pay.min.js?201504218001" ></script>
<script type="text/javascript" src="js/loader.min.js?201504218001"></script>
<!--身份证号码验证:2.0为没有限制年龄-->
<script type="text/javascript" src="js/identity_id_2.0.js" ></script>
<script type="text/javascript">
(function(){
getData('/sdk/pay/json');
......
......@@ -23,6 +23,7 @@ section{
a,input,textarea,select {
outline: 0;
}
input[type=button],input[type=text],input[type=password]{-webkit-appearance:none;outline:none}
a:focus {
outline:thin dotted; /* 处理“outline”在Chrome浏览器中和其它浏览器之间的不一致 */
}
......
......@@ -1325,3 +1325,116 @@ input:-webkit-autofill, textarea:-webkit-autofill, select:-webkit-autofill {
background-color: rgb(255, 255, 255) !important;
box-shadow: 0 0 0px 1000px white inset !important;
}
/**------实名验证--------*/
.SDK-titlebox{
height: 33px;
background: #00beef;
}
.user-center{
position: relative;
text-align: center;
padding: 26px 0 18px;
border-bottom: 2px solid #fff;
color: #00beef;
font-family: "Microsoft YaHei","微软雅黑";
font-size: 36px;
}
.new-sdk-container .new-sdk-box {
padding: 20px 37px;
border-top: 1px solid #c4c3c3;
box-sizing: border-box;
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box;
}
.new-sdk-container .new-sdk-box .input {
margin-bottom: 15px;
border: 1px solid #c0c0c0;
/* box-shadow: 1px 2px 2px #c2c2c2 inset; */
border-radius: 10px;
-moz-border-radius: 10px;
-webkit-border-radius: 10px;
padding: 25px 0;
background: #fff;
box-sizing: border-box;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
}
.new-sdk-container .new-sdk-box .input input {
display: inline-block;
width: 100%;
background: none;
border: none;
color: #000;
font-size: 30px;
font-family: "Microsoft YaHei","微软雅黑";
white-space: nowrap;
text-overflow: ellipsis;
overflow: hidden;
word-break: break-all;
height: 45px;
line-height: 45px;
vertical-align: middle;
margin: 20px 0;
box-shadow: none;
}
ol, ul {
list-style: none;
}
.new-sdk-container .inline-btn {
overflow: auto;
zoom: 1;
width: 88%;
margin: 0px auto 25px auto;
}
.new-sdk-container .inline-btn li {
float: left;
width: 45%;
text-align: center;
background: #ff9600;
border-radius: 20px;
padding: 26px 0;
}
.new-sdk-container .inline-btn .btn {
display: inline-block;
border: 0;
background: #00beef;
color: #fff;
font-size: 30px;
font-family: "Microsoft YaHei","微软雅黑";
letter-spacing: 2px;
cursor: pointer;
width: 100%;
vertical-align: middle;
border-radius: 20px;
-moz-border-radius: 20px;
-webkit-border-radius: 20px;
}
.new-sdk-container .inline-btn .btn-orange {
background: #ff9600;
}
/*字体图标*/
@font-face {font-family: "iconfont";
src: url('../font/iconfont.eot?t=1468997064'); /* IE9*/
src: url('../font/iconfont.eot?t=1468997064#iefix') format('embedded-opentype'), /* IE6-IE8 */
url('../font/iconfont.woff?t=1468997064') format('woff'), /* chrome, firefox */
url('../font/iconfont.ttf?t=1468997064') format('truetype'), /* chrome, firefox, opera, Safari, Android, iOS 4.2+*/
url('../font/iconfont.svg?t=1468997064#iconfont') format('svg'); /* iOS 4.1- */
}
.iconfont {
font-family:"iconfont" !important;
font-size:16px;
font-style:normal;
-webkit-font-smoothing: antialiased;
-webkit-text-stroke-width: 0.2px;
-moz-osx-font-smoothing: grayscale;
}
.icon-fanhui:before { content: "\e610"; color: #00beef; font-size: 36px;}
.user-center a {
position: absolute;
left: 37px;
bottom: 7px;
color: #ff9600;
font-size: 24px;
padding: 10px;
}
\ No newline at end of file
......
#!/bin/sh
#js css压缩,生成更新包打包
CDN_SERVER='http://cdn.9133.com/static'
CDN_SERVER='http://sdk.uuufish.com/static'
DIR_PATH="$( cd "$( dirname "$0" )" && pwd )"
......
......@@ -11,4 +11,4 @@
#proguard.config=${sdk.dir}/tools/proguard/proguard-android.txt:proguard-project.txt
# Project target.
target=android-19
target=android-20
......