Merge pull request #9 from Aurorastation/dev

Adds postmortem, fixes tab indexing, and bumps to 2.2.*
This commit is contained in:
Llywelwyn 2023-04-27 21:02:08 +01:00 committed by GitHub
commit ed4e156f18
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 40 additions and 36 deletions

View file

@ -50,5 +50,5 @@ using System.Windows;
// You can specify all the values or you can default the Build and Revision Numbers // You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below: // by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")] // [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("2.1.*")] [assembly: AssemblyVersion("2.2.*")]
[assembly: AssemblyFileVersion("1.1.0.0")] [assembly: AssemblyFileVersion("1.1.0.0")]

View file

@ -62,7 +62,8 @@ namespace CharacterRecordsGenerator
[ProtoMember(18)] [ProtoMember(18)]
public string NextOfKin { get; set; } = string.Empty; public string NextOfKin { get; set; } = string.Empty;
// 19 was used for MedicalPublicRecord, now empty [ProtoMember(19)]
public string MedicalPostmortem { get; set; } = string.Empty;
[ProtoMember(20)] [ProtoMember(20)]
public string MedicalAllergies { get; set; } = string.Empty; public string MedicalAllergies { get; set; } = string.Empty;

View file

@ -324,61 +324,69 @@
<TextBlock Grid.Row="0" Grid.ColumnSpan="2" HorizontalAlignment="Stretch" FontWeight="DemiBold" <TextBlock Grid.Row="0" Grid.ColumnSpan="2" HorizontalAlignment="Stretch" FontWeight="DemiBold"
VerticalAlignment="Top" Margin="5,5,5,0" Text="Opt-outs"/> VerticalAlignment="Top" Margin="5,5,5,0" Text="Opt-outs"/>
<TextBlock Grid.Row="1" Grid.ColumnSpan="2" HorizontalAlignment="Stretch" FontWeight="DemiBold" <TextBlock Grid.Row="1" Grid.ColumnSpan="2" HorizontalAlignment="Stretch" FontWeight="DemiBold"
VerticalAlignment="Top" Margin="5,5,5,0" Text="Allergies"/> VerticalAlignment="Top" Margin="5,5,5,0" Text="Postmortem Instructions"/>
<TextBlock Grid.Row="2" Grid.ColumnSpan="2" HorizontalAlignment="Stretch" FontWeight="DemiBold" <TextBlock Grid.Row="2" Grid.ColumnSpan="2" HorizontalAlignment="Stretch" FontWeight="DemiBold"
VerticalAlignment="Top" Margin="5,5,5,0" Text="Current Medications/Prescriptions"/> VerticalAlignment="Top" Margin="5,5,5,0" Text="Allergies"/>
<TextBlock Grid.Row="3" Grid.ColumnSpan="2" HorizontalAlignment="Stretch" FontWeight="DemiBold" <TextBlock Grid.Row="3" Grid.ColumnSpan="2" HorizontalAlignment="Stretch" FontWeight="DemiBold"
VerticalAlignment="Top" Margin="5,5,5,0" Text="Medication History"/> VerticalAlignment="Top" Margin="5,5,5,0" Text="Current Medications/Prescriptions"/>
<TextBlock Grid.Row="4" Grid.ColumnSpan="2" HorizontalAlignment="Stretch" FontWeight="DemiBold" <TextBlock Grid.Row="4" Grid.ColumnSpan="2" HorizontalAlignment="Stretch" FontWeight="DemiBold"
VerticalAlignment="Top" Margin="5,5,5,0" Text="Surgical History"/> VerticalAlignment="Top" Margin="5,5,5,0" Text="Medication History"/>
<TextBlock Grid.Row="5" Grid.ColumnSpan="2" HorizontalAlignment="Stretch" FontWeight="DemiBold" <TextBlock Grid.Row="5" Grid.ColumnSpan="2" HorizontalAlignment="Stretch" FontWeight="DemiBold"
VerticalAlignment="Top" Margin="5,5,5,0" Text="Physical Evaluations"/> VerticalAlignment="Top" Margin="5,5,5,0" Text="Surgical History"/>
<TextBlock Grid.Row="6" Grid.ColumnSpan="2" HorizontalAlignment="Stretch" FontWeight="DemiBold" <TextBlock Grid.Row="6" Grid.ColumnSpan="2" HorizontalAlignment="Stretch" FontWeight="DemiBold"
VerticalAlignment="Top" Margin="5,5,5,0" Text="Documented Psychological Disorders"/> VerticalAlignment="Top" Margin="5,5,5,0" Text="Physical Evaluations"/>
<TextBlock Grid.Row="7" Grid.ColumnSpan="2" HorizontalAlignment="Stretch" FontWeight="DemiBold" <TextBlock Grid.Row="7" Grid.ColumnSpan="2" HorizontalAlignment="Stretch" FontWeight="DemiBold"
VerticalAlignment="Top" Margin="5,5,5,0" Text="Documented Psychological Disorders"/>
<TextBlock Grid.Row="8" Grid.ColumnSpan="2" HorizontalAlignment="Stretch" FontWeight="DemiBold"
VerticalAlignment="Top" Margin="5,5,5,0" Text="Psychological Evaluations"/> VerticalAlignment="Top" Margin="5,5,5,0" Text="Psychological Evaluations"/>
<TextBox Margin="0,21,0,10" AcceptsReturn="True"
TextWrapping="Wrap" controls:TextBoxHelper.Watermark="e.g.&#x0a;Cremate and return remains to next of kin, located on Xanu Prime."
controls:TextBoxHelper.IsSpellCheckContextMenuEnabled="True"
VerticalScrollBarVisibility="Auto"
ToolTip="Instructions to execute upon death." Grid.Row="1"
Text="{Binding Path=MedicalPostmortem}" TabIndex="4" Grid.ColumnSpan="2" />
<TextBox Margin="0,21,0,10" AcceptsReturn="True" TextWrapping="Wrap" <TextBox Margin="0,21,0,10" AcceptsReturn="True" TextWrapping="Wrap"
controls:TextBoxHelper.Watermark="e.g.&#x0a;Peanuts (severe)&#x0a;Latex (minor irritation)" controls:TextBoxHelper.Watermark="e.g.&#x0a;Peanuts (severe)&#x0a;Latex (minor irritation)"
controls:TextBoxHelper.IsSpellCheckContextMenuEnabled="True" controls:TextBoxHelper.IsSpellCheckContextMenuEnabled="True"
VerticalScrollBarVisibility="Auto" VerticalScrollBarVisibility="Auto"
ToolTip="List of allergies. One per line." ToolTip="List of allergies. One per line."
Grid.Row="1" Text="{Binding Path=MedicalAllergies}" TabIndex="6" Grid.ColumnSpan="2" /> Grid.Row="2" Text="{Binding Path=MedicalAllergies}" TabIndex="5" Grid.ColumnSpan="2" />
<TextBox Margin="0,21,0,10" AcceptsReturn="True" TextWrapping="Wrap" <TextBox Margin="0,21,0,10" AcceptsReturn="True" TextWrapping="Wrap"
controls:TextBoxHelper.Watermark="e.g.&#x0a;2x 5u Perconol (daily) for back pain." controls:TextBoxHelper.Watermark="e.g.&#x0a;2x 5u Perconol (daily) for back pain."
controls:TextBoxHelper.IsSpellCheckContextMenuEnabled="True" controls:TextBoxHelper.IsSpellCheckContextMenuEnabled="True"
VerticalScrollBarVisibility="Auto" VerticalScrollBarVisibility="Auto"
ToolTip="Current prescriptions, etc. One per line." Grid.Row="2" ToolTip="Current prescriptions, etc. One per line." Grid.Row="3"
Text="{Binding Path=MedicalCurrentPrescriptions}" TabIndex="7" Grid.ColumnSpan="2" /> Text="{Binding Path=MedicalCurrentPrescriptions}" TabIndex="6" Grid.ColumnSpan="2" />
<TextBox Margin="0,21,0,10" AcceptsReturn="True" <TextBox Margin="0,21,0,10" AcceptsReturn="True"
TextWrapping="Wrap" controls:TextBoxHelper.Watermark="e.g.&#x0a;[12/07/2462 - 12/08/2462] 5u Hyperzine (daily) for heart injury.&#x0a;[14/09/2463 - 16/09/2463] 30u Nightlife (daily) prescribed for a weekend party." TextWrapping="Wrap" controls:TextBoxHelper.Watermark="e.g.&#x0a;[12/07/2462 - 12/08/2462] 5u Hyperzine (daily) for heart injury.&#x0a;[14/09/2463 - 16/09/2463] 30u Nightlife (daily) prescribed for a weekend party."
controls:TextBoxHelper.IsSpellCheckContextMenuEnabled="True" controls:TextBoxHelper.IsSpellCheckContextMenuEnabled="True"
VerticalScrollBarVisibility="Auto" VerticalScrollBarVisibility="Auto"
ToolTip="Dated records of medical history. One per line." Grid.Row="3" ToolTip="Dated records of medical history. One per line." Grid.Row="4"
Text="{Binding Path=MedicalHistory}" TabIndex="8" Grid.ColumnSpan="2" /> Text="{Binding Path=MedicalHistory}" TabIndex="7" Grid.ColumnSpan="2" />
<TextBox Margin="0,21,0,10" AcceptsReturn="True" <TextBox Margin="0,21,0,10" AcceptsReturn="True"
TextWrapping="Wrap" controls:TextBoxHelper.Watermark="e.g.&#x0a;[09/04/2460] Triple coronary artery bypass" TextWrapping="Wrap" controls:TextBoxHelper.Watermark="e.g.&#x0a;[09/04/2460] Triple coronary artery bypass"
controls:TextBoxHelper.IsSpellCheckContextMenuEnabled="True" controls:TextBoxHelper.IsSpellCheckContextMenuEnabled="True"
VerticalScrollBarVisibility="Auto" VerticalScrollBarVisibility="Auto"
ToolTip="Dated records of surgical history. One per line." Grid.Row="4" ToolTip="Dated records of surgical history. One per line." Grid.Row="5"
Text="{Binding Path=MedicalSurgicalHistory}" TabIndex="9" Grid.ColumnSpan="2" /> Text="{Binding Path=MedicalSurgicalHistory}" TabIndex="8" Grid.ColumnSpan="2" />
<TextBox Margin="0,21,0,10" AcceptsReturn="True" <TextBox Margin="0,21,0,10" AcceptsReturn="True"
TextWrapping="Wrap" controls:TextBoxHelper.Watermark="e.g.&#x0a;[30/03/2458] Passed - Fully able for work.&#x0a;[29/03/2459] Passed - Fully able for work." TextWrapping="Wrap" controls:TextBoxHelper.Watermark="e.g.&#x0a;[30/03/2458] Passed - Fully able for work.&#x0a;[29/03/2459] Passed - Fully able for work."
controls:TextBoxHelper.IsSpellCheckContextMenuEnabled="True" controls:TextBoxHelper.IsSpellCheckContextMenuEnabled="True"
VerticalScrollBarVisibility="Auto" VerticalScrollBarVisibility="Auto"
ToolTip="Dated records of physical evaluations. One per line." Grid.Row="5" ToolTip="Dated records of physical evaluations. One per line." Grid.Row="6"
Text="{Binding Path=MedicalPhysicalEvaluations}" TabIndex="10" Grid.ColumnSpan="2" /> Text="{Binding Path=MedicalPhysicalEvaluations}" TabIndex="9" Grid.ColumnSpan="2" />
<TextBox Margin="0,21,0,10" AcceptsReturn="True" <TextBox Margin="0,21,0,10" AcceptsReturn="True"
TextWrapping="Wrap" controls:TextBoxHelper.Watermark="e.g.&#x0a;Obsessive-compulsive disorder" TextWrapping="Wrap" controls:TextBoxHelper.Watermark="e.g.&#x0a;Obsessive-compulsive disorder"
controls:TextBoxHelper.IsSpellCheckContextMenuEnabled="True" controls:TextBoxHelper.IsSpellCheckContextMenuEnabled="True"
VerticalScrollBarVisibility="Auto" VerticalScrollBarVisibility="Auto"
ToolTip="Any documented psychological disorders. One per line." Grid.Row="6" ToolTip="Any documented psychological disorders. One per line." Grid.Row="7"
Text="{Binding Path=MedicalPsychDisorders}" TabIndex="10" Grid.ColumnSpan="2" /> Text="{Binding Path=MedicalPsychDisorders}" TabIndex="10" Grid.ColumnSpan="2" />
<TextBox Margin="0,21,0,10" AcceptsReturn="True" <TextBox Margin="0,21,0,10" AcceptsReturn="True"
TextWrapping="Wrap" controls:TextBoxHelper.Watermark="e.g.&#x0a;[04/02/2459] Passed - John Doe is an example of excellent mental health." TextWrapping="Wrap" controls:TextBoxHelper.Watermark="e.g.&#x0a;[04/02/2459] Passed - John Doe is an example of excellent mental health."
controls:TextBoxHelper.IsSpellCheckContextMenuEnabled="True" controls:TextBoxHelper.IsSpellCheckContextMenuEnabled="True"
VerticalScrollBarVisibility="Auto" VerticalScrollBarVisibility="Auto"
ToolTip="Dated records of psychological evaluations. One per line." Grid.Row="7" ToolTip="Dated records of psychological evaluations. One per line." Grid.Row="8"
Text="{Binding Path=MedicalPsychEvaluations}" TabIndex="10" Grid.ColumnSpan="2" /> Text="{Binding Path=MedicalPsychEvaluations}" TabIndex="11" Grid.ColumnSpan="2" />
</Grid> </Grid>
</ScrollViewer> </ScrollViewer>
</TabItem> </TabItem>

