CEC-377 Create multi-file updates (#71)

* Replace Deploy Package with Deploy Manifest page
Stub new controls for package files

* Add Release notes and ECU FIles to Create Manifest

* Add Release notes and ECU FIles to Create Manifest

* Oops

* Replace multi release notes with single url

* Implement multiple file uploads and progress

* Update snapshots

* Unused import

* Move file to end of form
Update progress layout
This commit is contained in:
John Wu
2021-08-09 08:54:48 -07:00
committed by GitHub
parent 5d82356991
commit 0545b54daf
19 changed files with 1533 additions and 1943 deletions

View File

@@ -8,10 +8,8 @@ import { Roles } from "../../utils/roles";
const SSOForm = React.lazy(() => import("../SSOForm"));
const Home = React.lazy(() => import("../Home"));
const FileUploadForm = React.lazy(() => import("../UpdatePackages/Create"));
const VehicleAddForm = React.lazy(() => import("../Cars/Add"));
const PageNotFound = React.lazy(() => import("../404"));
const UpdatePackagesForm = React.lazy(() => import("../UpdatePackages/List"));
const UpdatePackageEdit = React.lazy(() => import("../UpdatePackages/Edit"));
const CarUpdatesDeploy = React.lazy(() => import("../CarUpdates/Deploy"));
const CarUpdatesStatus = React.lazy(() => import("../CarUpdates/Status"));
@@ -22,6 +20,7 @@ const Dashboard = React.lazy(() => import("../Dashboard"));
const Manifests = React.lazy(() => import("../Manifest/List"));
const ManifestDeploy = React.lazy(() => import("../Manifest/Deploy"));
const ManifestStatus = React.lazy(() => import("../Manifest/Status"));
const ManifestCreate = React.lazy(() => import("../Manifest/Create"));
const SiteRoutes = () => {
const { token, groups } = useUserContext();
@@ -42,22 +41,6 @@ const SiteRoutes = () => {
type={TYPES.PROTECTED}
token={token}
/>
<AuthRoute
path="/package-upload"
render={() => <FileUploadForm />}
type={TYPES.PROTECTED}
token={token}
groups={groups}
roles={[Roles.CREATE]}
/>
<AuthRoute
path="/updates"
render={() => <UpdatePackagesForm />}
type={TYPES.PROTECTED}
token={token}
groups={groups}
roles={[Roles.CREATE]}
/>
<AuthRoute
path="/update/:id"
render={() => <UpdatePackageEdit />}
@@ -123,7 +106,7 @@ const SiteRoutes = () => {
roles={[Roles.READ, Roles.CREATE]}
/>
<AuthRoute
path="/manifests"
path="/packages"
render={() => <Manifests />}
type={TYPES.PROTECTED}
token={token}
@@ -131,7 +114,7 @@ const SiteRoutes = () => {
roles={[Roles.READ, Roles.CREATE]}
/>
<AuthRoute
path="/manifest-deploy/:manifest_id"
path="/package-deploy/:manifest_id"
render={() => <ManifestDeploy />}
type={TYPES.PROTECTED}
token={token}
@@ -139,13 +122,21 @@ const SiteRoutes = () => {
roles={[Roles.CREATE]}
/>
<AuthRoute
path="/manifest-status/:manifest_id"
path="/package-status/:manifest_id"
render={() => <ManifestStatus />}
type={TYPES.PROTECTED}
token={token}
groups={groups}
roles={[Roles.READ, Roles.CREATE]}
/>
<AuthRoute
path="/package-create"
render={() => <ManifestCreate />}
type={TYPES.PROTECTED}
token={token}
groups={groups}
roles={[Roles.CREATE]}
/>
<PageNotFound />
</Switch>
</Suspense>