Express.php 345 B

123456789101112131415161718
  1. <?php
  2. namespace App\Models;
  3. use Illuminate\Database\Eloquent\Model;
  4. class Express extends Model{
  5. protected $table='express';
  6. public function get_express(){
  7. return $this->hasMany(Express::class,'number','number');
  8. }
  9. public function get_order(){
  10. return $this->hasOne(Ordertest::class,'id','order_id');
  11. }
  12. }