Settings
Settings copied to clipboard
Add settings easily from admin panel with improvements to handle upload image field
i have been thinking about this pull request from the first time i used this package but i hadn't really time to do it but now it's done i hope it will be useful and improve the usage of this awesome package
How to use
-
admin create the settings field he need and click save

-
if he selected for example image field ( it will be empty inside the list page )

-
admin now can click edit button and he will find the field he selected from the create page

-
now if it's image as we set before i have setup configurations for configure almost everything for image field and if cropper enabled etc the image will appear normally and use can save it

that's all and here's a list of supported field
[
'text' => 'Text',
'email' => 'Email',
'checkbox' => 'Checkbox',
'number' => 'Number',
'url' => 'URL',
'image' => 'Image',
'password' => 'Password',
'icon_picker' => 'Icon Picker',
]
and here's how it appears in list page

nice :)
It would be good if settings are stored in json as well :)
@bloggervista hey i don't encourage that specially for keys and passwords etc but we can make it optional ;)
@iMokhles password can be encrypted using bcrypt like normal :)
@bloggervista bcrypt() for hashing so we cannot reverse it into their plain text again, but yes we can encrypt passwords and decrypt them if needed using Crypt
use Illuminate\Support\Facades\Crypt;
$encrypted = Crypt::encryptString('Hello world.');
$decrypted = Crypt::decryptString($encrypted);
@iMokhles password are never means to be decrypted isn't it? Am i wrong here?
@bloggervista sometimes we need to decrypt passwords ( which we use for external API calls ) in my case i have my Apple Developer Account credentials saved to my database and password is encrypted and once i need to call apple's api to authenticate my request i decrypt this password before passing it with my request
I'm getting lost in the discussion about password encrypting and decrypting.
hey sorry for taking so long time to answer you @lloy0076 , in my case i was talking about password ( which means API keys for real password for social accounts ).
example: my facebook account credentials: Email: [email protected] Password 123456 so i don't want saving this password as plain text like that ( i need to encrypt it ) and saved the encrypted text to database, and once i call this encrypted password i can decrypt it to reverse it back to plain text it's some sort of protection and make it more privately so anyone get access to database don't see the plain password and won't be able to decrypt it because i'm the only has the decryption key..
what if he(hacker) gets decryption keys?
@bloggervista he won't get it because the key is hardcoded inside PHP which in the server side and won't be rendered to html output after the server send it to the browser, unless your server got hack and he got access to all your PHP source codes files. ( that's the only way ( i ) know to get this key from your PHP code )
@tabacitu @iMokhles Hi guys, just asking, how's the progress with this PR? Will it be merged or is there any additional issue needed to be resolved?