0% found this document useful (0 votes)
7 views16 pages

Frs for Add Vendors

The document details the Functional Requirements Specification for a Supplier Management System, which aims to streamline supplier information management. It outlines the user interface, functionalities for adding and managing supplier details, and includes sections on personal and company information, balance and credit management, and order history. Additionally, it specifies non-functional requirements such as usability, performance, and security, along with API endpoints for various operations related to suppliers.

Uploaded by

HYPER Rishabh
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
7 views16 pages

Frs for Add Vendors

The document details the Functional Requirements Specification for a Supplier Management System, which aims to streamline supplier information management. It outlines the user interface, functionalities for adding and managing supplier details, and includes sections on personal and company information, balance and credit management, and order history. Additionally, it specifies non-functional requirements such as usability, performance, and security, along with API endpoints for various operations related to suppliers.

Uploaded by

HYPER Rishabh
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 16

Functional Requirements Specification (FRS) Document

Document Title: supplier Management System

1. Introduction
This document outlines the functional requirements for the supplier Management
System, designed to streamline the process of adding, managing, and viewing
supplier details. The system will provide functionalities for entering personal and
company details, managing balance and credit information, and categorising
suppliers based on their role as buyers or suppliers.
2. Scope
The scope of this document covers the user interface and functionalities related to
adding and managing supplier information. This includes data input fields, dropdown
menus, buttons, and other interactive elements as shown in the provided design
sketch.

3. Functional Requirements
3.1 supplier Management Interface
Module Name: Add supplier
Purpose: To allow users to add new suppliers by entering their personal and company
information, and manage existing supplier records.
3.2 Personal Details Section
Fields:
Name: A text field to input the supplier's name.
Email: A text field to input the supplier's email address.
Phone: A text field to input the supplier's phone number.
Manage Person Details: I this option he should be able to add more person details.
3.3 Balance and Credit Information
Fields:
Balance: A numeric field to display the current balance associated with the
supplier.
Credit: A numeric field to display the credit amount available to the supplier.
Radio Buttons:
Buyer: To categorize the supplier as a buyer.
Supplier: To categorize the supplier as a supplier.
Both: To categorize the supplier as both buyer and supplier.
3.4 Company Information Section
Fields:
Company Name: A text field to input the name of the supplier's company.
Address: A text field to input the company's address.
Email ID: A text field to input the company's email address.

3.5 Additional Company Details


Tabs/Sections:
Overview: Provides a general view of the company details.
GST Number: A text field to input the company's GST number.
GST Type Dropdown: A dropdown to select the GST type (e.g., UNknown, resgistererd).
3.6 supplier Products and Order History
supplier Products: A section where users can add and manage the list of products
supplied by the supplier.
Order History: A section to view the order history related to the supplier.
3.7 Additional Functionalities
Buttons:
Deactivate: A button to deactivate the supplier.
Create New PO: A button to create a new purchase order.
Print: A button to print supplier details.
Email: A button to send an email to the supplier.
3.8 Contact Details
Fields:
Company Address 1: A text field to input an additional company address.
Contact Number: A text field to input a secondary contact number.
3.9 Add Notes Section
Notes: A text area or similar input field to add notes related to the supplier.

4. Non-Functional Requirements
Usability: The interface should be user-friendly and intuitive, with clear labels
for each input field and action button.
Performance: The system should respond promptly to user actions, with a maximum
load time of 2 seconds for any operation.
Security: Sensitive information, such as balance and credit details, should be
stored securely with appropriate access controls.
Scalability: The system should be capable of handling a large number of suppliers
without degradation in performance.

5. Assumptions and Dependencies


The system assumes that the user has the necessary permissions to add, edit, or
deactivate supplier information.
The system relies on an existing database for storing supplier details, which
should be designed to accommodate the data fields described in this document.

6. Glossary
PO: Purchase Order
GST: Goods and Services Tax

7. Revision History

