minor updates

This commit is contained in:
2020-10-09 15:26:26 +02:00
parent 5bbf4c86de
commit d99bc00396
8 changed files with 78 additions and 18 deletions
+1 -2
View File
@@ -270,5 +270,4 @@ Temp/
**/Assets/setup.*
**/Assets/*.js
deps/*.dll
zero.Commerce/
Hofbauer.To.Zero/
commerce/
+1 -12
View File
@@ -281,18 +281,7 @@ namespace zero.Core.Api
/// <inheritdoc />
public async Task<EntityResult<T>> Purge<T>(string querySuffix = null, Parameters parameters = null)
{
var collectionName = Raven.Conventions.FindCollectionName(typeof(T));
var operationQuery = new DeleteByQueryOperation(new IndexQuery()
{
Query = $"from {collectionName} c {querySuffix ?? String.Empty}",
QueryParameters = parameters
});
Operation operation = await Raven.Operations.SendAsync(operationQuery);
await operation.WaitForCompletionAsync(TimeSpan.FromSeconds(30));
await Raven.PurgeAsync<T>(querySuffix, parameters);
return EntityResult<T>.Success();
}
}
@@ -1,6 +1,9 @@
using Raven.Client.Documents;
using Raven.Client;
using Raven.Client.Documents;
using Raven.Client.Documents.Conventions;
using Raven.Client.Documents.Operations;
using Raven.Client.Documents.Operations.CompareExchange;
using Raven.Client.Documents.Queries;
using Raven.Client.Json.Serialization.NewtonsoftJson;
using System;
using System.Linq;
@@ -143,5 +146,22 @@ namespace zero.Core.Extensions
CompareExchangeResult<string> result = await store.Operations.SendAsync(operation).ConfigureAwait(false);
return result.Successful;
}
/// <inheritdoc />
public static async Task PurgeAsync<T>(this IDocumentStore store, string querySuffix = null, Parameters parameters = null)
{
var collectionName = store.Conventions.FindCollectionName(typeof(T));
var operationQuery = new DeleteByQueryOperation(new IndexQuery()
{
Query = $"from {collectionName} c {querySuffix ?? String.Empty}",
QueryParameters = parameters
});
Operation operation = await store.Operations.SendAsync(operationQuery);
await operation.WaitForCompletionAsync(TimeSpan.FromSeconds(30));
}
}
}
+1 -1
View File
@@ -5,7 +5,7 @@
</PropertyGroup>
<ItemGroup>
<ProjectReference Include="..\zero.Commerce\zero.Commerce.csproj" />
<ProjectReference Include="..\commerce\zero.Commerce\zero.Commerce.csproj" />
<ProjectReference Include="..\zero.Core\zero.Core.csproj" />
<ProjectReference Include="..\zero.Web\zero.Web.csproj" />
</ItemGroup>
@@ -1,6 +1,7 @@
<template>
<div class="ui-add-button">
<ui-button v-if="!hasDropdown" :type="type" :label="label" @click="onClick(shared)" :disabled="disabled" />
<ui-button v-if="!hasDropdown" :type="type" :label="label" @click="onClick(shared)" :disabled="disabled" /> <!-- :attach="true"-->
<!--<ui-button v-if="!hasDropdown" :type="type" icon="fth-chevron-down" />-->
<ui-dropdown v-else ref="dropdown" align="right">
<template v-slot:button>
<ui-button :label="label" :type="type" :disabled="disabled" />
@@ -90,6 +91,10 @@
</script>
<style lang="scss">
.ui-add-button
{
display: flex;
}
/*.ui-add-button .ui-dropdown-button
{
font-weight: 700;
@@ -54,6 +54,10 @@
ellipsis: {
type: Boolean,
default: false
},
attach: {
type: Boolean,
default: false
}
},
@@ -94,6 +98,10 @@
{
classes.push('no-label');
}
if (this.attach)
{
classes.push('is-attached');
}
return classes;
},
+20
View File
@@ -115,6 +115,26 @@ button::-moz-focus-inner
margin-left: 15px;
}
&.is-attached
{
border-top-right-radius: 0;
border-bottom-right-radius: 0;
& + .ui-button
{
border-top-left-radius: 0;
border-bottom-left-radius: 0;
margin-left: -1px;
border-left: 1px solid rgba(0,0,0,0.1);
padding: 0 9px 0 8px;
.ui-button-icon
{
margin: 0 !important;
}
}
}
.ui-button-icon, .ui-button-caret
{
margin-left: 18px;
+20 -1
View File
@@ -5,7 +5,7 @@ VisualStudioVersion = 16.0.29709.97
MinimumVisualStudioVersion = 10.0.40219.1
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "zero.Core", "zero.Core\zero.Core.csproj", "{7BFF3DDE-F910-4CE1-9B94-846059CE80DA}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "zero.Commerce", "zero.Commerce\zero.Commerce.csproj", "{63A8AD15-15F0-4555-BD62-C38B4465FFC1}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "zero.Commerce", "commerce\zero.Commerce\zero.Commerce.csproj", "{63A8AD15-15F0-4555-BD62-C38B4465FFC1}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "zero.Debug", "zero.Debug\zero.Debug.csproj", "{83473041-7A1B-40ED-9FD0-968B22EB36B3}"
EndProject
@@ -39,6 +39,12 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "build", "build", "{1CE271AD
build\build.ps1 = build\build.ps1
EndProjectSection
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "commerce", "commerce", "{1CC446F8-A670-4EB1-87D3-C41F0D14603F}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "zero.Commerce.Depots.Providers.Bits", "commerce\zero.Commerce.Depots.Providers.Bits\zero.Commerce.Depots.Providers.Bits.csproj", "{A7FC3CAC-658E-424A-A23E-70159C65B696}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "zero.Commerce.Payment.Providers.Adyen", "commerce\zero.Commerce.Payment.Providers.Adyen\zero.Commerce.Payment.Providers.Adyen.csproj", "{B9281DC6-1691-4FBD-93DA-DC6059DEAC2F}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
@@ -65,10 +71,23 @@ Global
{8CE1A69A-35DB-4748-AE1C-86F5BC2E11D4}.Debug|Any CPU.Build.0 = Debug|Any CPU
{8CE1A69A-35DB-4748-AE1C-86F5BC2E11D4}.Release|Any CPU.ActiveCfg = Debug|Any CPU
{8CE1A69A-35DB-4748-AE1C-86F5BC2E11D4}.Release|Any CPU.Build.0 = Debug|Any CPU
{A7FC3CAC-658E-424A-A23E-70159C65B696}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{A7FC3CAC-658E-424A-A23E-70159C65B696}.Debug|Any CPU.Build.0 = Debug|Any CPU
{A7FC3CAC-658E-424A-A23E-70159C65B696}.Release|Any CPU.ActiveCfg = Release|Any CPU
{A7FC3CAC-658E-424A-A23E-70159C65B696}.Release|Any CPU.Build.0 = Release|Any CPU
{B9281DC6-1691-4FBD-93DA-DC6059DEAC2F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{B9281DC6-1691-4FBD-93DA-DC6059DEAC2F}.Debug|Any CPU.Build.0 = Debug|Any CPU
{B9281DC6-1691-4FBD-93DA-DC6059DEAC2F}.Release|Any CPU.ActiveCfg = Release|Any CPU
{B9281DC6-1691-4FBD-93DA-DC6059DEAC2F}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(NestedProjects) = preSolution
{63A8AD15-15F0-4555-BD62-C38B4465FFC1} = {1CC446F8-A670-4EB1-87D3-C41F0D14603F}
{A7FC3CAC-658E-424A-A23E-70159C65B696} = {1CC446F8-A670-4EB1-87D3-C41F0D14603F}
{B9281DC6-1691-4FBD-93DA-DC6059DEAC2F} = {1CC446F8-A670-4EB1-87D3-C41F0D14603F}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {AD3F31B9-8BBB-4334-9571-F556B9E632C9}
EndGlobalSection