View file

@ -17,6 +17,7 @@ namespace CharacterRecordsGenerator
private IList<string> _publicNotes; private IList<string> _publicNotes;
private IList<string> _MedicalPostmortem;
private IList<string> _MedicalAllergies; private IList<string> _MedicalAllergies;
private IList<string> _MedicalCurrentPrescriptions; private IList<string> _MedicalCurrentPrescriptions;
private IList<string> _MedicalHistory; private IList<string> _MedicalHistory;
@ -43,6 +44,7 @@ namespace CharacterRecordsGenerator
_publicNotes = _targetRecord.PublicNotes?.LineSplit(); _publicNotes = _targetRecord.PublicNotes?.LineSplit();
// Medical // Medical
_MedicalPostmortem = _targetRecord.MedicalPostmortem?.LineSplit();
_MedicalAllergies = _targetRecord.MedicalAllergies?.LineSplit(); _MedicalAllergies = _targetRecord.MedicalAllergies?.LineSplit();
_MedicalCurrentPrescriptions = _targetRecord.MedicalCurrentPrescriptions?.LineSplit(); _MedicalCurrentPrescriptions = _targetRecord.MedicalCurrentPrescriptions?.LineSplit();
_MedicalHistory = _targetRecord.MedicalHistory?.LineSplit(); _MedicalHistory = _targetRecord.MedicalHistory?.LineSplit();

