Skip to content

Commit

Permalink
Merge pull request #1647 from GSA-TTS/ds-auditors-coversheet
Browse files Browse the repository at this point in the history
Add metadata, brief instructions, and UEI entry all workbooks' coversheets
  • Loading branch information
jadudm authored Aug 4, 2023
2 parents b7f12e5 + 1f2bf5e commit 6624aa0
Show file tree
Hide file tree
Showing 29 changed files with 6,929 additions and 6,129 deletions.
36 changes: 32 additions & 4 deletions backend/audit/test_validators.py
Original file line number Diff line number Diff line change
Expand Up @@ -634,7 +634,14 @@ def test_validation_is_applied(self):
template = json.loads(template_definition_path.read_text(encoding="utf-8"))
invalid = json.loads('{"CorrectiveActionPlan":{}}')
expected_msg = str(
("A", "2", "Auditee UEI", template["sheets"][1]["single_cells"][0]["help"])
[
(
"B",
"4",
"Auditee UEI",
template["sheets"][0]["single_cells"][2]["help"],
)
]
)
self.assertRaisesRegex(
ValidationError, expected_msg, validate_corrective_action_plan_json, invalid
Expand Down Expand Up @@ -683,7 +690,14 @@ def test_validation_is_applied(self):
template = json.loads(template_definition_path.read_text(encoding="utf-8"))
invalid = json.loads('{"AdditionalUEIs":{}}')
expected_msg = str(
("A", "2", "Auditee UEI", template["sheets"][1]["single_cells"][0]["help"])
[
(
"B",
"4",
"Auditee UEI",
template["sheets"][0]["single_cells"][2]["help"],
)
]
)
self.assertRaisesRegex(
ValidationError, expected_msg, validate_additional_ueis_json, invalid
Expand All @@ -707,7 +721,14 @@ def test_validation_is_applied(self):
template = json.loads(template_definition_path.read_text(encoding="utf-8"))
invalid = json.loads('{"NotesToSefa":{}}')
expected_msg = str(
("A", "2", "Auditee UEI", template["sheets"][2]["single_cells"][0]["help"])
[
(
"B",
"4",
"Auditee UEI",
template["sheets"][0]["single_cells"][2]["help"],
)
]
)
self.assertRaisesRegex(
ValidationError, expected_msg, validate_notes_to_sefa_json, invalid
Expand All @@ -731,7 +752,14 @@ def test_validation_is_applied(self):
template = json.loads(template_definition_path.read_text(encoding="utf-8"))
invalid = json.loads('{"SecondaryAuditors":{}}')
expected_msg = str(
("A", "2", "Auditee UEI", template["sheets"][1]["single_cells"][0]["help"])
[
(
"B",
"4",
"Auditee UEI",
template["sheets"][0]["single_cells"][2]["help"],
)
]
)
self.assertRaisesRegex(
ValidationError, expected_msg, validate_secondary_auditors_json, invalid
Expand Down
89 changes: 74 additions & 15 deletions backend/schemas/output/excel/json/additional-ueis-workbook.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,47 +2,106 @@
"filename": "additional-ueis-workbook.xlsx",
"sheets": [
{
"header_height": 48,
"hide_col_from": 2,
"name": "Form",
"open_ranges": [
"header_height": 60,
"hide_col_from": 3,
"meta_cells": [
{
"help": {
"link": "https://fac.gov/documentation/validation/#unknown",
"text": "If you see this error, please contact support."
},
"keep_locked": true,
"title": "Federal Audit Clearinghouse\nfac.gov",
"title_cell": "A1",
"type": "meta_cell"
},
{
"help": {
"link": "https://fac.gov/documentation/validation/#unknown",
"text": "If you see this error, please contact support."
},
"keep_locked": true,
"title": "This workbook contains two worksheets: a coversheet (this sheet) and a data entry sheet.\nBefore submitting, please make sure the fields below are filled out.",
"title_cell": "B1",
"type": "meta_cell",
"width": 48
}
],
"name": "Coversheet",
"single_cells": [
{
"format": "text",
"formula": "=\"1.0.0\"",
"help": {
"link": "https://fac.gov/documentation/validation/#plain_text",
"text": "Only plain text is allowed in this field, no emoji or other special additions"
},
"keep_locked": true,
"range_cell": "B2",
"range_name": "version",
"title": "Version",
"title_cell": "A2",
"type": "single_cell",
"validation": {
"type": "NOVALIDATION"
},
"width": 48
},
{
"format": "text",
"formula": "=\"AdditionalUeis\"",
"help": {
"link": "https://fac.gov/documentation/validation/#plain_text",
"text": "Only plain text is allowed in this field, no emoji or other special additions"
},
"keep_locked": true,
"range_cell": "B3",
"range_name": "section_name",
"title": "Section",
"title_cell": "A3",
"type": "single_cell",
"validation": {
"type": "NOVALIDATION"
},
"width": 48
},
{
"format": "text",
"help": {
"link": "https://fac.gov/documentation/validation/#uei",
"text": "UEIs are 12 characters long and match rules as given by SAM.gov"
},
"range_name": "additional_uei",
"title": "Additional UEIs",
"title_cell": "A1",
"type": "open_range",
"range_cell": "B4",
"range_name": "auditee_uei",
"title": "Auditee UEI:",
"title_cell": "A4",
"type": "single_cell",
"validation": {
"custom_error": "Expecting something with 12 characters",
"custom_title": "Must be length of 12",
"formula1": 12,
"operator": "equal",
"type": "textLength"
},
"width": 36
"width": 48
}
]
},
{
"header_height": 48,
"hide_col_from": 2,
"name": "Auditee UEI",
"single_cells": [
"name": "Form",
"open_ranges": [
{
"format": "text",
"help": {
"link": "https://fac.gov/documentation/validation/#uei",
"text": "UEIs are 12 characters long and match rules as given by SAM.gov"
},
"range_cell": "A2",
"range_name": "auditee_uei",
"title": "Auditee UEI",
"range_name": "additional_uei",
"title": "Additional UEIs",
"title_cell": "A1",
"type": "single_cell",
"type": "open_range",
"validation": {
"custom_error": "Expecting something with 12 characters",
"custom_title": "Must be length of 12",
Expand Down
113 changes: 86 additions & 27 deletions backend/schemas/output/excel/json/audit-findings-text-workbook.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,92 @@
{
"filename": "audit-findings-text-workbook.xlsx",
"sheets": [
{
"header_height": 60,
"hide_col_from": 3,
"meta_cells": [
{
"help": {
"link": "https://fac.gov/documentation/validation/#unknown",
"text": "If you see this error, please contact support."
},
"keep_locked": true,
"title": "Federal Audit Clearinghouse\nfac.gov",
"title_cell": "A1",
"type": "meta_cell"
},
{
"help": {
"link": "https://fac.gov/documentation/validation/#unknown",
"text": "If you see this error, please contact support."
},
"keep_locked": true,
"title": "This workbook contains two worksheets: a coversheet (this sheet) and a data entry sheet.\nBefore submitting, please make sure the fields below are filled out.",
"title_cell": "B1",
"type": "meta_cell",
"width": 48
}
],
"name": "Coversheet",
"single_cells": [
{
"format": "text",
"formula": "=\"1.0.0\"",
"help": {
"link": "https://fac.gov/documentation/validation/#plain_text",
"text": "Only plain text is allowed in this field, no emoji or other special additions"
},
"keep_locked": true,
"range_cell": "B2",
"range_name": "version",
"title": "Version",
"title_cell": "A2",
"type": "single_cell",
"validation": {
"type": "NOVALIDATION"
},
"width": 48
},
{
"format": "text",
"formula": "=\"FindingsText\"",
"help": {
"link": "https://fac.gov/documentation/validation/#plain_text",
"text": "Only plain text is allowed in this field, no emoji or other special additions"
},
"keep_locked": true,
"range_cell": "B3",
"range_name": "section_name",
"title": "Section",
"title_cell": "A3",
"type": "single_cell",
"validation": {
"type": "NOVALIDATION"
},
"width": 48
},
{
"format": "text",
"help": {
"link": "https://fac.gov/documentation/validation/#uei",
"text": "UEIs are 12 characters long and match rules as given by SAM.gov"
},
"range_cell": "B4",
"range_name": "auditee_uei",
"title": "Auditee UEI:",
"title_cell": "A4",
"type": "single_cell",
"validation": {
"custom_error": "Expecting something with 12 characters",
"custom_title": "Must be length of 12",
"formula1": 12,
"operator": "equal",
"type": "textLength"
},
"width": 48
}
]
},
{
"header_height": 48,
"hide_col_from": 4,
Expand Down Expand Up @@ -56,33 +142,6 @@
"width": 36
}
]
},
{
"header_height": 48,
"hide_col_from": 2,
"name": "UEI",
"single_cells": [
{
"format": "text",
"help": {
"link": "https://fac.gov/documentation/validation/#uei",
"text": "UEIs are 12 characters long and match rules as given by SAM.gov"
},
"range_cell": "A2",
"range_name": "auditee_uei",
"title": "Auditee UEI",
"title_cell": "A1",
"type": "single_cell",
"validation": {
"custom_error": "Expecting something with 12 characters",
"custom_title": "Must be length of 12",
"formula1": 12,
"operator": "equal",
"type": "textLength"
},
"width": 36
}
]
}
],
"title_row": 1
Expand Down
Loading

0 comments on commit 6624aa0

Please sign in to comment.