Moving CommentDriver, HasCommentsContainerDriver and HasCommentsDriver from Models to Controllers

--HG--
branch : dev
This commit is contained in:
Andrew Ma
2010-02-23 20:54:19 -08:00
parent fe70317db1
commit 3a207d403a
6 changed files with 14 additions and 9 deletions

View File

@@ -1,14 +1,15 @@
using JetBrains.Annotations;
using Orchard.Comments.Models;
using Orchard.ContentManagement;
using Orchard.ContentManagement.Drivers;
namespace Orchard.Comments.Models {
namespace Orchard.Comments.Controlers {
[UsedImplicitly]
public class CommentDriver : ContentItemDriver<Comment> {
public readonly static ContentType ContentType = new ContentType {
Name = "comment",
DisplayName = "Comment"
};
Name = "comment",
DisplayName = "Comment"
};
protected override ContentType GetContentType() {
return ContentType;

View File

@@ -1,11 +1,12 @@
using System.Linq;
using JetBrains.Annotations;
using Orchard.Comments.Models;
using Orchard.Comments.ViewModels;
using Orchard.ContentManagement;
using Orchard.ContentManagement.Drivers;
using Orchard.Core.Common.Records;
namespace Orchard.Comments.Models {
namespace Orchard.Comments.Controllers {
[UsedImplicitly]
public class HasCommentsContainerDriver : ContentPartDriver<HasCommentsContainer> {
protected override DriverResult Display(HasCommentsContainer part, string displayType) {

View File

@@ -1,9 +1,10 @@
using JetBrains.Annotations;
using Orchard.Comments.Models;
using Orchard.Comments.ViewModels;
using Orchard.ContentManagement;
using Orchard.ContentManagement.Drivers;
namespace Orchard.Comments.Models {
namespace Orchard.Comments.Controllers {
[UsedImplicitly]
public class HasCommentsDriver : ContentPartDriver<HasComments> {
protected override DriverResult Display(HasComments part, string displayType) {

View File

@@ -1,4 +1,5 @@
using JetBrains.Annotations;
using Orchard.Comments.Controlers;
using Orchard.ContentManagement.Handlers;
using Orchard.Core.Common.Models;
using Orchard.Data;

View File

@@ -68,16 +68,16 @@
<Compile Include="AdminMenu.cs" />
<Compile Include="Controllers\AdminController.cs" />
<Compile Include="Controllers\CommentController.cs" />
<Compile Include="Controllers\CommentDriver.cs" />
<Compile Include="Controllers\HasCommentsContainerDriver.cs" />
<Compile Include="Controllers\HasCommentsDriver.cs" />
<Compile Include="Extensions\HtmlHelperExtensions.cs" />
<Compile Include="Models\ClosedCommentsRecord.cs" />
<Compile Include="Models\Comment.cs" />
<Compile Include="Models\CommentDriver.cs" />
<Compile Include="Models\CommentHandler.cs" />
<Compile Include="Models\CommentStatus.cs" />
<Compile Include="Models\HasCommentsContainer.cs" />
<Compile Include="Models\HasCommentsContainerDriver.cs" />
<Compile Include="Models\HasCommentsContainerHandler.cs" />
<Compile Include="Models\HasCommentsDriver.cs" />
<Compile Include="Feeds\CommentedOnContainerFeedQuery.cs" />
<Compile Include="Feeds\CommentedOnFeedQuery.cs" />
<Compile Include="Feeds\CommentFeedItemBuilder.cs" />

View File

@@ -2,6 +2,7 @@
using System.Linq;
using JetBrains.Annotations;
using Orchard.Comments.Models;
using Orchard.Comments.Controlers;
using Orchard.ContentManagement.Aspects;
using Orchard.Data;
using Orchard.Logging;