Skip to content
This repository has been archived by the owner on Jan 16, 2024. It is now read-only.

Commit

Permalink
v1.2.6.7
Browse files Browse the repository at this point in the history
   - An entity's concurrency token property is no longer a required parameter in its constructor (#24)
   - Simplified cascade delete settings in property editor for associations
   - Fixed bad code generation in EFCore for cascade delete overrides (#22)
   - Missing files when generating code for .NET Core projects fixed
   - Tightened up and swatted some bugs in INotifyPropertyChanged handling. Added documentation to doc site for this feature (following up on #23)
   - Ensured multiline editing was available in property window for those properties that made sense
  • Loading branch information
msawczyn committed Sep 24, 2018
1 parent 8895274 commit 80d2119
Show file tree
Hide file tree
Showing 18 changed files with 247 additions and 81 deletions.
16 changes: 14 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,15 +43,27 @@ You can read more about how to use the designer in the [Documentation site](http

### Change Log

***1.2.6.6***
***1.2.6.7***
- An entity's concurrency token property is no longer a required parameter in its constructor (https://github.com/msawczyn/EFDesigner/issues/24)
- Simplified cascade delete settings in property editor for associations
- Fixed bad code generation in EFCore for cascade delete overrides (https://github.com/msawczyn/EFDesigner/issues/22)
- Missing files when generating code for .NET Core projects fixed
- Tightened up and swatted some bugs in INotifyPropertyChanged handling. Added documentation to doc site for this feature (following up on https://github.com/msawczyn/EFDesigner/issues/23)
- Ensured multiline editing was available in property window for those properties that made sense

**1.2.6.6**
- Deleting a generalization or superclass gives the choice of pushing attributes and associations down to the former child class(es)

**1.2.6.5**
<details>
<summary><b>1.2.6.5</b></summary>

- Comment elements now wrap the text
- Multiline editor available in property window for element comment descriptions and Comment element text
- Xml format changed for .efmodel file - can't be loaded by any version < 1.2.6.3
- Support for automatic migration to new model xml formats

</details>

<details>
<summary><b>1.2.6.2</b></summary>

Expand Down
8 changes: 8 additions & 0 deletions VSMarketplace blurb.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,14 @@ For comprehensive documentation, please visit [the project's documentation site]

**ChangeLog**

**1.2.6.7**
- An entity's concurrency token property is no longer a required parameter in its constructor (https://github.com/msawczyn/EFDesigner/issues/24)
- Simplified cascade delete settings in property editor for associations
- Fixed bad code generation in EFCore for cascade delete overrides (https://github.com/msawczyn/EFDesigner/issues/22)
- Missing files when generating code for .NET Core projects fixed
- Tightened up and swatted some bugs in INotifyPropertyChanged handling. Added documentation to doc site for this feature (following up on https://github.com/msawczyn/EFDesigner/issues/23)
- Ensured multiline editing was available in property window for those properties that made sense

**1.2.6.6**
- Deleting a generalization or superclass gives the choice of pushing attributes and associations down to the former child class(es)

Expand Down
5 changes: 3 additions & 2 deletions changelog.txt
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
1.2.6.7
- An entity's concurrency token property is no longer a required parameter in its constructor (https://github.com/msawczyn/EFDesigner/issues/24)
- Simplified cascade delete settings in property editor for associations
- Fixed bad code generation in EFCore for cascade delete overrides
- Fixed bad code generation in EFCore for cascade delete overrides (https://github.com/msawczyn/EFDesigner/issues/22)
- Missing files when generating code for .NET Core projects fixed
- Tightened up and swatted some bugs in INotifyPropertyChanged handling. Added documentation to doc site for this feature
- Tightened up and swatted some bugs in INotifyPropertyChanged handling. Added documentation to doc site for this feature (following up on https://github.com/msawczyn/EFDesigner/issues/23)
- Ensured multiline editing was available in property window for those properties that made sense

1.2.6.6
- Deleting a generalization or superclass gives the choice of pushing attributes and associations down to the former child class(es)
Expand Down
Binary file modified dist/Sawczyn.EFDesigner.EFModel.DslPackage.vsix
Binary file not shown.
4 changes: 4 additions & 0 deletions docs/Associations.md
Original file line number Diff line number Diff line change
Expand Up @@ -110,5 +110,9 @@ Bidirectional associations have the following properties:
</tbody>
</table>

### Cascade delete

More to come on this.

### Next Step
[Inheritance](Inheritance)
4 changes: 4 additions & 0 deletions docs/Entities.md
Original file line number Diff line number Diff line change
Expand Up @@ -90,5 +90,9 @@ Right-clicking on an entity displays a Visual Studio context menu with some new
<tr><td valign="top"> Properties </td><td valign="top">Switches focus to the Properties window.</td></tr>
</table>

### INotifyPropertyChanged

More to come on this.

### Next Step
[Properties](Properties)
7 changes: 7 additions & 0 deletions docs/Using-the-designer.md
Original file line number Diff line number Diff line change
Expand Up @@ -156,6 +156,13 @@ documentation), you can generate the code in one of three ways:
- At any time, you can right click the design surface and choose `Generate Code` from the context menu
- As with any T4 file, you can always right click the `[Model Name].tt` file in your project and choose `Run Custom Tool` from the context menu

Note: if you haven't set up target project directories for your files, they'll be dropped in the same directory
that contains your .csproj file. Unfortunately, when that happens Visual Studio tries to be "helpful" and tucks them
under the `.tt` file in the Solution Explorer tree, so you may not realize that they've been created. It's best practice
to create a subdirectory for them and target the output there. Minimally setting the `Entity Output Directory`
property on the design surface will default all the other output directories, and you'll get visual confirmation in the
Solution Explorer tree when you generate your code files.

### Next Step
[Persistent entities](Entities)

Expand Down
2 changes: 2 additions & 0 deletions docs/_layouts/default.html
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,7 @@ <h2 class="project-tagline">{{ site.description | default: site.github.project_t
<li><a href="Entities.html#removing-an-entity">Removing an entity</a></li>
<li><a href="Entities.html#entity-properties">Entity properties</a></li>
<li><a href="Entities.html#context-menu">Context menu</a></li>
<li><a href="Entities.html#inotifypropertychanged">INotifyPropertyChanged</a></li>
</ul>
<a href="Properties.html">Properties</a>
<ul>
Expand All @@ -138,6 +139,7 @@ <h2 class="project-tagline">{{ site.description | default: site.github.project_t
<li><a href="Associations.html#cardinalities">Cardinalities</a></li>
<li><a href="Associations.html#unidirectional-associations">Unidirectional association properties</a></li>
<li><a href="Associations.html#bidirectional-associations">Bidirectional association properties</a></li>
<li><a href="Associations.html#cascade-delete">Cascade delete</a></li>
</ul>
<a href="Inheritance.html">Inheritance</a>
<ul>
Expand Down
8 changes: 8 additions & 0 deletions src/Dsl/CustomCode/Partials/ModelRoot.cs
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,14 @@ private void ConnectionStringMustExist(ValidationContext context)
context.LogError("Model: Entity container needs a name", "MREContainerNameEmpty", this);
}

[ValidationMethod(ValidationCategories.Open | ValidationCategories.Save | ValidationCategories.Menu)]
// ReSharper disable once UnusedMember.Local
private void SummaryDescriptionIsEmpty(ValidationContext context)
{
if (string.IsNullOrWhiteSpace(Summary) && WarnOnMissingDocumentation)
context.LogWarning($"Model: Summary documentation missing", "AWMissingSummary", this);
}

#endregion Validation methods

#region DatabaseSchema tracking property
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

using Microsoft.VisualStudio.Modeling;
using Microsoft.VisualStudio.Modeling.Design;

Expand All @@ -29,6 +27,19 @@ private PropertyDescriptorCollection GetCustomProperties(Attribute[] attributes)
{
storeDomainDataDirectory = association.Store.DomainDataDirectory;

// only display delete behavior on the principal end
if (association.SourceRole != EndpointRole.Principal)
{
PropertyDescriptor sourceDeleteActionTypeDescriptor = propertyDescriptors.OfType<PropertyDescriptor>().Single(x => x.Name == "SourceDeleteAction");
propertyDescriptors.Remove(sourceDeleteActionTypeDescriptor);
}

if (association.TargetRole != EndpointRole.Principal)
{
PropertyDescriptor targetDeleteActionTypeDescriptor = propertyDescriptors.OfType<PropertyDescriptor>().Single(x => x.Name == "TargetDeleteAction");
propertyDescriptors.Remove(targetDeleteActionTypeDescriptor);
}

/********************************************************************************/

DomainPropertyInfo collectionClassPropertyInfo = storeDomainDataDirectory.GetDomainProperty(Association.CollectionClassDomainPropertyId);
Expand Down
2 changes: 1 addition & 1 deletion src/Dsl/Dsl.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@
<Compile Include="CustomCode\Extensions\SyntaxNodeExtensions.cs" />
<Compile Include="CustomCode\Gestures\CompartmentDragMouseAction.cs" />
<Compile Include="CustomCode\Partials\AssociationConnector.cs" />
<Compile Include="CustomCode\Partials\AssociationTypeDescriptor.cs" />
<Compile Include="CustomCode\Type Descriptors\AssociationTypeDescriptor.cs" />
<Compile Include="CustomCode\Partials\BidirectionalAssociation.cs" />
<Compile Include="CustomCode\Connection Builders\BidirectionalAssociationBuilder.cs" />
<Compile Include="CustomCode\Partials\BidirectionalConnector.cs" />
Expand Down
98 changes: 97 additions & 1 deletion src/Dsl/DslDefinition.dsl
Original file line number Diff line number Diff line change
Expand Up @@ -211,11 +211,27 @@
</Type>
</DomainProperty>
<DomainProperty Id="a95a5645-b5d5-4b11-b177-d674cee91290" Description="Detailed code documentation" Name="Description" DisplayName="Comment Detail" DefaultValue="" Category="Documentation">
<Attributes>
<ClrAttribute Name="System.ComponentModel.Editor">
<Parameters>
<AttributeParameter Value="typeof(System.ComponentModel.Design.MultilineStringEditor)" />
<AttributeParameter Value="typeof(System.Drawing.Design.UITypeEditor)" />
</Parameters>
</ClrAttribute>
</Attributes>
<Type>
<ExternalTypeMoniker Name="/System/String" />
</Type>
</DomainProperty>
<DomainProperty Id="a25a2ffe-9ae9-408b-a346-056805de6975" Description="Brief code documentation" Name="Summary" DisplayName="Comment Summary" Category="Documentation">
<Attributes>
<ClrAttribute Name="System.ComponentModel.Editor">
<Parameters>
<AttributeParameter Value="typeof(System.ComponentModel.Design.MultilineStringEditor)" />
<AttributeParameter Value="typeof(System.Drawing.Design.UITypeEditor)" />
</Parameters>
</ClrAttribute>
</Attributes>
<Type>
<ExternalTypeMoniker Name="/System/String" />
</Type>
Expand Down Expand Up @@ -353,6 +369,14 @@
</Type>
</DomainProperty>
<DomainProperty Id="5ff45bb4-658f-412e-8cdc-2593d9ea3d37" Description="Brief code documentation" Name="Summary" DisplayName="Comment Summary" Category="Documentation">
<Attributes>
<ClrAttribute Name="System.ComponentModel.Editor">
<Parameters>
<AttributeParameter Value="typeof(System.ComponentModel.Design.MultilineStringEditor)" />
<AttributeParameter Value="typeof(System.Drawing.Design.UITypeEditor)" />
</Parameters>
</ClrAttribute>
</Attributes>
<Type>
<ExternalTypeMoniker Name="/System/String" />
</Type>
Expand Down Expand Up @@ -451,11 +475,27 @@
</Type>
</DomainProperty>
<DomainProperty Id="d974a312-57fe-42b3-b377-22fe01562356" Description="Detailed code documentation" Name="Description" DisplayName="Comment Detail" DefaultValue="" Category="Documentation">
<Attributes>
<ClrAttribute Name="System.ComponentModel.Editor">
<Parameters>
<AttributeParameter Value="typeof(System.ComponentModel.Design.MultilineStringEditor)" />
<AttributeParameter Value="typeof(System.Drawing.Design.UITypeEditor)" />
</Parameters>
</ClrAttribute>
</Attributes>
<Type>
<ExternalTypeMoniker Name="/System/String" />
</Type>
</DomainProperty>
<DomainProperty Id="1ebd74c3-5011-48e6-b5c1-67d78293067d" Description="Brief code documentation" Name="Summary" DisplayName="Comment Summary" Category="Documentation">
<Attributes>
<ClrAttribute Name="System.ComponentModel.Editor">
<Parameters>
<AttributeParameter Value="typeof(System.ComponentModel.Design.MultilineStringEditor)" />
<AttributeParameter Value="typeof(System.Drawing.Design.UITypeEditor)" />
</Parameters>
</ClrAttribute>
</Attributes>
<Type>
<ExternalTypeMoniker Name="/System/String" />
</Type>
Expand Down Expand Up @@ -602,6 +642,14 @@
</Type>
</DomainProperty>
<DomainProperty Id="12ea7154-be17-4707-ac96-eb1f8f2029ce" Description="Brief code documentation" Name="Summary" DisplayName="Comment Summary" Category="Documentation">
<Attributes>
<ClrAttribute Name="System.ComponentModel.Editor">
<Parameters>
<AttributeParameter Value="typeof(System.ComponentModel.Design.MultilineStringEditor)" />
<AttributeParameter Value="typeof(System.Drawing.Design.UITypeEditor)" />
</Parameters>
</ClrAttribute>
</Attributes>
<Type>
<ExternalTypeMoniker Name="/System/String" />
</Type>
Expand Down Expand Up @@ -653,6 +701,14 @@
</Type>
</DomainProperty>
<DomainProperty Id="4eec932a-9148-4d3c-9f29-35d8dbd13844" Description="Brief code documentation" Name="Summary" DisplayName="Comment Summary" Category="Documentation">
<Attributes>
<ClrAttribute Name="System.ComponentModel.Editor">
<Parameters>
<AttributeParameter Value="typeof(System.ComponentModel.Design.MultilineStringEditor)" />
<AttributeParameter Value="typeof(System.Drawing.Design.UITypeEditor)" />
</Parameters>
</ClrAttribute>
</Attributes>
<Type>
<ExternalTypeMoniker Name="/System/String" />
</Type>
Expand Down Expand Up @@ -736,16 +792,40 @@
</Type>
</DomainProperty>
<DomainProperty Id="8983d9c4-c5f3-4eaa-b8b2-14d18a858f21" Description="Detailed code documentation for this end of the association" Name="TargetDescription" DisplayName="End2 Comment Detail" DefaultValue="" Category="End 2">
<Attributes>
<ClrAttribute Name="System.ComponentModel.Editor">
<Parameters>
<AttributeParameter Value="typeof(System.ComponentModel.Design.MultilineStringEditor)" />
<AttributeParameter Value="typeof(System.Drawing.Design.UITypeEditor)" />
</Parameters>
</ClrAttribute>
</Attributes>
<Type>
<ExternalTypeMoniker Name="/System/String" />
</Type>
</DomainProperty>
<DomainProperty Id="edec72cc-c40b-4c64-b2d4-e713f691ecd0" Description="Short code documentation for this end of the association" Name="TargetSummary" DisplayName="End2 Comment Summary" Category="End 2">
<Attributes>
<ClrAttribute Name="System.ComponentModel.Editor">
<Parameters>
<AttributeParameter Value="typeof(System.ComponentModel.Design.MultilineStringEditor)" />
<AttributeParameter Value="typeof(System.Drawing.Design.UITypeEditor)" />
</Parameters>
</ClrAttribute>
</Attributes>
<Type>
<ExternalTypeMoniker Name="/System/String" />
</Type>
</DomainProperty>
<DomainProperty Id="53747127-cd19-43e0-b37b-1b669d506ed2" Description="Brief code documentation" Name="Summary" DisplayName="Comment Summary" Category="Documentation">
<DomainProperty Id="53747127-cd19-43e0-b37b-1b669d506ed2" Description="Brief code documentation" Name="Summary" DisplayName="Comment Summary" Category="Documentation" IsBrowsable="false">
<Attributes>
<ClrAttribute Name="System.ComponentModel.Editor">
<Parameters>
<AttributeParameter Value="typeof(System.ComponentModel.Design.MultilineStringEditor)" />
<AttributeParameter Value="typeof(System.Drawing.Design.UITypeEditor)" />
</Parameters>
</ClrAttribute>
</Attributes>
<Type>
<ExternalTypeMoniker Name="/System/String" />
</Type>
Expand Down Expand Up @@ -866,11 +946,27 @@
</Type>
</DomainProperty>
<DomainProperty Id="378e5c5a-9eb0-4d42-ad4c-7feca0176995" Description="Detailed code documentation for this end of the association" Name="SourceDescription" DisplayName="End1 Comment Detail" DefaultValue="" Category="End 1">
<Attributes>
<ClrAttribute Name="System.ComponentModel.Editor">
<Parameters>
<AttributeParameter Value="typeof(System.ComponentModel.Design.MultilineStringEditor)" />
<AttributeParameter Value="typeof(System.Drawing.Design.UITypeEditor)" />
</Parameters>
</ClrAttribute>
</Attributes>
<Type>
<ExternalTypeMoniker Name="/System/String" />
</Type>
</DomainProperty>
<DomainProperty Id="73bbc365-57ca-4f07-a834-9fe6605b76d0" Description="Short code documentation for this end of the association" Name="SourceSummary" DisplayName="End1 Comment Summary" Category="End 1">
<Attributes>
<ClrAttribute Name="System.ComponentModel.Editor">
<Parameters>
<AttributeParameter Value="typeof(System.ComponentModel.Design.MultilineStringEditor)" />
<AttributeParameter Value="typeof(System.Drawing.Design.UITypeEditor)" />
</Parameters>
</ClrAttribute>
</Attributes>
<Type>
<ExternalTypeMoniker Name="/System/String" />
</Type>
Expand Down
Loading

0 comments on commit 80d2119

Please sign in to comment.