inital commit

This commit is contained in:
2024-02-01 09:53:53 +00:00
commit 9743fce12b
19771 changed files with 4230637 additions and 0 deletions

68
app/Models/Coridor.php Normal file
View File

@@ -0,0 +1,68 @@
<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Model;
class Coridor extends Model
{
public static function boot()
{
parent::boot();
self::creating(function($model){
});
self::created(function($model){
});
self::updating(function($model){
auth()->user()->addActivityComplete(1052,$model);
});
self::updated(function($model){
});
self::deleting(function($model){
auth()->user()->addActivityComplete(1053,$model);
});
self::deleted(function($model){
});
}
protected $fillable = [
'province_name',
'city_name',
'name',
'status',
'type',
'team_num',
'staff_num',
'phone',
'responsible_name',
'responsible_mobile',
'successor_name',
'successor_mobile',
'machine_data',
'team_data',
'code',
'lat',
'lng',
'start_lat',
'start_lng',
'geometry',
'color',
'end_lat',
'end_lng'
];
public function files()
{
return $this->morphMany('App\Models\PointFile', 'point_fileable');
}
public function rahdariPointHistories()
{
return $this->hasMany('App\Models\RahdariPointHistory', 'point_id');
}
}