ТороповаДА 8 meses atrás
pai
commit
1ff8863234

+ 1 - 1
WriteErase/ClassBase/Model1.Designer.cs

@@ -1,4 +1,4 @@
-// Создание кода T4 для модели "C:\Users\котковакв\Source\Repos\WhiteErase2\WriteErase\ClassBase\Model1.edmx" включено. 
+// Создание кода T4 для модели "C:\Users\тороповада\source\repos\WhiteErase\WriteErase\ClassBase\Model1.edmx" включено. 
 // Чтобы включить формирование кода прежних версий, измените значение свойства "Стратегия создания кода" конструктора
 // на "Legacy ObjectContext". Это свойство доступно в окне "Свойства", если модель
 // открыта в конструкторе.

+ 18 - 6
WriteErase/ClassBase/Model1.edmx

@@ -373,7 +373,9 @@
           <NavigationProperty Name="Role" Relationship="Self.FK__User__UserRole__398D8EEE" FromRole="User" ToRole="Role" />
         </EntityType>
         <Association Name="FK__OrderProd__Order__403A8C7D">
-          <End Role="Order" Type="Self.Order" Multiplicity="1" />
+          <End Role="Order" Type="Self.Order" Multiplicity="1" >
+            <OnDelete Action="Cascade" />
+          </End>
           <End Role="OrderProduct" Type="Self.OrderProduct" Multiplicity="*" />
           <ReferentialConstraint>
             <Principal Role="Order">
@@ -397,7 +399,9 @@
           </ReferentialConstraint>
         </Association>
         <Association Name="FK__OrderProd__Produ__412EB0B6">
-          <End Role="Product" Type="Self.Product" Multiplicity="1" />
+          <End Role="Product" Type="Self.Product" Multiplicity="1" >
+            <OnDelete Action="Cascade" />
+          </End>
           <End Role="OrderProduct" Type="Self.OrderProduct" Multiplicity="*" />
           <ReferentialConstraint>
             <Principal Role="Product">
@@ -409,7 +413,9 @@
           </ReferentialConstraint>
         </Association>
         <Association Name="FK_Product_ProductCategory">
-          <End Role="ProductCategory" Type="Self.ProductCategory" Multiplicity="1" />
+          <End Role="ProductCategory" Type="Self.ProductCategory" Multiplicity="1" >
+            <OnDelete Action="Cascade" />
+          </End>
           <End Role="Product" Type="Self.Product" Multiplicity="*" />
           <ReferentialConstraint>
             <Principal Role="ProductCategory">
@@ -421,7 +427,9 @@
           </ReferentialConstraint>
         </Association>
         <Association Name="FK_Product_ProductManufacturer">
-          <End Role="ProductManufacturer" Type="Self.ProductManufacturer" Multiplicity="1" />
+          <End Role="ProductManufacturer" Type="Self.ProductManufacturer" Multiplicity="1" >
+            <OnDelete Action="Cascade" />
+          </End>
           <End Role="Product" Type="Self.Product" Multiplicity="*" />
           <ReferentialConstraint>
             <Principal Role="ProductManufacturer">
@@ -433,7 +441,9 @@
           </ReferentialConstraint>
         </Association>
         <Association Name="FK_Product_ProductSuplier">
-          <End Role="ProductSuplier" Type="Self.ProductSuplier" Multiplicity="1" />
+          <End Role="ProductSuplier" Type="Self.ProductSuplier" Multiplicity="1" >
+            <OnDelete Action="Cascade" />
+          </End>
           <End Role="Product" Type="Self.Product" Multiplicity="*" />
           <ReferentialConstraint>
             <Principal Role="ProductSuplier">
@@ -445,7 +455,9 @@
           </ReferentialConstraint>
         </Association>
         <Association Name="FK_Product_ProductUnit">
-          <End Role="ProductUnit" Type="Self.ProductUnit" Multiplicity="0..1" />
+          <End Role="ProductUnit" Type="Self.ProductUnit" Multiplicity="0..1" >
+            <OnDelete Action="Cascade" />
+          </End>
           <End Role="Product" Type="Self.Product" Multiplicity="*" />
           <ReferentialConstraint>
             <Principal Role="ProductUnit">