Version
Date
Description
Author
1.0
03/09/2024
Initial Draft
Vishal Ojha
API DOCUMENT FOR THE ADD suppliers PAGE

Database Schema for the Supplier

CREATE TABLE supplier_master (


supplier_id INT AUTO_INCREMENT PRIMARY KEY,
supplier_name VARCHAR(255) NOT NULL,
supplier_code VARCHAR(100) UNIQUE,
contact_person_first_name VARCHAR(255),
contact_person_last_name VARCHAR(255),
contact_email VARCHAR(255),
contact_phone VARCHAR(20),
address_line1 VARCHAR(255),
address_line2 VARCHAR(255),
city VARCHAR(100),
state VARCHAR(100),
postal_code VARCHAR(20),
country VARCHAR(100),
gst_number VARCHAR(50),
payment_terms VARCHAR(255),
currency VARCHAR(3) DEFAULT 'USD',
bank_account_number VARCHAR(50),
bank_name VARCHAR(255),
bank_ifsc_code VARCHAR(20),
lead_time_days INT DEFAULT 0,
supplier_rating DECIMAL(3, 2) DEFAULT 0.00,
supplier_category VARCHAR(100),
credit_limit DECIMAL(15, 2) DEFAULT 0.00,
discount_terms VARCHAR(255),
is_preferred_supplier BOOLEAN DEFAULT FALSE,
tax_country_code VARCHAR(3),
tax_registration_number VARCHAR(50),
contract_start_date DATE,
contract_end_date DATE,
discount,
supplier_website VARCHAR(255),
supplier_notes TEXT,
payment_method VARCHAR(100),
supplier_certifications VARCHAR(255),
is_active BOOLEAN DEFAULT TRUE,
created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP,
updated_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP
);
API FOR DELETING THE supplier

Method :POST
API Endpoint : /api/delete-_supplier
Caller : UI/User
Request Body:

{
"delete_supplier": {
"supplier_name": "NESTBOTICS"
}
}

Response Body:
{
"status": 200,
"message": "Supplier Deleted Successfully",
"data": {
"deleted_supplier": "PRD "
}
}

API for Add Supplier

This API allows the user to submit personal information for a supplier such as
Name, Email and Phone Number . The data is captured through a form on the frontend
and submitted to the backend API.

Method :POST
API Endpoint : /api/add-supplier
Caller : UI/User

Request Body :

This request body is in JSON Format , containing the supplier’s Personal details
captured from fields . Each Key represents the data entered by the user in the
form.

Request Payload:

{
"add_supplier": {

"salutation": "Mr.",
"first_name": "Rishabh"l,
"last_name": "kk"l,
"phone": "1234567890",
"email": "rishabh@example.com”,
"designation": "Manager",
"gst_number": "GST123456”,
"gst_type": "Regular" ,
“supplier_name”:”xyz”,
“supplier_email”:”xzt@gail.com”,
“supplier_display_name”:”xyz”,
“payment_method” :”xyz”,
“discount”:00,
“currency”:”rupee”,
}
}

Response Payload:

{
"status": 200,
"message": "supplier Added Successfully",
"data": {
"supplier_name": "PRD " }
}

Incase of error
{
"status": 500,
"message": "Internal Server Error",
"data": {
"supplier_name": "Error Adding Supplier " }
}

API for Balance and Credit/opening balance

This Component will fetch the balance and credit data from the backend API and
Update the values Dynamically in the Frontend. The Values will replace the Dummy
value ( 0.00) .

Method : GET
API Endpoint : /api/get-balance-credit

Response:

The API returns the balance and Credit amounts in JSON Format, Which are then set
in the components state.
Response Payload:

{
"Balance": 15000,
"Credit": 1000
}

Request Payload:
{
"balance_credit": {
"supplier_name": 244343
}
}

Response Payload Description:

Balance : The Balance of the Add supplier’s Balance value.


