Skip to content

Commit

Permalink
Merge branch 'master' into use-constants
Browse files Browse the repository at this point in the history
  • Loading branch information
mark86092 authored Sep 5, 2024
2 parents 6cd8772 + efa7ac5 commit 6cc02b6
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,10 @@ import { tabType } from '../../../constants/companyJobTitle';
import { createWorkExperienceWithRating } from 'actions/experiences';
import { transferKeyToSnakecase } from 'utils/objectUtil';
import { GA_CATEGORY, GA_ACTION } from 'constants/gaConstants';
import { ERROR_CODE_MSG } from 'constants/errorCodeMsg';

import { sendEvent } from 'utils/hotjarUtil';
import rollbar from 'utils/rollbar';

const header = <Header title="分享你的工作心得(評價)" />;

Expand Down Expand Up @@ -137,6 +139,11 @@ const TypeForm = ({ open, onClose, hideProgressBar = false }) => {
category: GA_CATEGORY.SHARE_WORK,
action: GA_ACTION.UPLOAD_FAIL,
});
const errorCode = 'ER0020';
rollbar.error(
`[${errorCode}] ${ERROR_CODE_MSG[errorCode].internal} ${error.message}`,
error,
);
}, []);

return (
Expand Down
3 changes: 3 additions & 0 deletions src/constants/errorCodeMsg.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,4 +78,7 @@ export const ERROR_CODE_MSG = {
ER0019: {
internal: 'Not submittable',
},
ER0020: {
internal: 'Submit work experience failed',
},
};
2 changes: 2 additions & 0 deletions src/graphql/jobTitle.js
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ export const queryJobTitleOverviewGql = /* GraphQL */ `
reply_count
like_count
recommend_to_others
averageSectionRating
}
}
salaryWorkTimesResult(start: 0, limit: $salaryWorkTimesLimit) {
Expand Down Expand Up @@ -272,6 +273,7 @@ export const getJobTitleWorkExperiencesQuery = /* GraphQL */ `
reply_count
like_count
recommend_to_others
averageSectionRating
}
}
}
Expand Down

0 comments on commit 6cc02b6

Please sign in to comment.