1234567891011121314151617181920212223242526272829303132 |
- <?php
- namespace app\model;
- use support\Model;
- class OrderReturn extends Model
- {
- protected $table = 'order_return';
- protected $primaryKey = 'orders_return_id';
- protected $dateFormat = 'U';
- const CREATED_AT = 'order_return_addtimes';
- const UPDATED_AT = null;
- public function member()
- {
- return $this->hasOne(Member::class, 'member_id', 'join_return_member_id');
- }
- public function cert()
- {
- return $this->hasOne(MemberCert::class, 'join_cert_member_id', 'join_return_member_id');
- }
- public function order()
- {
- return $this->hasOne(Order::class, 'order_id', 'join_return_order_id');
- }
- }
|