Hello, thanks for such an amazing admin package, I absolutely love Twill!
I'm having the following issue: I'm building a CMS for a single language website (english). I enabled the Settings option in the config/twill.php file, I copied the settings migration to my migrations folder as suggested in the documentation but removed the translations table as I will not use it. My "translatable" locales settings array only contains the "en" code so no other languages are available. The problem comes when I try to store some settings as I get the following error:
ErrorException (E_WARNING)
Illegal string offset 'en'
66
ErrorException
…/vendor/area17/twill/src/Repositories/SettingRepository.php45
I've tried adding the "translated=false" attribute on the form fields but I still get the same error.
I removed the tables and re-executed the migrations but this time leaving the translations table, I enabled the translated=true attribute on the form fields and it worked correctly, however I can't store any images so it does not solve my problem.
Any help would be much appreciated.
Thank you!
Hi @manuelsofia,
thanks for your kind words :) And happy to see that you've been able to sort out many of your issues on your own. Your feedback is super helpful to improve our docs!
2 things about the settings feature:
Cheers!
Hi @ifox , thank you very much for your reply, I really appreciate it.
come across the same issue here.
Fixed. This will be released in 1.2.1 and can be tested using 1.2.x-dev.
See https://github.com/area17/twill/pull/91#issuecomment-446488514 for more info.