Packages can be marked hand delivered
parent
5648a1b31a
commit
c5425d8cb4
@ -0,0 +1,26 @@
|
|||||||
|
import React, {useState} from 'react'
|
||||||
|
import Router from 'next/router'
|
||||||
|
|
||||||
|
import ActionBar from '~/components/admin/actionBar'
|
||||||
|
import {FormController, DateInput, TextArea, Button} from '~/components/form'
|
||||||
|
|
||||||
|
EnterDelivery.getInitialProps = async ({ctx: {axios, query: {id}}}) => {
|
||||||
|
const {data: order} = await axios.get(`/api/orders/${id}`)
|
||||||
|
return {order}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default function EnterDelivery({order}){
|
||||||
|
return (
|
||||||
|
<>
|
||||||
|
<ActionBar title="Mark Delivered"/>
|
||||||
|
|
||||||
|
<FormController afterSubmit={() => Router.push(`/admin/orders/${order.uuid}`)} url={`/api/orders/${order.uuid}/ship/delivery`}>
|
||||||
|
<p>Use this to enter delivery information for packages delivered in-person or at a con.</p>
|
||||||
|
<p>In case we ever have future corespondence with this person, please be sure to describe where, when, and to who you gave the package.</p>
|
||||||
|
<TextArea label="Description" validate={val => val.length > 0} type="text" name="description" hint="Please describe how and where you delivered the order to them" />
|
||||||
|
<DateInput label="Delivery Date" placeholder="Today" name="date" />
|
||||||
|
<Button type="submit">Submit</Button>
|
||||||
|
</FormController>
|
||||||
|
</>
|
||||||
|
)
|
||||||
|
}
|
Loading…
Reference in New Issue