Restock

Restock Used AI

5 devlogs
14h 12m
Created by Galaxic dev

Restockis a simple but yet effective android kotlin app to manage your pantry's stock and automatically generate a shopping list.
Simply scan the item you took and let restock do the rest.

Timeline

Earned sticker

This last hour I integrated a system that allows the users to create storages.
Originally I wanted to keep this all on the system as a local DB, but since we want to have the ability to sync with other people and let them also add items we needed to make a central database that holds this info.
For this I choose appwrite, since you get a very generous tier with github education.
I had some challanges with the new TablesDB since I could only find documentation for the old Databases system. But after looking some deeper I was able to create it. The UI is still fairly simple and the system can become way more advanced. During the next hour I will make it so you can share storages with other people, and that you can actually open the storage and add items etc.

Update attachment

This is a rather short devlog.
Since I didn't want to make the previous devlog 8h+, I didn't include this yet.
During these 26 minutes I added persistent login.
In the previous devlog I added appwrite authentication with oauth and password.
But since it wasn't yet persistent, you needed to login every time you opened the app. This is a big dealbreaker.
To make this system we try to get the users session at the start of the app, if there is an active session the user can pass, else the user will be redirected to the login screen.
To make sure the user doesn't see the login screen before we can check if he/she is logged in, I added an loading screen that doesn't go away before the check is complete.
In the next devlog I will add the screens back from devlog 1&2 and possibly add an option to create a shared/family storage.

Update attachment

After a whole fight with firebase oauth I finally was able to add an authentication system using appwrite, since firebase wouldn't work for me.
Currently the system only allows you to create an account and log in, it doesn't yet redirect you to the main app. In the next few hour I will try to optimise the authentication logic and add a callback to navigate the user to the main app, if he is logged in.

With firebase I was able to get an whole auth flow, but for some reason google oauth wouldn't work. I tried everything to fix this, but after some frustrating hours/days I decided to switch to appwrite, since I already have an app with oauth that works with appwrite.
I cloned the appwrite starter repo, that they give you when you create an android project. I then connected everything to my appwrite project, followed by creating the login/register flow. The UI is still not like I would love it to be, but this is an nice to have that doesn't have priority.

Update attachment

During the last 2h I added the item/folder list with some hard coded data for now. The list still needs a lot of improvement and a reworked design. Since I am not good at designing actually pretty and usable interfaces, I used Claude 4 along with a figma drawing and some extra context of how it should look to create this UI. It uses a item/folder system to make it less cluttered and give you the ability to sort the items into different category's/storage locations.
For this list we currently use a normal column, but this will need to be changed to a lazycolumn in order to maximise performance. A LazyColumn only loads the items that are currently visible, instead of all the 100's of items that are under it and will need some scrolling to get to.
I also followed the google ML barcode scanning docs to create the backend of the barcode scanning system that will be a big part of entering and removing items from the list.
Again since this is my first app and I'm no design artist I asked Claude 3.7 to design a overlay for the camera that will show the user where to hold the camera, along with a fake scanning line for aesthetics.
Next I will create a system that will search the barcode up and fetch the details from the openfoodfacts database (very great system, check out for sure!) and automatically fetch the image and details and fill them in into the add product page (or show the product if they found it)

Update attachment

During these first few hours I watched a couple video's and asked AI for code examples in order to learn the basics of kotlin android apps.
I went to the google material UI 3 documentation and tried to implement a simple bottom navigation bar and a simple header for all the pages.
I had some issues with getting the padding for the headers correct (pages had different paddings for some reason, making it ugly)
I still need to change the color theme a bit to match my color palette.
The next big thing I need to implement is a LazyCollumn list that will display all the items/category's in a nice way.

Update attachment