Category : javascript

I’m trying to show a modal when I click the edit button, so I added wire:click : <td class="py-3 px-6 text-left"> <div class="flex items-center"> <span class="font-medium">{{ $project->project }}</span> </div> </td> <td class="py-3 px-6 text-left"> <div class="flex items-center"> <span>{{ $project->username }}</span> </div> </td> <td class="py-3 px-6 text-center"> <span class="bg-{{ $project->status_color }}-200 text-{{ $project->status_color }}-600 py-1 px-3 ..

Read more

i am trying to show a modal when i click the edit button so i added the wire:click : <td class="py-3 px-6 text-left"> <div class="flex items-center"> <span class="font-medium">{{ $project->project }}</span> </div> </td> <td class="py-3 px-6 text-left"> <div class="flex items-center"> <span>{{ $project->username }}</span> </div> </td> <td class="py-3 px-6 text-center"> <span class="bg-{{ $project->status_color }}-200 text-{{ $project->status_color }}-600 ..

Read more

We have a category selection function. Can you please help to suggest a filtering function that, when choosing a specific category, will pull up all blogs from this category by ID? JavaScript document.querySelectorAll(‘.category-filter_item’).forEach(el => { el.addEventListener(‘click’, () => { document .querySelector(‘.category-filter_item.active’) .classList.remove(‘active’); el.classList.add(‘active’); Development environment Laravel We have something like the following code on the ..

Read more

i have a form whose data comes from 2 tables. idtable_record is foreign key from category Now i need some help to make the edit function, because i can’t display the data. In the edit function i would i need to make something like: Select * from category and semantic where category.category_id=$category_id and semantic.table_mr="Person" For ..

Read more

This is my Laravel PenilaianController: public function index() { // $penilaian1 = PenilaianTahap1::join(‘peserta_t1’, ‘nilai_t1.nim’, ‘=’, ‘peserta_t1.nim’) ->join(‘pendaftar’, ‘peserta_t1.nim’, ‘=’, ‘pendaftar.nim’) ->join(‘sub_kriteria_t1’, ‘nilai_t1.id_sk1’, ‘=’, ‘sub_kriteria_t1.id_sk1’) ->join(‘kriteria_t1’, ‘sub_kriteria_t1.id_k1’, ‘=’, ‘kriteria_t1.id_k1’) ->get([ ‘nilai_t1.nim’, ‘pendaftar.nama’, ‘nilai_t1.nilai’, ‘nilai_t1.id_sk1’ ]); $subkriteria = SubKriteriaTahap1::join(‘kriteria_t1’, ‘sub_kriteria_t1.id_k1’, ‘=’, ‘kriteria_t1.id_k1’) ->get([ ‘sub_kriteria_t1.sub_kriteria’, ‘sub_kriteria_t1.bobot’, ]); $kriteria = KriteriaTahap1::all(); $response = [ ‘message’ => ‘Data pendaftar OR ..

Read more

This is my Laravel PenilaianController: public function index() { // $penilaian1 = PenilaianTahap1::join(‘peserta_t1’, ‘nilai_t1.nim’, ‘=’, ‘peserta_t1.nim’) ->join(‘pendaftar’, ‘peserta_t1.nim’, ‘=’, ‘pendaftar.nim’) ->join(‘sub_kriteria_t1’, ‘nilai_t1.id_sk1’, ‘=’, ‘sub_kriteria_t1.id_sk1’) ->join(‘kriteria_t1’, ‘sub_kriteria_t1.id_k1’, ‘=’, ‘kriteria_t1.id_k1’) ->get([ ‘nilai_t1.nim’, ‘pendaftar.nama’, ‘nilai_t1.nilai’, ‘nilai_t1.id_sk1’ ]); $subkriteria = SubKriteriaTahap1::join(‘kriteria_t1’, ‘sub_kriteria_t1.id_k1’, ‘=’, ‘kriteria_t1.id_k1’) ->get([ ‘sub_kriteria_t1.sub_kriteria’, ‘sub_kriteria_t1.bobot’, ]); $kriteria = KriteriaTahap1::all(); $response = [ ‘message’ => ‘Data pendaftar OR ..

Read more

Controller load the view and load the jQuery. index.blade.php <table id="UserGrid" class="table table-bordered table-striped"> <thead> <tr> <th>ID</th> <th>Name</th> <th>Country</th> <th>Dept</th> <th>Title</th> <th>Username</th> <th>Role</th> <th>Status</th> <th>Created at</th> <th>Action</th> </tr> </thead> <tbody> </tbody> </table> </div> @php $pageJsScript = array( ‘<script type = "text/javascript" src="js/setting/user/User_search.js")></script>’ ); $pageJsCalls = array( ‘User_search.init();’ ); @endphp The above code is in between ..

Read more

my controller public function index() { $blogs = Blog::all(); $categories = Category:all(); return view(‘blog’, compact(‘blogs’, ‘categories’)); } We have something like this code on the blog page. First we get all the available categories, then a list of all blogs @extends(‘layouts.app’) @section(‘content’) <div class="container"> <div class="category-filter" id="filter"> <div class="category-filter_item active">All</div> @foreach($categories as $category) <div class="category-filter_item">{{ ..

Read more

I have a Laravel Blade View I am displaying about 280 products from database using code below. @if (get_setting(‘best_selling’) == 1) <section class="mb-4"> <div class="container"> <div class="px-2 py-4 px-md-4 py-md-3 bg-white shadow-sm rounded"> <div class="d-flex mb-3 align-items-baseline border-bottom"> <h3 class="h5 fw-700 mb-0"> <span class="border-bottom border-primary border-width-2 pb-3 d-inline-block">{{ translate(‘Just For You’) }}</span> </h3> <a href="../search" ..

Read more

controller public function index() { $blogs = Blog::all(); $categories = Category:all(); return view(‘blog’, compact(‘blogs’, ‘categories’)); } We have something like this code on the blog page. First we get all the available categories, then a list of all blogs @extends(‘layouts.app’) @section(‘content’) <div class="container"> <div class="category-filter" id="filter"> <div class="category-filter_item active">All</div> @foreach($categories as $category) <div class="category-filter_item">{{ $category->title ..

Read more

I am trying to get vue-router to work in a Vue.js/Laravel project. I have the following simple pages: home page: about page (scrolled down in single page): Made from these files: welcome.blade.php: <!DOCTYPE html> <html lang="{{ str_replace(‘_’, ‘-‘, app()->getLocale()) }}"> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <script crossorigin="anonymous" src="https://polyfill.io/v3/polyfill.min.js?features=WeakMap"></script> <title>title</title> </head> <body id="body"> <div ..

Read more

I’ve recently been looking into the Laravel PHP framework. Since I have never worked with backend frameworks, it feels quite complex. Is there maybe something smaller on the market for developing smaller, RESTful Web Apps, specifically with vue.js in the Frontend, which require only a manageable logic? As a beginner, it would of course be ..

Read more