Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Indy join class request page #79

Merged
merged 9 commits into from
Dec 9, 2024
Merged

Conversation

faucomte97
Copy link
Contributor

@faucomte97 faucomte97 commented Nov 18, 2024

This change is Reviewable

@faucomte97 faucomte97 self-assigned this Nov 18, 2024
@faucomte97 faucomte97 linked an issue Nov 18, 2024 that may be closed by this pull request
2 tasks
@faucomte97 faucomte97 marked this pull request as ready for review November 20, 2024 12:25
Copy link
Contributor

@SKairinos SKairinos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed 6 of 6 files at r1, all commit messages.
Reviewable status: all files reviewed, 11 unresolved discussions (waiting on @faucomte97)


-- commits line 1 at r1:
general comment: need to update the PR name to follow semantic release conventions


src/pages/studentJoinClass/StudentJoinClass.tsx line 6 at r1 (raw file):

import type { SessionMetadata } from "codeforlife/hooks"
import { Typography } from "@mui/material"
import { handleResultState } from "codeforlife/utils/api.tsx"

no file extension codeforlife/utils/api. Please remove file extensions from all imports


src/pages/studentJoinClass/StudentJoinClass.tsx line 43 at r1 (raw file):

              details.
            </Typography>

delete blank line


src/pages/studentJoinClass/StudentJoinClass.tsx line 44 at r1 (raw file):

            </Typography>

            <UpdateRequestingToJoinClassForm

RequestToJoinClassForm