Credit : The Credit of the Add supplier’s Credit value.

API For Order History

This API retrieves the list of orders from the database. The retrieved data
is then displayed in the user interface in a tabular format.

Method : GET
API Endpoint : api/supplier-order-information
Caller : UI/User
Request:
{
"order_history": {
"supplier_name": "PRD"
}
}

Response Payload:

{
"status": "success",
"message": "History Orders retrieved successfully",
"data": [
{
"supplier_name": "prd",
"order_history": [
{
"Order ID": 112223,
"Date": "04/09/2024",
"Total Amount": 60000,
"Location": "Noida"
},
{
"Order ID": 2333,
"Date": "04/08/2024",
"Total Amount": 56565,
"Location": "Delhi"
},
{
"Order ID": 4543,
"Date": "24/08/2024",
"Total Amount": 56565,
"Location": "Noida"
}
],
"supplier_info": {
"supplier_Id": 12345,
"contact_person_name": "ABC",
"contact_email": "ABC@example.com",
"contact_phone": "1234567890",
"gst_number": "GSTIN12345678",
"supplier_contact": 12135565,
"supplier_address_1": "vihar colony",
"supplier_address_2": "Delhi",
“supplier_address_1”: “meerut”,
supplier_address_2:supplierInfo.SUPPLIER_ADDRESS_2,
"supplier_address": "XTY",
"supplier_email_details": "snjbs@gmail.com"
}
}
]
}

Response Payload Description:


The response contains an array of JSON objects representing the contents of each
order. Each element has the following key pairs

Order ID: The unique identifier of the order.


Date: The date when the order was placed.
Total Amount: The total value of the order.
Location: The place from which the order originated.
API FOR UPDATING THE SKU WITH THE SUPPLIER

POST /api/supplier-sku-mapping
This endpoint allows the mapping of a SKU to a specific supplier.
REQUEST:
{
"supplier_name": "ABC Supplies",
"user_name": "karan",
"data": [
{
"sku_id": "SKU001"
},
{
"sku_id": "SKU002"
}
]
}

RESPONSE:
{
"status": "success",
"message": "SKU mappings for the supplier have been successfully saved",
"supplier_id": "SUP123",
"mapped_skus": [
{
"sku_id": "SKU001"
},
{
"sku_id": "SKU002"
}
]
}

{
"status": "error",
"message": "Error in Adding the item vendor mapping.",
"supplier_id": "SUP123",
"sku_mappings": []
}


API for Fetch supplier/supplier info
This API allows users to retrieve the contact person and supplier form details

Method: GET
API Endpoint: /api/get-supplier/{supplier_id}
Caller: UI/User
Response Payload as successful:
{
"status": 200,
"message": "supplier Details Retrieved Successfully",
"data": { "salutation": "Mr.",
"first_name": "Rishabh"l,
"last_name": "kk"l,
"phone": "1234567890",
"email": "rishabh@example.com”,
"designation": "Manager",
"gst_number": "GST123456”,
"gst_type": "Regular" ,
“supplier_name”:”xyz”,
“supplier_email”:”xzt@gail.com”,
“supplier_display_name”:”xyz”,
“payment_method” :”xyz”,
“discount”:00,
“currency”:”rupee”,}}
Response Payload as an Error:
{
"status": 400,
"message": "supplier Not Found",
"data": {
"supplier_id": "{supplier_id}",
"error": "No supplier found with the given ID"
}
}

Response Payload for Internal Server Error:


{
"status": 500,
"message": "Internal Server Error",
"data": {
"supplier_id": "{supplier_id}",
"error": "Error in Fetching supplier Details"
}
}

⦁ API for Fetch Delivery Address:


This API allows users to retrieve delivery address details..