View file

@ -146,6 +146,7 @@ namespace CharacterRecordsGenerator
!_MedicalPhysicalEvaluations.Any() && !_MedicalPhysicalEvaluations.Any() &&
!_MedicalPsychEvaluations.Any() && !_MedicalPsychEvaluations.Any() &&
!_MedicalPsychDisorders.Any() && !_MedicalPsychDisorders.Any() &&
!_MedicalPostmortem.Any() &&
!_targetRecord.NoBorg && !_targetRecord.NoBorg &&
!_targetRecord.NoProsthetic && !_targetRecord.NoProsthetic &&
!_targetRecord.NoRevive) !_targetRecord.NoRevive)
@ -161,44 +162,39 @@ namespace CharacterRecordsGenerator
if (_targetRecord.NoBorg || _targetRecord.NoProsthetic || _targetRecord.NoRevive) if (_targetRecord.NoBorg || _targetRecord.NoProsthetic || _targetRecord.NoRevive)
{ {
recordText.AppendLine("IMPORTANT NOTES:"); recordText.AppendLine("OPT-OUTS:");
if (_targetRecord.NoBorg) if (_targetRecord.NoBorg)
MakeMedicalNote(ref recordText, "DO NOT BORGIFY"); MakeMedicalNote(ref recordText, "DO NOT BORGIFY");
if (_targetRecord.NoProsthetic) if (_targetRecord.NoProsthetic)
MakeMedicalNote(ref recordText, "DO NOT INSTALL PROSTHETICS"); MakeMedicalNote(ref recordText, "DO NOT INSTALL PROSTHETICS");
if (_targetRecord.NoRevive) if (_targetRecord.NoRevive)
MakeMedicalNote(ref recordText, "DO NOT REVIVE"); MakeMedicalNote(ref recordText, "DO NOT REVIVE");
recordText.AppendLine(); recordText.AppendLine();
} }
WriteSectionIfAny(ref recordText,
"POSTMORTEM INSTRUCTIONS:",
_MedicalPostmortem);
WriteSectionIfAny(ref recordText,
"ALLERGIES:",
_MedicalAllergies);
WriteSectionIfAny(ref recordText, WriteSectionIfAny(ref recordText,
"Current Prescriptions:", "Current Prescriptions:",
_MedicalCurrentPrescriptions); _MedicalCurrentPrescriptions);
WriteSectionIfAny(ref recordText,
"Allergies:",
_MedicalAllergies);
WriteSectionIfAny(ref recordText, WriteSectionIfAny(ref recordText,
"Surgical History:", "Surgical History:",
_MedicalSurgicalHistory); _MedicalSurgicalHistory);
WriteSectionIfAny(ref recordText, WriteSectionIfAny(ref recordText,
"Medication History:", "Medication History:",
_MedicalHistory); _MedicalHistory);
WriteSectionIfAny(ref recordText, WriteSectionIfAny(ref recordText,
"Physical Evaluations:", "Physical Evaluations:",
_MedicalPhysicalEvaluations); _MedicalPhysicalEvaluations);
WriteSectionIfAny(ref recordText, WriteSectionIfAny(ref recordText,
"Documented Psychological Disorders:", "Documented Psychological Disorders:",
_MedicalPsychDisorders); _MedicalPsychDisorders);
WriteSectionIfAny(ref recordText, WriteSectionIfAny(ref recordText,
"Psychological Evaluations:", "Psychological Evaluations:",
_MedicalPsychEvaluations); _MedicalPsychEvaluations);
@ -234,15 +230,12 @@ namespace CharacterRecordsGenerator
WriteSectionIfAny(ref recordText, WriteSectionIfAny(ref recordText,
"Attitude Towards the SCC:", "Attitude Towards the SCC:",
_securityAttitudeScc); _securityAttitudeScc);
WriteSectionIfAny(ref recordText, WriteSectionIfAny(ref recordText,
"Attitude Towards the Crew:", "Attitude Towards the Crew:",
_securityAttitudeCrew); _securityAttitudeCrew);
WriteSectionIfAny(ref recordText, WriteSectionIfAny(ref recordText,
"Notes:", "Notes:",
_securityNotes); _securityNotes);
WriteSectionIfAny(ref recordText, WriteSectionIfAny(ref recordText,
"Record:", "Record:",
_securityRecords); _securityRecords);