gigiloouu
gigiloouu
FFilament
Created by gigiloouu on 1/9/2025 in #❓┊help
problem with exel uploader
can u refactor my code ? how i should add it there ?
\EightyNine\ExcelImport\ExcelImportAction::make()
->label('ექსელის ატვირთვა')
->sampleExcel(
sampleData: [
['internal_company_name', 'identification_code', 'holding_company_id', 'director_id', 'is_active'],
],
fileName: 'holding_companies_example.xlsx',
sampleButtonLabel: 'გადმოიწერე_მაგალითი',
customiseActionUsing: fn(Action $action) => $action->color('primary')
->icon('heroicon-m-clipboard')
->requiresConfirmation(),
)
->color('danger'),
\EightyNine\ExcelImport\ExcelImportAction::make()
->label('ექსელის ატვირთვა')
->sampleExcel(
sampleData: [
['internal_company_name', 'identification_code', 'holding_company_id', 'director_id', 'is_active'],
],
fileName: 'holding_companies_example.xlsx',
sampleButtonLabel: 'გადმოიწერე_მაგალითი',
customiseActionUsing: fn(Action $action) => $action->color('primary')
->icon('heroicon-m-clipboard')
->requiresConfirmation(),
)
->color('danger'),
14 replies
FFilament
Created by gigiloouu on 1/9/2025 in #❓┊help
problem with exel uploader
u mean use relationship?
14 replies
FFilament
Created by gigiloouu on 1/9/2025 in #❓┊help
problem with exel uploader
what i should do to also add directors in pivot table?
14 replies
FFilament
Created by gigiloouu on 1/9/2025 in #❓┊help
problem with exel uploader
yes its works now but its not adding directors in pivot table :((
14 replies
FFilament
Created by gigiloouu on 1/9/2025 in #❓┊help
problem with exel uploader
ou wait i will try, may i need it in my holding company model
14 replies
FFilament
Created by gigiloouu on 1/9/2025 in #❓┊help
problem with exel uploader
also there is direcor model for pivot table
<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;

class Director extends Model
{
use HasFactory;

protected $fillable = ['name', 'email', 'phone'];

public function holdingCompanies()
{
return $this->belongsToMany(HoldingCompany::class, 'directors_holding_companies', 'director_id', 'holding_company_id');
}
}
<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;

class Director extends Model
{
use HasFactory;

protected $fillable = ['name', 'email', 'phone'];

public function holdingCompanies()
{
return $this->belongsToMany(HoldingCompany::class, 'directors_holding_companies', 'director_id', 'holding_company_id');
}
}
14 replies
FFilament
Created by gigiloouu on 1/9/2025 in #❓┊help
problem with exel uploader
this is my model of holdingcomapny
14 replies
FFilament
Created by gigiloouu on 1/9/2025 in #❓┊help
problem with exel uploader
<?php namespace App\Models; use Illuminate\Database\Eloquent\Factories\HasFactory; use Illuminate\Database\Eloquent\Model; use Illuminate\Database\Eloquent\Relations\HasMany; class HoldingCompany extends Model { use HasFactory; protected $fillable = ['internal_company_name', 'identification_code', 'director_id']; public function directors() { return $this->hasMany(Director::class, 'director_holding_company', 'holding_company_id', 'director_id'); } public function directorHoldingCompany(): HasMany { return $this->hasMany(directorHoldingCompany::class); } }
14 replies
FFilament
Created by gigiloouu on 1/9/2025 in #❓┊help
problem with exel uploader
anyone? (
14 replies
FFilament
Created by gigiloouu on 12/24/2024 in #❓┊help
show total sum by filters
i just use custom summarize ->summarize(Summarizer::make() ->label('გადახდილი ჯამი') ->using(function (Builder $query) {}
41 replies
FFilament
Created by gigiloouu on 12/24/2024 in #❓┊help
show total sum by filters
thats working thanks!
41 replies
FFilament
Created by gigiloouu on 12/24/2024 in #❓┊help
show total sum by filters
okay i wil ltry thanks
41 replies
FFilament
Created by gigiloouu on 12/24/2024 in #❓┊help
show total sum by filters
i try ->summarize(function ($records) { return $records->sum('amount'); // Summing the 'amount' field from the records }) like this but not working
41 replies
FFilament
Created by gigiloouu on 12/24/2024 in #❓┊help
show total sum by filters
??
41 replies
FFilament
Created by gigiloouu on 12/24/2024 in #❓┊help
show total sum by filters
how can u write it please?
41 replies
FFilament
Created by gigiloouu on 12/24/2024 in #❓┊help
show total sum by filters
without summarize its works btw
41 replies
FFilament
Created by gigiloouu on 12/24/2024 in #❓┊help
show total sum by filters
i have this error
41 replies
FFilament
Created by gigiloouu on 12/24/2024 in #❓┊help
show total sum by filters
SQLSTATE[42S22]: Column not found: 1054 Unknown column 'non_commercials.total' in 'field list' (Connection: mysql, SQL: select sum(non_commercials.total) as "U6Cs8X2Up1514m57" from (select * from `non_commercials`) as `non_commercials`)
SQLSTATE[42S22]: Column not found: 1054 Unknown column 'non_commercials.total' in 'field list' (Connection: mysql, SQL: select sum(non_commercials.total) as "U6Cs8X2Up1514m57" from (select * from `non_commercials`) as `non_commercials`)
41 replies
FFilament
Created by gigiloouu on 12/24/2024 in #❓┊help
show total sum by filters
like that?
41 replies
FFilament
Created by gigiloouu on 12/24/2024 in #❓┊help
show total sum by filters
``````
41 replies