20211130035103_Init02.Designer.cs 123 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324
  1. // <auto-generated />
  2. using System;
  3. using Microsoft.EntityFrameworkCore;
  4. using Microsoft.EntityFrameworkCore.Infrastructure;
  5. using Microsoft.EntityFrameworkCore.Migrations;
  6. using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
  7. using Ropin.Inspection.Model.Entities;
  8. namespace Ropin.Inspection.Model.Migrations
  9. {
  10. [DbContext(typeof(InspectionDbContext))]
  11. [Migration("20211130035103_Init02")]
  12. partial class Init02
  13. {
  14. protected override void BuildTargetModel(ModelBuilder modelBuilder)
  15. {
  16. #pragma warning disable 612, 618
  17. modelBuilder
  18. .HasAnnotation("Relational:MaxIdentifierLength", 64)
  19. .HasAnnotation("ProductVersion", "5.0.4");
  20. modelBuilder.Entity("Ropin.Inspection.Model.Entities.Report", b =>
  21. {
  22. b.Property<Guid>("G_ID")
  23. .ValueGeneratedOnAdd()
  24. .HasColumnType("char(36)");
  25. b.Property<string>("C_Data")
  26. .HasColumnType("longtext CHARACTER SET utf8mb4");
  27. b.Property<string>("C_GroupName")
  28. .HasColumnType("longtext CHARACTER SET utf8mb4");
  29. b.Property<string>("C_Name")
  30. .HasColumnType("longtext CHARACTER SET utf8mb4");
  31. b.Property<string>("C_Remark")
  32. .HasColumnType("longtext CHARACTER SET utf8mb4");
  33. b.Property<string>("C_Status")
  34. .HasColumnType("longtext CHARACTER SET utf8mb4");
  35. b.Property<DateTime>("D_CreateTime")
  36. .HasColumnType("datetime(6)");
  37. b.Property<DateTime>("D_End")
  38. .HasColumnType("datetime(6)");
  39. b.Property<DateTime>("D_Start")
  40. .HasColumnType("datetime(6)");
  41. b.Property<int>("I_Type")
  42. .HasColumnType("int");
  43. b.HasKey("G_ID");
  44. b.ToTable("Report");
  45. });
  46. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TBDM_Area", b =>
  47. {
  48. b.Property<string>("C_Code")
  49. .HasMaxLength(20)
  50. .HasColumnType("varchar(20) CHARACTER SET utf8mb4");
  51. b.Property<string>("C_CityCode")
  52. .IsRequired()
  53. .HasMaxLength(20)
  54. .HasColumnType("varchar(20) CHARACTER SET utf8mb4");
  55. b.Property<string>("C_Name")
  56. .IsRequired()
  57. .HasMaxLength(50)
  58. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  59. b.Property<string>("C_Status")
  60. .IsRequired()
  61. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  62. b.Property<int>("I_Sort")
  63. .HasColumnType("int");
  64. b.HasKey("C_Code");
  65. b.HasIndex("C_CityCode");
  66. b.ToTable("TBDM_Area");
  67. });
  68. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TBDM_City", b =>
  69. {
  70. b.Property<string>("C_Code")
  71. .HasMaxLength(20)
  72. .HasColumnType("varchar(20) CHARACTER SET utf8mb4");
  73. b.Property<string>("C_Name")
  74. .IsRequired()
  75. .HasMaxLength(50)
  76. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  77. b.Property<string>("C_ProvCode")
  78. .IsRequired()
  79. .HasMaxLength(20)
  80. .HasColumnType("varchar(20) CHARACTER SET utf8mb4");
  81. b.Property<string>("C_Status")
  82. .IsRequired()
  83. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  84. b.Property<int>("I_Sort")
  85. .HasColumnType("int");
  86. b.HasKey("C_Code");
  87. b.HasIndex("C_ProvCode");
  88. b.ToTable("TBDM_City");
  89. });
  90. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TBDM_CodeDetail", b =>
  91. {
  92. b.Property<string>("C_Code")
  93. .HasMaxLength(50)
  94. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  95. b.Property<Guid>("C_CreateBy")
  96. .HasColumnType("char(36)");
  97. b.Property<string>("C_Default")
  98. .IsRequired()
  99. .HasMaxLength(1)
  100. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  101. b.Property<string>("C_IsSys")
  102. .IsRequired()
  103. .HasMaxLength(1)
  104. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  105. b.Property<Guid?>("C_LastUpdatedBy")
  106. .HasColumnType("char(36)");
  107. b.Property<string>("C_MainCode")
  108. .IsRequired()
  109. .HasMaxLength(50)
  110. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  111. b.Property<string>("C_Name")
  112. .IsRequired()
  113. .HasMaxLength(50)
  114. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  115. b.Property<string>("C_Remark")
  116. .HasMaxLength(500)
  117. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  118. b.Property<string>("C_Status")
  119. .IsRequired()
  120. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  121. b.Property<string>("C_Value")
  122. .IsRequired()
  123. .HasMaxLength(255)
  124. .HasColumnType("varchar(255) CHARACTER SET utf8mb4");
  125. b.Property<DateTime>("D_CreateOn")
  126. .HasColumnType("datetime(6)");
  127. b.Property<DateTime?>("D_LastUpdatedOn")
  128. .HasColumnType("datetime(6)");
  129. b.Property<int>("I_Sort")
  130. .HasColumnType("int");
  131. b.HasKey("C_Code");
  132. b.HasIndex("C_CreateBy");
  133. b.HasIndex("C_LastUpdatedBy");
  134. b.ToTable("TBDM_CodeDetail");
  135. });
  136. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TBDM_CodeMain", b =>
  137. {
  138. b.Property<string>("C_Code")
  139. .HasMaxLength(50)
  140. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  141. b.Property<Guid>("C_CreateBy")
  142. .HasColumnType("char(36)");
  143. b.Property<Guid?>("C_LastUpdatedBy")
  144. .HasColumnType("char(36)");
  145. b.Property<string>("C_Name")
  146. .IsRequired()
  147. .HasMaxLength(50)
  148. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  149. b.Property<string>("C_Remark")
  150. .HasMaxLength(500)
  151. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  152. b.Property<string>("C_Status")
  153. .IsRequired()
  154. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  155. b.Property<DateTime>("D_CreateOn")
  156. .HasColumnType("datetime(6)");
  157. b.Property<DateTime?>("D_LastUpdatedOn")
  158. .HasColumnType("datetime(6)");
  159. b.Property<int>("I_Sort")
  160. .HasColumnType("int");
  161. b.HasKey("C_Code");
  162. b.HasIndex("C_CreateBy");
  163. b.HasIndex("C_LastUpdatedBy");
  164. b.ToTable("TBDM_CodeMain");
  165. });
  166. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TBDM_Prov", b =>
  167. {
  168. b.Property<string>("C_Code")
  169. .HasMaxLength(20)
  170. .HasColumnType("varchar(20) CHARACTER SET utf8mb4");
  171. b.Property<string>("C_Name")
  172. .IsRequired()
  173. .HasMaxLength(50)
  174. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  175. b.Property<string>("C_Status")
  176. .IsRequired()
  177. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  178. b.Property<int>("I_Sort")
  179. .HasColumnType("int");
  180. b.HasKey("C_Code");
  181. b.ToTable("TBDM_Prov");
  182. });
  183. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TDEV_DevAlert", b =>
  184. {
  185. b.Property<Guid>("C_ID")
  186. .ValueGeneratedOnAdd()
  187. .HasColumnType("char(36)");
  188. b.Property<string>("C_ConfigCode")
  189. .IsRequired()
  190. .HasMaxLength(50)
  191. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  192. b.Property<string>("C_DeviceCode")
  193. .IsRequired()
  194. .HasMaxLength(50)
  195. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  196. b.Property<string>("C_Value")
  197. .IsRequired()
  198. .HasMaxLength(100)
  199. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  200. b.Property<DateTime>("D_CreateOn")
  201. .HasColumnType("datetime(6)");
  202. b.HasKey("C_ID");
  203. b.ToTable("TDEV_DevAlert");
  204. });
  205. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TDEV_DevAlertConfig", b =>
  206. {
  207. b.Property<string>("C_Code")
  208. .HasMaxLength(50)
  209. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  210. b.Property<Guid>("C_CreateBy")
  211. .HasColumnType("char(36)");
  212. b.Property<Guid?>("C_LastUpdatedBy")
  213. .HasColumnType("char(36)");
  214. b.Property<string>("C_Name")
  215. .IsRequired()
  216. .HasMaxLength(50)
  217. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  218. b.Property<string>("C_Remark")
  219. .HasMaxLength(1024)
  220. .HasColumnType("varchar(1024) CHARACTER SET utf8mb4");
  221. b.Property<string>("C_Status")
  222. .IsRequired()
  223. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  224. b.Property<DateTime>("D_CreateOn")
  225. .HasColumnType("datetime(6)");
  226. b.Property<DateTime?>("D_LastUpdatedOn")
  227. .HasColumnType("datetime(6)");
  228. b.HasKey("C_Code");
  229. b.HasIndex("C_CreateBy");
  230. b.HasIndex("C_LastUpdatedBy");
  231. b.ToTable("TDEV_DevAlertConfig");
  232. });
  233. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TDEV_DevData", b =>
  234. {
  235. b.Property<Guid>("C_ID")
  236. .ValueGeneratedOnAdd()
  237. .HasColumnType("char(36)");
  238. b.Property<string>("C_ConfigCode")
  239. .IsRequired()
  240. .HasMaxLength(50)
  241. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  242. b.Property<string>("C_DeviceCode")
  243. .IsRequired()
  244. .HasMaxLength(50)
  245. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  246. b.Property<string>("C_Value")
  247. .IsRequired()
  248. .HasMaxLength(50)
  249. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  250. b.Property<DateTime>("D_CreateOn")
  251. .HasColumnType("datetime(6)");
  252. b.HasKey("C_ID");
  253. b.ToTable("TDEV_DevData");
  254. });
  255. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TDEV_DevDataConfig", b =>
  256. {
  257. b.Property<string>("C_Code")
  258. .HasMaxLength(50)
  259. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  260. b.Property<Guid>("C_CreateBy")
  261. .HasColumnType("char(36)");
  262. b.Property<Guid?>("C_LastUpdatedBy")
  263. .HasColumnType("char(36)");
  264. b.Property<string>("C_Name")
  265. .IsRequired()
  266. .HasMaxLength(50)
  267. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  268. b.Property<string>("C_Remark")
  269. .HasMaxLength(1024)
  270. .HasColumnType("varchar(1024) CHARACTER SET utf8mb4");
  271. b.Property<string>("C_Status")
  272. .IsRequired()
  273. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  274. b.Property<DateTime>("D_CreateOn")
  275. .HasColumnType("datetime(6)");
  276. b.Property<DateTime?>("D_LastUpdatedOn")
  277. .HasColumnType("datetime(6)");
  278. b.Property<int>("I_Interval")
  279. .HasColumnType("int");
  280. b.HasKey("C_Code");
  281. b.HasIndex("C_CreateBy");
  282. b.HasIndex("C_LastUpdatedBy");
  283. b.ToTable("TDEV_DevDataConfig");
  284. });
  285. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TDEV_Device", b =>
  286. {
  287. b.Property<Guid>("C_Code")
  288. .ValueGeneratedOnAdd()
  289. .HasColumnType("char(36)");
  290. b.Property<Guid>("C_CreateBy")
  291. .HasColumnType("char(36)");
  292. b.Property<Guid?>("C_LastUpdatedBy")
  293. .HasColumnType("char(36)");
  294. b.Property<string>("C_MachineCode")
  295. .HasMaxLength(255)
  296. .HasColumnType("varchar(255) CHARACTER SET utf8mb4");
  297. b.Property<string>("C_ProductCode")
  298. .IsRequired()
  299. .HasMaxLength(50)
  300. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  301. b.Property<string>("C_Remark")
  302. .HasMaxLength(1024)
  303. .HasColumnType("varchar(1024) CHARACTER SET utf8mb4");
  304. b.Property<DateTime>("D_CreateOn")
  305. .HasColumnType("datetime(6)");
  306. b.Property<DateTime?>("D_LastUpdatedOn")
  307. .HasColumnType("datetime(6)");
  308. b.Property<int>("I_Status")
  309. .HasColumnType("int");
  310. b.HasKey("C_Code");
  311. b.HasIndex("C_CreateBy");
  312. b.HasIndex("C_LastUpdatedBy");
  313. b.ToTable("TDEV_Device");
  314. });
  315. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_Content", b =>
  316. {
  317. b.Property<Guid>("C_ID")
  318. .ValueGeneratedOnAdd()
  319. .HasColumnType("char(36)");
  320. b.Property<string>("C_AlarmLevel")
  321. .IsRequired()
  322. .HasMaxLength(1)
  323. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  324. b.Property<Guid>("C_CreateBy")
  325. .HasColumnType("char(36)");
  326. b.Property<Guid>("C_LastUpdatedBy")
  327. .HasColumnType("char(36)");
  328. b.Property<string>("C_Name")
  329. .IsRequired()
  330. .HasMaxLength(50)
  331. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  332. b.Property<string>("C_Remark")
  333. .HasMaxLength(500)
  334. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  335. b.Property<string>("C_Status")
  336. .HasColumnType("longtext CHARACTER SET utf8mb4");
  337. b.Property<DateTime>("D_CreateOn")
  338. .HasColumnType("datetime(6)");
  339. b.Property<DateTime>("D_LastUpdatedOn")
  340. .HasColumnType("datetime(6)");
  341. b.HasKey("C_ID");
  342. b.HasIndex("C_CreateBy");
  343. b.HasIndex("C_LastUpdatedBy");
  344. b.ToTable("TISP_Content");
  345. });
  346. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_ContentGroup", b =>
  347. {
  348. b.Property<Guid>("G_ID")
  349. .ValueGeneratedOnAdd()
  350. .HasColumnType("char(36)");
  351. b.Property<string>("C_Name")
  352. .IsRequired()
  353. .HasMaxLength(50)
  354. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  355. b.Property<string>("C_PatrolItem")
  356. .HasMaxLength(50)
  357. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  358. b.Property<string>("C_Remark")
  359. .HasMaxLength(500)
  360. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  361. b.Property<string>("C_Status")
  362. .IsRequired()
  363. .HasMaxLength(1)
  364. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  365. b.Property<DateTime>("D_CreateOn")
  366. .HasColumnType("datetime(6)");
  367. b.Property<DateTime>("D_LastUpdatedOn")
  368. .HasColumnType("datetime(6)");
  369. b.Property<Guid>("G_CreateBy")
  370. .HasColumnType("char(36)");
  371. b.Property<Guid>("G_LastUpdatedBy")
  372. .HasColumnType("char(36)");
  373. b.Property<int>("I_Sort")
  374. .HasColumnType("int");
  375. b.Property<int>("I_Type")
  376. .HasColumnType("int");
  377. b.HasKey("G_ID");
  378. b.HasIndex("G_CreateBy");
  379. b.HasIndex("G_LastUpdatedBy");
  380. b.ToTable("TISP_ContentGroup");
  381. });
  382. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_ContentGroupItem", b =>
  383. {
  384. b.Property<Guid>("G_ID")
  385. .ValueGeneratedOnAdd()
  386. .HasColumnType("char(36)");
  387. b.Property<Guid>("G_ContentCode")
  388. .HasColumnType("char(36)");
  389. b.Property<Guid>("G_ContentGroupCode")
  390. .HasColumnType("char(36)");
  391. b.HasKey("G_ID");
  392. b.HasIndex("G_ContentCode");
  393. b.HasIndex("G_ContentGroupCode");
  394. b.ToTable("TISP_ContentGroupItem");
  395. });
  396. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_Record", b =>
  397. {
  398. b.Property<Guid>("C_ID")
  399. .ValueGeneratedOnAdd()
  400. .HasColumnType("char(36)");
  401. b.Property<Guid>("C_CreateBy")
  402. .HasColumnType("char(36)");
  403. b.Property<Guid>("C_LastUpdatedBy")
  404. .HasColumnType("char(36)");
  405. b.Property<Guid>("C_SpotCode")
  406. .HasColumnType("char(36)");
  407. b.Property<string>("C_Status")
  408. .IsRequired()
  409. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  410. b.Property<DateTime>("D_CreateOn")
  411. .HasColumnType("datetime(6)");
  412. b.Property<DateTime>("D_LastUpdatedOn")
  413. .HasColumnType("datetime(6)");
  414. b.HasKey("C_ID");
  415. b.HasIndex("C_CreateBy");
  416. b.HasIndex("C_LastUpdatedBy");
  417. b.HasIndex("C_SpotCode");
  418. b.ToTable("TISP_Record");
  419. });
  420. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_RecordAlarm", b =>
  421. {
  422. b.Property<Guid>("C_ID")
  423. .ValueGeneratedOnAdd()
  424. .HasColumnType("char(36)");
  425. b.Property<Guid>("C_InspectionRecordCode")
  426. .HasColumnType("char(36)");
  427. b.Property<Guid>("C_SpotContentCode")
  428. .HasColumnType("char(36)");
  429. b.Property<string>("C_Status")
  430. .IsRequired()
  431. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  432. b.HasKey("C_ID");
  433. b.ToTable("TISP_RecordAlarm");
  434. });
  435. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_RecordImage", b =>
  436. {
  437. b.Property<Guid>("C_ID")
  438. .ValueGeneratedOnAdd()
  439. .HasColumnType("char(36)");
  440. b.Property<string>("C_ImageURL")
  441. .IsRequired()
  442. .HasMaxLength(200)
  443. .HasColumnType("varchar(200) CHARACTER SET utf8mb4");
  444. b.Property<Guid>("C_RecordItemCode")
  445. .HasColumnType("char(36)");
  446. b.Property<string>("C_Status")
  447. .IsRequired()
  448. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  449. b.HasKey("C_ID");
  450. b.HasIndex("C_RecordItemCode");
  451. b.ToTable("TISP_RecordImage");
  452. });
  453. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_RecordItem", b =>
  454. {
  455. b.Property<Guid>("C_ID")
  456. .ValueGeneratedOnAdd()
  457. .HasColumnType("char(36)");
  458. b.Property<Guid>("C_ContentCode")
  459. .HasColumnType("char(36)");
  460. b.Property<Guid>("C_CreateBy")
  461. .HasMaxLength(50)
  462. .HasColumnType("char(50)");
  463. b.Property<string>("C_InspectionContent")
  464. .HasColumnType("longtext CHARACTER SET utf8mb4");
  465. b.Property<Guid>("C_LastUpdatedBy")
  466. .HasMaxLength(50)
  467. .HasColumnType("char(50)");
  468. b.Property<Guid>("C_RecordCode")
  469. .HasColumnType("char(36)");
  470. b.Property<string>("C_Remark")
  471. .HasColumnType("longtext CHARACTER SET utf8mb4");
  472. b.Property<string>("C_Status")
  473. .IsRequired()
  474. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  475. b.Property<DateTime>("D_CreateOn")
  476. .HasColumnType("datetime(6)");
  477. b.Property<DateTime>("D_LastUpdatedOn")
  478. .HasColumnType("datetime(6)");
  479. b.HasKey("C_ID");
  480. b.HasIndex("C_ContentCode");
  481. b.HasIndex("C_CreateBy");
  482. b.HasIndex("C_LastUpdatedBy");
  483. b.HasIndex("C_RecordCode");
  484. b.ToTable("TISP_RecordItem");
  485. });
  486. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_Region", b =>
  487. {
  488. b.Property<Guid>("C_ID")
  489. .ValueGeneratedOnAdd()
  490. .HasColumnType("char(36)");
  491. b.Property<Guid>("C_CreateBy")
  492. .HasMaxLength(50)
  493. .HasColumnType("char(50)");
  494. b.Property<string>("C_ImageUrl")
  495. .HasMaxLength(100)
  496. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  497. b.Property<Guid>("C_LastUpdatedBy")
  498. .HasMaxLength(50)
  499. .HasColumnType("char(50)");
  500. b.Property<string>("C_Name")
  501. .IsRequired()
  502. .HasMaxLength(50)
  503. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  504. b.Property<string>("C_Remark")
  505. .HasMaxLength(500)
  506. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  507. b.Property<string>("C_Status")
  508. .IsRequired()
  509. .HasMaxLength(1)
  510. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  511. b.Property<DateTime>("D_CreateOn")
  512. .HasColumnType("datetime(6)");
  513. b.Property<DateTime>("D_LastUpdatedOn")
  514. .HasColumnType("datetime(6)");
  515. b.HasKey("C_ID");
  516. b.HasIndex("C_CreateBy");
  517. b.HasIndex("C_LastUpdatedBy");
  518. b.ToTable("TISP_Region");
  519. });
  520. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_Route", b =>
  521. {
  522. b.Property<Guid>("C_ID")
  523. .ValueGeneratedOnAdd()
  524. .HasColumnType("char(36)");
  525. b.Property<Guid>("C_CreateBy")
  526. .HasMaxLength(50)
  527. .HasColumnType("char(50)");
  528. b.Property<string>("C_ImageUrl")
  529. .HasMaxLength(100)
  530. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  531. b.Property<Guid>("C_LastUpdatedBy")
  532. .HasMaxLength(50)
  533. .HasColumnType("char(50)");
  534. b.Property<string>("C_Name")
  535. .IsRequired()
  536. .HasMaxLength(50)
  537. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  538. b.Property<string>("C_Remark")
  539. .HasMaxLength(500)
  540. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  541. b.Property<string>("C_Status")
  542. .IsRequired()
  543. .HasMaxLength(1)
  544. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  545. b.Property<DateTime>("D_CreateOn")
  546. .HasColumnType("datetime(6)");
  547. b.Property<DateTime>("D_LastUpdatedOn")
  548. .HasColumnType("datetime(6)");
  549. b.HasKey("C_ID");
  550. b.HasIndex("C_CreateBy");
  551. b.HasIndex("C_LastUpdatedBy");
  552. b.ToTable("TISP_Route");
  553. });
  554. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_Spot", b =>
  555. {
  556. b.Property<Guid>("C_Code")
  557. .ValueGeneratedOnAdd()
  558. .HasColumnType("char(36)");
  559. b.Property<Guid>("C_CreateBy")
  560. .HasMaxLength(50)
  561. .HasColumnType("char(50)");
  562. b.Property<string>("C_GPS")
  563. .HasMaxLength(50)
  564. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  565. b.Property<string>("C_ImageUrl")
  566. .HasMaxLength(100)
  567. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  568. b.Property<Guid>("C_LastUpdatedBy")
  569. .HasMaxLength(50)
  570. .HasColumnType("char(50)");
  571. b.Property<string>("C_Name")
  572. .IsRequired()
  573. .HasMaxLength(50)
  574. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  575. b.Property<string>("C_Number")
  576. .IsRequired()
  577. .HasMaxLength(50)
  578. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  579. b.Property<string>("C_Position")
  580. .HasMaxLength(100)
  581. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  582. b.Property<string>("C_QRCode")
  583. .HasMaxLength(100)
  584. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  585. b.Property<string>("C_Remark")
  586. .HasMaxLength(500)
  587. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  588. b.Property<string>("C_Status")
  589. .IsRequired()
  590. .HasMaxLength(1)
  591. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  592. b.Property<DateTime>("D_CreateOn")
  593. .HasColumnType("datetime(6)");
  594. b.Property<DateTime>("D_LastUpdatedOn")
  595. .HasColumnType("datetime(6)");
  596. b.Property<int>("I_Offset")
  597. .HasColumnType("int");
  598. b.HasKey("C_Code");
  599. b.HasIndex("C_CreateBy");
  600. b.HasIndex("C_LastUpdatedBy");
  601. b.ToTable("TISP_Spot");
  602. });
  603. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_SpotContent", b =>
  604. {
  605. b.Property<Guid>("C_ID")
  606. .ValueGeneratedOnAdd()
  607. .HasColumnType("char(36)");
  608. b.Property<Guid>("C_ContentCode")
  609. .HasColumnType("char(36)");
  610. b.Property<Guid>("C_CreateBy")
  611. .HasColumnType("char(36)");
  612. b.Property<Guid>("C_LastUpdatedBy")
  613. .HasColumnType("char(36)");
  614. b.Property<string>("C_Remark")
  615. .HasMaxLength(500)
  616. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  617. b.Property<Guid>("C_SpotCode")
  618. .HasColumnType("char(36)");
  619. b.Property<string>("C_Status")
  620. .IsRequired()
  621. .HasMaxLength(1)
  622. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  623. b.Property<DateTime>("D_CreateOn")
  624. .HasColumnType("datetime(6)");
  625. b.Property<DateTime>("D_LastUpdatedOn")
  626. .HasColumnType("datetime(6)");
  627. b.HasKey("C_ID");
  628. b.HasIndex("C_ContentCode");
  629. b.HasIndex("C_CreateBy");
  630. b.HasIndex("C_LastUpdatedBy");
  631. b.HasIndex("C_SpotCode");
  632. b.ToTable("TISP_SpotContent");
  633. });
  634. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_SpotRegion", b =>
  635. {
  636. b.Property<Guid>("C_ID")
  637. .ValueGeneratedOnAdd()
  638. .HasColumnType("char(36)");
  639. b.Property<Guid>("C_CreateBy")
  640. .HasColumnType("char(36)");
  641. b.Property<Guid>("C_LastUpdatedBy")
  642. .HasColumnType("char(36)");
  643. b.Property<Guid>("C_RegionCode")
  644. .HasColumnType("char(36)");
  645. b.Property<string>("C_Remark")
  646. .HasMaxLength(500)
  647. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  648. b.Property<Guid>("C_SpotCode")
  649. .HasColumnType("char(36)");
  650. b.Property<string>("C_Status")
  651. .IsRequired()
  652. .HasMaxLength(1)
  653. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  654. b.Property<DateTime>("D_CreateOn")
  655. .HasColumnType("datetime(6)");
  656. b.Property<DateTime>("D_LastUpdatedOn")
  657. .HasColumnType("datetime(6)");
  658. b.HasKey("C_ID");
  659. b.HasIndex("C_CreateBy");
  660. b.HasIndex("C_LastUpdatedBy");
  661. b.HasIndex("C_RegionCode");
  662. b.HasIndex("C_SpotCode");
  663. b.ToTable("TISP_SpotRegion");
  664. });
  665. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_SpotRoute", b =>
  666. {
  667. b.Property<Guid>("C_ID")
  668. .ValueGeneratedOnAdd()
  669. .HasColumnType("char(36)");
  670. b.Property<Guid>("C_CreateBy")
  671. .HasColumnType("char(36)");
  672. b.Property<Guid>("C_LastUpdatedBy")
  673. .HasColumnType("char(36)");
  674. b.Property<string>("C_Remark")
  675. .HasMaxLength(500)
  676. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  677. b.Property<Guid>("C_RouteCode")
  678. .HasColumnType("char(36)");
  679. b.Property<Guid>("C_SpotCode")
  680. .HasColumnType("char(36)");
  681. b.Property<string>("C_Status")
  682. .IsRequired()
  683. .HasMaxLength(1)
  684. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  685. b.Property<DateTime>("D_CreateOn")
  686. .HasColumnType("datetime(6)");
  687. b.Property<DateTime>("D_LastUpdatedOn")
  688. .HasColumnType("datetime(6)");
  689. b.HasKey("C_ID");
  690. b.HasIndex("C_CreateBy");
  691. b.HasIndex("C_LastUpdatedBy");
  692. b.HasIndex("C_RouteCode");
  693. b.HasIndex("C_SpotCode");
  694. b.ToTable("TISP_SpotRoute");
  695. });
  696. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_SpotUser", b =>
  697. {
  698. b.Property<Guid>("C_ID")
  699. .ValueGeneratedOnAdd()
  700. .HasColumnType("char(36)");
  701. b.Property<Guid>("C_CreateBy")
  702. .HasColumnType("char(36)");
  703. b.Property<Guid>("C_LastUpdatedBy")
  704. .HasColumnType("char(36)");
  705. b.Property<string>("C_Remark")
  706. .HasMaxLength(500)
  707. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  708. b.Property<Guid>("C_SpotCode")
  709. .HasColumnType("char(36)");
  710. b.Property<string>("C_Status")
  711. .IsRequired()
  712. .HasMaxLength(1)
  713. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  714. b.Property<Guid>("C_UserCode")
  715. .HasColumnType("char(36)");
  716. b.Property<DateTime>("D_CreateOn")
  717. .HasColumnType("datetime(6)");
  718. b.Property<DateTime>("D_LastUpdatedOn")
  719. .HasColumnType("datetime(6)");
  720. b.HasKey("C_ID");
  721. b.HasIndex("C_CreateBy");
  722. b.HasIndex("C_LastUpdatedBy");
  723. b.HasIndex("C_SpotCode");
  724. b.HasIndex("C_UserCode");
  725. b.ToTable("TISP_SpotUser");
  726. });
  727. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TPNT_Area", b =>
  728. {
  729. b.Property<Guid>("C_Code")
  730. .ValueGeneratedOnAdd()
  731. .HasColumnType("char(36)");
  732. b.Property<Guid>("C_CreateBy")
  733. .HasColumnType("char(36)");
  734. b.Property<string>("C_ImageUrl")
  735. .HasMaxLength(255)
  736. .HasColumnType("varchar(255) CHARACTER SET utf8mb4");
  737. b.Property<Guid?>("C_LastUpdatedBy")
  738. .HasColumnType("char(36)");
  739. b.Property<string>("C_Name")
  740. .IsRequired()
  741. .HasMaxLength(255)
  742. .HasColumnType("varchar(255) CHARACTER SET utf8mb4");
  743. b.Property<string>("C_Remark")
  744. .HasMaxLength(1024)
  745. .HasColumnType("varchar(1024) CHARACTER SET utf8mb4");
  746. b.Property<string>("C_SName")
  747. .HasMaxLength(16)
  748. .HasColumnType("varchar(16) CHARACTER SET utf8mb4");
  749. b.Property<string>("C_Status")
  750. .IsRequired()
  751. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  752. b.Property<Guid>("C_StoreCode")
  753. .HasColumnType("char(36)");
  754. b.Property<DateTime>("D_CreateOn")
  755. .HasColumnType("datetime(6)");
  756. b.Property<DateTime?>("D_LastUpdatedOn")
  757. .HasColumnType("datetime(6)");
  758. b.Property<int>("I_Sort")
  759. .HasColumnType("int");
  760. b.HasKey("C_Code");
  761. b.HasIndex("C_CreateBy");
  762. b.HasIndex("C_LastUpdatedBy");
  763. b.HasIndex("C_StoreCode");
  764. b.ToTable("TPNT_Area");
  765. });
  766. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TPNT_Store", b =>
  767. {
  768. b.Property<Guid>("C_ID")
  769. .ValueGeneratedOnAdd()
  770. .HasColumnType("char(36)");
  771. b.Property<string>("C_Address")
  772. .HasMaxLength(50)
  773. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  774. b.Property<string>("C_AreaCode")
  775. .HasMaxLength(50)
  776. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  777. b.Property<string>("C_Code")
  778. .IsRequired()
  779. .HasMaxLength(50)
  780. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  781. b.Property<Guid>("C_CreateBy")
  782. .HasColumnType("char(36)");
  783. b.Property<string>("C_GPS")
  784. .HasMaxLength(50)
  785. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  786. b.Property<Guid?>("C_LastUpdatedBy")
  787. .HasColumnType("char(36)");
  788. b.Property<string>("C_LicenseCode")
  789. .IsRequired()
  790. .HasMaxLength(50)
  791. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  792. b.Property<string>("C_Name")
  793. .IsRequired()
  794. .HasMaxLength(255)
  795. .HasColumnType("varchar(255) CHARACTER SET utf8mb4");
  796. b.Property<string>("C_Remark")
  797. .HasMaxLength(500)
  798. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  799. b.Property<string>("C_SName")
  800. .HasMaxLength(16)
  801. .HasColumnType("varchar(16) CHARACTER SET utf8mb4");
  802. b.Property<string>("C_Status")
  803. .IsRequired()
  804. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  805. b.Property<Guid>("C_TypeCode")
  806. .HasColumnType("char(36)");
  807. b.Property<DateTime>("D_CreateOn")
  808. .HasColumnType("datetime(6)");
  809. b.Property<DateTime?>("D_LastUpdatedOn")
  810. .HasColumnType("datetime(6)");
  811. b.Property<int>("I_Sort")
  812. .HasColumnType("int");
  813. b.Property<Guid?>("LicenseC_ID")
  814. .HasColumnType("char(36)");
  815. b.Property<Guid?>("StoreOrgC_OrgCode")
  816. .HasColumnType("char(36)");
  817. b.Property<string>("StoreOrgC_StoreCode")
  818. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  819. b.HasKey("C_ID");
  820. b.HasIndex("C_AreaCode");
  821. b.HasIndex("C_Code")
  822. .IsUnique();
  823. b.HasIndex("C_CreateBy");
  824. b.HasIndex("C_LastUpdatedBy");
  825. b.HasIndex("C_TypeCode");
  826. b.HasIndex("LicenseC_ID");
  827. b.HasIndex("StoreOrgC_StoreCode", "StoreOrgC_OrgCode");
  828. b.ToTable("TPNT_Store");
  829. });
  830. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TPNT_StoreOrg", b =>
  831. {
  832. b.Property<string>("C_StoreCode")
  833. .HasMaxLength(50)
  834. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  835. b.Property<Guid>("C_OrgCode")
  836. .HasColumnType("char(36)");
  837. b.Property<Guid>("C_CreateBy")
  838. .HasColumnType("char(36)");
  839. b.Property<DateTime>("D_CreateOn")
  840. .HasColumnType("datetime(6)");
  841. b.HasKey("C_StoreCode", "C_OrgCode");
  842. b.HasIndex("C_CreateBy");
  843. b.ToTable("TPNT_StoreOrg");
  844. });
  845. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TPNT_Type", b =>
  846. {
  847. b.Property<Guid>("C_Code")
  848. .ValueGeneratedOnAdd()
  849. .HasColumnType("char(36)");
  850. b.Property<string>("C_Name")
  851. .IsRequired()
  852. .HasMaxLength(50)
  853. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  854. b.Property<string>("C_Status")
  855. .IsRequired()
  856. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  857. b.Property<int>("I_Sort")
  858. .HasColumnType("int");
  859. b.HasKey("C_Code");
  860. b.ToTable("TPNT_Type");
  861. });
  862. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TPRD_Log", b =>
  863. {
  864. b.Property<Guid>("C_Code")
  865. .ValueGeneratedOnAdd()
  866. .HasColumnType("char(36)");
  867. b.Property<string>("C_AlarmMsg")
  868. .HasMaxLength(1024)
  869. .HasColumnType("varchar(1024) CHARACTER SET utf8mb4");
  870. b.Property<Guid>("C_CreateBy")
  871. .HasColumnType("char(36)");
  872. b.Property<string>("C_DeviceCode")
  873. .HasMaxLength(50)
  874. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  875. b.Property<string>("C_ProductCode")
  876. .IsRequired()
  877. .HasMaxLength(50)
  878. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  879. b.Property<string>("C_Remark")
  880. .HasMaxLength(1024)
  881. .HasColumnType("varchar(1024) CHARACTER SET utf8mb4");
  882. b.Property<string>("C_SpotCode")
  883. .HasMaxLength(50)
  884. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  885. b.Property<string>("C_StoreCode")
  886. .IsRequired()
  887. .HasMaxLength(50)
  888. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  889. b.Property<DateTime>("D_CreateOn")
  890. .HasColumnType("datetime(6)");
  891. b.Property<int>("I_Type")
  892. .HasColumnType("int");
  893. b.HasKey("C_Code");
  894. b.ToTable("TPRD_Log");
  895. });
  896. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TPRD_ProdSKU", b =>
  897. {
  898. b.Property<string>("C_SKUCode")
  899. .HasMaxLength(100)
  900. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  901. b.Property<string>("C_Brand")
  902. .IsRequired()
  903. .HasMaxLength(100)
  904. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  905. b.Property<Guid>("C_CreateBy")
  906. .HasColumnType("char(36)");
  907. b.Property<string>("C_IconPath")
  908. .IsRequired()
  909. .HasMaxLength(100)
  910. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  911. b.Property<string>("C_ImagePath")
  912. .IsRequired()
  913. .HasMaxLength(100)
  914. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  915. b.Property<Guid?>("C_LastUpdatedBy")
  916. .HasColumnType("char(36)");
  917. b.Property<string>("C_Name")
  918. .IsRequired()
  919. .HasMaxLength(255)
  920. .HasColumnType("varchar(255) CHARACTER SET utf8mb4");
  921. b.Property<string>("C_ProdArea")
  922. .IsRequired()
  923. .HasMaxLength(50)
  924. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  925. b.Property<string>("C_Remark")
  926. .HasMaxLength(500)
  927. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  928. b.Property<string>("C_Spec")
  929. .IsRequired()
  930. .HasMaxLength(500)
  931. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  932. b.Property<string>("C_Status")
  933. .IsRequired()
  934. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  935. b.Property<string>("C_TypeCode")
  936. .IsRequired()
  937. .HasMaxLength(50)
  938. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  939. b.Property<string>("C_Unit")
  940. .IsRequired()
  941. .HasMaxLength(50)
  942. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  943. b.Property<string>("C_Vender")
  944. .IsRequired()
  945. .HasMaxLength(255)
  946. .HasColumnType("varchar(255) CHARACTER SET utf8mb4");
  947. b.Property<DateTime>("D_CreateOn")
  948. .HasColumnType("datetime(6)");
  949. b.Property<DateTime?>("D_LastUpdatedOn")
  950. .HasColumnType("datetime(6)");
  951. b.Property<int>("I_AlarmDays")
  952. .HasColumnType("int");
  953. b.Property<int>("I_MinStock")
  954. .HasColumnType("int");
  955. b.Property<int>("I_Sort")
  956. .HasColumnType("int");
  957. b.Property<int>("I_ValiDays")
  958. .HasColumnType("int");
  959. b.HasKey("C_SKUCode");
  960. b.HasIndex("C_CreateBy");
  961. b.HasIndex("C_LastUpdatedBy");
  962. b.ToTable("TPRD_ProdSKU");
  963. });
  964. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TPRD_Product", b =>
  965. {
  966. b.Property<string>("C_Code")
  967. .HasMaxLength(50)
  968. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  969. b.Property<string>("C_AlarmMsg")
  970. .IsRequired()
  971. .HasMaxLength(1024)
  972. .HasColumnType("varchar(1024) CHARACTER SET utf8mb4");
  973. b.Property<string>("C_AreaCode")
  974. .IsRequired()
  975. .HasMaxLength(50)
  976. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  977. b.Property<Guid>("C_CreateBy")
  978. .HasColumnType("char(36)");
  979. b.Property<string>("C_DeviceCode")
  980. .IsRequired()
  981. .HasMaxLength(50)
  982. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  983. b.Property<string>("C_ImageUrl")
  984. .IsRequired()
  985. .HasMaxLength(255)
  986. .HasColumnType("varchar(255) CHARACTER SET utf8mb4");
  987. b.Property<Guid?>("C_LastUpdatedBy")
  988. .HasColumnType("char(36)");
  989. b.Property<string>("C_QRCode")
  990. .IsRequired()
  991. .HasMaxLength(255)
  992. .HasColumnType("varchar(255) CHARACTER SET utf8mb4");
  993. b.Property<string>("C_Remark")
  994. .HasMaxLength(1024)
  995. .HasColumnType("varchar(1024) CHARACTER SET utf8mb4");
  996. b.Property<string>("C_SKUCode")
  997. .IsRequired()
  998. .HasMaxLength(100)
  999. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  1000. b.Property<string>("C_SpotCode")
  1001. .IsRequired()
  1002. .HasMaxLength(50)
  1003. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1004. b.Property<string>("C_StoreCode")
  1005. .IsRequired()
  1006. .HasMaxLength(50)
  1007. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1008. b.Property<DateTime>("D_CreateOn")
  1009. .HasColumnType("datetime(6)");
  1010. b.Property<DateTime?>("D_LastISP")
  1011. .HasColumnType("datetime(6)");
  1012. b.Property<DateTime?>("D_LastUpdatedOn")
  1013. .HasColumnType("datetime(6)");
  1014. b.Property<DateTime?>("D_ProdDate")
  1015. .HasColumnType("datetime(6)");
  1016. b.Property<DateTime?>("D_ValiDate")
  1017. .HasColumnType("datetime(6)");
  1018. b.Property<decimal?>("F_Map_X")
  1019. .HasColumnType("decimal(12,2)");
  1020. b.Property<decimal?>("F_Map_Y")
  1021. .HasColumnType("decimal(12,2)");
  1022. b.Property<int>("I_IsAlarm")
  1023. .HasColumnType("int");
  1024. b.Property<int>("I_Sort")
  1025. .HasColumnType("int");
  1026. b.Property<int>("I_Status")
  1027. .HasColumnType("int");
  1028. b.HasKey("C_Code");
  1029. b.HasIndex("C_CreateBy");
  1030. b.HasIndex("C_LastUpdatedBy");
  1031. b.ToTable("TPRD_Product");
  1032. });
  1033. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TPRD_Type", b =>
  1034. {
  1035. b.Property<Guid>("C_Code")
  1036. .ValueGeneratedOnAdd()
  1037. .HasColumnType("char(36)");
  1038. b.Property<Guid>("C_CreateBy")
  1039. .HasColumnType("char(36)");
  1040. b.Property<Guid?>("C_LastUpdatedBy")
  1041. .HasColumnType("char(36)");
  1042. b.Property<string>("C_Name")
  1043. .IsRequired()
  1044. .HasMaxLength(50)
  1045. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1046. b.Property<string>("C_Remark")
  1047. .HasMaxLength(500)
  1048. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  1049. b.Property<string>("C_Status")
  1050. .IsRequired()
  1051. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  1052. b.Property<DateTime>("D_CreateOn")
  1053. .HasColumnType("datetime(6)");
  1054. b.Property<DateTime?>("D_LastUpdatedOn")
  1055. .HasColumnType("datetime(6)");
  1056. b.Property<int>("I_IfFPP")
  1057. .HasColumnType("int");
  1058. b.Property<int>("I_Sort")
  1059. .HasColumnType("int");
  1060. b.HasKey("C_Code");
  1061. b.HasIndex("C_CreateBy");
  1062. b.ToTable("TPRD_Type");
  1063. });
  1064. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSEC_Record", b =>
  1065. {
  1066. b.Property<Guid>("C_ID")
  1067. .ValueGeneratedOnAdd()
  1068. .HasColumnType("char(36)");
  1069. b.Property<Guid>("C_CreateBy")
  1070. .HasColumnType("char(36)");
  1071. b.Property<Guid>("C_LastUpdatedBy")
  1072. .HasColumnType("char(36)");
  1073. b.Property<string>("C_Remark")
  1074. .HasMaxLength(500)
  1075. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  1076. b.Property<string>("C_SecurityContent")
  1077. .HasColumnType("longtext CHARACTER SET utf8mb4");
  1078. b.Property<Guid>("C_SpotCode")
  1079. .HasColumnType("char(36)");
  1080. b.Property<string>("C_Status")
  1081. .IsRequired()
  1082. .HasMaxLength(1)
  1083. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  1084. b.Property<DateTime>("D_CreateOn")
  1085. .HasColumnType("datetime(6)");
  1086. b.Property<DateTime>("D_LastUpdatedOn")
  1087. .HasColumnType("datetime(6)");
  1088. b.HasKey("C_ID");
  1089. b.HasIndex("C_CreateBy");
  1090. b.HasIndex("C_LastUpdatedBy");
  1091. b.ToTable("TSEC_Record");
  1092. });
  1093. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSEC_RecordImage", b =>
  1094. {
  1095. b.Property<Guid>("C_ID")
  1096. .ValueGeneratedOnAdd()
  1097. .HasColumnType("char(36)");
  1098. b.Property<string>("C_ImageURL")
  1099. .IsRequired()
  1100. .HasMaxLength(100)
  1101. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  1102. b.Property<Guid>("C_SecurityRecordCode")
  1103. .HasColumnType("char(36)");
  1104. b.Property<string>("C_Status")
  1105. .IsRequired()
  1106. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  1107. b.HasKey("C_ID");
  1108. b.ToTable("TSEC_RecordImage");
  1109. });
  1110. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSEC_RecordItem", b =>
  1111. {
  1112. b.Property<Guid>("C_ID")
  1113. .ValueGeneratedOnAdd()
  1114. .HasColumnType("char(36)");
  1115. b.Property<Guid>("C_CreateBy")
  1116. .HasColumnType("char(36)");
  1117. b.Property<Guid>("C_LastUpdatedBy")
  1118. .HasColumnType("char(36)");
  1119. b.Property<Guid>("C_RecordItemCode")
  1120. .HasColumnType("char(36)");
  1121. b.Property<string>("C_Remark")
  1122. .HasMaxLength(500)
  1123. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  1124. b.Property<string>("C_SecurityContent")
  1125. .HasMaxLength(500)
  1126. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  1127. b.Property<string>("C_Status")
  1128. .IsRequired()
  1129. .HasMaxLength(1)
  1130. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  1131. b.Property<DateTime>("D_CreateOn")
  1132. .HasColumnType("datetime(6)");
  1133. b.Property<DateTime>("D_LastUpdatedOn")
  1134. .HasColumnType("datetime(6)");
  1135. b.HasKey("C_ID");
  1136. b.HasIndex("C_CreateBy");
  1137. b.HasIndex("C_LastUpdatedBy");
  1138. b.ToTable("TSEC_RecordItem");
  1139. });
  1140. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_License", b =>
  1141. {
  1142. b.Property<Guid>("C_ID")
  1143. .ValueGeneratedOnAdd()
  1144. .HasColumnType("char(36)");
  1145. b.Property<string>("C_Code")
  1146. .IsRequired()
  1147. .HasMaxLength(50)
  1148. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1149. b.Property<Guid>("C_CreateBy")
  1150. .HasColumnType("char(36)");
  1151. b.Property<string>("C_FilePath")
  1152. .IsRequired()
  1153. .HasMaxLength(500)
  1154. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  1155. b.Property<Guid?>("C_LastUpdatedBy")
  1156. .HasColumnType("char(36)");
  1157. b.Property<string>("C_Name")
  1158. .IsRequired()
  1159. .HasMaxLength(100)
  1160. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  1161. b.Property<string>("C_Remark")
  1162. .HasMaxLength(500)
  1163. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  1164. b.Property<string>("C_Status")
  1165. .IsRequired()
  1166. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  1167. b.Property<Guid>("C_TypeCode")
  1168. .HasColumnType("char(36)");
  1169. b.Property<DateTime>("D_CreateOn")
  1170. .HasColumnType("datetime(6)");
  1171. b.Property<DateTime>("D_EndDate")
  1172. .HasColumnType("datetime(6)");
  1173. b.Property<DateTime?>("D_LastUpdatedOn")
  1174. .HasColumnType("datetime(6)");
  1175. b.Property<DateTime>("D_StartDate")
  1176. .HasColumnType("datetime(6)");
  1177. b.Property<int>("I_DiskCapacity")
  1178. .HasColumnType("int");
  1179. b.Property<int>("I_MemberQty")
  1180. .HasColumnType("int");
  1181. b.Property<int>("I_Sort")
  1182. .HasColumnType("int");
  1183. b.HasKey("C_ID");
  1184. b.HasIndex("C_Code")
  1185. .IsUnique();
  1186. b.HasIndex("C_CreateBy");
  1187. b.HasIndex("C_LastUpdatedBy");
  1188. b.HasIndex("C_TypeCode");
  1189. b.ToTable("TSYS_License");
  1190. });
  1191. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_LicenseType", b =>
  1192. {
  1193. b.Property<Guid>("C_Code")
  1194. .ValueGeneratedOnAdd()
  1195. .HasColumnType("char(36)");
  1196. b.Property<Guid>("C_CreateBy")
  1197. .HasColumnType("char(36)");
  1198. b.Property<Guid?>("C_LastUpdatedBy")
  1199. .HasColumnType("char(36)");
  1200. b.Property<string>("C_Name")
  1201. .IsRequired()
  1202. .HasMaxLength(100)
  1203. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  1204. b.Property<string>("C_Remark")
  1205. .HasMaxLength(500)
  1206. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  1207. b.Property<string>("C_Status")
  1208. .IsRequired()
  1209. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  1210. b.Property<DateTime>("D_CreateOn")
  1211. .HasColumnType("datetime(6)");
  1212. b.Property<DateTime?>("D_LastUpdatedOn")
  1213. .HasColumnType("datetime(6)");
  1214. b.Property<int>("I_MaxFileSize")
  1215. .HasColumnType("int");
  1216. b.Property<int>("I_MaxMemberQty")
  1217. .HasColumnType("int");
  1218. b.Property<int>("I_MaxStoreQty")
  1219. .HasColumnType("int");
  1220. b.Property<int>("I_Sort")
  1221. .HasColumnType("int");
  1222. b.HasKey("C_Code");
  1223. b.HasIndex("C_CreateBy");
  1224. b.HasIndex("C_LastUpdatedBy");
  1225. b.ToTable("TSYS_LicenseType");
  1226. });
  1227. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_LicenseTypePriv", b =>
  1228. {
  1229. b.Property<Guid>("C_LicenseTypeCode")
  1230. .HasColumnType("char(36)");
  1231. b.Property<string>("C_PrivilegeCode")
  1232. .HasMaxLength(50)
  1233. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1234. b.Property<Guid>("C_CreateBy")
  1235. .HasColumnType("char(36)");
  1236. b.Property<DateTime>("D_CreateOn")
  1237. .HasColumnType("datetime(6)");
  1238. b.HasKey("C_LicenseTypeCode", "C_PrivilegeCode");
  1239. b.HasIndex("C_CreateBy");
  1240. b.HasIndex("C_PrivilegeCode");
  1241. b.ToTable("TSYS_LicenseTypePriv");
  1242. });
  1243. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_Message", b =>
  1244. {
  1245. b.Property<Guid>("C_Code")
  1246. .ValueGeneratedOnAdd()
  1247. .HasColumnType("char(36)");
  1248. b.Property<string>("C_Content")
  1249. .IsRequired()
  1250. .HasMaxLength(1000)
  1251. .HasColumnType("varchar(1000) CHARACTER SET utf8mb4");
  1252. b.Property<Guid>("C_CreateBy")
  1253. .HasColumnType("char(36)");
  1254. b.Property<Guid?>("C_LastUpdatedBy")
  1255. .HasColumnType("char(36)");
  1256. b.Property<string>("C_LicenseCode")
  1257. .IsRequired()
  1258. .HasMaxLength(50)
  1259. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1260. b.Property<string>("C_RelatedID")
  1261. .HasMaxLength(50)
  1262. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1263. b.Property<string>("C_RelatedModule")
  1264. .HasMaxLength(200)
  1265. .HasColumnType("varchar(200) CHARACTER SET utf8mb4");
  1266. b.Property<string>("C_Status")
  1267. .IsRequired()
  1268. .HasMaxLength(1)
  1269. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  1270. b.Property<string>("C_Type")
  1271. .IsRequired()
  1272. .HasMaxLength(50)
  1273. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1274. b.Property<Guid>("C_UserID")
  1275. .HasColumnType("char(36)");
  1276. b.Property<DateTime>("D_CreateOn")
  1277. .HasColumnType("datetime(6)");
  1278. b.Property<DateTime?>("D_LastUpdatedOn")
  1279. .HasColumnType("datetime(6)");
  1280. b.HasKey("C_Code");
  1281. b.HasIndex("C_CreateBy");
  1282. b.HasIndex("C_LastUpdatedBy");
  1283. b.HasIndex("C_UserID");
  1284. b.ToTable("TSYS_Message");
  1285. });
  1286. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_Org", b =>
  1287. {
  1288. b.Property<int>("K_ID")
  1289. .ValueGeneratedOnAdd()
  1290. .HasColumnType("int");
  1291. b.Property<string>("C_Code")
  1292. .IsRequired()
  1293. .HasMaxLength(50)
  1294. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1295. b.Property<Guid>("C_CreateBy")
  1296. .HasColumnType("char(36)");
  1297. b.Property<string>("C_GIS")
  1298. .HasMaxLength(50)
  1299. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1300. b.Property<Guid?>("C_LastUpdatedBy")
  1301. .HasColumnType("char(36)");
  1302. b.Property<string>("C_Level")
  1303. .IsRequired()
  1304. .HasMaxLength(500)
  1305. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  1306. b.Property<string>("C_LicenseCode")
  1307. .IsRequired()
  1308. .HasMaxLength(50)
  1309. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1310. b.Property<string>("C_Linker")
  1311. .HasMaxLength(50)
  1312. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1313. b.Property<string>("C_Lname")
  1314. .HasMaxLength(2550)
  1315. .HasColumnType("longtext CHARACTER SET utf8mb4");
  1316. b.Property<string>("C_Name")
  1317. .IsRequired()
  1318. .HasMaxLength(255)
  1319. .HasColumnType("varchar(255) CHARACTER SET utf8mb4");
  1320. b.Property<int>("C_ParentCode")
  1321. .HasColumnType("int");
  1322. b.Property<string>("C_Phone")
  1323. .HasMaxLength(50)
  1324. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1325. b.Property<string>("C_Remark")
  1326. .HasMaxLength(500)
  1327. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  1328. b.Property<string>("C_SName")
  1329. .HasMaxLength(16)
  1330. .HasColumnType("varchar(16) CHARACTER SET utf8mb4");
  1331. b.Property<string>("C_Status")
  1332. .IsRequired()
  1333. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  1334. b.Property<Guid>("C_Type")
  1335. .HasColumnType("char(36)");
  1336. b.Property<DateTime>("D_CreateOn")
  1337. .HasColumnType("datetime(6)");
  1338. b.Property<DateTime?>("D_LastUpdatedOn")
  1339. .HasColumnType("datetime(6)");
  1340. b.Property<int>("I_Sort")
  1341. .HasColumnType("int");
  1342. b.Property<Guid?>("StoreOrgC_OrgCode")
  1343. .HasColumnType("char(36)");
  1344. b.Property<string>("StoreOrgC_StoreCode")
  1345. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1346. b.HasKey("K_ID");
  1347. b.HasIndex("C_CreateBy");
  1348. b.HasIndex("C_LastUpdatedBy");
  1349. b.HasIndex("C_ParentCode");
  1350. b.HasIndex("StoreOrgC_StoreCode", "StoreOrgC_OrgCode");
  1351. b.ToTable("TSYS_Org");
  1352. });
  1353. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_Organize", b =>
  1354. {
  1355. b.Property<Guid>("G_ID")
  1356. .ValueGeneratedOnAdd()
  1357. .HasColumnType("char(36)");
  1358. b.Property<string>("C_Address")
  1359. .HasMaxLength(100)
  1360. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  1361. b.Property<string>("C_GPS")
  1362. .HasMaxLength(100)
  1363. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  1364. b.Property<string>("C_ImageUrl")
  1365. .HasMaxLength(100)
  1366. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  1367. b.Property<string>("C_Name")
  1368. .IsRequired()
  1369. .HasMaxLength(50)
  1370. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1371. b.Property<string>("C_Number")
  1372. .HasMaxLength(50)
  1373. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1374. b.Property<string>("C_ParentCodeList")
  1375. .HasMaxLength(500)
  1376. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  1377. b.Property<string>("C_ParentName")
  1378. .HasMaxLength(50)
  1379. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1380. b.Property<string>("C_Remark")
  1381. .HasMaxLength(500)
  1382. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  1383. b.Property<string>("C_Status")
  1384. .IsRequired()
  1385. .HasMaxLength(1)
  1386. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  1387. b.Property<DateTime>("D_CreateOn")
  1388. .HasColumnType("datetime(6)");
  1389. b.Property<DateTime>("D_LastUpdatedOn")
  1390. .HasColumnType("datetime(6)");
  1391. b.Property<Guid>("G_CreateBy")
  1392. .HasColumnType("char(36)");
  1393. b.Property<Guid>("G_LastUpdatedBy")
  1394. .HasColumnType("char(36)");
  1395. b.Property<Guid>("G_ParentCode")
  1396. .HasColumnType("char(36)");
  1397. b.Property<int>("I_Layer")
  1398. .HasColumnType("int");
  1399. b.Property<int>("I_Sort")
  1400. .HasColumnType("int");
  1401. b.HasKey("G_ID");
  1402. b.ToTable("TSYS_Organize");
  1403. });
  1404. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_Post", b =>
  1405. {
  1406. b.Property<Guid>("G_ID")
  1407. .ValueGeneratedOnAdd()
  1408. .HasColumnType("char(36)");
  1409. b.Property<string>("C_Code")
  1410. .IsRequired()
  1411. .HasMaxLength(20)
  1412. .HasColumnType("varchar(20) CHARACTER SET utf8mb4");
  1413. b.Property<string>("C_Name")
  1414. .IsRequired()
  1415. .HasMaxLength(50)
  1416. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1417. b.Property<string>("C_Remark")
  1418. .HasMaxLength(100)
  1419. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  1420. b.Property<string>("C_Status")
  1421. .IsRequired()
  1422. .HasMaxLength(1)
  1423. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  1424. b.Property<DateTime>("D_CreateOn")
  1425. .HasColumnType("datetime(6)");
  1426. b.Property<DateTime>("D_LastUpdatedOn")
  1427. .HasColumnType("datetime(6)");
  1428. b.Property<Guid>("G_CreateBy")
  1429. .HasColumnType("char(36)");
  1430. b.Property<Guid>("G_LastUpdatedBy")
  1431. .HasColumnType("char(36)");
  1432. b.Property<int>("I_Sort")
  1433. .HasColumnType("int");
  1434. b.HasKey("G_ID");
  1435. b.ToTable("TSYS_Post");
  1436. });
  1437. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_Priv", b =>
  1438. {
  1439. b.Property<string>("C_Code")
  1440. .HasMaxLength(50)
  1441. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1442. b.Property<string>("C_ImageUrl")
  1443. .HasMaxLength(500)
  1444. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  1445. b.Property<string>("C_Module")
  1446. .IsRequired()
  1447. .HasMaxLength(50)
  1448. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1449. b.Property<string>("C_Name")
  1450. .IsRequired()
  1451. .HasMaxLength(50)
  1452. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1453. b.Property<string>("C_PageUrl")
  1454. .HasMaxLength(500)
  1455. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  1456. b.Property<string>("C_ParentCode")
  1457. .HasMaxLength(50)
  1458. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1459. b.Property<string>("C_Remark")
  1460. .HasMaxLength(100)
  1461. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  1462. b.Property<string>("C_Status")
  1463. .IsRequired()
  1464. .HasMaxLength(1)
  1465. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  1466. b.Property<string>("C_Type")
  1467. .IsRequired()
  1468. .HasMaxLength(50)
  1469. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1470. b.Property<int>("I_Sort")
  1471. .HasColumnType("int");
  1472. b.HasKey("C_Code");
  1473. b.HasIndex("C_ParentCode");
  1474. b.ToTable("TSYS_Priv");
  1475. });
  1476. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_Role", b =>
  1477. {
  1478. b.Property<Guid>("C_Code")
  1479. .ValueGeneratedOnAdd()
  1480. .HasColumnType("char(36)");
  1481. b.Property<Guid>("C_CreateBy")
  1482. .HasColumnType("char(36)");
  1483. b.Property<string>("C_Description")
  1484. .HasMaxLength(100)
  1485. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  1486. b.Property<Guid?>("C_LastUpdatedBy")
  1487. .HasColumnType("char(36)");
  1488. b.Property<string>("C_LicenseCode")
  1489. .IsRequired()
  1490. .HasMaxLength(50)
  1491. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1492. b.Property<string>("C_Name")
  1493. .HasMaxLength(50)
  1494. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1495. b.Property<string>("C_Remark")
  1496. .HasMaxLength(500)
  1497. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  1498. b.Property<string>("C_Status")
  1499. .IsRequired()
  1500. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  1501. b.Property<DateTime>("D_CreateOn")
  1502. .HasColumnType("datetime(6)");
  1503. b.Property<DateTime?>("D_LastUpdatedOn")
  1504. .HasColumnType("datetime(6)");
  1505. b.Property<int>("I_Sort")
  1506. .HasColumnType("int");
  1507. b.HasKey("C_Code");
  1508. b.HasIndex("C_CreateBy");
  1509. b.HasIndex("C_LastUpdatedBy");
  1510. b.ToTable("TSYS_Role");
  1511. });
  1512. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_RolePriv", b =>
  1513. {
  1514. b.Property<Guid>("C_RoleCode")
  1515. .HasColumnType("char(36)");
  1516. b.Property<string>("C_PrivilegeCode")
  1517. .HasMaxLength(50)
  1518. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1519. b.Property<Guid>("C_CreateBy")
  1520. .HasColumnType("char(36)");
  1521. b.Property<DateTime>("D_CreateOn")
  1522. .HasColumnType("datetime(6)");
  1523. b.Property<int>("I_Type")
  1524. .HasColumnType("int");
  1525. b.HasKey("C_RoleCode", "C_PrivilegeCode");
  1526. b.HasIndex("C_CreateBy");
  1527. b.ToTable("TSYS_RolePriv");
  1528. });
  1529. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_User", b =>
  1530. {
  1531. b.Property<Guid>("C_UserID")
  1532. .ValueGeneratedOnAdd()
  1533. .HasColumnType("char(36)");
  1534. b.Property<string>("C_Address")
  1535. .HasMaxLength(255)
  1536. .HasColumnType("varchar(255) CHARACTER SET utf8mb4");
  1537. b.Property<Guid>("C_CreateBy")
  1538. .HasColumnType("char(36)");
  1539. b.Property<string>("C_Email")
  1540. .HasMaxLength(50)
  1541. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1542. b.Property<string>("C_IDNum")
  1543. .HasMaxLength(100)
  1544. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  1545. b.Property<string>("C_ImagePath")
  1546. .HasMaxLength(500)
  1547. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  1548. b.Property<Guid?>("C_LastUpdatedBy")
  1549. .HasColumnType("char(36)");
  1550. b.Property<string>("C_LicenseCode")
  1551. .IsRequired()
  1552. .HasMaxLength(50)
  1553. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1554. b.Property<string>("C_Mobile")
  1555. .HasMaxLength(20)
  1556. .HasColumnType("varchar(20) CHARACTER SET utf8mb4");
  1557. b.Property<string>("C_Name")
  1558. .IsRequired()
  1559. .HasMaxLength(100)
  1560. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  1561. b.Property<string>("C_OrgCode")
  1562. .IsRequired()
  1563. .HasMaxLength(100)
  1564. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  1565. b.Property<string>("C_Password")
  1566. .IsRequired()
  1567. .HasMaxLength(100)
  1568. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  1569. b.Property<string>("C_Phone")
  1570. .HasMaxLength(20)
  1571. .HasColumnType("varchar(20) CHARACTER SET utf8mb4");
  1572. b.Property<Guid?>("C_Post")
  1573. .HasColumnType("char(36)");
  1574. b.Property<string>("C_ProgramID")
  1575. .HasMaxLength(100)
  1576. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  1577. b.Property<string>("C_Remark")
  1578. .HasMaxLength(500)
  1579. .HasColumnType("varchar(500) CHARACTER SET utf8mb4");
  1580. b.Property<string>("C_Status")
  1581. .IsRequired()
  1582. .HasMaxLength(1)
  1583. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  1584. b.Property<string>("C_UserName")
  1585. .IsRequired()
  1586. .HasMaxLength(50)
  1587. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1588. b.Property<string>("C_WechatID")
  1589. .HasMaxLength(100)
  1590. .HasColumnType("varchar(100) CHARACTER SET utf8mb4");
  1591. b.Property<DateTime>("D_BirthDay")
  1592. .HasColumnType("datetime(6)");
  1593. b.Property<DateTime>("D_CreateOn")
  1594. .HasColumnType("datetime(6)");
  1595. b.Property<DateTime?>("D_LastUpdatedOn")
  1596. .HasColumnType("datetime(6)");
  1597. b.Property<int>("I_Render")
  1598. .HasColumnType("int");
  1599. b.Property<int>("I_Sort")
  1600. .HasColumnType("int");
  1601. b.HasKey("C_UserID");
  1602. b.HasIndex("C_CreateBy");
  1603. b.HasIndex("C_IDNum")
  1604. .IsUnique();
  1605. b.HasIndex("C_LastUpdatedBy");
  1606. b.HasIndex("C_Mobile")
  1607. .IsUnique();
  1608. b.ToTable("TSYS_User");
  1609. });
  1610. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_UserPost", b =>
  1611. {
  1612. b.Property<Guid>("G_ID")
  1613. .ValueGeneratedOnAdd()
  1614. .HasColumnType("char(36)");
  1615. b.Property<DateTime>("D_CreateOn")
  1616. .HasColumnType("datetime(6)");
  1617. b.Property<Guid>("G_CreateBy")
  1618. .HasColumnType("char(36)");
  1619. b.Property<Guid>("G_PostCode")
  1620. .HasColumnType("char(36)");
  1621. b.Property<Guid>("G_UserCode")
  1622. .HasColumnType("char(36)");
  1623. b.HasKey("G_ID");
  1624. b.ToTable("TSYS_UserPost");
  1625. });
  1626. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_UserRole", b =>
  1627. {
  1628. b.Property<Guid>("C_UserCode")
  1629. .HasColumnType("char(36)");
  1630. b.Property<Guid>("C_RoleCode")
  1631. .HasColumnType("char(36)");
  1632. b.Property<Guid>("C_CreateBy")
  1633. .HasColumnType("char(36)");
  1634. b.Property<DateTime>("D_CreateOn")
  1635. .HasColumnType("datetime(6)");
  1636. b.HasKey("C_UserCode", "C_RoleCode");
  1637. b.HasIndex("C_CreateBy");
  1638. b.HasIndex("C_RoleCode");
  1639. b.ToTable("TSYS_UserRole");
  1640. });
  1641. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_Version", b =>
  1642. {
  1643. b.Property<Guid>("C_ID")
  1644. .ValueGeneratedOnAdd()
  1645. .HasColumnType("char(36)");
  1646. b.Property<string>("C_AppCode")
  1647. .IsRequired()
  1648. .HasMaxLength(50)
  1649. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1650. b.Property<Guid>("C_CreateBy")
  1651. .HasColumnType("char(36)");
  1652. b.Property<string>("C_DownloadURL")
  1653. .IsRequired()
  1654. .HasMaxLength(1000)
  1655. .HasColumnType("varchar(1000) CHARACTER SET utf8mb4");
  1656. b.Property<Guid?>("C_LastUpdatedBy")
  1657. .HasColumnType("char(36)");
  1658. b.Property<string>("C_Status")
  1659. .IsRequired()
  1660. .HasMaxLength(1)
  1661. .HasColumnType("varchar(1) CHARACTER SET utf8mb4");
  1662. b.Property<string>("C_UpdateContent")
  1663. .IsRequired()
  1664. .HasMaxLength(1000)
  1665. .HasColumnType("varchar(1000) CHARACTER SET utf8mb4");
  1666. b.Property<string>("C_VersionCode")
  1667. .IsRequired()
  1668. .HasMaxLength(50)
  1669. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1670. b.Property<DateTime>("D_CreateOn")
  1671. .HasColumnType("datetime(6)");
  1672. b.Property<DateTime?>("D_LastUpdatedOn")
  1673. .HasColumnType("datetime(6)");
  1674. b.HasKey("C_ID");
  1675. b.HasIndex("C_CreateBy");
  1676. b.HasIndex("C_LastUpdatedBy");
  1677. b.ToTable("TSYS_Version");
  1678. });
  1679. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TaskInfoDto", b =>
  1680. {
  1681. b.Property<string>("jobId")
  1682. .HasColumnType("varchar(255) CHARACTER SET utf8mb4");
  1683. b.Property<Guid?>("TasksQzId")
  1684. .HasColumnType("char(36)");
  1685. b.Property<string>("jobGroup")
  1686. .HasColumnType("longtext CHARACTER SET utf8mb4");
  1687. b.Property<string>("jobName")
  1688. .HasColumnType("longtext CHARACTER SET utf8mb4");
  1689. b.Property<string>("triggerGroup")
  1690. .HasColumnType("longtext CHARACTER SET utf8mb4");
  1691. b.Property<string>("triggerId")
  1692. .HasColumnType("longtext CHARACTER SET utf8mb4");
  1693. b.Property<string>("triggerName")
  1694. .HasColumnType("longtext CHARACTER SET utf8mb4");
  1695. b.Property<string>("triggerStatus")
  1696. .HasColumnType("longtext CHARACTER SET utf8mb4");
  1697. b.HasKey("jobId");
  1698. b.HasIndex("TasksQzId");
  1699. b.ToTable("TaskInfoDto");
  1700. });
  1701. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TasksQz", b =>
  1702. {
  1703. b.Property<Guid>("Id")
  1704. .ValueGeneratedOnAdd()
  1705. .HasColumnType("char(36)");
  1706. b.Property<string>("AssemblyName")
  1707. .HasMaxLength(200)
  1708. .HasColumnType("varchar(200) CHARACTER SET utf8mb4");
  1709. b.Property<DateTime?>("BeginTime")
  1710. .IsRequired()
  1711. .HasColumnType("datetime(6)");
  1712. b.Property<string>("C_LicenseCode")
  1713. .IsRequired()
  1714. .HasMaxLength(50)
  1715. .HasColumnType("varchar(50) CHARACTER SET utf8mb4");
  1716. b.Property<string>("ClassName")
  1717. .HasMaxLength(200)
  1718. .HasColumnType("varchar(200) CHARACTER SET utf8mb4");
  1719. b.Property<Guid>("CreateBy")
  1720. .HasColumnType("char(36)");
  1721. b.Property<DateTime>("CreateTime")
  1722. .HasColumnType("datetime(6)");
  1723. b.Property<string>("Cron")
  1724. .HasMaxLength(200)
  1725. .HasColumnType("varchar(200) CHARACTER SET utf8mb4");
  1726. b.Property<int>("CycleRunTimes")
  1727. .HasColumnType("int");
  1728. b.Property<DateTime?>("EndTime")
  1729. .IsRequired()
  1730. .HasColumnType("datetime(6)");
  1731. b.Property<int>("IntervalSecond")
  1732. .HasColumnType("int");
  1733. b.Property<bool?>("IsDeleted")
  1734. .HasColumnType("tinyint(1)");
  1735. b.Property<bool>("IsStart")
  1736. .HasColumnType("tinyint(1)");
  1737. b.Property<string>("JobGroup")
  1738. .HasMaxLength(200)
  1739. .HasColumnType("varchar(200) CHARACTER SET utf8mb4");
  1740. b.Property<string>("JobParams")
  1741. .HasColumnType("longtext CHARACTER SET utf8mb4");
  1742. b.Property<string>("Name")
  1743. .HasMaxLength(200)
  1744. .HasColumnType("varchar(200) CHARACTER SET utf8mb4");
  1745. b.Property<string>("Remark")
  1746. .HasMaxLength(1000)
  1747. .HasColumnType("varchar(1000) CHARACTER SET utf8mb4");
  1748. b.Property<int>("RunTimes")
  1749. .HasColumnType("int");
  1750. b.Property<int>("TriggerType")
  1751. .HasColumnType("int");
  1752. b.HasKey("Id");
  1753. b.ToTable("TasksQz");
  1754. });
  1755. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TBDM_Area", b =>
  1756. {
  1757. b.HasOne("Ropin.Inspection.Model.Entities.TBDM_City", "CityCityCode")
  1758. .WithMany()
  1759. .HasForeignKey("C_CityCode")
  1760. .OnDelete(DeleteBehavior.Cascade)
  1761. .IsRequired();
  1762. b.Navigation("CityCityCode");
  1763. });
  1764. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TBDM_City", b =>
  1765. {
  1766. b.HasOne("Ropin.Inspection.Model.Entities.TBDM_Prov", "ProvProvCode")
  1767. .WithMany()
  1768. .HasForeignKey("C_ProvCode")
  1769. .OnDelete(DeleteBehavior.Cascade)
  1770. .IsRequired();
  1771. b.Navigation("ProvProvCode");
  1772. });
  1773. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TBDM_CodeDetail", b =>
  1774. {
  1775. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  1776. .WithMany()
  1777. .HasForeignKey("C_CreateBy")
  1778. .OnDelete(DeleteBehavior.Cascade)
  1779. .IsRequired();
  1780. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  1781. .WithMany()
  1782. .HasForeignKey("C_LastUpdatedBy");
  1783. b.Navigation("UsersCreateBy");
  1784. b.Navigation("UsersLastUpdatedBy");
  1785. });
  1786. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TBDM_CodeMain", b =>
  1787. {
  1788. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  1789. .WithMany()
  1790. .HasForeignKey("C_CreateBy")
  1791. .OnDelete(DeleteBehavior.Cascade)
  1792. .IsRequired();
  1793. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  1794. .WithMany()
  1795. .HasForeignKey("C_LastUpdatedBy");
  1796. b.Navigation("UsersCreateBy");
  1797. b.Navigation("UsersLastUpdatedBy");
  1798. });
  1799. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TDEV_DevAlertConfig", b =>
  1800. {
  1801. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  1802. .WithMany()
  1803. .HasForeignKey("C_CreateBy")
  1804. .OnDelete(DeleteBehavior.Cascade)
  1805. .IsRequired();
  1806. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  1807. .WithMany()
  1808. .HasForeignKey("C_LastUpdatedBy");
  1809. b.Navigation("UsersCreateBy");
  1810. b.Navigation("UsersLastUpdatedBy");
  1811. });
  1812. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TDEV_DevDataConfig", b =>
  1813. {
  1814. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  1815. .WithMany()
  1816. .HasForeignKey("C_CreateBy")
  1817. .OnDelete(DeleteBehavior.Cascade)
  1818. .IsRequired();
  1819. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  1820. .WithMany()
  1821. .HasForeignKey("C_LastUpdatedBy");
  1822. b.Navigation("UsersCreateBy");
  1823. b.Navigation("UsersLastUpdatedBy");
  1824. });
  1825. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TDEV_Device", b =>
  1826. {
  1827. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  1828. .WithMany()
  1829. .HasForeignKey("C_CreateBy")
  1830. .OnDelete(DeleteBehavior.Cascade)
  1831. .IsRequired();
  1832. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  1833. .WithMany()
  1834. .HasForeignKey("C_LastUpdatedBy");
  1835. b.Navigation("UsersCreateBy");
  1836. b.Navigation("UsersLastUpdatedBy");
  1837. });
  1838. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_Content", b =>
  1839. {
  1840. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  1841. .WithMany()
  1842. .HasForeignKey("C_CreateBy")
  1843. .OnDelete(DeleteBehavior.Cascade)
  1844. .IsRequired();
  1845. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  1846. .WithMany()
  1847. .HasForeignKey("C_LastUpdatedBy")
  1848. .OnDelete(DeleteBehavior.Cascade)
  1849. .IsRequired();
  1850. b.Navigation("UsersCreateBy");
  1851. b.Navigation("UsersLastUpdatedBy");
  1852. });
  1853. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_ContentGroup", b =>
  1854. {
  1855. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  1856. .WithMany()
  1857. .HasForeignKey("G_CreateBy")
  1858. .OnDelete(DeleteBehavior.Cascade)
  1859. .IsRequired();
  1860. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  1861. .WithMany()
  1862. .HasForeignKey("G_LastUpdatedBy")
  1863. .OnDelete(DeleteBehavior.Cascade)
  1864. .IsRequired();
  1865. b.Navigation("UsersCreateBy");
  1866. b.Navigation("UsersLastUpdatedBy");
  1867. });
  1868. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_ContentGroupItem", b =>
  1869. {
  1870. b.HasOne("Ropin.Inspection.Model.Entities.TISP_Content", "ContentCode")
  1871. .WithMany()
  1872. .HasForeignKey("G_ContentCode")
  1873. .OnDelete(DeleteBehavior.Cascade)
  1874. .IsRequired();
  1875. b.HasOne("Ropin.Inspection.Model.Entities.TISP_ContentGroup", "ContentGroupCode")
  1876. .WithMany()
  1877. .HasForeignKey("G_ContentGroupCode")
  1878. .OnDelete(DeleteBehavior.Cascade)
  1879. .IsRequired();
  1880. b.Navigation("ContentCode");
  1881. b.Navigation("ContentGroupCode");
  1882. });
  1883. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_Record", b =>
  1884. {
  1885. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  1886. .WithMany()
  1887. .HasForeignKey("C_CreateBy")
  1888. .OnDelete(DeleteBehavior.Cascade)
  1889. .IsRequired();
  1890. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  1891. .WithMany()
  1892. .HasForeignKey("C_LastUpdatedBy")
  1893. .OnDelete(DeleteBehavior.Cascade)
  1894. .IsRequired();
  1895. b.HasOne("Ropin.Inspection.Model.Entities.TISP_Spot", "SpotCode")
  1896. .WithMany()
  1897. .HasForeignKey("C_SpotCode")
  1898. .OnDelete(DeleteBehavior.Cascade)
  1899. .IsRequired();
  1900. b.Navigation("SpotCode");
  1901. b.Navigation("UsersCreateBy");
  1902. b.Navigation("UsersLastUpdatedBy");
  1903. });
  1904. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_RecordImage", b =>
  1905. {
  1906. b.HasOne("Ropin.Inspection.Model.Entities.TISP_RecordItem", "RecordItemCode")
  1907. .WithMany()
  1908. .HasForeignKey("C_RecordItemCode")
  1909. .OnDelete(DeleteBehavior.Cascade)
  1910. .IsRequired();
  1911. b.Navigation("RecordItemCode");
  1912. });
  1913. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_RecordItem", b =>
  1914. {
  1915. b.HasOne("Ropin.Inspection.Model.Entities.TISP_Content", "ContentCode")
  1916. .WithMany()
  1917. .HasForeignKey("C_ContentCode")
  1918. .OnDelete(DeleteBehavior.Cascade)
  1919. .IsRequired();
  1920. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  1921. .WithMany()
  1922. .HasForeignKey("C_CreateBy")
  1923. .OnDelete(DeleteBehavior.Cascade)
  1924. .IsRequired();
  1925. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  1926. .WithMany()
  1927. .HasForeignKey("C_LastUpdatedBy")
  1928. .OnDelete(DeleteBehavior.Cascade)
  1929. .IsRequired();
  1930. b.HasOne("Ropin.Inspection.Model.Entities.TISP_Record", "RecordCode")
  1931. .WithMany()
  1932. .HasForeignKey("C_RecordCode")
  1933. .OnDelete(DeleteBehavior.Cascade)
  1934. .IsRequired();
  1935. b.Navigation("ContentCode");
  1936. b.Navigation("RecordCode");
  1937. b.Navigation("UsersCreateBy");
  1938. b.Navigation("UsersLastUpdatedBy");
  1939. });
  1940. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_Region", b =>
  1941. {
  1942. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  1943. .WithMany()
  1944. .HasForeignKey("C_CreateBy")
  1945. .OnDelete(DeleteBehavior.Cascade)
  1946. .IsRequired();
  1947. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  1948. .WithMany()
  1949. .HasForeignKey("C_LastUpdatedBy")
  1950. .OnDelete(DeleteBehavior.Cascade)
  1951. .IsRequired();
  1952. b.Navigation("UsersCreateBy");
  1953. b.Navigation("UsersLastUpdatedBy");
  1954. });
  1955. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_Route", b =>
  1956. {
  1957. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  1958. .WithMany()
  1959. .HasForeignKey("C_CreateBy")
  1960. .OnDelete(DeleteBehavior.Cascade)
  1961. .IsRequired();
  1962. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  1963. .WithMany()
  1964. .HasForeignKey("C_LastUpdatedBy")
  1965. .OnDelete(DeleteBehavior.Cascade)
  1966. .IsRequired();
  1967. b.Navigation("UsersCreateBy");
  1968. b.Navigation("UsersLastUpdatedBy");
  1969. });
  1970. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_Spot", b =>
  1971. {
  1972. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  1973. .WithMany()
  1974. .HasForeignKey("C_CreateBy")
  1975. .OnDelete(DeleteBehavior.Cascade)
  1976. .IsRequired();
  1977. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  1978. .WithMany()
  1979. .HasForeignKey("C_LastUpdatedBy")
  1980. .OnDelete(DeleteBehavior.Cascade)
  1981. .IsRequired();
  1982. b.Navigation("UsersCreateBy");
  1983. b.Navigation("UsersLastUpdatedBy");
  1984. });
  1985. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_SpotContent", b =>
  1986. {
  1987. b.HasOne("Ropin.Inspection.Model.Entities.TISP_Content", "ContentCode")
  1988. .WithMany()
  1989. .HasForeignKey("C_ContentCode")
  1990. .OnDelete(DeleteBehavior.Cascade)
  1991. .IsRequired();
  1992. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  1993. .WithMany()
  1994. .HasForeignKey("C_CreateBy")
  1995. .OnDelete(DeleteBehavior.Cascade)
  1996. .IsRequired();
  1997. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  1998. .WithMany()
  1999. .HasForeignKey("C_LastUpdatedBy")
  2000. .OnDelete(DeleteBehavior.Cascade)
  2001. .IsRequired();
  2002. b.HasOne("Ropin.Inspection.Model.Entities.TISP_Spot", "SpotCode")
  2003. .WithMany()
  2004. .HasForeignKey("C_SpotCode")
  2005. .OnDelete(DeleteBehavior.Cascade)
  2006. .IsRequired();
  2007. b.Navigation("ContentCode");
  2008. b.Navigation("SpotCode");
  2009. b.Navigation("UsersCreateBy");
  2010. b.Navigation("UsersLastUpdatedBy");
  2011. });
  2012. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_SpotRegion", b =>
  2013. {
  2014. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  2015. .WithMany()
  2016. .HasForeignKey("C_CreateBy")
  2017. .OnDelete(DeleteBehavior.Cascade)
  2018. .IsRequired();
  2019. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  2020. .WithMany()
  2021. .HasForeignKey("C_LastUpdatedBy")
  2022. .OnDelete(DeleteBehavior.Cascade)
  2023. .IsRequired();
  2024. b.HasOne("Ropin.Inspection.Model.Entities.TISP_Region", "RegionCode")
  2025. .WithMany()
  2026. .HasForeignKey("C_RegionCode")
  2027. .OnDelete(DeleteBehavior.Cascade)
  2028. .IsRequired();
  2029. b.HasOne("Ropin.Inspection.Model.Entities.TISP_Spot", "SpotCode")
  2030. .WithMany()
  2031. .HasForeignKey("C_SpotCode")
  2032. .OnDelete(DeleteBehavior.Cascade)
  2033. .IsRequired();
  2034. b.Navigation("RegionCode");
  2035. b.Navigation("SpotCode");
  2036. b.Navigation("UsersCreateBy");
  2037. b.Navigation("UsersLastUpdatedBy");
  2038. });
  2039. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_SpotRoute", b =>
  2040. {
  2041. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  2042. .WithMany()
  2043. .HasForeignKey("C_CreateBy")
  2044. .OnDelete(DeleteBehavior.Cascade)
  2045. .IsRequired();
  2046. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  2047. .WithMany()
  2048. .HasForeignKey("C_LastUpdatedBy")
  2049. .OnDelete(DeleteBehavior.Cascade)
  2050. .IsRequired();
  2051. b.HasOne("Ropin.Inspection.Model.Entities.TISP_Route", "RouteCode")
  2052. .WithMany()
  2053. .HasForeignKey("C_RouteCode")
  2054. .OnDelete(DeleteBehavior.Cascade)
  2055. .IsRequired();
  2056. b.HasOne("Ropin.Inspection.Model.Entities.TISP_Spot", "SpotCode")
  2057. .WithMany()
  2058. .HasForeignKey("C_SpotCode")
  2059. .OnDelete(DeleteBehavior.Cascade)
  2060. .IsRequired();
  2061. b.Navigation("RouteCode");
  2062. b.Navigation("SpotCode");
  2063. b.Navigation("UsersCreateBy");
  2064. b.Navigation("UsersLastUpdatedBy");
  2065. });
  2066. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TISP_SpotUser", b =>
  2067. {
  2068. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  2069. .WithMany()
  2070. .HasForeignKey("C_CreateBy")
  2071. .OnDelete(DeleteBehavior.Cascade)
  2072. .IsRequired();
  2073. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  2074. .WithMany()
  2075. .HasForeignKey("C_LastUpdatedBy")
  2076. .OnDelete(DeleteBehavior.Cascade)
  2077. .IsRequired();
  2078. b.HasOne("Ropin.Inspection.Model.Entities.TISP_Spot", "SpotCode")
  2079. .WithMany()
  2080. .HasForeignKey("C_SpotCode")
  2081. .OnDelete(DeleteBehavior.Cascade)
  2082. .IsRequired();
  2083. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UserCode")
  2084. .WithMany()
  2085. .HasForeignKey("C_UserCode")
  2086. .OnDelete(DeleteBehavior.Cascade)
  2087. .IsRequired();
  2088. b.Navigation("SpotCode");
  2089. b.Navigation("UserCode");
  2090. b.Navigation("UsersCreateBy");
  2091. b.Navigation("UsersLastUpdatedBy");
  2092. });
  2093. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TPNT_Area", b =>
  2094. {
  2095. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  2096. .WithMany()
  2097. .HasForeignKey("C_CreateBy")
  2098. .OnDelete(DeleteBehavior.Cascade)
  2099. .IsRequired();
  2100. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  2101. .WithMany()
  2102. .HasForeignKey("C_LastUpdatedBy");
  2103. b.HasOne("Ropin.Inspection.Model.Entities.TPNT_Store", "Store")
  2104. .WithMany("Areas")
  2105. .HasForeignKey("C_StoreCode")
  2106. .OnDelete(DeleteBehavior.Cascade)
  2107. .IsRequired();
  2108. b.Navigation("Store");
  2109. b.Navigation("UsersCreateBy");
  2110. b.Navigation("UsersLastUpdatedBy");
  2111. });
  2112. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TPNT_Store", b =>
  2113. {
  2114. b.HasOne("Ropin.Inspection.Model.Entities.TBDM_Area", "AreaAreaCode")
  2115. .WithMany()
  2116. .HasForeignKey("C_AreaCode");
  2117. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  2118. .WithMany()
  2119. .HasForeignKey("C_CreateBy")
  2120. .OnDelete(DeleteBehavior.Cascade)
  2121. .IsRequired();
  2122. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  2123. .WithMany()
  2124. .HasForeignKey("C_LastUpdatedBy");
  2125. b.HasOne("Ropin.Inspection.Model.Entities.TPNT_Type", "TypeTypeCode")
  2126. .WithMany()
  2127. .HasForeignKey("C_TypeCode")
  2128. .OnDelete(DeleteBehavior.Cascade)
  2129. .IsRequired();
  2130. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_License", "License")
  2131. .WithMany("Stores")
  2132. .HasForeignKey("LicenseC_ID");
  2133. b.HasOne("Ropin.Inspection.Model.Entities.TPNT_StoreOrg", "StoreOrg")
  2134. .WithMany("Stores")
  2135. .HasForeignKey("StoreOrgC_StoreCode", "StoreOrgC_OrgCode");
  2136. b.Navigation("AreaAreaCode");
  2137. b.Navigation("License");
  2138. b.Navigation("StoreOrg");
  2139. b.Navigation("TypeTypeCode");
  2140. b.Navigation("UsersCreateBy");
  2141. b.Navigation("UsersLastUpdatedBy");
  2142. });
  2143. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TPNT_StoreOrg", b =>
  2144. {
  2145. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  2146. .WithMany()
  2147. .HasForeignKey("C_CreateBy")
  2148. .OnDelete(DeleteBehavior.Cascade)
  2149. .IsRequired();
  2150. b.Navigation("UsersCreateBy");
  2151. });
  2152. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TPRD_ProdSKU", b =>
  2153. {
  2154. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  2155. .WithMany()
  2156. .HasForeignKey("C_CreateBy")
  2157. .OnDelete(DeleteBehavior.Cascade)
  2158. .IsRequired();
  2159. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  2160. .WithMany()
  2161. .HasForeignKey("C_LastUpdatedBy");
  2162. b.Navigation("UsersCreateBy");
  2163. b.Navigation("UsersLastUpdatedBy");
  2164. });
  2165. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TPRD_Product", b =>
  2166. {
  2167. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  2168. .WithMany()
  2169. .HasForeignKey("C_CreateBy")
  2170. .OnDelete(DeleteBehavior.Cascade)
  2171. .IsRequired();
  2172. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  2173. .WithMany()
  2174. .HasForeignKey("C_LastUpdatedBy");
  2175. b.Navigation("UsersCreateBy");
  2176. b.Navigation("UsersLastUpdatedBy");
  2177. });
  2178. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TPRD_Type", b =>
  2179. {
  2180. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  2181. .WithMany()
  2182. .HasForeignKey("C_CreateBy")
  2183. .OnDelete(DeleteBehavior.Cascade)
  2184. .IsRequired();
  2185. b.Navigation("UsersCreateBy");
  2186. });
  2187. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSEC_Record", b =>
  2188. {
  2189. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  2190. .WithMany()
  2191. .HasForeignKey("C_CreateBy")
  2192. .OnDelete(DeleteBehavior.Cascade)
  2193. .IsRequired();
  2194. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  2195. .WithMany()
  2196. .HasForeignKey("C_LastUpdatedBy")
  2197. .OnDelete(DeleteBehavior.Cascade)
  2198. .IsRequired();
  2199. b.Navigation("UsersCreateBy");
  2200. b.Navigation("UsersLastUpdatedBy");
  2201. });
  2202. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSEC_RecordItem", b =>
  2203. {
  2204. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  2205. .WithMany()
  2206. .HasForeignKey("C_CreateBy")
  2207. .OnDelete(DeleteBehavior.Cascade)
  2208. .IsRequired();
  2209. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  2210. .WithMany()
  2211. .HasForeignKey("C_LastUpdatedBy")
  2212. .OnDelete(DeleteBehavior.Cascade)
  2213. .IsRequired();
  2214. b.Navigation("UsersCreateBy");
  2215. b.Navigation("UsersLastUpdatedBy");
  2216. });
  2217. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_License", b =>
  2218. {
  2219. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  2220. .WithMany()
  2221. .HasForeignKey("C_CreateBy")
  2222. .OnDelete(DeleteBehavior.Cascade)
  2223. .IsRequired();
  2224. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  2225. .WithMany()
  2226. .HasForeignKey("C_LastUpdatedBy");
  2227. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_LicenseType", "LicenseTypeTypeCode")
  2228. .WithMany()
  2229. .HasForeignKey("C_TypeCode")
  2230. .OnDelete(DeleteBehavior.Cascade)
  2231. .IsRequired();
  2232. b.Navigation("LicenseTypeTypeCode");
  2233. b.Navigation("UsersCreateBy");
  2234. b.Navigation("UsersLastUpdatedBy");
  2235. });
  2236. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_LicenseType", b =>
  2237. {
  2238. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  2239. .WithMany()
  2240. .HasForeignKey("C_CreateBy")
  2241. .OnDelete(DeleteBehavior.Cascade)
  2242. .IsRequired();
  2243. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  2244. .WithMany()
  2245. .HasForeignKey("C_LastUpdatedBy");
  2246. b.Navigation("UsersCreateBy");
  2247. b.Navigation("UsersLastUpdatedBy");
  2248. });
  2249. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_LicenseTypePriv", b =>
  2250. {
  2251. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  2252. .WithMany()
  2253. .HasForeignKey("C_CreateBy")
  2254. .OnDelete(DeleteBehavior.Cascade)
  2255. .IsRequired();
  2256. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_LicenseType", "LicenseTypeCode")
  2257. .WithMany()
  2258. .HasForeignKey("C_LicenseTypeCode")
  2259. .OnDelete(DeleteBehavior.Cascade)
  2260. .IsRequired();
  2261. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_Priv", "PrivPrivilegeCode")
  2262. .WithMany()
  2263. .HasForeignKey("C_PrivilegeCode")
  2264. .OnDelete(DeleteBehavior.Cascade)
  2265. .IsRequired();
  2266. b.Navigation("LicenseTypeCode");
  2267. b.Navigation("PrivPrivilegeCode");
  2268. b.Navigation("UsersCreateBy");
  2269. });
  2270. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_Message", b =>
  2271. {
  2272. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  2273. .WithMany()
  2274. .HasForeignKey("C_CreateBy")
  2275. .OnDelete(DeleteBehavior.Cascade)
  2276. .IsRequired();
  2277. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  2278. .WithMany()
  2279. .HasForeignKey("C_LastUpdatedBy");
  2280. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersUserID")
  2281. .WithMany()
  2282. .HasForeignKey("C_UserID")
  2283. .OnDelete(DeleteBehavior.Cascade)
  2284. .IsRequired();
  2285. b.Navigation("UsersCreateBy");
  2286. b.Navigation("UsersLastUpdatedBy");
  2287. b.Navigation("UsersUserID");
  2288. });
  2289. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_Org", b =>
  2290. {
  2291. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  2292. .WithMany()
  2293. .HasForeignKey("C_CreateBy")
  2294. .OnDelete(DeleteBehavior.Cascade)
  2295. .IsRequired();
  2296. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  2297. .WithMany()
  2298. .HasForeignKey("C_LastUpdatedBy");
  2299. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_Org", "OrgParentCode")
  2300. .WithMany()
  2301. .HasForeignKey("C_ParentCode")
  2302. .OnDelete(DeleteBehavior.Cascade)
  2303. .IsRequired();
  2304. b.HasOne("Ropin.Inspection.Model.Entities.TPNT_StoreOrg", "StoreOrg")
  2305. .WithMany("Orgs")
  2306. .HasForeignKey("StoreOrgC_StoreCode", "StoreOrgC_OrgCode");
  2307. b.Navigation("OrgParentCode");
  2308. b.Navigation("StoreOrg");
  2309. b.Navigation("UsersCreateBy");
  2310. b.Navigation("UsersLastUpdatedBy");
  2311. });
  2312. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_Priv", b =>
  2313. {
  2314. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_Priv", "PrivPrivilegeCode")
  2315. .WithMany()
  2316. .HasForeignKey("C_ParentCode");
  2317. b.Navigation("PrivPrivilegeCode");
  2318. });
  2319. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_Role", b =>
  2320. {
  2321. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  2322. .WithMany()
  2323. .HasForeignKey("C_CreateBy")
  2324. .OnDelete(DeleteBehavior.Cascade)
  2325. .IsRequired();
  2326. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  2327. .WithMany()
  2328. .HasForeignKey("C_LastUpdatedBy");
  2329. b.Navigation("UsersCreateBy");
  2330. b.Navigation("UsersLastUpdatedBy");
  2331. });
  2332. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_RolePriv", b =>
  2333. {
  2334. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  2335. .WithMany()
  2336. .HasForeignKey("C_CreateBy")
  2337. .OnDelete(DeleteBehavior.Cascade)
  2338. .IsRequired();
  2339. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_Role", "Roles")
  2340. .WithMany()
  2341. .HasForeignKey("C_RoleCode")
  2342. .OnDelete(DeleteBehavior.Cascade)
  2343. .IsRequired();
  2344. b.Navigation("Roles");
  2345. b.Navigation("UsersCreateBy");
  2346. });
  2347. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_User", b =>
  2348. {
  2349. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  2350. .WithMany()
  2351. .HasForeignKey("C_CreateBy")
  2352. .OnDelete(DeleteBehavior.Cascade)
  2353. .IsRequired();
  2354. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  2355. .WithMany()
  2356. .HasForeignKey("C_LastUpdatedBy");
  2357. b.Navigation("UsersCreateBy");
  2358. b.Navigation("UsersLastUpdatedBy");
  2359. });
  2360. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_UserRole", b =>
  2361. {
  2362. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  2363. .WithMany()
  2364. .HasForeignKey("C_CreateBy")
  2365. .OnDelete(DeleteBehavior.Cascade)
  2366. .IsRequired();
  2367. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_Role", "Roles")
  2368. .WithMany()
  2369. .HasForeignKey("C_RoleCode")
  2370. .OnDelete(DeleteBehavior.Cascade)
  2371. .IsRequired();
  2372. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "Users")
  2373. .WithMany()
  2374. .HasForeignKey("C_UserCode")
  2375. .OnDelete(DeleteBehavior.Cascade)
  2376. .IsRequired();
  2377. b.Navigation("Roles");
  2378. b.Navigation("Users");
  2379. b.Navigation("UsersCreateBy");
  2380. });
  2381. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_Version", b =>
  2382. {
  2383. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersCreateBy")
  2384. .WithMany()
  2385. .HasForeignKey("C_CreateBy")
  2386. .OnDelete(DeleteBehavior.Cascade)
  2387. .IsRequired();
  2388. b.HasOne("Ropin.Inspection.Model.Entities.TSYS_User", "UsersLastUpdatedBy")
  2389. .WithMany()
  2390. .HasForeignKey("C_LastUpdatedBy");
  2391. b.Navigation("UsersCreateBy");
  2392. b.Navigation("UsersLastUpdatedBy");
  2393. });
  2394. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TaskInfoDto", b =>
  2395. {
  2396. b.HasOne("Ropin.Inspection.Model.Entities.TasksQz", null)
  2397. .WithMany("Triggers")
  2398. .HasForeignKey("TasksQzId");
  2399. });
  2400. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TPNT_Store", b =>
  2401. {
  2402. b.Navigation("Areas");
  2403. });
  2404. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TPNT_StoreOrg", b =>
  2405. {
  2406. b.Navigation("Orgs");
  2407. b.Navigation("Stores");
  2408. });
  2409. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TSYS_License", b =>
  2410. {
  2411. b.Navigation("Stores");
  2412. });
  2413. modelBuilder.Entity("Ropin.Inspection.Model.Entities.TasksQz", b =>
  2414. {
  2415. b.Navigation("Triggers");
  2416. });
  2417. #pragma warning restore 612, 618
  2418. }
  2419. }
  2420. }