Recently delved into learning angularjs and bootstrap. Found a tutorial on creating buttons.
<div ng-controller="ButtonsCtrl">
<h4>Checkbox</h4>
<pre>{{checkModel}}</pre>
<div>
<button type="button" class="btn btn-primary" ng-click="checkModel.KateSpade = true" btn-checkbox>Kate Spade</label>
<button type="button" class="btn btn-primary" ng-model="checkModel.LouisVuitton" btn-checkbox>Louis Vuitton</label>
<button type="button" class="btn btn-primary" ng-model="checkModel.Burberry" btn-checkbox>Burberry</label>
<button type="button" class="btn btn-primary" ng-model="checkModel.CalvinKlien" btn-checkbox>Calvin Klien</label>
<button type="button" class="btn btn-primary" ng-model="checkModel.Forever21" btn-checkbox>Forever 21</label>
</div>
</div>
Any tips on how to update the values of ng-model upon clicking? My controller setup seems pretty standard.
app.controller('ButtonsCtrl', function($scope){
console.log("ButtonsCtrl has initiated");
$scope.checkModel = {
KateSpade: false,
LouisVuitton: true,
Burberry: false,
CalvinKlien: false,
Forever21: false
};
});