【译著】第9章 SportsStore:管理 — 《精通ASP.NET MVC 3框架》
<div id="cnblogs_post_body">C H A P T E R 9■ ■ ■
SportsStore: Administration
SportsStore:管理
In this final chapter on building the SportsStore application, we will give the site administrator a way of managing the product catalog. We will add support for creating, editing, and removing items from the product repository, as well as for uploading and displaying images alongside products in the catalog. And, since these are administrative functions, we’ll show you how to use authentication and filters to secure access to controllers and action methods, and to prompt users for credentials when needed.
在这个建立SportsStore应用程序的最后一章中,将为网站管理员提供一个管理产品分类的方法。我们将添加对产品存储库条目的创建、编辑、和删除、以及上传分类中产品的图片并在产品旁边显示图片的支持功能。另外,由于这些是管理功能,我们将演示如何使用认证和过滤来实现对控制器和动作方法的安全访问,并在需要时提示用户提供凭据。
Adding Catalog Management
添加分类管理
The convention for managing collections of items is to present the user with two types of pages: a list page and an edit page, as shown in Figure 9-1.
管理条目集合的惯例是向用户显示两种形式的页面:一个列表页面和一个编辑页面,如图9-1所示。
<div class="fig">http://images.cnblogs.com/cnblogs_com/r01cn/ch9-1.pngFigure 9-1. Sketch of a CRUD UI for the product catalog
图9-1. 用于产品分类的CRUD界面略图
页:
[1]