From a07438f6e3d04e9cc670e92a44b1845bb8370a7e Mon Sep 17 00:00:00 2001 From: nkdengineer Date: Mon, 8 Apr 2024 15:52:30 +0700 Subject: [PATCH 1/6] fix: message next steps --- src/libs/NextStepUtils.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libs/NextStepUtils.ts b/src/libs/NextStepUtils.ts index 8b0afe2d24c3..7146c6253e26 100644 --- a/src/libs/NextStepUtils.ts +++ b/src/libs/NextStepUtils.ts @@ -102,7 +102,7 @@ function buildNextStep( text: 'Waiting for ', }, { - text: 'you', + text: managerDisplayName, type: 'strong', }, { From a8429942d2896c79e47ef0f3d1e2276eb0f4192c Mon Sep 17 00:00:00 2001 From: nkdengineer Date: Tue, 9 Apr 2024 00:06:12 +0700 Subject: [PATCH 2/6] fix: add self review --- src/libs/NextStepUtils.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/libs/NextStepUtils.ts b/src/libs/NextStepUtils.ts index 7146c6253e26..d42babc4af6f 100644 --- a/src/libs/NextStepUtils.ts +++ b/src/libs/NextStepUtils.ts @@ -213,7 +213,7 @@ function buildNextStep( text: ' is waiting for ', }, { - text: 'you', + text: managerDisplayName, type: 'strong', }, { @@ -230,7 +230,7 @@ function buildNextStep( }; // Self review & another reviewer - if (isOwner) { + if (!isSelfApproval) { optimisticNextStep.message = [ { text: 'Waiting for ', From e3dcd852dd89f548ac27dd3788257e24d36007fd Mon Sep 17 00:00:00 2001 From: nkdengineer Date: Tue, 9 Apr 2024 00:12:09 +0700 Subject: [PATCH 3/6] remove useless code --- src/libs/NextStepUtils.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libs/NextStepUtils.ts b/src/libs/NextStepUtils.ts index d42babc4af6f..ede9746c6314 100644 --- a/src/libs/NextStepUtils.ts +++ b/src/libs/NextStepUtils.ts @@ -102,7 +102,7 @@ function buildNextStep( text: 'Waiting for ', }, { - text: managerDisplayName, + text: 'you', type: 'strong', }, { From 81c4ea9c6cb86efeb5d317dda29ac0434fac3d04 Mon Sep 17 00:00:00 2001 From: nkdengineer Date: Tue, 9 Apr 2024 09:48:35 +0700 Subject: [PATCH 4/6] remove useless code --- src/libs/NextStepUtils.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libs/NextStepUtils.ts b/src/libs/NextStepUtils.ts index ede9746c6314..ea8c8b71e0c1 100644 --- a/src/libs/NextStepUtils.ts +++ b/src/libs/NextStepUtils.ts @@ -289,7 +289,7 @@ function buildNextStep( text: 'Waiting for ', }, { - text: managerDisplayName, + text: 'you', type: 'strong', }, { From a4998225cea10eb456724ec386af536816ef8691 Mon Sep 17 00:00:00 2001 From: nkdengineer Date: Tue, 9 Apr 2024 09:50:58 +0700 Subject: [PATCH 5/6] Change optimistic next step --- src/libs/NextStepUtils.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/libs/NextStepUtils.ts b/src/libs/NextStepUtils.ts index ea8c8b71e0c1..1b57f6aa0526 100644 --- a/src/libs/NextStepUtils.ts +++ b/src/libs/NextStepUtils.ts @@ -213,7 +213,7 @@ function buildNextStep( text: ' is waiting for ', }, { - text: managerDisplayName, + text: 'you', type: 'strong', }, { @@ -289,7 +289,7 @@ function buildNextStep( text: 'Waiting for ', }, { - text: 'you', + text: managerDisplayName, type: 'strong', }, { From d7fcc276318523a2a157a6002e41b683effc448c Mon Sep 17 00:00:00 2001 From: nkdengineer Date: Tue, 16 Apr 2024 17:50:57 +0700 Subject: [PATCH 6/6] Fix case approver approves yourself --- src/libs/NextStepUtils.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libs/NextStepUtils.ts b/src/libs/NextStepUtils.ts index d522a64740eb..3b8fce748f45 100644 --- a/src/libs/NextStepUtils.ts +++ b/src/libs/NextStepUtils.ts @@ -230,7 +230,7 @@ function buildNextStep( }; // Self review & another reviewer - if (!isSelfApproval) { + if (!isSelfApproval || (isSelfApproval && isOwner)) { optimisticNextStep.message = [ { text: 'Waiting for ',