????? <script type="text/ng-template " id="myModalContent.html ">?? ??? ??? ?<form name="merchantForm " class="bs-example form-horizontal form-validation " ng-submit="ok() ">?? ??? ??? ??? ?<div class="modal-body ">?? ??? ??? ??? ??? ?<div class="panel panel-default ">?? ??? ??? ??? ??? ??? ?<div class="panel-heading font-bold ">{{title}}</div>?? ??? ??? ??? ??? ??? ?<div class="panel-body ">?? ??? ??? ??? ??? ??? ??? ?<div class="form-group ">?? ??? ??? ??? ??? ??? ??? ??? ?<label class="col-lg-3 control-label ">商戶名稱</label>?? ??? ??? ??? ??? ??? ??? ??? ?<div class="col-lg-9 ">?? ??? ??? ??? ??? ??? ??? ??? ??? ?<input type="text " class="form-control " placeholder="商戶名稱 " ng-model="merchant.name " required ng-maxlength="32 ">?? ??? ??? ??? ??? ??? ??? ??? ??? ?<!--<span class="help-block m-b-none ">Example block-level help text here.</span>-->?? ??? ??? ??? ??? ??? ??? ??? ?</div>?? ??? ??? ??? ??? ??? ??? ?</div>?? ??? ??? ??? ??? ??? ??? ?<div class="form-group ">?? ??? ??? ??? ??? ??? ??? ??? ?<label class="col-lg-3 control-label ">商戶地址</label>?? ??? ??? ??? ??? ??? ??? ??? ?<div class="col-lg-9 ">?? ??? ??? ??? ??? ??? ??? ??? ??? ?<input type="text " class="form-control " placeholder="商戶地址 " ng-model="merchant.address " required ng-maxlength="64 ">?? ??? ??? ??? ??? ??? ??? ??? ??? ?<!--<span class="help-block m-b-none ">Example block-level help text here.</span>-->?? ??? ??? ??? ??? ??? ??? ??? ?</div>?? ??? ??? ??? ??? ??? ??? ?</div>?? ??? ??? ??? ??? ??? ??? ?<div class="form-group ">?? ??? ??? ??? ??? ??? ??? ??? ?<label class="col-lg-3 control-label ">聯(lián)系人</label>?? ??? ??? ??? ??? ??? ??? ??? ?<div class="col-lg-9 ">?? ??? ??? ??? ??? ??? ??? ??? ??? ?<input type="text " class="form-control " placeholder="聯(lián)系人 " ng-model="user.realName " required ng-maxlength="16 ">?? ??? ??? ??? ??? ??? ??? ??? ??? ?<!--<span class="help-block m-b-none ">Example block-level help text here.</span>-->?? ??? ??? ??? ??? ??? ??? ??? ?</div>?? ??? ??? ??? ??? ??? ??? ?</div>?? ??? ??? ??? ??? ??? ??? ?<div class="form-group ">?? ??? ??? ??? ??? ??? ??? ??? ?<label class="col-lg-3 control-label ">聯(lián)系電話</label>?? ??? ??? ??? ??? ??? ??? ??? ?<div class="col-lg-9 ">?? ??? ??? ??? ??? ??? ??? ??? ??? ?<input type="phone" class="form-control " placeholder="聯(lián)系電話 " ng-model="user.phone " required? ng-pattern="/^1[3|4|5|7|8][0-9]\d{8}$/" ng-maxlength="11" popover="請(qǐng)輸入您的手機(jī)號(hào)碼。" popover-trigger="focus">?? ??? ??? ??? ??? ??? ??? ??? ??? ?<!--<span class="help-block m-b-none ">Example block-level help text here.</span>-->?? ??? ??? ??? ??? ??? ??? ??? ?</div>?? ??? ??? ??? ??? ??? ??? ?</div>?? ??? ??? ??? ??? ??? ??? ?<div class="form-group ">?? ??? ??? ??? ??? ??? ??? ??? ?<label class="col-lg-3 control-label ">管理員賬號(hào)</label>?? ??? ??? ??? ??? ??? ??? ??? ?<div class="col-lg-9 ">?? ??? ??? ??? ??? ??? ??? ??? ??? ?<input type="text " class="form-control " placeholder="管理員賬號(hào) " ng-model="user.loginName " required ng-maxlength="16" ng-pattern="/^[a-zA-Z]\w{5,15}$/" popover="請(qǐng)輸入一個(gè)字母開頭,6-16字節(jié)的登錄賬號(hào)。" popover-trigger="focus">?? ??? ??? ??? ??? ??? ??? ??? ??? ?<!--<span class="help-block m-b-none ">Example block-level help text here.</span>-->?? ??? ??? ??? ??? ??? ??? ??? ?</div>?? ??? ??? ??? ??? ??? ??? ?</div>?? ??? ??? ??? ??? ??? ??? ?<div class="form-group ">?? ??? ??? ??? ??? ??? ??? ??? ?<label class="col-lg-3 control-label ">管理員密碼</label>?? ??? ??? ??? ??? ??? ??? ??? ?<div class="col-lg-9 ">?? ??? ??? ??? ??? ??? ??? ??? ??? ?<input type="password" class="form-control " placeholder="管理員密碼 " name="password " ng-model="user.password " required ng-maxlength="32" ng-pattern="/^[a-zA-Z]\w{5,15}$/"? popover="請(qǐng)輸入一個(gè)字母開頭,6-16字節(jié)的登錄密碼。">?? ??? ??? ??? ??? ??? ??? ??? ?</div>?? ??? ??? ??? ??? ??? ??? ?</div>?? ??? ??? ??? ??? ??? ??? ?<div class="form-group ">?? ??? ??? ??? ??? ??? ??? ??? ?<label class="col-lg-3 control-label ">確認(rèn)密碼</label>?? ??? ??? ??? ??? ??? ??? ??? ?<div class="col-lg-9 ">?? ??? ??? ??? ??? ??? ??? ??? ??? ?<input type="password" class="form-control " placeholder="確認(rèn)密碼 " name="confirmPassword " popover="請(qǐng)?jiān)俅未_認(rèn)您的密碼。" popover-trigger="focus" ng-model="user.confirmPassword " required ng-pattern="/^[a-zA-Z]\w{5,15}$/" ng-maxlength="32 " ui-validate=" '$value==user.password' " ui-validate-watch=" 'user.password' ">?? ??? ??? ??? ??? ??? ??? ??? ??? ?<span ng-show='merchantForm.confirmPassword.$error.validator'>確認(rèn)密碼不正確</span>?? ??? ??? ??? ??? ??? ??? ??? ?</div>?? ??? ??? ??? ??? ??? ??? ?</div>?? ??? ??? ??? ??? ??? ??? ?<div class="text-danger wrapper text-center " ng-show="authError ">?? ??? ??? ??? ??? ??? ??? ??? ?{{authError}}?? ??? ??? ??? ??? ??? ??? ?</div>?? ??? ??? ??? ??? ??? ?</div>?? ??? ??? ??? ??? ?</div>?? ??? ??? ??? ?</div>?? ??? ??? ??? ?<div class="modal-footer ">?? ??? ??? ??? ??? ?<button type="submit " class="btn btn-primary ">確認(rèn)</button>?? ??? ??? ??? ??? ?<button type="button " class="btn btn-default " ng-click="cancel() ">取消</button>?? ??? ??? ??? ?</div>?? ??? ??? ?</form>?? ??? ?</script>?? ?</div>
angularJS中form表單提交具體項(xiàng)目代碼如下,提交時(shí)候出現(xiàn)數(shù)據(jù)不全也能提交的情況。忘大神幫忙解答
慕虎8944357
2016-11-30 15:43:45