From 3e0a0a3ce6184a32a118f91c7a4ae0296e797aec Mon Sep 17 00:00:00 2001 From: Luthando Date: Wed, 26 Apr 2023 16:36:48 +0200 Subject: [PATCH 001/126] Official green coa branch --- src/bika/coa/reports/Multigreen.pt | 674 +++++++++++++++++++++++++++++ src/bika/coa/reportview.py | 57 +++ 2 files changed, 731 insertions(+) create mode 100644 src/bika/coa/reports/Multigreen.pt diff --git a/src/bika/coa/reports/Multigreen.pt b/src/bika/coa/reports/Multigreen.pt new file mode 100644 index 0000000..a48f29d --- /dev/null +++ b/src/bika/coa/reports/Multigreen.pt @@ -0,0 +1,674 @@ + + + +
+
Custom Report Options
+ +
+
+
+ +
+ +
+ + Number of attachments rendered within one row per Analysis Request + +
+
+ + + + + + + + + +
+

Please make sure all Samples are on the same batch

+
+
+ + + + +
+ +
+ +

+
+
+ + +
+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + +
+

Certificate of Analysis

+
+

+

+

Batch

+
+

+

+

+

+ +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Container +
+
Sample Type +
+
Date Received +
+
Date Sampled +
+
AnalyzedFrom +
+
To +
+
Batch Remarks +
+
+
+ + + + +
+
+

Results

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Sample ID +
+
+
Client Sample ID
+
Sample Type
+
Sample Condition
+
Date Sampled
+
Date Received
+
Date Verified
+
+
+
+
+
+
+
+
+ + MethodUnitResult
+ + + + + + + + + + + + + + + + + + - + + + + + + + +
+
+
+
+
+
+ + + + + + +

Legend

+ + + + + + + + + + + + + +
+ + + Accredited methods +
+ ^ + + South African Veterinary Council registered +
+ + + Subcontracted methods +
+
+ + + + +

Additional Information

+ + + +
+
+
+ + + + + +
+

+
+ + +
+
+
+
+ + + + + + + + + + + +
+

Publisher

+
+

+

+

Date Time Published

+
+

+

+
+ + + + +

Authorised by

+

Pending response

+
+ + + +
+
+

Disclaimers

+
    +
  1. The results apply only to the samples / items as received, tested, and described above.
  2. +
  3. Where customer-provided details will affect the validity of the results, cannot be held liable if this information is not received, or supplied incorrectly.
  4. +
  5. This test report shall not be reproduced except in full, and not without written approval of .
  6. +
  7. Our interpretation of the results is for your benefit as guidance, for which we cannot be held liable if misinterpreted or misapplied.
  8. +
  9. + + + + + + + + + + + + + +
    + + + Accredited methods +
    + ^ + + South African Veterinary Council registered +
    + + + Subcontracted methods +
    +
  10. +
+
+
+
+
+ + + +

End of Certificate

+
+ + + + -
-

Accredited methods

-
-
-

South African Veterinary Council registered

-
-
-

Subcontracted methods

-
- - + +
+
+

Legend

+
+
+

Accredited methods

+
+
+

South African Veterinary Council registered

+
+
+

Subcontracted methods

