-
Notifications
You must be signed in to change notification settings - Fork 2
Add competence profile Word version #107
base: develop
Are you sure you want to change the base?
Conversation
foreach (var skill in HboIDomain.ProfessionalSkills) | ||
{ | ||
var value = skills.First(x => x.skillId == skill.Id); | ||
var cell = CreateTableCellWithBorders("500"); | ||
cell.FirstChild?.Append(new Shading | ||
{ Fill = value.maxMastery.Color, }); | ||
cell.Append(new Paragraph(new Run(new Text($"{value.count}")))); | ||
valueRow.AppendChild(cell); | ||
} |
Check notice
Code scanning / CodeQL
Missed opportunity to use Select
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is indeed something that can be used
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are some visual changes that need to change.
Could you povide a screenshot of the Word output? |
body.Append(new Paragraph(new Run(new Text("")))); | ||
body.AppendChild(GetTasks()); | ||
body.Append(new Paragraph(new Run(new Text("")))); | ||
body.AppendChild(GetSkills()); | ||
body.Append(new Paragraph(new Run(new Text("")))); | ||
body.AppendChild(GetLegend()); | ||
body.Append(new Paragraph(new Run(new Text("")))); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are these body.Append(new Paragraph(new Run(new Text(""))));
nessecary. It seems kind of bloated.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If these are not included, all the tables will merge together, will be automatically fixed with the refactor
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you atleast replace it with something like a line break?
var headerRow = new TableRow(); | ||
|
||
// Empty top-left cell. | ||
headerRow.AppendChild(CreateTableCellWithBorders("2500", new Paragraph(new Run(new Text(""))))); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you specify what these values are "2500
" (maybe make a constant)? Same here with the paragraph stuff.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
idk what these values are, still need to figure out what they do
// Set table properties for formatting. | ||
table.AppendChild(new TableProperties( | ||
new TableWidth { | ||
Width = "4", Type = TableWidthUnitValues.Auto, })); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Expand these to make the code look nices
The level legend should be under the tables and the "mastered, insufficient, etc." legend can be removed as it is not part of this component. Unless you added it to your screenshot on accident? |
I'm pretty much done here, ill keep implementing more stuff unless someone stops me but yeah