var publishedStateAssessor = ServiceLocator.Current.GetInstance<IPublishedStateAssessor>();
var isPublished = publishedStateAssessor.IsPublished(entryContent, PublishedStateCondition.None);
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using System.Web.Mvc; | |
| using EPiServer.DataAbstraction.RuntimeModel; | |
| using EPiServer.Framework; | |
| using EPiServer.Framework.Initialization; | |
| using EPiServer.ServiceLocation; | |
| using ModularAllowedTypes.Business.Rendering; | |
| using EPiServer.Web.Mvc; | |
| using EPiServer.Web.Mvc.Html; | |
| using StructureMap; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| namespace EPiServer.SocialAlloy.Web.Business.FindHelpers | |
| { | |
| using System; | |
| using System.Collections.Generic; | |
| using System.Linq; | |
| using System.Linq.Expressions; | |
| using System.Reflection; | |
| using EPiServer.Core; | |
| using EPiServer.Find; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public class FindExceptionInterceptor : IInterceptor | |
| { | |
| public void Intercept(IInvocation invocation) | |
| { | |
| try | |
| { | |
| invocation.Proceed(); | |
| } | |
| catch (ClientException) | |
| { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using System.Collections.Generic; | |
| using System.Linq; | |
| using EPiServer.Commerce.Catalog.ContentTypes; | |
| using EPiServer.Core; | |
| using EPiServer.Find; | |
| using EPiServer.Find.Cms; | |
| using EPiServer.PlugIn; | |
| using EPiServer.Scheduler; | |
| using EPiServer.ServiceLocation; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using System; | |
| using System.Collections.Generic; | |
| using System.Linq; | |
| using System.Web.Security. | |
| using Umbraco.Core.Services; | |
| using Umbraco.Web.Models; | |
| using Umbraco.Web.PublishedCache; | |
| /* | |
| * |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| DECLARE @SchemaName sysname, @TableName sysname, @IndexName sysname | |
| DECLARE @basesql nvarchar(max), @sql nvarchar(max) | |
| SET @basesql = 'ALTER INDEX @1 On @2 REBUILD WITH ( FILLFACTOR = 50 ) ' | |
| DECLARE IXC CURSOR FOR | |
| SELECT | |
| OBJECT_SCHEMA_NAME(i.object_id) As SchemaName | |
| , OBJECT_NAME(i.object_id) AS TableName | |
| , i.name AS IndexName |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| BEGIN | |
| set quoted_identifier on | |
| DECLARE @db varchar(max) = 'MyDB' | |
| DECLARE @today VARCHAR(9) = datename(w,sysdatetime()) | |
| DECLARE @tableName varchar(max) | |
| DECLARE @indexName varchar(max) | |
| DECLARE @sql Nvarchar(max) | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <system.codedom> | |
| <compilers> | |
| <compiler language="c#;cs;csharp" extension=".cshtml" compilerOptions="/nowarn:1702" type="Microsoft.CSharp.CSharpCodeProvider, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" warningLevel="4"> | |
| <providerOption name="CompilerVersion" value="v4.0" /> | |
| <providerOption name="WarnAsError" value="false" /> | |
| </compiler> | |
| </compilers> | |
| </system.codedom> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| let | |
| BaseUrl = "https://fake-odata-api.com/v1/Entities?", | |
| Token = "F4K3-T0K3N-D0NT-U5E-L0L", | |
| EntitiesPerPage = 1000, | |
| GetJson = (Url) => | |
| let Options = [Headers=[ #"Authorization" = "Bearer " & Token ]], | |
| RawData = Web.Contents(Url, Options), | |
| Json = Json.Document(RawData) | |
| in Json, |