Module to send medical log on mail

So… I made my first contrib module, and it’s now running on my production server.
:face_holding_back_tears:

When the vet has been here, he can create a medical log for the visit.

My module will send an email to the vet, with a summary of the medical log.
This will happen only if the veterinarian field matches the corresponding passive user in farmOS. (The email address is fetched from that user)

My module is a fork of @Farmer-Ed’s farm_withdrawal module.
I removed the calendar stuff completely, and added mail support.
Didn’t have a clue about php, but learned with ChatGPT along the process.

I currently use PHPMailer SMTP module for mail. Not sure if that is the most common way, but it wors for now.

Next up is to make a quickform with @paul121’s template module.

4 Likes

Awesome @pat!!

I haven’t tried that one myself, but good to know it works! There are a few options out there depending on how your server is set up. We document some options here: Email configuration | farmOS

1 Like