u
chenl
2018-12-10 7f89ab3d7edd9e58d76e0a959c5a7c81db1227d0
u
1 files modified
40 ■■■■ changed files
data/tpl/web/default/user/register.tpl.php 40 ●●●● patch | view | raw | blame | history
data/tpl/web/default/user/register.tpl.php
@@ -1,14 +1,22 @@
<?php defined('IN_IA') or exit('Access Denied');?><?php (!empty($this) && $this instanceof WeModuleSite || 0) ? (include $this->template('common/header-base', TEMPLATE_INCLUDEPATH)) : (include template('common/header-base', TEMPLATE_INCLUDEPATH));?>
<script>
   // 2018-11-28 添加邀请码URL传值设置 start
    <script>
    // 2018-11-28 添加邀请码URL传值设置 chenlei start
    $(function(){
        var invitationCode = getParam("invitation_code");
        if (invitationCode != null && invitationCode != "" && invitationCode != undefined && invitationCode.length == 6) {
            document.getElementById("invitation_code").value = invitationCode;
            document.getElementById("invitation_code").readOnly  = true;
        }
    });
   // 2018-11-28 添加邀请码URL传值设置 end
        var invitationCode = getParam("invitation_code");
        if (invitationCode != null && invitationCode != "" && invitationCode != undefined && invitationCode.length == 6) {
            document.getElementById("invitation_code").value = invitationCode;
            document.getElementById("invitation_code").readOnly  = true;
        }
    });
    function getParam(paramName) {
        paramValue = "", isFound = !1;
        if (this.location.search.indexOf("?") == 0 && this.location.search.indexOf("=") > 1) {
            arrSource = unescape(this.location.search).substring(1, this.location.search.length).split("&"), i = 0;
            while (i < arrSource.length && !isFound) arrSource[i].indexOf("=") > 0 && arrSource[i].split("=")[0].toLowerCase() == paramName.toLowerCase() && (paramValue = arrSource[i].split("=")[1], isFound = !0), i++
        }
        return paramValue == "" && (paramValue = null), paramValue
    }
    // 2018-11-28 添加邀请码URL传值设置 chenlei end
    $('#form1').submit(function(){
        if ($.trim($(':text[name="username"]').val()) == '') {
            util.message('没有输入用户名.', '', 'error');
@@ -40,16 +48,6 @@
        });
    var h = document.documentElement.clientHeight;
    $(".login").css('min-height',h);
    function getParam(paramName) {
        paramValue = "", isFound = !1;
        if (this.location.search.indexOf("?") == 0 && this.location.search.indexOf("=") > 1) {
            arrSource = unescape(this.location.search).substring(1, this.location.search.length).split("&"), i = 0;
            while (i < arrSource.length && !isFound) arrSource[i].indexOf("=") > 0 && arrSource[i].split("=")[0].toLowerCase() == paramName.toLowerCase() && (paramValue = arrSource[i].split("=")[1], isFound = !0), i++
        }
        return paramValue == "" && (paramValue = null), paramValue
    }
</script>
<div class="head">
    <nav class="navbar navbar-default" role="navigation">
@@ -103,9 +101,9 @@
                    
                    <!-- 2018-11-28 添加邀请码,手机号码 chenlei start -->
                    <div class="form-group">
                        <label for="" class="control-label col-sm-1">邀请码:<span class="color-red">*</span></label>
                        <label for="" class="control-label col-sm-1">邀请码:</label>
                        <div class="col-sm-11">
                            <input name="invitation_code" id="invitation_code" type="text" class="form-control" placeholder="请输入6位邀请码" ng-model="invitation_code" ng-blur="checkiIvitationCode()" required>
                            <input name="invitation_code" id="invitation_code" type="text" class="form-control" placeholder="请输入6位邀请码" ng-model="invitation_code" ng-blur="" required>
                            <span ng-class="{true:'fa fa-times form-control-feedback reg-system-valid',false:'fa fa-check form-control-feedback reg-system-valid'}[invitation_codeErr]" aria-hidden="true"></span>
                            <span ng-class="{true:'color-red',false:'sr-only'}[invitation_codeErr]" ng-bind="invitation_codeMsg"></span>
                        </div>