| Id | 6 |Item | 7 |new | 8 |
|---|---|---|
| {{inventoryItem.id}} | 13 |{{inventoryItem.name}} | 14 |15 | 16 | | 17 |
26 | This prototype exposes Greg Young's m-r sample 27 | - which has been the de-facto CRQS+ES (ES = Event Sourcing) sample in the community - through a 28 | RESTful interface. 29 |
30 |31 | This prototype exemplifies: 32 |
GET /api/InventoryItem[gets all items]
GET /api/InventoryItem/{id} [gets detail of a single item]POST /api/InventoryItem[creates an item]
POST /api/InventoryItem/{id}* [checks in stock items to the inventory]POST /api/InventoryItem/{id}* [removes stock items from the inventory]PUT /api/InventoryItem/{id} [renames an item]DELETE /api/InventoryItem/{id} [de-activates an item]/api/InventoryItem/{id}/AddToStock, we send a request with
54 | media type application/json;domain-model=CheckInItemsToInventoryCommand. This also 55 | moves away from the common misconception that HTTP Verbs must be mapped to CRUD. 56 |
Locationheader 72 | after POST, etc. 73 |
118 |
133 |
134 |
43 | * // Create a new module
44 | * var myModule = angular.module('myModule', []);
45 | *
46 | * // register a new service
47 | * myModule.value('appName', 'MyCoolApp');
48 | *
49 | * // configure existing services inside initialization blocks.
50 | * myModule.config(function($locationProvider) {
51 | 'use strict';
52 | * // Configure existing providers
53 | * $locationProvider.hashPrefix('!');
54 | * });
55 | *
56 | *
57 | * Then you can create an injector and load your modules like this:
58 | *
59 | * 60 | * var injector = angular.injector(['ng', 'MyModule']) 61 | *62 | * 63 | * However it's more likely that you'll just use 64 | * {@link ng.directive:ngApp ngApp} or 65 | * {@link angular.bootstrap} to simplify this process for you. 66 | * 67 | * @param {!string} name The name of the module to create or retrieve. 68 | * @param {Array.