Method: GET
API Endpoint: /api/get-delivery-address/{supplier_id}
Caller: UI/User
Response Payload as successful:{
"status": 200,
"message": "Delivery Addresses Retrieved Successfully",
"data": [
{
"supplier_id": "supplier_id",
"delivery_address_name": "delivery_address_name",
"address_lane1": "456 Delivery St",
"address_lane2": "Suite 200",
"pincode": "987654",
"city": “muradnahgars",
"state": "Uttar Pradesh",
"country": "India"
}
]
}

Response Payload as an Error (Not Found):{


"status": 404,
"message": "Delivery Address Not Found",
"data": {
"error": "No delivery addresses found for the given supplier id"
}
}
Response Payload for Internal Server Error:
{
"status": 500,
"message": "Internal Server Error",
"data": {
"error": "Internal Server Error"
}
}

Add or Edit Delivery Address


Method: POST
Endpoint: /api/add-edit-delivery-address
Description: Allows users to add a new delivery address or edit an existing one for
a specified supplier.
Caller: UI/User
Request Payload:
{
"add_edit_delivery_address": {
"supplier_id": "12345",
"new_delivery_address_name": "Main Warehouse",
"address_lane1": "123 Delivery St",
"address_lane2": "Building B",
"pincode": "110011",
"city": "muradnagar",
"state": "Uttar Pradesh",
"country": "India"
}
}

Response Payloads
1. Success Response for Update:
{
"status": 200,
"message": "Delivery Address Updated Successfully",
"data": {
"delivery_address_id": "123456"
}
}

Error Response

{
"status": 500,
"message": "Internal Server Error",
"data": {
"delivery_address_name": "Error in Adding/Updating Delivery Address"
}
}

⦁ API for Fetch Billing Address :


This API allows users to retrieve billing address details

Method: GET
API Endpoint: /api/get-billing-address/{supplier_id}
Caller: UI/User
Response Payload as successful:
{
"status": 200,
"message": "Billing Addresses Retrieved Successfully",
"data": {
"supplier_id": "{supplier_id}",
"billing_address_name": "{billing_address_name}",
"address_line1": "321 Updated St",
"address_line2": "Apt 5A",
"pincode": "987654",
"city": “muradnagar",
"state": "Uttar Pradesh",
"country": "India"
}
}
Response Payload as an Error (Not Found):
{
"status": 404,
"message": "Billing Address Not Found",
"data": {
"error": "No billing address found with the given supplier id"
}
}
Response Payload for Internal Server Error:
{
"status": 500,
"message": "Internal Server Error",
"data": {
"error": "Internal Server Error"
}
}

Add Billing Address


Method: POST
Endpoint: /api/add-billing-address/{supplier_id}
Description: Adds a new billing address for a specified supplier.
Caller: UI/User
Request Body:
Path Parameter:
supplier_id (string): Unique identifier for the supplier for whom the billing
address is to be added.

Body Payload
{
"billing_address_name": "billing_address_name",
"address_line1": "321 Updated St",
"address_line2": "Apt 5A",
"pincode": "987654",
"city": "Muradnagar",
"state": "Uttar Pradesh",
"country": "India"
}
Error Response (Duplicate)
{
"status": 409,
"message": "Duplicate Entry",
"data": {
"error": "Billing address for this supplier already exists"
}
}

API for payment History


This API provides historical payment data for a specific supplier, including unpaid
amounts categorized by due date range and total amount due.
Method: GET
Endpoint: /api/get-payment-history/{supplier_id}/
Caller: UI/User
Response Payload as successful:
{
"status": 200,
"message": "Payment History Retrieved Successfully",
"data": {
"supplier_id": "supplier_id",
"unpaid_amounts": {
"not_yet_due": "0.00",
"due_1_30_days": "0.00",
"due_30_60_days": "0.00",
"due_60_plus_days": "0.00"
},
"due_total": "0.00"
}}
Response Payload as an Error (Not Found):
{
"status": 404,
"message": "payment Not Found",
"data": {
"error": "No payment found with the given supplier id"
}
}
Response Payload for Internal Server Error:
{
"status": 500,
"message": "Internal Server Error",
"data": {
"error": "Internal Server Error"
}
}

