ic_item.cs 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700
  1. using Business.Core.Attributes;
  2. using Microsoft.EntityFrameworkCore;
  3. using System.ComponentModel;
  4. using System.ComponentModel.DataAnnotations;
  5. namespace Business.Domain
  6. {
  7. /// <summary>
  8. /// 物料详情
  9. /// </summary>
  10. [CollectionName("dopbase", "ic_item")]
  11. [Comment("物料详情")]
  12. [Index(nameof(number), nameof(fversion), nameof(tenant_id), nameof(company_id), nameof(factory_id), IsUnique = true)]
  13. public class ic_item : BaseEntity
  14. {
  15. public ic_item(long Id) : base(Id)
  16. {
  17. }
  18. /// <summary>
  19. /// 物料编码
  20. /// </summary>
  21. [StringLength(80)]
  22. [Comment("物料编码")]
  23. public string number { get; set; }
  24. /// <summary>
  25. /// 物料名称
  26. /// </summary>
  27. [StringLength(80)]
  28. [Comment("物料名称")]
  29. public string name { get; set; }
  30. /// <summary>
  31. /// 规格型号
  32. /// </summary>
  33. [StringLength(200)]
  34. [Comment("规格型号")]
  35. public string model { get; set; }
  36. /// <summary>
  37. /// 全名
  38. /// </summary>
  39. [StringLength(255)]
  40. [Comment("全名")]
  41. public string full_name { get; set; }
  42. /// <summary>
  43. /// fms旧料号
  44. /// </summary>
  45. [StringLength(80)]
  46. [Comment("fms旧料号")]
  47. public string fms_number { get; set; }
  48. /// <summary>
  49. /// erp旧料号
  50. /// </summary>
  51. [StringLength(80)]
  52. [Comment("erp旧料号")]
  53. public string erp_oldnumber { get; set; }
  54. /// <summary>
  55. /// 图号
  56. /// </summary>
  57. [StringLength(80)]
  58. [Comment("图号")]
  59. public string chart_number { get; set; }
  60. /// <summary>
  61. /// 版本号
  62. /// </summary>
  63. [StringLength(80)]
  64. [Comment("版本号")]
  65. public string fversion { get; set; }
  66. /// <summary>
  67. /// 盒贴规格
  68. /// </summary>
  69. [StringLength(200)]
  70. [Comment("盒贴规格")]
  71. public string box_model { get; set; }
  72. /// <summary>
  73. /// 物料属性
  74. /// </summary>
  75. [Comment("物料属性")]
  76. public int? erp_cls { get; set; }
  77. /// <summary>
  78. /// 物料属性名称
  79. /// </summary>
  80. [StringLength(80)]
  81. [Comment("物料属性")]
  82. public string erp_cls_name { get; set; }
  83. /// <summary>
  84. /// 单位
  85. /// </summary>
  86. [StringLength(80)]
  87. [Comment("单位")]
  88. public string unit { get; set; }
  89. /// <summary>
  90. /// 物料等级
  91. /// </summary>
  92. [Comment("物料等级")]
  93. public long? item_level { get; set; }
  94. /// <summary>
  95. /// 单位标准工时_小时
  96. /// </summary>
  97. [Precision(23, 10)]
  98. [Comment("单位标准工时_小时")]
  99. public decimal? standard_manhour { get; set; }
  100. /// <summary>
  101. /// 单位材料定额_元
  102. /// </summary>
  103. [Precision(23, 10)]
  104. [Comment("单位材料定额_元")]
  105. public decimal? unititem_amount { get; set; }
  106. /// <summary>
  107. /// 来源
  108. /// </summary>
  109. [StringLength(200)]
  110. [Comment("来源")]
  111. public string source { get; set; }
  112. /// <summary>
  113. /// 是否为设备
  114. /// </summary>
  115. [Comment("是否为设备")]
  116. public int? is_equipment { get; set; }
  117. /// <summary>
  118. /// 单位包装数量
  119. /// </summary>
  120. [Precision(23, 10)]
  121. [Comment("单位包装数量")]
  122. public decimal? unit_qty { get; set; }
  123. /// <summary>
  124. /// 是否关键件
  125. /// </summary>
  126. [Comment("是否关键件")]
  127. public int? iskeyitem { get; set; }
  128. /// <summary>
  129. /// 毛重
  130. /// </summary>
  131. [Precision(23, 10)]
  132. [Comment("毛重")]
  133. public decimal? gross_weight { get; set; }
  134. /// <summary>
  135. /// 净重
  136. /// </summary>
  137. [Precision(23, 10)]
  138. [Comment("净重")]
  139. public decimal? net_weight { get; set; }
  140. /// <summary>
  141. /// 重量单位
  142. /// </summary>
  143. [StringLength(80)]
  144. [Comment("重量单位")]
  145. public string maund { get; set; }
  146. /// <summary>
  147. /// 长度
  148. /// </summary>
  149. [Precision(23, 10)]
  150. [Comment("长度")]
  151. public decimal? length { get; set; }
  152. /// <summary>
  153. /// 长度单位
  154. /// </summary>
  155. [StringLength(80)]
  156. [Comment("长度单位")]
  157. public string cubic_measure { get; set; }
  158. /// <summary>
  159. /// 宽度
  160. /// </summary>
  161. [Precision(23, 10)]
  162. [Comment("宽度")]
  163. public decimal? width { get; set; }
  164. /// <summary>
  165. /// 高度
  166. /// </summary>
  167. [Precision(23, 10)]
  168. [Comment("高度")]
  169. public decimal? height { get; set; }
  170. /// <summary>
  171. /// 体积
  172. /// </summary>
  173. [Precision(23, 10)]
  174. [Comment("体积")]
  175. public decimal? size { get; set; }
  176. /// <summary>
  177. /// 允许采购
  178. /// </summary>
  179. [Comment("允许采购")]
  180. public int? allowpur { get; set; }
  181. /// <summary>
  182. /// 允许销售
  183. /// </summary>
  184. [Comment("允许销售")]
  185. public int? allowsale { get; set; }
  186. /// <summary>
  187. /// 允许生产
  188. /// </summary>
  189. [Comment("允许生产")]
  190. public int? allowmanu { get; set; }
  191. /// <summary>
  192. /// 允许委外
  193. /// </summary>
  194. [Comment("允许委外")]
  195. public int? allowout { get; set; }
  196. /// <summary>
  197. /// 批号管理
  198. /// </summary>
  199. [Comment("批号管理")]
  200. public int? allowbatch { get; set; }
  201. /// <summary>
  202. /// 序列号管理
  203. /// </summary>
  204. [Comment("序列号管理")]
  205. public int? allowserial { get; set; }
  206. /// <summary>
  207. /// 图片
  208. /// </summary>
  209. [StringLength(80)]
  210. [Comment("图片")]
  211. public string photo { get; set; }
  212. /// <summary>
  213. /// 领料类型
  214. /// </summary>
  215. [Comment("领料类型")]
  216. public long? picktype { get; set; }
  217. /// <summary>
  218. /// 出库类型
  219. /// </summary>
  220. [Comment("出库类型")]
  221. public long? output_type_id { get; set; }
  222. /// <summary>
  223. /// 启用预警
  224. /// </summary>
  225. [Comment("启用预警")]
  226. public int? enable_warning { get; set; }
  227. /// <summary>
  228. /// 生命周期状态:1-成熟品,2-新品,3-重点新品,4-退市
  229. /// </summary>
  230. [Comment("生命周期状态")]
  231. public int? life_state { get; set; }
  232. /// <summary>
  233. /// 经济生产批量
  234. /// </summary>
  235. [Comment("经济生产批量")]
  236. [Precision(23, 10)]
  237. public decimal? moq { get; set; }
  238. /// <summary>
  239. /// 最大生产批量
  240. /// </summary>
  241. [Comment("最大生产批量")]
  242. [Precision(23, 10)]
  243. public decimal? maq { get; set; }
  244. /// <summary>
  245. /// 是否备料前预处理
  246. /// </summary>
  247. [Comment("是否备料前预处理")]
  248. public int? is_clean { get; set; }
  249. /// <summary>
  250. /// 预处理提前期(天)
  251. /// </summary>
  252. [Comment("预处理提前期")]
  253. [Precision(23, 10)]
  254. public decimal? clean_leadtime { get; set; }
  255. /// <summary>
  256. /// 工序委外提前期/灭菌提前期(天)
  257. /// </summary>
  258. [Comment("工序委外提前期")]
  259. [Precision(23, 10)]
  260. public decimal? sterilize_leadtime { get; set; }
  261. /// <summary>
  262. /// 平台调拨提前期(天)
  263. /// </summary>
  264. [Comment("平台调拨提前期")]
  265. [Precision(23, 10)]
  266. public decimal? transfer_leadtime { get; set; }
  267. /// <summary>
  268. /// 标准工期(天)
  269. /// </summary>
  270. [Comment("标准工期")]
  271. [Precision(23, 10)]
  272. public decimal? standard_period { get; set; }
  273. /// <summary>
  274. /// FMR分类:F-F类,M-M类,R-R类
  275. /// </summary>
  276. [Comment("FMR分类")]
  277. public string fmr { get; set; }
  278. /// <summary>
  279. /// ABC分类:A-A类,B-B类,C-C类
  280. /// </summary>
  281. [Comment("ABC分类")]
  282. public string abc { get; set; }
  283. //ic_plan
  284. ///// <summary>
  285. ///// 物料id
  286. ///// </summary>
  287. //[Required]
  288. //[Comment("物料id")]
  289. //public long icitem_id { get; set; }
  290. ///// <summary>
  291. ///// 物料名称
  292. ///// </summary>
  293. //[StringLength(80)]
  294. //[Comment("物料名称")]
  295. //public string? icitem_name { get; set; }
  296. ///// <summary>
  297. ///// 计划员
  298. ///// </summary>
  299. //[StringLength(80)]
  300. //[Comment("计划员")]
  301. //public string? planner_name { get; set; }
  302. ///// <summary>
  303. ///// 计划员_工号
  304. ///// </summary>
  305. //[StringLength(80)]
  306. //[Comment("计划员_工号")]
  307. //public string? planner_num { get; set; }
  308. ///// <summary>
  309. ///// 工厂编码
  310. ///// </summary>
  311. //[StringLength(80)]
  312. //[Comment("工厂编码")]
  313. //public string? factory_code { get; set; }
  314. /// <summary>
  315. /// 固定提前期(天)
  316. /// </summary>
  317. [Precision(23, 10)]
  318. [Comment("固定提前期(天)")]
  319. public decimal? fix_leadtime { get; set; }
  320. /// <summary>
  321. /// 计划策略
  322. /// </summary>
  323. [Comment("计划策略")]
  324. public int? plan_trategy { get; set; }
  325. /// <summary>
  326. /// 订货策略
  327. /// </summary>
  328. [Comment("订货策略")]
  329. public int? order_trategy { get; set; }
  330. /// <summary>
  331. /// 订货间隔期_天
  332. /// </summary>
  333. [Precision(23, 10)]
  334. [Comment("订货间隔期_天")]
  335. public decimal? order_inter_val { get; set; }
  336. /// <summary>
  337. /// 变动提前期
  338. /// </summary>
  339. [Precision(23, 10)]
  340. [Comment("变动提前期")]
  341. public decimal? lead_time { get; set; }
  342. /// <summary>
  343. /// 变动提前期批量
  344. /// </summary>
  345. [Precision(23, 10)]
  346. [Comment("变动提前期批量")]
  347. public decimal? bat_change_economy { get; set; }
  348. /// <summary>
  349. /// 累计提前期
  350. /// </summary>
  351. [Precision(23, 10)]
  352. [Comment("累计提前期")]
  353. public decimal? total_tqq { get; set; }
  354. /// <summary>
  355. /// 再订货点
  356. /// </summary>
  357. [Precision(23, 10)]
  358. [Comment("再订货点")]
  359. public decimal? order_point { get; set; }
  360. /// <summary>
  361. /// 设置为固定再订货点
  362. /// </summary>
  363. [Comment("设置为固定再订货点")]
  364. public int? isfixedreorder { get; set; }
  365. /// <summary>
  366. /// 安全库存数量
  367. /// </summary>
  368. [Precision(23, 10)]
  369. [Comment("安全库存数量")]
  370. public decimal? secinv { get; set; }
  371. /// <summary>
  372. /// 安全库存触发采购比例
  373. /// </summary>
  374. [Precision(23, 10)]
  375. [Comment("安全库存触发采购比例")]
  376. public decimal? secinv_ratio { get; set; }
  377. /// <summary>
  378. /// 是否需要进行订补货计划的运算
  379. /// </summary>
  380. //[Comment("是否需要进行订补货计划的运算")]
  381. //public int? book_plan { get; set; }
  382. /// <summary>
  383. /// 辅助属性参与计划运算
  384. /// </summary>
  385. //[Comment("辅助属性参与计划运算")]
  386. //public int? aux_prop_plan { get; set; }
  387. /// <summary>
  388. /// 计划备注
  389. /// </summary>
  390. //[StringLength(1000)]
  391. //[Comment("计划备注")]
  392. //public string? plannote { get; set; }
  393. /// <summary>
  394. /// 计算ID
  395. /// </summary>
  396. //[Comment("计算id")]
  397. //[NotMapped]
  398. //public long? bang_id { get; set; }
  399. /// <summary>
  400. /// 自检提前期
  401. /// </summary>
  402. [Precision(23, 10)]
  403. [Comment("自检提前期")]
  404. public decimal? self_inspection_date { get; set; }
  405. /// <summary>
  406. /// 入库提前期
  407. /// </summary>
  408. [Precision(23, 10)]
  409. [Comment("入库提前期")]
  410. public decimal? Warehousing_date { get; set; }
  411. /// <summary>
  412. /// 发运提前期
  413. /// </summary>
  414. [Precision(23, 10)]
  415. [Comment("发运提前期")]
  416. public decimal? Shipping_date { get; set; }
  417. //ic_factory_details
  418. /// <summary>
  419. /// 物料id
  420. /// </summary>
  421. //[Required]
  422. //[Comment("物料id")]
  423. //public long icitem_id { get; set; }
  424. ///// <summary>
  425. ///// 物料名称
  426. ///// </summary>
  427. //[StringLength(80)]
  428. //[Comment("物料名称")]
  429. //public string? icitem_name { get; set; }
  430. /// <summary>
  431. /// 工厂编码
  432. /// </summary>
  433. //[StringLength(80)]
  434. //[Comment("工厂编码")]
  435. //public string? factory_fode { get; set; }
  436. /// <summary>
  437. /// 特殊备注
  438. /// </summary>
  439. //[StringLength(1000)]
  440. //[Comment("特殊备注")]
  441. //public string? note { get; set; }
  442. /// <summary>
  443. /// 产品线
  444. /// </summary>
  445. [StringLength(80)]
  446. [Comment("产品线")]
  447. public string product_line { get; set; }
  448. /// <summary>
  449. /// 领料类型
  450. /// </summary>
  451. //[Required]
  452. //[Comment("领料类型")]
  453. //public long pick_type { get; set; }
  454. /// <summary>
  455. /// 是否采用业务批次管理
  456. /// </summary>
  457. [Comment("是否采用业务批次管理")]
  458. public int batch_manager { get; set; }
  459. /// <summary>
  460. /// 是否需要库龄管理
  461. /// </summary>
  462. //[Comment("是否需要库龄管理")]
  463. //public int stock_time { get; set; }
  464. /// <summary>
  465. /// 盘点周期单位
  466. /// </summary>
  467. //[StringLength(80)]
  468. //[Comment("盘点周期单位")]
  469. //public string? check_cycunit { get; set; }
  470. /// <summary>
  471. /// 盘点周期
  472. /// </summary>
  473. //[Precision(23, 10)]
  474. //[Comment("盘点周期")]
  475. //public decimal? check_cycle { get; set; }
  476. /// <summary>
  477. /// 每周_月第天
  478. /// </summary>
  479. //[Comment("每周_月第天")]
  480. //public int days_per { get; set; }
  481. /// <summary>
  482. /// 上次盘点日期
  483. /// </summary>
  484. //[Comment("上次盘点日期")]
  485. //public DateTime? last_checkdate { get; set; }
  486. ///// <summary>
  487. /// 默认待检仓库
  488. /// </summary>
  489. //[Required]
  490. //[Comment("默认待检仓库")]
  491. //public long default_chkloc { get; set; }
  492. /// <summary>
  493. /// 默认待检仓位
  494. /// </summary>
  495. //[Required]
  496. //[Comment("默认待检仓位")]
  497. //public long default_chksp { get; set; }
  498. /// <summary>
  499. /// 默认仓库
  500. /// </summary>
  501. //[Required]
  502. //[Comment("默认仓库")]
  503. //public long default_loc { get; set; }
  504. /// <summary>
  505. /// 默认仓位
  506. /// </summary>
  507. //[Required]
  508. //[Comment("默认仓位")]
  509. //public long default_sp { get; set; }
  510. /// <summary>
  511. /// 货架信息
  512. /// </summary>
  513. //[StringLength(80)]
  514. //[Comment("货架信息")]
  515. //public string? item_shelve { get; set; }
  516. /// <summary>
  517. /// 默认仓管员
  518. /// </summary>
  519. //[StringLength(80)]
  520. //[Comment("默认仓管员")]
  521. //public string? default_manager { get; set; }
  522. /// <summary>
  523. /// 最低存量
  524. /// </summary>
  525. //[Precision(23, 10)]
  526. //[Comment("最低存量")]
  527. //public decimal? low_limit { get; set; }
  528. /// <summary>
  529. /// 最高存量
  530. /// </summary>
  531. //[Precision(23, 10)]
  532. //[Comment("最高存量")]
  533. //public decimal? high_limit { get; set; }
  534. /// <summary>
  535. /// 最大订货量
  536. /// </summary>
  537. //[Precision(23, 10)]
  538. //[Comment("最大订货量")]
  539. //public decimal? qty_max { get; set; }
  540. /// <summary>
  541. /// 日消耗量
  542. /// </summary>
  543. //[Precision(23, 10)]
  544. //[Comment("日消耗量")]
  545. //public decimal? daily_consume { get; set; }
  546. /// <summary>
  547. /// 库存备注
  548. /// </summary>
  549. //[StringLength(1000)]
  550. //[Comment("库存备注")]
  551. //public string? warehouse_note { get; set; }
  552. /// <summary>
  553. /// 工单发料时间/天
  554. /// </summary>
  555. [Precision(23, 10)]
  556. [Comment("工单发料时间/天")]
  557. public decimal? ordissu_days { get; set; }
  558. ///// <summary>
  559. ///// 原材料收货处理时间/天
  560. ///// </summary>
  561. //[Precision(23, 10)]
  562. //[Comment("原材料收货处理时间/天")]
  563. //public decimal? raw_matreceiv_days { get; set; }
  564. ///// <summary>
  565. ///// 成品入库时间/天
  566. ///// </summary>
  567. //[Precision(23, 10)]
  568. //[Comment("成品入库时间/天")]
  569. //public decimal? prdenter_days { get; set; }
  570. ///// <summary>
  571. ///// 原材料入库时间/天
  572. ///// </summary>
  573. //[Precision(23, 10)]
  574. //[Comment("原材料入库时间/天")]
  575. //public decimal? mat_enter_days { get; set; }
  576. ///// <summary>
  577. ///// 成品发货时间/天
  578. ///// </summary>
  579. //[Precision(23, 10)]
  580. //[Comment("成品发货时间/天")]
  581. //public decimal? prd_out_days { get; set; }
  582. /// <summary>
  583. /// 运输中提前期_天
  584. /// </summary>
  585. [Comment("运输中提前期_天")]
  586. [Required]
  587. [DefaultValue(0)]
  588. [Precision(23, 10)]
  589. public decimal? transportation_leadtime { get; set; }
  590. /// <summary>
  591. /// 仓库中提前期_天
  592. /// </summary>
  593. [Comment("仓库中提前期_天")]
  594. [Required]
  595. [DefaultValue(0)]
  596. [Precision(23, 10)]
  597. public decimal? stock_leadtime { get; set; }
  598. /// <summary>
  599. /// 生产中提前期_天
  600. /// </summary>
  601. [Comment("生产中提前期_天")]
  602. [Required]
  603. [DefaultValue(0)]
  604. [Precision(23, 10)]
  605. public decimal? production_leadtime { get; set; }
  606. /// <summary>
  607. /// 下单前置期_天
  608. /// </summary>
  609. [Comment("下单前置期_天")]
  610. [Required]
  611. [DefaultValue(0)]
  612. [Precision(23, 10)]
  613. public decimal? order_leadtime { get; set; }
  614. /// <summary>
  615. /// 最小包装量
  616. /// </summary>
  617. [Comment("最小包装量")]
  618. [Required]
  619. [DefaultValue(0)]
  620. [Precision(23, 10)]
  621. public decimal? minpackqty { get; set; }
  622. /// <summary>
  623. /// 最小订单量
  624. /// </summary>
  625. [Comment("最小订单量")]
  626. [Required]
  627. [DefaultValue(0)]
  628. [Precision(23, 10)]
  629. public decimal? minorderqty { get; set; }
  630. /// <summary>
  631. /// 是否倒冲
  632. /// </summary>
  633. [Comment("是否倒冲")]
  634. public int? isbackflush { get; set; }
  635. /// <summary>
  636. /// 生产负责人
  637. /// </summary>
  638. //[StringLength(80)]
  639. //[Comment("生产负责人")]
  640. //public string? product_principal { get; set; }
  641. /// <summary>
  642. /// 倒冲仓库
  643. /// </summary>
  644. //[StringLength(80)]
  645. //[Comment("倒冲仓库")]
  646. //public string? back_flush_stock { get; set; }
  647. /// <summary>
  648. /// 倒冲仓位
  649. /// </summary>
  650. //[StringLength(80)]
  651. //[Comment("倒冲仓位")]
  652. //public string? back_flush_sp { get; set; }
  653. /// <summary>
  654. /// 投料自动取整
  655. /// </summary>
  656. [Comment("投料自动取整")]
  657. public int? put_integer { get; set; }
  658. /// <summary>
  659. /// RS50成品 RS30 组件 RS11 原材料 RS12 零件 RS13 包装材料 RS14 辅料 RS15 低值易耗品 RS99 虚拟物料
  660. /// </summary>
  661. [StringLength(80)]
  662. [Comment("物料类型")]
  663. public string item_type { get; set; }
  664. /// <summary>
  665. /// 供应提前期
  666. /// </summary>
  667. [Comment("供应提前期")]
  668. [Required]
  669. [DefaultValue(0)]
  670. [Precision(23, 10)]
  671. public int PurLT { get; set; }
  672. }
  673. }