Bỏ bắt buộc field Admin notes khi admin duyệt or từ chối ticket
This commit is contained in:
parent
46d4ffa339
commit
ceb925f571
|
|
@ -284,7 +284,7 @@ class TicketController extends Controller
|
||||||
$rules = [
|
$rules = [
|
||||||
'ticket_id' => 'required',
|
'ticket_id' => 'required',
|
||||||
'action' => 'required',
|
'action' => 'required',
|
||||||
'admin_note' => 'required'
|
// 'admin_note' => 'required'
|
||||||
];
|
];
|
||||||
|
|
||||||
// Validate the request
|
// Validate the request
|
||||||
|
|
|
||||||
|
|
@ -183,7 +183,7 @@ const Navbar = ({
|
||||||
confirm_password: '',
|
confirm_password: '',
|
||||||
})
|
})
|
||||||
const [countSpam, setCountSpam] = useState(0)
|
const [countSpam, setCountSpam] = useState(0)
|
||||||
const [avatar, setAvatar] = useState(user.user.avatar)
|
const [avatar, setAvatar] = useState(user?.user?.avatar)
|
||||||
|
|
||||||
const navigate = useNavigate()
|
const navigate = useNavigate()
|
||||||
const dispatch = useAppDispatch()
|
const dispatch = useAppDispatch()
|
||||||
|
|
@ -301,7 +301,7 @@ const Navbar = ({
|
||||||
const res = await post(
|
const res = await post(
|
||||||
changePassword,
|
changePassword,
|
||||||
{
|
{
|
||||||
email: user.user.email,
|
email: user?.user?.email,
|
||||||
password: dataChange.password,
|
password: dataChange.password,
|
||||||
new_password: dataChange.new_password,
|
new_password: dataChange.new_password,
|
||||||
confirm_password: dataChange.confirm_password,
|
confirm_password: dataChange.confirm_password,
|
||||||
|
|
@ -417,7 +417,7 @@ const Navbar = ({
|
||||||
cursor: 'pointer',
|
cursor: 'pointer',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{user.user.name}
|
{user?.user?.name}
|
||||||
</Code>
|
</Code>
|
||||||
</Box>
|
</Box>
|
||||||
<Box
|
<Box
|
||||||
|
|
@ -569,7 +569,7 @@ const Navbar = ({
|
||||||
<Box p="sm">
|
<Box p="sm">
|
||||||
<TextInput
|
<TextInput
|
||||||
label="E-mail"
|
label="E-mail"
|
||||||
value={user.user.email}
|
value={user?.user?.email}
|
||||||
disabled
|
disabled
|
||||||
mb={'md'}
|
mb={'md'}
|
||||||
></TextInput>
|
></TextInput>
|
||||||
|
|
|
||||||
|
|
@ -509,7 +509,7 @@ const TicketsManagement = () => {
|
||||||
|
|
||||||
<Textarea
|
<Textarea
|
||||||
label="Admin Notes"
|
label="Admin Notes"
|
||||||
required
|
// required
|
||||||
value={form.values.admin_note}
|
value={form.values.admin_note}
|
||||||
onChange={(e) => form.setFieldValue('admin_note', e.target.value)}
|
onChange={(e) => form.setFieldValue('admin_note', e.target.value)}
|
||||||
/>
|
/>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue