Files

52 lines
1.4 KiB
PHP

<?php
// +----------------------------------------------------------------------
// | YwxApp AppMarket [ 应用市场中心站插件 ]
// +----------------------------------------------------------------------
// | Copyright (c) 2026-2036 http://ywxapp.cn All rights reserved.
// +----------------------------------------------------------------------
// | Author: ywxapp<admin@ywxapp.cn>
// +----------------------------------------------------------------------
declare(strict_types=1);
namespace addon\appmall\model;
use ywxapp\model\BaseModel;
/**
* 开发者(中心站)
* 表:appmall_developers
* @mixin \think\Model
*/
class Developer extends BaseModel
{
protected function getOptions(): array
{
return [
'strict' => true,
'name' => 'appmall_developers',
'autoWriteTimestamp' => 'int',
'createTime' => 'create_at',
'updateTime' => 'update_at',
];
}
/**
* 关联收益记录
* @return \think\model\relation\HasMany
*/
public function revenues()
{
return $this->hasMany(Revenue::class, 'developer_id', 'id');
}
/**
* 关联提现单
* @return \think\model\relation\HasMany
*/
public function withdrawals()
{
return $this->hasMany(Withdrawal::class, 'developer_id', 'id');
}
}