parent
4b8ee738c3
commit
def42e1ec3
9 changed files with 140 additions and 11 deletions
After Width: | Height: | Size: 308 B |
@ -0,0 +1,22 @@ |
||||
import React, { useState } from "react"; |
||||
import DatePicker from "../Calendar/CalendarComponents"; |
||||
|
||||
const RangeDatePicker = ({title}) => { |
||||
const [selectedDayRange, setSelectedDayRange] = useState({ |
||||
from: null, |
||||
to: null |
||||
}); |
||||
return ( |
||||
<DatePicker |
||||
value={selectedDayRange} |
||||
calendarClassName="range-date-picker" |
||||
onChange={setSelectedDayRange} |
||||
inputPlaceholder={title ? title : 'یک بازه زمانی انختاب کنید'} |
||||
shouldHighlightWeekends |
||||
locale='fa' |
||||
|
||||
/> |
||||
); |
||||
}; |
||||
|
||||
export default RangeDatePicker; |
@ -0,0 +1,65 @@ |
||||
import React, { useState, useEffect } from "react"; |
||||
import Checkbox from "../../../components/Checkbox"; |
||||
import arrow from '../../../assets/img/arrow-left-1.svg'; |
||||
import RangeDatePicker from "../../../components/RangeDatePicker"; |
||||
|
||||
const ProductInfos = () => { |
||||
const type = [ |
||||
{ |
||||
id: 0, |
||||
title: 'لطفا نوع محصول را مشخص کنید' |
||||
}, |
||||
{ |
||||
id: 1, |
||||
title: 'ساده' |
||||
}, |
||||
{ |
||||
id: 2, |
||||
title: 'متغیر' |
||||
}, |
||||
{ |
||||
id: 3, |
||||
title: 'الکترونیکی' |
||||
}, |
||||
{ |
||||
id: 4, |
||||
title: 'لورم ایپسوم' |
||||
}, |
||||
] |
||||
const inputs = [ |
||||
|
||||
] |
||||
return ( |
||||
<div className="w-full bg-white border mx-2 my-6 rounded-lg border-grayE0 flex flex-col py-6"> |
||||
<h1 className="text-blue3A text-lg font-bold w-full text-right px-4 mb-6 border-r-4 border-blue65"> |
||||
اطلاعات محصول |
||||
</h1> |
||||
<div className="flex w-full px-6 justify-between items-center"> |
||||
<select className="bg-white border border-solid border-gray-200 w-1/5 px-3 rounded-lg text-xs text-gray-400 outline-blueCD mx-2 h-12"> |
||||
{type.map((item) => ( |
||||
<option key={`TYPE_OF_PRODUCT__${item.id}`}>{item.title}</option> |
||||
))} |
||||
</select> |
||||
<img src={arrow} /> |
||||
<input type="number" placeholder='قیمت اصلی کالا' className="bg-white border border-grayE0 h-12 w-1/6 outline-none px-2 rounded-md" /> |
||||
<img src={arrow} /> |
||||
<input type="number" placeholder='قیمت کالا با تخفیف' className="bg-white border border-grayE0 h-12 w-1/6 outline-none px-2 rounded-md" /> |
||||
<img src={arrow} /> |
||||
<RangeDatePicker title='زمانبندی تخفیف' /> |
||||
<img src={arrow} /> |
||||
<input type="number" placeholder='موجودی' className="bg-white border border-grayE0 h-12 w-1/6 outline-none px-2 rounded-md" /> |
||||
|
||||
</div> |
||||
<div className="flex w-[80%] mr-[20%] py-4 items-center justify-between pr-[6%] pl-8"> |
||||
<input type="text" placeholder='شناسه کالا' className="bg-white border border-grayE0 h-12 w-1/2 outline-none px-2 rounded-md" /> |
||||
<div className="flex items-center font-bold text-gray70"> |
||||
<Checkbox /> |
||||
<p>آیا امکان پیش فروش این کالا باشد؟ </p> |
||||
</div> |
||||
</div> |
||||
|
||||
</div> |
||||
) |
||||
} |
||||
|
||||
export default ProductInfos; |
@ -0,0 +1,33 @@ |
||||
import React, {useState, useEffect} from "react"; |
||||
import Checkbox from "../../../components/Checkbox"; |
||||
|
||||
const Payment = () => { |
||||
const inputs = [ |
||||
'آنلاین', |
||||
'درب محل', |
||||
'کارت به کارت', |
||||
'قسطی', |
||||
] |
||||
return( |
||||
<div className="w-1/3 bg-white border mx-2 rounded-lg border-grayE0 flex flex-col py-6"> |
||||
<h1 className="text-blue3A text-lg font-bold w-full text-right px-4 mb-6 border-r-4 border-blue65"> |
||||
نحوه پرداخت |
||||
</h1> |
||||
<div className="flex flex-wrap px-4"> |
||||
{ |
||||
inputs.map( |
||||
(item, index) => ( |
||||
<div className="w-1/2 p-2 h-14 my-2 flex items-center font-bold" style={{color: '#707070'}}> |
||||
<Checkbox name={'paymentCheckBox' + index}/> |
||||
<p>{item}</p> |
||||
</div> |
||||
) |
||||
) |
||||
} |
||||
</div> |
||||
|
||||
</div> |
||||
) |
||||
} |
||||
|
||||
export default Payment; |
Loading…
Reference in new issue