Easily Manage Billing and Time Tracking

Plug It serves as a co-working space and studio hub catering to both working professionals and university students.

My friend Chan, a former colleague, has ventured into the co-working space industry and reached out to me to develop a system for monitoring their daily sales. I'm thrilled about this opportunity as it marks my first real-world project beyond creating simple ToDo apps, and it's a chance to leverage my expertise with Laravel into a successful venture.

Functional Requirements:

  • Track customer check-ins and check-outs.
  • Manage subscription plans (yearly, monthly, weekly).
  • Calculate total payments based on usage.
  • Provide a real-time overview of current customer activity.

The Challenge:

/**
* Get the current shift of the office hours.
*
* Since the office's shift is between two days (12pm - 6am),
* we have to use the current time to determine what the shift is.
*
* @return string
*/

private static function shift()
{
    $now = now()->setTime(11, 0, 0);

    /**
        * If the current time is before 12pm, then we'll assume we're
        * still supposed to be looking at yesterday's transactions.
        */
    if (now()->format('H') < 11) {
        $now->subDays(1);
    }

    return $now->format('Y-m-d H:i:s');
}

Other thing I Learned

I haven't experienced deploying a Laravel app before, gladly the internet is generous with resources, also, the app needs to be deployed locally but the thing is Chan wants to access the system anywhere.

php artisan serve --host 192.168.1.12 --port 80

Note: Change the host based on your IP Address

I feel like I have so much stuff I need to improve, eloquent, queries, better model structure, and a lot more, but I'm pretty happy with the result, knowing that they actually use it and the client is happy about it.