myMedisys/tomcatfiles/mymedisys-frontend/WEB-INF/classes/templates/page/medical/collect-medical-results.html
2023-09-06 05:56:42 +05:30

279 lines
13 KiB
HTML

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:th="http://www.thymeleaf.org"
layout:decorate="~{layouts/blank-layout}">
<head>
<title th:text="${pageTitle}">Collect MR</title>
</head>
<body layout:fragment="page_content" id="page_expat">
<div layout:fragment="page_subtitle">
<h1 class="title mb-1" th:text="${pageTitle}"></h1>
<h3 class="mt-0" th:text="#{Collect Medical Results}"></h3>
</div>
<form id="applicationForm" name="applicationForm" th:action="@{''}" autocomplete="off"
th:method="POST" enctype="multipart/form-data" th:object="${form}">
<div class="card">
<div class="card-header card-header-rose card-header-icon">
<h3 class="card-title m-0 pull-left" th:text="#{Worker Information}"></h3>
<a class="pull-right" href="#" th:onclick="|popup('${form.workerRegDtl.workerProfile?.wrkrProfId}')|">View Full Profile</a>
</div>
<div class="card-body" th:with="isValid=${(form.workerRegDtl==null || form.workerRegDtl.workerProfile==null)?false:true}">
<div class="row form-row">
<div class="col-sm-12 col-md-4 col-lg-4">
<label class="text-muted" th:text="#{'Full Name'}"></label>
<h6 th:text="${isValid ? form.workerRegDtl.workerProfile.firstName + ' ' + form.workerRegDtl.workerProfile.lastName : '-'}"></h6>
</div>
<div class="col-sm-12 col-md-4 col-lg-4">
<label class="text-muted" th:text="#{'Nationality'}"></label>
<h6 th:text="${isValid ? (form.workerRegDtl.workerProfile.nationality.cntryDesc):'-'}"></h6>
</div>
<div class="col-sm-12 col-md-4 col-lg-4">
<label class="text-muted" th:text="#{'Gender'}"></label>
<h6 th:text="${isValid ?(form.workerRegDtl.workerProfile?.gender == 'M' ? 'MALE' : 'FEMALE'):'-'}"></h6>
</div>
</div>
<div class="row form-row">
<div class="col-sm-12 col-md-4 col-lg-4">
<label class="text-muted" th:text="#{'Date of Birth'}"></label>
<h6 th:text="${isValid ? (#dates.format(form.workerRegDtl.workerProfile.dob, 'dd/MM/yyyy')):'-'}"></h6>
</div>
<div class="col-sm-12 col-md-8 col-lg-8">
<label class="text-muted" th:text="#{'Address'}"></label>
<h6>
<th:block th:text="${form.workerRegDtl?.workerProfile?.addr1}"></th:block>
<th:block
th:text="${form.workerRegDtl?.workerProfile?.zipcode!= null ? ' -' + form.workerRegDtl?.workerProfile?.zipcode : ''}"></th:block>
<th:block
th:text="${form.workerRegDtl?.workerProfile?.city?.cityDesc != null ? ' ' + form.workerRegDtl?.workerProfile?.city?.cityDesc : ''}"></th:block>
<th:block
th:text="${form.workerRegDtl?.workerProfile?.state?.stateDesc != null ? ', ' + form.workerRegDtl?.workerProfile?.state?.stateDesc : ''}"></th:block>
<th:block
th:text="${form.workerRegDtl?.workerProfile?.country?.cntryDesc != null ? ' ,' + form.workerRegDtl?.workerProfile?.country?.cntryDesc : ''}"></th:block>
</h6>
</div>
</div>
</div>
</div>
<input type="hidden" th:field="*{wrkrMcId}" />
<input type="hidden" th:field="*{workerRegDtl.wrkrRegId}" />
<input type="hidden" th:field="*{mcProfile.mcProfId}" />
<div class="card">
<div class="card-header card-header-rose card-header-icon">
<h3 class="card-title m-0 pull-left" th:text="#{Medical Result}"></h3>
<div class="ribbon ribbon-bookmark ribbon-right"
th:classappend="${form.status != null} ? (${form.status?.statusCd == 'UNFIT'} ? 'ribbon-danger' : (${form.status?.statusCd == 'FIT'} ? 'ribbon-success' : 'ribbon-warning')) : 'ribbon-info'">
<span id="testResults" ><th:block th:text="${form.status != null ? form.status?.statusDesc : 'NEW'}"></th:block></span>
</div>
</div>
<th:block th:if="${mcReport!=null}"
th:with="docId=${mcReport.docTypeId},title=#{'Medical result Report'}">
<br/>
<div class="col-md-6 col-lg-4 col-xlg-4">
<div class="form-group mb-4">
<a
th:href="'javascript:documentPopup(\'file/download?fmId=' +
${mcReport?.docMgtId} + '&bucketName=MYMEDISYS_RPT\',\''+ ${title} + '\', \'' + ${mcReport?.docContentType} + '\',\'' + ${title} + '\');'">
<i class="material-icons">picture_as_pdf</i> <th:block
th:text="${title}"></th:block>
</a>
</div>
</div>
</th:block>
<div class="card-body" th:with="isAdminEdit=${#authorization.expression('hasAuthority(''MC_ADMIN'')')} and ${form?.status!=null && (form?.workerRegDtl?.status?.statusCd=='PND')}">
<th:block th:unless="${isView}">
<div class="form-row" >
<div class="col-sm-12 col-md-6 col-lg-6">
<div class="form-group">
<label class="required bmd-label-floating" th:text="#{Medical Reference No.}"></label>
<input th:field="*{medRefRefNo}" type="text" class="form-control" required="required" />
</div>
</div>
<div class="col-sm-12 col-md-6 col-lg-6" >
<div class="form-group">
<label class="required bmd-label-floating" th:text="#{'Blood Type'}"></label>
<select id="transportation" class="form-control select-filter" required="required"
th:field="*{bloodTypeMtdt.mstrDtId}">
<option value="" />
<option th:each="meta : ${@staticreference.masterDataByType('BLOOD_TYPE')}"
th:value="${meta.mstrDtId}" th:text="${meta?.mstrDtDesc?.en}" />
</select>
</div>
</div>
</div>
<div class="row mt-2" >
<div class="col-sm-12 col-md-6 col-lg-6" >
<div class="form-group">
<label class="required bmd-label-floating" th:text="#{'Doctor Name'}"></label>
<select id="doctorNameSelection"
class="form-control custom-select"
th:field="*{doctorProfile.doctorProfId}"
required="required">
<option value=""></option>
<option th:each="mc : ${doctorList}"
th:with="mc1=${mc.doctorNm!=null?mc.doctorNm.toUpperCase():''}" th:value="${mc.doctorProfId}"
th:text="${mc1}"
th:data-email="${mc.doctorQualif!=null?mc.doctorQualif:'-'}"
th:data-regno="${mc.doctorId!=null?mc.doctorId.toUpperCase():'-'}"
></option>
</select>
</div>
</div>
<div class="col-sm-12 col-md-6 col-lg-6" >
<div class="form-group">
<label class="required bmd-label-floating" th:text="#{'Medical Examination Date'}"></label>
<input type="text" class="form-control datepicker pastDtPicker"
th:field="*{examinDt}" id="examinDt"
name="examinDt" required="required" />
</div>
</div>
</div>
<div id="divDocDetails" style="display:none">
<div class="row mt-2" >
<div class="col-sm-12 col-md-6 col-lg-6" >
<div class="form-group">
<label class="text-muted" th:text="#{Professional Id}"></label>
<h6 id="doctorprofCls" ></h6>
</div>
</div>
<div class="col-sm-12 col-md-6 col-lg-6" >
<div class="form-group">
<label class="text-muted" th:text="#{Qualification}"></label>
<h6 id="doctorqualiCls" ></h6>
</div>
</div>
</div>
</div>
<div class="row mt-2" >
<div class="col-sm-12 col-md-6 col-lg-6"
th:each="doc, row : ${form.medicalDocs}">
<extra:file extra:document="${doc.fileType}"
th:field="*{medicalDocs[__${row.index}__]}"></extra:file>
</div>
</div>
</th:block>
<th:block th:if="${isView}">
<div class="row mb-2">
<div class="col-sm-12 col-md-4 col-lg-4">
<label class="text-muted" th:text="#{Medical Reference No.}"></label>
<h6 th:text="${form.medRefRefNo}"></h6>
</div>
<div class="col-sm-12 col-md-4 col-lg-4">
<label class="text-muted" th:text="#{'Blood Type'}"></label>
<h6 th:text="${form.bloodTypeMtdt!=null?form.bloodTypeMtdt.mstrDtDesc.en:'-'}"></h6>
</div>
<div class="col-sm-12 col-md-4 col-lg-4" th:each="doc, row : *{medicalDocs}">
<a th:href="'javascript:documentPopup(\'file/download?fmId=' +
${doc?.fmId} + '&bucketName=' + ${doc?.fileType?.fmBucket} + '\',\''+ ${doc?.fileType?.docDesc?.en} + '\', \'' + ${doc?.file?.contentType} + '\',\'' + ${doc?.fileType?.docDesc?.en} + '\');'">
<i class="material-icons">picture_as_pdf</i>
<h6 style="display:inline;" th:text="${doc?.fileType?.docDesc?.en}" ></h6>
</a>
</div>
</div>
<br/><br/>
<h5 class="card-title" th:utext="#{Doctor Details}"></h5>
<br/>
<div class="row mb-2">
<div class="col-sm-12 col-md-4 col-lg-4">
<label class="text-muted" th:text="#{'Doctor Name'}"></label>
<h6 th:text="${form.doctorProfile!=null?form.doctorProfile.doctorNm:'-'}"></h6>
</div>
<div class="col-sm-12 col-md-4 col-lg-4">
<label class="text-muted" th:text="#{'Professional Id'}"></label>
<h6 th:text="${form.doctorProfile!=null?form.doctorProfile.doctorId:'-'}"></h6>
</div>
<div class="col-sm-12 col-md-4 col-lg-4">
<label class="text-muted" th:text="#{'Qualification'}"></label>
<h6 th:text="${form.doctorProfile!=null?form.doctorProfile.doctorQualif:'-'}"></h6>
</div>
</div>
</th:block>
<label class="required bmd-label-floating">Is the Worker tested <span class="text-info">NEGATIVE</span> with the following medical conditions?</label>
<div class="row mb-2">
<div class="col-sm-12 col-md-6 col-lg-6 mb-2" th:each="disease, idx : *{workerMedicalSymptomsRel}">
<input type="checkbox" th:disabled="${isView} ? 'disabled'"
th:field="*{workerMedicalSymptomsRel[__${idx.index}__].status}"
th:checked="*{workerMedicalSymptomsRel[__${idx.index}__].status} ? 'checked' "
class="diseaseSwitch" data-color="#26c6da" data-secondary-color="#f62d51" data-size="small" />
<span class="ml-1" th:text="${disease.symptMtdt.symptName}"></span>
<input type="hidden" th:id="#{symtoms__${idx.index}__relId}"
th:field="*{workerMedicalSymptomsRel[__${idx.index}__].relId}" />
<input type="hidden"
th:field="*{workerMedicalSymptomsRel[__${idx.index}__].symptMtdt.symptId}" />
</div>
</div>
<div class="row" th:unless="${isView}" sec:authorize="hasAnyAuthority('MC_OPERATOR')">
<div class="col-12" >
<div class="form">
<label th:text="#{Remarks}"></label>
<textarea class="form-control valid " th:field="*{remarks}" th:disabled="${!(form?.workerRegDtl?.status?.statusCd=='VER'||form?.workerRegDtl?.status?.statusCd=='REG' || form?.workerRegDtl?.status?.statusCd=='RTN')}"
placeholder="" aria-invalid="false" rows="3"></textarea>
<label class="text-danger" id="lblRemarksRequired" style="display: none" th:text="#{lbl.remarks.req}" ></label>
</div>
</div>
</div>
<div class="bd-example mt-4 mb-2" th:if="${isAdminEdit}">
<h3 class="card-title">Verify</h3><hr>
<div class="row">
<div class="col-12">
<label th:text="#{Status}"></label>
<div class="form-group">
<div class="form-check-radio form-check-inline">
<label class="form-check-label">
<input class="form-check-input" type="radio" th:field="*{appStatus}" value="APR"> Approve
<span class="circle"> <span class="check"></span></span>
</label>
</div>
<div class="form-check-radio form-check-inline">
<label class="form-check-label">
<input th:field="*{appStatus}" class="form-check-input" type="radio" value="RTN"> Return
<span class="circle"><span class="check"></span></span>
</label>
</div>
</div>
</div>
<label class="col-12 text-danger" id="lblStatusRequired" style="display: none" th:text="#{'Please Select Approve / Reject'}" />
</div>
<div class="row">
<div class="col-12">
<div class="form">
<label th:text="#{Remarks}"></label>
<textarea class="form-control valid " th:field="*{remarks}" placeholder="" aria-invalid="false" rows="3"></textarea>
<label class="text-danger" id="lblRemarksRequired" style="display: none" th:text="#{lbl.remarks.req}" />
</div>
</div>
</div>
</div>
<div class="row" th:if="${isView and !isAdminEdit}">
<div class="col-12" >
<div class="form">
<label class="text-muted" th:text="#{Remarks}"></label>
<h6 th:text="${form.remarks != null ? form.remarks :'-'}"></h6>
</div>
</div>
</div>
<div class="row">
<div class="col-12 mt-3">
<div class="pull-right">
<button type="button" class="btn btn-secondary"
th:onclick="|window.location.href='@{#{url.worker.appointment.list}}'|">Back</button>
<button type="submit" sec:authorize="hasAnyAuthority('MC_OPERATOR')"
th:if="${form?.workerRegDtl!=null && (form?.workerRegDtl?.status?.statusCd=='VER'|| form?.workerRegDtl?.status?.statusCd=='REG' || form?.workerRegDtl?.status?.statusCd=='RTN' )}"
class="btn btn-fill btn-primary btn-wd btn-focus">Submit</button>
<button type=""submit"" sec:authorize="hasAnyAuthority('MC_ADMIN')"
th:if="${form?.workerRegDtl?.status!=null && (form?.workerRegDtl?.status?.statusCd=='PND')}"
class="btn btn-fill btn-primary btn-wd btn-focus">Submit</button>
</div>
</div>
</div>
</div>
</div>
</form>
</body>
</html>