Compare commits
23 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| ea260fa15a | |||
| b604e0b527 | |||
| 991571b2d2 | |||
| 031a2f6680 | |||
| bf22570857 | |||
| 89aa5e0aef | |||
| 680833d5be | |||
| 1e0af67542 | |||
| 406af95861 | |||
| 14f69d4c3b | |||
| 24f915ee55 | |||
| 5da67c4c06 | |||
| a21eaa40f2 | |||
| a00e40dbe9 | |||
| fa51914987 | |||
| c8d40c1630 | |||
| f673fe99ef | |||
| 8d5d0672cc | |||
| 09def50875 | |||
| d6920b320c | |||
| cbfaf1e073 | |||
| 3d59b36850 | |||
| f1d659b273 |
Binary file not shown.
|
After Width: | Height: | Size: 7.6 KiB |
@@ -114,7 +114,7 @@ function AddJob({ popUpHandler, categories }) {
|
|||||||
id="country"
|
id="country"
|
||||||
name="country"
|
name="country"
|
||||||
value={props.values.country}
|
value={props.values.country}
|
||||||
className={`input-field p-2 mt-3 rounded-md placeholder:text-base text-dark-gray dark:text-white w-full h-10 bg-slate-100 dark:bg-[#11131F] focus:ring-0 focus:outline-none border`}
|
className={`input-field p-2 mt-3 rounded-full placeholder:text-base text-dark-gray w-full h-[42px] bg-slate-100 focus:ring-0 focus:outline-none border`}
|
||||||
onChange={props.handleChange}
|
onChange={props.handleChange}
|
||||||
onBlur={props.handleBlur}
|
onBlur={props.handleBlur}
|
||||||
disabled={walletDetails.data.length == 1}
|
disabled={walletDetails.data.length == 1}
|
||||||
@@ -177,6 +177,42 @@ function AddJob({ popUpHandler, categories }) {
|
|||||||
}
|
}
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
{/* Timeline */}
|
||||||
|
<div className="field w-full">
|
||||||
|
<label
|
||||||
|
className="job-label job-label-flex"
|
||||||
|
htmlFor="timeline_days"
|
||||||
|
>
|
||||||
|
Timeline
|
||||||
|
<span className="text-green-700 text-[12px] tracking-wide">
|
||||||
|
- Duration
|
||||||
|
</span>
|
||||||
|
</label>
|
||||||
|
|
||||||
|
<Field
|
||||||
|
component="select"
|
||||||
|
name="timeline_days"
|
||||||
|
className={`input-field p-2 mt-3 rounded-full placeholder:text-base text-dark-gray w-full h-[42px] bg-slate-100 focus:ring-0 focus:outline-none border ${
|
||||||
|
props.errors.timeline_days &&
|
||||||
|
props.touched.timeline_days
|
||||||
|
? "border-[#ff0a0a63] shadow-red-500 animate-shake"
|
||||||
|
: "dark:border-[#5e6278]"
|
||||||
|
}`}
|
||||||
|
value={props.values.timeline_days}
|
||||||
|
>
|
||||||
|
<option value="" className='text-slate-500 text-lg'>Select Duration</option>
|
||||||
|
{publicArray.map(({ name, duration }, idx) => (
|
||||||
|
<option
|
||||||
|
key={idx}
|
||||||
|
className="text-slate-500 text-lg"
|
||||||
|
value={duration}
|
||||||
|
>
|
||||||
|
{name}
|
||||||
|
</option>
|
||||||
|
))}
|
||||||
|
</Field>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{/* Title */}
|
{/* Title */}
|
||||||
@@ -288,7 +324,7 @@ function AddJob({ popUpHandler, categories }) {
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div className="field w-full mb-[5px]">
|
{/* <div className="field w-full mb-[5px]">
|
||||||
<div className={`flex items-center justify-between mb-2.5`}>
|
<div className={`flex items-center justify-between mb-2.5`}>
|
||||||
<label
|
<label
|
||||||
className="job-label"
|
className="job-label"
|
||||||
@@ -323,7 +359,7 @@ function AddJob({ popUpHandler, categories }) {
|
|||||||
</option>
|
</option>
|
||||||
))}
|
))}
|
||||||
</Field>
|
</Field>
|
||||||
</div>
|
</div> */}
|
||||||
{/* inputs ends here */}
|
{/* inputs ends here */}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -25,7 +25,7 @@ export default function LoginLayout({ slogan, children }) {
|
|||||||
>
|
>
|
||||||
</div> */}
|
</div> */}
|
||||||
<div className="p-5 sm:p-7 flex place-content-center lg:col-start-2">
|
<div className="p-5 sm:p-7 flex place-content-center lg:col-start-2">
|
||||||
<div className="py-5 w-full sm:w-11/12 max-w-[550px] shadow-md bg-slate-50 rounded-[0.475rem]">
|
<div className="py-5 w-full sm:w-11/12 max-w-[550px] shadow-md bg-slate-50 dark:bg-dark-white rounded-[0.475rem]">
|
||||||
<div className="w-full flex justify-center items-center">
|
<div className="w-full flex justify-center items-center">
|
||||||
{children && children}
|
{children && children}
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ import linkedInLogo from "../../../assets/images/Linkedin.png";
|
|||||||
import appleLogo from "../../../assets/images/apple-black.svg";
|
import appleLogo from "../../../assets/images/apple-black.svg";
|
||||||
import facebookLogo from "../../../assets/images/facebook.svg";
|
import facebookLogo from "../../../assets/images/facebook.svg";
|
||||||
import googleLogo from "../../../assets/images/google-logo.svg";
|
import googleLogo from "../../../assets/images/google-logo.svg";
|
||||||
import WrenchBoard from "../../../assets/images/wrenchboard-logo-text.png";
|
import WrenchBoard from "../../../assets/images/wrenchboard-logo-text_new.png";
|
||||||
import usersService from "../../../services/UsersService";
|
import usersService from "../../../services/UsersService";
|
||||||
import InputCom from "../../Helpers/Inputs/InputCom";
|
import InputCom from "../../Helpers/Inputs/InputCom";
|
||||||
import AuthLayout from "../AuthLayout2";
|
import AuthLayout from "../AuthLayout2";
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import React, { useCallback, useEffect, useState } from "react";
|
import React, { useCallback, useEffect, useState } from "react";
|
||||||
import { Link, useLocation, useNavigate } from "react-router-dom";
|
import { Link, useLocation, useNavigate } from "react-router-dom";
|
||||||
import WrenchBoard from "../../../assets/images/wrenchboard-logo-text.png";
|
import WrenchBoard from "../../../assets/images/wrenchboard-logo-text_new.png";
|
||||||
import usersService from "../../../services/UsersService";
|
import usersService from "../../../services/UsersService";
|
||||||
import InputCom from "../../Helpers/Inputs/InputCom";
|
import InputCom from "../../Helpers/Inputs/InputCom";
|
||||||
import AuthLayout from "../AuthLayout2";
|
import AuthLayout from "../AuthLayout2";
|
||||||
@@ -180,11 +180,11 @@ export default function SignUp() {
|
|||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
<div className="w-full flex items-center gap-2">
|
<div className="w-full flex items-center gap-2">
|
||||||
<div className="border-b border-[#eff2f5] max-w-[50%] w-full"></div>
|
<div className="border-b border-[#eff2f5] w-[48%]"></div>
|
||||||
<span className="text-[#b5b5c3] font-medium text-[0.7rem] w-[2%]">
|
<span className="text-[#b5b5c3] font-medium text-[0.7rem]">
|
||||||
OR
|
OR
|
||||||
</span>
|
</span>
|
||||||
<div className="border-b border-[#eff2f5] max-w-[50%] w-full"></div>
|
<div className="border-b border-[#eff2f5] w-[48%]"></div>
|
||||||
</div>
|
</div>
|
||||||
<div className="input-area">
|
<div className="input-area">
|
||||||
<SelectOption
|
<SelectOption
|
||||||
@@ -413,7 +413,7 @@ const SelectOption = ({
|
|||||||
disabled={disable}
|
disabled={disable}
|
||||||
name={name}
|
name={name}
|
||||||
id={name}
|
id={name}
|
||||||
className="input-wrapper border border-[#f5f8fa] dark:border-[#5e6278] w-full rounded-full h-[42px] overflow-hidden relative font-medium leading-6 bg-clip-padding text-[#5e6278] dark:text-gray-100 bg-[#f5f8fa] dark:bg-[#5e6278] text-base focus-visible:border-transparent focus-visible:outline-0 focus-visible:ring-transparent "
|
className="px-6 input-wrapper border border-[#f5f8fa] dark:border-[#5e6278] w-full rounded-full h-[42px] overflow-hidden relative font-medium leading-6 bg-clip-padding text-[#5e6278] dark:text-dark-gray bg-[#f5f8fa] dark:bg-[#FAFAFA] text-base focus-visible:border-transparent focus-visible:outline-0 focus-visible:ring-transparent "
|
||||||
onChange={inputHandler}
|
onChange={inputHandler}
|
||||||
value={value}
|
value={value}
|
||||||
>
|
>
|
||||||
|
|||||||
@@ -108,8 +108,8 @@ const LowerBanner = ({ image, title = "", desc = "", btn, link_path, key }) => {
|
|||||||
key={key}
|
key={key}
|
||||||
className="flex flex-col bg-white shadow-md h-full rounded-xl dark:border-[#5356fb29] dark:bg-dark-white"
|
className="flex flex-col bg-white shadow-md h-full rounded-xl dark:border-[#5356fb29] dark:bg-dark-white"
|
||||||
>
|
>
|
||||||
<div className="w-full flex justify-between border-b border-slate-300 p-2">
|
<div className="w-full xxs:flex justify-between items-center border-b border-slate-300 p-2">
|
||||||
<div className="h-[130px] flex justify-between items-center">
|
<div className="min-h-[150px] sm:min-h-[130px] flex justify-between items-center">
|
||||||
<div className="px-2 flex flex-col gap-2 dark:text-white">
|
<div className="px-2 flex flex-col gap-2 dark:text-white">
|
||||||
<Link to={link_path} className="text-lg font-bold">
|
<Link to={link_path} className="text-lg font-bold">
|
||||||
{title}
|
{title}
|
||||||
|
|||||||
@@ -121,65 +121,67 @@ export default function AssignPrevNewTask({
|
|||||||
value={activeTask?.data?.description}
|
value={activeTask?.data?.description}
|
||||||
/>
|
/>
|
||||||
</div> */}
|
</div> */}
|
||||||
<div className="my-3 w-full">
|
<div className='flex flex-col gap-2'>
|
||||||
<label className="job-label">
|
<div className="my-1 w-full">
|
||||||
Description
|
<label className="job-label">
|
||||||
</label>
|
Description
|
||||||
<p className="p-1 text-sm text-slate-900 dark:text-white max-h-[100px] overflow-y-auto">
|
</label>
|
||||||
{activeTask?.data?.description}
|
<p className="p-1 text-sm text-slate-900 dark:text-white max-h-[100px] overflow-y-auto">
|
||||||
</p>
|
{activeTask?.data?.description}
|
||||||
</div>
|
</p>
|
||||||
<div className="grid grid-cols-2">
|
</div>
|
||||||
<div className="w-full">
|
<div className="w-full grid grid-cols-2">
|
||||||
<div className="my-3 w-full flex items-center gap-1">
|
<div className="w-full">
|
||||||
<label className="job-label">
|
<div className="w-full flex items-center gap-1">
|
||||||
Reward
|
<label className="job-label">
|
||||||
</label>
|
Reward
|
||||||
<p className="p-1 text-sm text-slate-900 dark:text-white">
|
</label>
|
||||||
{PriceFormatter(
|
<p className="p-1 text-sm text-slate-900 dark:text-white">
|
||||||
activeTask?.data?.price * 0.01,
|
{PriceFormatter(
|
||||||
activeTask?.data?.currency,
|
activeTask?.data?.price * 0.01,
|
||||||
activeTask?.data?.curreny_code
|
activeTask?.data?.currency,
|
||||||
)}
|
activeTask?.data?.curreny_code
|
||||||
</p>
|
)}
|
||||||
</div>
|
</p>
|
||||||
|
</div>
|
||||||
|
|
||||||
<div className="my-3 w-full flex items-center gap-1">
|
<div className="w-full flex items-center gap-1">
|
||||||
<label className="job-label">
|
<label className="job-label">
|
||||||
Timeline
|
Timeline
|
||||||
</label>
|
</label>
|
||||||
<p className="p-1 text-sm text-slate-900 dark:text-white">{`${activeTask?.data?.timeline_days} day(s)`}</p>
|
<p className="p-1 text-sm text-slate-900 dark:text-white">{`${activeTask?.data?.timeline_days} day(s)`}</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div className="w-full flex items-center justify-center">
|
||||||
|
<div className="mb-1 w-24 max-h-24 rounded-2xl flex items-center justify-center">
|
||||||
|
<img
|
||||||
|
className="w-full h-auto"
|
||||||
|
loading="lazy"
|
||||||
|
src={imageSrc}
|
||||||
|
alt='job image'
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div className="w-full flex items-center justify-center">
|
|
||||||
<div className="mb-1 w-28 h-28 rounded-2xl flex items-center justify-center">
|
{/* ATTACHMENT SECTION*/}
|
||||||
<img
|
<div className="w-full max-h-28">
|
||||||
className="w-full h-auto"
|
<AttachFile data={activeTask.data} />
|
||||||
loading="lazy"
|
|
||||||
src={imageSrc}
|
|
||||||
alt='job image'
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
|
||||||
|
|
||||||
{/* ATTACHMENT SECTION*/}
|
|
||||||
<div className="w-full max-h-28">
|
|
||||||
<AttachFile data={activeTask.data} />
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div className="my-3">
|
<div className="my-3">
|
||||||
<label className="w-full job-label">
|
<label className="w-full job-label">
|
||||||
Delivery Detail
|
Delivery Detail
|
||||||
</label>
|
</label>
|
||||||
<textarea
|
<textarea
|
||||||
className={`p-1 w-full text-sm text-slate-900 dark:text-white bg-transparent outline-none border border-slate-300 rounded-md`}
|
className={`p-1 w-full text-sm text-slate-900 dark:text-white bg-transparent outline-none border border-slate-300 rounded-md`}
|
||||||
rows="5"
|
rows="5"
|
||||||
style={{ resize: "none" }}
|
style={{ resize: "none" }}
|
||||||
value={activeTask?.data?.job_detail}
|
value={activeTask?.data?.job_detail}
|
||||||
readOnly
|
readOnly
|
||||||
// onChange={handleInputChange}
|
// onChange={handleInputChange}
|
||||||
/>
|
/>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -93,9 +93,9 @@ const FamilyWaitlist = memo(
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div className="px-2 flex flex-col items-center justify-center">
|
<div className="px-2 flex flex-col items-center justify-center">
|
||||||
<p className="text-sm font-bold text-dark-gray dark:text-white">
|
{/* <p className="text-sm font-bold text-dark-gray dark:text-white">
|
||||||
{addedDate}
|
{addedDate}
|
||||||
</p>
|
</p> */}
|
||||||
<p className="text-xs py-1.5 w-[70px] cursor-default tracking-wide rounded-full bg-gold text-white flex justify-center items-center">
|
<p className="text-xs py-1.5 w-[70px] cursor-default tracking-wide rounded-full bg-gold text-white flex justify-center items-center">
|
||||||
{value.status_text}
|
{value.status_text}
|
||||||
</p>
|
</p>
|
||||||
|
|||||||
@@ -95,8 +95,7 @@ export default function InputCom({
|
|||||||
value={value}
|
value={value}
|
||||||
onChange={inputHandler}
|
onChange={inputHandler}
|
||||||
className={`input-field placeholder:text-base text-dark-gray w-full h-full ${
|
className={`input-field placeholder:text-base text-dark-gray w-full h-full ${
|
||||||
inputBg ? inputBg : "bg-[#FAFAFA] dark:bg-[#11131F] dark:text-white tracking-wide"
|
inputBg && inputBg} tracking-wide focus:ring-0 focus:outline-none ${fieldClass}`}
|
||||||
} focus:ring-0 focus:outline-none ${fieldClass}`}
|
|
||||||
type={type}
|
type={type}
|
||||||
id={name}
|
id={name}
|
||||||
name={name}
|
name={name}
|
||||||
|
|||||||
@@ -20,7 +20,7 @@ export default function ActiveJobMessage({ activeJobMesList }) {
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<div className='flex flex-col justify-between'>
|
<div className='flex flex-col justify-between'>
|
||||||
<div className="w-full h-full min-h-[400px] max-h-[400px] overflow-y-auto">
|
<div className="w-full h-full min-h-[250px] max-h-[300px] overflow-y-auto">
|
||||||
<table className="wallet-activity w-full table-auto border-collapse text-left">
|
<table className="wallet-activity w-full table-auto border-collapse text-left">
|
||||||
<thead className='border-b-2'>
|
<thead className='border-b-2'>
|
||||||
<tr className='text-slate-600'>
|
<tr className='text-slate-600'>
|
||||||
|
|||||||
@@ -13,6 +13,7 @@ import usersService from "../../services/UsersService";
|
|||||||
import { PriceFormatter } from "../Helpers/PriceFormatter";
|
import { PriceFormatter } from "../Helpers/PriceFormatter";
|
||||||
import { SocketValues } from "../Contexts/SocketIOContext";
|
import { SocketValues } from "../Contexts/SocketIOContext";
|
||||||
import TabButton from "../customTabs/TabButton";
|
import TabButton from "../customTabs/TabButton";
|
||||||
|
import AttachFile from "../attachmentCom/AttachFile";
|
||||||
|
|
||||||
function ActiveJobs(props) {
|
function ActiveJobs(props) {
|
||||||
let {sendMessage, joinRoom} = SocketValues() // destructures 'SEND MESSAGE' and 'JOIN ROOM' FUNCTIONS FROM SOCKET
|
let {sendMessage, joinRoom} = SocketValues() // destructures 'SEND MESSAGE' and 'JOIN ROOM' FUNCTIONS FROM SOCKET
|
||||||
@@ -539,6 +540,13 @@ function ActiveJobs(props) {
|
|||||||
|
|
||||||
{/* MESSAGE SECTION */}
|
{/* MESSAGE SECTION */}
|
||||||
<div className="w-full lg:w-1/2">
|
<div className="w-full lg:w-1/2">
|
||||||
|
<div className="mb-4">
|
||||||
|
<AttachFile
|
||||||
|
data={props.details}
|
||||||
|
showOnData={true}
|
||||||
|
fontSize={'text-lg'}
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
<div className="flex justify-between items-center gap-5">
|
<div className="flex justify-between items-center gap-5">
|
||||||
<p className="w-full text-lg font-bold text-dark-gray dark:text-white tracking-wide flex items-center gap-2 justify-between">
|
<p className="w-full text-lg font-bold text-dark-gray dark:text-white tracking-wide flex items-center gap-2 justify-between">
|
||||||
<span>Message</span>
|
<span>Message</span>
|
||||||
|
|||||||
@@ -1,8 +1,15 @@
|
|||||||
import React, { useRef, useState } from 'react'
|
import React, { useEffect, useRef, useState } from 'react'
|
||||||
import LoadingSpinner from '../Spinners/LoadingSpinner'
|
import LoadingSpinner from '../Spinners/LoadingSpinner'
|
||||||
import axios from 'axios'
|
import axios from 'axios'
|
||||||
|
|
||||||
export default function AttachFile({data}) {
|
import usersService from '../../services/UsersService'
|
||||||
|
|
||||||
|
export default function AttachFile({data='', fontSize='text-sm', showOnData=false}) {
|
||||||
|
|
||||||
|
const apiCall = new usersService()
|
||||||
|
|
||||||
|
let [uploadedList, setUploadedList] = useState({loading: true, data:{}})
|
||||||
|
let [reloadList, setReloadList] = useState(false) // Triggers list of upload reload
|
||||||
|
|
||||||
const [requestStatus, setRequestStatus] = useState({loading: false, status:false, message:''})
|
const [requestStatus, setRequestStatus] = useState({loading: false, status:false, message:''})
|
||||||
|
|
||||||
@@ -29,9 +36,8 @@ export default function AttachFile({data}) {
|
|||||||
formData.append(input, inputs[input]);
|
formData.append(input, inputs[input]);
|
||||||
}
|
}
|
||||||
|
|
||||||
console.log('data', formData, inputs)
|
|
||||||
axios.post(`${process.env.REACT_APP_MEDIA_LINK}/upload/task`,formData).then(res => {
|
axios.post(`${process.env.REACT_APP_MEDIA_LINK}/upload/task`,formData).then(res => {
|
||||||
if(res.data.status < 1){
|
if(res.data.internal_return < 0){
|
||||||
inputFile.current.value = null
|
inputFile.current.value = null
|
||||||
setRequestStatus({loading: false, status:false, message:'upload failed'})
|
setRequestStatus({loading: false, status:false, message:'upload failed'})
|
||||||
setTimeout(()=>{
|
setTimeout(()=>{
|
||||||
@@ -39,9 +45,9 @@ export default function AttachFile({data}) {
|
|||||||
}, 3000)
|
}, 3000)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
// console.log('RESPONSE', res.data)
|
|
||||||
setRequestStatus({loading: false, status:true, message:'uploaded'})
|
setRequestStatus({loading: false, status:true, message:'uploaded'})
|
||||||
inputFile.current.value = null
|
inputFile.current.value = null
|
||||||
|
setReloadList(prev => !prev) // Triggers list of upload reload
|
||||||
setTimeout(()=>{
|
setTimeout(()=>{
|
||||||
setRequestStatus({loading: false, status:false, message:''})
|
setRequestStatus({loading: false, status:false, message:''})
|
||||||
}, 3000)
|
}, 3000)
|
||||||
@@ -55,31 +61,113 @@ export default function AttachFile({data}) {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
useEffect(()=>{
|
||||||
|
apiCall.jobManagerFiles({job_uid:data?.job_uid || data?.origin_job_uid}).then(res => {
|
||||||
|
setUploadedList({loading: false, data:res.data})
|
||||||
|
}).catch(err => {
|
||||||
|
console.log(err)
|
||||||
|
setUploadedList({loading: false, data:{}})
|
||||||
|
})
|
||||||
|
},[data, reloadList])
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className='w-full h-full flex flex-col justify-center items-center rounded-md'>
|
<>
|
||||||
<div className='w-full flex flex-col items-start gap-1 overflow-hidden'>
|
{!showOnData ?
|
||||||
<div className='w-full flex justify-between items-center gap-1'>
|
<div className='w-full h-full flex flex-col justify-center items-center'>
|
||||||
<div className='job-label job-label-flex'>
|
<div className='w-full flex flex-col items-start gap-1 overflow-hidden'>
|
||||||
Files {
|
<div className='w-full flex justify-between items-center gap-1'>
|
||||||
requestStatus.loading ?
|
<div className='job-label job-label-flex'>
|
||||||
<LoadingSpinner size='6' />
|
Files {
|
||||||
:
|
requestStatus.loading ?
|
||||||
<span className={`text-[10px] ${requestStatus.status ? 'text-emerald-600' : 'text-red-500'}`}>{requestStatus.message}</span>
|
<LoadingSpinner size='6' />
|
||||||
}
|
:
|
||||||
|
<span className={`text-[10px] ${requestStatus.status ? 'text-emerald-600' : 'text-red-500'}`}>{requestStatus.message}</span>
|
||||||
|
}
|
||||||
|
</div>
|
||||||
|
<label htmlFor='file' className={`text-black bg-[#f8ffd4] cursor-pointer text-[12px] py-1 px-2 rounded-full border ${ requestStatus.loading && 'pointer-events-none'}`}>+ Add Files</label>
|
||||||
</div>
|
</div>
|
||||||
<label htmlFor='file' className={`cursor-pointer text-[12px] py-1 px-2 rounded-full border ${ requestStatus.loading && 'pointer-events-none'}`}>+ Add</label>
|
<div className='w-full p-2 rounded-2xl bg-slate-100'>
|
||||||
|
<div className='text-[12px] w-full h-20 overflow-y-auto flex flex-col gap-2'>
|
||||||
|
{uploadedList.loading ?
|
||||||
|
<div className='w-full h-full justify-center items-center'>
|
||||||
|
<LoadingSpinner size='6' height='h-full' />
|
||||||
|
</div>
|
||||||
|
:
|
||||||
|
Object.keys(uploadedList.data).length > 0 ?
|
||||||
|
uploadedList.data.result_list.length > 0 ?
|
||||||
|
uploadedList.data.result_list.map((item, index) => {
|
||||||
|
let fileNameExt = item.originalname.split('.')[item.originalname.split('.').length - 1]
|
||||||
|
return(
|
||||||
|
<div key={item.file_uid} className={`my-[6px] flex justify-start gap-2 ${fontSize}`}>
|
||||||
|
<span>{index + 1}:</span>
|
||||||
|
<a
|
||||||
|
target='_blank'
|
||||||
|
alt='download-link'
|
||||||
|
className=''
|
||||||
|
href={`${uploadedList?.data?.session_image_server}/${localStorage.getItem("session_token")}/jobfile/${item.file_uid}`}
|
||||||
|
>
|
||||||
|
{(item.originalname).toString().length > 30 ? (item.originalname).toString().slice(0, 26) + '..._.' + fileNameExt : (item.originalname).toString()}
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
)
|
||||||
|
})
|
||||||
|
:
|
||||||
|
<p className='text-sm'>No Uploaded files yet</p>
|
||||||
|
:
|
||||||
|
<></>
|
||||||
|
}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<input
|
||||||
|
type="file"
|
||||||
|
id='file'
|
||||||
|
ref={inputFile}
|
||||||
|
className='hidden file:rounded-full job-label p-1'
|
||||||
|
onChange={upload}
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
<div className='text-[12px] w-full px-2 py-1 h-20 overflow-y-auto flex justify-center items-center border'>
|
|
||||||
list shows here
|
|
||||||
</div>
|
|
||||||
<input
|
|
||||||
type="file"
|
|
||||||
id='file'
|
|
||||||
ref={inputFile}
|
|
||||||
className='hidden file:rounded-full job-label p-1'
|
|
||||||
onChange={upload}
|
|
||||||
/>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
:showOnData && uploadedList?.data?.result_list?.length > 0 ?
|
||||||
|
<div className='w-full h-full flex flex-col justify-center items-center'>
|
||||||
|
<div className='w-full flex flex-col items-start gap-1 overflow-hidden'>
|
||||||
|
<div className='w-full flex justify-between items-center gap-1'>
|
||||||
|
<div className='job-label job-label-flex'>
|
||||||
|
Files
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div className='w-full p-2 rounded-2xl bg-slate-100'>
|
||||||
|
<div className='text-[12px] w-full p-2 h-20 overflow-y-auto flex flex-col gap-2'>
|
||||||
|
{uploadedList.data.result_list.map((item, index) => {
|
||||||
|
let fileNameExt = item.originalname.split('.')[item.originalname.split('.').length - 1]
|
||||||
|
return(
|
||||||
|
<div key={item.file_uid} className={`my-[6px] flex justify-start gap-2 ${fontSize}`}>
|
||||||
|
<span>{index + 1}:</span>
|
||||||
|
<a
|
||||||
|
target='_blank'
|
||||||
|
alt='download-link'
|
||||||
|
className=''
|
||||||
|
href={`${uploadedList?.data?.session_image_server}/${localStorage.getItem("session_token")}/jobfile/${item.file_uid}`}
|
||||||
|
>
|
||||||
|
{(item.originalname).toString().length > 30 ? (item.originalname).toString().slice(0, 26) + '..._.' + fileNameExt : (item.originalname).toString()}
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
)
|
||||||
|
})
|
||||||
|
}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<input
|
||||||
|
type="file"
|
||||||
|
id='file'
|
||||||
|
ref={inputFile}
|
||||||
|
className='hidden file:rounded-full job-label p-1'
|
||||||
|
onChange={upload}
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
:
|
||||||
|
<></>
|
||||||
|
}
|
||||||
|
</>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -302,15 +302,15 @@ const EditJobPopoutNew = ({
|
|||||||
<Field
|
<Field
|
||||||
component="select"
|
component="select"
|
||||||
name="timeline_days"
|
name="timeline_days"
|
||||||
className={`input-field p-2 mt-3 rounded-full placeholder:text-base text-dark-gray w-full h-[42px] bg-slate-100 focus:ring-0 focus:outline-none ${
|
className={`input-field p-2 mt-3 rounded-full placeholder:text-base text-dark-gray w-full h-[42px] bg-slate-100 focus:ring-0 focus:outline-none border ${
|
||||||
props.errors.timeline_days &&
|
props.errors.timeline_days &&
|
||||||
props.touched.timeline_days
|
props.touched.timeline_days
|
||||||
? "border-[#ff0a0a63] shadow-red-500 border-[0.5px] animate-shake"
|
? "border-[#ff0a0a63] shadow-red-500 border-[0.5px] animate-shake"
|
||||||
: "border border-[#f5f8fa] dark:border-[#5e6278]"
|
: "dark:border-[#5e6278]"
|
||||||
}`}
|
}`}
|
||||||
value={props.values.timeline_days}
|
value={props.values.timeline_days}
|
||||||
>
|
>
|
||||||
<option value="">Select Duration</option>
|
<option value="" className='text-slate-500 text-lg'>Select Duration</option>
|
||||||
{publicArray.map(({ name, duration }, idx) => (
|
{publicArray.map(({ name, duration }, idx) => (
|
||||||
<option
|
<option
|
||||||
key={duration}
|
key={duration}
|
||||||
|
|||||||
@@ -11,6 +11,7 @@ import { tableReload } from "../../store/TableReloads";
|
|||||||
import { useDispatch } from "react-redux";
|
import { useDispatch } from "react-redux";
|
||||||
|
|
||||||
import { SocketValues } from "../Contexts/SocketIOContext";
|
import { SocketValues } from "../Contexts/SocketIOContext";
|
||||||
|
import AttachFile from "../attachmentCom/AttachFile";
|
||||||
|
|
||||||
const VideoElement = lazy(() => import("../VideoCom/VideoElement"));
|
const VideoElement = lazy(() => import("../VideoCom/VideoElement"));
|
||||||
const ImageElement = lazy(() => import("../ImageCon/ImageElement"));
|
const ImageElement = lazy(() => import("../ImageCon/ImageElement"));
|
||||||
@@ -206,11 +207,11 @@ function FamilyOfferJobPopout({ details, onClose, situation }) {
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
{/* ACTION SECTION */}
|
{/* ACTION SECTION */}
|
||||||
<div className="p-4 w-full md:w-2/5 h-full flex flex-col justify-between">
|
<div className="p-4 w-full md:w-2/5 h-full flex flex-col gap-4 justify-between">
|
||||||
{ details.job_type == 'TASK' ?
|
{ details.job_type == 'TASK' ?
|
||||||
<div className="image-wrapper w-full h-40 flex justify-center items-center">
|
<div className="image-wrapper w-full h-40 flex justify-center items-center">
|
||||||
<Suspense fallback={<p className="w-full text-center">Loading...</p>}>
|
<Suspense fallback={<p className="w-full text-center">Loading...</p>}>
|
||||||
<ImageElement src={details?.image} alt='banner' className='w-auto h-full' />
|
<ImageElement src={details?.image} alt='banner' className='w-full h-auto' />
|
||||||
</Suspense>
|
</Suspense>
|
||||||
</div>
|
</div>
|
||||||
:
|
:
|
||||||
@@ -222,6 +223,9 @@ function FamilyOfferJobPopout({ details, onClose, situation }) {
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
}
|
}
|
||||||
|
<div className="w-full">
|
||||||
|
<AttachFile data={details} showOnData={true} />
|
||||||
|
</div>
|
||||||
<div className="my-3 md:flex md:justify-center">
|
<div className="my-3 md:flex md:justify-center">
|
||||||
{requestStatus.loading && requestStatus.trigger == "offer" ? (
|
{requestStatus.loading && requestStatus.trigger == "offer" ? (
|
||||||
<LoadingSpinner size={8} color="sky-blue" />
|
<LoadingSpinner size={8} color="sky-blue" />
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ import React from 'react'
|
|||||||
function Detail({label, value, bg,}) {
|
function Detail({label, value, bg,}) {
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
<label className='job-label w-full md:w-1/4'>{label}</label>
|
<label className='job-label w-full md:w-[150px]'>{label}</label>
|
||||||
<p className={`p-1 w-full md:w-3/4 text-sm text-slate-900 dark:text-white ${bg ? bg : null}`}>{value}</p>
|
<p className={`p-1 w-full md:w-3/4 text-sm text-slate-900 dark:text-white ${bg ? bg : null}`}>{value}</p>
|
||||||
</>
|
</>
|
||||||
)
|
)
|
||||||
|
|||||||
@@ -44,6 +44,7 @@ export const apiConst = {
|
|||||||
WRENCH_FILE_FAMILY: 400,
|
WRENCH_FILE_FAMILY: 400,
|
||||||
WRENCH_FILE_FAMILYBANNER: 410,
|
WRENCH_FILE_FAMILYBANNER: 410,
|
||||||
WRENCH_FILE_JOB : 500,
|
WRENCH_FILE_JOB : 500,
|
||||||
|
JOB_MANAGER_FILES: 13012,
|
||||||
WRENCHBOARD_BKO_START: 10000,
|
WRENCHBOARD_BKO_START: 10000,
|
||||||
WRENCHBOARD_BKO_LOGIN: 10010,
|
WRENCHBOARD_BKO_LOGIN: 10010,
|
||||||
WRENCHBOARD_BKO_CREATEUSER: 10015,
|
WRENCHBOARD_BKO_CREATEUSER: 10015,
|
||||||
|
|||||||
@@ -1356,6 +1356,18 @@ class usersService {
|
|||||||
return this.postAuxEnd("/assignmediatask", postData);
|
return this.postAuxEnd("/assignmediatask", postData);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// API FUNCTION FOR LISTING JOB MANAGER FILES (TASK FILE UPLAOD)
|
||||||
|
jobManagerFiles(reqData) {
|
||||||
|
var postData = {
|
||||||
|
member_uid: localStorage.getItem("uid"),
|
||||||
|
member_id: localStorage.getItem("member_id"),
|
||||||
|
sessionid: localStorage.getItem("session_token"),
|
||||||
|
action: apiConst.JOB_MANAGER_FILES,
|
||||||
|
...reqData
|
||||||
|
};
|
||||||
|
return this.postAuxEnd("/jobmanagerfiles", postData);
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
- 20:27:30.118 FLOG_MAX [757411]: REQ_STRING(username)
|
- 20:27:30.118 FLOG_MAX [757411]: REQ_STRING(username)
|
||||||
- 20:27:30.118 FLOG_MAX [757411]: REQ_STRING(password)
|
- 20:27:30.118 FLOG_MAX [757411]: REQ_STRING(password)
|
||||||
|
|||||||
Reference in New Issue
Block a user