Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add osm profile link to mapper column in task tables #2487

Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 16 additions & 6 deletions src/components/TaskAnalysisTable/TaskAnalysisTable.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ import AsManager from '../../interactions/User/AsManager'
import AsColoredHashable from '../../interactions/Hashable/AsColoredHashable'
import WithLoadedTask from '../HOCs/WithLoadedTask/WithLoadedTask'
import WithConfigurableColumns from '../HOCs/WithConfigurableColumns/WithConfigurableColumns'
import WithTargetUser from '../../components/HOCs/WithTargetUser/WithTargetUser'
import { intlTableProps } from '../../components/IntlTable/IntlTable'
import ViewTask from '../ViewTask/ViewTask'
import SvgSymbol from '../SvgSymbol/SvgSymbol'
Expand Down Expand Up @@ -515,7 +516,14 @@ const setupColumnTypes = (props, taskBaseRoute, manager, data, openComments) =>
className="row-user-column"
style={{color: AsColoredHashable(_get(row._original.completedBy, 'username') || row._original.completedBy).hashColor}}
>
{_get(row._original.completedBy, 'username') || row._original.completedBy}
<a
className="mr-mx-4"
href={props.targetUserOSMProfileUrl()}
target='_blank'
rel="noopener noreferrer"
>
{_get(row._original.completedBy, 'username') || row._original.completedBy}
</a>
</div>
),
}
Expand Down Expand Up @@ -792,10 +800,12 @@ TaskAnalysisTableInternal.propTypes = {
}

export default injectIntl(
WithConfigurableColumns(
TaskAnalysisTableInternal,
ALL_COLUMNS,
DEFAULT_COLUMNS,
messages
WithTargetUser(
WithConfigurableColumns(
TaskAnalysisTableInternal,
ALL_COLUMNS,
DEFAULT_COLUMNS,
messages
)
)
)