orchardcms

What are the definitions of each of the Lifecycle Events in Orchard's CMS?

拥有回忆 提交于 2019-11-29 02:45:21
The documentation for content handlers in Orchard mentions Lifecycle Events ( http://docs.orchardproject.net/Documentation/Understanding-content-handlers ). Most events are self explanatory, but I was wondering if anybody can tell me the differences between OnActivated , OnInitializing , and OnLoading ? In firing order: OnActivated - content item object hierarchy has been created, but not yet fetched from db Used for preparing content part for further usage. Eg. setting getters and setters for lazy loaded objects, setting up delegates etc. Think of it as of a "constructor" for a given part.

Is Orchard or Umbraco MVC?

若如初见. 提交于 2019-11-28 10:52:08
I'm much happier with the quality of output I can get with MVC over webforms: hand crafted HTML that isn't full of additional machine generated gubbins (polite term). I realize of course that MVC is about a lot more than this, but concentrating on just that "view" part... I'm looking at Orchard or Umbraco for a project. I see both support Razor syntax (Umbraco just about) - but with my strong leaning to MVC Views rather than webforms, does that rule out Umbraco? All the Umbraco reading I've found so far is about the XSLT engine, as the razor syntax is brand new, which scares me :-) Orchard

How to skip displaying a content item in Orchard CMS?

半世苍凉 提交于 2019-11-28 10:27:20
问题 I have a content part that provides a begin timestamp and end timestamp option. These 2 fields are used to define a period of time in which the content item should be displayed. I now have difficulties to implement a skip approach whereas content items should not be displayed / skipped when the period of time does not span the current time. Digging in the source code and trying to find an entry point for my approach resulted in the following content handler public class SkipContentHandler :

Scheduled tasks using Orchard CMS

可紊 提交于 2019-11-28 01:59:31
问题 I need to create scheduled task using Orchard CMS. I have a service method (let's say it loads some data from external source), and I need to execute it everyday at 8:00 AM. I figured out I have to use IScheduledTaskHandler and IScheduledTaskManager... Does anyone know how to solve this problem? Some sample code will be appriciated. 回答1: In your IScheduledTaskHandler, you have to implement Process to provide your task implementation (I Advise you to put your implementation in another service

How to change Orchard record repository

谁说我不能喝 提交于 2019-11-27 08:08:10
I work on a project where we're considering using Orchard CMS . However, we want to use web services as data sources for some of the content items. I guess we have to change the repository implementation in order to make this possible, but I'm not sure about that. So my question is: Is my guess correct, or is it more complex? And how can it be done then? Thanks! Update: I see that Orchard's IRepository interface requires LINQ provider to be implemented. That's impossible in this scenario since the web services are offered via SOAP. I'll better further describe the scenario: The website we wish

Integrate existing ASP.NET MVC application with Orchard CMS

大兔子大兔子 提交于 2019-11-27 06:16:28
I have Orchard CMS and I want to integrate my MVC site with it. Can anybody tell me how to do this? It depends on how complex your MVC app is, but in most cases it is straighforward. The easiest way is to wrap your existing site into Orchard module. Writing a module is described here . These are the necessary steps: Copy your site to a subdirectory under ~/Orchard.Web/Modules along with the .csproj file so that the .csproj file should be in your application root (eg. ~/Orchard.Web/Modules/MyApplication/MyApplication.csproj) In the root of your app create a Module.txt manifest file. This small

How to change Orchard record repository

北战南征 提交于 2019-11-26 17:44:37
问题 I work on a project where we're considering using Orchard CMS. However, we want to use web services as data sources for some of the content items. I guess we have to change the repository implementation in order to make this possible, but I'm not sure about that. So my question is: Is my guess correct, or is it more complex? And how can it be done then? Thanks! Update: I see that Orchard's IRepository interface requires LINQ provider to be implemented. That's impossible in this scenario since

Integrate existing ASP.NET MVC application with Orchard CMS

空扰寡人 提交于 2019-11-26 11:56:09
问题 I have Orchard CMS and I want to integrate my MVC site with it. Can anybody tell me how to do this? 回答1: It depends on how complex your MVC app is, but in most cases it is straighforward. The easiest way is to wrap your existing site into Orchard module. Writing a module is described here. These are the necessary steps: Copy your site to a subdirectory under ~/Orchard.Web/Modules along with the .csproj file so that the .csproj file should be in your application root (eg. ~/Orchard.Web/Modules