The pipeline could be looked at but not driven. Adds the three pieces that make the machine walkable end to end from the UI. - ActivityForm renders whatever /view/form-screens returns — labels, types, select options, mandatory flags — and submits it back. No form is defined in this repo, so a field added in Studio appears here with no code change. - AddLead presents the three doors. Each is a separate INIT activity with its own permissions; the bank one lands further along because the bank already did CKYC. - Lead shows the file grouped in the order it was worked, ending with what the sourcing agent earns, plus the activities this state allows and who normally performs each. The "who normally performs this" label is presentational only. Nothing here enforces anything — the workflow refuses server-side and the form reports what it said, including a note when a 403 is the platform declining rather than the console misbehaving. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
34 lines
1.0 KiB
JavaScript
34 lines
1.0 KiB
JavaScript
import { Navigate, Route, Routes } from 'react-router-dom'
|
|
import { useZino } from './api/provider.jsx'
|
|
import Login from './pages/Login.jsx'
|
|
import Shell from './layout/Shell.jsx'
|
|
import Pipeline from './screens/Pipeline.jsx'
|
|
import Lead from './screens/Lead.jsx'
|
|
import AddLead from './screens/AddLead.jsx'
|
|
|
|
export default function App() {
|
|
const { isAuthed } = useZino()
|
|
|
|
if (!isAuthed) {
|
|
return (
|
|
<Routes>
|
|
<Route path="/login" element={<Login />} />
|
|
<Route path="*" element={<Login />} />
|
|
</Routes>
|
|
)
|
|
}
|
|
|
|
return (
|
|
<Routes>
|
|
<Route path="/login" element={<Navigate to="/" replace />} />
|
|
<Route element={<Shell />}>
|
|
<Route path="/" element={<Navigate to="/stage/zk-state-referred" replace />} />
|
|
<Route path="/stage/:stageUid" element={<Pipeline />} />
|
|
<Route path="/add" element={<AddLead />} />
|
|
<Route path="/lead/:instanceId" element={<Lead />} />
|
|
<Route path="*" element={<Navigate to="/" replace />} />
|
|
</Route>
|
|
</Routes>
|
|
)
|
|
}
|