California law is just as bad.
There are lots of bad old laws on the books that came from attempts to make sure that black people were disarmed.
If I remember accurately...the current statute permits you to transport a gun in the same locked up manner without a permit, but only between your home or place of business, or between a dealer and your home. Im not where i can confirm this at the moment...but Alabama hasn’t always been a beacon for sensible firearms laws. The state legislature was lock stock and barrel controlled by Dems until 20 years ago.