Skip to content

Commit 1ea01f1

Browse files
authored
Merge pull request #66 from ugunNet21/develop
Develop
2 parents f2508a3 + 01389f2 commit 1ea01f1

File tree

72 files changed

+4558
-17
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

72 files changed

+4558
-17
lines changed

README.md

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -330,6 +330,67 @@ routes/
330330
331331
````
332332

333+
```php
334+
335+
Available commands for the "make" namespace:
336+
make:amqp-consumer [gen:amqp-consumer] Create a new amqp consumer class
337+
make:amqp-producer [gen:amqp-producer] Create a new amqp producer class
338+
make:aspect [gen:aspect] Create a new aspect class
339+
make:channel Create a new channel class
340+
make:class [gen:class] Create a new class
341+
make:command Create a new Artisan command
342+
make:component Create a new view component class
343+
make:constant [gen:constant] Create a new constant class
344+
make:controller [gen:controller] Create a new controller class
345+
make:event Create a new event class
346+
make:factory Create a new model factory
347+
make:job Create a new job class
348+
make:kafka-consumer [gen:kafka-consumer] Create a new kafka consumer class
349+
make:listener Create a new event listener class
350+
make:mail Create a new email class
351+
make:middleware [gen:middleware] Create a new middleware class
352+
make:migration [gen:migration] Generate a new migration file
353+
make:model Create a new Eloquent model class
354+
make:nats-consumer [gen:nats-consumer] Create a new nats consumer class
355+
make:notification Create a new notification class
356+
make:notifications-table [notifications:table] Create a migration for the notifications table
357+
make:nsq-consumer [gen:nsq-consumer] Create a new nsq consumer class
358+
make:observer Create a new model observer class
359+
make:policy Create a new policy class
360+
make:process [gen:process] Create a new process class
361+
make:provider Create a new service provider class
362+
make:queue-batches-table [queue:batches-table] Create a migration for the batches database table
363+
make:queue-failed-table [queue:failed-table] Create a migration for the failed queue jobs database table
364+
make:queue-table [queue:table] Create a migration for the queue jobs database table
365+
make:request Create a new form request class
366+
make:resource [gen:resource] create a new resource
367+
make:rule Create a new validation rule
368+
make:seeder Create a new seeder class
369+
make:session-table [session:table] Create a migration for the session database table
370+
make:test Create a new test class
371+
372+
```
373+
374+
# Create base table like spatie
375+
376+
```php
377+
php artisan make:model Role -m
378+
# → Migration: 2025_05_17_154027_create_roles_table
379+
380+
php artisan make:model Permission -m
381+
# → Migration: 2025_05_17_154203_create_permissions_table
382+
383+
php artisan make:model ModelHasRole -m
384+
# → Migration: 2025_05_17_154248_create_model_has_roles_table
385+
386+
php artisan make:model ModelHasPermission -m
387+
# → Migration: 2025_05_17_154400_create_model_has_permissions_table
388+
389+
php artisan make:model RoleHasPermission -m
390+
# → Migration: 2025_05_17_154437_create_role_has_permissions_table
391+
392+
```
393+
333394

