yii2:radioList must be a string

I have this field in my _form.php

<?= $form->field($model, 'delivered')->radioList

([ 'delivered' => 'Delivered', 'part' => 'Partly Delivered']) ?>

I am getting the error, when I am selecting the radio-box Delivered I am getting the error -

delivered must be a string

I can’t make out what is wrong in the syntax.

Validation rule in the model is like:

public function rules()


        return [

            [['ipd_patient_id', 'room_name'], 'integer'],

            [['request_time', 'issue_time'], 'safe'],

            [['general_regn_no'], 'string', 'max' => 15],

            [['patient_name'], 'string', 'max' => 50],

            [['delivered'], 'string', 'max' => 20]



Any idea why this is happening? Thanks.

I have implement above code so , it works fine…

once you recheck your code than implement,

if error occur than give more info about it…