ModelStore.edmx 41 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <edmx:Edmx Version="3.0" xmlns:edmx="http://schemas.microsoft.com/ado/2009/11/edmx">
  3. <!-- EF Runtime content -->
  4. <edmx:Runtime>
  5. <!-- SSDL content -->
  6. <edmx:StorageModels>
  7. <Schema Namespace="gr672_pgvModel.Store" Provider="System.Data.SqlClient" ProviderManifestToken="2012" Alias="Self" xmlns:store="http://schemas.microsoft.com/ado/2007/12/edm/EntityStoreSchemaGenerator" xmlns:customannotation="http://schemas.microsoft.com/ado/2013/11/edm/customannotation" xmlns="http://schemas.microsoft.com/ado/2009/11/edm/ssdl">
  8. <EntityType Name="Cashier">
  9. <Key>
  10. <PropertyRef Name="CashierID" />
  11. </Key>
  12. <Property Name="CashierID" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
  13. <Property Name="IDStore" Type="int" Nullable="false" />
  14. </EntityType>
  15. <EntityType Name="Employee">
  16. <Key>
  17. <PropertyRef Name="EmployeeID" />
  18. </Key>
  19. <Property Name="EmployeeID" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
  20. <Property Name="LastName" Type="nvarchar" MaxLength="50" Nullable="false" />
  21. <Property Name="Name" Type="nvarchar" MaxLength="50" Nullable="false" />
  22. <Property Name="MiddleName" Type="nvarchar" MaxLength="50" Nullable="false" />
  23. <Property Name="Code" Type="nvarchar" MaxLength="5" Nullable="false" />
  24. </EntityType>
  25. <EntityType Name="EmployeeInStore">
  26. <Key>
  27. <PropertyRef Name="IDEmployeeInStore" />
  28. </Key>
  29. <Property Name="IDStore" Type="int" Nullable="false" />
  30. <Property Name="IDEmployee" Type="int" Nullable="false" />
  31. <Property Name="IDEmployeeInStore" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
  32. </EntityType>
  33. <EntityType Name="Order">
  34. <Key>
  35. <PropertyRef Name="OrderID" />
  36. </Key>
  37. <Property Name="OrderID" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
  38. <Property Name="Date" Type="date" Nullable="false" />
  39. <Property Name="IDWorkShift" Type="int" Nullable="false" />
  40. <Property Name="State" Type="bit" Nullable="false" />
  41. </EntityType>
  42. <EntityType Name="PaymentMetod">
  43. <Key>
  44. <PropertyRef Name="PaymentMetodID" />
  45. </Key>
  46. <Property Name="PaymentMetodID" Type="int" Nullable="false" />
  47. <Property Name="PaymentMetodName" Type="nvarchar" MaxLength="50" Nullable="false" />
  48. </EntityType>
  49. <EntityType Name="PaymentOrder">
  50. <Key>
  51. <PropertyRef Name="PaymentID" />
  52. </Key>
  53. <Property Name="PaymentID" Type="int" Nullable="false" />
  54. <Property Name="IDPaymentMetod" Type="int" Nullable="false" />
  55. <Property Name="IDOrder" Type="int" Nullable="false" />
  56. </EntityType>
  57. <EntityType Name="Product">
  58. <Key>
  59. <PropertyRef Name="ProductID" />
  60. </Key>
  61. <Property Name="ProductID" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
  62. <Property Name="NameProduct" Type="nvarchar(max)" Nullable="false" />
  63. <Property Name="Weight" Type="int" Nullable="false" />
  64. <Property Name="Packaging" Type="int" Nullable="false" />
  65. <Property Name="PriceOfOne" Type="money" Nullable="false" />
  66. <Property Name="BarCode" Type="nvarchar(max)" Nullable="false" />
  67. </EntityType>
  68. <EntityType Name="ProductInOrder">
  69. <Key>
  70. <PropertyRef Name="IDOrder" />
  71. <PropertyRef Name="IDProduct" />
  72. </Key>
  73. <Property Name="IDOrder" Type="int" Nullable="false" />
  74. <Property Name="IDProduct" Type="int" Nullable="false" />
  75. <Property Name="AmountProduct" Type="int" Nullable="false" />
  76. </EntityType>
  77. <EntityType Name="ProductInStore">
  78. <Key>
  79. <PropertyRef Name="ProductInStoreID" />
  80. </Key>
  81. <Property Name="ProductInStoreID" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
  82. <Property Name="IDStore" Type="int" Nullable="false" />
  83. <Property Name="IDProduct" Type="int" Nullable="false" />
  84. <Property Name="RemainsProduct" Type="int" Nullable="false" />
  85. </EntityType>
  86. <EntityType Name="Store">
  87. <Key>
  88. <PropertyRef Name="StoreID" />
  89. </Key>
  90. <Property Name="StoreID" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
  91. <Property Name="Address" Type="nvarchar(max)" Nullable="false" />
  92. </EntityType>
  93. <EntityType Name="WorkShift">
  94. <Key>
  95. <PropertyRef Name="WorkShiftID" />
  96. </Key>
  97. <Property Name="WorkShiftID" Type="int" Nullable="false" />
  98. <Property Name="IDCashier" Type="int" Nullable="false" />
  99. <Property Name="IDEmployee" Type="int" Nullable="false" />
  100. <Property Name="StartDateAndTimeWork" Type="datetime" Nullable="false" />
  101. <Property Name="EndDateAndTimeWork" Type="datetime" />
  102. </EntityType>
  103. <Association Name="FK_Cashier_Store">
  104. <End Role="Store" Type="Self.Store" Multiplicity="1" />
  105. <End Role="Cashier" Type="Self.Cashier" Multiplicity="*" />
  106. <ReferentialConstraint>
  107. <Principal Role="Store">
  108. <PropertyRef Name="StoreID" />
  109. </Principal>
  110. <Dependent Role="Cashier">
  111. <PropertyRef Name="IDStore" />
  112. </Dependent>
  113. </ReferentialConstraint>
  114. </Association>
  115. <Association Name="FK_EmployeeInStore_Employee">
  116. <End Role="Employee" Type="Self.Employee" Multiplicity="1" />
  117. <End Role="EmployeeInStore" Type="Self.EmployeeInStore" Multiplicity="*" />
  118. <ReferentialConstraint>
  119. <Principal Role="Employee">
  120. <PropertyRef Name="EmployeeID" />
  121. </Principal>
  122. <Dependent Role="EmployeeInStore">
  123. <PropertyRef Name="IDEmployee" />
  124. </Dependent>
  125. </ReferentialConstraint>
  126. </Association>
  127. <Association Name="FK_EmployeeInStore_Store">
  128. <End Role="Store" Type="Self.Store" Multiplicity="1" />
  129. <End Role="EmployeeInStore" Type="Self.EmployeeInStore" Multiplicity="*" />
  130. <ReferentialConstraint>
  131. <Principal Role="Store">
  132. <PropertyRef Name="StoreID" />
  133. </Principal>
  134. <Dependent Role="EmployeeInStore">
  135. <PropertyRef Name="IDStore" />
  136. </Dependent>
  137. </ReferentialConstraint>
  138. </Association>
  139. <Association Name="FK_Order_WorkShift">
  140. <End Role="WorkShift" Type="Self.WorkShift" Multiplicity="1" />
  141. <End Role="Order" Type="Self.Order" Multiplicity="*" />
  142. <ReferentialConstraint>
  143. <Principal Role="WorkShift">
  144. <PropertyRef Name="WorkShiftID" />
  145. </Principal>
  146. <Dependent Role="Order">
  147. <PropertyRef Name="IDWorkShift" />
  148. </Dependent>
  149. </ReferentialConstraint>
  150. </Association>
  151. <Association Name="FK_PaymentOrder_Order">
  152. <End Role="Order" Type="Self.Order" Multiplicity="1" />
  153. <End Role="PaymentOrder" Type="Self.PaymentOrder" Multiplicity="*" />
  154. <ReferentialConstraint>
  155. <Principal Role="Order">
  156. <PropertyRef Name="OrderID" />
  157. </Principal>
  158. <Dependent Role="PaymentOrder">
  159. <PropertyRef Name="IDOrder" />
  160. </Dependent>
  161. </ReferentialConstraint>
  162. </Association>
  163. <Association Name="FK_PaymentOrder_PaymentMetod">
  164. <End Role="PaymentMetod" Type="Self.PaymentMetod" Multiplicity="1" />
  165. <End Role="PaymentOrder" Type="Self.PaymentOrder" Multiplicity="*" />
  166. <ReferentialConstraint>
  167. <Principal Role="PaymentMetod">
  168. <PropertyRef Name="PaymentMetodID" />
  169. </Principal>
  170. <Dependent Role="PaymentOrder">
  171. <PropertyRef Name="IDPaymentMetod" />
  172. </Dependent>
  173. </ReferentialConstraint>
  174. </Association>
  175. <Association Name="FK_ProductInOrder_Order">
  176. <End Role="Order" Type="Self.Order" Multiplicity="1" />
  177. <End Role="ProductInOrder" Type="Self.ProductInOrder" Multiplicity="*" />
  178. <ReferentialConstraint>
  179. <Principal Role="Order">
  180. <PropertyRef Name="OrderID" />
  181. </Principal>
  182. <Dependent Role="ProductInOrder">
  183. <PropertyRef Name="IDOrder" />
  184. </Dependent>
  185. </ReferentialConstraint>
  186. </Association>
  187. <Association Name="FK_ProductInOrder_ProductInStore">
  188. <End Role="ProductInStore" Type="Self.ProductInStore" Multiplicity="1" />
  189. <End Role="ProductInOrder" Type="Self.ProductInOrder" Multiplicity="*" />
  190. <ReferentialConstraint>
  191. <Principal Role="ProductInStore">
  192. <PropertyRef Name="ProductInStoreID" />
  193. </Principal>
  194. <Dependent Role="ProductInOrder">
  195. <PropertyRef Name="IDProduct" />
  196. </Dependent>
  197. </ReferentialConstraint>
  198. </Association>
  199. <Association Name="FK_ProductInStore_Product">
  200. <End Role="Product" Type="Self.Product" Multiplicity="1" />
  201. <End Role="ProductInStore" Type="Self.ProductInStore" Multiplicity="*" />
  202. <ReferentialConstraint>
  203. <Principal Role="Product">
  204. <PropertyRef Name="ProductID" />
  205. </Principal>
  206. <Dependent Role="ProductInStore">
  207. <PropertyRef Name="IDProduct" />
  208. </Dependent>
  209. </ReferentialConstraint>
  210. </Association>
  211. <Association Name="FK_ProductInStore_Store">
  212. <End Role="Store" Type="Self.Store" Multiplicity="1" />
  213. <End Role="ProductInStore" Type="Self.ProductInStore" Multiplicity="*" />
  214. <ReferentialConstraint>
  215. <Principal Role="Store">
  216. <PropertyRef Name="StoreID" />
  217. </Principal>
  218. <Dependent Role="ProductInStore">
  219. <PropertyRef Name="IDStore" />
  220. </Dependent>
  221. </ReferentialConstraint>
  222. </Association>
  223. <Association Name="FK_WorkShift_Cashier">
  224. <End Role="Cashier" Type="Self.Cashier" Multiplicity="1" />
  225. <End Role="WorkShift" Type="Self.WorkShift" Multiplicity="*" />
  226. <ReferentialConstraint>
  227. <Principal Role="Cashier">
  228. <PropertyRef Name="CashierID" />
  229. </Principal>
  230. <Dependent Role="WorkShift">
  231. <PropertyRef Name="IDCashier" />
  232. </Dependent>
  233. </ReferentialConstraint>
  234. </Association>
  235. <Association Name="FK_WorkShift_EmployeeInStore">
  236. <End Role="EmployeeInStore" Type="Self.EmployeeInStore" Multiplicity="1" />
  237. <End Role="WorkShift" Type="Self.WorkShift" Multiplicity="*" />
  238. <ReferentialConstraint>
  239. <Principal Role="EmployeeInStore">
  240. <PropertyRef Name="IDEmployeeInStore" />
  241. </Principal>
  242. <Dependent Role="WorkShift">
  243. <PropertyRef Name="IDEmployee" />
  244. </Dependent>
  245. </ReferentialConstraint>
  246. </Association>
  247. <EntityContainer Name="gr672_pgvModelStoreContainer">
  248. <EntitySet Name="Cashier" EntityType="Self.Cashier" Schema="dbo" store:Type="Tables" />
  249. <EntitySet Name="Employee" EntityType="Self.Employee" Schema="dbo" store:Type="Tables" />
  250. <EntitySet Name="EmployeeInStore" EntityType="Self.EmployeeInStore" Schema="dbo" store:Type="Tables" />
  251. <EntitySet Name="Order" EntityType="Self.Order" Schema="dbo" store:Type="Tables" />
  252. <EntitySet Name="PaymentMetod" EntityType="Self.PaymentMetod" Schema="dbo" store:Type="Tables" />
  253. <EntitySet Name="PaymentOrder" EntityType="Self.PaymentOrder" Schema="dbo" store:Type="Tables" />
  254. <EntitySet Name="Product" EntityType="Self.Product" Schema="dbo" store:Type="Tables" />
  255. <EntitySet Name="ProductInOrder" EntityType="Self.ProductInOrder" Schema="dbo" store:Type="Tables" />
  256. <EntitySet Name="ProductInStore" EntityType="Self.ProductInStore" Schema="dbo" store:Type="Tables" />
  257. <EntitySet Name="Store" EntityType="Self.Store" Schema="dbo" store:Type="Tables" />
  258. <EntitySet Name="WorkShift" EntityType="Self.WorkShift" Schema="dbo" store:Type="Tables" />
  259. <AssociationSet Name="FK_Cashier_Store" Association="Self.FK_Cashier_Store">
  260. <End Role="Store" EntitySet="Store" />
  261. <End Role="Cashier" EntitySet="Cashier" />
  262. </AssociationSet>
  263. <AssociationSet Name="FK_EmployeeInStore_Employee" Association="Self.FK_EmployeeInStore_Employee">
  264. <End Role="Employee" EntitySet="Employee" />
  265. <End Role="EmployeeInStore" EntitySet="EmployeeInStore" />
  266. </AssociationSet>
  267. <AssociationSet Name="FK_EmployeeInStore_Store" Association="Self.FK_EmployeeInStore_Store">
  268. <End Role="Store" EntitySet="Store" />
  269. <End Role="EmployeeInStore" EntitySet="EmployeeInStore" />
  270. </AssociationSet>
  271. <AssociationSet Name="FK_Order_WorkShift" Association="Self.FK_Order_WorkShift">
  272. <End Role="WorkShift" EntitySet="WorkShift" />
  273. <End Role="Order" EntitySet="Order" />
  274. </AssociationSet>
  275. <AssociationSet Name="FK_PaymentOrder_Order" Association="Self.FK_PaymentOrder_Order">
  276. <End Role="Order" EntitySet="Order" />
  277. <End Role="PaymentOrder" EntitySet="PaymentOrder" />
  278. </AssociationSet>
  279. <AssociationSet Name="FK_PaymentOrder_PaymentMetod" Association="Self.FK_PaymentOrder_PaymentMetod">
  280. <End Role="PaymentMetod" EntitySet="PaymentMetod" />
  281. <End Role="PaymentOrder" EntitySet="PaymentOrder" />
  282. </AssociationSet>
  283. <AssociationSet Name="FK_ProductInOrder_Order" Association="Self.FK_ProductInOrder_Order">
  284. <End Role="Order" EntitySet="Order" />
  285. <End Role="ProductInOrder" EntitySet="ProductInOrder" />
  286. </AssociationSet>
  287. <AssociationSet Name="FK_ProductInOrder_ProductInStore" Association="Self.FK_ProductInOrder_ProductInStore">
  288. <End Role="ProductInStore" EntitySet="ProductInStore" />
  289. <End Role="ProductInOrder" EntitySet="ProductInOrder" />
  290. </AssociationSet>
  291. <AssociationSet Name="FK_ProductInStore_Product" Association="Self.FK_ProductInStore_Product">
  292. <End Role="Product" EntitySet="Product" />
  293. <End Role="ProductInStore" EntitySet="ProductInStore" />
  294. </AssociationSet>
  295. <AssociationSet Name="FK_ProductInStore_Store" Association="Self.FK_ProductInStore_Store">
  296. <End Role="Store" EntitySet="Store" />
  297. <End Role="ProductInStore" EntitySet="ProductInStore" />
  298. </AssociationSet>
  299. <AssociationSet Name="FK_WorkShift_Cashier" Association="Self.FK_WorkShift_Cashier">
  300. <End Role="Cashier" EntitySet="Cashier" />
  301. <End Role="WorkShift" EntitySet="WorkShift" />
  302. </AssociationSet>
  303. <AssociationSet Name="FK_WorkShift_EmployeeInStore" Association="Self.FK_WorkShift_EmployeeInStore">
  304. <End Role="EmployeeInStore" EntitySet="EmployeeInStore" />
  305. <End Role="WorkShift" EntitySet="WorkShift" />
  306. </AssociationSet>
  307. </EntityContainer>
  308. </Schema></edmx:StorageModels>
  309. <!-- CSDL content -->
  310. <edmx:ConceptualModels>
  311. <Schema Namespace="gr672_pgvModel" Alias="Self" annotation:UseStrongSpatialTypes="false" xmlns:annotation="http://schemas.microsoft.com/ado/2009/02/edm/annotation" xmlns:customannotation="http://schemas.microsoft.com/ado/2013/11/edm/customannotation" xmlns="http://schemas.microsoft.com/ado/2009/11/edm">
  312. <EntityType Name="Employee">
  313. <Key>
  314. <PropertyRef Name="EmployeeID" />
  315. </Key>
  316. <Property Name="EmployeeID" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
  317. <Property Name="LastName" Type="String" MaxLength="50" FixedLength="false" Unicode="true" Nullable="false" />
  318. <Property Name="Name" Type="String" MaxLength="50" FixedLength="false" Unicode="true" Nullable="false" />
  319. <Property Name="MiddleName" Type="String" MaxLength="50" FixedLength="false" Unicode="true" Nullable="false" />
  320. <Property Name="Code" Type="String" MaxLength="5" FixedLength="false" Unicode="true" Nullable="false" />
  321. <NavigationProperty Name="EmployeeInStore" Relationship="gr672_pgvModel.FK_EmployeeInStore_Employee" FromRole="Employee" ToRole="EmployeeInStore" />
  322. </EntityType>
  323. <EntityType Name="Order">
  324. <Key>
  325. <PropertyRef Name="OrderID" />
  326. </Key>
  327. <Property Name="OrderID" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
  328. <Property Name="Date" Type="DateTime" Nullable="false" Precision="0" />
  329. <Property Name="IDWorkShift" Type="Int32" Nullable="false" />
  330. <Property Name="State" Type="Boolean" Nullable="false" />
  331. <NavigationProperty Name="WorkShift" Relationship="Self.FK_Order_WorkShift" FromRole="Order" ToRole="WorkShift" />
  332. <NavigationProperty Name="PaymentOrder" Relationship="Self.FK_PaymentOrder_Order" FromRole="Order" ToRole="PaymentOrder" />
  333. <NavigationProperty Name="ProductInOrder" Relationship="Self.FK_ProductInOrder_Order" FromRole="Order" ToRole="ProductInOrder" />
  334. </EntityType>
  335. <EntityType Name="PaymentMetod">
  336. <Key>
  337. <PropertyRef Name="PaymentMetodID" />
  338. </Key>
  339. <Property Name="PaymentMetodID" Type="Int32" Nullable="false" />
  340. <Property Name="PaymentMetodName" Type="String" MaxLength="50" FixedLength="false" Unicode="true" Nullable="false" />
  341. <NavigationProperty Name="PaymentOrder" Relationship="Self.FK_PaymentOrder_PaymentMetod" FromRole="PaymentMetod" ToRole="PaymentOrder" />
  342. </EntityType>
  343. <EntityType Name="PaymentOrder">
  344. <Key>
  345. <PropertyRef Name="PaymentID" />
  346. </Key>
  347. <Property Name="PaymentID" Type="Int32" Nullable="false" />
  348. <Property Name="IDPaymentMetod" Type="Int32" Nullable="false" />
  349. <Property Name="IDOrder" Type="Int32" Nullable="false" />
  350. <NavigationProperty Name="Order" Relationship="Self.FK_PaymentOrder_Order" FromRole="PaymentOrder" ToRole="Order" />
  351. <NavigationProperty Name="PaymentMetod" Relationship="Self.FK_PaymentOrder_PaymentMetod" FromRole="PaymentOrder" ToRole="PaymentMetod" />
  352. </EntityType>
  353. <EntityType Name="Product">
  354. <Key>
  355. <PropertyRef Name="ProductID" />
  356. </Key>
  357. <Property Name="ProductID" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
  358. <Property Name="NameProduct" Type="String" MaxLength="Max" FixedLength="false" Unicode="true" Nullable="false" />
  359. <Property Name="Weight" Type="Int32" Nullable="false" />
  360. <Property Name="Packaging" Type="Int32" Nullable="false" />
  361. <Property Name="PriceOfOne" Type="Decimal" Precision="19" Scale="4" Nullable="false" />
  362. <Property Name="BarCode" Type="String" MaxLength="Max" FixedLength="false" Unicode="true" Nullable="false" />
  363. <NavigationProperty Name="ProductInStore" Relationship="Self.FK_ProductInStore_Product" FromRole="Product" ToRole="ProductInStore" />
  364. </EntityType>
  365. <EntityType Name="ProductInOrder">
  366. <Key>
  367. <PropertyRef Name="IDOrder" />
  368. <PropertyRef Name="IDProduct" />
  369. </Key>
  370. <Property Name="IDOrder" Type="Int32" Nullable="false" />
  371. <Property Name="IDProduct" Type="Int32" Nullable="false" />
  372. <Property Name="AmountProduct" Type="Int32" Nullable="false" />
  373. <NavigationProperty Name="Order" Relationship="Self.FK_ProductInOrder_Order" FromRole="ProductInOrder" ToRole="Order" />
  374. <NavigationProperty Name="ProductInStore" Relationship="Self.FK_ProductInOrder_ProductInStore" FromRole="ProductInOrder" ToRole="ProductInStore" />
  375. </EntityType>
  376. <EntityType Name="ProductInStore">
  377. <Key>
  378. <PropertyRef Name="ProductInStoreID" />
  379. </Key>
  380. <Property Name="ProductInStoreID" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
  381. <Property Name="IDStore" Type="Int32" Nullable="false" />
  382. <Property Name="IDProduct" Type="Int32" Nullable="false" />
  383. <Property Name="RemainsProduct" Type="Int32" Nullable="false" />
  384. <NavigationProperty Name="Product" Relationship="Self.FK_ProductInStore_Product" FromRole="ProductInStore" ToRole="Product" />
  385. <NavigationProperty Name="ProductInOrder" Relationship="Self.FK_ProductInOrder_ProductInStore" FromRole="ProductInStore" ToRole="ProductInOrder" />
  386. <NavigationProperty Name="Store" Relationship="Self.FK_ProductInStore_Store" FromRole="ProductInStore" ToRole="Store" />
  387. </EntityType>
  388. <EntityType Name="Store">
  389. <Key>
  390. <PropertyRef Name="StoreID" />
  391. </Key>
  392. <Property Name="StoreID" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
  393. <Property Name="Address" Type="String" MaxLength="Max" FixedLength="false" Unicode="true" Nullable="false" />
  394. <NavigationProperty Name="ProductInStore" Relationship="Self.FK_ProductInStore_Store" FromRole="Store" ToRole="ProductInStore" />
  395. <NavigationProperty Name="Cashier" Relationship="gr672_pgvModel.FK_Cashier_Store" FromRole="Store" ToRole="Cashier" />
  396. <NavigationProperty Name="EmployeeInStore" Relationship="gr672_pgvModel.FK_EmployeeInStore_Store" FromRole="Store" ToRole="EmployeeInStore" />
  397. </EntityType>
  398. <EntityType Name="WorkShift">
  399. <Key>
  400. <PropertyRef Name="WorkShiftID" />
  401. </Key>
  402. <Property Name="WorkShiftID" Type="Int32" Nullable="false" />
  403. <Property Name="IDCashier" Type="Int32" Nullable="false" />
  404. <Property Name="IDEmployee" Type="Int32" Nullable="false" />
  405. <Property Name="StartDateAndTimeWork" Type="DateTime" Nullable="false" Precision="3" />
  406. <Property Name="EndDateAndTimeWork" Type="DateTime" Precision="3" />
  407. <NavigationProperty Name="Order" Relationship="Self.FK_Order_WorkShift" FromRole="WorkShift" ToRole="Order" />
  408. <NavigationProperty Name="Cashier" Relationship="gr672_pgvModel.FK_WorkShift_Cashier" FromRole="WorkShift" ToRole="Cashier" />
  409. <NavigationProperty Name="EmployeeInStore" Relationship="gr672_pgvModel.FK_WorkShift_EmployeeInStore" FromRole="WorkShift" ToRole="EmployeeInStore" />
  410. </EntityType>
  411. <Association Name="FK_Order_WorkShift">
  412. <End Role="WorkShift" Type="Self.WorkShift" Multiplicity="1" />
  413. <End Role="Order" Type="Self.Order" Multiplicity="*" />
  414. <ReferentialConstraint>
  415. <Principal Role="WorkShift">
  416. <PropertyRef Name="WorkShiftID" />
  417. </Principal>
  418. <Dependent Role="Order">
  419. <PropertyRef Name="IDWorkShift" />
  420. </Dependent>
  421. </ReferentialConstraint>
  422. </Association>
  423. <Association Name="FK_PaymentOrder_Order">
  424. <End Role="Order" Type="Self.Order" Multiplicity="1" />
  425. <End Role="PaymentOrder" Type="Self.PaymentOrder" Multiplicity="*" />
  426. <ReferentialConstraint>
  427. <Principal Role="Order">
  428. <PropertyRef Name="OrderID" />
  429. </Principal>
  430. <Dependent Role="PaymentOrder">
  431. <PropertyRef Name="IDOrder" />
  432. </Dependent>
  433. </ReferentialConstraint>
  434. </Association>
  435. <Association Name="FK_ProductInOrder_Order">
  436. <End Role="Order" Type="Self.Order" Multiplicity="1" />
  437. <End Role="ProductInOrder" Type="Self.ProductInOrder" Multiplicity="*" />
  438. <ReferentialConstraint>
  439. <Principal Role="Order">
  440. <PropertyRef Name="OrderID" />
  441. </Principal>
  442. <Dependent Role="ProductInOrder">
  443. <PropertyRef Name="IDOrder" />
  444. </Dependent>
  445. </ReferentialConstraint>
  446. </Association>
  447. <Association Name="FK_PaymentOrder_PaymentMetod">
  448. <End Role="PaymentMetod" Type="Self.PaymentMetod" Multiplicity="1" />
  449. <End Role="PaymentOrder" Type="Self.PaymentOrder" Multiplicity="*" />
  450. <ReferentialConstraint>
  451. <Principal Role="PaymentMetod">
  452. <PropertyRef Name="PaymentMetodID" />
  453. </Principal>
  454. <Dependent Role="PaymentOrder">
  455. <PropertyRef Name="IDPaymentMetod" />
  456. </Dependent>
  457. </ReferentialConstraint>
  458. </Association>
  459. <Association Name="FK_ProductInStore_Product">
  460. <End Role="Product" Type="Self.Product" Multiplicity="1" />
  461. <End Role="ProductInStore" Type="Self.ProductInStore" Multiplicity="*" />
  462. <ReferentialConstraint>
  463. <Principal Role="Product">
  464. <PropertyRef Name="ProductID" />
  465. </Principal>
  466. <Dependent Role="ProductInStore">
  467. <PropertyRef Name="IDProduct" />
  468. </Dependent>
  469. </ReferentialConstraint>
  470. </Association>
  471. <Association Name="FK_ProductInOrder_ProductInStore">
  472. <End Role="ProductInStore" Type="Self.ProductInStore" Multiplicity="1" />
  473. <End Role="ProductInOrder" Type="Self.ProductInOrder" Multiplicity="*" />
  474. <ReferentialConstraint>
  475. <Principal Role="ProductInStore">
  476. <PropertyRef Name="ProductInStoreID" />
  477. </Principal>
  478. <Dependent Role="ProductInOrder">
  479. <PropertyRef Name="IDProduct" />
  480. </Dependent>
  481. </ReferentialConstraint>
  482. </Association>
  483. <Association Name="FK_ProductInStore_Store">
  484. <End Role="Store" Type="Self.Store" Multiplicity="1" />
  485. <End Role="ProductInStore" Type="Self.ProductInStore" Multiplicity="*" />
  486. <ReferentialConstraint>
  487. <Principal Role="Store">
  488. <PropertyRef Name="StoreID" />
  489. </Principal>
  490. <Dependent Role="ProductInStore">
  491. <PropertyRef Name="IDStore" />
  492. </Dependent>
  493. </ReferentialConstraint>
  494. </Association>
  495. <EntityContainer Name="gr672_pgvEntities" annotation:LazyLoadingEnabled="true">
  496. <EntitySet Name="Employee" EntityType="Self.Employee" />
  497. <EntitySet Name="Order" EntityType="Self.Order" />
  498. <EntitySet Name="PaymentMetod" EntityType="Self.PaymentMetod" />
  499. <EntitySet Name="PaymentOrder" EntityType="Self.PaymentOrder" />
  500. <EntitySet Name="Product" EntityType="Self.Product" />
  501. <EntitySet Name="ProductInOrder" EntityType="Self.ProductInOrder" />
  502. <EntitySet Name="ProductInStore" EntityType="Self.ProductInStore" />
  503. <EntitySet Name="Store" EntityType="Self.Store" />
  504. <EntitySet Name="WorkShift" EntityType="Self.WorkShift" />
  505. <AssociationSet Name="FK_Order_WorkShift" Association="Self.FK_Order_WorkShift">
  506. <End Role="WorkShift" EntitySet="WorkShift" />
  507. <End Role="Order" EntitySet="Order" />
  508. </AssociationSet>
  509. <AssociationSet Name="FK_PaymentOrder_Order" Association="Self.FK_PaymentOrder_Order">
  510. <End Role="Order" EntitySet="Order" />
  511. <End Role="PaymentOrder" EntitySet="PaymentOrder" />
  512. </AssociationSet>
  513. <AssociationSet Name="FK_ProductInOrder_Order" Association="Self.FK_ProductInOrder_Order">
  514. <End Role="Order" EntitySet="Order" />
  515. <End Role="ProductInOrder" EntitySet="ProductInOrder" />
  516. </AssociationSet>
  517. <AssociationSet Name="FK_PaymentOrder_PaymentMetod" Association="Self.FK_PaymentOrder_PaymentMetod">
  518. <End Role="PaymentMetod" EntitySet="PaymentMetod" />
  519. <End Role="PaymentOrder" EntitySet="PaymentOrder" />
  520. </AssociationSet>
  521. <AssociationSet Name="FK_ProductInStore_Product" Association="Self.FK_ProductInStore_Product">
  522. <End Role="Product" EntitySet="Product" />
  523. <End Role="ProductInStore" EntitySet="ProductInStore" />
  524. </AssociationSet>
  525. <AssociationSet Name="FK_ProductInOrder_ProductInStore" Association="Self.FK_ProductInOrder_ProductInStore">
  526. <End Role="ProductInStore" EntitySet="ProductInStore" />
  527. <End Role="ProductInOrder" EntitySet="ProductInOrder" />
  528. </AssociationSet>
  529. <AssociationSet Name="FK_ProductInStore_Store" Association="Self.FK_ProductInStore_Store">
  530. <End Role="Store" EntitySet="Store" />
  531. <End Role="ProductInStore" EntitySet="ProductInStore" />
  532. </AssociationSet>
  533. <EntitySet Name="Cashier" EntityType="gr672_pgvModel.Cashier" />
  534. <AssociationSet Name="FK_Cashier_Store" Association="gr672_pgvModel.FK_Cashier_Store">
  535. <End Role="Store" EntitySet="Store" />
  536. <End Role="Cashier" EntitySet="Cashier" />
  537. </AssociationSet>
  538. <AssociationSet Name="FK_WorkShift_Cashier" Association="gr672_pgvModel.FK_WorkShift_Cashier">
  539. <End Role="Cashier" EntitySet="Cashier" />
  540. <End Role="WorkShift" EntitySet="WorkShift" />
  541. </AssociationSet>
  542. <EntitySet Name="EmployeeInStore" EntityType="gr672_pgvModel.EmployeeInStore" />
  543. <AssociationSet Name="FK_EmployeeInStore_Employee" Association="gr672_pgvModel.FK_EmployeeInStore_Employee">
  544. <End Role="Employee" EntitySet="Employee" />
  545. <End Role="EmployeeInStore" EntitySet="EmployeeInStore" />
  546. </AssociationSet>
  547. <AssociationSet Name="FK_EmployeeInStore_Store" Association="gr672_pgvModel.FK_EmployeeInStore_Store">
  548. <End Role="Store" EntitySet="Store" />
  549. <End Role="EmployeeInStore" EntitySet="EmployeeInStore" />
  550. </AssociationSet>
  551. <AssociationSet Name="FK_WorkShift_EmployeeInStore" Association="gr672_pgvModel.FK_WorkShift_EmployeeInStore">
  552. <End Role="EmployeeInStore" EntitySet="EmployeeInStore" />
  553. <End Role="WorkShift" EntitySet="WorkShift" />
  554. </AssociationSet>
  555. </EntityContainer>
  556. <EntityType Name="Cashier">
  557. <Key>
  558. <PropertyRef Name="CashierID" />
  559. </Key>
  560. <Property Name="CashierID" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
  561. <Property Name="IDStore" Type="Int32" Nullable="false" />
  562. <NavigationProperty Name="Store" Relationship="gr672_pgvModel.FK_Cashier_Store" FromRole="Cashier" ToRole="Store" />
  563. <NavigationProperty Name="WorkShift" Relationship="gr672_pgvModel.FK_WorkShift_Cashier" FromRole="Cashier" ToRole="WorkShift" />
  564. </EntityType>
  565. <Association Name="FK_Cashier_Store">
  566. <End Type="gr672_pgvModel.Store" Role="Store" Multiplicity="1" />
  567. <End Type="gr672_pgvModel.Cashier" Role="Cashier" Multiplicity="*" />
  568. <ReferentialConstraint>
  569. <Principal Role="Store">
  570. <PropertyRef Name="StoreID" />
  571. </Principal>
  572. <Dependent Role="Cashier">
  573. <PropertyRef Name="IDStore" />
  574. </Dependent>
  575. </ReferentialConstraint>
  576. </Association>
  577. <Association Name="FK_WorkShift_Cashier">
  578. <End Type="gr672_pgvModel.Cashier" Role="Cashier" Multiplicity="1" />
  579. <End Type="gr672_pgvModel.WorkShift" Role="WorkShift" Multiplicity="*" />
  580. <ReferentialConstraint>
  581. <Principal Role="Cashier">
  582. <PropertyRef Name="CashierID" />
  583. </Principal>
  584. <Dependent Role="WorkShift">
  585. <PropertyRef Name="IDCashier" />
  586. </Dependent>
  587. </ReferentialConstraint>
  588. </Association>
  589. <EntityType Name="EmployeeInStore">
  590. <Key>
  591. <PropertyRef Name="IDEmployeeInStore" />
  592. </Key>
  593. <Property Name="IDStore" Type="Int32" Nullable="false" />
  594. <Property Name="IDEmployee" Type="Int32" Nullable="false" />
  595. <Property Name="IDEmployeeInStore" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
  596. <NavigationProperty Name="Employee" Relationship="gr672_pgvModel.FK_EmployeeInStore_Employee" FromRole="EmployeeInStore" ToRole="Employee" />
  597. <NavigationProperty Name="Store" Relationship="gr672_pgvModel.FK_EmployeeInStore_Store" FromRole="EmployeeInStore" ToRole="Store" />
  598. <NavigationProperty Name="WorkShift" Relationship="gr672_pgvModel.FK_WorkShift_EmployeeInStore" FromRole="EmployeeInStore" ToRole="WorkShift" />
  599. </EntityType>
  600. <Association Name="FK_EmployeeInStore_Employee">
  601. <End Type="gr672_pgvModel.Employee" Role="Employee" Multiplicity="1" />
  602. <End Type="gr672_pgvModel.EmployeeInStore" Role="EmployeeInStore" Multiplicity="*" />
  603. <ReferentialConstraint>
  604. <Principal Role="Employee">
  605. <PropertyRef Name="EmployeeID" />
  606. </Principal>
  607. <Dependent Role="EmployeeInStore">
  608. <PropertyRef Name="IDEmployee" />
  609. </Dependent>
  610. </ReferentialConstraint>
  611. </Association>
  612. <Association Name="FK_EmployeeInStore_Store">
  613. <End Type="gr672_pgvModel.Store" Role="Store" Multiplicity="1" />
  614. <End Type="gr672_pgvModel.EmployeeInStore" Role="EmployeeInStore" Multiplicity="*" />
  615. <ReferentialConstraint>
  616. <Principal Role="Store">
  617. <PropertyRef Name="StoreID" />
  618. </Principal>
  619. <Dependent Role="EmployeeInStore">
  620. <PropertyRef Name="IDStore" />
  621. </Dependent>
  622. </ReferentialConstraint>
  623. </Association>
  624. <Association Name="FK_WorkShift_EmployeeInStore">
  625. <End Type="gr672_pgvModel.EmployeeInStore" Role="EmployeeInStore" Multiplicity="1" />
  626. <End Type="gr672_pgvModel.WorkShift" Role="WorkShift" Multiplicity="*" />
  627. <ReferentialConstraint>
  628. <Principal Role="EmployeeInStore">
  629. <PropertyRef Name="IDEmployeeInStore" />
  630. </Principal>
  631. <Dependent Role="WorkShift">
  632. <PropertyRef Name="IDEmployee" />
  633. </Dependent>
  634. </ReferentialConstraint>
  635. </Association>
  636. </Schema>
  637. </edmx:ConceptualModels>
  638. <!-- C-S mapping content -->
  639. <edmx:Mappings>
  640. <Mapping Space="C-S" xmlns="http://schemas.microsoft.com/ado/2009/11/mapping/cs">
  641. <EntityContainerMapping StorageEntityContainer="gr672_pgvModelStoreContainer" CdmEntityContainer="gr672_pgvEntities">
  642. <EntitySetMapping Name="Employee">
  643. <EntityTypeMapping TypeName="gr672_pgvModel.Employee">
  644. <MappingFragment StoreEntitySet="Employee">
  645. <ScalarProperty Name="EmployeeID" ColumnName="EmployeeID" />
  646. <ScalarProperty Name="LastName" ColumnName="LastName" />
  647. <ScalarProperty Name="Name" ColumnName="Name" />
  648. <ScalarProperty Name="MiddleName" ColumnName="MiddleName" />
  649. <ScalarProperty Name="Code" ColumnName="Code" />
  650. </MappingFragment>
  651. </EntityTypeMapping>
  652. </EntitySetMapping>
  653. <EntitySetMapping Name="Order">
  654. <EntityTypeMapping TypeName="gr672_pgvModel.Order">
  655. <MappingFragment StoreEntitySet="Order">
  656. <ScalarProperty Name="OrderID" ColumnName="OrderID" />
  657. <ScalarProperty Name="Date" ColumnName="Date" />
  658. <ScalarProperty Name="IDWorkShift" ColumnName="IDWorkShift" />
  659. <ScalarProperty Name="State" ColumnName="State" />
  660. </MappingFragment>
  661. </EntityTypeMapping>
  662. </EntitySetMapping>
  663. <EntitySetMapping Name="PaymentMetod">
  664. <EntityTypeMapping TypeName="gr672_pgvModel.PaymentMetod">
  665. <MappingFragment StoreEntitySet="PaymentMetod">
  666. <ScalarProperty Name="PaymentMetodID" ColumnName="PaymentMetodID" />
  667. <ScalarProperty Name="PaymentMetodName" ColumnName="PaymentMetodName" />
  668. </MappingFragment>
  669. </EntityTypeMapping>
  670. </EntitySetMapping>
  671. <EntitySetMapping Name="PaymentOrder">
  672. <EntityTypeMapping TypeName="gr672_pgvModel.PaymentOrder">
  673. <MappingFragment StoreEntitySet="PaymentOrder">
  674. <ScalarProperty Name="PaymentID" ColumnName="PaymentID" />
  675. <ScalarProperty Name="IDPaymentMetod" ColumnName="IDPaymentMetod" />
  676. <ScalarProperty Name="IDOrder" ColumnName="IDOrder" />
  677. </MappingFragment>
  678. </EntityTypeMapping>
  679. </EntitySetMapping>
  680. <EntitySetMapping Name="Product">
  681. <EntityTypeMapping TypeName="gr672_pgvModel.Product">
  682. <MappingFragment StoreEntitySet="Product">
  683. <ScalarProperty Name="ProductID" ColumnName="ProductID" />
  684. <ScalarProperty Name="NameProduct" ColumnName="NameProduct" />
  685. <ScalarProperty Name="Weight" ColumnName="Weight" />
  686. <ScalarProperty Name="Packaging" ColumnName="Packaging" />
  687. <ScalarProperty Name="PriceOfOne" ColumnName="PriceOfOne" />
  688. <ScalarProperty Name="BarCode" ColumnName="BarCode" />
  689. </MappingFragment>
  690. </EntityTypeMapping>
  691. </EntitySetMapping>
  692. <EntitySetMapping Name="ProductInOrder">
  693. <EntityTypeMapping TypeName="gr672_pgvModel.ProductInOrder">
  694. <MappingFragment StoreEntitySet="ProductInOrder">
  695. <ScalarProperty Name="IDOrder" ColumnName="IDOrder" />
  696. <ScalarProperty Name="IDProduct" ColumnName="IDProduct" />
  697. <ScalarProperty Name="AmountProduct" ColumnName="AmountProduct" />
  698. </MappingFragment>
  699. </EntityTypeMapping>
  700. </EntitySetMapping>
  701. <EntitySetMapping Name="ProductInStore">
  702. <EntityTypeMapping TypeName="gr672_pgvModel.ProductInStore">
  703. <MappingFragment StoreEntitySet="ProductInStore">
  704. <ScalarProperty Name="ProductInStoreID" ColumnName="ProductInStoreID" />
  705. <ScalarProperty Name="IDStore" ColumnName="IDStore" />
  706. <ScalarProperty Name="IDProduct" ColumnName="IDProduct" />
  707. <ScalarProperty Name="RemainsProduct" ColumnName="RemainsProduct" />
  708. </MappingFragment>
  709. </EntityTypeMapping>
  710. </EntitySetMapping>
  711. <EntitySetMapping Name="Store">
  712. <EntityTypeMapping TypeName="gr672_pgvModel.Store">
  713. <MappingFragment StoreEntitySet="Store">
  714. <ScalarProperty Name="StoreID" ColumnName="StoreID" />
  715. <ScalarProperty Name="Address" ColumnName="Address" />
  716. </MappingFragment>
  717. </EntityTypeMapping>
  718. </EntitySetMapping>
  719. <EntitySetMapping Name="WorkShift">
  720. <EntityTypeMapping TypeName="gr672_pgvModel.WorkShift">
  721. <MappingFragment StoreEntitySet="WorkShift">
  722. <ScalarProperty Name="WorkShiftID" ColumnName="WorkShiftID" />
  723. <ScalarProperty Name="IDCashier" ColumnName="IDCashier" />
  724. <ScalarProperty Name="IDEmployee" ColumnName="IDEmployee" />
  725. <ScalarProperty Name="StartDateAndTimeWork" ColumnName="StartDateAndTimeWork" />
  726. <ScalarProperty Name="EndDateAndTimeWork" ColumnName="EndDateAndTimeWork" />
  727. </MappingFragment>
  728. </EntityTypeMapping>
  729. </EntitySetMapping>
  730. <EntitySetMapping Name="Cashier">
  731. <EntityTypeMapping TypeName="gr672_pgvModel.Cashier">
  732. <MappingFragment StoreEntitySet="Cashier">
  733. <ScalarProperty Name="IDStore" ColumnName="IDStore" />
  734. <ScalarProperty Name="CashierID" ColumnName="CashierID" />
  735. </MappingFragment>
  736. </EntityTypeMapping>
  737. </EntitySetMapping>
  738. <EntitySetMapping Name="EmployeeInStore">
  739. <EntityTypeMapping TypeName="gr672_pgvModel.EmployeeInStore">
  740. <MappingFragment StoreEntitySet="EmployeeInStore">
  741. <ScalarProperty Name="IDEmployeeInStore" ColumnName="IDEmployeeInStore" />
  742. <ScalarProperty Name="IDEmployee" ColumnName="IDEmployee" />
  743. <ScalarProperty Name="IDStore" ColumnName="IDStore" />
  744. </MappingFragment>
  745. </EntityTypeMapping>
  746. </EntitySetMapping>
  747. </EntityContainerMapping>
  748. </Mapping>
  749. </edmx:Mappings>
  750. </edmx:Runtime>
  751. <!-- EF Designer content (DO NOT EDIT MANUALLY BELOW HERE) -->
  752. <Designer xmlns="http://schemas.microsoft.com/ado/2009/11/edmx">
  753. <Connection>
  754. <DesignerInfoPropertySet>
  755. <DesignerProperty Name="MetadataArtifactProcessing" Value="EmbedInOutputAssembly" />
  756. </DesignerInfoPropertySet>
  757. </Connection>
  758. <Options>
  759. <DesignerInfoPropertySet>
  760. <DesignerProperty Name="ValidateOnBuild" Value="true" />
  761. <DesignerProperty Name="EnablePluralization" Value="false" />
  762. <DesignerProperty Name="IncludeForeignKeysInModel" Value="true" />
  763. <DesignerProperty Name="UseLegacyProvider" Value="false" />
  764. <DesignerProperty Name="CodeGenerationStrategy" Value="None" />
  765. </DesignerInfoPropertySet>
  766. </Options>
  767. <!-- Diagram content (shape and connector positions) -->
  768. <Diagrams></Diagrams>
  769. </Designer>
  770. </edmx:Edmx>