334395
> See [this issue](https://github.com/laravel/octane/issues/765) for more discussions.
335396
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
namespace App\Console\Commands;
6+
7+
use Hypervel\Console\Command;
8+
9+
class RunSpecificSeeder extends Command
10+
{
11+
/**
12+
* The name and signature of the console command.
13+
*/
14+
protected ?string $signature = 'app:run-specific-seeder';
15+
16+
/**
17+
* The console command description.
18+
*/
19+
protected string $description = 'Command description';
20+
21+
/**
22+
* Execute the console command.
23+
*/
24+
public function handle()
25+
{
26+
//
27+
}
28+
}
Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
namespace App\Models\AIAssistant;
6+
7+
use App\Models\Model;
8+
use App\Models\SchoolManagement\Subject;
9+
use App\Models\User;
10+
11+
class AiTutorSession extends Model
12+
{
13+
protected $primaryKey = 'id';
14+
protected $keyType = 'string';
15+
public $incrementing = false;
16+
17+
protected $fillable = [
18+
'user_id',
19+
'subject_id',
20+
'session_topic',
21+
'conversation_history',
22+
'start_time',
23+
'end_time',
24+
];
25+
26+
protected $casts = [
27+
'conversation_history' => 'array',
28+
'start_time' => 'datetime',
29+
'end_time' => 'datetime',
30+
'created_at' => 'datetime',
31+
'updated_at' => 'datetime',
32+
];
33+
34+
// Relationships
35+
public function user()
36+
{
37+
return $this->belongsTo(User::class);
38+
}
39+
40+
public function subject()
41+
{
42+
return $this->belongsTo(Subject::class);
43+
}
44+
}
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
namespace App\Models\CareerDevelopment;
6+
7+
use App\Models\Model;
8+
use App\Models\SchoolManagement\Student;
9+
use App\Models\User;
10+
11+
class CareerAssessment extends Model
12+
{
13+
protected $primaryKey = 'id';
14+
protected $keyType = 'string';
15+
public $incrementing = false;
16+
17+
protected $fillable = [
18+
'student_id',
19+
'assessment_type',
20+
'assessment_date',
21+
'results',
22+
'recommendations',
23+
'created_by',
24+
];
25+
26+
protected $casts = [
27+
'assessment_date' => 'date',
28+
'results' => 'array',
29+
'created_at' => 'datetime',
30+
'updated_at' => 'datetime',
31+
];
32+
33+
// Relationships
34+
public function student()
35+
{
36+
return $this->belongsTo(Student::class);
37+
}
38+
39+
public function creator()
40+
{
41+
return $this->belongsTo(User::class, 'created_by');
42+
}
43+
}
Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
<?php
2+
3+
declare (strict_types = 1);
4+
5+
namespace App\Models\CareerDevelopment;
6+
7+
use App\Models\Model;
8+
use App\Models\SchoolManagement\Student;
9+
use App\Models\SchoolManagement\Teacher;
10+
11+
class CounselingSession extends Model
12+
{
13+
protected $primaryKey = 'id';
14+
protected $keyType = 'string';
15+
public $incrementing = false;
16+
17+
protected $fillable = [
18+
'student_id',
19+
'counselor_id',
20+
'session_date',
21+
'session_time',
22+
'duration_minutes',
23+
'notes',
24+
'follow_up_date',
25+
];
26+
27+
protected $casts = [
28+
'session_date' => 'date',
29+
'session_time' => 'datetime:H:i',
30+
'follow_up_date' => 'date',
31+
'created_at' => 'datetime',
32+
'updated_at' => 'datetime',
33+
];
34+
35+
// Relationships
36+
public function student()
37+
{
38+
return $this->belongsTo(Student::class);
39+
}
40+
41+
public function counselor()
42+
{
43+
return $this->belongsTo(Teacher::class, 'counselor_id');
44+
}
45+
}
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
<?php
2+
3+
declare (strict_types = 1);
4+
5+
namespace App\Models\CareerDevelopment;
6+
7+
use App\Models\Model;
8+
9+
class IndustryPartner extends Model
10+
{
11+
protected $primaryKey = 'id';
12+
protected $keyType = 'string';
13+
public $incrementing = false;
14+
15+
protected $fillable = [
16+
'name',
17+
'industry',
18+
'contact_person',
19+
'contact_email',
20+
'contact_phone',
21+
'partnership_details',
22+
];
23+
24+
protected $casts = [
25+
'created_at' => 'datetime',
26+
'updated_at' => 'datetime',
27+
];
28+
}

app/Models/DigitalLibrary/Book.php

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
namespace App\Models\DigitalLibrary;
6+
7+
use App\Models\Model;
8+
9+
class Book extends Model
10+
{
11+
protected $primaryKey = 'id';
12+
protected $keyType = 'string';
13+
public $incrementing = false;
14+
15+
protected $fillable = [
16+
'isbn',
17+
'title',
18+
'author',
19+
'publisher',
20+
'publication_year',
21+
'category',
22+
'quantity',
23+
'available_quantity',
24+
'cover_url',
25+
'description',
26+
];
27+
28+
protected $casts = [
29+
'created_at' => 'datetime',
30+
'updated_at' => 'datetime',
31+
];
32+
33+
// Relationships
34+
public function ebookFormats()
35+
{
36+
return $this->hasMany(EbookFormat::class);
37+
}
38+
39+
public function bookLoans()
40+
{
41+
return $this->hasMany(BookLoan::class);
42+
}
43+
44+
public function bookReviews()
45+
{
46+
return $this->hasMany(BookReview::class);
47+
}
48+
}
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
namespace App\Models\DigitalLibrary;
6+
7+
use App\Models\Model;
8+
use App\Models\User;
9+
10+
class BookLoan extends Model
11+
{
12+
protected $primaryKey = 'id';
13+
protected $keyType = 'string';
14+
public $incrementing = false;
15+
16+
protected $fillable = [
17+
'book_id',
18+
'borrower_id',
19+
'loan_date',
20+
'due_date',
21+
'return_date',
22+
'status',
23+
];
24+
25+
protected $casts = [
26+
'loan_date' => 'date',
27+
'due_date' => 'date',
28+
'return_date' => 'date',
29+
'created_at' => 'datetime',
30+
'updated_at' => 'datetime',
31+
];
32+
33+
// Relationships
34+
public function book()
35+
{
36+
return $this->belongsTo(Book::class);
37+
}
38+
39+
public function borrower()
40+
{
41+
return $this->belongsTo(User::class, 'borrower_id');
42+
}
43+
}
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
namespace App\Models\DigitalLibrary;
6+
7+
use App\Models\Model;
8+
use App\Models\User;
9+
10+
class BookReview extends Model
11+
{
12+
protected $primaryKey = 'id';
13+
protected $keyType = 'string';
14+
public $incrementing = false;
15+
16+
protected $fillable = [
17+
'book_id',
18+
'reviewer_id',
19+
'rating',
20+
'review_text',
21+
'is_public',
22+
];
23+
24+
protected $casts = [
25+
'is_public' => 'boolean',
26+
'created_at' => 'datetime',
27+
'updated_at' => 'datetime',
28+
];
29+
30+
// Relationships
31+
public function book()
32+
{
33+
return $this->belongsTo(Book::class);
34+
}
35+
36+
public function reviewer()
37+
{
38+
return $this->belongsTo(User::class, 'reviewer_id');
39+
}
40+
}

0 commit comments

Comments
 (0)