+
+
+
From 31fd08dd21407c86fcd83cbaa7deb4b436cfd5d3 Mon Sep 17 00:00:00 2001 From: Luthando Date: Thu, 29 Jun 2023 10:46:14 +0200 Subject: [PATCH 079/126] Both Green tables using divs --- src/bika/coa/reports/GreenhillDALRRDMulti.pt | 371 ++++++++++--------- src/bika/coa/reports/GreenhillMulti.pt | 4 - 2 files changed, 197 insertions(+), 178 deletions(-) diff --git a/src/bika/coa/reports/GreenhillDALRRDMulti.pt b/src/bika/coa/reports/GreenhillDALRRDMulti.pt index e2a76a3..3f1474a 100644 --- a/src/bika/coa/reports/GreenhillDALRRDMulti.pt +++ b/src/bika/coa/reports/GreenhillDALRRDMulti.pt @@ -112,7 +112,31 @@ height: 2mm; border-top: 1px solid black; } - + + .table { + display: table; + width: 100%; + } + + .table-row { + display: table-row; + } + + .table-header { + display: table-cell; + padding: 4px; + border-top: 1px solid #ccc; + } + + .table-cell { + display: table-cell; + padding: 2px; + border-top: 1px solid #ccc; + } + + .table-header { + font-weight: bold; + } - -
-
-

Results

- - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Sample ID -
-
- Client Sample ID - -
-
-
Sample Type
-
-
-
-
Sample Point
-
-
-
-
Sample Condition
-
-
- -
-
Date Sampled
-
-
-
-
Date Received
-
-
-
-
Date Verified
-
-
-
- - MethodVerifierUnitResult
- - - - - - - - - - - - - - - - - - - - - - - - - - -
-
-
-
+ +

Results

+ + + +

+
+
+
Sample ID
+
+
+
+ +
+
+
+ +
+
+
Client Sample ID
+
+
+
+ +
+
+
+ +
+
+
Sample Type
+
+
+
+ +
+
+
+ +
+
+
Sample Point
+
+
+
+ +
+
+
+ +
+
+
Sample Condition
+
+
+
+ +
+
+
+ +
+
+
Date Sampled
+
+
+
+ +
+
+
+ +
+
+
Date Received
+
+
+
+ +
+
+
+ +
+
+
Date Verified
+
+
+
+ +
+
+
+ +
+ +
+
+ +
+
Method
+
Verifier
+
Unit
+ +
Result
+
+
+
+
+ + + + + + + + + + +
+
+ +
+
+ +
+
+ +
+ + + + +
+ + - + + + + + + +
+
+ +
+
+
+
+
+
-
- + + + diff --git a/src/bika/coa/reports/GreenhillMulti.pt b/src/bika/coa/reports/GreenhillMulti.pt index d86f5d8..61e3335 100644 --- a/src/bika/coa/reports/GreenhillMulti.pt +++ b/src/bika/coa/reports/GreenhillMulti.pt @@ -138,10 +138,6 @@ font-weight: bold; } - .colspan-4 { - grid-column: span 4; - } - diff --git a/src/bika/coa/reports/GreenhillMulti.pt b/src/bika/coa/reports/GreenhillMulti.pt index 0e56f58..f7bd1bb 100644 --- a/src/bika/coa/reports/GreenhillMulti.pt +++ b/src/bika/coa/reports/GreenhillMulti.pt @@ -133,6 +133,7 @@ display: table-cell; padding: 2px; border-top: 1px solid #ccc; + width: 22mm; } From 0750279d15b725dcf6f5e779424dab65cbd417e0 Mon Sep 17 00:00:00 2001 From: Luthando Ndlela <104898641+luthando5@users.noreply.github.com> Date: Wed, 5 Jul 2023 13:07:58 +0200 Subject: [PATCH 082/126] Lims 442, 443, 447 (#27) * New AWTC table * AWTC Cosmetics,LIMS 447 and LIMS 443 * No attachments * Added with of 25mm to columns * Fix column width value AWTC * Increase samples on coa awtc --- src/bika/coa/ajax.py | 7 +- src/bika/coa/reports/AWTCBatchMulti.pt | 371 ++++++++++++------------- src/bika/coa/reportview.py | 31 +++ 3 files changed, 214 insertions(+), 195 deletions(-) diff --git a/src/bika/coa/ajax.py b/src/bika/coa/ajax.py index f7604a1..0734510 100644 --- a/src/bika/coa/ajax.py +++ b/src/bika/coa/ajax.py @@ -72,16 +72,15 @@ def ajax_save_reports(self): sample = getAdapter(sample, ISuperModel) samples.append(sample) - csv_reports = [] is_multi_template = self.is_multi_template(template) - if template == "bika.coa:MultiGeochemistryBatch.pt": + if template == "bika.coa:GeoangolBatchMulti.pt": csv_report = self.create_geochemistry_csv_report(samples,coa_num) csv_reports = [csv_report for i in range(len(pdf_reports))] - elif template == "bika.coa:MultiBatch.pt": + elif template == "bika.coa:AWTCBatchMulti.pt": csv_report= self.create_batch_csv_reports(samples,coa_num) csv_reports = [csv_report for i in range(len(pdf_reports))] - if template == "bika.coa:MultiSampleTransposed.pt": + elif template == "bika.coa:ZimlabsTransposedMulti.pt": csv_report = self.create_zlabs_csv_report(samples,coa_num) csv_reports = [csv_report for i in range(len(pdf_reports))] elif is_multi_template: diff --git a/src/bika/coa/reports/AWTCBatchMulti.pt b/src/bika/coa/reports/AWTCBatchMulti.pt index 6ef43c5..78829cd 100644 --- a/src/bika/coa/reports/AWTCBatchMulti.pt +++ b/src/bika/coa/reports/AWTCBatchMulti.pt @@ -14,7 +14,7 @@ page_height options/page_height|nothing; content_width options/content_width|nothing; content_height options/content_height|nothing; - pages python:view.get_pages(options); + pages python:view.get_pages_awtc(options); report_images python:view.get_report_images(); styles python:view.get_coa_styles(); "> @@ -87,6 +87,25 @@ height: 2mm; border-top: 1px solid black; } + .table { + display: table; + width: 100%; + } + .table-row { + display: table-row; + } + .table-header { + display: table-cell; + padding: 4px; + font-weight: bold; + border-top: 1px solid #ccc; + } + .table-cell { + display: table-cell; + padding: 2px; + border-top: 1px solid #ccc; + width: 22mm; + } + + +
+

Please make sure all Samples are on the same batch

+
+
+ + - +
@@ -127,12 +154,23 @@
+
- @@ -247,35 +285,23 @@
+
+
+
+
+ +
- - - - - -
- -
-
@@ -287,7 +313,7 @@ - +
@@ -311,156 +337,135 @@
- -
-
-

Results

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Sample ID -
-
- Client Sample ID - -
-
-
Sample Type
-
-
-
-
Sample Point
-
-
-
-
Date Sampled
-
-
-
-
Date Received
-
-
-
-
Date Verified
-
-
-
- - - - - - - - - - - - - - + define="analyses_by_poc python:view.get_analyses_by_poc(collection); + categories_by_poc python:view.get_categories_by_poc(collection)"> +

Results

+ + + +
+
+
Sample ID
+
+ +
+
+
+ +
+
+
Client Sample ID
+
+ +
+
+
+ +
+
+
Sample Type
+
+ +
+
+
+ +
+
+
Sample Point
+
+ +
+
+
+ +
+
+
Date Sampled
+
+ +
+
+
+ +
+
+
Date Received
+
+ +
+
+
+ +
+
+
Date Verified
+
+ +
+
+
+ +
+ +
+
+ +
+
+
+
+ +
+
+ +
+ + + + +
+ + - + + + + -
-
-
-
-
-
- -

Mutli Batches found

-
+ +
+ + +
+
+ + +
+ +
+ + + - +
- - -
-
-

QC Results for

-
-

QC Results

-
-
-
-
-
- --> - - +
@@ -508,7 +497,7 @@ - +
@@ -551,7 +540,7 @@ - +
@@ -593,7 +582,7 @@ -
@@ -639,7 +628,7 @@ - +