From 9b0a11d33061e7cf4acc3221b1c5c8876ff91ce7 Mon Sep 17 00:00:00 2001 From: wrigh393 Date: Mon, 8 Feb 2021 09:20:45 -0500 Subject: [PATCH 1/9] Updated ItemTable docs props and the library that is being used for the table --- src/components/ItemTable/ItemTable.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/components/ItemTable/ItemTable.md b/src/components/ItemTable/ItemTable.md index 6e5544b..a98953a 100644 --- a/src/components/ItemTable/ItemTable.md +++ b/src/components/ItemTable/ItemTable.md @@ -1,6 +1,6 @@ The ItemTable is the primary view for webqueue2. It displays item metadata for items of selected queues and allows for filtering by field and opening an item by clicking. Items are passed in as a required parameter. It is to be used with the [ItemTableAppBar](/#/Components/ItemTableAppBar). -It is based on [material-table](https://material-table.com/). +It is based on [react-table](https://react-table.tanstack.com/). ```jsx import React, { useState, useEffect } from "react"; @@ -17,9 +17,9 @@ useEffect(() => { }, []); - + ``` ```jsx static - + ``` \ No newline at end of file From ecc31059304ff85d9089c81927dd74a017900e37 Mon Sep 17 00:00:00 2001 From: wrigh393 Date: Mon, 8 Feb 2021 09:21:20 -0500 Subject: [PATCH 2/9] Removed duplicate columns in ItemTable --- src/components/ItemTable/ItemTable.js | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/components/ItemTable/ItemTable.js b/src/components/ItemTable/ItemTable.js index d94dc72..ea43466 100644 --- a/src/components/ItemTable/ItemTable.js +++ b/src/components/ItemTable/ItemTable.js @@ -52,10 +52,7 @@ export default function ItemTable({ data, rowCanBeSelected }) { { Header: 'Department', accessor: 'department' }, { Header: 'Building', accessor: 'building' }, { Header: 'Date Received', accessor: 'dateReceived', sortInverted: true, Cell: ({ value }) => }, - { Header: 'Last Updated', accessor: 'lastUpdated', }, - { Header: 'Department', accessor: 'department' }, - { Header: 'Building', accessor: 'building' }, - { Header: 'Date Received', accessor: 'dateReceived', }, + ], []); const tableInstance = useTable( { From 86230719b31aa4b63336ed5b40c8aaec6dd7ab9a Mon Sep 17 00:00:00 2001 From: wrigh393 Date: Mon, 8 Feb 2021 09:23:58 -0500 Subject: [PATCH 3/9] Updated ItemHeaderView docs to show the proper library that is being used for the component --- .../ItemHeaderView/ItemHeaderView.md | 23 +++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/src/components/ItemHeaderView/ItemHeaderView.md b/src/components/ItemHeaderView/ItemHeaderView.md index e69de29..654ed00 100644 --- a/src/components/ItemHeaderView/ItemHeaderView.md +++ b/src/components/ItemHeaderView/ItemHeaderView.md @@ -0,0 +1,23 @@ +The ItemHeader displays item metadata for items of selected queues and allows for filtering by field and opening an item by clicking. Items are passed in as a required parameter. It is to be used with the [ItemTableAppBar](/#/Components/ItemTableAppBar). + +It is based on [react-table](https://react-table.tanstack.com/). +```jsx +import React, { useState, useEffect } from "react"; + + +const [itemData, setItemData] = useState([]); + +const testItems = [{"queue": "ce", "number": 9, "lastUpdated": "09-11-20 12:14 PM", "isLocked": false, "userEmail": "lslusher@purdue.edu", "userName": "Slusher, Laura M", "userAlias": "lslusher", "assignedTo": "bekuma", "subject": "RE: New laptop", "status": "waiting on reply/time to call", "priority": "deploy", "department": "che", "building": "frny", "dateReceived": "2020-03-12T18:07:27+0000"}, {"queue": "ce", "number": 42, "lastUpdated": "09-11-20 12:14 PM", "isLocked": false, "userEmail": "feng293@purdue.edu", "userName": "", "userAlias": "feng293", "assignedTo": "schmid22", "subject": "Upgrade system and Abaqus", "status": "", "priority": "", "department": "", "building": "", "dateReceived": "2020-05-14T10:21:32-0400"}, {"queue": "ce", "number": 51, "lastUpdated": "09-11-20 12:14 PM", "isLocked": false, "userEmail": "jclauso@purdue.edu", "userName": "", "userAlias": "jclauso", "assignedTo": "schmid22", "subject": "ECN privileges for future grad student", "status": "Waiting for reply", "priority": "", "department": "", "building": "", "dateReceived": "2020-05-14T15:03:07-0400"}]; + + +useEffect(() => { + + setItemData(testItems) + +}, []); + + +``` +```jsx static + +``` \ No newline at end of file From 6229c48fbed9ad51caac1a64f1d779a912fa324e Mon Sep 17 00:00:00 2001 From: wrigh393 Date: Mon, 8 Feb 2021 10:01:11 -0500 Subject: [PATCH 4/9] Changed styling of ItemViewAppBar to fix how its displayed in the docs --- src/components/ItemViewAppBar/ItemViewAppBar.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/components/ItemViewAppBar/ItemViewAppBar.js b/src/components/ItemViewAppBar/ItemViewAppBar.js index 0dc081f..aa243b3 100644 --- a/src/components/ItemViewAppBar/ItemViewAppBar.js +++ b/src/components/ItemViewAppBar/ItemViewAppBar.js @@ -21,8 +21,7 @@ export default function ItemViewAppBar({ title, setSidebarOpen }){ flexGrow: "1" }, appBarRoot: { - width: "inherit", - + width: "100%" }, })); const classes = useStyles(theme); @@ -31,7 +30,7 @@ export default function ItemViewAppBar({ title, setSidebarOpen }){ return( <> - + Date: Mon, 8 Feb 2021 10:02:01 -0500 Subject: [PATCH 5/9] Updated the props to thier current names. --- src/components/QueueSelector/QueueSelector.md | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/components/QueueSelector/QueueSelector.md b/src/components/QueueSelector/QueueSelector.md index ea505eb..5b515f8 100644 --- a/src/components/QueueSelector/QueueSelector.md +++ b/src/components/QueueSelector/QueueSelector.md @@ -22,6 +22,7 @@ const queues = [ } ]; + const useStyles = makeStyles({ root: { padding: "16px", @@ -30,9 +31,11 @@ const useStyles = makeStyles({ const classes = useStyles(); - + ``` ```jsx static - + + ``` \ No newline at end of file From ad09aca72db5fedce5fd870c1de921f17a3e0402 Mon Sep 17 00:00:00 2001 From: wrigh393 Date: Mon, 8 Feb 2021 15:09:34 -0500 Subject: [PATCH 6/9] Updated TeamMemberCard docs to give a accurate summary of the component. --- src/components/TeamMemberCard/TeamMemberCard.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/components/TeamMemberCard/TeamMemberCard.md b/src/components/TeamMemberCard/TeamMemberCard.md index 1554351..2a4ce00 100644 --- a/src/components/TeamMemberCard/TeamMemberCard.md +++ b/src/components/TeamMemberCard/TeamMemberCard.md @@ -1,4 +1,6 @@ -The ItemTable is the primary view for webqueue2. It displays item metadata for items of selected queues and allows for filtering by field and opening an item by clicking. By default, it is pre-configured to fetch data from the webqueue2 API. +The TeamMemberCard is used to give a quick summary on people that have worked on webqueue2. It displays a image of the team member, the person's first and last name, a brief professional summary, and a link to their personal portfolio(if applicable). + +If no image is provided the profile image is replaced with the first initial of the team memebers first name. ```jsx import React, { useState } from "react"; From 53c34bafaef586bb9cc732c9196dc358e8d30510 Mon Sep 17 00:00:00 2001 From: wrigh393 Date: Mon, 8 Feb 2021 15:18:20 -0500 Subject: [PATCH 7/9] Update AuthProvider docs with a description of components function --- src/components/AuthProvider/AuthProvider.md | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) diff --git a/src/components/AuthProvider/AuthProvider.md b/src/components/AuthProvider/AuthProvider.md index aad5bee..a5a9be9 100644 --- a/src/components/AuthProvider/AuthProvider.md +++ b/src/components/AuthProvider/AuthProvider.md @@ -1,14 +1 @@ -AuthProvider - -Description - ---- - -```jsx -import AuthProvider from "./AuthProvider"; - - -``` -```jsx static - -``` \ No newline at end of file +The AuthProvider component purpose is to give users access tokens on login and to refresh the tokens at set intervals of time. From 186be65ac6773d4533888557276593b22d16656c Mon Sep 17 00:00:00 2001 From: wrigh393 Date: Mon, 8 Feb 2021 15:21:59 -0500 Subject: [PATCH 8/9] More detailed explanation of the component in AuthProvider docs --- src/components/AuthProvider/AuthProvider.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/AuthProvider/AuthProvider.md b/src/components/AuthProvider/AuthProvider.md index a5a9be9..4da2b34 100644 --- a/src/components/AuthProvider/AuthProvider.md +++ b/src/components/AuthProvider/AuthProvider.md @@ -1 +1 @@ -The AuthProvider component purpose is to give users access tokens on login and to refresh the tokens at set intervals of time. +The AuthProvider component purpose is to give users access tokens on login and to refresh the tokens at set intervals of time. The users career account login information is used to determine if user can be authenticated. From 24f9efab404facd0554f5e38af53aab6540caf35 Mon Sep 17 00:00:00 2001 From: wrigh393 Date: Wed, 10 Feb 2021 14:23:23 -0500 Subject: [PATCH 9/9] Added ThemeProvider component to ItemBodyView docs to allow docs to properly display --- src/components/ItemBodyView/ItemBodyView.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/components/ItemBodyView/ItemBodyView.md b/src/components/ItemBodyView/ItemBodyView.md index 6a741ea..752987d 100644 --- a/src/components/ItemBodyView/ItemBodyView.md +++ b/src/components/ItemBodyView/ItemBodyView.md @@ -10,11 +10,18 @@ The ItemBodyView displays the seven actions possible in an item: ```jsx import ItemBodyView from "./ItemBodyView"; +import webqueue2Theme from "../../theme"; +import { ThemeProvider } from "@material-ui/core/styles"; + +const theme = webqueue2Theme(false); const demoItem = {"queue": "ce", "number": 100, "lastUpdated": "09-28-20 01:26 PM", "headers": [{"type": "Merged-Time", "content": "Tue, 23 Jun 2020 13:31:53 -0400"}, {"type": "Merged-By", "content": "campb303"}, {"type": "QTime", "content": "1"}, {"type": "QTime-Updated-Time", "content": "Tue, 23 Jun 2020 13:28:50 EDT"}, {"type": "QTime-Updated-By", "content": "campb303"}, {"type": "Time", "content": "1"}, {"type": "Time-Updated-Time", "content": "Tue, 23 Jun 2020 13:28:50 EDT"}, {"type": "Time-Updated-By", "content": "campb303"}, {"type": "Replied-Time", "content": "Tue, 23 Jun 2020 13:28:48 -0400"}, {"type": "Replied-By", "content": "campb303"}, {"type": "Edited-Time", "content": "Tue, 23 Jun 2020 13:27:56 -0400"}, {"type": "Edited-By", "content": "campb303"}, {"type": "QAssigned-To", "content": "campb303"}, {"type": "QAssigned-To-Updated-Time", "content": "Tue, 23 Jun 2020 13:27:00 EDT"}, {"type": "QAssigned-To-Updated-By", "content": "campb303"}, {"type": "Assigned-To", "content": "campb303"}, {"type": "Assigned-To-Updated-Time", "content": "Tue, 23 Jun 2020 13:27:00 EDT"}, {"type": "Assigned-To-Updated-By", "content": "campb303"}, {"type": "QStatus", "content": "Dont Delete"}, {"type": "QStatus-Updated-Time", "content": "Tue, 23 Jun 2020 13:26:55 EDT"}, {"type": "QStatus-Updated-By", "content": "campb303"}, {"type": "Status", "content": "Dont Delete"}, {"type": "Status-Updated-Time", "content": "Tue, 23 Jun 2020 13:26:55 EDT"}, {"type": "Status-Updated-By", "content": "campb303"}, {"type": "Date", "content": "Tue, 23 Jun 2020 13:25:51 -0400"}, {"type": "From", "content": "Justin Campbell "}, {"type": "Message-ID", "content": "<911CE050-3240-4980-91DD-9C3EBB8DBCF8@purdue.edu>"}, {"type": "Subject", "content": "Beepboop"}, {"type": "To", "content": "cesite@ecn.purdue.edu"}, {"type": "Content-Type", "content": "text/plain; charset=\"utf-8\""}, {"type": "X-ECN-Queue-Original-Path", "content": "/home/pier/e/queue/Attachments/inbox/2020-06-23/208-original.txt"}, {"type": "X-ECN-Queue-Original-URL", "content": "https://engineering.purdue.edu/webqueue/Attachments/inbox/2020-06-23/208-original.txt"}], "content": [{"type": "directory_information", "Name": "Heyi Feng", "Login": "feng293", "Computer": "civil4147pc2.ecn", "Location": "HAMP 4147", "Email": "feng293@purdue.edu", "Phone": "5039154835", "Office": "", "UNIX Dir": "None", "Zero Dir": "U=\\\\myhome.itap.purdue.edu\\myhome\\%username%", "User ECNDB": "http://eng.purdue.edu/jump/2e29495", "Host ECNDB": "http://eng.purdue.edu/jump/2eccc3f", "Subject": "Upgrade system and Abaqus"}, {"type": "assignment", "datetime": "2020-06-23T13:27:00-0400", "by": "campb303", "to": "campb303"}, {"type": "initial_message", "datetime": "2020-06-23T13:25:51-0400", "from_name": "Justin Campbell", "user_email": "campb303@purdue.edu", "to": [{"name": "", "email": "cesite@ecn.purdue.edu"}], "cc": [], "content": ["Testtest\n"]}, {"type": "status", "datetime": "2020-06-23T13:26:55", "by": "campb303", "content": ["Dont Delete\n"]}, {"type": "edit", "datetime": "2020-06-23T13:27:56", "by": "campb303", "content": ["This be an edit my boy\n"]}, {"type": "reply_to_user", "datetime": "2020-06-23T13:28:18", "by": "campb303", "content": ["This be a reply my son\n", "\n", "Justin\n", "ECN\n"]}, {"type": "reply_from_user", "datetime": "2020-06-23T13:30:45-0400", "from_name": "Justin Campbell", "from_email": "campb303@purdue.edu", "cc": [], "content": ["X-ECN-Queue-Original-Path: /home/pier/e/queue/Attachments/inbox/2020-06-23/212-original.txt\n", "X-ECN-Queue-Original-URL: https://engineering.purdue.edu/webqueue/Attachments/inbox/2020-06-23/212-original.txt\n", "\n", "Huzzah!\n"]}], "isLocked": "ce 100 is locked by knewell using qvi", "userEmail": "campb303@purdue.edu", "userName": "Justin Campbell", "userAlias": "campb303", "assignedTo": "campb303", "subject": "Beepboop", "status": "Dont Delete", "priority": "", "department": "", "building": "", "dateReceived": "2020-06-23T13:25:51-0400"}; + +
+
``` ```jsx static