This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<tbody> | |
<tr ng-repeat="person in people"> | |
<td><a ng-click="viewPerson(person.personId)"><i class="icon-edit"></i></a></td> | |
<td>{{person.title}}</td> | |
<td>{{person.firstName}}</td> | |
<td>{{person.middleName}}</td> | |
<td>{{person.lastName}}</td> | |
<td>{{person.suffix}}</td> | |
</tr> | |
</tbody> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
angular | |
.module('myApp.ctrl.list', []) | |
.controller('listCtrl', ['$scope', '$http', '$location', function ($scope, $http, $location) { | |
$scope.people = []; | |
$scope.viewPerson = function (id) { | |
$location.path("/detail/" + id); | |
}; | |
$http({ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class ExampleDataRepository | |
{ | |
public IEnumerable<Person> GetSomePeople() | |
{ | |
using (var ctx = new ExampleDbContext()) | |
{ | |
return ctx.People.AsNoTracking().Take(30).ToList(); | |
} | |
} | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class PeopleController : ApiController | |
{ | |
public IEnumerable<Person> Get() | |
{ | |
var repository = new ExampleDataRepository(); | |
return repository.GetSomePeople(); | |
} | |
public Person Get(int id) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
basePath = '../../'; | |
files = [ | |
JASMINE, | |
JASMINE_ADAPTER, | |
'angular/angular.js', | |
'angular/angular-mocks.js', | |
'app/**/*.js', | |
'testing/unit-tests/**/*.js' | |
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/// <reference path="../../angular/angular.js" /> | |
/// <reference path="../../angular/angular-mocks.js" /> | |
/// <reference path="../../app/home/homeCtrl.js" /> | |
/// <reference path="../../app/home/contactCtrl.js" /> | |
/// <reference path="../../app/home/aboutCtrl.js" /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@{ | |
Layout = null; | |
} | |
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> | |
<html> | |
<head> | |
<title>Jasmine Spec Runner</title> | |
<link rel="stylesheet" type="text/css" href="@Url.Content("~/Scripts/testing/jasmine/jasmine.css")" /> | |
<script type="text/javascript" src="@Url.Content("~/Scripts/testing/jasmine/jasmine.js")"></script> |
NewerOlder