API For Update information of supplier


This API allows the user to Update personal information for a supplier such as
Name, Email and Phone Number based on the given supplier id.

Method : PUT
API Endpoint : api/edit-supplier

Request Payload:

{
"update_supplier": {
"salutation": "Mr.",
"first_name": "Rishabh"l,
"last_name": "kk"l,
"phone": "1234567890",
"email": "rishabh@example.com”,
"designation": "Manager",
"gst_number": "GST123456”,
"gst_type": "Regular" ,
“supplier_name”:”xyz”,
“supplier_email”:”xzt@gail.com”,
“supplier_display_name”:”xyz”,
“payment_method” :”xyz”,
“discount”:00,
“currency”:”rupee”,
}
}

Response Payload:
{
"status": 200,
"message": "supplier Updated Successfully",
"data": {
"supplier_name": "PRD"
}
}

⦁ API for Add or Edit supplier Details from Modal:


This API allows users to either add a new supplier details or edit an existing
supplier's details, depending on whether the `supplier_id` is provided.

Method: POST
API Endpoint: /api/add-edit-supplier-details
Caller: UI/User

This request body is in JSON Format containing supplier details.


{
"supplier_id": "12345",
"add_edit_supplier_details": {
"supplier_type": “1" or “0".
"supplier_name": "Rishabh",
"supplier_email": "rishabh@example.com”,
"gst_number": "GST123456" ,
"gst_type": "Regular"
}
}

Response Payload as successful:


{
"status": 200,
"message": "supplier Details Added/Updated Successfully",
"data": {
"supplier_id": "{supplier_id}",
}
}

Response Payload as an Error:


{
"status": 500,
"message": "Internal Server Error",
"data": {
"supplier_id": "Error in Adding/Updating supplier"
}
}
⦁ API for Add or Edit Contact Details from Contact Details Modal:
This API allows users to submit new contact details or edit existing contact
details for a specific supplier, identified by `supplier_id`.

Method: POST
API Endpoint: /api/add-edit-contact-details
Caller: UI/User

Request Body:
{
"supplier_id": "12345",
"contact_details": {
"salutation": "Mr.",
"first_name": "Rishabh",
"last_name": "kumar",
"phone": "987xxxx10",
"email": "rishabh@example.com",
"designation": “xyz"
}
}

Response Payload as successful for Add:


{
"status": 201,
"message": "Contact Added Successfully",
"data": {
"supplier_id": "12345",
}
}

Response Payload as successful for Update:


{
"status": 200,
"message": "Contact Details Updated Successfully",
"data": {
"supplier_id": "12345",
}
}

Response Payload as an Error:


{
"status": 500,
"message": "Internal Server Error",
"data": {
"contact_name": "Error in Adding/Updating Contact"
}
}
⦁ API for Get Order History
This API allows users to retrieve order details for a specific customer based on
`customer_id`.

Method: GET
API Endpoint: /api/get-orders/{customer_id}/
Caller: UI/User

Response Payload as successful:


{
"status": 200,
"message": "Orders Retrieved Successfully",
"data": [
{
"orderId": "12345",
"date": "2024-09-20",
"status": "Delivered",
"locationCity": "New York",
"totalAmount": "$500",
"balanceAmount": "$0"
},
{
"orderId": "12346",
"date": "2024-09-21",
"status": "Pending",
"locationCity": "Los Angeles",
"totalAmount": "$300",
"balanceAmount": "$150"
}
// More orders can be included here
]
}

Response Payload as an Error (Not Found):


{
"status": 404,
"message": "No Orders Found",
"data": {
"error": "No orders found for the given customer id"
}
}

Response Payload for Internal Server Error:


{
"status": 500,
"message": "Internal Server Error",
"data": {
"error": "Internal Server Error"
}
}

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy