Closed uhonliu closed 6 years ago
Details
当数据库字段默认值为''是,php bin/swoft entity:create生成实体字段有问题.
/** * @var int $id 主键ID * @Id() * @Column(name="id", type=Types::INT) */ private $id = ''; /** * @var string $mobile 手机号 * @Column(name="mobile", type=Types::STRING, length=11) * @Required() */ private $mobile = ''''; /** * @var string $email 邮箱 * @Column(name="email", type=Types::STRING, length=50) * @Required() */ private $email = ''''; /** * @var string $auth_code 验证码 * @Column(name="auth_code", type=Types::STRING, length=8) * @Required() */ private $auth_code = ''''; /** * @var string $auth_type 行为:注册,找回密码等 * @Column(name="auth_type", type=Types::STRING, length=30) * @Required() */ private $auth_type = '''';
已修复,db组件请更新至v1.1.4
Details
当数据库字段默认值为''是,php bin/swoft entity:create生成实体字段有问题.