Coder Social home page Coder Social logo

mycargonaut's Issues

Searchbar: create sql-queries

Create sql queries to get data from the database to filter for offers and wanted.
The query used is in the backend is in the file /routes/searchbar.js.
The query filters for the needed attributes in the searchbar.

Mockup

Multiple assignees: @hfdd02

Create the Mockup based on the Wireframe from Issue #1.

Add Nodemon to backend

Add the nodemon dependency to the backend and configure package.json to use nodemon for npm start

[User-Story] Als Suchender möchte ich nach Angeboten suchen, um die für mich passende Fahrt zu finden.

Overview

Als Suchender möchte ich nach Angeboten suchen, um die für mich passende Fahrt zu finden.

Subtasks

☑️ Definition of Done checklist

Frontend

  • Are all functions implemented?
  • Are there front-end tests that test the appearance of the mockup?
  • Do the associated components look like the mockup?

Backend

  • Are all necessary routes documented via swagger?
  • Are all necessary methods tested via Jest (positive and negative tests)?

Is the user story finished to such an extent that no further work is required after the pull request (excluding hotfixes and adjustments)?

Create readme.md

Create readme.md and insert first informations about the project.

Datenbankentitäten basierend auf Datenbankschema erstellen

Basiert auf #34

Possible SQL Query

Getting the rating for the user with userId = 1

SELECT r.ratingId, r.bookingId, r.userWhoIsEvaluating, r.userWhoWasEvaluated, 
       r.punctuality, r.agreement, r.pleasent, r.freight, r.comment
FROM rating r
JOIN user u ON r.userWhoWasEvaluated = u.userId
WHERE u.userId = 1;

Getting all ads from a user with userId

SELECT a.adId, a.startLocation, a.endLocation, 
       GROUP_CONCAT(ig.location SEPARATOR ', ') AS intermediateGoals,
       a.startDate, a.endDate, a.animals, a.smoker, a.notes, a.numSeats, u.userId as advertiserUserId
FROM ad a
JOIN user u ON a.userId = u.userId
LEFT JOIN intermediateGoal ig ON a.adId = ig.adId
WHERE u.userId = 1
GROUP BY a.adId;

Get all offers with at least 2 seats available

SELECT o.offerId, v.numSeats, v.vehicleId
FROM offer o
JOIN vehicle v ON o.vehicleId = v.vehicleId
JOIN ad a ON o.adId = a.adId
WHERE (v.numSeats - (
        SELECT COALESCE(SUM(b.numSeats), 0)
        FROM booking b
        WHERE b.adId = a.adId AND b.canceled = FALSE
    )) >= 2;

fix: backend NPM package manager

npm install
shell: /usr/bin/bash -e {0}
npm ERR! must provide string spec

npm ERR! A complete log of this run can be found in: /home/runner/.npm/logs/2023-12-04T065611781Z-debug-0.log
Error: Process completed with exit code 1.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.