Skip to content

Commit

Permalink
Merge pull request #294 from openedx/ahtesham/van-1832
Browse files Browse the repository at this point in the history
fix: replace username with full name in the learner record title
  • Loading branch information
ahtesham-quraish authored Apr 4, 2024
2 parents 323ea5d + 22c4c9c commit 4445fe3
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 11 deletions.
22 changes: 12 additions & 10 deletions src/components/ProgramRecord/ProgramRecordHeader.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -77,15 +77,18 @@ function ProgramRecordHeader({
</span>
</div>
<div className="learner-info my-3">
<FormattedMessage
id="learner.username"
defaultMessage="{username}"
description="Username of the learner"
values={{
username: learner.username,
}}
/>
|
{
learner.full_name && (
<FormattedMessage
id="learner.full_name"
defaultMessage="{full_name} | "
description="Full name of the learner"
values={{
full_name: learner.full_name,
}}
/>
)
}
<FormattedMessage
id="learner.email"
defaultMessage="{email}"
Expand All @@ -103,7 +106,6 @@ ProgramRecordHeader.propTypes = {
learner: PropTypes.shape({
email: PropTypes.string,
full_name: PropTypes.string,
username: PropTypes.string,
}).isRequired,
program: PropTypes.shape({
name: PropTypes.string,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { Factory } from 'rosie'; // eslint-disable-line import/no-extraneous-dep
export default Factory.define('program_record_details')
.attr('record', {
learner: {
full_name: '',
full_name: 'test',
username: 'edx',
email: '[email protected]',
},
Expand Down

0 comments on commit 4445fe3

Please sign in to comment.