1234567891011121314151617181920212223242526272829 |
- <?php
- declare (strict_types = 1);
- namespace app\txx\model;
- use app\model\GoodBasic;
- use app\model\Platform;
- use think\model;
- /**
- * @mixin \think\Model
- */
- class PlatformYouzan extends Model
- {
- protected $createTime='addtime';
- protected $updateTime='updatetime';
- public function good(){
- return $this->belongsTo(GoodBasic::class,'spuCode','spuCode')
- ->bind(['good_name','cat_id','is_exclusive','brand_id','good_img',"good_info_img","good_thumb_img",'good_unit','unit_name','brand_name','cat_name','cat_search']);
- }
- public function platform(){
- return $this->belongsTo(Platform::class,'platform_id','id')->bind(['platform_name']);
- }
- public function yzGood(){
- return $this->belongsTo(YzGood::class,'skuCode','item_no');
- }
- }
|