Open rajdip-b opened 3 weeks ago
@kriptonian1 looks good?
Yeap
/attempt
Assigned the issue to @Tirthchoksi22!
@rajdip-b Hey I am participating Foss Hack so should i made the PR right now or during the hackathon ??
Hey buddy! We already have a few PRs related to the hackathon. As per the guidelines, the hackathon hours are the best for it. But if you want to, you can also make the PR now.
But, we won't be able to merge them before the timeline!
@rajdip-b Hey I have made the PR pls review it
@rajdip-b Volunteer of the foss hacks are saying that the PR commits at the time of hackathons will only be considered for evaluation so what should I do now as I have made the commit already
You can take down the PR! No worries about that. Alternatively, you can also ask them about what can be done.
If they are looking at the commit timeline, I would say you can redo this entire commit once again in the hackathon window.
@Tirthchoksi22 could you please join our Discord channel aswell? We have quite a few active FOSS contributors over there, so we can discuss this problem :)
You can take down the PR! No worries about that. Alternatively, you can also ask them about what can be done.
If they are looking at the commit timeline, I would say you can redo this entire commit once again in the hackathon window.
@rajdip-b they are looking at the commit timeline so better I take down the PR but before that pls review it tell me the change so at the hackathon time I can just directly commit with the changes
You can take down the PR! No worries about that. Alternatively, you can also ask them about what can be done. If they are looking at the commit timeline, I would say you can redo this entire commit once again in the hackathon window.
@rajdip-b they are looking at the commit timeline so better I take down the PR but before that pls review it tell me the change so at the hackathon time I can just directly commit with the changes
Yeap! That's underway :)
Okay look, about the PR:
globalSearch
under the workspace service would be enough imo. Then, you can use prisma to query for everything. If you go through our permission structure, you would find that there is an AuthorityChecker
class that does all the heavylifting of RBAC. So in this case, you would need to do the following:
READ_WORKSPACE
, READ_PROJECT
, READ_ENVIRONMENT
, READ_SECRET
and READ_VARIABLE
project -> authorities[]
entry, check if for a project, READ_WORKSPACE
, READ_PROJECT
, READ_ENVIRONMENT
, READ_SECRET
and READ_VARIABLE
exist in its allowed authorities. If yes, keep the project, if no, remove the project from this entry list.project
field to only select entities if the project.id
is in some
of the previously calculated project list.so i dont have to write seperate methods in project service but for this i have to make indiviual methods like getprojects
in workspace.service itself and same with the other three. will it be fine than?
so i dont have to write seperate methods in project service but for this i have to make indiviual methods like
getprojects
in workspace.service itself and same with the other three. will it be fine than?
Yeap that would be correct.
Description
Given a certain workspace, we would like to search the following items by partial name or note/description:
Also note, we would only like to display the items that the user has access to.
Solution
workspace.controller.ts
with the path/:workspaceId/global-search/:searchTerm
searchTerm
would be a non-null string fieldprojects
,environments
,secrets
,variables
whose name resemble with the search term.