5 | */
6 |
7 | .uploadify {
8 | position: relative;
9 | margin-bottom: 1em;
10 | }
11 | .uploadify-button {
12 | background-color: #505050;
13 | background-image: linear-gradient(bottom, #505050 0%, #707070 100%);
14 | background-image: -o-linear-gradient(bottom, #505050 0%, #707070 100%);
15 | background-image: -moz-linear-gradient(bottom, #505050 0%, #707070 100%);
16 | background-image: -webkit-linear-gradient(bottom, #505050 0%, #707070 100%);
17 | background-image: -ms-linear-gradient(bottom, #505050 0%, #707070 100%);
18 | background-image: -webkit-gradient(
19 | linear,
20 | left bottom,
21 | left top,
22 | color-stop(0, #505050),
23 | color-stop(1, #707070)
24 | );
25 | background-position: center top;
26 | background-repeat: no-repeat;
27 | -webkit-border-radius: 30px;
28 | -moz-border-radius: 30px;
29 | border-radius: 30px;
30 | border: 2px solid #808080;
31 | color: #FFF;
32 | font: bold 12px Arial, Helvetica, sans-serif;
33 | text-align: center;
34 | text-shadow: 0 -1px 0 rgba(0,0,0,0.25);
35 | width: 100%;
36 | }
37 | .uploadify:hover .uploadify-button {
38 | background-color: #606060;
39 | background-image: linear-gradient(top, #606060 0%, #808080 100%);
40 | background-image: -o-linear-gradient(top, #606060 0%, #808080 100%);
41 | background-image: -moz-linear-gradient(top, #606060 0%, #808080 100%);
42 | background-image: -webkit-linear-gradient(top, #606060 0%, #808080 100%);
43 | background-image: -ms-linear-gradient(top, #606060 0%, #808080 100%);
44 | background-image: -webkit-gradient(
45 | linear,
46 | left bottom,
47 | left top,
48 | color-stop(0, #606060),
49 | color-stop(1, #808080)
50 | );
51 | background-position: center bottom;
52 | }
53 | .uploadify-button.disabled {
54 | background-color: #D0D0D0;
55 | color: #808080;
56 | }
57 | .uploadify-queue {
58 | margin-bottom: 1em;
59 | }
60 | .uploadify-queue-item {
61 | background-color: #F5F5F5;
62 | -webkit-border-radius: 3px;
63 | -moz-border-radius: 3px;
64 | border-radius: 3px;
65 | font: 11px Verdana, Geneva, sans-serif;
66 | margin-top: 5px;
67 | max-width: 350px;
68 | padding: 10px;
69 | }
70 | .uploadify-error {
71 | background-color: #FDE5DD !important;
72 | }
73 | .uploadify-queue-item .cancel a {
74 | background: url('../img/uploadify-cancel.png') 0 0 no-repeat;
75 | float: right;
76 | height: 16px;
77 | text-indent: -9999px;
78 | width: 16px;
79 | }
80 | .uploadify-queue-item.completed {
81 | background-color: #E5E5E5;
82 | }
83 | .uploadify-progress {
84 | background-color: #E5E5E5;
85 | margin-top: 10px;
86 | width: 100%;
87 | }
88 | .uploadify-progress-bar {
89 | background-color: #0099FF;
90 | height: 3px;
91 | width: 1px;
92 | }
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Content/uploadify.swf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Content/uploadify.swf
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Controllers/ControllerBase.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Web.Mvc;
3 | using System.Web.Security;
4 |
5 | namespace ByteartRetail.Web.MVC.Controllers
6 | {
7 | ///
8 | /// 表示“控制器”Controller类型的基类型,所有Byteart Retail项目下的Controller都
9 | /// 应该继承于此基类型。
10 | ///
11 | public abstract class ControllerBase : Controller
12 | {
13 | #region Private Constants
14 | private const string SuccessPageAction = "SuccessPage";
15 | private const string SuccessPageController = "Home";
16 | #endregion
17 |
18 | #region Protected Properties
19 | ///
20 | /// 获取当前登录用户的ID值。
21 | ///
22 | protected Guid UserID
23 | {
24 | get
25 | {
26 | if (Session["UserID"] != null)
27 | return (Guid)Session["UserID"];
28 | var membershipUser = Membership.GetUser();
29 | if (membershipUser != null)
30 | {
31 | if (membershipUser.ProviderUserKey != null)
32 | {
33 | var id = new Guid(membershipUser.ProviderUserKey.ToString());
34 | Session["UserID"] = id;
35 | return id;
36 | }
37 | }
38 | return Guid.Empty;
39 | }
40 | }
41 | #endregion
42 |
43 | #region Protected Methods
44 | ///
45 | /// 将页面重定向到成功页面。
46 | ///
47 | /// 需要在成功页面显示的成功信息。
48 | /// 成功信息显示后返回的Action名称。默认值:Index。
49 | /// 成功信息显示后返回的Controller名称。默认值:Home。
50 | /// 在成功页面停留的时间(秒)。默认值:3。
51 | /// 执行的Action Result。
52 | protected ActionResult RedirectToSuccess(string pageTitle, string action = "Index", string controller = "Home", int waitSeconds = 3)
53 | {
54 | return RedirectToAction(SuccessPageAction, SuccessPageController, new { pageTitle = pageTitle, retAction = action, retController = controller, waitSeconds = waitSeconds });
55 | }
56 |
57 | #endregion
58 | }
59 | }
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Global.asax:
--------------------------------------------------------------------------------
1 | <%@ Application Codebehind="Global.asax.cs" Inherits="ByteartRetail.Web.MVC.MvcApplication" Language="C#" %>
2 |
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Global.asax.cs:
--------------------------------------------------------------------------------
1 | using System.Web.Mvc;
2 | using System.Web.Optimization;
3 | using System.Web.Routing;
4 | using ByteartRetail.Web.MVC.App_Start;
5 |
6 | namespace ByteartRetail.Web.MVC
7 | {
8 | // Note: For instructions on enabling IIS6 or IIS7 classic mode,
9 | // visit http://go.microsoft.com/?LinkId=9394801
10 | public class MvcApplication : System.Web.HttpApplication
11 | {
12 | protected void Application_Start()
13 | {
14 | AreaRegistration.RegisterAllAreas();
15 |
16 | //WebApiConfig.Register(GlobalConfiguration.Configuration);
17 | FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters);
18 | RouteConfig.RegisterRoutes(RouteTable.Routes);
19 | BundleConfig.RegisterBundles(BundleTable.Bundles);
20 | }
21 | }
22 | }
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Add.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Add.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Add2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Add2.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Admin_32.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Admin_32.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Back.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Back.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Bag.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Bag.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Cancel.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Cancel.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Category_32.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Category_32.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/CopyTo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/CopyTo.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Delete.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Delete.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Disable.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Disable.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Edit.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Edit.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Enable.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Enable.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Login.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Login.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Logout.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Logout.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Product_32.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Product_32.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Products/29ebfc59_e14a_49bc_9a41_d0796f392475.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Products/29ebfc59_e14a_49bc_9a41_d0796f392475.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Products/2d3df03f_0663_4f9a_8f6c_cb0af683cd23.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Products/2d3df03f_0663_4f9a_8f6c_cb0af683cd23.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Products/333c0de9_cae2_4458_a675_3560e8525ae5.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Products/333c0de9_cae2_4458_a675_3560e8525ae5.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Products/43dd3fe6_4203_41dd_b570_2c9eacb7c021.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Products/43dd3fe6_4203_41dd_b570_2c9eacb7c021.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Products/774f83b1_e90d_4ff1_a148_f90af591a865.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Products/774f83b1_e90d_4ff1_a148_f90af591a865.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Products/82d1556f_1238_43ce_a5fd_410cc246162e.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Products/82d1556f_1238_43ce_a5fd_410cc246162e.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Products/ProductImage.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Products/ProductImage.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Products/Thumbs.db:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Products/Thumbs.db
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Products/a1c1738a_eaba_4c4c_b683_7c5b4eb64306.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Products/a1c1738a_eaba_4c4c_b683_7c5b4eb64306.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Products/b182e978_85e1_474d_84e3_e505441e9000.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Products/b182e978_85e1_474d_84e3_e505441e9000.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Products/bc0d0d76_3d79_472e_86bb_63a9376d2bab.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Products/bc0d0d76_3d79_472e_86bb_63a9376d2bab.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Products/bc2dbf1a_699a_4eaf_a49f_4eccc199bb55.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Products/bc2dbf1a_699a_4eaf_a49f_4eccc199bb55.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Products/c9285a49_972c_4356_a893_3e2a4e45c17d.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Products/c9285a49_972c_4356_a893_3e2a4e45c17d.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Products/d5d4367d_ab87_4687_8d7c_d1544acf50d1.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Products/d5d4367d_ab87_4687_8d7c_d1544acf50d1.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Products/d633a09b_479f_4af2_af9d_635b7a59e1b7.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Products/d633a09b_479f_4af2_af9d_635b7a59e1b7.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Products/dafeaaed_0b93_45ea_8b04_00dd86c62d5e.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Products/dafeaaed_0b93_45ea_8b04_00dd86c62d5e.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Products/dd34e809_b1fc_4c75_b8f9_c5444a64cb47.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Products/dd34e809_b1fc_4c75_b8f9_c5444a64cb47.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Role_32.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Role_32.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/SalesOrder_32.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/SalesOrder_32.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Save.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Save.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/ShoppingCart.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/ShoppingCart.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/ShoppingCart.psd:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/ShoppingCart.psd
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/ShoppingCart256.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/ShoppingCart256.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/ShoppingCart32.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/ShoppingCart32.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/ShoppingCart64.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/ShoppingCart64.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Success_32.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Success_32.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Thumbs.db:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Thumbs.db
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/Update.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/Update.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/User_32.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/User_32.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/afterlogo.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/afterlogo.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/arrows-ffffff.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/arrows-ffffff.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/banner.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/banner.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/byteartretail_logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/byteartretail_logo.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/byteartretail_logo.psd:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/byteartretail_logo.psd
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/byteartretail_logo_trans.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/byteartretail_logo_trans.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/byteartretail_logo_trans.psd:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/byteartretail_logo_trans.psd
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/category.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/category.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/close.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/close.gif
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/favicon.ico
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/footer.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/footer.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/hard.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/hard.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/header.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/header.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/logo.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/logo.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/menu.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/menu.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/menu_beforelogo.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/menu_beforelogo.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/newtovar.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/newtovar.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/op.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/op.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/pic1.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/pic1.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/pic2.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/pic2.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/pic3.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/pic3.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/pic4.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/pic4.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/picap.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/picap.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/popular.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/popular.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/shadow.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/shadow.png
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/spacer.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/spacer.gif
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/taling.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/taling.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/taling_center.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/taling_center.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Images/trash.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Images/trash.jpg
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Models/LoginModel.cs:
--------------------------------------------------------------------------------
1 | using System.ComponentModel.DataAnnotations;
2 |
3 | namespace ByteartRetail.Web.MVC.Models
4 | {
5 | public class LoginModel
6 | {
7 | [Required]
8 | [Display(Name = "用户名")]
9 | public string UserName { get; set; }
10 |
11 | [Required]
12 | [DataType(DataType.Password)]
13 | [Display(Name = "密码")]
14 | public string Password { get; set; }
15 |
16 | [Display(Name = "记住密码?")]
17 | public bool RememberMe { get; set; }
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.CompilerServices;
3 | using System.Runtime.InteropServices;
4 |
5 | // General Information about an assembly is controlled through the following
6 | // set of attributes. Change these attribute values to modify the information
7 | // associated with an assembly.
8 | [assembly: AssemblyTitle("ByteartRetail.Web.MVC")]
9 | [assembly: AssemblyDescription("")]
10 | [assembly: AssemblyConfiguration("")]
11 | [assembly: AssemblyCompany("")]
12 | [assembly: AssemblyProduct("ByteartRetail.Web.MVC")]
13 | [assembly: AssemblyCopyright("Copyright © 2013")]
14 | [assembly: AssemblyTrademark("")]
15 | [assembly: AssemblyCulture("")]
16 |
17 | // Setting ComVisible to false makes the types in this assembly not visible
18 | // to COM components. If you need to access a type in this assembly from
19 | // COM, set the ComVisible attribute to true on that type.
20 | [assembly: ComVisible(false)]
21 |
22 | // The following GUID is for the ID of the typelib if this project is exposed to COM
23 | [assembly: Guid("6420ad6f-0d63-48d4-bfac-2f574c2a95e7")]
24 |
25 | // Version information for an assembly consists of the following four values:
26 | //
27 | // Major Version
28 | // Minor Version
29 | // Build Number
30 | // Revision
31 | //
32 | // You can specify all the values or you can default the Revision and Build Numbers
33 | // by using the '*' as shown below:
34 | [assembly: AssemblyVersion("1.0.0.0")]
35 | [assembly: AssemblyFileVersion("1.0.0.0")]
36 |
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Scripts/_references.js:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/ByteartRetail_Apworks/edb5051085578866056ad32893b0a03877191911/ByteartRetail.Web.MVC/Scripts/_references.js
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Scripts/jquery.bgiframe.min.js:
--------------------------------------------------------------------------------
1 | /* Copyright (c) 2006 Brandon Aaron (http://brandonaaron.net)
2 | * Dual licensed under the MIT (http://www.opensource.org/licenses/mit-license.php)
3 | * and GPL (http://www.opensource.org/licenses/gpl-license.php) licenses.
4 | *
5 | * $LastChangedDate: 2007-06-19 20:25:28 -0500 (Tue, 19 Jun 2007) $
6 | * $Rev: 2111 $
7 | *
8 | * Version 2.1
9 | */
10 | (function($){$.fn.bgIframe=$.fn.bgiframe=function(s){if($.browser.msie&&parseInt($.browser.version)<=6){s=$.extend({top:'auto',left:'auto',width:'auto',height:'auto',opacity:true,src:'javascript:false;'},s||{});var prop=function(n){return n&&n.constructor==Number?n+'px':n;},html='';return this.each(function(){if($('> iframe.bgiframe',this).length==0)this.insertBefore(document.createElement(html),this.firstChild);});}return this;};if(!$.browser.version)$.browser.version=navigator.userAgent.toLowerCase().match(/.+(?:rv|it|ra|ie)[\/: ]([\d.]+)/)[1];})(jQuery);
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Scripts/jquery.unobtrusive-ajax.min.js:
--------------------------------------------------------------------------------
1 | /*
2 | ** Unobtrusive Ajax support library for jQuery
3 | ** Copyright (C) Microsoft Corporation. All rights reserved.
4 | */
5 | (function(a){var b="unobtrusiveAjaxClick",g="unobtrusiveValidation";function c(d,b){var a=window,c=(d||"").split(".");while(a&&c.length)a=a[c.shift()];if(typeof a==="function")return a;b.push(d);return Function.constructor.apply(null,b)}function d(a){return a==="GET"||a==="POST"}function f(b,a){!d(a)&&b.setRequestHeader("X-HTTP-Method-Override",a)}function h(c,b,e){var d;if(e.indexOf("application/x-javascript")!==-1)return;d=(c.getAttribute("data-ajax-mode")||"").toUpperCase();a(c.getAttribute("data-ajax-update")).each(function(f,c){var e;switch(d){case"BEFORE":e=c.firstChild;a("").html(b).contents().each(function(){c.insertBefore(this,e)});break;case"AFTER":a("").html(b).contents().each(function(){c.appendChild(this)});break;default:a(c).html(b)}})}function e(b,e){var j,k,g,i;j=b.getAttribute("data-ajax-confirm");if(j&&!window.confirm(j))return;k=a(b.getAttribute("data-ajax-loading"));i=b.getAttribute("data-ajax-loading-duration")||0;a.extend(e,{type:b.getAttribute("data-ajax-method")||undefined,url:b.getAttribute("data-ajax-url")||undefined,beforeSend:function(d){var a;f(d,g);a=c(b.getAttribute("data-ajax-begin"),["xhr"]).apply(this,arguments);a!==false&&k.show(i);return a},complete:function(){k.hide(i);c(b.getAttribute("data-ajax-complete"),["xhr","status"]).apply(this,arguments)},success:function(a,e,d){h(b,a,d.getResponseHeader("Content-Type")||"text/html");c(b.getAttribute("data-ajax-success"),["data","status","xhr"]).apply(this,arguments)},error:c(b.getAttribute("data-ajax-failure"),["xhr","status","error"])});e.data.push({name:"X-Requested-With",value:"XMLHttpRequest"});g=e.type.toUpperCase();if(!d(g)){e.type="POST";e.data.push({name:"X-HTTP-Method-Override",value:g})}a.ajax(e)}function i(c){var b=a(c).data(g);return!b||!b.validate||b.validate()}a("a[data-ajax=true]").live("click",function(a){a.preventDefault();e(this,{url:this.href,type:"GET",data:[]})});a("form[data-ajax=true] input[type=image]").live("click",function(c){var g=c.target.name,d=a(c.target),f=d.parents("form")[0],e=d.offset();a(f).data(b,[{name:g+".x",value:Math.round(c.pageX-e.left)},{name:g+".y",value:Math.round(c.pageY-e.top)}]);setTimeout(function(){a(f).removeData(b)},0)});a("form[data-ajax=true] :submit").live("click",function(c){var e=c.target.name,d=a(c.target).parents("form")[0];a(d).data(b,e?[{name:e,value:c.target.value}]:[]);setTimeout(function(){a(d).removeData(b)},0)});a("form[data-ajax=true]").live("submit",function(d){var c=a(this).data(b)||[];d.preventDefault();if(!i(this))return;e(this,{url:this.action,type:this.method||"GET",data:c.concat(a(this).serializeArray())})})})(jQuery);
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Views/Account/Login.cshtml:
--------------------------------------------------------------------------------
1 | @model ByteartRetail.Web.MVC.Models.LoginModel
2 |
3 | @{
4 | ViewBag.Title = "用户登录";
5 | }
6 |
7 |
8 | @ViewBag.Title
9 |
10 |
11 |
39 |
40 |
41 | @section scripts {
42 |
47 | }
48 |
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Views/Admin/AddCategory.cshtml:
--------------------------------------------------------------------------------
1 | @using ByteartRetail.DataObjects;
2 | @using ByteartRetail.Web.MVC
3 |
4 | @model CategoryDataObject
5 |
6 | @{
7 | ViewBag.Title = "添加商品分类";
8 | }
9 |
10 |
11 | @Html.Image("Category_32.png") @ViewBag.Title
12 |
13 |
14 | @using (Html.BeginForm("AddCategory", "Admin", FormMethod.Post, new { id = "AddCategoryForm" }))
15 | {
16 | @Html.ValidationSummary(true)
17 |
18 |
19 | @Html.LabelFor(model => model.Name)
20 |
21 |
22 | @Html.TextBoxFor(model => model.Name)
23 | @Html.ValidationMessageFor(model => model.Name)
24 |
25 |
26 |
27 | @Html.LabelFor(model => model.Description)
28 |
29 |
30 | @Html.EditorFor(model => model.Description)
31 | @Html.ValidationMessageFor(model => model.Description)
32 |
33 | }
34 |
35 |
36 | @Html.ImageSubmitButton("AddCategoryForm", Url.Content("~/Images/Save.png"), "保存", "保存更改")
37 |
38 | @Html.ImageActionLink(Url.Content("~/Images/Cancel.png"), "取消添加", "取消添加", "Categories", "Admin")
39 |
40 |
41 | @section scripts
42 | {
43 |
48 | }
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Views/Admin/AddRole.cshtml:
--------------------------------------------------------------------------------
1 | @using ByteartRetail.DataObjects;
2 | @using ByteartRetail.Web.MVC
3 |
4 | @model RoleDataObject
5 |
6 | @{
7 | ViewBag.Title = "添加账户角色";
8 | }
9 |
10 |
11 | @Html.Image("Role_32.png") @ViewBag.Title
12 |
13 |
14 | @using (Html.BeginForm("AddRole", "Admin", FormMethod.Post, new { id = "AddRoleForm" }))
15 | {
16 | @Html.ValidationSummary(true)
17 |
18 | @Html.LabelFor(model => model.Name)
19 |
20 |
21 | @Html.EditorFor(model => model.Name)
22 | @Html.ValidationMessageFor(model => model.Name)
23 |
24 |
25 |
26 | @Html.LabelFor(model => model.Description)
27 |
28 |
29 | @Html.EditorFor(model => model.Description)
30 | @Html.ValidationMessageFor(model => model.Description)
31 |
32 | }
33 |
34 |
35 | @Html.ImageSubmitButton("AddRoleForm", Url.Content("~/Images/Save.png"), "保存", "保存更改")
36 |
37 | @Html.ImageActionLink(Url.Content("~/Images/Cancel.png"), "取消编辑", "取消编辑", "Roles", "Admin")
38 |
39 |
40 | @section scripts
41 | {
42 |
47 | }
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Views/Admin/Administration.cshtml:
--------------------------------------------------------------------------------
1 | @using ByteartRetail.Web.MVC
2 |
3 | @{
4 | ViewBag.Title = "站点管理";
5 | }
6 |
7 |
8 | @Html.Image("Admin_32.png") @ViewBag.Title
9 | 欢迎使用管理系统。请使用菜单栏目选择管理任务,对系统进行管理和设置。
10 |
11 |
12 |
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Views/Admin/Categories.cshtml:
--------------------------------------------------------------------------------
1 | @using ByteartRetail.DataObjects;
2 | @using ByteartRetail.Web.MVC
3 |
4 | @model IEnumerable
5 |
6 | @{
7 | ViewBag.Title = "商品分类管理";
8 | }
9 |
10 |
11 | @Html.Image("Category_32.png") @ViewBag.Title
12 | 请使用下面的工具按钮对商品分类进行增添、编辑或删除的管理操作。单击商品分类的名称同样可以打开该分类的编辑页面。
13 |
14 |
15 |
16 | @if (Model.Count()>0) {
17 | var grid = new WebGrid(Model, defaultSort: "Name", selectionFieldName: "ID");
18 | @grid.GetHtml(tableStyle:"webgrid",
19 | headerStyle:"webgrid-header",
20 | footerStyle:"webgrid-footer",
21 | rowStyle:"webgrid-row",
22 | alternatingRowStyle:"webgrid-alternating-row",
23 | columns: grid.Columns(
24 | grid.Column(
25 | format: @@Html.ActionLink((string)item.Name, "EditCategory", "Admin", new {id = item.ID}, null),
26 | columnName: "Name",
27 | header: "名称",
28 | canSort: true),
29 | grid.Column(
30 | columnName: "Description",
31 | header: "描述",
32 | canSort: false),
33 | grid.Column(
34 | style: "webgrid-toolicon",
35 | format: @@Html.ImageActionLink(Url.Content("/Images/Edit.png"), "编辑", "EditCategory", "Admin", new {id = item.ID}),
36 | header: "",
37 | canSort: false),
38 | grid.Column(
39 | style: "webgrid-toolicon",
40 | format: @@Html.ImageActionLink(Url.Content("/Images/Delete.png"), "删除", "DeleteCategory", "Admin", new { id = item.ID }, new { onclick = "return confirm('是否确定删除所选商品分类?');" }),
41 | header: "",
42 | canSort: false)))
43 | }
44 |
45 | @Html.ImageActionLink(Url.Content("/Images/Add.png"), "添加", "添加商品分类", "AddCategory", "Admin")
46 |
47 |
48 |
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Views/Admin/EditCategory.cshtml:
--------------------------------------------------------------------------------
1 | @using ByteartRetail.Web.MVC;
2 | @using ByteartRetail.DataObjects;
3 |
4 | @model CategoryDataObject
5 |
6 | @{
7 | ViewBag.Title = "编辑商品分类";
8 | }
9 |
10 |
11 | @Html.Image("Category_32.png") @ViewBag.Title
12 |
13 |
14 | @using (Html.BeginForm("EditCategory", "Admin", FormMethod.Post, new { id="EditCategoryForm" }))
15 | {
16 | @Html.ValidationSummary(true)
17 |
18 | @Html.HiddenFor(model => model.ID)
19 |
20 |
21 | @Html.LabelFor(model => model.Name)
22 |
23 |
24 | @Html.EditorFor(model => model.Name)
25 | @Html.ValidationMessageFor(model => model.Name)
26 |
27 |
28 |
29 | @Html.LabelFor(model => model.Description)
30 |
31 |
32 | @Html.EditorFor(model => model.Description)
33 | @Html.ValidationMessageFor(model => model.Description)
34 |
35 | }
36 |
37 |
38 | @Html.ImageSubmitButton("EditCategoryForm", Url.Content("~/Images/Save.png"), "保存", "保存更改")
39 |
40 | @Html.ImageActionLink(Url.Content("~/Images/Cancel.png"), "取消编辑", "取消编辑", "Categories", "Admin")
41 |
42 |
43 | @section scripts
44 | {
45 |
50 | }
51 |
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Views/Admin/EditRole.cshtml:
--------------------------------------------------------------------------------
1 | @using ByteartRetail.Web.MVC;
2 | @using ByteartRetail.DataObjects;
3 |
4 | @model RoleDataObject
5 |
6 | @{
7 | ViewBag.Title = "编辑用户角色";
8 | }
9 |
10 |
11 | @Html.Image("Role_32.png") @ViewBag.Title
12 |
13 |
14 | @using (Html.BeginForm("EditRole", "Admin", FormMethod.Post, new { id = "EditRoleForm"}))
15 | {
16 | @Html.ValidationSummary(true)
17 |
18 | @Html.HiddenFor(model => model.ID)
19 |
20 |
21 | @Html.LabelFor(model => model.Name)
22 |
23 |
24 | @Html.EditorFor(model => model.Name)
25 | @Html.ValidationMessageFor(model => model.Name)
26 |
27 |
28 |
29 | @Html.LabelFor(model => model.Description)
30 |
31 |
32 | @Html.EditorFor(model => model.Description)
33 | @Html.ValidationMessageFor(model => model.Description)
34 |
35 | }
36 |
37 |
38 |
39 | @Html.ImageSubmitButton("EditRoleForm", Url.Content("~/Images/Save.png"), "保存", "保存更改")
40 |
41 | @Html.ImageActionLink(Url.Content("~/Images/Cancel.png"), "取消编辑", "取消编辑", "Roles", "Admin")
42 |
43 |
44 | @section scripts
45 | {
46 |
51 | }
52 |
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Views/Admin/Products.cshtml:
--------------------------------------------------------------------------------
1 | @using ByteartRetail.DataObjects;
2 | @using ByteartRetail.Web.MVC
3 |
4 | @model IEnumerable
5 |
6 | @{
7 | ViewBag.Title = "商品信息管理";
8 | }
9 |
10 |
11 | @Html.Image("Product_32.png") @ViewBag.Title
12 | 请使用下面的工具按钮对商品信息进行增添、编辑或删除的管理操作。单击商品名称同样可以打开该分类的编辑页面。
13 |
14 |
15 |
16 | @if (Model.Count() > 0)
17 | {
18 | var grid = new WebGrid(Model, defaultSort: "Name", selectionFieldName: "ID");
19 | @grid.GetHtml(tableStyle:"webgrid",
20 | headerStyle:"webgrid-header",
21 | footerStyle:"webgrid-footer",
22 | rowStyle:"webgrid-row",
23 | alternatingRowStyle:"webgrid-alternating-row",
24 | columns: grid.Columns(
25 | grid.Column(
26 | format: @@Html.ProductImage((string)item.ImageUrl, ImageSize.Small),
27 | style:"product-grid-image",
28 | canSort:false),
29 | grid.Column(
30 | format: @@Html.ActionLink((string)item.Name, "EditProduct", "Admin", new {id = item.ID}, null),
31 | columnName: "Name",
32 | header: "名称",
33 | style: "product-grid-name",
34 | canSort: true),
35 | grid.Column(
36 | columnName: "Description",
37 | header: "描述",
38 | style: "product-grid-description",
39 | canSort: false),
40 | grid.Column(
41 | columnName: "Category",
42 | format: (item) => item.Category == null ? Html.Encode("(未分类)") : item.Category.Name,
43 | header: "分类",
44 | style: "product-grid-category",
45 | canSort: true),
46 | grid.Column(
47 | columnName: "UnitPrice",
48 | format: @@string.Format("{0:c}", item.UnitPrice),
49 | header: "单价",
50 | style: "product-grid-unitprice",
51 | canSort: true),
52 | grid.Column(
53 | style: "webgrid-toolicon",
54 | format: @@Html.ImageActionLink(Url.Content("/Images/Edit.png"), "编辑", "EditProduct", "Admin", new {id = item.ID}),
55 | header: "",
56 | canSort: false),
57 | grid.Column(
58 | style: "webgrid-toolicon",
59 | format: @@Html.ImageActionLink(Url.Content("/Images/Delete.png"), "删除", "DeleteProduct", "Admin", new { id = item.ID }, new { onclick = "return confirm('是否确定删除所选商品?');" }),
60 | header: "",
61 | canSort: false)))
62 | }
63 |
64 | @Html.ImageActionLink(Url.Content("/Images/Add.png"), "添加", "添加商品", "AddProduct", "Admin")
65 |
66 |
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Views/Admin/Roles.cshtml:
--------------------------------------------------------------------------------
1 | @using ByteartRetail.DataObjects;
2 | @using ByteartRetail.Web.MVC
3 |
4 | @model IEnumerable
5 |
6 | @{
7 | ViewBag.Title = "用户角色管理";
8 | }
9 |
10 |
11 | @Html.Image("Role_32.png") @ViewBag.Title
12 | 请使用下面的工具按钮对用户角色进行增添、编辑或删除的管理操作。单击用户角色名同样可以打开该角色的编辑页面。
13 |
14 |
15 |
16 | @if (Model != null && Model.Count() > 0)
17 | {
18 | var grid = new WebGrid(Model, defaultSort: "Name", selectionFieldName: "ID");
19 | @grid.GetHtml(tableStyle:"webgrid",
20 | headerStyle:"webgrid-header",
21 | footerStyle:"webgrid-footer",
22 | rowStyle:"webgrid-row",
23 | alternatingRowStyle:"webgrid-alternating-row",
24 | columns: grid.Columns(
25 | grid.Column(
26 | format: @@Html.ActionLink((string)item.Name, "EditRole", "Admin", new {id = item.ID}, null),
27 | columnName: "Name",
28 | header: "角色名",
29 | canSort: true),
30 | grid.Column(
31 | columnName: "Description",
32 | header: "角色描述",
33 | canSort: false),
34 | grid.Column(
35 | style: "webgrid-toolicon",
36 | format: @@Html.ImageActionLink(Url.Content("/Images/Edit.png"), "编辑", "EditRole", "Admin", new {id = item.ID}),
37 | header: "",
38 | canSort: false),
39 | grid.Column(
40 | style: "webgrid-toolicon",
41 | format: @@Html.ImageActionLink(Url.Content("/Images/Delete.png"), "删除", "DeleteRole", "Admin", new { id = item.ID }, new { onclick = "return confirm('是否确定删除所选角色?');" }),
42 | header: "",
43 | canSort: false)))
44 | }
45 |
46 | @Html.ImageActionLink(Url.Content("/Images/Add.png"), "添加", "添加角色", "AddRole", "Admin")
47 |
48 |
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Views/Home/About.cshtml:
--------------------------------------------------------------------------------
1 | @{
2 | ViewBag.Title = "关于Byteart Retail项目";
3 | }
4 | Byteart Retail 项目简介
5 |
6 | Byteart Retail是一个基于.NET开发的企业级应用程序,目的在于演示领域驱动设计在.NET开发中的应用。
7 | Byteart Retail以在线零售为业务背景,从各个技术层面展示了.NET企业级应用程序的架构设计,希望它能够
8 | 给社区朋友带来一定的帮助。
9 |
10 | 当前版本号
11 |
12 | V3
13 |
14 | 版本更新历史
15 |
19 |
20 |
21 |
22 |
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Views/Home/Category.cshtml:
--------------------------------------------------------------------------------
1 | @{Html.RenderAction("ProductsPartial", "Layout", new { categoryID = ViewData["CategoryID"], fromIndexPage = ViewData["FromIndexPage"] });}
2 |
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Views/Home/Checkout.cshtml:
--------------------------------------------------------------------------------
1 | @using ByteartRetail.DataObjects;
2 | @using ByteartRetail.Web.MVC
3 |
4 | @model SalesOrderDataObject
5 |
6 | @{
7 | ViewBag.Title = "订单生成";
8 | }
9 |
10 |
11 |
@Html.Image("Success_32.png") 生成订单成功!
12 |
13 |
14 |
15 | 订单编号:
16 | |
17 |
18 | @Model.ID.ToUpper()
19 | |
20 |
21 |
22 |
23 | 收货地址:
24 | |
25 |
26 | @Model.CustomerAddressZip, @Model.CustomerAddressStreet
27 |
28 | @Model.CustomerAddressCity, @Model.CustomerAddressState, @Model.CustomerAddressCountry
29 | |
30 |
31 |
32 |
33 | 联系人:
34 | |
35 |
36 | @Model.CustomerContact
37 | |
38 |
39 |
40 |
41 | 联系电话:
42 | |
43 |
44 | @Model.CustomerPhone
45 | |
46 |
47 |
48 |
49 | 电子邮件:
50 | |
51 |
52 | @Model.CustomerEmail
53 | |
54 |
55 |
56 |
57 |
您可以 @Html.ActionLink("单击此处", "SalesOrder", "Home", new { id = Model.ID }, new { id = "blue1" }) 查看此订单的详细信息,或者 @Html.ActionLink("单击此处", "SalesOrders", "Home", null, new { id = "blue1" }) 查看所有订单。
58 |
59 |
请 @Html.ActionLink("单击此处", "Index", "Home", null, new { id = "blue1" }) 回到首页继续购物。
60 |
61 |
62 |
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Views/Home/Contact.cshtml:
--------------------------------------------------------------------------------
1 | @{
2 | ViewBag.Title = "Contact";
3 | }
4 |
5 | 联系方式
6 | 您可以通过以下方式联系Byteart Retail示例项目的作者。
7 |
8 |
9 | 新浪微博:@@daxnet
10 |
11 |
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Views/Home/Index.cshtml:
--------------------------------------------------------------------------------
1 | @{Html.RenderAction("FeaturedProductsPartial", "Layout");}
2 | @{Html.RenderAction("ProductsPartial", "Layout");}
3 |
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Views/Home/SalesOrders.cshtml:
--------------------------------------------------------------------------------
1 | @using ByteartRetail.Web.MVC;
2 | @using ByteartRetail.DataObjects;
3 |
4 |
5 | @model SalesOrderDataObjectList
6 |
7 | @{
8 | ViewBag.Title = "我的订单";
9 | }
10 |
11 |
12 | @Html.Image("SalesOrder_32.png") @ViewBag.Title
13 |
14 |
15 | @if (Model.Count > 0)
16 | {
17 | var grid = new WebGrid(Model, defaultSort: "DateCreated", canSort: false, selectionFieldName: "ID");
18 | @grid.GetHtml(tableStyle: "webgrid",
19 | headerStyle: "webgrid-header",
20 | footerStyle: "webgrid-footer",
21 | rowStyle: "webgrid-row",
22 | alternatingRowStyle: "webgrid-alternating-row",
23 | columns: grid.Columns(
24 | grid.Column(
25 | style: "webgrid-guid",
26 | format: @@Html.ActionLink((string)item.IDText.ToUpper(), "SalesOrder", "Home", new { id = item.ID }, new { title = item.ID }),
27 | columnName: "ID",
28 | header: "编号"),
29 | grid.Column(
30 | style: "webgrid-numeric",
31 | columnName: "TotalLines",
32 | header: "条目数"),
33 | grid.Column(
34 | style: "webgrid-numeric",
35 | columnName: "TotalAmount",
36 | header: "总金额"),
37 | grid.Column(
38 | style: "webgrid-datetime",
39 | columnName: "DateCreatedText",
40 | header: "创建日期"),
41 | grid.Column(
42 | style: "webgrid-datetime",
43 | columnName: "DateDispatchedText",
44 | header: "发货日期"),
45 | grid.Column(
46 | style: "webgrid-datetime",
47 | columnName: "DateDeliveredText",
48 | header: "收货日期"),
49 | grid.Column(
50 | style: "webgrid-center",
51 | columnName: "StatusText",
52 | header: "当前状态"),
53 | grid.Column(
54 | style: "webgrid-center",
55 | columnName: "Confirm",
56 | header: "确认收货",
57 | format: item => item.CanConfirm ? Html.ActionLink("确认收货", "Confirm", "Home", new { id = item.ID }, new { onclick = "return confirm('请确保您已经收到了货品,否则可能财物两空。是否继续?');" }) : MvcHtmlString.Create(" "))))
58 | }
59 | else
60 | {
61 |
62 | 没有任何订单信息。
63 |
64 | }
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Views/Home/SuccessPage.cshtml:
--------------------------------------------------------------------------------
1 | @using ByteartRetail.Web.MVC;
2 |
3 | @{
4 | ViewBag.Title = ViewBag.PageTitle;
5 | }
6 |
7 |
8 |
@Html.Image("Success_32.png") @ViewBag.PageTitle
9 |
页面将在 秒后返回,或直接单击 @Html.ActionLink("此处", (string)ViewBag.RetAction, (string)ViewBag.RetController) 返回。
10 |
11 |
12 | @section scripts
13 | {
14 |
30 | }
31 |
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Views/Shared/CategoriesPartial.cshtml:
--------------------------------------------------------------------------------
1 | @model ByteartRetail.DataObjects.CategoryDataObjectList
2 |
3 |
4 |
5 |
6 |
7 |  商品分类 
8 |
10 | @foreach(var item in Model)
11 | {
12 |
14 | }
15 | |
16 |
17 |
18 | |
19 |
20 |
21 |
22 |  |
23 |
24 |
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Views/Shared/Error.cshtml:
--------------------------------------------------------------------------------
1 | @model System.Web.Mvc.HandleErrorInfo
2 |
3 | @{
4 | ViewBag.Title = "Error";
5 | }
6 |
7 |
8 | @Model.Exception.Message
9 |
10 |
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Views/Shared/FeaturedProductsPartial.cshtml:
--------------------------------------------------------------------------------
1 | @using ByteartRetail.DataObjects;
2 | @model ProductDataObjectList
3 |
4 |
5 |
6 |
7 | 特色商品推荐 |
8 |
9 |
10 |
11 |
12 |
13 | |
14 |
15 |
16 |
17 | @for (int i = 0; i < Model.Count; i++)
18 | {
19 | var model = Model[i];
20 |
21 |
22 |
23 |
24 |
25 | @Html.Encode(model.Name) |
26 | if (i != Model.Count - 1)
27 | {
28 |
29 |
30 | |
31 | }
32 | }
33 |
34 |
35 | |
36 | |
37 |
38 |
39 | |
40 |
41 |
42 |
43 |  |
44 |
45 |
46 |
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Views/Shared/_LoginPartial.cshtml:
--------------------------------------------------------------------------------
1 | @using ByteartRetail.Web.MVC;
2 |
3 | @if (Request.IsAuthenticated) {
4 |
5 |
6 |
7 | @Html.Image("ShoppingCart.png")
8 | |
9 |
10 | 欢迎您,@User.Identity.Name
11 |
12 |
13 | @ViewBag.ShoppingCartItems个商品
14 |
15 | |
16 |
17 | @using(Html.BeginForm("LogOff", "Account", FormMethod.Post, new {id = "logoutForm"})){
18 | 退出
19 | }
20 | |
21 |
22 |
23 | } else {
24 | using (Html.BeginForm("LogIn", "Account", FormMethod.Post, new { id="loginForm" }))
25 | {
26 | @Html.AntiForgeryToken()
27 |
28 |
29 |
30 | 登录
31 | |
32 |
33 |
34 |
35 | }
36 | }
37 |
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Views/_ViewStart.cshtml:
--------------------------------------------------------------------------------
1 | @{
2 | Layout = "~/Views/Shared/_Layout.cshtml";
3 | }
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Web.Debug.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
17 |
18 |
29 |
30 |
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/Web.Release.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
17 |
18 |
19 |
30 |
31 |
--------------------------------------------------------------------------------
/ByteartRetail.Web.MVC/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | Byteart Retail(Apworks 框架演示版)
2 | =====================
3 |
4 | 集成了Apworks框架的Byteart Retail案例,所有核心组件都由Apworks框架提供。是展示Apworks框架的一个很好的案例。
5 |
6 | Byteart Retail案例原版地址:[https://github.com/daxnet/ByteartRetail](https://github.com/daxnet/ByteartRetail)
7 |
8 | Apworks框架地址:[https://github.com/daxnet/Apworks](https://github.com/daxnet/Apworks)
9 |
--------------------------------------------------------------------------------