以下离子代码是否有任何问题,因为网址'./#/tab/guiderRegister'似乎无法正常工作,只显示标题。但'./#/tab/register'和'./#/tab/signup'可以正常工作。
//离子状态
.state('tabs.register', {
url:'/register',
views:{
'home-tab':{
templateUrl:'./register',
controller:'homeController'
}
}
})
.state('tabs.guiderRegister', {
url:'/guiderRegister',
views:{
'home-tab':{
templateUrl:'./guiderRegister',
controller:'homeController'
}
}
})
.state('tabs.signup', {
url:'/signup',
views:{
'home-tab':{
templateUrl:'./signup',
controller:'homeController'
}
}
})
// HTML
<div class="row registerChoose">
<div>
<div class="chooseEG"><a href="./#/tab/register">Expat</a></div>
<div class="chooseEG"><a href="./#/tab/guiderRegister">Guider</a></div>
<div class="chooseEG"><a href="./#/tab/signup">signup</a></div>
</div>
</div>
// guiderRegister
<ion-view view-title="Guider Register" hide-tabs>
<ion-nav-buttons side="secondary">
<a href="./#/tab/signup"><button class="button button-icon">Signup</button></a>
</ion-nav-buttons>
<ion-content class="">
<div class="list">
<form name="guiderRegister" action="./postGuiderRegister" method="post" id="guiderRegister">
<label class="item item-input">
<input type="text" placeholder="Username" name="username">
</label>
<label class="item item-input">
<input type="email" placeholder="Email" name="email">
</label>
<label class="item item-input">
<input type="password" placeholder="Password" name="password">
</label>
<label class="item item-input">
<input type="password" placeholder="Password Again" name="password_confirmation">
</label>
<label class="item item-input">
<input type="text" placeholder="Nationality" name="nationality" >
</label>
<label class="item item-input">
<textarea placeholder="* Intruduce Yourself" name="constantIntro" style="min-height:6em;">
</textarea>
</label>
<!-- <label class="item item-input">
<input type="text" placeholder="Service Location" name="location">
</label> -->
<ion-toggle ng-model="serviceLocation">Service Location</ion-toggle>
<ion-radio ng-model="myLocation" ng-show="serviceLocation" ng-repeat="destination in destinationSettings" ng-value="destination.text" name="location">
@{{ destination.text }}
</ion-radio>
<label class="item item-input">
<input type="text" placeholder="Charge" name="change">
</label>
<ion-toggle ng-model="serviceProvided">Service Provided</ion-toggle>
<ion-checkbox ng-repeat="item in provideList"
ng-model="item.checked"
ng-checked="item.checked"
ng-show="serviceProvided">
@{{ item.text }}
</ion-checkbox>
<input name="_token" type="hidden" value="{{ csrf_token() }}">
</form>
</div>
</ion-content>
<ion-footer-bar align-title="middle" class="bar-stable">
<input type="submit" class="title button" value="submit" form="guiderRegister">
</ion-footer-bar>
</ion-view>