-
Notifications
You must be signed in to change notification settings - Fork 3k
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
Worked on the feature to update group title #6047
Worked on the feature to update group title #6047
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice! some small comments then i think this is good to go
String tagUrn = _entityClient.ingestProposal(proposal, context.getAuthentication()); | ||
OwnerUtils.addCreatorAsOwner(context, tagUrn, OwnerEntityType.CORP_USER, OwnershipType.TECHNICAL_OWNER, _entityService); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you can change tagUrn
-> domainUrn
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Checked and Fixed!!
String tagUrn = _entityClient.ingestProposal(proposal, context.getAuthentication()); | ||
OwnerUtils.addCreatorAsOwner(context, tagUrn, OwnerEntityType.CORP_USER, OwnershipType.TECHNICAL_OWNER, _entityService); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same, tagUrn
-> glossaryNodeUrn
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Checked and Fixed!!
String tagUrn = _entityClient.ingestProposal(proposal, context.getAuthentication()); | ||
OwnerUtils.addCreatorAsOwner(context, tagUrn, OwnerEntityType.CORP_USER, OwnershipType.TECHNICAL_OWNER, _entityService); | ||
return tagUrn; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tagUrn
-> glossaryTermUrn
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Checked and Fixed!!
@@ -91,6 +103,29 @@ export default function GroupInfoSidebar({ sideBarData, refetch }: Props) { | |||
/* eslint-disable @typescript-eslint/no-unused-vars */ | |||
const [editGroupModal, showEditGroupModal] = useState(false); | |||
const canEditGroup = true; // TODO; Replace this will fine-grained understanding of user permissions. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can you update this to reflect our permissions? you can do something like
const me = useGetAuthenticatedUser();
const canEditGroup = me?.platformPrivileges.manageIdentities;
and then can you add a check to ensure that they have these permissions before making the name editable?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Checked and Fixed!!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looking good! the comments I have are around the functionality change fro DeprecationPill.
In the future, when you have separate projects can you put them in separate PRs? for example, your work on editing group names and adding owners on creation of terms, nodes, and domains is done, but now it's intermingled with your new deprecation pill work.
<GroupTitle level={3} editable={{ onChange: handleTitleUpdate }}> | ||
{groupTitle} | ||
</GroupTitle> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can you use the new canEditGroup
to make it so they can't edit the name if they can't edit the group? check below for the aboutText
where we say editable={canEditGroup ? { onChange: onSaveAboutMe } : false}
as an example
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Checked and Fixed!!
Sure. For the next time onward I'll definitely create a new PR for each task.
)} | ||
{isDividerNeeded && <ThinDivider />} | ||
<Button | ||
type="default" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Checked and Fixed!!
@@ -56,11 +57,14 @@ const StyledInfoCircleOutlined = styled(InfoCircleOutlined)` | |||
`; | |||
|
|||
type Props = { | |||
urns: Array<string>; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
while the mutation below is batch, I think this pill is only relevant to one entity at a time, so I think this can be a singular urn
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Checked and Fixed!!
}) | ||
} | ||
> | ||
Mark as un-deprecated |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I also don't think we want this button to be shown every time we show this pill. ie. we don't want them to be able to undeprecate from the search results page so DefaultPrevieCard
instances of this pill shouldn't show this button.
What do you think about adding a new optional prop called showUndeprecate
that will show this button if you pass it in?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Checked and Fixed!!
<LastEvaluatedAtLabel>{decommissionTimeLocal}</LastEvaluatedAtLabel> | ||
</Tooltip> | ||
</Typography.Text> | ||
<> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think you need these extra fragments around the decommission time piece
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nice!
you're getting failing tests on Check out |
@@ -10,7 +10,7 @@ | |||
import com.linkedin.metadata.Constants; | |||
import com.linkedin.metadata.key.GlossaryTermKey; | |||
import com.linkedin.metadata.utils.GenericRecordUtils; | |||
import com.linkedin.mxe.MetadataChangeProposal; | |||
gitimport com.linkedin.mxe.MetadataChangeProposal; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
gotta remove the "git" here as that's causing a failing build
Checklist