mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-10-15 19:54:57 +08:00
Merge branch 'master' into 1.9.x
This commit is contained in:
Binary file not shown.
Binary file not shown.
@@ -561,6 +561,23 @@
|
|||||||
<Target Name="MvcBuildViews" AfterTargets="AfterBuild" Condition="'$(MvcBuildViews)'=='true'">
|
<Target Name="MvcBuildViews" AfterTargets="AfterBuild" Condition="'$(MvcBuildViews)'=='true'">
|
||||||
<AspNetCompiler VirtualPath="temp" PhysicalPath="$(WebProjectOutputDir)" />
|
<AspNetCompiler VirtualPath="temp" PhysicalPath="$(WebProjectOutputDir)" />
|
||||||
</Target>
|
</Target>
|
||||||
|
<Target Name="DeleteDebugFiles" AfterTargets="AfterBuild">
|
||||||
|
<RemoveDir Directories="Themes;Core;Modules" />
|
||||||
|
</Target>
|
||||||
|
<Target Name="CopyDebugFiles" AfterTargets="DeleteDebugFiles" Condition="'$(Configuration)' == 'Debug'">
|
||||||
|
<PropertyGroup>
|
||||||
|
<SrcFolder>..\..</SrcFolder>
|
||||||
|
</PropertyGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<Excluded Include="$(SrcFolder)\**\bin\**\*;$(SrcFolder)\**\obj\**\*;$(SrcFolder)\**\*.user;$(SrcFolder)\**\*.cs;$(SrcFolder)\**\*.csproj;$(SrcFolder)\**\.hg\**\*" />
|
||||||
|
<Src-Themes Include="$(SrcFolder)\Orchard.Web\Themes\**\*" Exclude="@(Excluded)" />
|
||||||
|
<Src-Core Include="$(SrcFolder)\Orchard.Web\Core\**\*" Exclude="@(Excluded)" />
|
||||||
|
<Src-Modules Include="$(SrcFolder)\Orchard.Web\Modules\**\*" Exclude="@(Excluded)" />
|
||||||
|
</ItemGroup>
|
||||||
|
<Copy SourceFiles="@(Src-Themes)" DestinationFolder="Themes\%(RecursiveDir)" />
|
||||||
|
<Copy SourceFiles="@(Src-Core)" DestinationFolder="Core\%(RecursiveDir)" />
|
||||||
|
<Copy SourceFiles="@(Src-Modules)" DestinationFolder="Modules\%(RecursiveDir)" />
|
||||||
|
</Target>
|
||||||
<ProjectExtensions>
|
<ProjectExtensions>
|
||||||
<VisualStudio>
|
<VisualStudio>
|
||||||
<FlavorProperties GUID="{349c5851-65df-11da-9384-00065b846f21}">
|
<FlavorProperties GUID="{349c5851-65df-11da-9384-00065b846f21}">
|
||||||
@@ -580,6 +597,11 @@
|
|||||||
</FlavorProperties>
|
</FlavorProperties>
|
||||||
</VisualStudio>
|
</VisualStudio>
|
||||||
</ProjectExtensions>
|
</ProjectExtensions>
|
||||||
|
<PropertyGroup>
|
||||||
|
<PreBuildEvent>del "$(TargetDir)\Modules"
|
||||||
|
del "$(TargetDir)\Themes"
|
||||||
|
del "$(TargetDir)\Media"</PreBuildEvent>
|
||||||
|
</PropertyGroup>
|
||||||
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
||||||
Other similar extension points exist, see Microsoft.Common.targets.
|
Other similar extension points exist, see Microsoft.Common.targets.
|
||||||
<Target Name="BeforeBuild">
|
<Target Name="BeforeBuild">
|
||||||
|
@@ -192,7 +192,7 @@
|
|||||||
</dependentAssembly>
|
</dependentAssembly>
|
||||||
<dependentAssembly>
|
<dependentAssembly>
|
||||||
<assemblyIdentity name="Microsoft.WindowsAzure.Storage" publicKeyToken="31bf3856ad364e35" culture="neutral"/>
|
<assemblyIdentity name="Microsoft.WindowsAzure.Storage" publicKeyToken="31bf3856ad364e35" culture="neutral"/>
|
||||||
<bindingRedirect oldVersion="0.0.0.0-5.0.0.0" newVersion="5.0.0.0"/>
|
<bindingRedirect oldVersion="0.0.0.0-5.0.2.0" newVersion="5.0.2.0"/>
|
||||||
</dependentAssembly>
|
</dependentAssembly>
|
||||||
<dependentAssembly>
|
<dependentAssembly>
|
||||||
<assemblyIdentity name="Microsoft.Data.Edm" publicKeyToken="31BF3856AD364E35" culture="neutral"/>
|
<assemblyIdentity name="Microsoft.Data.Edm" publicKeyToken="31BF3856AD364E35" culture="neutral"/>
|
||||||
|
@@ -203,7 +203,7 @@
|
|||||||
</dependentAssembly>
|
</dependentAssembly>
|
||||||
<dependentAssembly>
|
<dependentAssembly>
|
||||||
<assemblyIdentity name="Microsoft.WindowsAzure.Storage" publicKeyToken="31bf3856ad364e35" culture="neutral"/>
|
<assemblyIdentity name="Microsoft.WindowsAzure.Storage" publicKeyToken="31bf3856ad364e35" culture="neutral"/>
|
||||||
<bindingRedirect oldVersion="0.0.0.0-4.3.0.0" newVersion="4.3.0.0"/>
|
<bindingRedirect oldVersion="0.0.0.0-5.0.2.0" newVersion="5.0.2.0"/>
|
||||||
</dependentAssembly>
|
</dependentAssembly>
|
||||||
<dependentAssembly>
|
<dependentAssembly>
|
||||||
<assemblyIdentity name="Microsoft.Data.Edm" publicKeyToken="31BF3856AD364E35" culture="neutral"/>
|
<assemblyIdentity name="Microsoft.Data.Edm" publicKeyToken="31BF3856AD364E35" culture="neutral"/>
|
||||||
|
@@ -199,7 +199,7 @@
|
|||||||
</dependentAssembly>
|
</dependentAssembly>
|
||||||
<dependentAssembly>
|
<dependentAssembly>
|
||||||
<assemblyIdentity name="Microsoft.WindowsAzure.Storage" publicKeyToken="31bf3856ad364e35" culture="neutral"/>
|
<assemblyIdentity name="Microsoft.WindowsAzure.Storage" publicKeyToken="31bf3856ad364e35" culture="neutral"/>
|
||||||
<bindingRedirect oldVersion="0.0.0.0-4.3.0.0" newVersion="4.3.0.0"/>
|
<bindingRedirect oldVersion="0.0.0.0-5.0.2.0" newVersion="5.0.2.0"/>
|
||||||
</dependentAssembly>
|
</dependentAssembly>
|
||||||
<dependentAssembly>
|
<dependentAssembly>
|
||||||
<assemblyIdentity name="Microsoft.Data.Edm" publicKeyToken="31BF3856AD364E35" culture="neutral"/>
|
<assemblyIdentity name="Microsoft.Data.Edm" publicKeyToken="31BF3856AD364E35" culture="neutral"/>
|
||||||
|
@@ -73,7 +73,7 @@
|
|||||||
</dependentAssembly>
|
</dependentAssembly>
|
||||||
<dependentAssembly>
|
<dependentAssembly>
|
||||||
<assemblyIdentity name="Microsoft.WindowsAzure.Storage" publicKeyToken="31bf3856ad364e35" culture="neutral" />
|
<assemblyIdentity name="Microsoft.WindowsAzure.Storage" publicKeyToken="31bf3856ad364e35" culture="neutral" />
|
||||||
+ <bindingRedirect oldVersion="0.0.0.0-5.0.0.0" newVersion="5.0.0.0" />
|
<bindingRedirect oldVersion="0.0.0.0-5.0.2.0" newVersion="5.0.2.0"/>
|
||||||
</dependentAssembly>
|
</dependentAssembly>
|
||||||
</assemblyBinding>
|
</assemblyBinding>
|
||||||
</runtime>
|
</runtime>
|
||||||
|
@@ -355,7 +355,7 @@ namespace Orchard.Azure.Services.FileSystems {
|
|||||||
// as opposed to the File System implementation, if nothing is done on the stream
|
// as opposed to the File System implementation, if nothing is done on the stream
|
||||||
// the file will be emptied, because Azure doesn't implement FileMode.Truncate
|
// the file will be emptied, because Azure doesn't implement FileMode.Truncate
|
||||||
_blob.DeleteIfExists();
|
_blob.DeleteIfExists();
|
||||||
_blob = _blob.Container.GetBlockBlobReference(_blob.Uri.ToString());
|
_blob = _blob.Container.GetBlockBlobReference(_blob.Name);
|
||||||
_blob.UploadFromStream(new MemoryStream(new byte[0]));
|
_blob.UploadFromStream(new MemoryStream(new byte[0]));
|
||||||
return OpenWrite();
|
return OpenWrite();
|
||||||
}
|
}
|
||||||
|
@@ -237,7 +237,10 @@ namespace Orchard.Indexing.Services {
|
|||||||
// skip items from types which are not indexed
|
// skip items from types which are not indexed
|
||||||
var settings = GetTypeIndexingSettings(item.ContentItem);
|
var settings = GetTypeIndexingSettings(item.ContentItem);
|
||||||
if (settings.List.Contains(indexName)) {
|
if (settings.List.Contains(indexName)) {
|
||||||
documentIndex = ExtractDocumentIndex(item.ContentItem);
|
if (item.ContentItem.HasPublished()) {
|
||||||
|
var published = _contentManager.Get(item.Id, VersionOptions.Published);
|
||||||
|
documentIndex = ExtractDocumentIndex(published);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else if (settings.List.Contains(indexName + ":latest")) {
|
else if (settings.List.Contains(indexName + ":latest")) {
|
||||||
var latest = _contentManager.Get(item.Id, VersionOptions.Latest);
|
var latest = _contentManager.Get(item.Id, VersionOptions.Latest);
|
||||||
|
@@ -156,10 +156,10 @@ namespace Orchard.MediaLibrary.Controllers {
|
|||||||
if (!Services.Authorizer.Authorize(Permissions.ManageOwnMedia, T("Cannot view media")))
|
if (!Services.Authorizer.Authorize(Permissions.ManageOwnMedia, T("Cannot view media")))
|
||||||
return new HttpUnauthorizedResult();
|
return new HttpUnauthorizedResult();
|
||||||
|
|
||||||
var rootMediaFolder = _mediaLibraryService.GetRootMediaFolder().MediaPath;
|
var rootMediaFolder = _mediaLibraryService.GetRootMediaFolder();
|
||||||
|
var rootMediaFolderPath = rootMediaFolder == null ? null : rootMediaFolder.MediaPath;
|
||||||
var mediaParts = _mediaLibraryService.GetMediaContentItems(rootMediaFolder, skip, count, order, mediaType);
|
var mediaParts = _mediaLibraryService.GetMediaContentItems(rootMediaFolderPath, skip, count, order, mediaType);
|
||||||
var mediaPartsCount = _mediaLibraryService.GetMediaContentItemsCount(rootMediaFolder, mediaType);
|
var mediaPartsCount = _mediaLibraryService.GetMediaContentItemsCount(rootMediaFolderPath, mediaType);
|
||||||
|
|
||||||
|
|
||||||
var mediaItems = mediaParts.Select(x => new MediaManagerMediaItemViewModel {
|
var mediaItems = mediaParts.Select(x => new MediaManagerMediaItemViewModel {
|
||||||
|
@@ -31,7 +31,7 @@ namespace Orchard.MediaLibrary {
|
|||||||
},
|
},
|
||||||
new PermissionStereotype {
|
new PermissionStereotype {
|
||||||
Name = "Author",
|
Name = "Author",
|
||||||
Permissions = new[] {ManageMediaContent}
|
Permissions = new[] {ManageOwnMedia}
|
||||||
},
|
},
|
||||||
new PermissionStereotype {
|
new PermissionStereotype {
|
||||||
Name = "Contributor",
|
Name = "Contributor",
|
||||||
|
@@ -71,8 +71,11 @@ $(function () {
|
|||||||
|
|
||||||
var listWidth = $('#media-library-main-list').width();
|
var listWidth = $('#media-library-main-list').width();
|
||||||
var listHeight = $('#media-library-main-list').height();
|
var listHeight = $('#media-library-main-list').height();
|
||||||
var itemWidth = $('.thumbnail').first().width();
|
var itemWidth = $('#media-library-main-list li').first().width();
|
||||||
var itemHeight = $('.thumbnail').first().height();
|
var itemHeight = $('#media-library-main-list li').first().height();
|
||||||
|
var defaultDimension = $(window).width() < 1420 ? 120 : 200;
|
||||||
|
if (itemHeight == 0 || itemHeight == null) itemHeight = defaultDimension;
|
||||||
|
if (itemWidth == 0 || itemWidth == null) itemWidth = defaultDimension;
|
||||||
var draftText = $("#media-library").data("draft-text");
|
var draftText = $("#media-library").data("draft-text");
|
||||||
|
|
||||||
var itemsPerRow = Math.floor(listWidth / itemWidth);
|
var itemsPerRow = Math.floor(listWidth / itemWidth);
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
.zone-content, #content, #main, #layout-content, #layout-main {
|
.zone-content, #content, #main, #layout-content, #layout-main {
|
||||||
height: 100%;
|
height: 100%;
|
||||||
display: block;
|
display: block;
|
||||||
min-height: 400px;
|
min-height: 400px;
|
||||||
@@ -155,6 +155,10 @@
|
|||||||
background-position: center;
|
background-position: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#media-library-main-list.pending li {
|
||||||
|
opacity:.3;
|
||||||
|
}
|
||||||
|
|
||||||
/* Remove the space for the editor, and the scrollbar in the import page */
|
/* Remove the space for the editor, and the scrollbar in the import page */
|
||||||
#media-library-import #media-library-main-list {
|
#media-library-import #media-library-main-list {
|
||||||
overflow-y: hidden;
|
overflow-y: hidden;
|
||||||
|
@@ -69,10 +69,6 @@ namespace Orchard.Search {
|
|||||||
|
|
||||||
public int Create() {
|
public int Create() {
|
||||||
|
|
||||||
_indexManager.GetSearchIndexProvider().CreateIndex("Admin");
|
|
||||||
|
|
||||||
ContentDefinitionManager.AlterTypeDefinition("Page", cfg => cfg.WithSetting("TypeIndexing.Indexes", "Page:latest"));
|
|
||||||
|
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -185,7 +185,7 @@
|
|||||||
</dependentAssembly>
|
</dependentAssembly>
|
||||||
<dependentAssembly>
|
<dependentAssembly>
|
||||||
<assemblyIdentity name="Microsoft.WindowsAzure.Storage" publicKeyToken="31bf3856ad364e35" culture="neutral"/>
|
<assemblyIdentity name="Microsoft.WindowsAzure.Storage" publicKeyToken="31bf3856ad364e35" culture="neutral"/>
|
||||||
<bindingRedirect oldVersion="0.0.0.0-4.3.0.0" newVersion="4.3.0.0"/>
|
<bindingRedirect oldVersion="0.0.0.0-5.0.2.0" newVersion="5.0.2.0"/>
|
||||||
</dependentAssembly>
|
</dependentAssembly>
|
||||||
<dependentAssembly>
|
<dependentAssembly>
|
||||||
<assemblyIdentity name="Microsoft.Data.Edm" publicKeyToken="31BF3856AD364E35" culture="neutral"/>
|
<assemblyIdentity name="Microsoft.Data.Edm" publicKeyToken="31BF3856AD364E35" culture="neutral"/>
|
||||||
|
Reference in New Issue
Block a user