spDbContextModelSnapshot.cs 63 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746
  1. // <auto-generated />
  2. using System;
  3. using Microsoft.EntityFrameworkCore;
  4. using Microsoft.EntityFrameworkCore.Infrastructure;
  5. using Microsoft.EntityFrameworkCore.Metadata;
  6. using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
  7. using wispro.sp.api;
  8. namespace wispro.sp.api.Migrations
  9. {
  10. [DbContext(typeof(spDbContext))]
  11. partial class spDbContextModelSnapshot : ModelSnapshot
  12. {
  13. protected override void BuildModel(ModelBuilder modelBuilder)
  14. {
  15. #pragma warning disable 612, 618
  16. modelBuilder
  17. .HasAnnotation("Relational:MaxIdentifierLength", 128)
  18. .HasAnnotation("ProductVersion", "5.0.9")
  19. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  20. modelBuilder.Entity("wispro.sp.entity.AppealRecord", b =>
  21. {
  22. b.Property<int>("Id")
  23. .ValueGeneratedOnAdd()
  24. .HasColumnType("int")
  25. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  26. b.Property<DateTime>("CreateTime")
  27. .HasColumnType("datetime2");
  28. b.Property<int>("CreaterId")
  29. .HasColumnType("int");
  30. b.Property<int>("ItemId")
  31. .HasColumnType("int");
  32. b.Property<string>("Reason")
  33. .HasMaxLength(500)
  34. .HasColumnType("nvarchar(500)");
  35. b.Property<DateTime?>("ReviewTime")
  36. .HasColumnType("datetime2");
  37. b.Property<int?>("ReviewerId")
  38. .HasColumnType("int");
  39. b.Property<string>("ReviewerMemo")
  40. .HasColumnType("nvarchar(max)");
  41. b.Property<int>("State")
  42. .HasColumnType("int");
  43. b.Property<int>("TypeId")
  44. .HasColumnType("int");
  45. b.HasKey("Id");
  46. b.HasIndex("CreaterId");
  47. b.HasIndex("ItemId");
  48. b.HasIndex("ReviewerId");
  49. b.HasIndex("TypeId");
  50. b.ToTable("AppealRecord");
  51. });
  52. modelBuilder.Entity("wispro.sp.entity.AppealType", b =>
  53. {
  54. b.Property<int>("Id")
  55. .ValueGeneratedOnAdd()
  56. .HasColumnType("int")
  57. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  58. b.Property<string>("CanDoExpress")
  59. .HasMaxLength(500)
  60. .HasColumnType("nvarchar(500)");
  61. b.Property<string>("Name")
  62. .HasMaxLength(50)
  63. .HasColumnType("nvarchar(50)");
  64. b.Property<string>("ReviewerExpress")
  65. .HasMaxLength(500)
  66. .HasColumnType("nvarchar(500)");
  67. b.Property<int>("Type")
  68. .HasColumnType("int");
  69. b.HasKey("Id");
  70. b.ToTable("AppealType");
  71. b.HasData(
  72. new
  73. {
  74. Id = 1,
  75. CanDoExpress = "p.ItemStaffs.Count()>1",
  76. Name = "绩效点数分配比率",
  77. Type = 0
  78. },
  79. new
  80. {
  81. Id = 2,
  82. CanDoExpress = "p.DoItem==\"新申请\"",
  83. Name = "案件系数复核",
  84. ReviewerExpress = "p.Reviewer",
  85. Type = 0
  86. },
  87. new
  88. {
  89. Id = 3,
  90. CanDoExpress = "p.DoItem==\"新申请\"",
  91. Name = "处理事项系数复核",
  92. ReviewerExpress = "p.Reviewer",
  93. Type = 0
  94. },
  95. new
  96. {
  97. Id = 4,
  98. CanDoExpress = "",
  99. Name = "案件缺漏申诉",
  100. ReviewerExpress = "p.Reviewer",
  101. Type = 1
  102. },
  103. new
  104. {
  105. Id = 5,
  106. CanDoExpress = "p.isDanger()",
  107. Name = "案件严重超期说明",
  108. Type = 0
  109. },
  110. new
  111. {
  112. Id = 6,
  113. CanDoExpress = "p.DoItem==\"新申请\" || p.DoItem==\"翻译\"",
  114. Name = "按照翻译字数算绩效备注",
  115. Type = 0
  116. });
  117. });
  118. modelBuilder.Entity("wispro.sp.entity.AttachFile", b =>
  119. {
  120. b.Property<Guid>("Id")
  121. .ValueGeneratedOnAdd()
  122. .HasColumnType("uniqueidentifier");
  123. b.Property<int?>("AppealRecordId")
  124. .HasColumnType("int");
  125. b.Property<string>("Name")
  126. .HasMaxLength(200)
  127. .HasColumnType("nvarchar(200)");
  128. b.Property<string>("SavePath")
  129. .HasMaxLength(200)
  130. .HasColumnType("nvarchar(200)");
  131. b.Property<int>("UploadUserId")
  132. .HasColumnType("int");
  133. b.HasKey("Id");
  134. b.HasIndex("AppealRecordId");
  135. b.HasIndex("UploadUserId");
  136. b.ToTable("AttachFile");
  137. });
  138. modelBuilder.Entity("wispro.sp.entity.BasePointRule", b =>
  139. {
  140. b.Property<int>("Id")
  141. .ValueGeneratedOnAdd()
  142. .HasColumnType("int")
  143. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  144. b.Property<string>("PointExpress")
  145. .HasMaxLength(100)
  146. .HasColumnType("nvarchar(100)");
  147. b.Property<int>("Priority")
  148. .HasColumnType("int");
  149. b.Property<string>("Rule")
  150. .HasMaxLength(1000)
  151. .HasColumnType("nvarchar(1000)");
  152. b.Property<string>("Type")
  153. .HasMaxLength(20)
  154. .HasColumnType("nvarchar(20)");
  155. b.HasKey("Id");
  156. b.ToTable("BasePointRule");
  157. });
  158. modelBuilder.Entity("wispro.sp.entity.CalMonth", b =>
  159. {
  160. b.Property<int>("Id")
  161. .ValueGeneratedOnAdd()
  162. .HasColumnType("int")
  163. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  164. b.Property<int>("Month")
  165. .HasColumnType("int")
  166. .HasColumnName("month");
  167. b.Property<int>("Status")
  168. .HasColumnType("int")
  169. .HasColumnName("status");
  170. b.Property<int>("Year")
  171. .HasColumnType("int")
  172. .HasColumnName("year");
  173. b.HasKey("Id");
  174. b.ToTable("CalMonth");
  175. });
  176. modelBuilder.Entity("wispro.sp.entity.CaseCeoffcient", b =>
  177. {
  178. b.Property<string>("Ceoffcient")
  179. .HasColumnType("nvarchar(450)");
  180. b.Property<double>("Value")
  181. .HasColumnType("float");
  182. b.HasKey("Ceoffcient");
  183. b.ToTable("CaseCeofficient");
  184. b.HasData(
  185. new
  186. {
  187. Ceoffcient = "S",
  188. Value = 2.5
  189. },
  190. new
  191. {
  192. Ceoffcient = "A",
  193. Value = 1.5
  194. },
  195. new
  196. {
  197. Ceoffcient = "B",
  198. Value = 1.0
  199. },
  200. new
  201. {
  202. Ceoffcient = "C",
  203. Value = 0.69999999999999996
  204. },
  205. new
  206. {
  207. Ceoffcient = "D",
  208. Value = 0.40000000000000002
  209. });
  210. });
  211. modelBuilder.Entity("wispro.sp.entity.Customer", b =>
  212. {
  213. b.Property<int>("Id")
  214. .ValueGeneratedOnAdd()
  215. .HasColumnType("int")
  216. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  217. b.Property<string>("Address")
  218. .HasMaxLength(500)
  219. .HasColumnType("nvarchar(500)");
  220. b.Property<string>("ContactMan")
  221. .HasMaxLength(50)
  222. .HasColumnType("nvarchar(50)");
  223. b.Property<string>("Name")
  224. .IsRequired()
  225. .HasMaxLength(200)
  226. .HasColumnType("nvarchar(200)");
  227. b.Property<string>("Phone")
  228. .HasMaxLength(50)
  229. .HasColumnType("nvarchar(50)");
  230. b.Property<int?>("ResponseManId")
  231. .HasColumnType("int");
  232. b.HasKey("Id");
  233. b.HasIndex("ResponseManId");
  234. b.ToTable("Customer");
  235. });
  236. modelBuilder.Entity("wispro.sp.entity.InputField", b =>
  237. {
  238. b.Property<int>("Id")
  239. .ValueGeneratedOnAdd()
  240. .HasColumnType("int")
  241. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  242. b.Property<int>("AppealState")
  243. .HasColumnType("int");
  244. b.Property<int>("AppealTypeId")
  245. .HasColumnType("int");
  246. b.Property<bool>("CanMuliSelect")
  247. .HasColumnType("bit");
  248. b.Property<string>("FieldName")
  249. .HasMaxLength(50)
  250. .HasColumnType("nvarchar(50)");
  251. b.Property<string>("FieldType")
  252. .HasMaxLength(50)
  253. .HasColumnType("nvarchar(50)");
  254. b.Property<string>("MapObjectField")
  255. .HasMaxLength(50)
  256. .HasColumnType("nvarchar(50)");
  257. b.Property<string>("MapObjectFieldLabel")
  258. .HasColumnType("nvarchar(max)");
  259. b.Property<int?>("MaxSize")
  260. .HasColumnType("int");
  261. b.HasKey("Id");
  262. b.HasIndex("AppealTypeId");
  263. b.ToTable("InputField");
  264. b.HasData(
  265. new
  266. {
  267. Id = 1,
  268. AppealState = 0,
  269. AppealTypeId = 1,
  270. CanMuliSelect = false,
  271. FieldName = "分配比率",
  272. FieldType = "System.Double",
  273. MapObjectField = "ItemStaffs.PerformancePoint",
  274. MapObjectFieldLabel = "ItemStaffs.DoPerson.Name"
  275. },
  276. new
  277. {
  278. Id = 3,
  279. AppealState = 0,
  280. AppealTypeId = 1,
  281. CanMuliSelect = false,
  282. FieldName = "原因",
  283. FieldType = "System.String"
  284. },
  285. new
  286. {
  287. Id = 4,
  288. AppealState = 1,
  289. AppealTypeId = 1,
  290. CanMuliSelect = false,
  291. FieldName = "备注",
  292. FieldType = "System.String"
  293. },
  294. new
  295. {
  296. Id = 5,
  297. AppealState = 1,
  298. AppealTypeId = 1,
  299. CanMuliSelect = false,
  300. FieldName = "审核意见",
  301. FieldType = "System.String"
  302. },
  303. new
  304. {
  305. Id = 6,
  306. AppealState = 0,
  307. AppealTypeId = 2,
  308. CanMuliSelect = false,
  309. FieldName = "案件系数",
  310. FieldType = "System.String",
  311. MapObjectField = "CaseCoefficient"
  312. },
  313. new
  314. {
  315. Id = 9,
  316. AppealState = 1,
  317. AppealTypeId = 2,
  318. CanMuliSelect = false,
  319. FieldName = "备注",
  320. FieldType = "System.String"
  321. },
  322. new
  323. {
  324. Id = 10,
  325. AppealState = 1,
  326. AppealTypeId = 2,
  327. CanMuliSelect = false,
  328. FieldName = "审核意见",
  329. FieldType = "System.String"
  330. },
  331. new
  332. {
  333. Id = 11,
  334. AppealState = 0,
  335. AppealTypeId = 3,
  336. CanMuliSelect = false,
  337. FieldName = "处理事项系数",
  338. FieldType = "System.String",
  339. MapObjectField = "DoItemCoefficient"
  340. },
  341. new
  342. {
  343. Id = 12,
  344. AppealState = 1,
  345. AppealTypeId = 3,
  346. CanMuliSelect = false,
  347. FieldName = "备注",
  348. FieldType = "System.String"
  349. },
  350. new
  351. {
  352. Id = 13,
  353. AppealState = 1,
  354. AppealTypeId = 3,
  355. CanMuliSelect = false,
  356. FieldName = "审核意见",
  357. FieldType = "System.String"
  358. },
  359. new
  360. {
  361. Id = 14,
  362. AppealState = 0,
  363. AppealTypeId = 4,
  364. CanMuliSelect = false,
  365. FieldName = "我方文号",
  366. FieldType = "System.String"
  367. },
  368. new
  369. {
  370. Id = 15,
  371. AppealState = 0,
  372. AppealTypeId = 4,
  373. CanMuliSelect = false,
  374. FieldName = "处理事项",
  375. FieldType = "System.String"
  376. },
  377. new
  378. {
  379. Id = 16,
  380. AppealState = 1,
  381. AppealTypeId = 4,
  382. CanMuliSelect = false,
  383. FieldName = "备注",
  384. FieldType = "System.String"
  385. },
  386. new
  387. {
  388. Id = 17,
  389. AppealState = 1,
  390. AppealTypeId = 4,
  391. CanMuliSelect = false,
  392. FieldName = "审核意见",
  393. FieldType = "System.String"
  394. },
  395. new
  396. {
  397. Id = 18,
  398. AppealState = 0,
  399. AppealTypeId = 5,
  400. CanMuliSelect = false,
  401. FieldName = "超期说明",
  402. FieldType = "System.String",
  403. MapObjectField = "OverDueMemo"
  404. },
  405. new
  406. {
  407. Id = 21,
  408. AppealState = 1,
  409. AppealTypeId = 5,
  410. CanMuliSelect = false,
  411. FieldName = "审核意见",
  412. FieldType = "System.String"
  413. },
  414. new
  415. {
  416. Id = 22,
  417. AppealState = 1,
  418. AppealTypeId = 5,
  419. CanMuliSelect = false,
  420. FieldName = "备注",
  421. FieldType = "System.String"
  422. },
  423. new
  424. {
  425. Id = 19,
  426. AppealState = 0,
  427. AppealTypeId = 6,
  428. CanMuliSelect = false,
  429. FieldName = "翻译类型",
  430. FieldType = "System.String",
  431. MapObjectField = "AgentFeedbackMemo"
  432. },
  433. new
  434. {
  435. Id = 20,
  436. AppealState = 0,
  437. AppealTypeId = 6,
  438. CanMuliSelect = false,
  439. FieldName = "翻译字数",
  440. FieldType = "System.Int32",
  441. MapObjectField = "WordCount"
  442. },
  443. new
  444. {
  445. Id = 23,
  446. AppealState = 1,
  447. AppealTypeId = 6,
  448. CanMuliSelect = false,
  449. FieldName = "审核意见",
  450. FieldType = "System.Int32"
  451. },
  452. new
  453. {
  454. Id = 24,
  455. AppealState = 1,
  456. AppealTypeId = 6,
  457. CanMuliSelect = false,
  458. FieldName = "翻译字数",
  459. FieldType = "System.Int32",
  460. MapObjectField = "WordCount"
  461. });
  462. });
  463. modelBuilder.Entity("wispro.sp.entity.InputFieldValue", b =>
  464. {
  465. b.Property<int>("Id")
  466. .ValueGeneratedOnAdd()
  467. .HasColumnType("int")
  468. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  469. b.Property<int>("AppealRecordId")
  470. .HasColumnType("int");
  471. b.Property<int>("InputFieldId")
  472. .HasColumnType("int");
  473. b.Property<string>("Label")
  474. .HasColumnType("nvarchar(max)");
  475. b.Property<string>("Value")
  476. .HasMaxLength(500)
  477. .HasColumnType("nvarchar(500)");
  478. b.Property<string>("mapExpress")
  479. .HasColumnType("nvarchar(max)");
  480. b.HasKey("Id");
  481. b.HasIndex("AppealRecordId");
  482. b.HasIndex("InputFieldId");
  483. b.ToTable("InputFieldValue");
  484. });
  485. modelBuilder.Entity("wispro.sp.entity.ItemStaff", b =>
  486. {
  487. b.Property<int>("ItemId")
  488. .HasColumnType("int");
  489. b.Property<int>("DoPersonId")
  490. .HasColumnType("int");
  491. b.Property<double?>("PerformancePoint")
  492. .HasColumnType("float");
  493. b.HasKey("ItemId", "DoPersonId");
  494. b.HasIndex("DoPersonId");
  495. b.ToTable("ItemStaff");
  496. });
  497. modelBuilder.Entity("wispro.sp.entity.Message", b =>
  498. {
  499. b.Property<Guid>("Id")
  500. .ValueGeneratedOnAdd()
  501. .HasColumnType("uniqueidentifier");
  502. b.Property<int>("FromId")
  503. .HasColumnType("int");
  504. b.Property<string>("MessageInfo")
  505. .HasMaxLength(500)
  506. .HasColumnType("nvarchar(500)");
  507. b.Property<int>("Type")
  508. .HasColumnType("int");
  509. b.HasKey("Id");
  510. b.HasIndex("FromId");
  511. b.ToTable("Message");
  512. });
  513. modelBuilder.Entity("wispro.sp.entity.MessagePerformanceItem", b =>
  514. {
  515. b.Property<int>("ItemId")
  516. .HasColumnType("int");
  517. b.Property<Guid>("MessageId")
  518. .HasColumnType("uniqueidentifier");
  519. b.HasKey("ItemId", "MessageId");
  520. b.HasIndex("MessageId");
  521. b.ToTable("MessagePerformanceItems");
  522. });
  523. modelBuilder.Entity("wispro.sp.entity.MessageReadRecord", b =>
  524. {
  525. b.Property<Guid>("MessageId")
  526. .HasColumnType("uniqueidentifier");
  527. b.Property<int>("StaffId")
  528. .HasColumnType("int");
  529. b.Property<Guid?>("MessageId1")
  530. .HasColumnType("uniqueidentifier");
  531. b.Property<bool>("isReaded")
  532. .HasColumnType("bit");
  533. b.HasKey("MessageId", "StaffId");
  534. b.HasIndex("MessageId1");
  535. b.HasIndex("StaffId");
  536. b.ToTable("MessageReadRecord");
  537. });
  538. modelBuilder.Entity("wispro.sp.entity.PerformanceItem", b =>
  539. {
  540. b.Property<int>("Id")
  541. .ValueGeneratedOnAdd()
  542. .HasColumnType("int")
  543. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  544. b.Property<string>("AgentFeedbackMemo")
  545. .HasColumnType("nvarchar(max)");
  546. b.Property<string>("ApplicationName")
  547. .HasMaxLength(200)
  548. .HasColumnType("nvarchar(200)");
  549. b.Property<string>("ApplicationType")
  550. .HasMaxLength(50)
  551. .HasColumnType("nvarchar(50)");
  552. b.Property<decimal?>("BasePoint")
  553. .HasColumnType("numeric(18,2)");
  554. b.Property<string>("BusinessType")
  555. .HasMaxLength(50)
  556. .HasColumnType("nvarchar(50)");
  557. b.Property<int>("CalMonthId")
  558. .HasColumnType("int");
  559. b.Property<string>("CaseCoefficient")
  560. .HasMaxLength(10)
  561. .HasColumnType("nvarchar(10)");
  562. b.Property<string>("CaseMemo")
  563. .HasColumnType("nvarchar(max)");
  564. b.Property<string>("CaseName")
  565. .HasMaxLength(500)
  566. .HasColumnType("nvarchar(500)");
  567. b.Property<string>("CaseNo")
  568. .HasMaxLength(50)
  569. .HasColumnType("nvarchar(50)");
  570. b.Property<string>("CaseStage")
  571. .HasMaxLength(50)
  572. .HasColumnType("nvarchar(50)");
  573. b.Property<string>("CaseState")
  574. .HasMaxLength(50)
  575. .HasColumnType("nvarchar(50)");
  576. b.Property<string>("CaseType")
  577. .HasMaxLength(50)
  578. .HasColumnType("nvarchar(50)");
  579. b.Property<int?>("CustomerId")
  580. .HasColumnType("int");
  581. b.Property<DateTime?>("CustomerLimitDate")
  582. .HasColumnType("date");
  583. b.Property<string>("DoItem")
  584. .HasMaxLength(50)
  585. .HasColumnType("nvarchar(50)");
  586. b.Property<string>("DoItemCoefficient")
  587. .HasMaxLength(50)
  588. .HasColumnType("nvarchar(50)");
  589. b.Property<string>("DoItemMemo")
  590. .HasMaxLength(500)
  591. .HasColumnType("nvarchar(500)");
  592. b.Property<string>("DoItemState")
  593. .HasMaxLength(50)
  594. .HasColumnType("nvarchar(50)");
  595. b.Property<DateTime?>("EntrustingDate")
  596. .HasColumnType("date");
  597. b.Property<DateTime?>("FinalizationDate")
  598. .HasColumnType("date");
  599. b.Property<DateTime?>("FinishedDate")
  600. .HasColumnType("date");
  601. b.Property<DateTime?>("FirstDraftDate")
  602. .HasColumnType("date");
  603. b.Property<DateTime?>("InternalDate")
  604. .HasColumnType("date");
  605. b.Property<string>("OverDueMemo")
  606. .HasMaxLength(100)
  607. .HasColumnType("nvarchar(100)");
  608. b.Property<int?>("PreOastaffId")
  609. .HasColumnType("int")
  610. .HasColumnName("PreOAStaffId");
  611. b.Property<string>("ReturnCasseNo")
  612. .HasColumnType("nvarchar(max)");
  613. b.Property<DateTime?>("ReturnDate")
  614. .HasColumnType("date");
  615. b.Property<int?>("ReviewerId")
  616. .HasColumnType("int");
  617. b.Property<int?>("Status")
  618. .HasColumnType("int");
  619. b.Property<string>("Type")
  620. .HasColumnType("nvarchar(max)");
  621. b.Property<int?>("WordCount")
  622. .HasColumnType("int");
  623. b.HasKey("Id");
  624. b.HasIndex("CalMonthId");
  625. b.HasIndex("CustomerId");
  626. b.HasIndex("PreOastaffId");
  627. b.HasIndex("ReviewerId");
  628. b.ToTable("PerformanceItem");
  629. });
  630. modelBuilder.Entity("wispro.sp.entity.SelectValue", b =>
  631. {
  632. b.Property<int>("Id")
  633. .ValueGeneratedOnAdd()
  634. .HasColumnType("int")
  635. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  636. b.Property<int>("InputFieldId")
  637. .HasColumnType("int");
  638. b.Property<string>("Value")
  639. .HasColumnType("nvarchar(max)");
  640. b.HasKey("Id");
  641. b.HasIndex("InputFieldId");
  642. b.ToTable("SelectValue");
  643. b.HasData(
  644. new
  645. {
  646. Id = 1,
  647. InputFieldId = 5,
  648. Value = "同意"
  649. },
  650. new
  651. {
  652. Id = 2,
  653. InputFieldId = 5,
  654. Value = "拒绝"
  655. },
  656. new
  657. {
  658. Id = 3,
  659. InputFieldId = 10,
  660. Value = "同意"
  661. },
  662. new
  663. {
  664. Id = 4,
  665. InputFieldId = 10,
  666. Value = "拒绝"
  667. },
  668. new
  669. {
  670. Id = 5,
  671. InputFieldId = 13,
  672. Value = "同意"
  673. },
  674. new
  675. {
  676. Id = 6,
  677. InputFieldId = 13,
  678. Value = "拒绝"
  679. },
  680. new
  681. {
  682. Id = 7,
  683. InputFieldId = 17,
  684. Value = "同意"
  685. },
  686. new
  687. {
  688. Id = 8,
  689. InputFieldId = 17,
  690. Value = "拒绝"
  691. },
  692. new
  693. {
  694. Id = 9,
  695. InputFieldId = 6,
  696. Value = "S"
  697. },
  698. new
  699. {
  700. Id = 10,
  701. InputFieldId = 6,
  702. Value = "A"
  703. },
  704. new
  705. {
  706. Id = 11,
  707. InputFieldId = 6,
  708. Value = "B"
  709. },
  710. new
  711. {
  712. Id = 12,
  713. InputFieldId = 6,
  714. Value = "C"
  715. },
  716. new
  717. {
  718. Id = 13,
  719. InputFieldId = 6,
  720. Value = "D"
  721. },
  722. new
  723. {
  724. Id = 14,
  725. InputFieldId = 11,
  726. Value = "实质"
  727. },
  728. new
  729. {
  730. Id = 15,
  731. InputFieldId = 11,
  732. Value = "形式"
  733. },
  734. new
  735. {
  736. Id = 16,
  737. InputFieldId = 19,
  738. Value = "中-德"
  739. },
  740. new
  741. {
  742. Id = 17,
  743. InputFieldId = 19,
  744. Value = "中-英"
  745. },
  746. new
  747. {
  748. Id = 18,
  749. InputFieldId = 19,
  750. Value = "英-中"
  751. },
  752. new
  753. {
  754. Id = 19,
  755. InputFieldId = 22,
  756. Value = "同意"
  757. },
  758. new
  759. {
  760. Id = 20,
  761. InputFieldId = 22,
  762. Value = "拒绝"
  763. });
  764. });
  765. modelBuilder.Entity("wispro.sp.entity.Staff", b =>
  766. {
  767. b.Property<int>("Id")
  768. .ValueGeneratedOnAdd()
  769. .HasColumnType("int")
  770. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  771. b.Property<string>("Account")
  772. .IsRequired()
  773. .HasMaxLength(50)
  774. .HasColumnType("nvarchar(50)");
  775. b.Property<string>("Department")
  776. .HasMaxLength(50)
  777. .HasColumnType("nvarchar(50)");
  778. b.Property<DateTime?>("EntyDate")
  779. .HasColumnType("date");
  780. b.Property<bool>("IsCalPerformsnce")
  781. .HasColumnType("bit")
  782. .HasColumnName("isCalPerformsnce");
  783. b.Property<bool>("IsOnJob")
  784. .HasColumnType("bit");
  785. b.Property<string>("Mail")
  786. .HasColumnType("nvarchar(max)");
  787. b.Property<string>("Memo")
  788. .HasColumnType("nvarchar(max)");
  789. b.Property<string>("Mobile")
  790. .HasColumnType("nvarchar(max)");
  791. b.Property<string>("Name")
  792. .IsRequired()
  793. .HasMaxLength(50)
  794. .HasColumnType("nvarchar(50)");
  795. b.Property<string>("Password")
  796. .IsRequired()
  797. .HasColumnType("nvarchar(max)");
  798. b.Property<string>("Sex")
  799. .HasColumnType("nvarchar(max)");
  800. b.Property<int?>("StaffGradeId")
  801. .HasColumnType("int");
  802. b.Property<string>("Status")
  803. .IsRequired()
  804. .HasMaxLength(25)
  805. .HasColumnType("nvarchar(25)");
  806. b.Property<string>("Tel")
  807. .HasColumnType("nvarchar(max)");
  808. b.Property<string>("WorkPlace")
  809. .HasMaxLength(50)
  810. .HasColumnType("nvarchar(50)");
  811. b.HasKey("Id");
  812. b.HasIndex("StaffGradeId");
  813. b.ToTable("Staff");
  814. });
  815. modelBuilder.Entity("wispro.sp.entity.StaffGrade", b =>
  816. {
  817. b.Property<int>("Id")
  818. .ValueGeneratedOnAdd()
  819. .HasColumnType("int")
  820. .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn);
  821. b.Property<double>("Coefficient")
  822. .HasColumnType("float");
  823. b.Property<string>("Grade")
  824. .IsRequired()
  825. .HasMaxLength(5)
  826. .HasColumnType("nchar(5)")
  827. .IsFixedLength(true);
  828. b.HasKey("Id");
  829. b.ToTable("StaffGrade");
  830. b.HasData(
  831. new
  832. {
  833. Id = 1,
  834. Coefficient = 1.2,
  835. Grade = "S级"
  836. },
  837. new
  838. {
  839. Id = 2,
  840. Coefficient = 1.1000000000000001,
  841. Grade = "A3级"
  842. },
  843. new
  844. {
  845. Id = 3,
  846. Coefficient = 1.1000000000000001,
  847. Grade = "A2级"
  848. },
  849. new
  850. {
  851. Id = 4,
  852. Coefficient = 1.1000000000000001,
  853. Grade = "A1级"
  854. },
  855. new
  856. {
  857. Id = 5,
  858. Coefficient = 1.0,
  859. Grade = "B3级"
  860. },
  861. new
  862. {
  863. Id = 6,
  864. Coefficient = 1.0,
  865. Grade = "B2级"
  866. },
  867. new
  868. {
  869. Id = 7,
  870. Coefficient = 0.90000000000000002,
  871. Grade = "B1级"
  872. },
  873. new
  874. {
  875. Id = 8,
  876. Coefficient = 0.90000000000000002,
  877. Grade = "C3级"
  878. },
  879. new
  880. {
  881. Id = 9,
  882. Coefficient = 0.69999999999999996,
  883. Grade = "C2级"
  884. },
  885. new
  886. {
  887. Id = 10,
  888. Coefficient = 0.69999999999999996,
  889. Grade = "C1级"
  890. },
  891. new
  892. {
  893. Id = 11,
  894. Coefficient = 0.59999999999999998,
  895. Grade = "D3级"
  896. },
  897. new
  898. {
  899. Id = 12,
  900. Coefficient = 0.59999999999999998,
  901. Grade = "D2级"
  902. },
  903. new
  904. {
  905. Id = 13,
  906. Coefficient = 0.5,
  907. Grade = "D1级"
  908. },
  909. new
  910. {
  911. Id = 14,
  912. Coefficient = 1.1000000000000001,
  913. Grade = "A级"
  914. },
  915. new
  916. {
  917. Id = 15,
  918. Coefficient = 1.0,
  919. Grade = "C级"
  920. },
  921. new
  922. {
  923. Id = 16,
  924. Coefficient = 0.90000000000000002,
  925. Grade = "D级"
  926. });
  927. });
  928. modelBuilder.Entity("wispro.sp.entity.VerifyCoefficient", b =>
  929. {
  930. b.Property<int>("CheckerId")
  931. .HasColumnType("int");
  932. b.Property<int>("DoPersonId")
  933. .HasColumnType("int");
  934. b.Property<double>("Coefficient")
  935. .HasColumnType("float");
  936. b.HasKey("CheckerId", "DoPersonId");
  937. b.HasIndex("DoPersonId");
  938. b.ToTable("VerifyCoefficient");
  939. b.HasData(
  940. new
  941. {
  942. CheckerId = 1,
  943. DoPersonId = 5,
  944. Coefficient = 0.29999999999999999
  945. },
  946. new
  947. {
  948. CheckerId = 1,
  949. DoPersonId = 6,
  950. Coefficient = 0.29999999999999999
  951. },
  952. new
  953. {
  954. CheckerId = 1,
  955. DoPersonId = 7,
  956. Coefficient = 0.29999999999999999
  957. },
  958. new
  959. {
  960. CheckerId = 1,
  961. DoPersonId = 8,
  962. Coefficient = 0.29999999999999999
  963. },
  964. new
  965. {
  966. CheckerId = 1,
  967. DoPersonId = 9,
  968. Coefficient = 0.40000000000000002
  969. },
  970. new
  971. {
  972. CheckerId = 1,
  973. DoPersonId = 10,
  974. Coefficient = 0.40000000000000002
  975. },
  976. new
  977. {
  978. CheckerId = 1,
  979. DoPersonId = 11,
  980. Coefficient = 0.5
  981. },
  982. new
  983. {
  984. CheckerId = 1,
  985. DoPersonId = 12,
  986. Coefficient = 0.5
  987. },
  988. new
  989. {
  990. CheckerId = 1,
  991. DoPersonId = 13,
  992. Coefficient = 0.59999999999999998
  993. },
  994. new
  995. {
  996. CheckerId = 2,
  997. DoPersonId = 5,
  998. Coefficient = 0.20000000000000001
  999. },
  1000. new
  1001. {
  1002. CheckerId = 2,
  1003. DoPersonId = 6,
  1004. Coefficient = 0.20000000000000001
  1005. },
  1006. new
  1007. {
  1008. CheckerId = 2,
  1009. DoPersonId = 7,
  1010. Coefficient = 0.20000000000000001
  1011. },
  1012. new
  1013. {
  1014. CheckerId = 2,
  1015. DoPersonId = 8,
  1016. Coefficient = 0.20000000000000001
  1017. },
  1018. new
  1019. {
  1020. CheckerId = 2,
  1021. DoPersonId = 9,
  1022. Coefficient = 0.29999999999999999
  1023. },
  1024. new
  1025. {
  1026. CheckerId = 2,
  1027. DoPersonId = 10,
  1028. Coefficient = 0.29999999999999999
  1029. },
  1030. new
  1031. {
  1032. CheckerId = 2,
  1033. DoPersonId = 11,
  1034. Coefficient = 0.40000000000000002
  1035. },
  1036. new
  1037. {
  1038. CheckerId = 2,
  1039. DoPersonId = 12,
  1040. Coefficient = 0.40000000000000002
  1041. },
  1042. new
  1043. {
  1044. CheckerId = 2,
  1045. DoPersonId = 13,
  1046. Coefficient = 0.5
  1047. },
  1048. new
  1049. {
  1050. CheckerId = 3,
  1051. DoPersonId = 5,
  1052. Coefficient = 0.20000000000000001
  1053. },
  1054. new
  1055. {
  1056. CheckerId = 3,
  1057. DoPersonId = 6,
  1058. Coefficient = 0.20000000000000001
  1059. },
  1060. new
  1061. {
  1062. CheckerId = 3,
  1063. DoPersonId = 7,
  1064. Coefficient = 0.20000000000000001
  1065. },
  1066. new
  1067. {
  1068. CheckerId = 3,
  1069. DoPersonId = 8,
  1070. Coefficient = 0.20000000000000001
  1071. },
  1072. new
  1073. {
  1074. CheckerId = 3,
  1075. DoPersonId = 9,
  1076. Coefficient = 0.29999999999999999
  1077. },
  1078. new
  1079. {
  1080. CheckerId = 3,
  1081. DoPersonId = 10,
  1082. Coefficient = 0.29999999999999999
  1083. },
  1084. new
  1085. {
  1086. CheckerId = 3,
  1087. DoPersonId = 11,
  1088. Coefficient = 0.40000000000000002
  1089. },
  1090. new
  1091. {
  1092. CheckerId = 3,
  1093. DoPersonId = 12,
  1094. Coefficient = 0.40000000000000002
  1095. },
  1096. new
  1097. {
  1098. CheckerId = 3,
  1099. DoPersonId = 13,
  1100. Coefficient = 0.5
  1101. },
  1102. new
  1103. {
  1104. CheckerId = 4,
  1105. DoPersonId = 5,
  1106. Coefficient = 0.20000000000000001
  1107. },
  1108. new
  1109. {
  1110. CheckerId = 4,
  1111. DoPersonId = 6,
  1112. Coefficient = 0.20000000000000001
  1113. },
  1114. new
  1115. {
  1116. CheckerId = 4,
  1117. DoPersonId = 7,
  1118. Coefficient = 0.20000000000000001
  1119. },
  1120. new
  1121. {
  1122. CheckerId = 4,
  1123. DoPersonId = 8,
  1124. Coefficient = 0.20000000000000001
  1125. },
  1126. new
  1127. {
  1128. CheckerId = 4,
  1129. DoPersonId = 9,
  1130. Coefficient = 0.29999999999999999
  1131. },
  1132. new
  1133. {
  1134. CheckerId = 4,
  1135. DoPersonId = 10,
  1136. Coefficient = 0.29999999999999999
  1137. },
  1138. new
  1139. {
  1140. CheckerId = 4,
  1141. DoPersonId = 11,
  1142. Coefficient = 0.40000000000000002
  1143. },
  1144. new
  1145. {
  1146. CheckerId = 4,
  1147. DoPersonId = 12,
  1148. Coefficient = 0.40000000000000002
  1149. },
  1150. new
  1151. {
  1152. CheckerId = 4,
  1153. DoPersonId = 13,
  1154. Coefficient = 0.5
  1155. },
  1156. new
  1157. {
  1158. CheckerId = 5,
  1159. DoPersonId = 5,
  1160. Coefficient = 0.20000000000000001
  1161. },
  1162. new
  1163. {
  1164. CheckerId = 5,
  1165. DoPersonId = 6,
  1166. Coefficient = 0.20000000000000001
  1167. },
  1168. new
  1169. {
  1170. CheckerId = 5,
  1171. DoPersonId = 7,
  1172. Coefficient = 0.20000000000000001
  1173. },
  1174. new
  1175. {
  1176. CheckerId = 5,
  1177. DoPersonId = 8,
  1178. Coefficient = 0.20000000000000001
  1179. },
  1180. new
  1181. {
  1182. CheckerId = 5,
  1183. DoPersonId = 9,
  1184. Coefficient = 0.29999999999999999
  1185. },
  1186. new
  1187. {
  1188. CheckerId = 5,
  1189. DoPersonId = 10,
  1190. Coefficient = 0.29999999999999999
  1191. },
  1192. new
  1193. {
  1194. CheckerId = 5,
  1195. DoPersonId = 11,
  1196. Coefficient = 0.40000000000000002
  1197. },
  1198. new
  1199. {
  1200. CheckerId = 5,
  1201. DoPersonId = 12,
  1202. Coefficient = 0.40000000000000002
  1203. },
  1204. new
  1205. {
  1206. CheckerId = 5,
  1207. DoPersonId = 13,
  1208. Coefficient = 0.5
  1209. },
  1210. new
  1211. {
  1212. CheckerId = 6,
  1213. DoPersonId = 5,
  1214. Coefficient = 0.20000000000000001
  1215. },
  1216. new
  1217. {
  1218. CheckerId = 6,
  1219. DoPersonId = 6,
  1220. Coefficient = 0.20000000000000001
  1221. },
  1222. new
  1223. {
  1224. CheckerId = 6,
  1225. DoPersonId = 7,
  1226. Coefficient = 0.20000000000000001
  1227. },
  1228. new
  1229. {
  1230. CheckerId = 6,
  1231. DoPersonId = 8,
  1232. Coefficient = 0.20000000000000001
  1233. },
  1234. new
  1235. {
  1236. CheckerId = 6,
  1237. DoPersonId = 9,
  1238. Coefficient = 0.29999999999999999
  1239. },
  1240. new
  1241. {
  1242. CheckerId = 6,
  1243. DoPersonId = 10,
  1244. Coefficient = 0.29999999999999999
  1245. },
  1246. new
  1247. {
  1248. CheckerId = 6,
  1249. DoPersonId = 11,
  1250. Coefficient = 0.40000000000000002
  1251. },
  1252. new
  1253. {
  1254. CheckerId = 6,
  1255. DoPersonId = 12,
  1256. Coefficient = 0.40000000000000002
  1257. },
  1258. new
  1259. {
  1260. CheckerId = 6,
  1261. DoPersonId = 13,
  1262. Coefficient = 0.5
  1263. });
  1264. });
  1265. modelBuilder.Entity("wispro.sp.entity.AppealRecord", b =>
  1266. {
  1267. b.HasOne("wispro.sp.entity.Staff", "Creater")
  1268. .WithMany()
  1269. .HasForeignKey("CreaterId")
  1270. .OnDelete(DeleteBehavior.Cascade)
  1271. .IsRequired();
  1272. b.HasOne("wispro.sp.entity.PerformanceItem", "Item")
  1273. .WithMany()
  1274. .HasForeignKey("ItemId")
  1275. .OnDelete(DeleteBehavior.Cascade)
  1276. .IsRequired();
  1277. b.HasOne("wispro.sp.entity.Staff", "Reviewer")
  1278. .WithMany()
  1279. .HasForeignKey("ReviewerId")
  1280. .OnDelete(DeleteBehavior.NoAction);
  1281. b.HasOne("wispro.sp.entity.AppealType", "Type")
  1282. .WithMany()
  1283. .HasForeignKey("TypeId")
  1284. .OnDelete(DeleteBehavior.NoAction)
  1285. .IsRequired();
  1286. b.Navigation("Creater");
  1287. b.Navigation("Item");
  1288. b.Navigation("Reviewer");
  1289. b.Navigation("Type");
  1290. });
  1291. modelBuilder.Entity("wispro.sp.entity.AttachFile", b =>
  1292. {
  1293. b.HasOne("wispro.sp.entity.AppealRecord", "AppealRecord")
  1294. .WithMany("AttachFiles")
  1295. .HasForeignKey("AppealRecordId")
  1296. .HasConstraintName("FK_AttachFile_AppealRecord");
  1297. b.HasOne("wispro.sp.entity.Staff", "UploadUser")
  1298. .WithMany()
  1299. .HasForeignKey("UploadUserId")
  1300. .HasConstraintName("FK_AttachFile_UpdateUser")
  1301. .OnDelete(DeleteBehavior.NoAction)
  1302. .IsRequired();
  1303. b.Navigation("AppealRecord");
  1304. b.Navigation("UploadUser");
  1305. });
  1306. modelBuilder.Entity("wispro.sp.entity.Customer", b =>
  1307. {
  1308. b.HasOne("wispro.sp.entity.Staff", "ResponseMan")
  1309. .WithMany("Customers")
  1310. .HasForeignKey("ResponseManId")
  1311. .HasConstraintName("FK_Customer_Staff");
  1312. b.Navigation("ResponseMan");
  1313. });
  1314. modelBuilder.Entity("wispro.sp.entity.InputField", b =>
  1315. {
  1316. b.HasOne("wispro.sp.entity.AppealType", "AppealType")
  1317. .WithMany()
  1318. .HasForeignKey("AppealTypeId")
  1319. .OnDelete(DeleteBehavior.Cascade)
  1320. .IsRequired();
  1321. b.Navigation("AppealType");
  1322. });
  1323. modelBuilder.Entity("wispro.sp.entity.InputFieldValue", b =>
  1324. {
  1325. b.HasOne("wispro.sp.entity.AppealRecord", "AppealRecord")
  1326. .WithMany()
  1327. .HasForeignKey("AppealRecordId")
  1328. .OnDelete(DeleteBehavior.Cascade)
  1329. .IsRequired();
  1330. b.HasOne("wispro.sp.entity.InputField", "InputField")
  1331. .WithMany()
  1332. .HasForeignKey("InputFieldId")
  1333. .OnDelete(DeleteBehavior.Cascade)
  1334. .IsRequired();
  1335. b.Navigation("AppealRecord");
  1336. b.Navigation("InputField");
  1337. });
  1338. modelBuilder.Entity("wispro.sp.entity.ItemStaff", b =>
  1339. {
  1340. b.HasOne("wispro.sp.entity.Staff", "DoPerson")
  1341. .WithMany("ItemStaffs")
  1342. .HasForeignKey("DoPersonId")
  1343. .HasConstraintName("FK_ItemStaff_Staff")
  1344. .IsRequired();
  1345. b.HasOne("wispro.sp.entity.PerformanceItem", "Item")
  1346. .WithMany("ItemStaffs")
  1347. .HasForeignKey("ItemId")
  1348. .HasConstraintName("FK_ItemStaff_PerformanceItem")
  1349. .IsRequired();
  1350. b.Navigation("DoPerson");
  1351. b.Navigation("Item");
  1352. });
  1353. modelBuilder.Entity("wispro.sp.entity.Message", b =>
  1354. {
  1355. b.HasOne("wispro.sp.entity.Staff", "From")
  1356. .WithMany()
  1357. .HasForeignKey("FromId")
  1358. .HasConstraintName("FK_From_Staff")
  1359. .IsRequired();
  1360. b.Navigation("From");
  1361. });
  1362. modelBuilder.Entity("wispro.sp.entity.MessagePerformanceItem", b =>
  1363. {
  1364. b.HasOne("wispro.sp.entity.PerformanceItem", "Item")
  1365. .WithMany()
  1366. .HasForeignKey("ItemId")
  1367. .HasConstraintName("FK_MessagePerformanceItem_Item")
  1368. .OnDelete(DeleteBehavior.Cascade)
  1369. .IsRequired();
  1370. b.HasOne("wispro.sp.entity.Message", "Message")
  1371. .WithMany("RelatedItem")
  1372. .HasForeignKey("MessageId")
  1373. .HasConstraintName("FK_MessagePerformanceItem_Message")
  1374. .OnDelete(DeleteBehavior.Cascade)
  1375. .IsRequired();
  1376. b.Navigation("Item");
  1377. b.Navigation("Message");
  1378. });
  1379. modelBuilder.Entity("wispro.sp.entity.MessageReadRecord", b =>
  1380. {
  1381. b.HasOne("wispro.sp.entity.Message", "Message")
  1382. .WithMany()
  1383. .HasForeignKey("MessageId")
  1384. .HasConstraintName("FK_MessageReadRecord_Message")
  1385. .IsRequired();
  1386. b.HasOne("wispro.sp.entity.Message", null)
  1387. .WithMany("To")
  1388. .HasForeignKey("MessageId1");
  1389. b.HasOne("wispro.sp.entity.Staff", "Staff")
  1390. .WithMany()
  1391. .HasForeignKey("StaffId")
  1392. .HasConstraintName("FK_MessageReadRecord_Staff")
  1393. .IsRequired();
  1394. b.Navigation("Message");
  1395. b.Navigation("Staff");
  1396. });
  1397. modelBuilder.Entity("wispro.sp.entity.PerformanceItem", b =>
  1398. {
  1399. b.HasOne("wispro.sp.entity.CalMonth", "CalMonth")
  1400. .WithMany("PerformanceItems")
  1401. .HasForeignKey("CalMonthId")
  1402. .HasConstraintName("FK_PerformanceItem_CalMonth")
  1403. .OnDelete(DeleteBehavior.Cascade)
  1404. .IsRequired();
  1405. b.HasOne("wispro.sp.entity.Customer", "Customer")
  1406. .WithMany("PerformanceItems")
  1407. .HasForeignKey("CustomerId")
  1408. .HasConstraintName("FK_PerformanceItem_Customer");
  1409. b.HasOne("wispro.sp.entity.Staff", "PreOastaff")
  1410. .WithMany()
  1411. .HasForeignKey("PreOastaffId")
  1412. .HasConstraintName("FK_PerformanceItem_Staff");
  1413. b.HasOne("wispro.sp.entity.Staff", "Reviewer")
  1414. .WithMany("ReviewerItems")
  1415. .HasForeignKey("ReviewerId")
  1416. .HasConstraintName("FK_PerformanceItem_Reviewer");
  1417. b.Navigation("CalMonth");
  1418. b.Navigation("Customer");
  1419. b.Navigation("PreOastaff");
  1420. b.Navigation("Reviewer");
  1421. });
  1422. modelBuilder.Entity("wispro.sp.entity.SelectValue", b =>
  1423. {
  1424. b.HasOne("wispro.sp.entity.InputField", "InputField")
  1425. .WithMany("SelectValues")
  1426. .HasForeignKey("InputFieldId")
  1427. .OnDelete(DeleteBehavior.Cascade)
  1428. .IsRequired();
  1429. b.Navigation("InputField");
  1430. });
  1431. modelBuilder.Entity("wispro.sp.entity.Staff", b =>
  1432. {
  1433. b.HasOne("wispro.sp.entity.StaffGrade", "StaffGrade")
  1434. .WithMany("Staff")
  1435. .HasForeignKey("StaffGradeId")
  1436. .HasConstraintName("FK_Staff_StaffGrade");
  1437. b.Navigation("StaffGrade");
  1438. });
  1439. modelBuilder.Entity("wispro.sp.entity.VerifyCoefficient", b =>
  1440. {
  1441. b.HasOne("wispro.sp.entity.StaffGrade", "Checker")
  1442. .WithMany("VerifyCoefficientCheckers")
  1443. .HasForeignKey("CheckerId")
  1444. .HasConstraintName("FK_VerifyCoefficient_StaffGrade")
  1445. .IsRequired();
  1446. b.HasOne("wispro.sp.entity.StaffGrade", "DoPerson")
  1447. .WithMany("VerifyCoefficientDoPeople")
  1448. .HasForeignKey("DoPersonId")
  1449. .HasConstraintName("FK_VerifyCoefficient_StaffGrade1")
  1450. .IsRequired();
  1451. b.Navigation("Checker");
  1452. b.Navigation("DoPerson");
  1453. });
  1454. modelBuilder.Entity("wispro.sp.entity.AppealRecord", b =>
  1455. {
  1456. b.Navigation("AttachFiles");
  1457. });
  1458. modelBuilder.Entity("wispro.sp.entity.CalMonth", b =>
  1459. {
  1460. b.Navigation("PerformanceItems");
  1461. });
  1462. modelBuilder.Entity("wispro.sp.entity.Customer", b =>
  1463. {
  1464. b.Navigation("PerformanceItems");
  1465. });
  1466. modelBuilder.Entity("wispro.sp.entity.InputField", b =>
  1467. {
  1468. b.Navigation("SelectValues");
  1469. });
  1470. modelBuilder.Entity("wispro.sp.entity.Message", b =>
  1471. {
  1472. b.Navigation("RelatedItem");
  1473. b.Navigation("To");
  1474. });
  1475. modelBuilder.Entity("wispro.sp.entity.PerformanceItem", b =>
  1476. {
  1477. b.Navigation("ItemStaffs");
  1478. });
  1479. modelBuilder.Entity("wispro.sp.entity.Staff", b =>
  1480. {
  1481. b.Navigation("Customers");
  1482. b.Navigation("ItemStaffs");
  1483. b.Navigation("ReviewerItems");
  1484. });
  1485. modelBuilder.Entity("wispro.sp.entity.StaffGrade", b =>
  1486. {
  1487. b.Navigation("Staff");
  1488. b.Navigation("VerifyCoefficientCheckers");
  1489. b.Navigation("VerifyCoefficientDoPeople");
  1490. });
  1491. #pragma warning restore 612, 618
  1492. }
  1493. }
  1494. }