官术网_书友最值得收藏!

A real-world application – koCart

In order to demonstrate how to use Knockout in a real application, we are going to build a simple shopping cart called koCart.

First of all we are going to define the user stories. We just need a few sentences to know what we want to achieve, which are as follows:

  • The user should be able to view the catalog
  • We should have the ability to search the catalog
  • The user can click on a button to add items to the catalog
  • The application will allow us to add, update, and delete items from the catalog
  • The user should be able to add, update, and delete items from the cart
  • We will allow the user to update his personal information.
  • The application should be able to calculate the total amount in the cart
  • The user should be able to complete an order

Through user stories, we can see that our application has the following three parts:

  • The catalog, which contains and manages all the products we have in the shop.
  • The cart, which has responsibility for calculating the price of each line and the total amount of the order.
  • The order, where the user can update his personal information and confirm the order.
主站蜘蛛池模板: 临汾市| 盐亭县| 秦皇岛市| 磐安县| 政和县| 河北区| 宜丰县| 科技| 清远市| 福鼎市| 仙桃市| 阜新| 仙桃市| 玉溪市| 凤城市| 绵阳市| 阿坝县| 介休市| 徐汇区| 长垣县| 千阳县| 罗田县| 湟源县| 海阳市| 随州市| 咸丰县| 鄂州市| 炎陵县| 济南市| 泗水县| 潼南县| 秦安县| 蒲城县| 崇阳县| 固安县| 泾阳县| 东乡族自治县| 桦甸市| 晋中市| 辰溪县| 多伦县|