Skip to content

Implement Job Management Functionality #38

@AhmedFatthy1040

Description

@AhmedFatthy1040

Issue Title: Implement Job Management Functionality

Issue Description:

As a client, I want to manage my job listings effectively so that I can view, update, or delete my jobs as needed. This functionality should provide endpoints for clients to interact with their job postings.

Tasks:

  1. Get All Jobs:

    • Create an endpoint in the JobController to retrieve all job listings posted by the authenticated client.
    • Implement pagination to limit the number of jobs returned in a single request.
  2. Get Specific Job by ID:

    • Create an endpoint to fetch details of a specific job posted by the authenticated client using its job ID.
  3. Update Job:

    • Create an endpoint to allow clients to update the details of their job postings.
    • Ensure that only the client who created the job can update it.
  4. Delete Job:

    • Create an endpoint to allow clients to delete their job postings.
    • Implement checks to ensure that only the client who created the job can delete it.

Acceptance Criteria:

  • Get All Jobs:

    • Clients should be able to make a GET request to /jobs to retrieve their job listings.
    • Return 200 OK with a list of jobs or 204 No Content if no jobs are found.
  • Get Specific Job by ID:

    • Clients should be able to make a GET request to /jobs/{jobId} to retrieve a specific job.
    • Return 200 OK with job details or 404 Not Found if the job does not exist.
  • Update Job:

    • Clients should be able to make a PUT request to /jobs/{jobId} to update their job details.
    • Return 200 OK if the update is successful or 400 Bad Request if invalid data is provided.
  • Delete Job:

    • Clients should be able to make a DELETE request to /jobs/{jobId} to delete their job postings.
    • Return 204 No Content if the deletion is successful or 404 Not Found if the job does not exist.

Endpoint Specifications:

  • Get All Jobs:

    • Method: GET
    • URL: /jobs
  • Get Specific Job by ID:

    • Method: GET
    • URL: /jobs/{jobId}
  • Update Job:

    • Method: PUT
    • URL: /jobs/{jobId}
    • Request Body Example:
      {
        "title": "Updated Job Title",
        "description": "Updated job description.",
        "budget": 600.00,
        "job_type": "Hourly"
      }
  • Delete Job:

    • Method: DELETE
    • URL: /jobs/{jobId}

Metadata

Metadata

Assignees

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions