<?php
namespace app\admin\model;
use think\Model;
class a extends Model
{
protected $name = null;
public function __construct($name = null)
{
$this->name = $name;
$this->initialize();
}
}
$t1 = new a('table1');
$t2 = new a('table2');
能实例化。但读不到表数据。都是空的