[WEB-1642] chore: mutating issue estimation_point when we delete the estimate point from the project (#4862)
* chore: mutating issue estimation_point when we delete the eatimate point from the project * chore: updated try catch * chore: updated removed issues length check on estimate delete
This commit is contained in:
parent
a06beaa312
commit
0b4faf7db2
1 changed files with 10 additions and 1 deletions
|
|
@ -273,10 +273,19 @@ export class Estimate implements IEstimate {
|
|||
newEstimatePointId ? { new_estimate_id: newEstimatePointId } : undefined
|
||||
);
|
||||
|
||||
const currentIssues = Object.values(this.store.issue.issues.issuesMap || {});
|
||||
if (currentIssues) {
|
||||
currentIssues.map((issue) => {
|
||||
if (issue.estimate_point === estimatePointId) {
|
||||
this.store.issue.issues.updateIssue(issue.id, { estimate_point: newEstimatePointId });
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
runInAction(() => {
|
||||
unset(this.estimatePoints, [estimatePointId]);
|
||||
});
|
||||
if (deleteEstimatePoint && deleteEstimatePoint.length > 0) {
|
||||
if (deleteEstimatePoint) {
|
||||
runInAction(() => {
|
||||
deleteEstimatePoint.map((estimatePoint) => {
|
||||
if (estimatePoint.id)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue