Skip to content

Commit

Permalink
Revert "Swapped EPT position of increase/decrease factors (#744)" (#773)
Browse files Browse the repository at this point in the history
* Revert "Swapped EPT position of increase/decrease factors (#744)"

* Removed unused stylesheet

---------

Co-authored-by: Daniel Rabstejnek <rabstejnek@gmail.com>
  • Loading branch information
shapiromatron and rabstejnek authored Jan 30, 2023
1 parent db335cd commit 88fb85c
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 31 deletions.
20 changes: 10 additions & 10 deletions frontend/summary/summaryTable/evidenceProfileTable/EvidenceForm.js
Original file line number Diff line number Diff line change
Expand Up @@ -69,17 +69,17 @@ const EvidenceForm = observer(props => {
/>
</th>
<th>
Factors that decrease certainty
Factors that increase certainty
<HelpTextPopup
title="Help-text"
content={`${HELP_TEXT.IRIS_HANDBOOK} For entries with a free text option, summarize the evidence supporting the selected factor(s) in a few words (required). Note any other factors that decreased certainty`}
content={`${HELP_TEXT.IRIS_HANDBOOK} For entries with a free text option, summarize the evidence supporting the selected factor(s) in a few words (required). Note any other factors that increased certainty`}
/>
</th>
<th>
Factors that increase certainty
Factors that decrease certainty
<HelpTextPopup
title="Help-text"
content={`${HELP_TEXT.IRIS_HANDBOOK} For entries with a free text option, summarize the evidence supporting the selected factor(s) in a few words (required). Note any other factors that increased certainty`}
content={`${HELP_TEXT.IRIS_HANDBOOK} For entries with a free text option, summarize the evidence supporting the selected factor(s) in a few words (required). Note any other factors that decreased certainty`}
/>
</th>
<th>
Expand Down Expand Up @@ -159,17 +159,17 @@ const EvidenceForm = observer(props => {
<td>
<FactorsForm
store={store}
updateKey={`${contentType}.rows[${index}].uncertain_factors`}
content={row.uncertain_factors}
isIncreasing={false}
updateKey={`${contentType}.rows[${index}].certain_factors`}
content={row.certain_factors}
isIncreasing={true}
/>
</td>
<td>
<FactorsForm
store={store}
updateKey={`${contentType}.rows[${index}].certain_factors`}
content={row.certain_factors}
isIncreasing={true}
updateKey={`${contentType}.rows[${index}].uncertain_factors`}
content={row.uncertain_factors}
isIncreasing={false}
/>
</td>
<td>
Expand Down
4 changes: 2 additions & 2 deletions frontend/summary/summaryTable/evidenceProfileTable/Table.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ const subTitleStyle = {backgroundColor: "#f5f5f5"},
<td>
<div dangerouslySetInnerHTML={{__html: row.summary.findings}}></div>
</td>
<FactorsCell content={row.uncertain_factors} isIncreasing={false} />
<FactorsCell content={row.certain_factors} isIncreasing={true} />
<FactorsCell content={row.uncertain_factors} isIncreasing={false} />
{index == 0 || rowSpan == 1 ? (
<td rowSpan={rowSpan > 1 ? rowSpan : null}>
<Judgement
Expand Down Expand Up @@ -273,8 +273,8 @@ class Table extends Component {
<tr>
<th>Studies</th>
<th>Summary of key findings</th>
<th>Factors that decrease certainty</th>
<th>Factors that increase certainty</th>
<th>Factors that decrease certainty</th>
<th>Evidence Synthesis Judgment(s)</th>
{summary_judgement.hide_content ? null : <SummaryCell store={store} />}
</tr>
Expand Down
14 changes: 0 additions & 14 deletions hawc/static/css/pagedown.css

This file was deleted.

10 changes: 5 additions & 5 deletions hawc/tools/tables/ept.py
Original file line number Diff line number Diff line change
Expand Up @@ -234,15 +234,15 @@ def to_docx(self, parser: QuillParser, block):


class CertainFactorsCell(FactorsCell):
column: int = 3
column: int = 2

@property
def factor_types(self):
return CERTAIN_FACTORS


class UncertainFactorsCell(FactorsCell):
column: int = 2
column: int = 3

@property
def factor_types(self):
Expand Down Expand Up @@ -326,8 +326,8 @@ def _set_cells(self):
self.cells = [
self.evidence,
self.summary,
self.uncertain_factors,
self.certain_factors,
self.uncertain_factors,
self.judgement,
]

Expand Down Expand Up @@ -438,10 +438,10 @@ def column_headers(self):
True, 1, 1, 1, 1, tag_wrapper("Summary of key findings", "p", "strong")
),
GenericCell.parse_args(
True, 1, 2, 1, 1, tag_wrapper("Factors that decrease certainty", "p", "strong")
True, 1, 2, 1, 1, tag_wrapper("Factors that increase certainty", "p", "strong")
),
GenericCell.parse_args(
True, 1, 3, 1, 1, tag_wrapper("Factors that increase certainty", "p", "strong")
True, 1, 3, 1, 1, tag_wrapper("Factors that decrease certainty", "p", "strong")
),
GenericCell.parse_args(
True, 1, 4, 1, 1, tag_wrapper("Evidence Synthesis Judgment(s)", "p", "strong")
Expand Down

0 comments on commit 88fb85c

Please sign in to comment.