Thursday, March 14, 2024

Validation Regex

 

 'name' => 'required|unique:rooms|not_regex:/(0)[1-9][0-9]{2}$/|min:2',

Friday, January 19, 2024

v-viewer

 

npm install v-viewer viewerjs

 onImageClick: function(attachment) {
     
        this.$viewerApi({
          attachments : attachment,
        })
     
    },


 

<div v-for="attachment in attachments" class="images" v-viewer>

Monday, January 8, 2024

Apache error

 

Get solution for the issue, need to change in apache2.conf file after that it will works,

old code in /etc/apache2/apache2.conf

<Directory /var/www/>
        Options Indexes FollowSymLinks
        AllowOverride None
        Require all granted
</Directory>

changed in to

 <Directory /var/www/>
            Options Indexes FollowSymLinks
            AllowOverride All
            Require all granted
    </Directory>

after that, In order for Apache to understand rewrite rules, we first need to activate mod_rewrite. It's already installed, but it's disabled on a default Apache installation. Use the a2enmod command to enable the module:

$ sudo a2enmod rewrite

This will activate the module or alert you that the module is already enabled. To put these changes into effect, restart Apache.

$ sudo systemctl restart apache2

it works for me finally.

Friday, December 22, 2023

Laravel

Multi Select

 https://github.com/SuadeLabs/vue3-multiselect

 

Todo List admin-lte template add

https://www.youtube.com/watch?v=ligOIMNQVxg 


Multi Purpose

https://github.com/clovon/Multipurpose-Laravel9-and-Vue3-Application

https://www.youtube.com/watch?v=8tejtb1c5AM&list=PLGg3vnFos8GN3MAvxbI-QXKSkBKi2yIFO&index=6

Sunday, November 26, 2023

Docker Installation

 Follow the steps from Docker installation guide.


docker ps

if you have permission issue,

sudo usermod -aG docker 'username'

sudo systemctl enable docker (to get startup when system reboot)

OpenVPN mikrotik


 Pls find 

Monday, November 13, 2023

Validation with 2 column

 

$validatedData = $request->validate([
'item_id' => 'required|unique:req_records,item_id,' . $request->item_id . ',id,req_id,' . $req_id,

],
[
'item_id.unique' => 'You already requested this item with same req_id',
]);