36], [['elemento'], 'string', 'max' => 255], [['costo', 'descripcion'], 'string', 'max' => 100], [['id'], 'unique'], [['idServicio'], 'exist', 'skipOnError' => true, 'targetClass' => Servicio::class, 'targetAttribute' => ['idServicio' => 'id']], ]; } /** * {@inheritdoc} */ public function attributeLabels() { return [ 'id' => 'ID', 'idServicio' => 'Id Servicio', 'elemento' => 'Elemento', 'costo' => 'Costo', 'descripcion' => 'Descripcion', 'creado' => 'Creado', 'modificado' => 'Modificado', 'eliminado' => 'Eliminado', ]; } /** * Gets query for [[IdServicio]]. * * @return \yii\db\ActiveQuery */ public function getServicio() { return $this->hasOne(Servicio::class, ['id' => 'idServicio']); } }