From e93c6bb7eed35da354704c33c37516afb7f90756 Mon Sep 17 00:00:00 2001 From: "Arslan, Erdem" Date: Fri, 24 Nov 2023 00:19:11 +0100 Subject: [PATCH] [Entities] C1 Producer View Table - create and add data to the producer table --- pkgs/ui/src/app/client-1/page.tsx | 15 ++++++- pkgs/ui/src/mock/client_1/index.ts | 64 +++++++++++++++++++++++++++++- 2 files changed, 76 insertions(+), 3 deletions(-) diff --git a/pkgs/ui/src/app/client-1/page.tsx b/pkgs/ui/src/app/client-1/page.tsx index cb39bfc..4d74186 100644 --- a/pkgs/ui/src/app/client-1/page.tsx +++ b/pkgs/ui/src/app/client-1/page.tsx @@ -1,7 +1,13 @@ "use client"; import SummaryDetails from "@/components/summary_card"; -import { Client1SummaryDetails, Client1ConsumerData, Client1ConsumerTableConfig } from "@/mock/client_1"; +import { + Client1SummaryDetails, + Client1ConsumerData, + Client1ConsumerTableConfig, + Client1ProducerTableConfig, + Client1ProducerData +} from "@/mock/client_1"; import CustomTable from "@/components/table"; export default function Client1() { @@ -22,6 +28,13 @@ export default function Client1() { configuration={Client1ConsumerTableConfig} /> +
+

Producer View

+ +
); } diff --git a/pkgs/ui/src/mock/client_1/index.ts b/pkgs/ui/src/mock/client_1/index.ts index d374e38..fbbe0d5 100644 --- a/pkgs/ui/src/mock/client_1/index.ts +++ b/pkgs/ui/src/mock/client_1/index.ts @@ -48,10 +48,8 @@ export const Client1ConsumerData = [ "producer_did": "did:sov:test:0062", "network": "Test Network B", }, - ] - export const Client1ConsumerTableConfig = [ { key: "service_name", @@ -78,3 +76,65 @@ export const Client1ConsumerTableConfig = [ label: "Network" } ] + +export const Client1ProducerData = [ + { + "service_name": "Carlo's Printing", + "service_type": "3D Printing", + "end_point": "URL", + "usage": "C1(3), C3(4)", + "status": "DRAFT, REGISTERED", + "action": "Register, Deregister, Delete", + }, + { + "service_name": "Steve's Printing", + "service_type": "3D Printing", + "end_point": "URL", + "usage": "C1(3), C3(4)", + "status": "REGISTERED", + "action": "Create", + }, + { + "service_name": "Test Printing A", + "service_type": "3D Printing", + "end_point": "URL", + "usage": "C1(3), C3(4)", + "status": "DRAFT", + "action": "Register, Deregister", + }, + { + "service_name": "Test Printing B", + "service_type": "3D Printing", + "end_point": "URL", + "usage": "C1(3), C3(4)", + "status": "DRAFT, REGISTERED", + "action": "Delete, Create", + }, +] + +export const Client1ProducerTableConfig = [ + { + key: "service_name", + label: "Service name" + }, + { + key: "service_type", + label: "Service Type" + }, + { + key: "end_point", + label: "End Point" + }, + { + key: "usage", + label: "Usage" + }, + { + key: "status", + label: "Status" + }, + { + key: "action", + label: "Action" + } +] \ No newline at end of file