Merged PR 11840: Added MFS logic to ensure notes data cannot be removed.
Added MFS logic to ensure notes data cannot be removed. Related work items: #231781
This commit is contained in:
parent
15495aa7ef
commit
6fd0d30717
@ -51,7 +51,7 @@ EQU COL$ITEM_ID TO 7
|
||||
EQU COL$ITEM_RI_NO TO 8
|
||||
|
||||
Declare subroutine Post_Event, Database_Services
|
||||
Declare function Datetime, SRP_String
|
||||
Declare function Datetime, SRP_String, Database_Services
|
||||
|
||||
// Update the arguments so that the OpenInsight OLE event will treate the ActiveX event as a native event handler.
|
||||
If Event EQ 'OLE' then
|
||||
@ -79,9 +79,9 @@ Return EventFlow or 1
|
||||
Event WINDOW.CREATE(CreateParam)
|
||||
|
||||
GoSub SetupOLEControls
|
||||
* IOOptions = Get_Property(@Window, 'IOOPTIONS')
|
||||
* IOOptions<6> = True$ ; // Don't clear on write
|
||||
* Set_Property(@Window, 'IOOPTIONS', IOOptions)
|
||||
IOOptions = Get_Property(@Window, 'IOOPTIONS')
|
||||
IOOptions<6> = True$ ; // Don't clear on write
|
||||
Set_Property(@Window, 'IOOPTIONS', IOOptions)
|
||||
|
||||
end event
|
||||
|
||||
@ -98,6 +98,10 @@ Event WINDOW.WRITE()
|
||||
GoSub UpdateNotes
|
||||
QBF = Get_Property(@Window, "QBFSTATUS")
|
||||
If QBF EQ False$ then Set_Property(@Window:'.OLE_EDT_NOTES', 'OLE.ARRAY', '')
|
||||
|
||||
IOOptions = Get_Property(@Window, 'IOOPTIONS')
|
||||
IOOptions<6> = True$
|
||||
Set_Property(@Window, 'IOOPTIONS', IOOptions)
|
||||
|
||||
end event
|
||||
|
||||
@ -220,7 +224,8 @@ return
|
||||
|
||||
FillForm:
|
||||
|
||||
AtRecord = Get_Property(@Window, 'ATRECORD')
|
||||
RLNo = Get_Property(@Window:'.REACTOR_LOG_NO', 'TEXT')
|
||||
AtRecord = Database_Services('ReadDataRow', 'REACTOR_LOG', RLNo)
|
||||
Notes = AtRecord<REACTOR_LOG_NOTES$>
|
||||
// OI 10 seems to messing up delimiters...
|
||||
Convert @TM to @VM in Notes
|
||||
@ -270,8 +275,9 @@ UpdateNotes:
|
||||
AtRecord<REACTOR_LOG_NOTES$> = Notes
|
||||
AtRecord<REACTOR_LOG_NOTES_DTMS$> = IConv(NotesDTMs, 'DT')
|
||||
AtRecord<REACTOR_LOG_NOTES_USERS$> = Get_Property(@Window, '@NOTES_USERNAMES')
|
||||
Set_Property(@Window, 'ATRECORD', AtRecord)
|
||||
@Record = AtRecord
|
||||
Database_Services('WriteDataRow', 'REACTOR_LOG', @ID, AtRecord, True$)
|
||||
|
||||
return
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user