Skip to content

Commit

Permalink
chore: disable view inspection; redirect on success
Browse files Browse the repository at this point in the history
  • Loading branch information
pantheredeye committed Dec 5, 2024
1 parent 6dbfc07 commit 5e29de2
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion deploy.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
[[production.servers]]
host = "swppp.top"
username = "devops"
privateKeyPath = "C:/Users/bburnworth/.ssh/id_ed25519"
privateKeyPath = "C:/Users/39P3QC2/.ssh/id_ed25519"
sides = ["api","web"]
packageManagerCommand = "yarn"
monitorCommand = "pm2"
Expand Down
6 changes: 3 additions & 3 deletions web/src/components/InspectionsTable/columns.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import React from 'react'
import { ColumnDef } from '@tanstack/react-table'
import { MoreHorizontal } from 'lucide-react'

import { navigate, routes } from '@redwoodjs/router'
// import { navigate, routes } from '@redwoodjs/router'

import { Button } from 'src/components/ui/Button'
import {
Expand Down Expand Up @@ -79,13 +79,13 @@ export const columns: ColumnDef<Inspection>[] = [
Copy inspection ID
</DropdownMenuItem>
<DropdownMenuSeparator />
<DropdownMenuItem
{/* <DropdownMenuItem
onClick={() =>
navigate(routes.viewInspection({ id: inspection.id }))
}
>
View inspection
</DropdownMenuItem>
</DropdownMenuItem> */}
<DropdownMenuItem>
<ExportPDFButton inspectionId={inspection.id} />
</DropdownMenuItem>
Expand Down
2 changes: 2 additions & 0 deletions web/src/pages/NewInspectionPage/NewInspectionPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import {
TimeField,
DatetimeLocalField,
} from '@redwoodjs/forms'
import { navigate } from '@redwoodjs/router'
import { useMutation } from '@redwoodjs/web'

import { useAuth } from 'src/auth'
Expand Down Expand Up @@ -183,6 +184,7 @@ const NewInspectionPage = () => {
},
},
})
navigate('/dashboard')
} catch (error) {
console.error('Error in handleSubmit:', error.message)
alert(
Expand Down

0 comments on commit 5e29de2

Please sign in to comment.