Skip to content

Commit

Permalink
Merge branch 'dev' into illia-rudniev/feat/kyb-new-collection-flow2
Browse files Browse the repository at this point in the history
  • Loading branch information
alonp99 committed Aug 10, 2023
2 parents 050d5e1 + 18f0f5f commit 227afc8
Show file tree
Hide file tree
Showing 6 changed files with 78 additions and 3 deletions.
43 changes: 43 additions & 0 deletions apps/backoffice-v2/src/common/components/atoms/icons/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -454,3 +454,46 @@ export const PhotoSvg = (props: SVGProps<SVGSVGElement>) => {
</svg>
);
};

export const NoCasesSvg = (props: SVGProps<SVGSVGElement>) => (
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 96 81" fill="none" {...props}>
<circle cx="45.8955" cy="42" r="39" fill="#D9D9D9" />
<path
d="M64.9549 27.3496H25.8361C23.9378 27.3496 22.1013 28.0247 20.6549 29.2541L2.89551 44.3496V67.5H87.8955V44.3496L70.1361 29.2541C68.6897 28.0247 66.8532 27.3496 64.9549 27.3496Z"
fill="#E7E7E7"
/>
<path
d="M87.8955 44.3496L70.1361 29.2541C68.6897 28.0247 66.8532 27.3496 64.9549 27.3496H25.8361C23.9378 27.3496 22.1013 28.0247 20.6549 29.2541L2.89551 44.3496"
stroke="black"
strokeWidth="2"
/>
<path
d="M1.89551 47C1.89551 44.7909 3.68637 43 5.89551 43H18.1336C21.028 43 23.7804 44.2541 25.6796 46.4382L29.1022 50.3741C31.3813 52.9951 34.6842 54.5 38.1574 54.5H52.6336C56.1068 54.5 59.4097 52.9951 61.6888 50.3741L65.1114 46.4382C67.0106 44.2541 69.763 43 72.6574 43H84.8955C87.1046 43 88.8955 44.7909 88.8955 47V64C88.8955 66.2091 87.1046 68 84.8955 68H5.89551C3.68637 68 1.89551 66.2091 1.89551 64V47Z"
fill="white"
stroke="black"
strokeWidth="2"
/>
<path
d="M73.8955 38C81.1492 36.6795 90.4869 28.6125 85.2113 20.2091C81.1492 13.7387 71.7109 17.4116 75.9266 24.0326C79.1106 29.0334 88.9059 25.3056 90.6338 17.1607M89.2736 8C89.5981 8.67957 89.8695 9.34662 90.0916 10M90.7924 13C90.8134 13.1679 90.8311 13.3345 90.8455 13.5"
stroke="black"
strokeWidth="2"
strokeLinecap="round"
/>
<circle
cx="86.2744"
cy="3.41506"
r="2.5"
transform="rotate(-30 86.2744 3.41506)"
fill="black"
/>
<ellipse cx="91.6045" cy="2.64648" rx="3.5" ry="1.5" fill="black" />
<ellipse
cx="82.9445"
cy="7.64665"
rx="3.5"
ry="1.5"
transform="rotate(-60 82.9445 7.64665)"
fill="black"
/>
</svg>
);
32 changes: 30 additions & 2 deletions apps/backoffice-v2/src/pages/Entities/Entities.page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import { useEntities } from './hooks/useEntities/useEntities';
import { Case } from '../Entity/components/Case/Case';
import { MotionScrollArea } from '../../common/components/molecules/MotionScrollArea/MotionScrollArea';
import { FunctionComponent } from 'react';
import { NoCasesSvg } from '../../common/components/atoms/icons';

export const Entities: FunctionComponent = () => {
const {
Expand Down Expand Up @@ -70,8 +71,35 @@ export const Entities: FunctionComponent = () => {
</Case>
)}
{Array.isArray(cases) && !cases.length && !isLoading ? (
<div className={`p-2`}>
<h2 className={`mt-4 text-6xl`}>No cases were found</h2>
<div className="flex items-center justify-center border-l-[1px] p-4">
<div className="inline-flex flex-col items-start gap-4 rounded-md border-[1px] border-[#CBD5E1] p-6">
<div className="flex w-[464px] items-center justify-center">
<NoCasesSvg width={96} height={81} />
</div>

<div className="flex w-[464px] flex-col items-start gap-2">
<h2 className="text-lg font-[600]">No cases found</h2>

<div className="text-sm leading-[20px]">
<p className="font-[400]">
It looks like there aren&apos;t any cases in your queue right now.
</p>

<div className="mt-[20px] flex flex-col">
<span className="font-[700]">What can you do now?</span>

<ul className="list-disc pl-6 pr-2">
<li>Make sure to refresh or check back often for new cases.</li>
<li>Ensure that your filters aren&apos;t too narrow.</li>
<li>
If you suspect a technical issue, reach out to your technical team to diagnose
the issue.
</li>
</ul>
</div>
</div>
</div>
</div>
</div>
) : (
<Outlet />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ export class DocumentChangedWebhookCaller {
this.configService.get('NODE_ENV'),
this.configService.get('WEBHOOK_URL'),
this.configService.get('WEBHOOK_SECRET'),
'workflow.context.document.changed',
);

if (!url) {
Expand Down
3 changes: 2 additions & 1 deletion services/workflows-service/src/events/get-webhook-info.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,11 @@ export const getWebhookInfo = (
NODE_ENV: string | undefined,
WEBHOOK_URL: string | undefined,
WEBHOOK_SECRET: string | undefined,
event: string,
) => {
const id = randomUUID();
const environment = NODE_ENV;
const url = getDynamicWebhookUrl(config, 'workflow.context.document.changed') || WEBHOOK_URL;
const url = getDynamicWebhookUrl(config, event) || WEBHOOK_URL;
const authSecret = WEBHOOK_SECRET;

return { id, environment, url, authSecret, apiVersion: packageJson.version };
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ export class WorkflowCompletedWebhookCaller {
this.configService.get('NODE_ENV'),
this.configService.get('WEBHOOK_URL'),
this.configService.get('WEBHOOK_SECRET'),
'workflow.completed',
);

if (!url) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ export class WorkflowStateChangedWebhookCaller {
this.configService.get('NODE_ENV'),
this.configService.get('WEBHOOK_URL'),
this.configService.get('WEBHOOK_SECRET'),
'workflow.state.changed',
);

if (!url) {
Expand Down

0 comments on commit 227afc8

Please sign in to comment.