12345678910111213141516171819202122232425262728293031323334 |
- <?php
- /**
- * Created by PhpStorm.
- * User: Administrator
- * Date: 2019/4/8
- * Time: 15:24
- */
- namespace App\Transfer;
- use Illuminate\Database\Eloquent\Model;
- class Jobs extends Model
- {
- protected $connection = "transfer_center";
- protected $table = "qs_jobs";
- protected $guarded = [];
- public function jobsContact()
- {
- return $this->hasOne(JobsContact::class, 'pid')->with('jobs');
- }
- public function promotions()
- {
- return $this->hasMany(Promotion::class, 'cp_jobid', 'id');
- }
- public function autoRefresh()
- {
- return $this->hasMany(QueueAutoRefresh::class, 'pid');
- }
- }
|