fix method not allowed error in delete require file from list
This commit is contained in:
parent
b7b8431975
commit
24a299b609
|
|
@ -72,18 +72,13 @@ function CommandPage() {
|
|||
const columns: ColumnDef<CommandRegistry>[] = [
|
||||
{
|
||||
accessorKey: "commandName",
|
||||
header: "Tên lệnh",
|
||||
header: () => <div className="min-w-[220px] whitespace-normal">Tên lệnh</div>,
|
||||
size: 100,
|
||||
cell: ({ getValue, row }) => {
|
||||
const full = (getValue() as string) || row.original.commandName || "";
|
||||
return (
|
||||
<div className="max-w-[100px]">
|
||||
<Tooltip>
|
||||
<TooltipTrigger asChild>
|
||||
<span className="font-semibold truncate block cursor-help">{full}</span>
|
||||
</TooltipTrigger>
|
||||
<TooltipContent side="bottom">{full}</TooltipContent>
|
||||
</Tooltip>
|
||||
<div className="min-w-[220px] whitespace-normal break-words">
|
||||
<span className="font-semibold block leading-tight">{full}</span>
|
||||
</div>
|
||||
);
|
||||
},
|
||||
|
|
|
|||
|
|
@ -111,7 +111,7 @@ export async function addRequiredFile(data: any): Promise<{ message: string }> {
|
|||
* @param fileId - ID file
|
||||
*/
|
||||
export async function deleteRequiredFile(fileId: number): Promise<{ message: string }> {
|
||||
const response = await axios.delete(
|
||||
const response = await axios.post(
|
||||
API_ENDPOINTS.APP_VERSION.DELETE_REQUIRED_FILE(fileId)
|
||||
);
|
||||
return response.data;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user