|
9 | 9 | <label data-abm-label>Email</label> |
10 | 10 | <input type="email" name="email" class="form-control" placeholder="johndoe@mail.com" abm-form-control ng-model="user.email" required> |
11 | 11 | </abm-form-group> |
12 | | - <abm-form-group> |
13 | | - <label>Prefered notifications via:</label> |
14 | | - <div class="checkbox" abm-checkbox label="Text Message"> |
15 | | - <input type="checkbox" name="notifications" ng-model="user.notifications.text"> |
| 12 | + <div class="form-group"> |
| 13 | + <div class="togglebutton" abm-toggle label="Premium Account"> |
| 14 | + <input type="checkbox" name="premiumAccount" ng-model="user.premium" ng-change="user.paymentMode=undefined"> |
16 | 15 | </div> |
17 | | - <div class="checkbox" abm-checkbox label="Email"> |
18 | | - <input type="checkbox" name="notifications" ng-model="user.notifications.email"> |
19 | | - </div> |
20 | | - </abm-form-group> |
21 | | - <div class="togglebutton" abm-toggle label="Premium Account"> |
22 | | - <input type="checkbox" name="premiumAccount" ng-model="user.premium" ng-change="user.paymentMode=null"> |
23 | 16 | </div> |
24 | 17 | <abm-form-group error-messages="errorMap"> |
25 | 18 | <label>Prefered payment method</label> |
|
30 | 23 | <input type="radio" name="payment" value="credit" ng-model="user.paymentMode" ng-required="user.premium" ng-disabled="!user.premium"> |
31 | 24 | </div> |
32 | 25 | </abm-form-group> |
| 26 | + <div class="form-group"> |
| 27 | + <div class="togglebutton" abm-toggle label="Send Me Updates"> |
| 28 | + <input type="checkbox" name="notifications" ng-model="user.notify" ng-change="user.notifications={}"> |
| 29 | + </div> |
| 30 | + </div> |
| 31 | + <div class="row"> |
| 32 | + <div class="col-xs-6"> |
| 33 | + <abm-form-group error-messages="errorMap"> |
| 34 | + <label>Notifications via:</label> |
| 35 | + <div class="checkbox" abm-checkbox label="Text Message"> |
| 36 | + <input type="checkbox" name="text-notifications" ng-model="user.notifications.text" ng-disabled="!user.notify" ng-required="user.notify && !user.notifications.email"> |
| 37 | + </div> |
| 38 | + <div class="checkbox" abm-checkbox label="Email"> |
| 39 | + <input type="checkbox" name="email-notifications" ng-model="user.notifications.email" ng-disabled="!user.notify" ng-required="user.notify && !user.notifications.text"> |
| 40 | + </div> |
| 41 | + </abm-form-group> |
| 42 | + </div> |
| 43 | + <div class="col-xs-6"> |
| 44 | + <abm-form-group error-messages="errorMap"> |
| 45 | + <label>Notification Frequency:</label> |
| 46 | + <select class="form-control" name="frequency" abm-form-control ng-model="user.notifications.frequency" ng-disabled="!user.notify" ng-required="user.notify"> |
| 47 | + <option>Daily</option> |
| 48 | + <option>Weekly</option> |
| 49 | + <option>Monthly</option> |
| 50 | + </select> |
| 51 | + </abm-form-group> |
| 52 | + </div> |
| 53 | + </div> |
33 | 54 | <a href="" class="btn btn-raised btn-primary" ng-disabled="signup.$invalid" abm-component>Create Account</a> |
34 | 55 | </form> |
35 | 56 | </div> |
|
0 commit comments