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: basic chat implementation #3

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open

feat: basic chat implementation #3

wants to merge 5 commits into from

Conversation

joakimunge
Copy link
Collaborator

@joakimunge joakimunge commented Jul 15, 2024

Implements rudimentary chat functionality across tender requests.
Also sends notification to all participants (including the sender for demo purposes).

Note: Also resolves some dependencies that were present in package-lock.json but omitted from package.json. If this was intended in anyway, feel free to let me know so that I can revert those changes.

@joakimunge joakimunge requested a review from luciadabezies July 15, 2024 10:42
@@ -5,7 +5,7 @@ import io from 'socket.io-client'
export const SocketContext = createContext()

export const SocketProvider = ({ children }) => {
const socket = io('https://skaff-api.iteam.pub')
const socket = io('http://localhost:3000')
Copy link
Collaborator

Choose a reason for hiding this comment

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

Not sure if we want to commit this?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

No we do not! Thanks!

state.tenderRequests[tenderRequestIndex].messages = [
...tenderRequest.messages,
message,
]
Copy link
Collaborator

Choose a reason for hiding this comment

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

Just to be sure I'm getting it, if we add the messages to the tender can we somehow filter them to only show the messages sent between the buyer (who published the tender) and each producer separately? Or do we show all the messages that are involved in the tender to every user?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Currently we show every message to everyone that is in the tender. I was not sure how the implementation was supposed to work, but since its a POC i think its fine?

Copy link
Collaborator

Choose a reason for hiding this comment

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

Yes! I guess for a POC is enough, just wanted to make sure I was understanding correctly, it looks good then💃🏽

@joakimunge joakimunge requested a review from luciadabezies July 16, 2024 10:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants