Category : undefined

I just doing project import excel using laravel. But there is an error when import / upload file excel and for web page can open and work. ErrorException Undefined array key 7 public function model(array $row) { return new Dso([ ‘id_dso’ => $row[1], ‘id_rso’ => $row[2], ‘id_focus’ => $row[3], ‘id_wilayah’ => $row[4], ‘id_grup_wilayah’ => $row[5], ..

Read more

I was posting on last discussion, may be is no clear my problem. I’m apologize if I was created 2 same discussion And now I will attach all information including all code, I hope it can be fixed soon. and there is few part SiswaController.php, use AppExportsSiswaExport; use AppImportsSiswaImport; use MaatwebsiteExcelFacadesExcel; use AppHttpControllersController; class SiswaController ..

Read more

I’m trying to render PWA directives, but I have this error Error Class ‘AppServicesPWAMetaService’ not found I have this in AppServiceProvider.php public function boot() { Blade::directive(‘PWA’, function (){ return (new AppServicesPWAMetaService())->render(); }); } But the class exists this is the class <?php namespace AppServices; class MetaService { public function render(): string { return "<?php $config ..

Read more

I try to pass data from Laravel blade to Vue with props and I get undefined in console. I tried also <example-component :course="{{ $course }}"></example-component> <example-component course="{{!! $course !!}}"></example-component> index.blade.php @extends(‘layouts.app’) @section(‘content’) <div id="app"> </div> <example-component course="{{ $course }}"></example-component> <script src="{{asset(‘js/course/app.js’)}}"></script> @endsection app.js import { createApp } from ‘vue’; import App from ‘./components/App.vue’ import router ..

Read more

I keep getting Undefined variable: products products.blade @foreach ($products as $prod) <td>{{ $prod->name }} </td> <td>{{ $prod->buying_price }}</td> <td>{{ $prod->selling_price }}</td> <td>{{ $prod->weight}}</td> @endforeach products controller public function index() { $products = products::all(); return view(‘products.products’)->with(‘products’, $products); } i also tried public function index() { $products = products::all(); return view (‘products.products’,compact(‘products’)); } route Route::resource(‘products’, ‘ProductsController’); Source: ..

Read more

after grouping urls with prefix in web.php I have created language switcher like this Route::redirect(‘/’,’/ge’); Route::group([‘prefix’ => ‘{language}’],function (){ Route::get(‘/’, function () { return view(‘welcome’); }); }); I tested it and it was working fine. now I need to add links ( language switcher) but after I do this I receive an exception and an ..

Read more

I want to insert data into multiple tables (one to one), but i get error and in my database the column "metode_id" is null. i want the "metode_id" is not null this is class "Transaksi" : class Transaksi extends Model { protected $table = "transaksi"; protected $primarykey = "id"; protected $fillable = [‘stok_kedelai’, ‘stok_ragi’, ‘harga_kedelai’, ..

Read more

I’m stuck in my ToDo App where I want to add a progress Bar for the completed tasks. I defined tasks in data in my TaskComponent.vue: data(){ return{ hook: ”, editmode: false, // todos: [], todos: { title: ”, completed: ”, and get the response data from the database using laravel: getTask(){ axios.get(‘api/task’).then(function(res) { this.todos ..

Read more

This is my jQuery function for appending new input fields. But after sending data, I always receive only the first inputs value in the request array. Blockquote var count = 1; $("#delete_button0").hide(); $(document).on(‘click’, ‘#add_button’, function () { $(this).remove(); var newLink=”; var lastCount = count – 1; newLink += ‘<div class="row">’+ ‘<div class="form-group col-lg-8">’+ ‘<input type="text" ..

Read more