At work, for the last couple weeks we have been refactoring a system of our software. We offer a standalone desktop version (where most data processing happens) and a 'Web Portal' as an add-on to allow a company's customers to preview the data that the company has. I was in charge of implementing the new process on the Web Portal. One of these features is a 'Waste Report' which collates a group of records with varying Weights and Percentages. However this is not relevant. I'm writing this post to reflect on a terrible hack I implemented in the server side code to output the Pie Charts to represent the data. As I was rushing to get this done, instead of creating multiple endpoints to gather the data needed and then generating the waste chart on the client side , I hacked it all into one response on the server. I did this because the Web Portal is built as a monolith using primitive PHP for frontend and backend, and since I want the Web Portal to function as a we...
Romans' Dev-ventures
I dunno what im doing but im trying my best