From 4f1a4dd0454514a95dbffb89b87109dd1b84fe85 Mon Sep 17 00:00:00 2001 From: victorAnumudu Date: Mon, 15 May 2023 21:16:18 +0100 Subject: [PATCH 1/4] Delete/Edit Btn Position Changed --- src/components/MyJobs/MyJobTable.jsx | 50 +++++++++++++++------------- 1 file changed, 26 insertions(+), 24 deletions(-) diff --git a/src/components/MyJobs/MyJobTable.jsx b/src/components/MyJobs/MyJobTable.jsx index ec54677..968d393 100644 --- a/src/components/MyJobs/MyJobTable.jsx +++ b/src/components/MyJobs/MyJobTable.jsx @@ -62,33 +62,35 @@ export default function MyJobTable({MyJobList, className }) { currentJobList.map((value, index) => ( -
-
- data -
-
-

- {value.title} -

-
- {value.description} +
+
+
+ data
- - Price: {value.price*0.01} - - - Duration: {value.timeline_days} day(s) - +
+

+ {value.title} +

+
+ {value.description} +
+ + Price: {value.price*0.01} + + + Duration: {value.timeline_days} day(s) + +
-
-
-
- | + +
+ + |
From 5fd39409118a8fdeb84ce85521b0198163c4797a Mon Sep 17 00:00:00 2001 From: victorAnumudu Date: Mon, 15 May 2023 21:39:07 +0100 Subject: [PATCH 2/4] Fixed broken link on active job view button --- src/components/jobPopout/ActiveJobsPopout.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/jobPopout/ActiveJobsPopout.jsx b/src/components/jobPopout/ActiveJobsPopout.jsx index 21ea57b..01c041d 100644 --- a/src/components/jobPopout/ActiveJobsPopout.jsx +++ b/src/components/jobPopout/ActiveJobsPopout.jsx @@ -66,7 +66,7 @@ function ActiveJobsPopout({details, onClose, situation}) {
From 7e0f19212f17b66cbb0cfcf04f929a9aa127a7e5 Mon Sep 17 00:00:00 2001 From: Ebube Date: Tue, 16 May 2023 00:58:43 +0100 Subject: [PATCH 3/4] manage pop up --- src/components/MyWallet/WalletHeader.jsx | 352 ++++++++++++----------- src/components/Partials/Header.jsx | 14 +- 2 files changed, 195 insertions(+), 171 deletions(-) diff --git a/src/components/MyWallet/WalletHeader.jsx b/src/components/MyWallet/WalletHeader.jsx index 5cfa5a3..40fa543 100644 --- a/src/components/MyWallet/WalletHeader.jsx +++ b/src/components/MyWallet/WalletHeader.jsx @@ -1,4 +1,4 @@ -import {Link} from 'react-router-dom' +import { Link, useLocation, useNavigate } from "react-router-dom"; import Icons from "../Helpers/Icons"; import bank1 from "../../assets/images/bank-1.png"; import bank2 from "../../assets/images/bank-2.png"; @@ -8,180 +8,194 @@ import Accordion from "../Helpers/Accordion"; export default function WalletHeader(props) { // debugger; - //props.myWalletList.result_list - return ( - <> -
-
props.handlerBalance()} - className="flex items-center lg:justify-between justify-center w-full h-full" - > - - - -

- Wallet -

- - - -
-
-
-

- Wallet -

+ //props.myWalletList.result_list + let { pathname } = useLocation(); + let navigate = useNavigate(); + return ( + <> +
+
props.handlerBalance()} + className="flex items-center lg:justify-between justify-center w-full h-full" + > + + + +

Wallet

+ + + +
+
+
+

+ Wallet +

+
+
+
    + {props.myWalletList && + props.myWalletList?.result_list?.length > 0 && + props.myWalletList.result_list.map((value, index) => ( +
  • +
    +
    +
    + +
    +
    +

    + {value.description} +

    +
    +
    +
    +

    + {(value.amount * 0.01).toFixed(2)} {value.code} +

    +

    + {/*(773.69 USD)*/} +

    +
    -
    -
      + + ))} - {props.myWalletList && - props.myWalletList?.result_list?.length > 0 && - props.myWalletList.result_list.map((value, index) => ( -
    • -
      -
      -
      - -
      -
      -

      - {value.description} -

      -
      -
      -
      -

      - {(value.amount*0.01).toFixed(2)} {value.code} -

      -

      - {/*(773.69 USD)*/} -

      -
      -
      -
    • - ))} - - {/*
    • */} - {/*
      */} - {/*
      */} - {/* */} - {/* */} - {/*
      */} - {/*
      */} - {/*

      */} - {/* MetaMask*/} - {/*

      */} - {/*
      */} - {/*
      */} - {/*
      */} - {/*

      */} - {/* 75,320 ETH*/} - {/*

      */} - {/*

      */} - {/* (773.69 USD)*/} - {/*

      */} - {/*
      */} - {/*
    */} - {/*
  • */} - {/*
  • */} - {/*
    */} - {/*
    */} - {/* */} - {/* */} - {/*
    */} - {/*
    */} - {/*

    */} - {/* Coinbase Wallet*/} - {/*

    */} - {/*
    */} - {/*
    */} - {/*
    */} - {/*

    */} - {/* 56,124 ETH*/} - {/*

    */} - {/*

    */} - {/* (773.69 USD)*/} - {/*

    */} - {/*
    */} - {/*
*/} - {/**/} - {/*
  • */} - {/*
    */} - {/*
    */} - {/* */} - {/* */} - {/*
    */} - {/*
    */} - {/*

    */} - {/* Bitski*/} - {/*

    */} - {/*
    */} - {/*
    */} - {/*
    */} - {/*

    */} - {/* 99,123 ETH*/} - {/*

    */} - {/*

    */} - {/* (773.69 USD)*/} - {/*

    */} - {/*
    */} - {/*
  • */} - {/**/} - {/*
  • */} - {/*
    */} - {/*
    */} - {/* */} - {/* */} - {/*
    */} - {/*
    */} - {/*

    */} - {/* WalletConnect*/} - {/*

    */} - {/*
    */} - {/*
    */} - {/*
    */} - {/*

    */} - {/* 43,728 ETH*/} - {/*

    */} - {/*

    */} - {/* (773.69 USD)*/} - {/*

    */} - {/*
    */} - {/*
  • */} - {/**/} - -
    - {/*
    */} + {/**/} + {/*
  • */} + {/*
    */} + {/*
    */} + {/* */} + {/* */} + {/*
    */} + {/*
    */} + {/*

    */} + {/* Coinbase Wallet*/} + {/*

    */} + {/*
    */} + {/*
    */} + {/*
    */} + {/*

    */} + {/* 56,124 ETH*/} + {/*

    */} + {/*

    */} + {/* (773.69 USD)*/} + {/*

    */} + {/*
    */} + {/*
  • */} + {/**/} + {/*
  • */} + {/*
    */} + {/*
    */} + {/* */} + {/* */} + {/*
    */} + {/*
    */} + {/*

    */} + {/* Bitski*/} + {/*

    */} + {/*
    */} + {/*
    */} + {/*
    */} + {/*

    */} + {/* 99,123 ETH*/} + {/*

    */} + {/*

    */} + {/* (773.69 USD)*/} + {/*

    */} + {/*
    */} + {/*
  • */} + {/**/} + {/*
  • */} + {/*
    */} + {/*
    */} + {/* */} + {/* */} + {/*
    */} + {/*
    */} + {/*

    */} + {/* WalletConnect*/} + {/*

    */} + {/*
    */} + {/*
    */} + {/*
    */} + {/*

    */} + {/* 43,728 ETH*/} + {/*

    */} + {/*

    */} + {/* (773.69 USD)*/} + {/*

    */} + {/*
    */} + {/*
  • */} + {/**/} + +
    + {/* */} - Manage -
    -
    -
    + { + if (pathname == "/my-wallet") + props.setBalanceDropdown.toggle(); + else navigate("/my-wallet", { replace: true }); + }} + className="w-[122px] h-11 flex justify-center items-center btn-gradient text-base rounded-full text-white" + > + Manage +
    - {/**/} - {/*
    */} - {/*

    */} - {/* $ 234,435.34*/} - {/*

    */} - {/*
    */} - {/*
    */} -
    - ); + + + + {/**/} + {/*
    */} + {/*

    */} + {/* $ 234,435.34*/} + {/*

    */} + {/*
    */} + {/**/} +
    + + ); } diff --git a/src/components/Partials/Header.jsx b/src/components/Partials/Header.jsx index ef85dd6..2df00a4 100644 --- a/src/components/Partials/Header.jsx +++ b/src/components/Partials/Header.jsx @@ -1,5 +1,5 @@ import React, { useContext,useState, useEffect } from "react"; -import { Link } from "react-router-dom"; +import { Link, useLocation } from "react-router-dom"; import bank1 from "../../assets/images/bank-1.png"; import bank2 from "../../assets/images/bank-2.png"; import bank3 from "../../assets/images/bank-3.png"; @@ -91,6 +91,15 @@ export default function Header({ logoutModalHandler, sidebarHandler }) { setToggleNotification.toggle() } + // getting the location of head + let {pathname} = useLocation() + + const handleWalletBtn = () => { + if (pathname === "/my-wallet"){ + setbalanceValue.set(false) + } else return balanceDropdown + } + // User Profile let {firstname, lastname, email, profile_pic} = userDetails let userEmail = email.split('@')[0] @@ -234,7 +243,8 @@ export default function Header({ logoutModalHandler, sidebarHandler }) { myWalletList={myWalletList} handlerBalance={handlerBalance} balanceDropdown={balanceDropdown} - addMoneyHandler={addMoneyHandler} /> + addMoneyHandler={addMoneyHandler} + setBalanceDropdown = {setbalanceValue} /> {/* notification */}
    Date: Tue, 16 May 2023 06:45:53 -0400 Subject: [PATCH 4/4] My Task page --- src/components/MyActiveJobs/MyActiveJobTable.jsx | 8 ++++---- src/services/UsersService.js | 12 ++++++++++++ src/views/MyTaskPage.jsx | 2 +- 3 files changed, 17 insertions(+), 5 deletions(-) diff --git a/src/components/MyActiveJobs/MyActiveJobTable.jsx b/src/components/MyActiveJobs/MyActiveJobTable.jsx index dbae9da..f918103 100644 --- a/src/components/MyActiveJobs/MyActiveJobTable.jsx +++ b/src/components/MyActiveJobs/MyActiveJobTable.jsx @@ -68,10 +68,10 @@ export default function MyActiveJobTable({MyJobList, className }) { Duration: {value.timeline_days} day(s) - Expire: {value.expire} + Due Date: {value.delivery_date} - Send to: {value.job_to} + Confirmation: {value.contract}
    @@ -82,10 +82,10 @@ export default function MyActiveJobTable({MyJobList, className }) { diff --git a/src/services/UsersService.js b/src/services/UsersService.js index 72c70f2..7aca25a 100644 --- a/src/services/UsersService.js +++ b/src/services/UsersService.js @@ -198,6 +198,18 @@ class usersService { return this.postAuxEnd("/sendmoneyfee", postData); } + // Task for the person doing the job + getMyActiveTaskList(){ + var postData = { + uuid: localStorage.getItem("uid"), + member_id: localStorage.getItem("member_id"), + sessionid: localStorage.getItem("session_token"), + page:0, + offset:0, + limit :100 + }; + return this.postAuxEnd("/activetaskslist", postData); + } getMyActiveJobList(){ var postData = { uuid: localStorage.getItem("uid"), diff --git a/src/views/MyTaskPage.jsx b/src/views/MyTaskPage.jsx index a957162..08e2af8 100644 --- a/src/views/MyTaskPage.jsx +++ b/src/views/MyTaskPage.jsx @@ -10,7 +10,7 @@ export default function MyTaskPage() { const getMyActiveJobList = async () => { try { - const res = await api.getMyActiveJobList(); + const res = await api.getMyActiveTaskList(); setMyActiveJobList(res.data); } catch (error) { console.log("Error getting mode");