{"__symbolic":"module","version":4,"metadata":{"JtsnxAlertService":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable","line":3,"character":1},"arguments":[{"providedIn":"root"}]}],"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","module":"@angular/common/http","name":"HttpClient","line":8,"character":28}]}],"getAlertList":[{"__symbolic":"method"}],"getAdmitCaseWorker":[{"__symbolic":"method"}],"getCSECLevelStatus":[{"__symbolic":"method"}],"getAlertsInfo":[{"__symbolic":"method"}],"insertAlert":[{"__symbolic":"method"}],"dToD":[{"__symbolic":"method"}]},"statics":{"ɵprov":{}}},"JtsnxAlertComponent":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Component","line":7,"character":1},"arguments":[{"selector":"lib-jtsnx-alert","template":"<div class=\"row\" style=\"font-size: 20px\">\r\n  <span>Alerts assigned by:&nbsp;</span><span style=\"font-weight: bold\">{{juvenileStateInfo.userID}}</span>\r\n</div>\r\n<form #alertForm=\"ngForm\" (ngSubmit)=\"alertFormSubmitted(alertForm)\">\r\n  <div class=\"row\">\r\n    <table class=\"table table-borderless w-75 m-auto\">\r\n      <tbody>\r\n      <tr>\r\n        <td style=\"width: 30%; color: red; padding-top: 6px\">Alert:</td>\r\n        <td style=\"width: 70%\">\r\n          <select name=\"cmbAlerts\" id=\"cmbAlerts\" class=\"form-control\" required style=\"display: inline; width: 310px\"\r\n                  [(ngModel)]=\"alertModel.InsertAlertMainInput.AlertId\" #cmbAlerts=\"ngModel\"\r\n                  (change)=\"alertIDChanged()\">\r\n            <option [ngValue]=\"null\"></option>\r\n            <option *ngFor=\"let item of alertList\" value=\"{{item.luAlertID}}\">{{item.luAlertDescription}}</option>\r\n          </select>&nbsp;\r\n          <span class=\"validation-message\" *ngIf=\"alertForm.submitted && cmbAlerts.invalid\">Required</span>\r\n        </td>\r\n      </tr>\r\n      <tr>\r\n        <td style=\"color: red; padding-top: 6px\">\r\n          Begin Date:\r\n        </td>\r\n        <td>\r\n          <kendo-datetimepicker\r\n            style=\"width: 250px\"\r\n            [(ngModel)]=\"AlertBeginDate\"\r\n            name=\"alertBeginDt\"\r\n            required\r\n            #alertBeginDt=\"ngModel\"\r\n            [format]=\"'MM/dd/yyyy hh:mm:ss aaa'\"\r\n            [placeholder]=\"'MM/dd/yyyy hh:mm:ss AM/PM'\"\r\n            [min]=\"jtsnxAlertService.dToD(juvenileStateInfo.djjAdmitDate)\"\r\n            [max]=\"currentDate\">\r\n          </kendo-datetimepicker>\r\n          <span class=\"validation-message\" *ngIf=\"alertForm.submitted && alertBeginDt.invalid\">Required/Invalid</span>\r\n        </td>\r\n      </tr>\r\n      <tr>\r\n        <td style=\"color: black; padding-top: 6px\">\r\n          End Date:\r\n        </td>\r\n        <td>\r\n          <kendo-datetimepicker\r\n            style=\"width: 250px\"\r\n            [(ngModel)]=\"AlertEndDate\"\r\n            name=\"alertEndDt\"\r\n            #alertEndDt=\"ngModel\"\r\n            [format]=\"'MM/dd/yyyy hh:mm:ss aaa'\"\r\n            [placeholder]=\"'MM/dd/yyyy hh:mm:ss AM/PM'\"\r\n            [min]=\"AlertBeginDate\"\r\n            (dblclick)=\"setAlertEndDateToNow()\">\r\n          </kendo-datetimepicker>\r\n          <span class=\"validation-message\" *ngIf=\"alertForm.submitted && alertEndDt.invalid\">Invalid</span>\r\n        </td>\r\n      </tr>\r\n      <tr>\r\n        <td>\r\n          <button class=\"btn btn-link p-0 m-0\" type=\"button\" title=\"Click to Change the Case Worker for this Juvenile\"\r\n                  (click)=\"openCW('edit')\">Alert Contact Name\r\n          </button>\r\n        </td>\r\n        <td>\r\n          <button class=\"btn btn-link p-0 m-0\" type=\"button\" title=\"Click to view the selected Contact's Information\"\r\n                  (click)=\"openCW('read')\">{{caseWorkerName}}</button>\r\n        </td>\r\n      </tr>\r\n      </tbody>\r\n    </table>\r\n  </div>\r\n  <div class=\"row\" *ngIf=\"alertModel.InsertAlertMainInput.AlertId === '21'\">\r\n    <table class=\"table table-borderless w-75 m-auto\">\r\n      <tbody>\r\n      <tr>\r\n        <td style=\"width: 30%; color: red; padding-top: 6px\">Type Of Plan:\r\n        </td>\r\n        <td style=\"width: 70%; padding-top: 6px\">\r\n          <!--          <div class=\"row\" hidden>-->\r\n          <!--            <input type=\"checkbox\" name=\"chkreferral\" id=\"chkreferral\" class=\"form-check-input\" #typeOfPlanChks=\"ngModel\"-->\r\n          <!--                    [(ngModel)]=\"chkReferral\"-->\r\n          <!--                   (change)=\"checkboxChecked(0, chkReferral)\">&nbsp;&nbsp;-->\r\n          <!--            <label for=\"chkreferral\">Referral</label>-->\r\n          <!--          </div>-->\r\n          <div class=\"row form-check\">\r\n            <input type=\"checkbox\" name=\"chksuicideprevention\" id=\"chksuicideprevention\" class=\"form-check-input\"\r\n                   [(ngModel)]=\"chkSuicidePrevention\" #chksuicideprevention=\"ngModel\"\r\n                   [required]=\"!chkBehaviorProblems && !chkVictimizationRisk\"\r\n                   (change)=\"checkboxChecked(1, chkSuicidePrevention)\">&nbsp;&nbsp;\r\n            <label class=\"form-check-label\" for=\"chksuicideprevention\">Suicide/Self Harm Prevention</label>\r\n          </div>\r\n          <div class=\"row form-check\">\r\n            <input type=\"checkbox\" name=\"chkbehaviorproblems\" id=\"chkbehaviorproblems\" class=\"form-check-input\"\r\n                   [(ngModel)]=\"chkBehaviorProblems\" #chkbehaviorproblems=\"ngModel\"\r\n                   [required]=\"!chkSuicidePrevention && !chkVictimizationRisk\"\r\n                   (change)=\"checkboxChecked(2, chkBehaviorProblems)\">&nbsp;&nbsp;\r\n            <label class=\"form-check-label\" for=\"chkbehaviorproblems\">Coping Support</label>\r\n          </div>\r\n          <div class=\"row form-check\">\r\n            <input type=\"checkbox\" name=\"chkvictimizationrisk\" id=\"chkvictimizationrisk\" class=\"form-check-input\"\r\n                   [(ngModel)]=\"chkVictimizationRisk\" #chkvictimizationrisk=\"ngModel\"\r\n                   [required]=\"!chkSuicidePrevention && !chkBehaviorProblems\"\r\n                   (change)=\"checkboxChecked(3, chkVictimizationRisk)\">&nbsp;&nbsp;\r\n            <label class=\"form-check-label\" for=\"chkvictimizationrisk\">Victim Risk</label>\r\n          </div>\r\n          <div class=\"row\"\r\n               *ngIf=\"alertForm.submitted && (chksuicideprevention.invalid || chkbehaviorproblems.invalid || chkvictimizationrisk.invalid)\">\r\n            <span class=\"validation-message\">Required</span>\r\n          </div>\r\n        </td>\r\n      </tr>\r\n      </tbody>\r\n    </table>\r\n  </div>\r\n  <div class=\"row mt-2\">\r\n    <span [style.color]=\"this.alertModel.InsertAlertMainInput.AlertId === '10' || this.alertModel.InsertAlertMainInput.AlertId === '116' ||\r\n      alertModel.InsertAlertCAInput.ConfinementType !== null ? 'red' : 'black'\" style=\"font-size: 16px\">\r\n      Comments:</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\r\n    (Characters remaining:&nbsp;\r\n    <span style=\"color: blue\">{{500 - alertModel.InsertAlertMainInput.AlertComments?.length}}</span>)\r\n  </div>\r\n  <div class=\"row\">\r\n    <textarea class=\"form-control\" name=\"txtComments\" id=\"txtComments\" rows=\"3\"\r\n              [ngModel]=\"alertModel.InsertAlertMainInput.AlertComments\" maxlength=\"500\"\r\n              (ngModelChange)=\"alertModel.InsertAlertMainInput.AlertComments = $event.toUpperCase()\"\r\n              [required]=\"this.alertModel.InsertAlertMainInput.AlertId === '10' || this.alertModel.InsertAlertMainInput.AlertId === '116' ||alertModel.InsertAlertCAInput.ConfinementType !== null\"\r\n              #txtComments=\"ngModel\"\r\n    ></textarea>\r\n  </div>\r\n  <div class=\"row d-flex justify-content-center\" *ngIf=\"alertForm.submitted && txtComments.invalid\">\r\n    <span class=\"validation-message\">Required</span>\r\n  </div>\r\n  <div class=\"row justify-content-center mt-2\" *ngIf=\"alertModel.InsertAlertMainInput.AlertId === '113'\">\r\n    <div class=\"form-check form-check-inline\">\r\n      <input [(ngModel)]=\"alertModel.InsertAlertCAInput.ConfinementType\" required #rdConfi=\"ngModel\"\r\n             class=\"form-check-input\" id=\"rdconfiPre\" name=\"rdConfi\" [value]=\"1\" type=\"radio\"/>&nbsp;\r\n      <label class=\"form-check-label\" for=\"rdconfiPre\" style=\"color: red\">Apparent Behavior</label>\r\n    </div>\r\n    <div class=\"form-check form-check-inline\">\r\n      <input [(ngModel)]=\"alertModel.InsertAlertCAInput.ConfinementType\" required\r\n             class=\"form-check-input\" id=\"rdconfiDisc\" name=\"rdConfi\" [value]=\"2\" type=\"radio\"/>&nbsp;\r\n      <label class=\"form-check-label\" for=\"rdconfiDisc\" style=\"color: red\">Imminent Threat</label>\r\n    </div>\r\n    <div class=\"row d-flex justify-content-center w-100\" *ngIf=\"alertForm.submitted && rdConfi.invalid\">\r\n      <span class=\"validation-message\">Required</span>\r\n    </div>\r\n  </div>\r\n\r\n  <div class=\"row w-100\" *ngIf=\"alertModel.InsertAlertMainInput.AlertId === '10'\">\r\n    <span style=\"font-size: 16px\">Discharge Statement</span>\r\n    <textarea class=\"form-control w-100\" name=\"txtDischargeStatement\" id=\"txtDischargeStatement\" rows=\"3\"\r\n              [(ngModel)]=\"alertModel.InsertAlertDischargeStatementInput.DischargeStatement\"></textarea>\r\n  </div>\r\n\r\n  <div class=\"row d-flex justify-content-center mt-2\" *ngIf=\"alertModel.InsertAlertMainInput.AlertId === '110'\">\r\n    <table class=\"table table-borderless w-75 m-auto\">\r\n      <tbody>\r\n      <tr>\r\n        <td style=\"width: 40%; padding-top: 6px\">CSEC Level Status:\r\n          <img src=\"{{alertInputData.serverUrl + 'cdn/images/alert.png'}}\" alt=\"\" (click)=\"openCSECIntro()\"\r\n               style=\"width: 16px; height: 16px; vertical-align:auto; cursor: pointer\">\r\n        </td>\r\n        <td style=\"width: 60%\">\r\n          <select class=\"form-control\" name=\"cboCSECStatus\" id=\"cboCSECStatus\"\r\n                  [(ngModel)]=\"alertModel.InsertAlertCSECInput.CSECStatus\" required #cboCSECStatus=\"ngModel\"\r\n                  style=\"width: 285px;display: inline\">\r\n            <option [ngValue]=\"null\"></option>\r\n            <option *ngFor=\"let item of csecList\"\r\n                    value=\"{{item.luAlertsCSECLevelStatusId}}\">{{item.luAlertsCSECLevelStatusDesc}}</option>\r\n          </select>&nbsp;\r\n          <span *ngIf=\"alertForm.submitted && cboCSECStatus.invalid\" style=\"font-weight: bold\"\r\n                class=\"validation-message\">*</span>\r\n        </td>\r\n      </tr>\r\n      <tr>\r\n        <td>Start Date:</td>\r\n        <td>\r\n          <kendo-datepicker\r\n            [(ngModel)]=\"CSECBeginDate\"\r\n            style=\"width:170px;\"\r\n            name=\"csecBeginDt\"\r\n            required\r\n            #csecBeginDt=\"ngModel\"\r\n            [min]=\"csecBeginDateMin(AlertBeginDate)\"\r\n            [format]=\"'MM/dd/yyyy'\"\r\n            [placeholder]=\"'MM/dd/yyyy'\">\r\n          </kendo-datepicker>&nbsp;\r\n          <span *ngIf=\"alertForm.submitted && csecBeginDt.invalid\" style=\"font-weight: bold\" class=\"validation-message\">Required/Invalid</span>\r\n        </td>\r\n      </tr>\r\n      <tr>\r\n        <td>End Date:</td>\r\n        <td>\r\n          <kendo-datepicker\r\n            [(ngModel)]=\"CSECEndDate\"\r\n            style=\"width:170px;\"\r\n            name=\"csecEndDt\"\r\n            #csecEndDt=\"ngModel\"\r\n            [min]=\"CSECBeginDate\"\r\n            [format]=\"'MM/dd/yyyy'\"\r\n            [placeholder]=\"'MM/dd/yyyy'\">\r\n          </kendo-datepicker>&nbsp;\r\n          <span *ngIf=\"alertForm.submitted && csecEndDt.invalid\" style=\"font-weight: bold\" class=\"validation-message\">Invalid</span>\r\n        </td>\r\n      </tr>\r\n      </tbody>\r\n    </table>\r\n  </div>\r\n\r\n  <div class=\"row d-flex justify-content-center mt-2\" *ngIf=\"alertModel.InsertAlertMainInput.AlertId === '111'\">\r\n    <div class=\"form-check form-check-inline\">\r\n      <input [(ngModel)]=\"alertModel.InsertAlertPCInput.PCSegregated\" required #rdSegregated=\"ngModel\"\r\n             class=\"form-check-input\" id=\"rdSeg\" name=\"rdSegregated\" [value]=\"1\" type=\"radio\"/>&nbsp;\r\n      <label class=\"form-check-label\" for=\"rdSeg\" style=\"color: red\">Segregated</label>\r\n    </div>\r\n    <div class=\"form-check form-check-inline\">\r\n      <input [(ngModel)]=\"alertModel.InsertAlertPCInput.PCSegregated\" required\r\n             class=\"form-check-input\" id=\"rdNSeg\" name=\"rdSegregated\" [value]=\"2\" type=\"radio\"/>&nbsp;\r\n      <label class=\"form-check-label\" for=\"rdNSeg\" style=\"color: red\">Not Segregated</label>\r\n    </div>\r\n    <div class=\"row d-flex justify-content-center w-100\" *ngIf=\"alertForm.submitted && rdSegregated.invalid\">\r\n      <span class=\"validation-message\">Required</span>\r\n    </div>\r\n    <div class=\"row w-100 mt-2\">\r\n      <table class=\"table table-borderless w-75 m-auto\">\r\n        <tbody>\r\n        <tr>\r\n          <td style=\"width: 25%; color: red\">Start Date:</td>\r\n          <td style=\"width: 75%\">\r\n            <kendo-datetimepicker\r\n              style=\"width: 250px\"\r\n              [(ngModel)]=\"PCStartDate\"\r\n              name=\"pcStartDt\"\r\n              required\r\n              #pcStartDt=\"ngModel\"\r\n              [format]=\"'MM/dd/yyyy hh:mm:ss aaa'\"\r\n              [placeholder]=\"'MM/dd/yyyy hh:mm:ss AM/PM'\"\r\n              [min]=\"AlertBeginDate\">\r\n            </kendo-datetimepicker>\r\n            <span *ngIf=\"alertForm.submitted && pcStartDt.invalid\" style=\"font-weight: bold\"\r\n                  class=\"validation-message\">Required/Invalid</span>\r\n          </td>\r\n        </tr>\r\n        <tr>\r\n          <td style=\"width: 25%;\">End Date:</td>\r\n          <td style=\"width: 75%\">\r\n            <kendo-datetimepicker\r\n              style=\"width: 250px\"\r\n              [(ngModel)]=\"PCEndDate\"\r\n              name=\"pcEndDt\"\r\n              #pcEndDt=\"ngModel\"\r\n              [format]=\"'MM/dd/yyyy hh:mm:ss aaa'\"\r\n              [placeholder]=\"'MM/dd/yyyy hh:mm:ss AM/PM'\"\r\n              [min]=\"PCStartDate\">\r\n            </kendo-datetimepicker>\r\n            <span *ngIf=\"alertForm.submitted && pcEndDt.invalid\" style=\"font-weight: bold\"\r\n                  class=\"validation-message\">Invalid</span>\r\n          </td>\r\n        </tr>\r\n        </tbody>\r\n      </table>\r\n    </div>\r\n  </div>\r\n\r\n  <div class=\"row d-flex justify-content-center mt-3\">\r\n    <button class=\"btn btn-primary mr-2\" type=\"submit\">Save</button>\r\n    <button class=\"btn btn-primary ml-2\" type=\"button\" (click)=\"closeWindow()\">Close</button>\r\n  </div>\r\n</form>\r\n<hr>\r\n<div class=\"row\">\r\n  <table class=\"table table-bordered alert-table\">\r\n    <tbody>\r\n    <tr>\r\n      <th style=\"width: 20%\">Description</th>\r\n      <th style=\"width: 20%\">Begin Date</th>\r\n      <th style=\"width: 20%; max-width: 20%\">End Date</th>\r\n      <th style=\"width: 20%; max-width: 150px\">Comments</th>\r\n      <th style=\"width: 20%\">Contact Name</th>\r\n    </tr>\r\n    <tr *ngFor=\"let item of alertsInfo\">\r\n      <td [style.background]=\"item.luColorCode === 3? 'pink' : item.luColorCode === 2? 'orange' : 'lightgreen'\"\r\n      >\r\n        <button class=\"btn btn-link p-0 m-0\" type=\"button\" style=\"font-size: 0.7rem\"\r\n                (click)=\"openAlertAudit(item.alertNum)\">{{item.luAlertDescription}}</button>\r\n      </td>\r\n      <td style=\"vertical-align: middle\">\r\n        <button *ngIf=\"item.activeStatus === 1 && (item.alertID !== 19 || booAllowBHPR)\" class=\"btn btn-link p-0 m-0\"\r\n                style=\"font-size: 0.7rem; white-space: nowrap\" (click)=\"openAlertEdit(item.alertNum, item.alertBegDate)\"\r\n                type=\"button\">{{item.alertBegDate | date: 'MM/dd/yy hh:mm:ss aaa'}}</button>\r\n        <span *ngIf=\"item.activeStatus === 1 && item.alertID === 19 && !booAllowBHPR\" title=\"You do not have permissions to edit this BHPRP Alert\"\r\n                style=\"font-size: 0.7rem; color:#007bff; font-weight: bold;\">{{item.alertBegDate | date: 'MM/dd/yy hh:mm:ss aaa'}}</span>\r\n        <span *ngIf=\"item.activeStatus === 0\"\r\n              style=\"font-size: 0.7rem\">{{item.alertBegDate | date: 'MM/dd/yy hh:mm:ss aaa'}}</span>\r\n      </td>\r\n      <td style=\"vertical-align: middle\">\r\n        <span\r\n          style=\"font-size: 0.7rem; white-space: nowrap\">{{item.alertEndDate | date: 'MM/dd/yy hh:mm:ss aaa'}}</span>\r\n      </td>\r\n      <td style=\"overflow: hidden; max-width: 150px; white-space: nowrap; vertical-align: middle; padding-right: 10px\"\r\n          title=\"{{item.alertComments}}\">\r\n        <p style=\"overflow: hidden; max-width: 150px; white-space: nowrap; vertical-align: middle\">\r\n          {{item.alertComments === null || item.alertComments === '' ? '-' : item.alertComments}}\r\n        </p>\r\n      </td>\r\n      <td>{{item.caseWName}}</td>\r\n    </tr>\r\n    </tbody>\r\n  </table>\r\n</div>\r\n","styles":["table>tbody>tr>td,table>tbody>tr>th{font-size:18px;padding:2px 10px}table>tbody>tr>th{background:beige;border:2px solid grey;font-weight:700;text-align:center}.alert-table>tbody>tr>td{background:#fff;border:2px solid grey;font-size:14px;text-align:center}label{font-size:16px;margin-bottom:0}"]}]}],"members":{"alertInputData":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input","line":13,"character":3}}]}],"openCWClicked":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Output","line":14,"character":3}}]}],"openAlertEditClicked":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Output","line":15,"character":3}}]}],"closeWindowClicked":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Output","line":16,"character":3}}]}],"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"JtsnxAlertService"},{"__symbolic":"reference","module":"@angular/common","name":"DatePipe","line":43,"character":77}]}],"ngOnInit":[{"__symbolic":"method"}],"initAlert":[{"__symbolic":"method"}],"getAlertList":[{"__symbolic":"method"}],"getAlerts":[{"__symbolic":"method"}],"getAlertCaseWorker":[{"__symbolic":"method"}],"alertFormSubmitted":[{"__symbolic":"method"}],"setAlertEndDateToNow":[{"__symbolic":"method"}],"openCW":[{"__symbolic":"method"}],"setCW":[{"__symbolic":"method"}],"checkboxChecked":[{"__symbolic":"method"}],"alertIDChanged":[{"__symbolic":"method"}],"openCSECIntro":[{"__symbolic":"method"}],"csecBeginDateMin":[{"__symbolic":"method"}],"openAlertAudit":[{"__symbolic":"method"}],"openAlertEdit":[{"__symbolic":"method"}],"closeWindow":[{"__symbolic":"method"}]}},"JtsnxAlertModule":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"NgModule","line":7,"character":1},"arguments":[{"declarations":[{"__symbolic":"reference","name":"JtsnxAlertComponent"}],"imports":[{"__symbolic":"reference","module":"@angular/common/http","name":"HttpClientModule","line":9,"character":12},{"__symbolic":"reference","module":"@angular/common","name":"CommonModule","line":9,"character":30},{"__symbolic":"reference","module":"@angular/forms","name":"FormsModule","line":9,"character":44},{"__symbolic":"reference","module":"@progress/kendo-angular-dateinputs","name":"DateInputsModule","line":9,"character":57}],"exports":[{"__symbolic":"reference","name":"JtsnxAlertComponent"}]}]}],"members":{}}},"origins":{"JtsnxAlertService":"./lib/jtsnx-alert.service","JtsnxAlertComponent":"./lib/jtsnx-alert.component","JtsnxAlertModule":"./lib/jtsnx-alert.module"},"importAs":"jtsnx-alert"}