mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-10-14 19:04:51 +08:00
Merge
--HG-- branch : 1.x
This commit is contained in:
@@ -1,4 +1,4 @@
|
|||||||
<parameters>
|
<parameters>
|
||||||
<!-- Prompts where to copy the content files and takes a web site path (such as "contoso.com/app") -->
|
<!-- Prompts where to copy the content files and takes a web site path (such as "contoso.com/app") -->
|
||||||
<parameter name="Application Path" description="Full site path where you would like to install your application (i.e., Default Web Site/orchard)" defaultValue="Default Web Site/orchard" tags="iisapp">
|
<parameter name="Application Path" description="Full site path where you would like to install your application (i.e., Default Web Site/orchard)" defaultValue="Default Web Site/orchard" tags="iisapp">
|
||||||
<parameterEntry type="ProviderPath" scope="iisapp" match="Orchard" />
|
<parameterEntry type="ProviderPath" scope="iisapp" match="Orchard" />
|
||||||
@@ -13,7 +13,7 @@
|
|||||||
<parameterEntry type="ProviderPath" scope="setAcl" match="Orchard/Media" />
|
<parameterEntry type="ProviderPath" scope="setAcl" match="Orchard/Media" />
|
||||||
</parameter>
|
</parameter>
|
||||||
|
|
||||||
<!-- Prompts for database server name, this is used in the connection string parameter later -->
|
<!-- Prompts for database server name, this is used in the connection string parameter later -->
|
||||||
<parameter name="Database Server" description="Location of your database server (i.e. server name, IP address, or server\instance)" defaultValue=".\SQLEXPRESS" tags="SQL, dbServer">
|
<parameter name="Database Server" description="Location of your database server (i.e. server name, IP address, or server\instance)" defaultValue=".\SQLEXPRESS" tags="SQL, dbServer">
|
||||||
</parameter>
|
</parameter>
|
||||||
|
|
||||||
@@ -22,13 +22,13 @@
|
|||||||
<parameterEntry type="TextFile" scope="install.sql" match="PlaceHolderForDb" />
|
<parameterEntry type="TextFile" scope="install.sql" match="PlaceHolderForDb" />
|
||||||
</parameter>
|
</parameter>
|
||||||
|
|
||||||
<!-- Prompts for the database username and fills it into the database scripts.
|
<!-- Prompts for the database username and fills it into the database scripts.
|
||||||
The SQL tag indicates it is a parameter required for SQL, the DbUsername tag indicates this is a Db username -->
|
The SQL tag indicates it is a parameter required for SQL, the DbUsername tag indicates this is a Db username -->
|
||||||
<parameter name="Database Username" description="User name to access you application database." defaultValue="orcharduser" tags="SQL, DbUsername">
|
<parameter name="Database Username" description="User name to access you application database." defaultValue="orcharduser" tags="SQL, DbUsername">
|
||||||
<parameterEntry type="TextFile" scope="install.sql" match="PlaceHolderForUser" />
|
<parameterEntry type="TextFile" scope="install.sql" match="PlaceHolderForUser" />
|
||||||
</parameter>
|
</parameter>
|
||||||
|
|
||||||
<!-- Prompts for the database password and fills it into the database scripts.
|
<!-- Prompts for the database password and fills it into the database scripts.
|
||||||
The SQL tag indicates it is a parameter required for SQL, the DbUserPassword tag indicates this is a Db password -->
|
The SQL tag indicates it is a parameter required for SQL, the DbUserPassword tag indicates this is a Db password -->
|
||||||
<parameter name="Database Password" description="Password for the Database Username." tags="New, Password, SQL, DbUserPassword">
|
<parameter name="Database Password" description="Password for the Database Username." tags="New, Password, SQL, DbUserPassword">
|
||||||
<parameterEntry type="TextFile" scope="install.sql" match="PlaceHolderForPassword" />
|
<parameterEntry type="TextFile" scope="install.sql" match="PlaceHolderForPassword" />
|
||||||
@@ -46,24 +46,18 @@
|
|||||||
<parameter name="Database Administrator Password" description="Password for the database administrator account." tags="New, Password, SQL, dbAdminPassword">
|
<parameter name="Database Administrator Password" description="Password for the database administrator account." tags="New, Password, SQL, dbAdminPassword">
|
||||||
</parameter>
|
</parameter>
|
||||||
|
|
||||||
<!-- This is the hidden admin connection string used to run the database scripts -->
|
<parameter name="Admin Connection String SqlServer"
|
||||||
<parameter name="Connection String" description="Automatically sets the connection string for the connection request." defaultValue="Server={Database Server};Database={Database Name};uid={Database Administrator};Pwd={Database Administrator Password};" tags="Hidden, SQL">
|
tags="SQLConnectionString, AdminConnectionString, Hidden, Validate" description="Automatically sets the connection string for the connection request."
|
||||||
<parameterEntry type="ProviderPath" scope="dbfullsql" match="install.sql" />
|
defaultValue="Data Source={Database Server};Initial Catalog={Database Name};User Id={Database Administrator};Password={Database Administrator Password}">
|
||||||
|
<parameterEntry type="ProviderPath" scope="dbfullsql" match="install.sql" />
|
||||||
</parameter>
|
</parameter>
|
||||||
|
|
||||||
<parameter name="Settings Data Provider for SQL" description="Orchard SQL Data Provider Setting" defaultValue="DataProvider: SqlServer" tags="Hidden, SQL">
|
<parameter name="Non-Admin Connection String SqlServer"
|
||||||
<parameterEntry kind="TextFile" scope="\\Settings\.txt$" match="DataProvider\s*:[^\r\n]*" />
|
tags="SQLConnectionString, UserConnectionString, Hidden" description="Automatically sets the connection string for the connection request."
|
||||||
</parameter>
|
defaultValue="Data Source={Database Server};Initial Catalog={Database Name};User Id={Database Username};Password={Database Password}">
|
||||||
|
</parameter>
|
||||||
<parameter name="Settings Data Connection String for SQL" description="Orchard SQL Data Connection String Setting" defaultValue="DataConnectionString: Server={Database Server};Database={Database Name};uid={Database Administrator};Pwd={Database Administrator Password};" tags="Hidden, SQL">
|
|
||||||
<parameterEntry kind="TextFile" scope="\\Settings\.txt$" match="DataConnectionString\s*:[^\r\n]*" />
|
<parameter name="Orchard Connection String" friendlyName="Orchard Connection String" description="Orchard SQL Data Connection String Setting" defaultValue="" tags="Sql, SqlCE, SingleLineConnectionString, Hidden">
|
||||||
</parameter>
|
<parameterEntry kind="TextFile" scope="\\Settings\.txt$" match="(?<=\s*DataConnectionString:\s+)[^\s].*[^\r\n]" />
|
||||||
|
</parameter>
|
||||||
<parameter name="Settings Data Provider for SQLCE" description="Orchard SQLCE Data Provider Setting" defaultValue="DataProvider: SqlCe" tags="Hidden, SQLCE, NoStore">
|
|
||||||
<parameterEntry kind="TextFile" scope="\\Settings\.txt$" match="DataProvider\s*:[^\r\n]*" />
|
|
||||||
</parameter>
|
|
||||||
|
|
||||||
<parameter name="Settings Data Connection String for SQLCE" description="Orchard SQLCE Data Connection String Setting" defaultValue="DataConnectionString: " tags="Hidden, SQLCE, NoStore">
|
|
||||||
<parameterEntry kind="TextFile" scope="\\Settings\.txt$" match="DataConnectionString\s*:[^\r\n]*" />
|
|
||||||
</parameter>
|
|
||||||
</parameters>
|
</parameters>
|
@@ -231,14 +231,14 @@ namespace Orchard.Tests.Modules.Indexing {
|
|||||||
_provider.Store("default", _provider.New(2).Add("body", "Renaud is also in the kitchen.").Analyze().Add("title", "A love affair").Analyze());
|
_provider.Store("default", _provider.New(2).Add("body", "Renaud is also in the kitchen.").Analyze().Add("title", "A love affair").Analyze());
|
||||||
_provider.Store("default", _provider.New(3).Add("body", "Bertrand is a little bit jealous.").Analyze().Add("title", "Soap opera").Analyze());
|
_provider.Store("default", _provider.New(3).Add("body", "Bertrand is a little bit jealous.").Analyze().Add("title", "Soap opera").Analyze());
|
||||||
|
|
||||||
Assert.That(_searchBuilder.Parse(new[] { "body" }, "kitchen").Count(), Is.EqualTo(2));
|
Assert.That(_searchBuilder.Parse(new[] { "body" }, "kitchen", false).Count(), Is.EqualTo(2));
|
||||||
Assert.That(_searchBuilder.Parse(new[] { "body" }, "kitchen bertrand").Count(), Is.EqualTo(3));
|
Assert.That(_searchBuilder.Parse(new[] { "body" }, "kitchen bertrand", false).Count(), Is.EqualTo(3));
|
||||||
Assert.That(_searchBuilder.Parse(new[] { "body" }, "kitchen +bertrand").Count(), Is.EqualTo(1));
|
Assert.That(_searchBuilder.Parse(new[] { "body" }, "kitchen +bertrand", false).Count(), Is.EqualTo(1));
|
||||||
Assert.That(_searchBuilder.Parse(new[] { "body" }, "+kitchen +bertrand").Count(), Is.EqualTo(0));
|
Assert.That(_searchBuilder.Parse(new[] { "body" }, "+kitchen +bertrand", false).Count(), Is.EqualTo(0));
|
||||||
Assert.That(_searchBuilder.Parse(new[] { "body" }, "kit").Count(), Is.EqualTo(0));
|
Assert.That(_searchBuilder.Parse(new[] { "body" }, "kit", false).Count(), Is.EqualTo(0));
|
||||||
Assert.That(_searchBuilder.Parse(new[] { "body" }, "kit*").Count(), Is.EqualTo(2));
|
Assert.That(_searchBuilder.Parse(new[] { "body" }, "kit*", false).Count(), Is.EqualTo(2));
|
||||||
Assert.That(_searchBuilder.Parse(new[] { "body", "title" }, "bradley love^3 soap").Count(), Is.EqualTo(3));
|
Assert.That(_searchBuilder.Parse(new[] { "body", "title" }, "bradley love^3 soap", false).Count(), Is.EqualTo(3));
|
||||||
Assert.That(_searchBuilder.Parse(new[] { "body", "title" }, "bradley love^3 soap").Search().First().ContentItemId, Is.EqualTo(2));
|
Assert.That(_searchBuilder.Parse(new[] { "body", "title" }, "bradley love^3 soap", false).Search().First().ContentItemId, Is.EqualTo(2));
|
||||||
}
|
}
|
||||||
|
|
||||||
[Test]
|
[Test]
|
||||||
@@ -308,6 +308,14 @@ namespace Orchard.Tests.Modules.Indexing {
|
|||||||
Assert.That(_searchBuilder.Parse("title", "home").WithField("culture", 1033).AsFilter().Count(), Is.EqualTo(1));
|
Assert.That(_searchBuilder.Parse("title", "home").WithField("culture", 1033).AsFilter().Count(), Is.EqualTo(1));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
[Test]
|
||||||
|
public void ParsedTextShouldBeEscapedByDefault() {
|
||||||
|
_provider.CreateIndex("default");
|
||||||
|
_provider.Store("default", _provider.New(1).Add("body", "foo.bar").Analyze());
|
||||||
|
|
||||||
|
Assert.That(_searchBuilder.Parse("body", "*@!woo*@!").Count(), Is.EqualTo(0));
|
||||||
|
}
|
||||||
|
|
||||||
[Test]
|
[Test]
|
||||||
public void FieldsCanContainMultipleValue() {
|
public void FieldsCanContainMultipleValue() {
|
||||||
_provider.CreateIndex("default");
|
_provider.CreateIndex("default");
|
||||||
|
@@ -203,7 +203,7 @@ namespace Lucene.Services {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public ISearchBuilder CreateSearchBuilder(string indexName) {
|
public ISearchBuilder CreateSearchBuilder(string indexName) {
|
||||||
return new LuceneSearchBuilder(GetDirectory(indexName));
|
return new LuceneSearchBuilder(GetDirectory(indexName)) { Logger = Logger };
|
||||||
}
|
}
|
||||||
|
|
||||||
private string GetSettingsFileName(string indexName) {
|
private string GetSettingsFileName(string indexName) {
|
||||||
|
@@ -48,11 +48,11 @@ namespace Lucene.Services {
|
|||||||
InitPendingClause();
|
InitPendingClause();
|
||||||
}
|
}
|
||||||
|
|
||||||
public ISearchBuilder Parse(string defaultField, string query) {
|
public ISearchBuilder Parse(string defaultField, string query, bool escape, bool mandatory) {
|
||||||
return Parse(new[] {defaultField}, query);
|
return Parse(new[] {defaultField}, query, escape, mandatory);
|
||||||
}
|
}
|
||||||
|
|
||||||
public ISearchBuilder Parse(string[] defaultFields, string query) {
|
public ISearchBuilder Parse(string[] defaultFields, string query, bool escape, bool mandatory) {
|
||||||
if ( defaultFields.Length == 0 ) {
|
if ( defaultFields.Length == 0 ) {
|
||||||
throw new ArgumentException("Default field can't be empty");
|
throw new ArgumentException("Default field can't be empty");
|
||||||
}
|
}
|
||||||
@@ -61,9 +61,13 @@ namespace Lucene.Services {
|
|||||||
throw new ArgumentException("Query can't be empty");
|
throw new ArgumentException("Query can't be empty");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (escape) {
|
||||||
|
query = QueryParser.Escape(query);
|
||||||
|
}
|
||||||
|
|
||||||
var analyzer = LuceneIndexProvider.CreateAnalyzer();
|
var analyzer = LuceneIndexProvider.CreateAnalyzer();
|
||||||
foreach ( var defaultField in defaultFields ) {
|
foreach ( var defaultField in defaultFields ) {
|
||||||
var clause = new BooleanClause(new QueryParser(LuceneIndexProvider.LuceneVersion, defaultField, analyzer).Parse(query), BooleanClause.Occur.SHOULD);
|
var clause = new BooleanClause(new QueryParser(LuceneIndexProvider.LuceneVersion, defaultField, analyzer).Parse(query), mandatory ? BooleanClause.Occur.MUST : BooleanClause.Occur.SHOULD);
|
||||||
_clauses.Add(clause);
|
_clauses.Add(clause);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -1,26 +0,0 @@
|
|||||||
<?xml version="1.0"?>
|
|
||||||
<configuration>
|
|
||||||
<appSettings>
|
|
||||||
<add key="webpages:Enabled" value="false" />
|
|
||||||
</appSettings>
|
|
||||||
<system.web>
|
|
||||||
<compilation targetFramework="4.0">
|
|
||||||
<assemblies>
|
|
||||||
<add assembly="System.Web.Mvc, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
|
|
||||||
</assemblies>
|
|
||||||
</compilation>
|
|
||||||
|
|
||||||
<pages controlRenderingCompatibilityVersion="3.5" clientIDMode="AutoID">
|
|
||||||
<namespaces>
|
|
||||||
<add namespace="System.Web.Mvc"/>
|
|
||||||
<add namespace="System.Web.Mvc.Ajax"/>
|
|
||||||
<add namespace="System.Web.Mvc.Html"/>
|
|
||||||
<add namespace="System.Web.Routing"/>
|
|
||||||
<add namespace="System.Linq"/>
|
|
||||||
<add namespace="System.Collections.Generic"/>
|
|
||||||
<add namespace="Orchard.Mvc.Html"/>
|
|
||||||
</namespaces>
|
|
||||||
</pages>
|
|
||||||
</system.web>
|
|
||||||
<system.web.extensions/>
|
|
||||||
</configuration>
|
|
@@ -9,7 +9,7 @@
|
|||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
|
|
||||||
// Original file name:
|
// Original file name:
|
||||||
// Generation date: 12/16/2010 1:21:46 AM
|
// Generation date: 1/10/2011 10:36:55 PM
|
||||||
namespace Orchard.Packaging.GalleryServer
|
namespace Orchard.Packaging.GalleryServer
|
||||||
{
|
{
|
||||||
|
|
||||||
@@ -128,17 +128,17 @@ namespace Orchard.Packaging.GalleryServer
|
|||||||
/// <param name="price">Initial value of Price.</param>
|
/// <param name="price">Initial value of Price.</param>
|
||||||
/// <param name="requireLicenseAcceptance">Initial value of RequireLicenseAcceptance.</param>
|
/// <param name="requireLicenseAcceptance">Initial value of RequireLicenseAcceptance.</param>
|
||||||
/// <param name="isLatestVersion">Initial value of IsLatestVersion.</param>
|
/// <param name="isLatestVersion">Initial value of IsLatestVersion.</param>
|
||||||
/// <param name="rating">Initial value of Rating.</param>
|
|
||||||
/// <param name="ratingsCount">Initial value of RatingsCount.</param>
|
|
||||||
/// <param name="downloadCount">Initial value of DownloadCount.</param>
|
|
||||||
/// <param name="versionRating">Initial value of VersionRating.</param>
|
/// <param name="versionRating">Initial value of VersionRating.</param>
|
||||||
/// <param name="versionRatingsCount">Initial value of VersionRatingsCount.</param>
|
/// <param name="versionRatingsCount">Initial value of VersionRatingsCount.</param>
|
||||||
/// <param name="versionDownloadCount">Initial value of VersionDownloadCount.</param>
|
/// <param name="versionDownloadCount">Initial value of VersionDownloadCount.</param>
|
||||||
/// <param name="created">Initial value of Created.</param>
|
/// <param name="created">Initial value of Created.</param>
|
||||||
/// <param name="lastUpdated">Initial value of LastUpdated.</param>
|
/// <param name="lastUpdated">Initial value of LastUpdated.</param>
|
||||||
/// <param name="published">Initial value of Published.</param>
|
/// <param name="published">Initial value of Published.</param>
|
||||||
|
/// <param name="rating">Initial value of Rating.</param>
|
||||||
|
/// <param name="ratingsCount">Initial value of RatingsCount.</param>
|
||||||
|
/// <param name="downloadCount">Initial value of DownloadCount.</param>
|
||||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Services.Design", "1.0.0")]
|
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Services.Design", "1.0.0")]
|
||||||
public static PublishedPackage CreatePublishedPackage(string ID, string version, long packageSize, decimal price, bool requireLicenseAcceptance, bool isLatestVersion, double rating, int ratingsCount, int downloadCount, double versionRating, int versionRatingsCount, int versionDownloadCount, global::System.DateTime created, global::System.DateTime lastUpdated, global::System.DateTime published)
|
public static PublishedPackage CreatePublishedPackage(string ID, string version, long packageSize, decimal price, bool requireLicenseAcceptance, bool isLatestVersion, double versionRating, int versionRatingsCount, int versionDownloadCount, global::System.DateTime created, global::System.DateTime lastUpdated, global::System.DateTime published, double rating, int ratingsCount, int downloadCount)
|
||||||
{
|
{
|
||||||
PublishedPackage publishedPackage = new PublishedPackage();
|
PublishedPackage publishedPackage = new PublishedPackage();
|
||||||
publishedPackage.Id = ID;
|
publishedPackage.Id = ID;
|
||||||
@@ -147,15 +147,15 @@ namespace Orchard.Packaging.GalleryServer
|
|||||||
publishedPackage.Price = price;
|
publishedPackage.Price = price;
|
||||||
publishedPackage.RequireLicenseAcceptance = requireLicenseAcceptance;
|
publishedPackage.RequireLicenseAcceptance = requireLicenseAcceptance;
|
||||||
publishedPackage.IsLatestVersion = isLatestVersion;
|
publishedPackage.IsLatestVersion = isLatestVersion;
|
||||||
publishedPackage.Rating = rating;
|
|
||||||
publishedPackage.RatingsCount = ratingsCount;
|
|
||||||
publishedPackage.DownloadCount = downloadCount;
|
|
||||||
publishedPackage.VersionRating = versionRating;
|
publishedPackage.VersionRating = versionRating;
|
||||||
publishedPackage.VersionRatingsCount = versionRatingsCount;
|
publishedPackage.VersionRatingsCount = versionRatingsCount;
|
||||||
publishedPackage.VersionDownloadCount = versionDownloadCount;
|
publishedPackage.VersionDownloadCount = versionDownloadCount;
|
||||||
publishedPackage.Created = created;
|
publishedPackage.Created = created;
|
||||||
publishedPackage.LastUpdated = lastUpdated;
|
publishedPackage.LastUpdated = lastUpdated;
|
||||||
publishedPackage.Published = published;
|
publishedPackage.Published = published;
|
||||||
|
publishedPackage.Rating = rating;
|
||||||
|
publishedPackage.RatingsCount = ratingsCount;
|
||||||
|
publishedPackage.DownloadCount = downloadCount;
|
||||||
return publishedPackage;
|
return publishedPackage;
|
||||||
}
|
}
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@@ -453,69 +453,6 @@ namespace Orchard.Packaging.GalleryServer
|
|||||||
partial void OnIsLatestVersionChanging(bool value);
|
partial void OnIsLatestVersionChanging(bool value);
|
||||||
partial void OnIsLatestVersionChanged();
|
partial void OnIsLatestVersionChanged();
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// There are no comments for Property Rating in the schema.
|
|
||||||
/// </summary>
|
|
||||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Services.Design", "1.0.0")]
|
|
||||||
public double Rating
|
|
||||||
{
|
|
||||||
get
|
|
||||||
{
|
|
||||||
return this._Rating;
|
|
||||||
}
|
|
||||||
set
|
|
||||||
{
|
|
||||||
this.OnRatingChanging(value);
|
|
||||||
this._Rating = value;
|
|
||||||
this.OnRatingChanged();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Services.Design", "1.0.0")]
|
|
||||||
private double _Rating;
|
|
||||||
partial void OnRatingChanging(double value);
|
|
||||||
partial void OnRatingChanged();
|
|
||||||
/// <summary>
|
|
||||||
/// There are no comments for Property RatingsCount in the schema.
|
|
||||||
/// </summary>
|
|
||||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Services.Design", "1.0.0")]
|
|
||||||
public int RatingsCount
|
|
||||||
{
|
|
||||||
get
|
|
||||||
{
|
|
||||||
return this._RatingsCount;
|
|
||||||
}
|
|
||||||
set
|
|
||||||
{
|
|
||||||
this.OnRatingsCountChanging(value);
|
|
||||||
this._RatingsCount = value;
|
|
||||||
this.OnRatingsCountChanged();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Services.Design", "1.0.0")]
|
|
||||||
private int _RatingsCount;
|
|
||||||
partial void OnRatingsCountChanging(int value);
|
|
||||||
partial void OnRatingsCountChanged();
|
|
||||||
/// <summary>
|
|
||||||
/// There are no comments for Property DownloadCount in the schema.
|
|
||||||
/// </summary>
|
|
||||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Services.Design", "1.0.0")]
|
|
||||||
public int DownloadCount
|
|
||||||
{
|
|
||||||
get
|
|
||||||
{
|
|
||||||
return this._DownloadCount;
|
|
||||||
}
|
|
||||||
set
|
|
||||||
{
|
|
||||||
this.OnDownloadCountChanging(value);
|
|
||||||
this._DownloadCount = value;
|
|
||||||
this.OnDownloadCountChanged();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Services.Design", "1.0.0")]
|
|
||||||
private int _DownloadCount;
|
|
||||||
partial void OnDownloadCountChanging(int value);
|
|
||||||
partial void OnDownloadCountChanged();
|
|
||||||
/// <summary>
|
|
||||||
/// There are no comments for Property VersionRating in the schema.
|
/// There are no comments for Property VersionRating in the schema.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Services.Design", "1.0.0")]
|
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Services.Design", "1.0.0")]
|
||||||
@@ -726,26 +663,68 @@ namespace Orchard.Packaging.GalleryServer
|
|||||||
partial void OnIconUrlChanging(string value);
|
partial void OnIconUrlChanging(string value);
|
||||||
partial void OnIconUrlChanged();
|
partial void OnIconUrlChanged();
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// There are no comments for Property ReportAbuseUrl in the schema.
|
/// There are no comments for Property Rating in the schema.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Services.Design", "1.0.0")]
|
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Services.Design", "1.0.0")]
|
||||||
public string ReportAbuseUrl
|
public double Rating
|
||||||
{
|
{
|
||||||
get
|
get
|
||||||
{
|
{
|
||||||
return this._ReportAbuseUrl;
|
return this._Rating;
|
||||||
}
|
}
|
||||||
set
|
set
|
||||||
{
|
{
|
||||||
this.OnReportAbuseUrlChanging(value);
|
this.OnRatingChanging(value);
|
||||||
this._ReportAbuseUrl = value;
|
this._Rating = value;
|
||||||
this.OnReportAbuseUrlChanged();
|
this.OnRatingChanged();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Services.Design", "1.0.0")]
|
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Services.Design", "1.0.0")]
|
||||||
private string _ReportAbuseUrl;
|
private double _Rating;
|
||||||
partial void OnReportAbuseUrlChanging(string value);
|
partial void OnRatingChanging(double value);
|
||||||
partial void OnReportAbuseUrlChanged();
|
partial void OnRatingChanged();
|
||||||
|
/// <summary>
|
||||||
|
/// There are no comments for Property RatingsCount in the schema.
|
||||||
|
/// </summary>
|
||||||
|
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Services.Design", "1.0.0")]
|
||||||
|
public int RatingsCount
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
return this._RatingsCount;
|
||||||
|
}
|
||||||
|
set
|
||||||
|
{
|
||||||
|
this.OnRatingsCountChanging(value);
|
||||||
|
this._RatingsCount = value;
|
||||||
|
this.OnRatingsCountChanged();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Services.Design", "1.0.0")]
|
||||||
|
private int _RatingsCount;
|
||||||
|
partial void OnRatingsCountChanging(int value);
|
||||||
|
partial void OnRatingsCountChanged();
|
||||||
|
/// <summary>
|
||||||
|
/// There are no comments for Property DownloadCount in the schema.
|
||||||
|
/// </summary>
|
||||||
|
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Services.Design", "1.0.0")]
|
||||||
|
public int DownloadCount
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
return this._DownloadCount;
|
||||||
|
}
|
||||||
|
set
|
||||||
|
{
|
||||||
|
this.OnDownloadCountChanging(value);
|
||||||
|
this._DownloadCount = value;
|
||||||
|
this.OnDownloadCountChanged();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Services.Design", "1.0.0")]
|
||||||
|
private int _DownloadCount;
|
||||||
|
partial void OnDownloadCountChanging(int value);
|
||||||
|
partial void OnDownloadCountChanged();
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// There are no comments for Property Categories in the schema.
|
/// There are no comments for Property Categories in the schema.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@@ -810,6 +789,48 @@ namespace Orchard.Packaging.GalleryServer
|
|||||||
partial void OnDependenciesChanging(string value);
|
partial void OnDependenciesChanging(string value);
|
||||||
partial void OnDependenciesChanged();
|
partial void OnDependenciesChanged();
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
/// There are no comments for Property ReportAbuseUrl in the schema.
|
||||||
|
/// </summary>
|
||||||
|
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Services.Design", "1.0.0")]
|
||||||
|
public string ReportAbuseUrl
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
return this._ReportAbuseUrl;
|
||||||
|
}
|
||||||
|
set
|
||||||
|
{
|
||||||
|
this.OnReportAbuseUrlChanging(value);
|
||||||
|
this._ReportAbuseUrl = value;
|
||||||
|
this.OnReportAbuseUrlChanged();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Services.Design", "1.0.0")]
|
||||||
|
private string _ReportAbuseUrl;
|
||||||
|
partial void OnReportAbuseUrlChanging(string value);
|
||||||
|
partial void OnReportAbuseUrlChanged();
|
||||||
|
/// <summary>
|
||||||
|
/// There are no comments for Property GalleryDetailsUrl in the schema.
|
||||||
|
/// </summary>
|
||||||
|
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Services.Design", "1.0.0")]
|
||||||
|
public string GalleryDetailsUrl
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
return this._GalleryDetailsUrl;
|
||||||
|
}
|
||||||
|
set
|
||||||
|
{
|
||||||
|
this.OnGalleryDetailsUrlChanging(value);
|
||||||
|
this._GalleryDetailsUrl = value;
|
||||||
|
this.OnGalleryDetailsUrlChanged();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Services.Design", "1.0.0")]
|
||||||
|
private string _GalleryDetailsUrl;
|
||||||
|
partial void OnGalleryDetailsUrlChanging(string value);
|
||||||
|
partial void OnGalleryDetailsUrlChanged();
|
||||||
|
/// <summary>
|
||||||
/// There are no comments for Screenshots in the schema.
|
/// There are no comments for Screenshots in the schema.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Services.Design", "1.0.0")]
|
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Services.Design", "1.0.0")]
|
||||||
|
@@ -1,10 +1,10 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<ReferenceGroup xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" ID="bf634e7d-1d71-45cd-b4d8-f06f74cb7bc7" xmlns="urn:schemas-microsoft-com:xml-dataservicemap">
|
<ReferenceGroup xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" ID="680b6c18-74a9-42fd-978e-d9d9c1c396d2" xmlns="urn:schemas-microsoft-com:xml-dataservicemap">
|
||||||
<MetadataSources>
|
<MetadataSources>
|
||||||
<MetadataSource Address="http://orchardproject.net:777/GalleryServer/FeedService.svc/" Protocol="http" SourceId="1" />
|
<MetadataSource Address="http://orchardproject.net/gallery/server/FeedService.svc" Protocol="http" SourceId="1" />
|
||||||
</MetadataSources>
|
</MetadataSources>
|
||||||
<Metadata>
|
<Metadata>
|
||||||
<MetadataFile FileName="service.edmx" MetadataType="Edmx" ID="ed52956e-0709-4cc7-a9ba-74cca2274614" SourceId="1" SourceUrl="http://orchardproject.net:777/GalleryServer/FeedService.svc/" />
|
<MetadataFile FileName="service.edmx" MetadataType="Edmx" ID="0ee65dc8-3919-409c-a84e-c78cc88d0597" SourceId="1" SourceUrl="http://orchardproject.net/gallery/server/FeedService.svc" />
|
||||||
</Metadata>
|
</Metadata>
|
||||||
<Extensions />
|
<Extensions />
|
||||||
</ReferenceGroup>
|
</ReferenceGroup>
|
@@ -8,10 +8,10 @@
|
|||||||
</Key>
|
</Key>
|
||||||
<Property Name="Id" Type="Edm.String" Nullable="false" />
|
<Property Name="Id" Type="Edm.String" Nullable="false" />
|
||||||
<Property Name="Version" Type="Edm.String" Nullable="false" />
|
<Property Name="Version" Type="Edm.String" Nullable="false" />
|
||||||
<Property Name="Title" Type="Edm.String" Nullable="true" m:FC_TargetPath="SyndicationTitle" m:FC_ContentKind="text" m:FC_KeepInContent="true" />
|
<Property Name="Title" Type="Edm.String" Nullable="true" />
|
||||||
<Property Name="Authors" Type="Edm.String" Nullable="true" m:FC_TargetPath="SyndicationAuthorName" m:FC_ContentKind="text" m:FC_KeepInContent="true" />
|
<Property Name="Authors" Type="Edm.String" Nullable="true" />
|
||||||
<Property Name="PackageType" Type="Edm.String" Nullable="true" />
|
<Property Name="PackageType" Type="Edm.String" Nullable="true" />
|
||||||
<Property Name="Summary" Type="Edm.String" Nullable="true" m:FC_TargetPath="SyndicationSummary" m:FC_ContentKind="text" m:FC_KeepInContent="true" />
|
<Property Name="Summary" Type="Edm.String" Nullable="true" />
|
||||||
<Property Name="Description" Type="Edm.String" Nullable="true" />
|
<Property Name="Description" Type="Edm.String" Nullable="true" />
|
||||||
<Property Name="Copyright" Type="Edm.String" Nullable="true" />
|
<Property Name="Copyright" Type="Edm.String" Nullable="true" />
|
||||||
<Property Name="PackageHashAlgorithm" Type="Edm.String" Nullable="true" />
|
<Property Name="PackageHashAlgorithm" Type="Edm.String" Nullable="true" />
|
||||||
@@ -20,24 +20,25 @@
|
|||||||
<Property Name="Price" Type="Edm.Decimal" Nullable="false" />
|
<Property Name="Price" Type="Edm.Decimal" Nullable="false" />
|
||||||
<Property Name="RequireLicenseAcceptance" Type="Edm.Boolean" Nullable="false" />
|
<Property Name="RequireLicenseAcceptance" Type="Edm.Boolean" Nullable="false" />
|
||||||
<Property Name="IsLatestVersion" Type="Edm.Boolean" Nullable="false" />
|
<Property Name="IsLatestVersion" Type="Edm.Boolean" Nullable="false" />
|
||||||
<Property Name="Rating" Type="Edm.Double" Nullable="false" />
|
|
||||||
<Property Name="RatingsCount" Type="Edm.Int32" Nullable="false" />
|
|
||||||
<Property Name="DownloadCount" Type="Edm.Int32" Nullable="false" />
|
|
||||||
<Property Name="VersionRating" Type="Edm.Double" Nullable="false" />
|
<Property Name="VersionRating" Type="Edm.Double" Nullable="false" />
|
||||||
<Property Name="VersionRatingsCount" Type="Edm.Int32" Nullable="false" />
|
<Property Name="VersionRatingsCount" Type="Edm.Int32" Nullable="false" />
|
||||||
<Property Name="VersionDownloadCount" Type="Edm.Int32" Nullable="false" />
|
<Property Name="VersionDownloadCount" Type="Edm.Int32" Nullable="false" />
|
||||||
<Property Name="Created" Type="Edm.DateTime" Nullable="false" />
|
<Property Name="Created" Type="Edm.DateTime" Nullable="false" />
|
||||||
<Property Name="LastUpdated" Type="Edm.DateTime" Nullable="false" m:FC_TargetPath="SyndicationUpdated" m:FC_ContentKind="text" m:FC_KeepInContent="true" />
|
<Property Name="LastUpdated" Type="Edm.DateTime" Nullable="false" />
|
||||||
<Property Name="Published" Type="Edm.DateTime" Nullable="false" />
|
<Property Name="Published" Type="Edm.DateTime" Nullable="false" />
|
||||||
<Property Name="ExternalPackageUrl" Type="Edm.String" Nullable="true" />
|
<Property Name="ExternalPackageUrl" Type="Edm.String" Nullable="true" />
|
||||||
<Property Name="ProjectUrl" Type="Edm.String" Nullable="true" />
|
<Property Name="ProjectUrl" Type="Edm.String" Nullable="true" />
|
||||||
<Property Name="LicenseUrl" Type="Edm.String" Nullable="true" />
|
<Property Name="LicenseUrl" Type="Edm.String" Nullable="true" />
|
||||||
<Property Name="IconUrl" Type="Edm.String" Nullable="true" />
|
<Property Name="IconUrl" Type="Edm.String" Nullable="true" />
|
||||||
<Property Name="ReportAbuseUrl" Type="Edm.String" Nullable="true" />
|
<Property Name="Rating" Type="Edm.Double" Nullable="false" />
|
||||||
|
<Property Name="RatingsCount" Type="Edm.Int32" Nullable="false" />
|
||||||
|
<Property Name="DownloadCount" Type="Edm.Int32" Nullable="false" />
|
||||||
<NavigationProperty Name="Screenshots" Relationship="Gallery.Infrastructure.FeedModels.PublishedPackage_Screenshots" FromRole="PublishedPackage" ToRole="Screenshots" />
|
<NavigationProperty Name="Screenshots" Relationship="Gallery.Infrastructure.FeedModels.PublishedPackage_Screenshots" FromRole="PublishedPackage" ToRole="Screenshots" />
|
||||||
<Property Name="Categories" Type="Edm.String" Nullable="true" />
|
<Property Name="Categories" Type="Edm.String" Nullable="true" />
|
||||||
<Property Name="Tags" Type="Edm.String" Nullable="true" />
|
<Property Name="Tags" Type="Edm.String" Nullable="true" />
|
||||||
<Property Name="Dependencies" Type="Edm.String" Nullable="true" />
|
<Property Name="Dependencies" Type="Edm.String" Nullable="true" />
|
||||||
|
<Property Name="ReportAbuseUrl" Type="Edm.String" Nullable="true" />
|
||||||
|
<Property Name="GalleryDetailsUrl" Type="Edm.String" Nullable="true" />
|
||||||
</EntityType>
|
</EntityType>
|
||||||
<EntityType Name="PublishedScreenshot">
|
<EntityType Name="PublishedScreenshot">
|
||||||
<Key>
|
<Key>
|
||||||
|
@@ -9,6 +9,7 @@ namespace Orchard.Packaging.Services {
|
|||||||
public string Version { get; set; }
|
public string Version { get; set; }
|
||||||
public string PackageStreamUri { get; set; }
|
public string PackageStreamUri { get; set; }
|
||||||
public string ProjectUrl { get; set; }
|
public string ProjectUrl { get; set; }
|
||||||
|
public string GalleryDetailsUrl { get; set; }
|
||||||
public DateTime LastUpdated { get; set; }
|
public DateTime LastUpdated { get; set; }
|
||||||
public string Authors { get; set; }
|
public string Authors { get; set; }
|
||||||
public string Description { get; set; }
|
public string Description { get; set; }
|
||||||
|
@@ -83,6 +83,7 @@ namespace Orchard.Packaging.Services {
|
|||||||
PackageId = package.Id,
|
PackageId = package.Id,
|
||||||
PackageStreamUri = downloadUri.ToString(),
|
PackageStreamUri = downloadUri.ToString(),
|
||||||
ProjectUrl = package.ProjectUrl,
|
ProjectUrl = package.ProjectUrl,
|
||||||
|
GalleryDetailsUrl = package.GalleryDetailsUrl,
|
||||||
Source = source,
|
Source = source,
|
||||||
Version = package.Version ?? string.Empty,
|
Version = package.Version ?? string.Empty,
|
||||||
Description = package.Description,
|
Description = package.Description,
|
||||||
|
@@ -31,7 +31,32 @@
|
|||||||
|
|
||||||
<div class="iconThumbnail">
|
<div class="iconThumbnail">
|
||||||
<div class="extensionDetails column">
|
<div class="extensionDetails column">
|
||||||
<div class="extensionName">
|
<div class="extensionName">
|
||||||
|
@if (!string.IsNullOrWhiteSpace(item.GalleryDetailsUrl)) {
|
||||||
|
<a href="@item.GalleryDetailsUrl">
|
||||||
|
<h2>@item.Title<span> - @T("Version: {0}", item.Version)</span></h2>
|
||||||
|
</a>
|
||||||
|
} else {
|
||||||
|
<h2>@item.Title<span> - @T("Version: {0}", item.Version)</span></h2>
|
||||||
|
}
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="related">
|
||||||
|
@Html.ActionLink(T("Install").ToString(), "Install", new RouteValueDictionary { { "packageId", item.PackageId }, { "version", item.Version }, { "sourceId", item.Source.Id }, { "redirectTo", "Modules" } })@T(" | ")
|
||||||
|
<a href="@item.PackageStreamUri">@T("Download")</a>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="properties">
|
||||||
|
<p>@(item.Description == null ? T("(No description").Text : item.Description)</p>
|
||||||
|
<ul class="pageStatus">
|
||||||
|
<li>@T("Last Updated: {0}", DateTime.Now.ToLocalTime())</li>
|
||||||
|
<li> | @T("Author: {0}", !string.IsNullOrEmpty(item.Authors) ? item.Authors : T("Unknown").ToString())</li>
|
||||||
|
<li> | @T("Rating: {0}", item.Rating)</li>
|
||||||
|
<li> | @T("Ratings Count: {0}", item.RatingsCount)</li>
|
||||||
|
<li> | @T("Website: ")
|
||||||
|
@if (!string.IsNullOrEmpty(item.ProjectUrl)) { <a href="@item.ProjectUrl">@item.ProjectUrl</a> } else { @T("Unknown").ToString() }
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
@@ -38,7 +38,13 @@
|
|||||||
<div class="@extensionClass">
|
<div class="@extensionClass">
|
||||||
<div class="extensionDetails column">
|
<div class="extensionDetails column">
|
||||||
<div class="extensionName">
|
<div class="extensionName">
|
||||||
<h2>@item.Title<span> - @T("Version: {0}", item.Version)</span></h2>
|
@if (!string.IsNullOrWhiteSpace(item.GalleryDetailsUrl)) {
|
||||||
|
<a href="@item.GalleryDetailsUrl">
|
||||||
|
<h2>@item.Title<span> - @T("Version: {0}", item.Version)</span></h2>
|
||||||
|
</a>
|
||||||
|
} else {
|
||||||
|
<h2>@item.Title<span> - @T("Version: {0}", item.Version)</span></h2>
|
||||||
|
}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="related">
|
<div class="related">
|
||||||
|
@@ -27,14 +27,6 @@ namespace Orchard.Setup.Controllers {
|
|||||||
public Localizer T { get; set; }
|
public Localizer T { get; set; }
|
||||||
|
|
||||||
private ActionResult IndexViewResult(SetupViewModel model) {
|
private ActionResult IndexViewResult(SetupViewModel model) {
|
||||||
string message;
|
|
||||||
if (!CanWriteToAppDataFolder(out message)) {
|
|
||||||
_notifier.Error(
|
|
||||||
T(
|
|
||||||
"Hey, it looks like I can't write to the App_Data folder in the root of this application and that's where I need to save some of the information you're about to enter.\r\n\r\nPlease give me (the machine account this application is running under) write access to App_Data so I can get this app all set up for you.\r\n\r\nThanks!\r\n\r\n----\r\n{0}",
|
|
||||||
message));
|
|
||||||
}
|
|
||||||
|
|
||||||
return View(model);
|
return View(model);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -105,19 +97,5 @@ namespace Orchard.Setup.Controllers {
|
|||||||
return IndexViewResult(model);
|
return IndexViewResult(model);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
bool CanWriteToAppDataFolder(out string message) {
|
|
||||||
try {
|
|
||||||
_appDataFolder.CreateFile("_systemcheck.txt", "Communicator check one two one two");
|
|
||||||
_appDataFolder.DeleteFile("_systemcheck.txt");
|
|
||||||
|
|
||||||
message = "";
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
catch (Exception ex) {
|
|
||||||
message = ex.Message.Replace("_systemcheck.txt", "");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -3,8 +3,8 @@ using System.Collections.Generic;
|
|||||||
|
|
||||||
namespace Orchard.Indexing {
|
namespace Orchard.Indexing {
|
||||||
public interface ISearchBuilder {
|
public interface ISearchBuilder {
|
||||||
ISearchBuilder Parse(string defaultField, string query);
|
ISearchBuilder Parse(string defaultField, string query, bool escape = true, bool mandatory = false);
|
||||||
ISearchBuilder Parse(string[] defaultFields, string query);
|
ISearchBuilder Parse(string[] defaultFields, string query, bool escape = true, bool mandatory = false);
|
||||||
|
|
||||||
ISearchBuilder WithField(string field, bool value);
|
ISearchBuilder WithField(string field, bool value);
|
||||||
ISearchBuilder WithField(string field, DateTime value);
|
ISearchBuilder WithField(string field, DateTime value);
|
||||||
|
@@ -4,11 +4,11 @@ using System.Linq;
|
|||||||
|
|
||||||
namespace Orchard.Indexing {
|
namespace Orchard.Indexing {
|
||||||
public class NullSearchBuilder : ISearchBuilder {
|
public class NullSearchBuilder : ISearchBuilder {
|
||||||
public ISearchBuilder Parse(string defaultField, string query) {
|
public ISearchBuilder Parse(string defaultField, string query, bool escape, bool mandatory) {
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
public ISearchBuilder Parse(string[] defaultFields, string query) {
|
public ISearchBuilder Parse(string[] defaultFields, string query, bool escape, bool mandatory) {
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user