-
Notifications
You must be signed in to change notification settings - Fork 107
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- new tree selector widget - support for "version published" content in C1 Package system - fix: adding new language and selecting 'give access to all users' will include access to all groups also
- Loading branch information
Showing
26 changed files
with
648 additions
and
62 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
param ( | ||
[string]$cleanupTargetName, | ||
[string]$cleanupDirectory | ||
) | ||
|
||
Write-Host "ReleaseCleanup script started..." | ||
# This script deletes/rename files according to rules in ReleaseCleanupConfiguration.xml - it is used by automated builds | ||
|
||
if(-not($cleanupTargetName)) { Throw "You must supply a value for -cleanupTargetName - matching a target name in ReleaseCleanupConfiguration.xml" } | ||
if(-not($cleanupDirectory)) { Throw "You must supply a value for -cleanupDirectory - this is the path where cleaning will be taking place" } | ||
|
||
$scriptPath = split-path -parent $MyInvocation.MyCommand.Definition | ||
[xml]$xml = Get-Content (Join-Path $scriptPath "ReleaseCleanupConfiguration.xml") | ||
|
||
$targetItems = $xml.SelectNodes("/Configuration/Target[@name='" + $cleanupTargetName + "']/*/*[@path]") | ||
|
||
Foreach ($fileNode in $targetItems) { | ||
$relPath = $fileNode.Attributes["path"].Value | ||
$fullPath = Join-Path $cleanupDirectory $relPath | ||
|
||
if (($fileNode.Attributes["rename-find"]) -and ($fileNode.Attributes["rename-replace"]) ) { | ||
# if rename | ||
Write-Host "Handling $fullPath for renaming" | ||
|
||
$findString = $fileNode.Attributes["rename-find"].Value.Replace("\","/") | ||
$replaceString = $fileNode.Attributes["rename-replace"].Value | ||
|
||
$matches = Get-ChildItem -Path $fullPath -Recurse | ||
|
||
if ($matches.length -eq 0) { Write-Warning "Pattern matched 0 files - probably you should remove it from ReleaseCleanupConfiguration.xml in repo" } | ||
|
||
Foreach ($match in $matches) { | ||
$name = $match.FullName.Replace("\","/") | ||
$newName = $name.Replace($findString.Replace("\","/"), $replaceString) | ||
|
||
#ensure dir | ||
$newDirPath = Split-Path -Path $newName | ||
if (-not (Test-Path($newDirPath))) { New-Item -ItemType Directory -Force -Path $newDirPath } | ||
Move-Item $match -Destination $newName -Force | ||
} | ||
} | ||
else { | ||
# assume delete otherwise | ||
Write-Host "Handling $fullPath for deletion" | ||
|
||
if (($fileNode.Name -eq "Directory") -and (Test-Path $fullPath)) { | ||
Remove-Item -LiteralPath $fullPath -Force -Recurse | ||
} else { | ||
$matches = Get-ChildItem -Path $fullPath -Recurse | ||
|
||
if ($matches.length -eq 0) { Write-Warning "Pattern matched 0 files - probably you should remove it from ReleaseCleanupConfiguration.xml in repo" } | ||
|
||
$matches | Where-Object { Test-Path($_) } | Remove-Item -Force -Recurse | ||
} | ||
} | ||
} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
<?xml version="1.0" encoding="utf-8" ?> | ||
<Configuration> | ||
<Target name="prejavascriptcompile"> | ||
<CleanupOperations> | ||
<!-- operations are done in sequence --> | ||
<Directory path="/obj" /> | ||
<Directory path="/test" /> | ||
<Directory path="/Composite/content/dialogs/tests" /> | ||
<Directory path="/Composite/content/views/dev/developer/tests" /> | ||
<Directory path="/Composite/content/views/search" /> | ||
<Directory path="/Composite/extensions" /> | ||
<File path="/App_Data/Composite/ReleaseBuild.Composite.config.changeHistory.txt" /> | ||
<File path="*.bat" /> | ||
<File path="DebugBuild.*" /> | ||
<File path="*.csproj*" /> | ||
<File path="/bin/*.pdb" /> | ||
<File path="/bin/Composite.xml" rename-find=".xml" rename-replace=".xml.yolo" /> | ||
<File path="/bin/*.xml" /> | ||
<File path="/bin/Composite.xml.yolo" rename-find=".xml.yolo" rename-replace=".xml" /> | ||
</CleanupOperations> | ||
</Target> | ||
|
||
<Target name="postjavascriptcompile"> | ||
<CleanupOperations> | ||
<Directory path="/Composite/scripts/source" /> | ||
<Directory path="/Composite/applets" /> | ||
<Directory path="/Composite/Images/Icons/svg" /> | ||
<Directory path="/Composite/Styles/default" /> | ||
<Directory path="/bower_components" /> | ||
<Directory path="/jspm_packages" /> | ||
<Directory path="/node_modules" /> | ||
<File path="/bower.json" /> | ||
<File path="/gruntfile.js" /> | ||
<File path="/package.json" /> | ||
<File path="/jspm.config.js" /> | ||
<File path="/package-lock.json" /> | ||
<File path="/packages.config" /> | ||
<File path="/Composite/Styles/styles.less" /> | ||
<File path="/Composite/console/index.prod.html" rename-find="console/index.prod.html" rename-replace="console.index.prod.html" /> | ||
<Directory path="/Composite/console" /> | ||
<File path="/Composite/console.index.prod.html" rename-find="console.index.prod.html" rename-replace="console/index.html" /> | ||
<File path=".*" /> | ||
<File path="ReleaseBuild.*" rename-find="ReleaseBuild." rename-replace="" /> | ||
<File path="/ReleaseCleanupConfiguration.xml" /> | ||
</CleanupOperations> | ||
</Target> | ||
</Configuration> |
32 changes: 32 additions & 0 deletions
32
Composite/C1Console/Forms/CoreUiControls/TreeSelectorUiControl.cs
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using Composite.C1Console.Forms.Foundation; | ||
|
||
namespace Composite.C1Console.Forms.CoreUiControls | ||
{ | ||
[ControlValueProperty("SelectedKeys")] | ||
internal abstract class TreeSelectorUiControl : UiControl | ||
{ | ||
[BindableProperty] | ||
[FormsProperty] | ||
public string SelectedKey { get; set; } | ||
|
||
[FormsProperty] | ||
public string ElementProvider { get; set; } | ||
|
||
[FormsProperty] | ||
public string SelectableElementPropertyName { get; set; } | ||
|
||
[FormsProperty] | ||
public string SelectableElementPropertyValue { get; set; } | ||
|
||
[FormsProperty] | ||
public string SelectableElementReturnValue { get; set; } | ||
|
||
[FormsProperty] | ||
public string SerializedSearchToken { get; set; } | ||
|
||
[FormsProperty] | ||
public bool Required { get; set; } | ||
} | ||
} |
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.