Pharmasight, a comprehensive sales data visualization platform designed to revolutionize pharmaceutical sales analysis in Bangladesh. Pharmasight is designed to provide users with an interactive platform to explore and analyze pharmaceutical sales data effectively. It’s tailored to the needs of pharmaceutical companies, sales teams, market analysts, and policymakers to ensure better decision-making through data-driven insights.
--
This project was previously hosted on Pharmasight Live Demo,but the deployment link is no longer active.
To test locally, follow the setup instructions below.
- Java 11 or higher
- Node.js and npm
- MySQL Server
git clone https://github.com/mondrita/Pharmasight.git
cd Pharmasightcd pharmasight-backend/pharmasight- Create a MySQL database named
pharmasightdb - Import the SQL file:
mysql -u your_username -p pharmasightdb < ../../pharmasightDB.sql- Update
application.propertieswith your MySQL credentials - Run the app:
./mvnw spring-boot:run
# or
mvn spring-boot:runBackend will run on http://localhost:8080
cd ../../../pharmasight-frontend
npm install
ng serveFrontend will run on http://localhost:4200
- Username:
tahsin - Password:
123456
For any issues or feature ideas, feel free to open an issue or fork the repo!
- Users can effortlessly locate sales data by applying four mandatory filters: Generic, Vendor, Start Date, and End Date.
- The search results dynamically populate in both a table and a map format, ensuring clarity and convenience for users with varied preferences.
- Sales data is visually represented on an interactive map of Bangladesh, where each location is marked with sales performance metrics for quick identification.
- Users can drill down into specific divisions by clicking on them. The selected division zooms in for a closer view, and its border is highlighted for clarity.
- At the division level, district-wise sales data is displayed on the map, with each district marked distinctly to provide granular insights into sales distribution.
- Dedicated insights on top-performing drug brands and their sales data are provided through separate tabs.
- Market share analysis for each brand and drug is presented, allowing users to identify leading players and assess competitive performance.
- Specific drug performance, including highest and lowest sales months and regions, is also highlighted to support strategic decision-making.
- Sales data can be seamlessly downloaded in Excel format.
- This feature supports offline reporting and further detailed analysis, ensuring flexibility for users.
- Backend: Spring Boot
- Frontend: Angular
- Database: MySQL
- Mapping: OpenStreetMap
- Security: Spring Security
- Languages: Java, TypeScript, HTML, CSS
| Endpoint | Method | Description | Parameters/Request Body | Response |
|---|---|---|---|---|
/division/boundary |
GET | Get GeoJSON data by division name | name (String, query parameter) |
200 OK: Returns DivisionDto containing division details. |
/division/district-coordinates |
GET | Get district coordinates | divisionId (Long, query parameter) |
200 OK: Returns a list of DistrictDTO containing district coordinates. |
/export-excel |
GET | Export Excel report | Accepts SearchCriteriaDTO as query parameters |
200 OK: Returns an Excel file (application/octet-stream). |
/upload/geojson/{id} |
POST | Upload GeoJSON file | id (Long, path), file (MultipartFile) |
200 OK: Success message or 500 Internal Server Error: Error message. |
/generic/search |
GET | Get generic suggestions | prefix (String, query), limit (Integer, optional) |
200 OK: Returns a list of Generic suggestions. |
/sales-info/demographic |
GET | Get demographic sales data | Accepts SearchCriteriaDTO as query parameters |
200 OK: Returns DemographicDTO. |
/sales-info/top-brands |
GET | Get top brands | Accepts SearchCriteriaDTO as query parameters |
200 OK: Returns a list of TopDrugDTO. |
/sales-info/demographic-districts |
GET | Get district sales data | Accepts SearchCriteriaDTO as query parameters |
200 OK: Returns a list of DistrictSalesDTO. |
/sales-info/district-market-share |
GET | Get district market share | Accepts SearchCriteriaDTO as query parameters |
200 OK: Returns a list of DistrictMarketShareDTO. |
/sales-info/Drug-report |
GET | Get drug report | Accepts SearchCriteriaDTO as query parameters |
200 OK: Returns DrugReportDTO. |
/ |
GET | Server status check | None | 200 OK: "Server is On" or 500 Internal Server Error: "Internal Server Error". |
/register |
POST | Register user | User (Request Body) |
200 OK: Returns the registered User. |
/login |
POST | User login | UserLoginDTO (Request Body) |
200 OK: Returns a token or 401 Unauthorized: Authentication failed. |
/vendor/search |
GET | Get vendor suggestions | prefix (String, query), limit (Integer, optional) |
200 OK: Returns a list of VendorDTO suggestions. |