src/pages/studentJoinClass/StudentJoinClass.tsx line 45 at r1 (raw file):

            <UpdateRequestingToJoinClassForm
              indyUser={{

indyUser={user}


src/pages/studentJoinClass/RequestPending.tsx line 19 at r1 (raw file):

  const school = result.data

  if (!school) return <CircularProgress />

please use the util: handleResultState (this is what it's for)

Code quote:

  const result = useRetrieveSchoolQuery(user.requesting_to_join_class!.school)
  const school = result.data

  if (!school) return <CircularProgress />

src/pages/studentJoinClass/RequestPending.tsx line 44 at r1 (raw file):

        decision.
      </Typography>

delete blank line


src/pages/studentJoinClass/RequestPending.tsx line 46 at r1 (raw file):

      <Stack direction="row" spacing={2}>
        <Button

Please use LinkButton component instead.

import {LinkButton} from "codeforlife/components/router"


src/pages/studentJoinClass/UpdateRequestingToJoinClassForm.tsx line 21 at r1 (raw file):

  return (
    <>

delete. only one top-level component.


src/pages/studentJoinClass/UpdateRequestingToJoinClassForm.tsx line 51 at r1 (raw file):

          required
        />

delete blank line.


src/pages/studentJoinClass/UpdateRequestingToJoinClassForm.tsx line 53 at r1 (raw file):

        <Stack direction="row" spacing={2} paddingY={3}>
          <Button

Use LinkButton

Copy link
Contributor Author

@faucomte97 faucomte97 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewable status: all files reviewed, 11 unresolved discussions (waiting on @SKairinos)


-- commits line 1 at r1:

Previously, SKairinos (Stefan Kairinos) wrote…

general comment: need to update the PR name to follow semantic release conventions

Done.


src/pages/studentJoinClass/RequestPending.tsx line 19 at r1 (raw file):

Previously, SKairinos (Stefan Kairinos) wrote…

please use the util: handleResultState (this is what it's for)

Done.


src/pages/studentJoinClass/RequestPending.tsx line 44 at r1 (raw file):

Previously, SKairinos (Stefan Kairinos) wrote…

delete blank line

Done.


src/pages/studentJoinClass/RequestPending.tsx line 46 at r1 (raw file):

Previously, SKairinos (Stefan Kairinos) wrote…

Please use LinkButton component instead.

import {LinkButton} from "codeforlife/components/router"

Done, also path was wrong.


src/pages/studentJoinClass/StudentJoinClass.tsx line 6 at r1 (raw file):

Previously, SKairinos (Stefan Kairinos) wrote…

no file extension codeforlife/utils/api. Please remove file extensions from all imports

Done.


src/pages/studentJoinClass/StudentJoinClass.tsx line 43 at r1 (raw file):

Previously, SKairinos (Stefan Kairinos) wrote…

delete blank line

Done.


src/pages/studentJoinClass/StudentJoinClass.tsx line 44 at r1 (raw file):

Previously, SKairinos (Stefan Kairinos) wrote…

RequestToJoinClassForm

Done.


src/pages/studentJoinClass/StudentJoinClass.tsx line 45 at r1 (raw file):

Previously, SKairinos (Stefan Kairinos) wrote…

indyUser={user}

image.png

😞


src/pages/studentJoinClass/UpdateRequestingToJoinClassForm.tsx line 21 at r1 (raw file):

Previously, SKairinos (Stefan Kairinos) wrote…

delete. only one top-level component.

Done.


src/pages/studentJoinClass/UpdateRequestingToJoinClassForm.tsx line 51 at r1 (raw file):

Previously, SKairinos (Stefan Kairinos) wrote…

delete blank line.

Done.


src/pages/studentJoinClass/UpdateRequestingToJoinClassForm.tsx line 53 at r1 (raw file):

Previously, SKairinos (Stefan Kairinos) wrote…

Use LinkButton

Done.

@faucomte97 faucomte97 changed the title Indy join class request page feat: Indy join class request page Nov 22, 2024
Copy link
Contributor

@SKairinos SKairinos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed 3 of 3 files at r2, all commit messages.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @faucomte97)


src/pages/studentJoinClass/StudentJoinClass.tsx line 45 at r1 (raw file):

Previously, faucomte97 (Florian Aucomte) wrote…

image.png

😞

Apologies. I forgot we were expanding the requesting_to_join_class field in portal. Then can just set it to

indyUser={{ id: user.id,  requesting_to_join_class: user.requesting_to_join_class.id }}

Copy link
Contributor

@SKairinos SKairinos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewable status: all files reviewed, 2 unresolved discussions (waiting on @faucomte97)


src/pages/studentJoinClass/RequestPending.tsx line 23 at r2 (raw file):

    useRetrieveSchoolQuery(user.requesting_to_join_class!.school),
    school => {
      return (

can just do

school => (
....
)

Code quote:

    school => {
      return (

Copy link
Contributor Author

@faucomte97 faucomte97 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewable status: all files reviewed, 2 unresolved discussions (waiting on @SKairinos)


src/pages/studentJoinClass/RequestPending.tsx line 23 at r2 (raw file):

Previously, SKairinos (Stefan Kairinos) wrote…

can just do

school => (
....
)

Done.


src/pages/studentJoinClass/StudentJoinClass.tsx line 45 at r1 (raw file):

Previously, SKairinos (Stefan Kairinos) wrote…

Apologies. I forgot we were expanding the requesting_to_join_class field in portal. Then can just set it to

indyUser={{ id: user.id,  requesting_to_join_class: user.requesting_to_join_class.id }}

image.png

Still doesn't like it

Copy link
Contributor Author

@faucomte97 faucomte97 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewable status: all files reviewed, 2 unresolved discussions (waiting on @SKairinos)


src/pages/studentJoinClass/StudentJoinClass.tsx line 45 at r1 (raw file):

Previously, faucomte97 (Florian Aucomte) wrote…

image.png

Still doesn't like it

nvm, fixed with !

Copy link
Contributor

@SKairinos SKairinos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed 2 of 2 files at r3, all commit messages.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @faucomte97)

@SKairinos SKairinos merged commit a6eb1f0 into main Dec 9, 2024
8 of 9 checks passed
@SKairinos SKairinos deleted the requesting_to_join_class branch December 9, 2024 09:37
@cfl-bot
Copy link
Collaborator

cfl-bot commented Dec 17, 2024

🎉 This PR is included in version 1.0.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

faucomte97 pushed a commit that referenced this pull request Dec 31, 2024
# 1.0.0 (2024-12-17)

### Bug Fixes

* otp deploy ([ef969b6](ef969b6))
* otp deploy ([#80](#80)) ([e622d4b](e622d4b))

### Features

* Indy join class request page ([#79](#79)) ([a6eb1f0](a6eb1f0))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

student dashboard - /independent/join
3 participants