Skip to content

Commit

Permalink
TH-119992: fixed the issue that CGL company name can't be updated
Browse files Browse the repository at this point in the history
  • Loading branch information
bcgov-brwang committed Sep 11, 2024
1 parent 5c24c2a commit 134590b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion client/src/js/views/OwnersDetail.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -505,7 +505,7 @@ class OwnersDetail extends React.Component {
</Col>
<Col lg={4} md={6} sm={12} xs={12}>
<ColDisplay labelProps={{ xs: 6 }} fieldProps={{ xs: 6 }} label="CGL Insurance Company">
{owner.cglCompanyName}
{owner.cglCompany}
</ColDisplay>
</Col>
<Col lg={4} md={6} sm={12} xs={12}>
Expand Down
10 changes: 5 additions & 5 deletions client/src/js/views/dialogs/OwnersPolicyEditDialog.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ class OwnersPolicyEditDialog extends React.Component {
this.state = {
workSafeBCPolicyNumber: owner.workSafeBCPolicyNumber || '',
workSafeBCExpiryDate: owner.workSafeBCExpiryDate || '',
cglCompanyName: owner.cglCompanyName || '',
cglCompany: owner.cglCompany || '',
cglPolicyNumber: owner.cglPolicyNumber || '',
cglEndDate: owner.cglEndDate || '',

Expand All @@ -52,7 +52,7 @@ class OwnersPolicyEditDialog extends React.Component {
if (this.state.workSafeBCExpiryDate !== owner.workSafeBCExpiryDate) {
return true;
}
if (this.state.cglCompanyName !== owner.cglCompanyName) {
if (this.state.cglCompany !== owner.cglCompany) {
return true;
}
if (this.state.cglPolicyNumber !== owner.cglPolicyNumber) {
Expand Down Expand Up @@ -99,7 +99,7 @@ class OwnersPolicyEditDialog extends React.Component {
...this.props.owner,
workSafeBCPolicyNumber: this.state.workSafeBCPolicyNumber,
workSafeBCExpiryDate: toZuluTime(this.state.workSafeBCExpiryDate),
cglCompanyName: this.state.cglCompanyName,
cglCompany: this.state.cglCompany,
cglPolicyNumber: this.state.cglPolicyNumber,
cglEndDate: toZuluTime(this.state.cglEndDate),
};
Expand Down Expand Up @@ -155,11 +155,11 @@ class OwnersPolicyEditDialog extends React.Component {
</Row>
<Row>
<Col xs={12}>
<FormGroup controlId="cglCompanyName">
<FormGroup controlId="cglCompany">
<FormLabel>CGL Insurance Company</FormLabel>
<FormInputControl
type="text"
value={this.state.cglCompanyName}
value={this.state.cglCompany}
updateState={this.updateState}
maxLength={Constant.MAX_LENGTH_CGL_COMPANY_NAME}
/>
Expand Down

0 comments on commit 134590b

Please sign in to comment.