Compare commits

..

131 Commits

Author SHA1 Message Date
djankowski 9e10948e59 Merge pull request 'Development' (#770) from Development into master
Merging development into master after successful testing.
2026-05-15 10:06:27 -04:00
djankowski f8663e038f Merge pull request 'Development' (#752) from Development into master
Merging from dev into master after successful testing.
2026-04-01 10:21:52 -04:00
djankowski 124cfb14ab Merge pull request 'Development' (#749) from Development into master
Merging from dev into Master after successful testing.
2026-03-27 10:50:22 -04:00
djankowski 4852b7c2c0 Merge pull request 'Development' (#735) from Development into master
Merging changes from dev into master after successful testing.
2026-03-12 15:17:28 -04:00
djankowski dd4b08ec2b Merge pull request 'Development' (#732) from Development into master
Merging changes from dev into master after successful testing.
2026-03-11 11:09:47 -04:00
djankowski 6aef00ffc6 Merge pull request 'Development' (#708) from Development into master
Merging dev into master after successful testing.
2026-02-09 08:26:02 -05:00
djankowski 76eb6fca13 Merge pull request 'Development' (#706) from Development into master
Merging dev into master after successful testing.
2026-02-06 09:37:35 -05:00
djankowski 892b84690e Merge pull request 'Development' (#698) from Development into master
Merging dev into master after successful testing.
2026-01-29 08:46:50 -05:00
djankowski b0bfb4d3f6 Merge pull request 'Development' (#690) from Development into master
Merging Development into master after successful testing.
2026-01-22 08:17:16 -05:00
djankowski af1a05ff40 Merge pull request 'Development' (#681) from Development into master
Merging C2025-043 from dev into master after successful testing.
2026-01-13 16:35:02 -05:00
djankowski de89200eae Merge pull request 'Development' (#678) from Development into master
Merging dev into master after successful testing.
2026-01-05 08:22:25 -05:00
djankowski 7009ca78f2 Merge pull request 'Development' (#675) from Development into master
Merging dev into master after successful testing.
2025-12-18 08:34:38 -05:00
djankowski 03c58b7ae3 Merge pull request 'Development' (#672) from Development into master
Merging changes from dev into Master after successful testing
2025-12-11 08:44:58 -05:00
djankowski c9166f6f92 Merge pull request 'Development' (#669) from Development into master
Merging all changes from dev into master after successful testing.
2025-12-05 11:50:16 -05:00
djankowski 343d6a8c9a Merge pull request 'Development' (#650) from Development into master
Merging from dev into master after successful testing.
2025-11-06 09:23:19 -05:00
djankowski 8c5c7a5d93 Merge pull request 'Development' (#634) from Development into master
Merging dev into master after successful testing.
2025-10-09 12:50:13 -04:00
djankowski 864ec2709c Merge pull request 'Development' (#620) from Development into master
Merging Dev into master after successful testing.
2025-09-24 08:25:00 -04:00
djankowski 4b1ca8d7bf Merge pull request 'Development' (#612) from Development into master
Merging data into master after successful testing
2025-09-11 12:13:22 -04:00
djankowski 3b73d54ea2 Merge pull request 'Development' (#600) from Development into master
Merging dev into master after successful testing.
2025-08-15 08:37:48 -04:00
djankowski 2ca433c83f Merge pull request 'Development' (#576) from Development into master
Merging Dev into Master after successful testing.
2025-07-28 08:20:18 -04:00
djankowski 0b40569727 Merge pull request 'Development' (#570) from Development into master
Reviewed-on: #570
2025-06-23 14:58:28 -04:00
djankowski afb0247d87 Merge pull request 'Development' (#559) from Development into master
Merging changes from dev into master after successful testing.
2025-05-20 13:24:21 -04:00
djankowski bce8461a7e Merge pull request 'Development' (#555) from Development into master
Merging all changes from dev into master after successful testing.
2025-05-15 15:01:00 -04:00
djankowski 9d5cc43d71 Merge pull request 'Development' (#543) from Development into master
Merging dev into master after successful testing.
2025-05-01 11:25:49 -04:00
djankowski bc1370ab29 Merge pull request 'Development' (#540) from Development into master
Merging changes from Development into master after successful testing.
2025-04-23 15:13:56 -04:00
djankowski eaf2b14cfc Merge pull request 'Development' (#535) from Development into master
Merging all changes from development into master after successful testing.
2025-03-26 09:25:11 -04:00
djankowski 1cf7d81aa5 Merge pull request 'Development' (#530) from Development into master
Merging all changes through B2025-017 from dev into master after successful testing.
2025-03-04 10:24:28 -05:00
djankowski f11a9536f0 Merge pull request 'Development' (#524) from Development into master
Merging all changes through B2025-015 from development into master after successful testing.
2025-02-20 15:33:44 -05:00
djankowski c7bdcf0104 Merge pull request 'Development' (#516) from Development into master
Merging changes from development into master after successful testing
2025-02-11 15:25:38 -05:00
djankowski df026499d5 Merge pull request 'Development' (#512) from Development into master
Merging all changes from development into master after successful testing.
2025-02-10 09:20:43 -05:00
djankowski a3aa4157b8 Merge pull request 'Development' (#508) from Development into master
Merging all changes through B2025-012 from development into master after successful testing.
2025-02-05 10:50:35 -05:00
djankowski 8f3268e1bc Merge pull request 'Development' (#504) from Development into master
Merging all changes from development into master after successful testing.
2025-01-30 15:55:02 -05:00
djankowski 5721d440e9 Merge branch 'master' of https://git.volian.com/Volian/SourceCode 2025-01-21 10:42:15 -05:00
djankowski 505c396283 Merge pull request 'Development' (#489) from Development into master
Merging from development into master after successful testing.
2025-01-21 10:41:15 -05:00
djankowski 643e6bc94f Merge pull request 'Development' (#486) from Development into master
Merging all items through B2025-003 from development in master after successful testing.
2025-01-09 15:02:16 -05:00
djankowski 76502e6d97 Merge pull request 'Development' (#481) from Development into master
Merging all changes through F2024-087 after successful testing.
2024-12-11 11:52:34 -05:00
djankowski 851a0b3810 Merge pull request 'Development' (#464) from Development into master
Merging all items through B2024-092 from development into master after successful testing.
2024-11-11 11:39:01 -05:00
djankowski fd8dbb4c8b Merge pull request 'Development' (#454) from Development into master
Merging all changes from development into master after successful testing.
2024-11-01 14:18:00 -04:00
djankowski 4ffd994c5e Merge pull request 'Development' (#450) from Development into master
Merging all development items into master after successful testing.
2024-10-31 09:11:59 -04:00
djankowski a34828113a Merge pull request 'Development' (#416) from Development into master
Merging C2017-031 and B2024-075 from development into master after successful testing.
2024-10-03 12:08:30 -04:00
djankowski 461329468c Merge pull request 'Development' (#413) from Development into master
Merging F2023-136 and F2024-074 in master after successful testing
2024-09-27 14:27:22 -04:00
djankowski 35de5df04d Merge pull request 'Development' (#410) from Development into master
Merging all items through B2024-03 from development into master after successful testing.
2024-09-17 12:03:23 -04:00
djankowski 4f0548fd60 Merge pull request 'Development' (#402) from Development into master
Merging C2021-034 and B2024-065 into master after successful testing.
2024-09-06 09:56:37 -04:00
djankowski 5c1d96cc51 Merge pull request 'Development' (#399) from Development into master
Merging all fixes through B2024-063 from development into master after successful testing.
2024-08-27 15:58:15 -04:00
djankowski 57049c0c52 Merge pull request 'Development' (#392) from Development into master
Merging B2024-059 and B2024-058 from development into master after successful testing.
2024-08-15 14:55:27 -04:00
djankowski 31326e1c91 Merge pull request 'Development' (#389) from Development into master
Merging all changes through F2024-069 from development into master after successful testing.
2024-08-09 13:06:40 -04:00
djankowski 3c60994a0a Merge pull request 'Development' (#373) from Development into master
Merging all changes through B2024-053 from development into master after successful testing.
2024-08-01 08:37:23 -04:00
djankowski 773cc42346 Merge pull request 'Development' (#362) from Development into master
Merging B2024-046 and B2024-047 from development into master after successful testing.
2024-07-25 10:44:42 -04:00
djankowski f46a1f39dc Merge pull request 'Development' (#359) from Development into master
Merging B2024-042 from development into master after successful testing.
2024-07-22 11:14:19 -04:00
djankowski b7175bf77f Merge pull request 'Development' (#357) from Development into master
Merging C2024-005 from development into master after successful testing.
2024-07-18 15:41:20 -04:00
djankowski ec22232aa8 Merge pull request 'Development' (#356) from Development into master
Merging all items through B2024-041 from development into master after successful testing.
2024-07-18 09:51:54 -04:00
djankowski f303cd2236 Merge pull request 'Development' (#348) from Development into master
Merging F2024-065 and F2024-066 from development into master after successful testing.
2024-07-03 10:45:41 -04:00
djankowski f40cef4416 Merge pull request 'Development' (#346) from Development into master
Merging F2024-064 from development into master after successful testing.
2024-07-01 11:54:15 -04:00
djankowski fbca97d38d Merge pull request 'Development' (#344) from Development into master
Merging C2024-013 from development into master after successful testing.
2024-06-25 15:55:32 -04:00
djankowski 28bd2cba5c Merge pull request 'Development' (#342) from Development into master
Merging C2022-029 from development into master after successful testing.
2024-06-20 11:36:59 -04:00
djankowski 4b35f73bbf Merge pull request 'Development' (#340) from Development into master
Merging C2024-004 from development into master after successful testing.
2024-06-19 16:23:23 -04:00
djankowski f4706eb126 Merge pull request 'Development' (#338) from Development into master
Merging C2019-047 from development into master after successful testing.
2024-06-17 08:38:34 -04:00
djankowski 21bcb90558 Merge pull request 'Development' (#335) from Development into master
Merging B2024-036 and F2024-063 from development into master after successful testing.
2024-06-06 14:51:13 -04:00
djankowski ae48ac0cae Merge pull request 'Development' (#332) from Development into master
Merging changes through B2024-035 from development into master after successful testing.
2024-05-30 08:08:28 -04:00
djankowski cb4979d5bc Merge pull request 'Development' (#327) from Development into master
Merging F2024-061 from development into master after successful testing.
2024-05-20 14:11:12 -04:00
djankowski 7d3ae74e1f Merge pull request 'Development' (#325) from Development into master
Merging F2024-060 from development into master after successful testing.
2024-05-16 15:32:13 -04:00
djankowski 9d680aa500 Merge pull request 'Development' (#323) from Development into master
Merging C2024-001 from development into master after successful testing.
2024-05-16 14:17:17 -04:00
djankowski 0d50b1c2fe Merge pull request 'Development' (#321) from Development into master
Merging all items through B2024-030 from development into master after successful testing.
2024-05-15 08:33:58 -04:00
djankowski 75e034863f Merge pull request 'Development' (#315) from Development into master
Merging all changes through B2024-026 from development into master after successful testing.
2024-05-09 14:01:48 -04:00
jjenko 3b42de1571 Merge pull request 'F2024-059_Callaway' (#311) from F2024-059_Callaway into master
Format only changes
2024-05-07 16:00:36 -04:00
djankowski 668472286e Merge pull request 'Development' (#307) from Development into master
Merging all changes through C2023-006 into master after successful testing.
2024-04-26 09:21:44 -04:00
djankowski e00d34c99d Merge pull request 'Development' (#300) from Development into master
Merging C2024-008 and C2024-007 from development into master after successful testing.
2024-04-17 14:57:22 -04:00
djankowski 9fb496dfb3 Merge pull request 'Development' (#297) from Development into master
Merging F2024-053 from development into master after successful testing.
2024-04-11 09:23:34 -04:00
djankowski f4eaa4a3ef Merge pull request 'Development' (#295) from Development into master
Merging F2024-052 from development into master after successful testing.
2024-04-08 11:11:43 -04:00
djankowski 5d50ed6bdf Merge pull request 'Development' (#292) from Development into master
Merging F2024-051, B2024-021, F2024-049, F2024-050 and F2024-045 after successful testing.
2024-04-05 10:54:57 -04:00
djankowski d7ace4eaf9 Merge pull request 'Development' (#287) from Development into master
Merging F2024-047, F2024-048, B2024-017 and B2024-019 from development into master after successful testing.
2024-04-04 11:36:56 -04:00
djankowski 16a4d335ea Merge pull request 'Development' (#282) from Development into master
Merging all items through B2024-018 from development into master after successful testing.
2024-03-27 13:39:46 -04:00
djankowski ba69bb0772 Merge pull request 'Development' (#275) from Development into master
Merging F2024-037 and CSLA updates into master after successful testing.
2024-03-20 16:07:27 -04:00
djankowski 455940caa2 Merge pull request 'Development' (#271) from Development into master
Merging F2024-040 into master after successful testing.
2024-03-18 10:00:30 -04:00
djankowski 439344757e Merge pull request 'Development' (#269) from Development into master
Merging F2024-044, F2024-043, and F2024-019 in master after successful testing.
2024-03-15 09:33:57 -04:00
djankowski ad912691c9 Merge pull request 'Development' (#265) from Development into master
Merging 	F2024-016, 	F2024-032, 	B2024-013, 	F2024-025,	F2024-027 & F2024-028 into master after successful testing.
2024-03-12 14:01:12 -04:00
djankowski 237144aff6 Merge pull request 'Development' (#259) from Development into master
Merging B2024-014 from development into master after successful testing.
2024-03-04 15:02:18 -05:00
djankowski 810332d558 Merge pull request 'Development' (#256) from Development into master
Merging F2024-020 from development into master.  No testing required since formats are under development.
2024-02-29 13:23:48 -05:00
djankowski f8431d0ba1 Merge pull request 'Development' (#252) from Development into master
Merging F2024-022 from development into master.  No testing required since formats are under development.
2024-02-29 09:23:51 -05:00
djankowski 57c3bfa16a Merge pull request 'Development' (#250) from Development into master
Merging C2023-003 and F2024-026 into master after successful testing.
2024-02-28 11:56:15 -05:00
djankowski 61f1077608 Merge pull request 'Development' (#248) from Development into master
Merging F2024-029, B2024-009, F2024-023, B2024-011, B2024-012 and F2024-017 from development into master after successful testing.
2024-02-27 14:21:22 -05:00
djankowski 8877e968b9 Merge pull request 'Development' (#239) from Development into master
Merging F2024-018, B2024-008, B2024-007, and F2024-015 from development into master after successful testing.
2024-02-22 08:22:26 -05:00
djankowski 4575c90bee Merge pull request 'Development' (#233) from Development into master
Merging updated formats from development into master after successful testing.
2024-02-14 16:07:57 -05:00
djankowski 21279a87ae Merge pull request 'Development' (#231) from Development into master
Merging B2024-006 from development into master after successful testing.
2024-02-14 08:19:09 -05:00
djankowski 3d5ad4a17e Merge pull request 'Development' (#229) from Development into master
Merging C2024-002 and F2024-013 from development into master after successful testing.
2024-02-09 11:30:41 -05:00
djankowski 9bb7b044a8 Merge pull request 'Development' (#226) from Development into master
Merging F2024-010, 	F2024-011, 	F2024-008, 	B2024-002, 	F2024-012  and B2024-005 from development into master after successful testing.
2024-02-08 11:38:49 -05:00
djankowski dc8f2f7561 Merge pull request 'Development' (#219) from Development into master
Merging C2022-009 into master after successful testing.
2024-02-02 13:53:22 -05:00
djankowski 829dbf84da Merge pull request 'Development' (#217) from Development into master
Merging F2024-005 and B2024-004 from development into master after successful testing
2024-01-31 08:34:00 -05:00
djankowski 7b156c17f8 Merge pull request 'Development' (#212) from Development into master
Merging all changes up through F2024-006 from development into master after successful testing.
2024-01-24 11:30:40 -05:00
djankowski cbf7cbc164 Merge pull request 'Development' (#198) from Development into master
Merging F2024-002 and F2023-112 from development into master.  No testing required since formats are under development.
2024-01-08 15:24:15 -05:00
djankowski b04faa816e Merge pull request 'Development' (#196) from Development into master
Merging F2023-126, F2024-001, C2022-009, C2023-024 and C2023-023 from development into Master after successful testing.
2024-01-03 10:54:22 -05:00
djankowski 517ebe2902 Merge pull request 'Development' (#189) from Development into master
Initial check-in of Vogtle Background formats.  No testing required since formats are under development.
2023-12-15 15:48:55 -05:00
djankowski 03d0d314e3 Merge pull request 'Development' (#187) from Development into master
Merging B2023-115 from development into master after successful testing.
2023-12-12 15:31:06 -05:00
djankowski 3e804c5cce Merge pull request 'Development' (#185) from Development into master
Merging F2023-133 into from development into master. No testing required since formats are under development.
2023-12-11 10:08:22 -05:00
djankowski ee2b8b538e Merge pull request 'Development' (#183) from Development into master
Merging PROMSFixes from development into master after minor changes to UpdateFormatList.
2023-12-08 14:51:21 -05:00
djankowski fdfd34fe92 Merge pull request 'Development' (#181) from Development into master
Merging F2023-151 from development into master.  No testing required since formats are under development.
2023-12-07 15:55:16 -05:00
djankowski 2d6fb6523b Merge pull request 'Development' (#179) from Development into master
Merging F2023-133 from development into master.  No testing required since formats are under development.
2023-12-07 11:44:31 -05:00
djankowski 3084bf3982 Merge pull request 'Development' (#177) from Development into master
Merging B2023-115 and F2023-150 from development into master.  No testing required since formats are under development.
2023-12-06 09:08:18 -05:00
djankowski 5ba51e8392 Merge pull request 'Development' (#174) from Development into master
Merging F2023-149 from development into master.  No testing required since formats are under development.
2023-12-05 16:30:39 -05:00
djankowski fb5eb43e34 Merge pull request 'Development' (#172) from Development into master
Merging F2023-124 from development into master.  No testing required since formats are under development.
2023-12-04 11:22:59 -05:00
djankowski b154056276 Merge pull request 'Development' (#170) from Development into master
Merging F2023-119 from development into master.  No testing required since formats are under development.
2023-12-01 15:36:22 -05:00
djankowski c67b8f9ca1 Merge pull request 'Development' (#168) from Development into master
Merging F2023-146 from development to master.  No testing required since formats are under development.
2023-12-01 10:02:50 -05:00
djankowski 95e4181360 Merge pull request 'Development' (#166) from Development into master
Merging F2023-148, F2023-148, and B2023-120 from development into Master. No testing required since formats are under development.
2023-11-30 14:38:49 -05:00
djankowski 32dffbe56b Merge pull request 'Development' (#162) from Development into master
Merging B2023-116, B2023-117, and F2023-143 from development to master after successful testing.
2023-11-29 15:58:44 -05:00
jjenko 6b3c8d373b Merge pull request 'F2023-143_Vogtle3&4_Alrm_Footer' (#159) from F2023-143_Vogtle3&4_Alrm_Footer into master
Format only change.
Vogtle 3&4 formats under development. This change will be tested as data in entered into PROMS by Volian
2023-11-27 16:23:44 -05:00
djankowski db29107f47 Merge pull request 'Development' (#156) from Development into master
Merging F2023-142 and B2022-046 in from development to master after successful testing.
2023-11-14 08:45:47 -05:00
djankowski 355537f2ab Merge pull request 'Development' (#153) from Development into master
Merging F2023-140, F2023-123, B2023-007, B2023-108, F2023-139, F2023-138 and B2023-103
2023-11-09 10:33:40 -05:00
djankowski 0729ef0c21 Merge pull request 'Development' (#147) from Development into master
Merging F2023-139 from development into master after successful testing.
2023-10-26 10:10:33 -04:00
djankowski 6fe82bfd0f Merge pull request 'Development' (#145) from Development into master
Merging F2023-138 from development into master after successful testing.
2023-10-25 14:40:15 -04:00
djankowski 39bf072363 Merge pull request 'Development' (#142) from Development into master
Merging B2023-103 from development into master after successful testing.
2023-10-23 15:28:31 -04:00
djankowski da7c384fd8 Merge pull request 'Development' (#139) from Development into master
Merging C2023-017, C2023-019, B2023-104, B2023-101 and B2023-102 from development into master after successful testing.
2023-10-18 10:37:59 -04:00
djankowski 95130fd9a0 Merge pull request 'Development' (#133) from Development into master
Merging C2023-018 from development into master after successful testing.
2023-10-11 09:26:45 -04:00
djankowski 978e2344a3 Merge pull request 'Development' (#131) from Development into master
Merging C2023-016 and C2023-017 from development into master after successful testing.
2023-10-06 10:56:34 -04:00
djankowski c9bf45602c Merge pull request 'Development' (#128) from Development into master
Merging F2023-137 and B2023-100 from development into master. F2023-137 does not require testing since formats are under development. B2023-100 tested successfully.
2023-10-02 11:52:22 -04:00
djankowski aa160b2036 Merge pull request 'Development' (#124) from Development into master
Merging B2023-099 from development into master after successful testing.
2023-09-28 15:58:27 -04:00
djankowski f82b32d351 Merge pull request 'Development' (#122) from Development into master
Merging B2023-097 and B2023-098 from development into master after successful testing.
2023-09-26 14:58:05 -04:00
djankowski e519dc9a57 Merge pull request 'Development' (#120) from Development into master
Merging B2023-094 from development into master after successful testing.
2023-09-22 13:24:17 -04:00
djankowski f020c37db9 Merge pull request 'Development' (#118) from Development into master
Merged B2023-096 from development into master after successful testing.
2023-09-15 11:50:57 -04:00
djankowski 5a4ec3b6b1 Merge pull request 'Development' (#117) from Development into master
Merging F2023-135 and B2023-093 from development into master after successful testing.
2023-09-14 15:58:52 -04:00
djankowski 2602d6c9d2 Merge pull request 'Development' (#113) from Development into master
Merging C2023-015 from development into master.
2023-09-12 09:23:57 -04:00
djankowski ff403583d7 Merge pull request 'Development' (#111) from Development into master
Merging B2023-091 and B2023-078 from development into master.
2023-08-30 16:07:17 -04:00
djankowski c5577cc2bd Merge pull request 'Development' (#108) from Development into master
Merging F2023-134 from development into master.  No testing required since formats are under development.
2023-08-24 15:01:12 -04:00
djankowski 78be6e5dc1 Merge pull request 'Development' (#106) from Development into master
Merging GitAutomation from Development into Master.
2023-08-24 09:13:06 -04:00
djankowski b954a41375 Merge pull request 'Development' (#104) from Development into master
Merging B2023-089 and F2023-131 from Development into Master.  No testing required since formats are under development.
2023-08-24 09:05:31 -04:00
djankowski 0100a11cfe Merge pull request 'Development' (#101) from Development into master
Merging F2023-125 from development into master.  No testing required since formats are under development.
2023-08-23 08:19:00 -04:00
djankowski 04cf2e8534 Merge pull request 'Development' (#99) from Development into master
Merging F2023-130 from Development into Master. No testing required since formats are under development.
2023-08-22 15:04:22 -04:00
djankowski be00724818 Merge pull request 'Development' (#97) from Development into master
Merging B2023-088 from development into master.  No testing required since formats are under development.
2023-08-22 10:52:09 -04:00
djankowski 274d93c61a Merge pull request 'Development' (#94) from Development into master
Merging F2023-122 from development into master.  No testing required since formats are under development.
2023-08-22 08:53:57 -04:00
djankowski 7dc4c30436 Merge pull request 'Development' (#92) from Development into master
Merging F2023-127 from development into master.  No testing required since formats are under development.
2023-08-22 08:33:56 -04:00
djankowski 028ef4bc31 Merge pull request 'Development' (#89) from Development into master
Merging F2023-128 and F2023-129 from development into master.  No testing required since formats are under development.
2023-08-21 11:46:01 -04:00
djankowski 42124d65c7 Merge pull request 'Development' (#87) from Development into master
Merging F2023-118,  F2023-120 and F2023-121 from development into master.  No testing required since formats are under development.
2023-08-16 10:13:52 -04:00
16 changed files with 529 additions and 884 deletions
@@ -116,12 +116,12 @@ namespace ROEditor
public uint thisoff; public uint thisoff;
public string title; public string title;
public FstTmpSTRC(ushort type, uint offset, string tl) public FstTmpSTRC(ushort type, uint offset, string tl)
{ {
thistype = type; thistype = type;
thisoff = offset; thisoff = offset;
title = tl; title = tl;
} }
void WriteString(BinaryWriter bw, string str) void WriteString(BinaryWriter bw, string str)
{ {
@@ -150,7 +150,7 @@ namespace ROEditor
bw.Write(thisoff); bw.Write(thisoff);
bw.Write(thistype); bw.Write(thistype);
WriteString(bw,title); WriteString(bw,title);
} }
} }
// The Sorted Array was not sorting via the ASCII value of each character in a given string. // The Sorted Array was not sorting via the ASCII value of each character in a given string.
@@ -565,8 +565,8 @@ namespace ROEditor
string RecIdStr = elem.GetAttribute("RecID"); string RecIdStr = elem.GetAttribute("RecID");
curRecID = System.Convert.ToUInt32(RecIdStr,16); curRecID = System.Convert.ToUInt32(RecIdStr,16);
// Get the current node's parent id // Get the current node's parent id
string ParIdStr = elem.GetAttribute("ParentID"); string ParIdStr = elem.GetAttribute("ParentID");
elemParentID = Convert.ToUInt32(ParIdStr,16); elemParentID = Convert.ToUInt32(ParIdStr,16);
string HasKids = elem.GetAttribute("HasChild"); string HasKids = elem.GetAttribute("HasChild");
@@ -771,8 +771,8 @@ namespace ROEditor
private ushort SaveROToFST(XmlNode RONode,ArrayList InUseList,string RtnValTmplate, string AccPageIDTplate) private ushort SaveROToFST(XmlNode RONode,ArrayList InUseList,string RtnValTmplate, string AccPageIDTplate)
{ {
ushort RtnVal; ushort RtnVal;
uint startFST = (uint)fhFST.BaseStream.Position; uint startFST = (uint)fhFST.BaseStream.Position;
uint RORecID; uint RORecID;
uint ParID; uint ParID;
byte nullbyte=0; byte nullbyte=0;
@@ -844,12 +844,8 @@ namespace ROEditor
AccPageID = " "; AccPageID = " ";
WriteString(AccPageID); WriteString(AccPageID);
//C2026-008 Re-Architect RO.FST to include RO Modification date/time // Save the ID and offset entry for the current ID
string moddt = ROdatabase.RODB_GetModDateTime(elem.GetAttribute("RecID"), elem.GetAttribute("Table")); IdsAndOffsets.Add(RORecID,startFST);
if (!string.IsNullOrEmpty(moddt)) WriteString(moddt);
// Save the ID and offset entry for the current ID
IdsAndOffsets.Add(RORecID, startFST);
// Save the RecID and Accessory Page id // Save the RecID and Accessory Page id
IdsAndAccPgIds[AccPageID] = RORecID; IdsAndAccPgIds[AccPageID] = RORecID;
@@ -322,9 +322,9 @@ namespace RODBInterface
get { return _PCChildList; } get { return _PCChildList; }
set { _PCChildList = value; } set { _PCChildList = value; }
} }
#endregion #endregion
#region abstracts // need these for each method that must be defined for each database type #region abstracts // need these for each method that must be defined for each database type
public abstract string RODB_GetNextGroupTable(); public abstract string RODB_GetNextGroupTable();
public abstract string RODB_GetNextRecId(string table); public abstract string RODB_GetNextRecId(string table);
public abstract bool RODB_GetRootGroups(VlnXmlElement root); public abstract bool RODB_GetRootGroups(VlnXmlElement root);
public abstract bool RODB_DeleteGroup(XmlNode group, string tbname, string toprecid); public abstract bool RODB_DeleteGroup(XmlNode group, string tbname, string toprecid);
@@ -355,10 +355,9 @@ namespace RODBInterface
public abstract string RODB_GetDBServerForAbout(); public abstract string RODB_GetDBServerForAbout();
public abstract string RODB_HasBeenConverted(); public abstract string RODB_HasBeenConverted();
public abstract bool RODB_WriteSqlConnectToAccess(string newConectStr); public abstract bool RODB_WriteSqlConnectToAccess(string newConectStr);
public abstract string RODB_GetModDateTime(string Recid, string table); #endregion
#endregion
public RODB() public RODB()
{ {
} }
@@ -2383,9 +2382,9 @@ namespace RODBInterface
RecID = DBE.GetString(0); RecID = DBE.GetString(0);
MyRecID = RecID; MyRecID = RecID;
Info = DBE.GetString(1); Info = DBE.GetString(1);
// it's defined in the local table if the first character is "<" which starts // it's defined in the local table if the first character is "<" which starts
// the schema definition string. // the schema definition string.
if ("<" == Info.Substring(0, 1)) if ("<" == Info.Substring(0, 1))
{ {
name = ParseEleName(Info); name = ParseEleName(Info);
if (name != null) if (name != null)
@@ -2426,7 +2425,7 @@ namespace RODBInterface
return retlist; return retlist;
} }
public override string RODB_GetSchemaPiece(string Recid, string table) public override string RODB_GetSchemaPiece(string Recid, string table)
{ {
string strGetSchemaPiece; string strGetSchemaPiece;
string Info; string Info;
@@ -3083,28 +3082,7 @@ namespace RODBInterface
return GrpCnt; return GrpCnt;
} }
//C2026-008 Re-Architect RO.FST to include RO Modification date/time }
//Get the Modification Date / Time for the RO
public override string RODB_GetModDateTime(string Recid, string table)
{
using (System.Data.OleDb.OleDbConnection connection = new System.Data.OleDb.OleDbConnection(strDatabaseConnectionCommand))
{
connection.Open();
using (System.Data.OleDb.OleDbCommand command = connection.CreateCommand())
{
//Unfortunately Access wont let you paramaterize the table name
command.CommandText = $"SELECT ModDateTime FROM {Regex.Replace(table, "[^a-zA-Z0-9]", "")} WHERE RecID = @Value";
command.Parameters.Add(new System.Data.OleDb.OleDbParameter
{
OleDbType = System.Data.OleDb.OleDbType.VarChar,
ParameterName = "@Value",
Value = Recid
});
return command.ExecuteScalar().ToString();
}
}
}
}
} }
@@ -1803,9 +1803,9 @@ namespace RODBInterface
RecID = reader.GetString(0); RecID = reader.GetString(0);
MyRecID = RecID; MyRecID = RecID;
Info = reader.GetString(1); Info = reader.GetString(1);
// it's defined in the local table if the first character is "<" which starts // it's defined in the local table if the first character is "<" which starts
// the schema definition string. // the schema definition string.
if ("<" == Info.Substring(0, 1)) if ("<" == Info.Substring(0, 1))
{ {
name = ParseEleName(Info); name = ParseEleName(Info);
if (name != null) if (name != null)
@@ -1859,9 +1859,9 @@ namespace RODBInterface
RecID = reader.GetString(0); RecID = reader.GetString(0);
MyRecID = RecID; MyRecID = RecID;
Info = reader.GetString(1); Info = reader.GetString(1);
// it's defined in the local table if the first character is "<" which starts // it's defined in the local table if the first character is "<" which starts
// the schema definition string. // the schema definition string.
if ("<" == Info.Substring(0, 1)) if ("<" == Info.Substring(0, 1))
{ {
name = ParseEleName(Info); name = ParseEleName(Info);
if (name != null) if (name != null)
@@ -2653,36 +2653,8 @@ namespace RODBInterface
} }
return GrpCnt; return GrpCnt;
} }
#endregion
//C2026-008 Re-Architect RO.FST to include RO Modification date/time public static bool TestConnect(string constring)
//Get the Modification Date / Time for the RO
public override string RODB_GetModDateTime(string Recid, string table)
{
using (SqlConnection connection = new SqlConnection(strDatabaseConnectionCommand))
{
connection.Open();
using (SqlCommand command = connection.CreateCommand())
{
command.CommandText = $"SELECT ModDateTime FROM ROALL WHERE RecID = @Value AND ROTable = @table";
command.Parameters.Add(new SqlParameter
{
SqlDbType = SqlDbType.VarChar,
ParameterName = "@Value",
Value = Recid
});
command.Parameters.Add(new SqlParameter
{
SqlDbType = SqlDbType.VarChar,
ParameterName = "@table",
Value = table
});
return command.ExecuteScalar().ToString();
}
}
}
#endregion
public static bool TestConnect(string constring)
{ {
bool success = false; bool success = false;
using (SqlConnection connection = new SqlConnection(constring)) using (SqlConnection connection = new SqlConnection(constring))
+32 -163
View File
@@ -13541,6 +13541,34 @@ IF EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[deleteAllDocVers
DROP PROCEDURE [deleteAllDocVersionPdfs]; DROP PROCEDURE [deleteAllDocVersionPdfs];
GO GO
/*****************************************************************************
Volian Enterprises - Proprietary Information - DO NOT COPY OR DISTRIBUTE
Copyright 2017 - Volian Enterprises, Inc. All rights reserved.
*****************************************************************************/
CREATE PROCEDURE [dbo].[deleteAllDocVersionPdfs]
(
@VersionID int
)
WITH EXECUTE AS OWNER
AS
BEGIN TRY -- Try Block
BEGIN TRANSACTION
DELETE [Pdfs]
WHERE [DocID] IN(select EE.DocID from vefn_GetVersionItems(cast(@VersionID as varchar(20))) VI
Join Entries EE ON EE.ContentID= VI.ContentID)
IF( @@TRANCOUNT > 0 ) COMMIT
END TRY
BEGIN CATCH -- Catch Block
IF( @@TRANCOUNT = 1 ) ROLLBACK -- Only rollback if top level
ELSE IF( @@TRANCOUNT > 1 ) COMMIT -- Otherwise commit. Top level will rollback
EXEC vlnErrorHandler
END CATCH
GO
-- Display the status of Proc creation
IF (@@Error = 0) PRINT 'Procedure Creation: deleteAllDocVersionPdfs Succeeded'
ELSE PRINT 'Procedure Creation: deleteAllDocVersionPdfs Error on Creation'
GO
/****** Object: StoredProcedure [addFiguresByROFstIDandImageIDs] ******/ /****** Object: StoredProcedure [addFiguresByROFstIDandImageIDs] ******/
IF EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[addFiguresByROFstIDandImageIDs]') AND OBJECTPROPERTY(id,N'IsProcedure') = 1) IF EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[addFiguresByROFstIDandImageIDs]') AND OBJECTPROPERTY(id,N'IsProcedure') = 1)
DROP PROCEDURE [addFiguresByROFstIDandImageIDs]; DROP PROCEDURE [addFiguresByROFstIDandImageIDs];
@@ -17141,7 +17169,6 @@ GO
[roid] [varchar](50) NOT NULL, [roid] [varchar](50) NOT NULL,
[appid] [varchar](max) NULL, [appid] [varchar](max) NULL,
[value] [varchar](max) NULL, [value] [varchar](max) NULL,
[moddatetime] [datetime] NULL,
CONSTRAINT [PK_RofstChild] PRIMARY KEY CLUSTERED CONSTRAINT [PK_RofstChild] PRIMARY KEY CLUSTERED
( (
[RofstChildID] ASC [RofstChildID] ASC
@@ -17276,23 +17303,6 @@ GO
End -- Rofst Tables End -- Rofst Tables
Go Go
-- =============================================
-- Author: Matthew Schill
-- Create date: 03/30/2026
-- Description: Store RO Modification date/time
-- =============================================
--- Add Column to store RO Modification date/time if it does not already exist
IF NOT EXISTS(SELECT *
FROM INFORMATION_SCHEMA.COLUMNS
WHERE TABLE_NAME = 'RofstChild'
AND COLUMN_NAME = 'moddatetime')
ALTER TABLE RofstChild ADD moddatetime datetime NULL;
go
-- Display the status
IF (@@Error = 0) PRINT 'Altered table [RofstChild] Succeeded for moddatetime'
ELSE PRINT 'Altered table [RofstChild] Error on Alter for moddatetime'
go
/* /*
---------------------------------------------------------------------------------- ----------------------------------------------------------------------------------
@@ -19695,7 +19705,6 @@ GO
@roid VarChar(50), @roid VarChar(50),
@appid VarChar(Max) = null, @appid VarChar(Max) = null,
@value VarChar(Max) = null, @value VarChar(Max) = null,
@ModDateTime DateTime = null,
@missingDefaultValue VarChar(Max) = null @missingDefaultValue VarChar(Max) = null
) )
With Execute as Owner With Execute as Owner
@@ -19713,8 +19722,8 @@ GO
Set @missingDefaultValue = '[TBD]'; Set @missingDefaultValue = '[TBD]';
-- Create Rofst Child/Group Record --> [Roid = (12) Digits] -- Create Rofst Child/Group Record --> [Roid = (12) Digits]
Insert Into RofstChild (RofstID, ID, ParentID, dbiID, [type], title, roid, appid, moddatetime, [value]) Insert Into RofstChild (RofstID, ID, ParentID, dbiID, [type], title, roid, appid, [value])
Values (@RofstID, @ID, @ParentID, @dbiID, @type, @title, @roid, @appid, @ModDateTime, REPLACE(REPLACE(@value, '&123;', '{'), '&125;', '}')); Values (@RofstID, @ID, @ParentID, @dbiID, @type, @title, @roid, @appid, REPLACE(REPLACE(@value, '&123;', '{'), '&125;', '}'));
-- Check for appid, if exists, then insert the default value for each return type if multi-value -- Check for appid, if exists, then insert the default value for each return type if multi-value
@@ -24768,146 +24777,6 @@ IF (@@Error = 0) PRINT 'Procedure Creation: [GetMissingDocsByUnit] Succeeded'
ELSE PRINT 'Procedure Creation: [GetMissingDocsByUnit] Error on Creation' ELSE PRINT 'Procedure Creation: [GetMissingDocsByUnit] Error on Creation'
GO GO
IF EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[vefn_ROFST_changes]') AND OBJECTPROPERTY(id,N'IsTableFunction') = 1)
DROP FUNCTION [vefn_ROFST_changes];
GO
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
/*
==========================================================================================================
Author: Matthew Schill
Create Date: 03/31/2026
Description: Function for ROs that updated in latest RO FST Load
==========================================================================================================
*/
CREATE FUNCTION [dbo].[vefn_ROFST_changes](@OrigFSTID int, @NewFSTid int, @VersionID int)
RETURNS @ROIDs TABLE
(
[roid] varchar(50)
)
WITH EXECUTE AS OWNER
AS
BEGIN
insert into @ROIDs
SELECT DISTINCT ISNULL(RofstChild.roid,previous.roid)
FROM
(SELECT * FROM RofstChild where RofstChild.RofstID = @NewFSTid) RofstChild
FULL OUTER JOIN
(SELECT * FROM RofstChild previous where previous.RofstID = @OrigFSTID) previous
ON previous.dbiID = RofstChild.dbiID AND previous.ID = RofstChild.ID
where
ISNULL(previous.RofstID,'') != ISNULL(RofstChild.RofstID,'')
AND
(
(RofstChild.RofstID = @NewFSTid OR RofstChild.RofstID IS NULL)
AND
(previous.RofstID = @OrigFSTID OR previous.RofstID IS NULL)
)
AND
(previous.moddatetime IS NULL
OR RofstChild.moddatetime IS NULL
OR RofstChild.moddatetime != previous.moddatetime
OR RofstChild.title != previous.title
OR RofstChild.value != previous.value
)
RETURN
END
go
IF (@@Error = 0) PRINT 'TableFunction [vefn_ROFST_changes] Succeeded'
ELSE PRINT 'TableFunction [vefn_ROFST_changes] Error on Creation'
go
/****** Object: StoredProcedure [deleteDocVersionPdfsWithNewROs] ******/
IF EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[deleteDocVersionPdfsWithNewROs]') AND OBJECTPROPERTY(id,N'IsProcedure') = 1)
DROP PROCEDURE [deleteDocVersionPdfsWithNewROs];
GO
/*
==========================================================================================================
Author: Matthew Schill
Create Date: 03/31/2026
Description: Delete all PDFs with ROs that will need re-resolved
==========================================================================================================
*/
CREATE PROCEDURE [dbo].[deleteDocVersionPdfsWithNewROs]
(
@VersionID int,
@OrigFSTid int,
@NewFSTid int
)
WITH EXECUTE AS OWNER
AS
BEGIN
DELETE [Pdfs]
WHERE [DocID] IN
(
select EE.DocID from vefn_GetVersionItems(cast(@VersionID as varchar(20))) VI
Join Entries EE ON EE.ContentID= VI.ContentID
Join DRoUsages ON DRoUsages.DocID = EE.DocID
Join dbo.vefn_ROFST_changes(@OrigFSTID, @NewFSTid, @VersionID) ROFST_changes on LEFT(DRoUsages.ROID,12) = ROFST_changes.roid
)
RETURN
END
GO
-- Display the status of Proc creation
IF (@@Error = 0) PRINT 'Procedure Creation: deleteDocVersionPdfsWithNewROs Succeeded'
ELSE PRINT 'Procedure Creation: deleteDocVersionPdfsWithNewROs Error on Creation'
GO
/****** Object: StoredProcedure [getItemsWithNewROs] ******/
IF EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N'[getItemsWithNewROs]') AND OBJECTPROPERTY(id,N'IsProcedure') = 1)
DROP PROCEDURE [getItemsWithNewROs];
GO
/*
==========================================================================================================
Author: Matthew Schill
Create Date: 03/31/2026
Description: Get Items with New ROs that will need resolved
==========================================================================================================
*/
CREATE PROCEDURE [dbo].[getItemsWithNewROs]
(
@VersionID int,
@OrigFSTid int,
@NewFSTid int
)
WITH EXECUTE AS OWNER
AS
BEGIN
select DISTINCT tblItems.ItemID FROM
dbo.vefn_ROFST_changes(@OrigFSTID, @NewFSTid, @VersionID) ROFST_changes
INNER JOIN RoUsages ON LEFT(RoUsages.ROID,12) = ROFST_changes.roid
INNER JOIN tblItems ON RoUsages.ContentID = tblItems.ContentID
OUTER APPLY (Select VersionID = dbo.vefn_GetVersionIDByItemID(tblItems.ItemID)) ver
INNER JOIN DocVersions DV ON DV.VersionID = ver.VersionID
INNER JOIN Associations ON Associations.VersionID = DV.VersionID
where ver.VersionID = @VersionID
RETURN
END
GO
-- Display the status of Proc creation
IF (@@Error = 0) PRINT 'Procedure Creation: getItemsWithNewROs Succeeded'
ELSE PRINT 'Procedure Creation: getItemsWithNewROs Error on Creation'
GO
/* /*
--------------------------------------------------------------------------- ---------------------------------------------------------------------------
| ADD New Code Before this Block | | ADD New Code Before this Block |
@@ -24941,8 +24810,8 @@ BEGIN TRY -- Try Block
DECLARE @RevDate varchar(255) DECLARE @RevDate varchar(255)
DECLARE @RevDescription varchar(255) DECLARE @RevDescription varchar(255)
set @RevDate = '04/21/2026 7:00 AM' set @RevDate = '03/13/2026 7:00 AM'
set @RevDescription = 'Store RO Modification date/time' set @RevDescription = 'Added Get Missing Docs by Unit for Generating Pdf table'
Select cast(@RevDate as datetime) RevDate, @RevDescription RevDescription Select cast(@RevDate as datetime) RevDate, @RevDescription RevDescription
PRINT 'SQL Code Revision ' + @RevDate + ' - ' + @RevDescription PRINT 'SQL Code Revision ' + @RevDate + ' - ' + @RevDescription
@@ -1036,11 +1036,8 @@ namespace VEPROMS
ROFstInfo roFstInfo = dq.DocVersionAssociations[0].MyROFst; ROFstInfo roFstInfo = dq.DocVersionAssociations[0].MyROFst;
string rofstPath = roFstInfo.MyRODb.FolderPath + @"\ro.fst"; string rofstPath = roFstInfo.MyRODb.FolderPath + @"\ro.fst";
//must get id before ROFST gets updated so know what to refresh later //if (!pathExists(rofstPath))
int origfstid = roFstInfo.ROFstID; if (!File.Exists(rofstPath))
//if (!pathExists(rofstPath))
if (!File.Exists(rofstPath))
{ {
ProgressBar.ColorTable = eProgressBarItemColor.Error; ProgressBar.ColorTable = eProgressBarItemColor.Error;
FinalProgressBarMessage = "No existing RO.FST"; FinalProgressBarMessage = "No existing RO.FST";
@@ -1066,29 +1063,9 @@ namespace VEPROMS
ROFstInfo.UpdateRoFst(roFstInfo.MyRODb, dv, roFstInfo, DoProgressBarRefresh); ROFstInfo.UpdateRoFst(roFstInfo.MyRODb, dv, roFstInfo, DoProgressBarRefresh);
roFstInfo = dq.DocVersionAssociations[0].MyROFst; roFstInfo = dq.DocVersionAssociations[0].MyROFst;
} }
else if (!dv.ROfstLastCompleted && origfstid == roFstInfo.ROFstID) roFstInfo.ROTableUpdate += new ROFstInfoROTableUpdateEvent(roFstInfo_ROTableUpdate);
{ ROFst newrofst = ROFstInfo.RefreshROFst(dv, roFstInfo, DoProgressBarRefresh, txtProcess);
//Handle issue where load failed without completing update roFstInfo.ROTableUpdate -= new ROFstInfoROTableUpdateEvent(roFstInfo_ROTableUpdate);
//previous RO FST did not load, get last loaded ID
//if none, use -1 which will check all ROs in the Working Draft
string cfg = dv.DocVersionAssociations[0].Config;
AssociationConfig ac = new AssociationConfig((cfg == null || cfg.Length == 0) ? "<Config />" : cfg);
if (dv.DocVersionAssociations[0]?.MyROFst != null)
{
if (!int.TryParse(ac.ROUpdate_PrevROFSTID, out origfstid))
{
origfstid = -1;
}
}
else
{
origfstid = -1;
}
}
roFstInfo.ROTableUpdate += new ROFstInfoROTableUpdateEvent(roFstInfo_ROTableUpdate);
ROFstInfo.RefreshROFstAtItemLevel(DocVersionInfo.Get(dv.VersionID), DoProgressBarRefresh, txtProcess, roFstInfo, origfstid, roFstInfo.ROFstID);
roFstInfo.ROTableUpdate -= new ROFstInfoROTableUpdateEvent(roFstInfo_ROTableUpdate);
} }
Cursor = Cursors.Default; Cursor = Cursors.Default;
@@ -1339,10 +1316,10 @@ namespace VEPROMS
{ {
if (ProgressBar == null) return; if (ProgressBar == null) return;
ProgressBar.Text = value; ProgressBar.Value = 100;
ProgressBar.Maximum = 100; ProgressBar.Maximum = 100;
ProgressBar.Value = 100; ProgressBar.Text = value;
txtProcess.AppendText(value); txtProcess.AppendText(value);
txtProcess.AppendText(Environment.NewLine); txtProcess.AppendText(Environment.NewLine);
txtProcess.AppendText(Environment.NewLine); txtProcess.AppendText(Environment.NewLine);
+8 -45
View File
@@ -1594,7 +1594,7 @@ namespace VEPROMS
displayRO.MyROFST = SelectedROFst; displayRO.MyROFST = SelectedROFst;
// B2023-021: force Load of Step Prop/RO panel RO tree by passing in // B2023-021: force Load of Step Prop/RO panel RO tree by passing in
// true to LoadTree // true to LoadTree
if (!_WeAreExitingPROMS) displayRO.LoadTree(true); displayRO.LoadTree(true);
} }
} }
@@ -2395,7 +2395,6 @@ namespace VEPROMS
tv.MySessionInfo = MySessionInfo; tv.MySessionInfo = MySessionInfo;
tv.MyUserInfo = MyUserInfo; tv.MyUserInfo = MyUserInfo;
StepTabRibbon.MySessionInfo = MySessionInfo; StepTabRibbon.MySessionInfo = MySessionInfo;
displayRO.MySessionInfo = MySessionInfo;
// Initialize Caption with Server name and Database name. // Initialize Caption with Server name and Database name.
SetCaption(tv.TopNode as VETreeNode); SetCaption(tv.TopNode as VETreeNode);
@@ -4554,15 +4553,6 @@ namespace VEPROMS
SetCaption(tv.SelectedNode as VETreeNode); SetCaption(tv.SelectedNode as VETreeNode);
displayApplicability.MyDisplayTabItem = tc.SelectedDisplayTabItem; displayApplicability.MyDisplayTabItem = tc.SelectedDisplayTabItem;
//C2026-008 Re-Architect RO.FST to include RO Modification date/time
// DisplayTab was changed
// need to clear the RTB selected
// without resetting the DVI or FST
// (those will be set manually / individually)
// this will prevent DVI and FST from changing to null then back again
// which will trigger reloads
displayRO.ClearRTB();
if (tc.SelectedDisplayTabItem.MyItemInfo.MyDocVersion.DocVersionAssociationCount > 0) if (tc.SelectedDisplayTabItem.MyItemInfo.MyDocVersion.DocVersionAssociationCount > 0)
{ {
displayRO.MyROFST = tc.SelectedDisplayTabItem.MyItemInfo.MyDocVersion.DocVersionAssociations[0].MyROFst; displayRO.MyROFST = tc.SelectedDisplayTabItem.MyItemInfo.MyDocVersion.DocVersionAssociations[0].MyROFst;
@@ -4572,24 +4562,9 @@ namespace VEPROMS
displayRO.MyROFST = null; displayRO.MyROFST = null;
} }
//C2026-008 Re-Architect RO.FST to include RO Modification date/time // B2022-026 RO Memory reduction coding (Jakes Merge)
// set the DocVersionInfo so that the FST and docversion are in sync // B2022-123: RO Tab Treeview not showing correct RO values when switching between procedures. (Added True for the forceLoad parameter)
SelectedDVI = tc.SelectedDisplayTabItem.MyItemInfo.MyDocVersion; displayRO.LoadTree(true);
if (displayRO.MyDvi != SelectedDVI)
{
displayRO.MyDvi = SelectedDVI;
}
Application.DoEvents();
// B2022-026 RO Memory reduction coding (Jakes Merge)
// B2022-123: RO Tab Treeview not showing correct RO values when switching between procedures. (Added True for the forceLoad parameter)
//C2026-008 Re-Architect RO.FST to include RO Modification date/time
// if ROFST got updated,
// set the Selected FST so it is in sync
if (!_WeAreExitingPROMS && displayRO.LoadTree(true))
{
SelectedROFst = displayRO.MyROFST;
}
lblUser.Text = tc.SelectedDisplayTabItem.MyUserRole; lblUser.Text = tc.SelectedDisplayTabItem.MyUserRole;
@@ -4790,13 +4765,7 @@ namespace VEPROMS
// B2022-026 RO Memory reduction coding (Jakes Merge) // B2022-026 RO Memory reduction coding (Jakes Merge)
displayRO.ProgressBar = bottomProgBar; displayRO.ProgressBar = bottomProgBar;
displayRO.MyRTB = args.MyEditItem.MyStepRTB; displayRO.MyRTB = args.MyEditItem.MyStepRTB;
//C2026-008 Re-Architect RO.FST to include RO Modification date/time displayRO.LoadTree();
// if ROFST got updated,
// set the Selected FST so it is in sync
if (!_WeAreExitingPROMS && displayRO.LoadTree())
{
SelectedROFst = displayRO.MyROFST;
}
displayBookMarks.MyEditItem = args.MyEditItem; displayBookMarks.MyEditItem = args.MyEditItem;
displayHistory.MyEditItem = args.MyEditItem; displayHistory.MyEditItem = args.MyEditItem;
@@ -4826,7 +4795,7 @@ namespace VEPROMS
// B2022-026 RO Memory reduction coding (Jakes Merge) // B2022-026 RO Memory reduction coding (Jakes Merge)
displayRO.SetFindDocROButton(false); displayRO.SetFindDocROButton(false);
if (!_WeAreExitingPROMS) displayRO.LoadTree(); displayRO.LoadTree();
//C2019-036 View Only mode work with Checked Out Procedures //C2019-036 View Only mode work with Checked Out Procedures
//In View Only Mode - Step Properties should be disabled //In View Only Mode - Step Properties should be disabled
@@ -4959,14 +4928,8 @@ namespace VEPROMS
displayRO.MyRTB = SelectedStepTabPanel.MyStepPanel.SelectedEditItem.MyStepRTB; displayRO.MyRTB = SelectedStepTabPanel.MyStepPanel.SelectedEditItem.MyStepRTB;
displayRO.CurROLink = args.MyLinkText.MyRoUsageInfo; displayRO.CurROLink = args.MyLinkText.MyRoUsageInfo;
// B2022-026 RO Memory reduction coding (Jakes Merge) // B2022-026 RO Memory reduction coding (Jakes Merge)
//C2026-008 Re-Architect RO.FST to include RO Modification date/time displayRO.LoadTree();
// if ROFST got updated,
// set the Selected FST so it is in sync
if (displayRO.LoadTree())
{
SelectedROFst = displayRO.MyROFST;
}
} }
#endregion #endregion
@@ -899,10 +899,10 @@ namespace VEPROMS
set set
{ {
if (ProgressBar == null) return; if (ProgressBar == null) return;
ProgressBar.Text = value; ProgressBar.Maximum = 100;
ProgressBar.Maximum = 100; ProgressBar.Value = 100;
ProgressBar.Value = 100; ProgressBar.Text = value;
Application.DoEvents(); Application.DoEvents();
} }
} }
@@ -1527,11 +1527,8 @@ namespace VEPROMS
Cursor = Cursors.WaitCursor; Cursor = Cursors.WaitCursor;
//must get id before ROFST gets updated so know what to refresh later // RO changes placed in file in the Documents\VEPROMS folder
int origfstid = SelectedROFst.ROFstID; swROUpdate = new System.IO.StreamWriter(ROFstInfo.ROUpdateResultsPath(_DocVersionConfig.MyDocVersion.MyDocVersionInfo));
// RO changes placed in file in the Documents\VEPROMS folder
swROUpdate = new System.IO.StreamWriter(ROFstInfo.ROUpdateResultsPath(_DocVersionConfig.MyDocVersion.MyDocVersionInfo));
DocVersion dv = _DocVersionConfig.MyDocVersion; DocVersion dv = _DocVersionConfig.MyDocVersion;
// B2022-026 RO Memory Reduction code - first load the new ro.fst so that we can assign the ROTableUpdate event to the correct roFstInfo // B2022-026 RO Memory Reduction code - first load the new ro.fst so that we can assign the ROTableUpdate event to the correct roFstInfo
if (dv.ROfstLoadingFigures || dv.NewerRoFst) // B2017-125 see if loading figures was completed if (dv.ROfstLoadingFigures || dv.NewerRoFst) // B2017-125 see if loading figures was completed
@@ -1539,32 +1536,13 @@ namespace VEPROMS
ROFstInfo.UpdateRoFst(SelectedROFst.MyRODb, dv, SelectedROFst, DoProgressBarRefresh); ROFstInfo.UpdateRoFst(SelectedROFst.MyRODb, dv, SelectedROFst, DoProgressBarRefresh);
SelectedROFst = null; // set to null to force getting the updated ROfst SelectedROFst = null; // set to null to force getting the updated ROfst
} }
else if (!dv.ROfstLastCompleted && origfstid == SelectedROFst.ROFstID)
{
//Handle issue where load failed without completing update
//previous RO FST did not load, get last loaded ID
//if none, use -1 which will check all ROs in the Working Draft
string cfg = dv.DocVersionAssociations[0].Config;
AssociationConfig ac = new AssociationConfig((cfg == null || cfg.Length == 0) ? "<Config />" : cfg);
if (dv.DocVersionAssociations[0]?.MyROFst != null)
{
if (!int.TryParse(ac.ROUpdate_PrevROFSTID, out origfstid))
{
origfstid = -1;
}
}
else
{
origfstid = -1;
}
}
ContentInfo.StaticContentInfoChange += ContentInfo_StaticContentInfoChange; // write changes to a text file ContentInfo.StaticContentInfoChange += ContentInfo_StaticContentInfoChange; // write changes to a text file
SelectedROFst.ROTableUpdate += new ROFstInfoROTableUpdateEvent(roFstInfo_ROTableUpdate); SelectedROFst.ROTableUpdate += new ROFstInfoROTableUpdateEvent(roFstInfo_ROTableUpdate);
ROFstInfo.RefreshROFstAtItemLevel(DocVersionInfo.Get(dv.VersionID), DoProgressBarRefresh, null, SelectedROFst, origfstid, SelectedROFst.ROFstID); ROFst newrofst = ROFstInfo.RefreshROFst(_DocVersionConfig.MyDocVersion, SelectedROFst, DoProgressBarRefresh, null);
ContentInfo.StaticContentInfoChange -= ContentInfo_StaticContentInfoChange; ContentInfo.StaticContentInfoChange -= ContentInfo_StaticContentInfoChange;
SelectedROFst.ROTableUpdate -= new ROFstInfoROTableUpdateEvent(roFstInfo_ROTableUpdate); SelectedROFst.ROTableUpdate -= new ROFstInfoROTableUpdateEvent(roFstInfo_ROTableUpdate);
swROUpdate.Close(); swROUpdate.Close();
@@ -124,26 +124,9 @@ namespace VEPROMS.CSLA.Library
_Xp["ROUpdate", "LoadingFigures"] = value; // save selected value _Xp["ROUpdate", "LoadingFigures"] = value; // save selected value
} }
} }
#endregion // ROUpdate
[Category("RO Update")] #region ToString
[DisplayName("Previous ROFSTID")] public override string ToString()
[RefreshProperties(RefreshProperties.All)]
[Description("Previous ROFSTID")]
public string ROUpdate_PrevROFSTID
{
get
{
string s = _Xp["ROUpdate", "PrevROFSTID"];// get the saved value
return s;
}
set
{
_Xp["ROUpdate", "PrevROFSTID"] = value; // save selected value
}
}
#endregion // ROUpdate
#region ToString
public override string ToString()
{ {
string s = _Xp.ToString(); string s = _Xp.ToString();
if (s == "<Config/>" || s == "<Config></config>") return string.Empty; if (s == "<Config/>" || s == "<Config></config>") return string.Empty;
@@ -97,8 +97,7 @@ namespace VEPROMS.CSLA.Library
public string appid; public string appid;
public int ID; public int ID;
public int ParentID; public int ParentID;
public DateTime? ModDateTime; //C2026-008 Re-Architect RO.FST to include RO Modification date/time public rochild[] children;
public rochild[] children;
}; };
[Serializable] [Serializable]
@@ -111,8 +110,7 @@ namespace VEPROMS.CSLA.Library
public string roid; // roid unique identifier public string roid; // roid unique identifier
public string appid; // accessory page id - user specified unique id public string appid; // accessory page id - user specified unique id
public string value; // return value, can be multiple values public string value; // return value, can be multiple values
public DateTime? ModDateTime; //C2026-008 Re-Architect RO.FST to include RO Modification date/time public rochild[] children;
public rochild[] children;
}; };
public class RoExtension public class RoExtension
@@ -688,19 +686,15 @@ namespace VEPROMS.CSLA.Library
//return string.Format("{0,10:#####0.00}", TimeSpan.FromTicks(DateTime.Now.Ticks - dtStart.Ticks).TotalSeconds); //return string.Format("{0,10:#####0.00}", TimeSpan.FromTicks(DateTime.Now.Ticks - dtStart.Ticks).TotalSeconds);
} }
//C2026-008 Re-Architect RO.FST to include RO Modification date/time #endregion
//return new ROFstID if there is a newer ID that matches the same ROFSTDB
public int GetNewerFSTID() => RofstGetLatestID(RofstID);
#endregion #endregion
#endregion #region Private Methods
#region Private Methods #region (Database Calls)
#region (Database Calls) private bool RofstDataExists(int rofstID)
private bool RofstDataExists(int rofstID)
{ {
int headerStatusID = RofstDataGetHeaderLoadStatus(rofstID); int headerStatusID = RofstDataGetHeaderLoadStatus(rofstID);
@@ -894,7 +888,7 @@ namespace VEPROMS.CSLA.Library
} }
} }
private void RofstChildInsert(int rofstID, int id, int parentID, int dbiID, int type, string title, string roid, string appid, string value, DateTime? dt = null) private void RofstChildInsert(int rofstID, int id, int parentID, int dbiID, int type, string title, string roid, string appid, string value)
{ {
try try
{ {
@@ -923,10 +917,7 @@ namespace VEPROMS.CSLA.Library
if (!string.IsNullOrEmpty(this.RoMissingDefaultValue)) if (!string.IsNullOrEmpty(this.RoMissingDefaultValue))
cmd.Parameters.Add(new SqlParameter("@missingDefaultValue", SqlDbType.VarChar)).Value = this.RoMissingDefaultValue; cmd.Parameters.Add(new SqlParameter("@missingDefaultValue", SqlDbType.VarChar)).Value = this.RoMissingDefaultValue;
if (dt != null) cmd.ExecuteNonQuery();
cmd.Parameters.Add(new SqlParameter("@ModDateTime", SqlDbType.DateTime)).Value = dt;
cmd.ExecuteNonQuery();
} }
} }
} }
@@ -1308,37 +1299,11 @@ namespace VEPROMS.CSLA.Library
} }
} }
//C2026-008 Re-Architect RO.FST to include RO Modification date/time #endregion
//return new ROFstID if there is a newer ID that matches the same ROFSTDB
private int RofstGetLatestID(int rofstID)
{
try
{
using (SqlConnection cn = Database.VEPROMS_SqlConnection)
{
using (SqlCommand cmd = cn.CreateCommand())
{
cmd.CommandTimeout = 0;
cmd.CommandType = CommandType.Text;
cmd.CommandText = "SELECT ISNULL((SELECT TOP 1 ROFsts.ROFstID FROM ROFsts INNER JOIN ROFsts curFST ON curFST.RODbID = ROFsts.RODbID WHERE curFST.ROFstID = @FSTid order by ROFsts.DTS desc),-1)";
cmd.Parameters.Add(new SqlParameter("@FSTid", SqlDbType.Int)).Value = rofstID; #region (Core/Base logic for RO Values & UnitInfo RO Values)
return (int) cmd.ExecuteScalar(); private ROFSTLookup.rochild RofstDataGetChildByRoid(int rofstID, string roid, bool loadChildren = false, bool loadAllChildren = false)
}
}
}
catch (Exception ex)
{
throw new DbCslaException("RofstData.RofstGetLatestID", ex);
}
}
#endregion
#region (Core/Base logic for RO Values & UnitInfo RO Values)
private ROFSTLookup.rochild RofstDataGetChildByRoid(int rofstID, string roid, bool loadChildren = false, bool loadAllChildren = false)
{ {
try try
{ {
@@ -1550,7 +1515,7 @@ namespace VEPROMS.CSLA.Library
myOffset += (7 + slen); myOffset += (7 + slen);
ROFSTLookup.rogrp tmpg = LoadGroup(ab, childOffset, tableID); ROFSTLookup.rogrp tmpg = LoadGroup(ab, childOffset, tableID);
tmp.ID = tmpg.ID; tmp.ID = tmpg.ID;
tmp.ParentID = tmpg.ParentID; tmp.ParentID = tmpg.ParentID;
@@ -1558,12 +1523,8 @@ namespace VEPROMS.CSLA.Library
tmp.appid = tmpg.appid; tmp.appid = tmpg.appid;
tmp.roid = tableID.ToString("X4") + tmp.ID.ToString("X8"); tmp.roid = tableID.ToString("X4") + tmp.ID.ToString("X8");
tmp.children = tmpg.children; tmp.children = tmpg.children;
if (tmpg.ModDateTime != null)
{
tmp.ModDateTime = tmpg.ModDateTime;
}
int j; int j;
for (j = i - 1; j >= 0 && tmp.ID < myGrp.children[j].ID; j--) for (j = i - 1; j >= 0 && tmp.ID < myGrp.children[j].ID; j--)
{ {
@@ -1581,13 +1542,7 @@ namespace VEPROMS.CSLA.Library
int slen2 = StringLength(ab, offset + 13 + slen); int slen2 = StringLength(ab, offset + 13 + slen);
myGrp.appid = Encoding.Default.GetString(ab, offset + 13 + slen, slen2); myGrp.appid = Encoding.Default.GetString(ab, offset + 13 + slen, slen2);
//C2026-008 Re-Architect RO.FST to include RO Modification date/time _dbRoCnt++;
if (myGrp.value != "" && DateTime.TryParseExact(Encoding.Default.GetString(ab, offset + 14 + slen + slen2, 14), "yyyyMMddHHmmss", null, System.Globalization.DateTimeStyles.None, out DateTime dt))
{
myGrp.ModDateTime = dt;
}
_dbRoCnt++;
} }
return myGrp; return myGrp;
@@ -1700,7 +1655,7 @@ namespace VEPROMS.CSLA.Library
private void LoadChild(int rofstID, int dbiID, ROFSTLookup.rochild child) private void LoadChild(int rofstID, int dbiID, ROFSTLookup.rochild child)
{ {
//Insert Rofst Child //Insert Rofst Child
RofstChildInsert(rofstID, child.ID, child.ParentID, dbiID, child.type, child.title, child.roid, child.appid, child.value, child.ModDateTime); RofstChildInsert(rofstID, child.ID, child.ParentID, dbiID, child.type, child.title, child.roid, child.appid, child.value);
//Increment RO Count if RoChild has a return value //Increment RO Count if RoChild has a return value
if (!string.IsNullOrEmpty(child.value)) _curRoCnt++; if (!string.IsNullOrEmpty(child.value)) _curRoCnt++;
+28 -87
View File
@@ -1093,17 +1093,8 @@ namespace VEPROMS.CSLA.Library
} }
} }
} }
// B2022-026 RO Memory Reduction code - pass in ROFstInfo
//C2026-008 Re-Architect RO.FST to include RO Modification date/time internal static void MyRefreshReferenceObjects(ItemInfo itemInfo, IVEDrillDownReadOnly itemParent, SectionInfo sectionInfo, DocVersionInfo docVersionInfo, ROFstInfo origROFst)
//Refresh at item level
public static void RefreshReferenceObjects(ItemInfo tmp, ROFstInfo origROFst)
{
if (tmp.MyDocVersion.DocVersionConfig.SelectedSlave <= 0)
MyRefreshReferenceObjects(tmp, null, tmp.GetSectionInfo(), tmp.MyDocVersion, origROFst);
}
// B2022-026 RO Memory Reduction code - pass in ROFstInfo
internal static void MyRefreshReferenceObjects(ItemInfo itemInfo, IVEDrillDownReadOnly itemParent, SectionInfo sectionInfo, DocVersionInfo docVersionInfo, ROFstInfo origROFst)
{ {
if (itemInfo.MyContent.ContentPartCount > 0) if (itemInfo.MyContent.ContentPartCount > 0)
{ {
@@ -1228,47 +1219,31 @@ namespace VEPROMS.CSLA.Library
return true; return true;
} }
//C2026-008 Re-Architect RO.FST to include RO Modification date/time #region Debug Code
public static List<ItemInfo> GetItemInfoWithChangedROs(int docversionid, int origfstid, int newfstid)
{
List<ItemInfo> lst = new List<ItemInfo>();
foreach (DataRow r in Data_GetItemsWithChangedROs(docversionid, origfstid, newfstid).Rows) //private static void ShowDifference(string oldText, string newText)
{ //{
using (ItemInfo itm = Get((int)r["ItemID"])) // string nt = newText.Replace(@"\u8209?", "-").Replace(@"\u160?", " ").Replace("\xA0", " ");
{ // string ot = oldText.Replace(@"\u8209?", "-").Replace(@"\u160?", " ").Replace("\xA0", " ");
lst.Add(itm); // ShowText("OldText", ot);
} // ShowText("NewText", nt);
} //}
//private static void ShowText(string title, string newText)
//{
// StringBuilder sb = new StringBuilder();
// foreach (char c in newText)
// {
// if(c<' ' || c> '\x7F')
// sb.Append(string.Format("\\x{0:X2}",((int) c)));
// else
// sb.Append(c);
// }
// Console.WriteLine("{0}='{1}'",title,sb.ToString());
//}
return lst; #endregion // debug
}
#region Debug Code internal static void SetParentSectionAndDocVersionPageNum(ItemInfo itemInfo, IVEDrillDownReadOnly itemParent, SectionInfo sectionInfo, ProcedureInfo procInfo, DocVersionInfo docVersionInfo, TransitionLookup tranLookup)
//private static void ShowDifference(string oldText, string newText)
//{
// string nt = newText.Replace(@"\u8209?", "-").Replace(@"\u160?", " ").Replace("\xA0", " ");
// string ot = oldText.Replace(@"\u8209?", "-").Replace(@"\u160?", " ").Replace("\xA0", " ");
// ShowText("OldText", ot);
// ShowText("NewText", nt);
//}
//private static void ShowText(string title, string newText)
//{
// StringBuilder sb = new StringBuilder();
// foreach (char c in newText)
// {
// if(c<' ' || c> '\x7F')
// sb.Append(string.Format("\\x{0:X2}",((int) c)));
// else
// sb.Append(c);
// }
// Console.WriteLine("{0}='{1}'",title,sb.ToString());
//}
#endregion // debug
internal static void SetParentSectionAndDocVersionPageNum(ItemInfo itemInfo, IVEDrillDownReadOnly itemParent, SectionInfo sectionInfo, ProcedureInfo procInfo, DocVersionInfo docVersionInfo, TransitionLookup tranLookup)
{ {
if (itemInfo.MyContent.ContentPartCount > 0) if (itemInfo.MyContent.ContentPartCount > 0)
{ {
@@ -1915,44 +1890,10 @@ namespace VEPROMS.CSLA.Library
foreach (ItemInfo itemInfo in partInfo.MyItems) foreach (ItemInfo itemInfo in partInfo.MyItems)
itemInfo.SpinThroughChildren(); itemInfo.SpinThroughChildren();
} }
#endregion
//C2026-008 Re-Architect RO.FST to include RO Modification date/time #region LoadAtOnce
private static DataTable Data_GetItemsWithChangedROs(int docversionid, int origfstid, int newfstid) // Method to Get Item and children
{ public static ItemInfo GetItemAndChildren(int? itemID, int? parentID)
try
{
using (SqlConnection cn = Database.VEPROMS_SqlConnection)
{
using (SqlCommand cm = cn.CreateCommand())
{
cm.CommandType = CommandType.StoredProcedure;
cm.CommandText = "getItemsWithNewROs";
cm.Parameters.AddWithValue("@VersionID", docversionid);
cm.Parameters.AddWithValue("@OrigFSTid", origfstid);
cm.Parameters.AddWithValue("@NewFSTid", newfstid);
cm.CommandTimeout = Database.DefaultTimeout;
using (SqlDataAdapter da = new SqlDataAdapter(cm))
{
DataTable dt = new DataTable();
da.Fill(dt);
return dt;
}
}
}
}
catch (Exception ex)
{
Database.LogException("ItemInfoList.Data_GetItemsWithChangedROs", ex);
throw new DbCslaException("ItemInfoList.Data_GetItemsWithChangedROs", ex);
}
}
#endregion
#region LoadAtOnce
// Method to Get Item and children
public static ItemInfo GetItemAndChildren(int? itemID, int? parentID)
{ {
try try
{ {
+50 -40
View File
@@ -61,47 +61,57 @@ namespace VEPROMS.CSLA.Library
throw new DbCslaException("Pdf.DataPortal_Delete", ex); throw new DbCslaException("Pdf.DataPortal_Delete", ex);
} }
} }
// used to remove word section PDFs to force ROs to be updated when printed or saved
public static void DeleteAllDocVersion(int versionID)
{
if (!CanDeleteObject())
throw new System.Security.SecurityException("User not authorized to remove a Pdf");
try
{
DataPortal.Delete(new VersionIDCriteria(versionID));
}
catch (Exception ex)
{
throw new DbCslaException("Error on Pdf.DeleteAllDocVersion", ex);
}
}
[Serializable()]
protected class VersionIDCriteria
{
private int _VersionID;
public int VersionID
{ get { return _VersionID; } }
public VersionIDCriteria(int versionID)
{
_VersionID = versionID;
}
}
[Transactional(TransactionalTypes.TransactionScope)]
private void DataPortal_Delete(VersionIDCriteria criteria)
{
if (_MyLog.IsDebugEnabled) _MyLog.DebugFormat("[{0}] Pdf.DataPortal_Delete", GetHashCode());
try
{
using (SqlConnection cn = Database.VEPROMS_SqlConnection)
{
using (SqlCommand cm = cn.CreateCommand())
{
cm.CommandType = CommandType.StoredProcedure;
cm.CommandTimeout = Database.SQLTimeout;
cm.CommandText = "deleteAllDocVersionPdfs";
cm.Parameters.AddWithValue("@VersionID", criteria.VersionID);
cm.ExecuteNonQuery();
}
}
}
catch (Exception ex)
{
if (_MyLog.IsErrorEnabled) _MyLog.Error("Pdf.DataPortal_Delete", ex);
_ErrorMessage = ex.Message;
throw new DbCslaException("Pdf.DataPortal_Delete", ex);
}
}
//C2026-008 Re-Architect RO.FST to include RO Modification date/time
// used to remove word section PDFs to force ROs to be updated when printed or saved
public static void DeleteDocVersionPDFsWithNewROs(int versionID, int origfstid, int newfstid)
{
if (!CanDeleteObject())
throw new System.Security.SecurityException("User not authorized to remove a Pdf");
try
{
DeleteWithNewROs(versionID, origfstid, newfstid);
}
catch (Exception ex)
{
throw new DbCslaException("Error on Pdf.DeleteAllDocVersion", ex);
}
}
static private void DeleteWithNewROs(int docversionID, int origfstid, int newfstid)
{
try
{
using (SqlConnection cn = Database.VEPROMS_SqlConnection)
{
using (SqlCommand cm = cn.CreateCommand())
{
cm.CommandType = CommandType.StoredProcedure;
cm.CommandTimeout = Database.SQLTimeout;
cm.CommandText = "deleteDocVersionPdfsWithNewROs";
cm.Parameters.AddWithValue("@VersionID", docversionID);
cm.Parameters.AddWithValue("@OrigFSTid", origfstid);
cm.Parameters.AddWithValue("@NewFSTid", newfstid);
cm.ExecuteNonQuery();
}
}
}
catch (Exception ex)
{
if (_MyLog.IsErrorEnabled) _MyLog.Error("Pdf.DeleteWithNewROs", ex);
throw new DbCslaException("Pdf.DeleteWithNewROs", ex);
}
}
} }
public partial class PdfInfo public partial class PdfInfo
{ {
+245 -77
View File
@@ -225,62 +225,41 @@ namespace VEPROMS.CSLA.Library
} }
} }
//C2026-008 Re-Architect RO.FST to include RO Modification date/time // B2022-026 RO Memory Reduction code - pass in the ROFstInfo
// Refresh at item level public static int RefreshROFst(DocVersionInfo dvi, ROFstInfoProgressBarRefresh myProgressBarRefresh, System.Windows.Forms.TextBox tbStatus, ROFstInfo origROFst)
public static int RefreshROFstAtItemLevel(DocVersionInfo dvi, ROFstInfoProgressBarRefresh myProgressBarRefresh, System.Windows.Forms.TextBox tbStatus, ROFstInfo localROFst, int origfstid, int newfstid) {
{ int fixedROs = 0;
int fixedROs = 0;
if (dvi.DocVersionConfig.SelectedSlave <= 0) if (dvi.DocVersionConfig.SelectedSlave <= 0)
{ {
// remove word section PDFs to force update of RO values when printed myProgressBarRefresh(1, 100, "Update MS Word ROs");
myProgressBarRefresh(1, 100, "Updating MS Word ROs In Progress");
Pdf.DeleteDocVersionPDFsWithNewROs(dvi.VersionID, origfstid, newfstid);
//Loop Through ROs in this docversion that are different than the previous fst Pdf.DeleteAllDocVersion(dvi.VersionID); // remove word section PDFs to force update of RO values when printed
myProgressBarRefresh(50, 100, "Updating ROs In PROMS Steps In Progress"); int i = 0;
int i = 0;
List<ItemInfo> list = ItemInfo.GetItemInfoWithChangedROs(dvi.VersionID, origfstid, newfstid);
foreach (ItemInfo itm in list)
{
DateTime start = DateTime.Now;
ItemInfo.ResetROCounters(); foreach (ProcedureInfo proc in dvi.Procedures)
myProgressBarRefresh(++i, list.Count, string.Format("{0} ({1}/{2} ROs {3})", itm.MyProcedure.DisplayNumber, i, list.Count, fixedROs)); {
ItemInfo.RefreshReferenceObjects(itm, localROFst); DateTime start = DateTime.Now;
fixedROs += ItemInfo.ROFixCount;
TimeSpan ts = DateTime.Now - start; ProcedureInfo.ResetROCounters();
myProgressBarRefresh(++i, dvi.Procedures.Count, string.Format("{0} ({1}/{2} ROs {3})", proc.DisplayNumber, i, dvi.Procedures.Count, fixedROs));
ProcedureInfo.RefreshReferenceObjects(proc, origROFst);
fixedROs += ProcedureInfo.ROFixCount;
if (tbStatus != null) TimeSpan ts = DateTime.Now - start;
tbStatus.AppendText(string.Format("Procedure: {1}{0}, Checked {2} Referenced Objects{0}, Fixed {3} Referenced Objects{0}, Elapsed Seconds:{4}{0}{0}", Environment.NewLine, itm.MyProcedure.DisplayNumber, ItemInfo.ROCheckCount, ItemInfo.ROFixCount, ts.TotalSeconds));
}
//Update the DocVersion Associations to link to the new RO FST id and current date/time if (tbStatus != null)
using (DocVersion dv = DocVersion.Get(dvi.VersionID)) tbStatus.AppendText(string.Format("Procedure: {1}{0}, Checked {2} Referenced Objects{0}, Fixed {3} Referenced Objects{0}, Elapsed Seconds:{4}{0}{0}", Environment.NewLine, proc.DisplayNumber, ProcedureInfo.ROCheckCount, ProcedureInfo.ROFixCount, ts.TotalSeconds));
{ }
if (dvi.DocVersionAssociations[0].MyROFst.ROFstID != newfstid) }
{
dv.DocVersionAssociations[0].MyROFst = localROFst.GetJustROFst();
SetAssociationLastCompleted(dv, DateTime.Now.ToString());
}
}
}
// pop up a message window telling the user the RO Update has completed and how many ROs were updated return fixedROs;
// If we are updating RO from the Admin Tools (from the V button) and we are updating more than on procedure set, then just append the "RO Update Complete" text }
// To the MessageList. Once completed will all procedure sets, Admin Tools will display one message box with all the results in it.
if (MessageList == null)
FlexibleMessageBox.Show(fixedROs == 0 ? "No ROs Required Updating" : string.Format("{0} ROs Updated for {1}", fixedROs, dvi.MyFolder.Name), "RO Update Complete");
else
MessageList.AppendLine((fixedROs == 0 ? "No ROs Required Updating for " : string.Format("{0} ROs Updated for ", fixedROs)) + dvi.MyFolder.Name);
return fixedROs;
}
//C2022-028 for Admin tool to check for bad RO links //C2022-028 for Admin tool to check for bad RO links
//B2022-144 we now loop through checked procedures list from Admin Tools and call this method for each procedure we want to process //B2022-144 we now loop through checked procedures list from Admin Tools and call this method for each procedure we want to process
public static int CheckROLinksInThisProcedure(ProcedureInfo proc, System.Windows.Forms.TextBox tbStatus) public static int CheckROLinksInThisProcedure(ProcedureInfo proc, System.Windows.Forms.TextBox tbStatus)
{ {
int FoundBadROLinks = 0; int FoundBadROLinks = 0;
DocVersionInfo dvi = DocVersionInfo.Get(proc.MyDocVersion.VersionID); DocVersionInfo dvi = DocVersionInfo.Get(proc.MyDocVersion.VersionID);
@@ -312,6 +291,34 @@ namespace VEPROMS.CSLA.Library
return Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments) + @"\VEPROMS\ROUpdateReport_" + ValidFileName.FixFileName(dvi.MyFolder.Name.Replace(" ", "_") + "_" + DateTime.Now.ToString("MM-dd-yyyy_HH-mm-ss") + ".txt"); return Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments) + @"\VEPROMS\ROUpdateReport_" + ValidFileName.FixFileName(dvi.MyFolder.Name.Replace(" ", "_") + "_" + DateTime.Now.ToString("MM-dd-yyyy_HH-mm-ss") + ".txt");
} }
// B2022-026 RO Memory Reduction code - moved the call to UpdateROFst() to before we call RefreshROFst
// so that we used the correct ROFstInfo which as the needed event methods set when updated RO Table types
public static ROFst RefreshROFst(DocVersion docver, ROFstInfo origROFst, ROFstInfoProgressBarRefresh myProgressBarRefresh, System.Windows.Forms.TextBox tbStatus)
{
ROFst rofst = null;
rofst = docver.DocVersionAssociations[0].MyROFst;
DocVersionInfo dvi = DocVersionInfo.Get(docver.VersionID);
SetAssociationLastCompleted(docver, string.Empty);
int fixedROs = RefreshROFst(dvi, myProgressBarRefresh, tbStatus, origROFst);
SetAssociationLastCompleted(docver, DateTime.Now.ToString()); // RO Update completed successfully and un-interrupted, save the date/time to the Doc Version Association config
myProgressBarRefresh(100, 100, "RO Update Complete"); // update the progress bar
System.Windows.Forms.Application.DoEvents();
// pop up a message window telling the user the RO Update has completed and how many ROs were updated
// If we are updating RO from the Admin Tools (from the V button) and we are updating more than on procedure set, then just append the "RO Update Complete" text
// To the MessageList. Once completed will all procedure sets, Admin Tools will display one message box with all the results in it.
if (MessageList == null)
FlexibleMessageBox.Show(fixedROs == 0 ? "No ROs Required Updating" : string.Format("{0} ROs Updated for {1}", fixedROs, dvi.MyFolder.Name), "RO Update Complete");
else
MessageList.AppendLine((fixedROs == 0 ? "No ROs Required Updating for " : string.Format("{0} ROs Updated for ", fixedROs)) + dvi.MyFolder.Name);
return rofst;
}
/// <summary> /// <summary>
/// Updates an ro.fst into a sql database. /// Updates an ro.fst into a sql database.
/// </summary> /// </summary>
@@ -328,9 +335,7 @@ namespace VEPROMS.CSLA.Library
{ {
if (myProgressBarRefresh != null) myProgressBarRefresh(0, 100, "Starting Update"); if (myProgressBarRefresh != null) myProgressBarRefresh(0, 100, "Starting Update");
int origFSTid = origROFst.ROFstID; DirectoryInfo di = new DirectoryInfo(rdi.FolderPath);
DirectoryInfo di = new DirectoryInfo(rdi.FolderPath);
string rofstfilepath = rdi.FolderPath + @"\ro.fst"; string rofstfilepath = rdi.FolderPath + @"\ro.fst";
FileStream fsIn = new FileStream(rofstfilepath, FileMode.Open, FileAccess.Read, FileShare.ReadWrite); FileStream fsIn = new FileStream(rofstfilepath, FileMode.Open, FileAccess.Read, FileShare.ReadWrite);
FileInfo rofstFI = new FileInfo(rofstfilepath); FileInfo rofstFI = new FileInfo(rofstfilepath);
@@ -356,9 +361,8 @@ namespace VEPROMS.CSLA.Library
docver.DocVersionAssociations[0].MyROFst = rofst; docver.DocVersionAssociations[0].MyROFst = rofst;
SetAssociationLastCompleted(docver, string.Empty); SetAssociationLastCompleted(docver, string.Empty);
SetPrevFSTID(docver, origFSTid); // //C2026-008 Re-Architect RO.FST to include RO Modification date/time
return rofst; return rofst;
} }
// Read in the rofst & make the rofst record. // Read in the rofst & make the rofst record.
@@ -380,10 +384,7 @@ namespace VEPROMS.CSLA.Library
// Keep a list of ROIDs for Images that have changed. // Keep a list of ROIDs for Images that have changed.
List<string> MyChangedFigureROIDs = UpdateROFigures(rdi, myProgressBarRefresh, rofst, rodb, myLookup, docver); List<string> MyChangedFigureROIDs = UpdateROFigures(rdi, myProgressBarRefresh, rofst, rodb, myLookup, docver);
//C2026-008 Re-Architect RO.FST to include RO Modification date/time return rofst;
SetPrevFSTID(docver, origFSTid);
return rofst;
} }
} }
@@ -483,22 +484,8 @@ namespace VEPROMS.CSLA.Library
docver.Save(); docver.Save();
} }
//C2026-008 Re-Architect RO.FST to include RO Modification date/time // Place the status of loading the RO Figures when updating RO Values
// Place the previous ROFSTID in the config in case network error or computer crashes while updating RO Values private static void SetAssociationROFiguresLoading(DocVersion docver, string value)
private static void SetPrevFSTID(DocVersion docver, int value)
{
if (docver.DocVersionAssociations[0]?.MyROFst != null && value != -1)
{
string cfg = docver.DocVersionAssociations[0].Config;
AssociationConfig ac = new AssociationConfig((cfg == null || cfg.Length == 0) ? "<Config />" : cfg);
ac.ROUpdate_PrevROFSTID = value.ToString();
docver.DocVersionAssociations[0].Config = ac.ToString();
docver.Save();
}
}
// Place the status of loading the RO Figures when updating RO Values
private static void SetAssociationROFiguresLoading(DocVersion docver, string value)
{ {
string cfg = docver.DocVersionAssociations[0].Config; string cfg = docver.DocVersionAssociations[0].Config;
@@ -683,7 +670,188 @@ namespace VEPROMS.CSLA.Library
return sb.ToString(); return sb.ToString();
} }
private static DateTime ShowDuration(DateTime dtLast, string message) private static void UpdateROValuesText(ROFstInfo origROFstInfo, ROFst newROFst, DocVersionInfo dvi, ROFstInfoProgressBarRefresh myProgressBarRefresh, List<string> MyChangedFigureROIDs)
{
if (myProgressBarRefresh != null) myProgressBarRefresh(0, 100, "Update Ro Values");
string versionList = dvi.VersionID.ToString();
ROFSTLookup origLookup = new ROFSTLookup(origROFstInfo.ROFstID, dvi);
ROFSTLookup newLookup = new ROFSTLookup(newROFst.ROFstID, dvi);
List<string> delList = new List<string>();
List<string> chgList = newLookup.GetValueDifferences(origROFstInfo.ROFstID, ref delList);
// Any figures which have been changed will be included in the list of values that have changed.
if (MyChangedFigureROIDs != null)
{
foreach (string roid in MyChangedFigureROIDs)
{
if (!chgList.Contains(roid)) chgList.Add(roid);
}
}
string RoidList = GetRoidList(newROFst.RODbID, chgList);
if (myProgressBarRefresh != null) myProgressBarRefresh(0, chgList.Count, "Getting List of ROs Used");
List<string> activeRoids = BuildActiveROIDsForRoUsages12(RoidList, versionList);
if (myProgressBarRefresh != null) myProgressBarRefresh(0, chgList.Count, "Updating RO Values");
int iCount = 0;
if (activeRoids.Count > 0)
{
foreach (string chg in chgList)
{
if (myProgressBarRefresh != null) myProgressBarRefresh(++iCount, chgList.Count, "Updating RO Values");
if (activeRoids.Contains(chg.Substring(0, 12)))
{
ROFSTLookup.rochild roch = newLookup.GetRoChild(chg);
string desc = string.Format("Change in RO Values: Old value = {0}, New value = {1}", origLookup.GetRoChild(chg).value, roch.value);
// roid's are stored in database as 16 characters long in the RoUsages table. They may be stored as 12 characters in the ro.fst.
// string padroid = chg.Length <= 12 ? chg + "0000" : chg;
// B2022-088: Find Doc Ro button not working in Word Sections
string padroid = ROFSTLookup.FormatRoidKey(chg, true);
using (RoUsageInfoList affected = RoUsageInfoList.GetAffected(origROFstInfo.MyRODb.RODbID, padroid, desc, "Changed", versionList))
{
foreach (RoUsageInfo roUsg in affected)
{
using (Content content = Content.Get(roUsg.MyContent.ContentID))
{
foreach (ItemInfo ii in roUsg.MyContent.ContentItems)
{
string val = newLookup.GetTranslatedRoValue(padroid, ii.ActiveFormat.PlantFormat.FormatData.SectData.ConvertCaretToDelta, ii.ActiveFormat.PlantFormat.FormatData.SectData.UseTildaPoundCharsForSuperSubScriptInROValues, false, ii);
content.FixContentText(roUsg, val, roch.type, origROFstInfo, true);
if (content.IsDirty)
{
// Update UserID and DTS when RO Value is updated.
content.UserID = Volian.Base.Library.VlnSettings.UserID;
content.DTS = DateTime.Now;
content.Save();
if (content.MyGrid != null)
{
GridInfo.Refresh(content.MyGrid);
}
}
}
}
}
}
}
}
}
if (myProgressBarRefresh != null) myProgressBarRefresh(0, chgList.Count, "Getting List of ROs Used");
List<string> activeDRoids = BuildActiveROIDsForDRoUsages12(RoidList, versionList);
iCount = 0;
if (activeDRoids.Count > 0)
{
foreach (string chg in chgList)
{
// B2022-088: Find Doc Ro button not working in Word Sections
// string padroid = chg.Length <= 12 ? chg + "0000" : chg;
string padroid = ROFSTLookup.FormatRoidKey(chg, true);
if (myProgressBarRefresh != null) myProgressBarRefresh(++iCount, chgList.Count, "Updating RO Values");
if (activeDRoids.Contains(chg.Substring(0, 12)))
{
ROFSTLookup.rochild roch = newLookup.GetRoChild(chg);
string desc = string.Format("Change in RO Values: Old value = {0}, New value = {1}", origLookup.GetRoChild(chg).value, roch.value);
// roid's are stored in database as 16 characters long in the rousages table. They may be stored as 12 characters in the ro.fst.
using (DROUsageInfoList affected = DROUsageInfoList.GetAffected(origROFstInfo.MyRODb.RODbID, padroid, desc, "Changed", versionList))
{
foreach (DROUsageInfo droUsg in affected)
{
Pdf.DeleteAll(droUsg.DocID);
}
}
}
}
}
iCount = 0;
string RoidDelList = GetRoidList(newROFst.RODbID, delList);
if (myProgressBarRefresh != null) myProgressBarRefresh(0, chgList.Count, "Getting List of ROs Used");
activeRoids = BuildActiveROIDsForRoUsages12(RoidDelList, versionList);
if (activeRoids.Count > 0)
{
foreach (string del in delList)
{
// B2022-088: Find Doc Ro button not working in Word Sections
//string padroiddel = del.Length <= 12 ? del + "0000" : del;
string padroiddel = ROFSTLookup.FormatRoidKey(del, true);
if (myProgressBarRefresh != null) myProgressBarRefresh(++iCount, chgList.Count, "Removing Old RO Values");
string desc = string.Format("Deleted RO: Value = {0}", origLookup.GetRoChild(del).value);
if (activeRoids.Contains(del.Substring(0, 12).ToUpper()))
{
using (RoUsageInfoList affected = RoUsageInfoList.GetAffected(origROFstInfo.MyRODb.RODbID, padroiddel, desc, "Deleted", versionList))
{
foreach (RoUsageInfo roUsg in affected)
{
using (Content content = Content.Get(roUsg.MyContent.ContentID))
{
content.FixContentText(roUsg, "?", 0, origROFstInfo);
if (content.IsDirty)
{
// Update UserID and DTS when RO Value is updated.
content.UserID = Volian.Base.Library.VlnSettings.UserID;
content.DTS = DateTime.Now;
content.Save();
}
}
}
}
}
}
}
if (myProgressBarRefresh != null) myProgressBarRefresh(0, chgList.Count, "Getting List of ROs Used");
activeDRoids = BuildActiveROIDsForDRoUsages12(RoidDelList, versionList);
iCount = 0;
if (activeDRoids.Count > 0)
{
foreach (string del in delList)
{
// B2022-088: Find Doc Ro button not working in Word Sections
string padroiddel = ROFSTLookup.FormatRoidKey(del, true);
if (myProgressBarRefresh != null) myProgressBarRefresh(++iCount, chgList.Count, "Removing Old RO Values");
string desc = string.Format("Deleted RO: Value = {0}", origLookup.GetRoChild(del).value);
// If there's an issue then maybe try getting the RoChild with the Padded roid instead
//string desc = string.Format("Deleted RO: Value = {0}", origLookup.GetRoChild(padroiddel).value);
if (activeDRoids.Contains(del.Substring(0, 12).ToUpper()))
{
using (DROUsageInfoList Daffected = DROUsageInfoList.GetAffected(origROFstInfo.MyRODb.RODbID, padroiddel, desc, "Deleted", versionList))
{
foreach (DROUsageInfo droUsg in Daffected)
{
if (myProgressBarRefresh != null) myProgressBarRefresh(++iCount, chgList.Count, "Removing Old RO Values");
Pdf.DeleteAll(droUsg.DocID);
}
}
}
}
}
if (myProgressBarRefresh != null) myProgressBarRefresh(100, 100, "RO Values Updated");
}
private static DateTime ShowDuration(DateTime dtLast, string message)
{ {
DateTime dtNext = DateTime.Now; DateTime dtNext = DateTime.Now;
Console.WriteLine("{0,10:#####0.00},'{1}'", TimeSpan.FromTicks(dtNext.Ticks - dtLast.Ticks).TotalSeconds, message); Console.WriteLine("{0,10:#####0.00},'{1}'", TimeSpan.FromTicks(dtNext.Ticks - dtLast.Ticks).TotalSeconds, message);
@@ -931,10 +1099,10 @@ namespace VEPROMS.CSLA.Library
} }
} }
#endregion #endregion
} }
public class ROFstInfoROTableUpdateEventArgs public class ROFstInfoROTableUpdateEventArgs
{ {
private string _ROText; private string _ROText;
public string ROText public string ROText
@@ -1084,5 +1252,5 @@ namespace VEPROMS.CSLA.Library
this.RaiseListChangedEvents = true; this.RaiseListChangedEvents = true;
} }
} }
} }
+82 -170
View File
@@ -59,11 +59,11 @@ namespace Volian.Controls.Library
private DisplayTags displayTags; private DisplayTags displayTags;
#endregion #endregion
#region Properties #region Properties
public ProgressBarItem ProgressBar public ProgressBarItem ProgressBar
{ {
get { return _progressBar; } get { return _progressBar; }
set { _progressBar = value; } set { _progressBar = value; }
@@ -89,10 +89,7 @@ namespace Volian.Controls.Library
(_myRTB != null && (_myRTB.IsRoTable != lastRTBwasROTable || _myRTB.IsRoFigure != lastRTBwasROFigure)); } (_myRTB != null && (_myRTB.IsRoTable != lastRTBwasROTable || _myRTB.IsRoFigure != lastRTBwasROFigure)); }
} }
//This flag will be set when the docversion gets updated to let it know that the full tree needs a refresh public ROFstInfo MyROFST
private bool changedDocVersion = false;
public ROFstInfo MyROFST
{ {
get { return _myROFST; } get { return _myROFST; }
set set
@@ -131,22 +128,16 @@ namespace Volian.Controls.Library
// B2022-135 Submitted for Admin Tools (Check RO Links tool) // B2022-135 Submitted for Admin Tools (Check RO Links tool)
if (_docVersionInfo == null || _docVersionInfo != value || _docVersionInfo.VersionID != value.VersionID) if (_docVersionInfo == null || _docVersionInfo != value || _docVersionInfo.VersionID != value.VersionID)
{ {
//Set flag for modified the docversion - should check for new ROs _docVersionInfo = value;
if (_docVersionInfo?.VersionID != value?.VersionID)
{
changedDocVersion = true;
}
_docVersionInfo = value;
if (_myRTB != null && (_docVersionInfo == null || _docVersionInfo.VersionID != _myRTB.MyDVI.VersionID)) if (_myRTB != null && (_docVersionInfo == null || _docVersionInfo.VersionID != _myRTB.MyDVI.VersionID))
{ {
_docVersionInfo = _myRTB.MyDVI; _docVersionInfo = _myRTB.MyDVI;
} }
} }
// B2022-123: RO Tab Treeview not showing correct RO values when switching between procedures. // B2022-123: RO Tab Treeview not showing correct RO values when switching between procedures.
_currDocVersionID = (_docVersionInfo != null) ? (int?)_docVersionInfo.VersionID : null; _currDocVersionID = (_docVersionInfo != null) ? (int?)_docVersionInfo.VersionID : null;
} }
} }
@@ -210,11 +201,7 @@ namespace Volian.Controls.Library
// B2022-098: [JPR] ROs not being resolved in Word Sections // B2022-098: [JPR] ROs not being resolved in Word Sections
CurROLink = null; CurROLink = null;
_savCurROLink = null; _savCurROLink = null;
}
//Clear flag for modified the docversion (if should check for new ROs)
//clearing this flag here prevents it from checking twice
changedDocVersion = false;
}
else if(_myRTB != value) else if(_myRTB != value)
{ {
if (_myRTB != null) if (_myRTB != null)
@@ -234,9 +221,9 @@ namespace Volian.Controls.Library
CurROLink = null; CurROLink = null;
_savCurROLink = null; _savCurROLink = null;
} }
// B2023-004 assign the doc version info associated with the current RTB (rich text box) // B2023-004 assign the doc version info associated with the current RTB (rich text box)
// this fixes an issue where unit designators could not be linked in the step edit (BNPP data) // this fixes an issue where unit designators could not be linked in the step edit (BNPP data)
MyDvi = _myRTB.MyItemInfo.MyDocVersion; MyDvi = _myRTB.MyItemInfo.MyDocVersion;
MyROFST = (_myRTB.MyItemInfo.MyDocVersion.DocVersionAssociationCount > 0) ? _myRTB.MyItemInfo.MyDocVersion.DocVersionAssociations[0].MyROFst : null; MyROFST = (_myRTB.MyItemInfo.MyDocVersion.DocVersionAssociationCount > 0) ? _myRTB.MyItemInfo.MyDocVersion.DocVersionAssociations[0].MyROFst : null;
} }
@@ -264,13 +251,11 @@ namespace Volian.Controls.Library
set { _myUserInfo = value; } set { _myUserInfo = value; }
} }
public SessionInfo MySessionInfo { get; set; } #endregion
#endregion #region Constructors
#region Constructors public DisplayRO()
public DisplayRO()
{ {
InitializeComponent(); InitializeComponent();
@@ -292,62 +277,48 @@ namespace Volian.Controls.Library
// Initialize the DisplayTags object // Initialize the DisplayTags object
displayTags = new DisplayTags(); displayTags = new DisplayTags();
_progressBar = null;
} }
#endregion #endregion
#region Event Handlers
#region (Progress Bar)
private string InitialProgressBarMessage #region Event Handlers
{
set
{
if (ProgressBar == null) return;
ProgressBar.Value = 0;
ProgressBar.Maximum = 100;
ProgressBar.Text = value;
Application.DoEvents();
}
}
private string FinalProgressBarMessage
{
set
{
if (ProgressBar == null) return;
ProgressBar.Text = value;
ProgressBar.Maximum = 100;
ProgressBar.Value = 100;
Application.DoEvents();
}
}
private void DoProgressBarRefresh(int value, int max, string text)
{
if (ProgressBar == null) return;
ProgressBar.Maximum = max;
ProgressBar.Value = value;
ProgressBar.Text = text;
Application.DoEvents();
}
#endregion #region (Progress Bar)
#region (RTB) private void ProgressBar_Initialize(int max, string desc)
{
if (_progressBar != null)
{
_progressBar.Maximum = max;
_progressBar.Text = desc;
_progressBar.TextVisible = true;
}
}
//C2026-008 Re-Architect RO.FST to include RO Modification date/time private void ProgressBar_SetValue(int curval)
// DisplayTab was changed {
// need to clear the RTB selected if (_progressBar != null)
// without resetting the DVI or FST {
// (those will be set manually / individually) _progressBar.Value = curval;
// this will prevent DVI and FST from changing to null then back again }
// which will trigger reloads }
public void ClearRTB()
{
_myRTB = null;
CurROLink = null;
_savCurROLink = null;
}
public void MyRTB_LinkChanged(object sender, StepPanelLinkEventArgs args) private void ProgressBar_Clear()
{
if (_progressBar != null)
{
_progressBar.Text = string.Empty;
_progressBar.Maximum = 0;
_progressBar.Value = 0;
}
}
#endregion
#region (RTB)
public void MyRTB_LinkChanged(object sender, StepPanelLinkEventArgs args)
{ {
CurROLink = null; CurROLink = null;
if (MyRTB.MyLinkText != null) CurROLink = args.MyLinkText.MyRoUsageInfo; if (MyRTB.MyLinkText != null) CurROLink = args.MyLinkText.MyRoUsageInfo;
@@ -594,106 +565,55 @@ namespace Volian.Controls.Library
} }
} }
private void lbFound_SelectedValueChanged(object sender, EventArgs e) private void lbFound_SelectedValueChanged(object sender, EventArgs e)
{
if (lbFound.Visible && lbFound.SelectedIndex >= 0 && lbFound.SelectedValue != null)
{
ExpandNode(Convert.ToString(lbFound.SelectedValue));
}
}
#endregion
#region (ROUpdate)
public List<string> roFstInfo_ROTableUpdate(object sender, ROFstInfoROTableUpdateEventArgs args)
{
return VlnFlexGrid.ROTableUpdate(sender, args);
}
#endregion
#endregion
#region Public Methods
//C2026-008 Re-Architect RO.FST to include RO Modification date/time
// changed to return true if the RO FST got updated
public bool LoadTree(bool forceReload = false)
{ {
bool updatedROs = false; if (lbFound.Visible && lbFound.SelectedIndex >= 0 && lbFound.SelectedValue != null)
{
ExpandNode(Convert.ToString(lbFound.SelectedValue));
}
}
#endregion
#endregion
#region Public Methods
public void LoadTree(bool forceReload = false)
{
if (MyROFST == null) if (MyROFST == null)
{ {
tvROFST.Nodes.Clear(); tvROFST.Nodes.Clear();
lbFound.Visible = false; lbFound.Visible = false;
return updatedROs; return;
} }
if (changedDocVersion || forceReload || RoTreeNeedsReloaded || tvROFST.Nodes == null || tvROFST.Nodes.Count <= 0) if (forceReload || RoTreeNeedsReloaded || tvROFST.Nodes == null || tvROFST.Nodes.Count <= 0)
{ {
//C2026-008 Re-Architect RO.FST to include RO Modification date/time //B2025-008
//check if newer data - if there is, check if user wants to update data //in cases where a RO table is clicked on
int fstid = MyROFSTLookup.GetNewerFSTID(); //it will refresh the list
int origfstid = MyROFSTLookup.RofstID; //temp store what the ROID was before the list refreshes
//so can go to it after the refresh
string tmpROID = CurROLink?.ROID;
if (_docVersionInfo != null && fstid != -1 && fstid != MyROFSTLookup.RofstID) ROFSTLookup.rodbi[] dbs = MyROFSTLookup.GetRODatabaseList(true);
{
string message = string.Empty;
if (_progressBar?.Text != "Cannot check-out Working Draft" && !MySessionInfo.CanCheckOutItem(_docVersionInfo.VersionID, CheckOutType.DocVersion, ref message))
{
FlexibleMessageBox.Show(this, message, "Working Draft Has Items Already Checked Out", MessageBoxButtons.OK, MessageBoxIcon.Warning);
FinalProgressBarMessage = "Cannot check-out Working Draft";
}
else if (!MySessionInfo.CanCheckOutItem(_docVersionInfo.VersionID, CheckOutType.DocVersion, ref message))
{
//do nothing - is still checked out
}
else if (changedDocVersion && MessageBox.Show($"There exists a newer ROFST for this RO database that was loaded for other sets.\r\n\r\nDo you want to update this set's ROs to be consistent/use the latest loaded ROFST?", "Load ROs", MessageBoxButtons.YesNo) == DialogResult.Yes)
{
InitialProgressBarMessage = "Updating ROs";
ROFstInfo roFstInfo = ROFstInfo.Get(fstid);
roFstInfo.ROTableUpdate += new ROFstInfoROTableUpdateEvent(roFstInfo_ROTableUpdate);
ROFstInfo.RefreshROFstAtItemLevel(_docVersionInfo, DoProgressBarRefresh, null, roFstInfo, origfstid, fstid);
roFstInfo.ROTableUpdate -= new ROFstInfoROTableUpdateEvent(roFstInfo_ROTableUpdate);
Application.DoEvents();
FinalProgressBarMessage = "ROs values updated";
MyROFST = roFstInfo;
updatedROs = true;
}
}
//B2025-008
//in cases where a RO table is clicked on
//it will refresh the list
//temp store what the ROID was before the list refreshes
//so can go to it after the refresh
string tmpROID = CurROLink?.ROID;
ROFSTLookup.rodbi[] dbs = MyROFSTLookup?.GetRODatabaseList(true);
// B2022-123: RO Tab Treeview not showing correct RO values when switching between procedures. // B2022-123: RO Tab Treeview not showing correct RO values when switching between procedures.
// Added optional parameter "forceReload" and cleared out any existing nodes before reloading the tree // Added optional parameter "forceReload" and cleared out any existing nodes before reloading the tree
// the clear nodes code below has to be after the GetRODatabaseList database call because of races conditions in the code // the clear nodes code below has to be after the GetRODatabaseList database call because of races conditions in the code
tvROFST.Nodes.Clear(); tvROFST.Nodes.Clear();
ResetSearch(); //B2023-050 need to reset the SaveRO, and any RO info that was selected last time the tree was loaded ResetSearch(); //B2023-050 need to reset the SaveRO, and any RO info that was selected last time the tree was loaded
if (dbs != null) for (int i = 0; i < dbs.Length; i++)
{ {
for (int i = 0; i < dbs.Length; i++) ROFSTLookup.rodbi db = dbs[i];
{
ROFSTLookup.rodbi db = dbs[i];
TreeNode tn = new TreeNode(db.dbiTitle); TreeNode tn = new TreeNode(db.dbiTitle);
tn.Tag = db; tn.Tag = db;
tvROFST.Nodes.Add(tn); tvROFST.Nodes.Add(tn);
AddDummyGroup(db, tn); AddDummyGroup(db, tn);
} }
}
_currRofstID = (IsRofstValid) ? (int?)_myROFST.ROFstID : null; _currRofstID = (IsRofstValid) ? (int?)_myROFST.ROFstID : null;
_currDocVersionID = null; _currDocVersionID = null;
@@ -701,13 +621,7 @@ namespace Volian.Controls.Library
if(_docVersionInfo != null) _currDocVersionID = (int?)_docVersionInfo.VersionID; if(_docVersionInfo != null) _currDocVersionID = (int?)_docVersionInfo.VersionID;
if (tmpROID != null) ExpandNode(ROFSTLookup.FormatRoidKey(tmpROID, true)); if (tmpROID != null) ExpandNode(ROFSTLookup.FormatRoidKey(tmpROID, true));
}
//doc version would have updated (if needed) so reset flag
if (_progressBar?.Text != "Cannot check-out Working Draft")
{
changedDocVersion = false;
}
}
var unitInfoNode = tvROFST.Nodes.Cast<TreeNode>().Where(x => x.Text == "Unit Information").FirstOrDefault(); var unitInfoNode = tvROFST.Nodes.Cast<TreeNode>().Where(x => x.Text == "Unit Information").FirstOrDefault();
@@ -758,9 +672,7 @@ namespace Volian.Controls.Library
} }
_curROTypeFilter = _roTypeFilter; _curROTypeFilter = _roTypeFilter;
}
return updatedROs;
}
public void SetFindDocROButton(bool enabled) public void SetFindDocROButton(bool enabled)
{ {
@@ -887,18 +887,9 @@ namespace Volian.Controls.Library
Bar b = myTabItem.ContainerControl as Bar; Bar b = myTabItem.ContainerControl as Bar;
if (b != null) if (b != null)
{ {
try b.CloseDockTab(myTabItem);
{ //b.Items.Remove(myTabItem);
b.CloseDockTab(myTabItem); RemoveItem(myTabItem);
}
catch
{
//This is to work around a bug inside 3rd party DotNetBar
//The bug occurs when events happen out of order and it tries
//to remove a TabItem from the Collection the has already been removed
}
RemoveItem(myTabItem);
} }
} }
/// <summary> /// <summary>
+8 -32
View File
@@ -3556,10 +3556,7 @@ namespace Volian.Controls.Library
MyEditItem.SaveContents(); MyEditItem.SaveContents();
using (DocVersion dv = DocVersion.Get(Mydvi.VersionID)) using (DocVersion dv = DocVersion.Get(Mydvi.VersionID))
{ {
//must get id before ROFST gets updated so know what to refresh later swROUpdate = new System.IO.StreamWriter(ROFstInfo.ROUpdateResultsPath(Mydvi));
int origfstid = roFstInfo.ROFstID;
swROUpdate = new System.IO.StreamWriter(ROFstInfo.ROUpdateResultsPath(Mydvi));
// B2022-026 RO Memory Reduction code - first load the new ro.fst so that we can assign the ROTableUpdate event to the correct roFstInfo // B2022-026 RO Memory Reduction code - first load the new ro.fst so that we can assign the ROTableUpdate event to the correct roFstInfo
if (dv.ROfstLoadingFigures || dv.NewerRoFst) // B2017-125 see if loading figures was completed if (dv.ROfstLoadingFigures || dv.NewerRoFst) // B2017-125 see if loading figures was completed
{ {
@@ -3567,30 +3564,10 @@ namespace Volian.Controls.Library
ROFstInfo.UpdateRoFst(roFstInfo.MyRODb, dv, roFstInfo, DoProgressBarRefresh); ROFstInfo.UpdateRoFst(roFstInfo.MyRODb, dv, roFstInfo, DoProgressBarRefresh);
roFstInfo = Mydvi.DocVersionAssociations[0].MyROFst; roFstInfo = Mydvi.DocVersionAssociations[0].MyROFst;
} }
else if (!dv.ROfstLastCompleted && origfstid == roFstInfo.ROFstID)
{
//Handle issue where load failed without completing update
//previous RO FST did not load, get last loaded ID
//if none, use -1 which will check all ROs in the Working Draft
string cfg = dv.DocVersionAssociations[0].Config;
AssociationConfig ac = new AssociationConfig((cfg == null || cfg.Length == 0) ? "<Config />" : cfg);
if (dv.DocVersionAssociations[0]?.MyROFst != null)
{
if (!int.TryParse(ac.ROUpdate_PrevROFSTID, out origfstid))
{
origfstid = -1;
}
}
else
{
origfstid = -1;
}
}
roFstInfo.ROTableUpdate += new ROFstInfoROTableUpdateEvent(roFstInfo_ROTableUpdate); roFstInfo.ROTableUpdate += new ROFstInfoROTableUpdateEvent(roFstInfo_ROTableUpdate);
ContentInfo.StaticContentInfoChange += ContentInfo_StaticContentInfoChange; // write changes to a text file ContentInfo.StaticContentInfoChange += ContentInfo_StaticContentInfoChange; // write changes to a text file
ROFstInfo.RefreshROFstAtItemLevel(DocVersionInfo.Get(dv.VersionID), DoProgressBarRefresh, null, roFstInfo, origfstid, roFstInfo.ROFstID); ROFst newrofst = ROFstInfo.RefreshROFst(dv, roFstInfo, DoProgressBarRefresh, null);
swROUpdate.Close(); swROUpdate.Close();
ContentInfo.StaticContentInfoChange -= ContentInfo_StaticContentInfoChange; ContentInfo.StaticContentInfoChange -= ContentInfo_StaticContentInfoChange;
roFstInfo.ROTableUpdate -= new ROFstInfoROTableUpdateEvent(roFstInfo_ROTableUpdate); roFstInfo.ROTableUpdate -= new ROFstInfoROTableUpdateEvent(roFstInfo_ROTableUpdate);
StepPanelTabDisplayEventArgs args = new StepPanelTabDisplayEventArgs("DisplayROUpdateROFST"); StepPanelTabDisplayEventArgs args = new StepPanelTabDisplayEventArgs("DisplayROUpdateROFST");
@@ -3598,7 +3575,7 @@ namespace Volian.Controls.Library
} }
Cursor = Cursors.Default; Cursor = Cursors.Default;
FinalProgressBarMessage = "ROs values updated"; FinalProgressBarMessage = "ROs values updated";
} }
private System.IO.StreamWriter swROUpdate; private System.IO.StreamWriter swROUpdate;
// write the RO reference changes to a text file, include the old/new text, location, and the itemid of the step element // write the RO reference changes to a text file, include the old/new text, location, and the itemid of the step element
void ContentInfo_StaticContentInfoChange(object sender, StaticContentInfoEventArgs args) void ContentInfo_StaticContentInfoChange(object sender, StaticContentInfoEventArgs args)
@@ -3638,11 +3615,10 @@ namespace Volian.Controls.Library
set set
{ {
if (ProgressBar == null) return; if (ProgressBar == null) return;
ProgressBar.Value = 100;
ProgressBar.Text = value; ProgressBar.Maximum = 100;
ProgressBar.Maximum = 100; ProgressBar.Text = value;
ProgressBar.Value = 100; Application.DoEvents();
Application.DoEvents();
} }
} }
+8 -32
View File
@@ -2465,11 +2465,7 @@ namespace Volian.Controls.Library
} }
Cursor = Cursors.WaitCursor; // C2023-002: move wait cursor after check out error Cursor = Cursors.WaitCursor; // C2023-002: move wait cursor after check out error
int ownerid = MySessionInfo.CheckOutItem(MyDVI.VersionID, CheckOutType.DocVersion); int ownerid = MySessionInfo.CheckOutItem(MyDVI.VersionID, CheckOutType.DocVersion);
using (DocVersion dv = DocVersion.Get(MyDVI.VersionID))
//must get id before ROFST gets updated so know what to refresh later
int origfstid = roFstInfo.ROFstID;
using (DocVersion dv = DocVersion.Get(MyDVI.VersionID))
{ {
swROUpdate = new System.IO.StreamWriter(ROFstInfo.ROUpdateResultsPath(MyDVI)); // RO changes placed in file in the Documents\VEPROMS folder swROUpdate = new System.IO.StreamWriter(ROFstInfo.ROUpdateResultsPath(MyDVI)); // RO changes placed in file in the Documents\VEPROMS folder
// B2022-026 RO Memory Reduction code - first load the new ro.fst so that we can assign the ROTableUpdate event to the correct roFstInfo // B2022-026 RO Memory Reduction code - first load the new ro.fst so that we can assign the ROTableUpdate event to the correct roFstInfo
@@ -2479,30 +2475,10 @@ namespace Volian.Controls.Library
ROFstInfo.UpdateRoFst(roFstInfo.MyRODb, dv, roFstInfo, DoProgressBarRefresh); ROFstInfo.UpdateRoFst(roFstInfo.MyRODb, dv, roFstInfo, DoProgressBarRefresh);
roFstInfo = MyDVI.DocVersionAssociations[0].MyROFst; roFstInfo = MyDVI.DocVersionAssociations[0].MyROFst;
} }
else if (!dv.ROfstLastCompleted && origfstid == roFstInfo.ROFstID) roFstInfo.ROTableUpdate += new ROFstInfoROTableUpdateEvent(roFstInfo_ROTableUpdate);
{
//Handle issue where load failed without completing update
//previous RO FST did not load, get last loaded ID
//if none, use -1 which will check all ROs in the Working Draft
string cfg = dv.DocVersionAssociations[0].Config;
AssociationConfig ac = new AssociationConfig((cfg == null || cfg.Length == 0) ? "<Config />" : cfg);
if (dv.DocVersionAssociations[0]?.MyROFst != null)
{
if (!int.TryParse(ac.ROUpdate_PrevROFSTID, out origfstid))
{
origfstid = -1;
}
}
else
{
origfstid = -1;
}
}
roFstInfo.ROTableUpdate += new ROFstInfoROTableUpdateEvent(roFstInfo_ROTableUpdate);
ContentInfo.StaticContentInfoChange += ContentInfo_StaticContentInfoChange; // write changes to a text file ContentInfo.StaticContentInfoChange += ContentInfo_StaticContentInfoChange; // write changes to a text file
ROFstInfo.RefreshROFstAtItemLevel(DocVersionInfo.Get(dv.VersionID), DoProgressBarRefresh, null, roFstInfo, origfstid, roFstInfo.ROFstID); ROFst newrofst = ROFstInfo.RefreshROFst(dv, roFstInfo, DoProgressBarRefresh, null);
swROUpdate.Close(); swROUpdate.Close();
ContentInfo.StaticContentInfoChange -= ContentInfo_StaticContentInfoChange; ContentInfo.StaticContentInfoChange -= ContentInfo_StaticContentInfoChange;
roFstInfo.ROTableUpdate -= new ROFstInfoROTableUpdateEvent(roFstInfo_ROTableUpdate); roFstInfo.ROTableUpdate -= new ROFstInfoROTableUpdateEvent(roFstInfo_ROTableUpdate);
OnTabDisplay(this, new StepPanelTabDisplayEventArgs("DisplayROUpdateROFST")); OnTabDisplay(this, new StepPanelTabDisplayEventArgs("DisplayROUpdateROFST"));
@@ -2550,10 +2526,10 @@ namespace Volian.Controls.Library
set set
{ {
if (ProgressBar == null) return; if (ProgressBar == null) return;
ProgressBar.Text = value; ProgressBar.Value = 100;
ProgressBar.Maximum = 100; ProgressBar.Maximum = 100;
ProgressBar.Value = 100; ProgressBar.Text = value;
Application.DoEvents(); Application.DoEvents();
} }
} }
public List<string> roFstInfo_ROTableUpdate(object sender, ROFstInfoROTableUpdateEventArgs args) public List<string> roFstInfo_ROTableUpdate(object sender, ROFstInfoROTableUpdateEventArgs args)