Skip to content
This repository has been archived by the owner on May 3, 2024. It is now read-only.

I can't able to disable the select option #123

Open
thehiddennepali opened this issue Nov 25, 2014 · 1 comment
Open

I can't able to disable the select option #123

thehiddennepali opened this issue Nov 25, 2014 · 1 comment

Comments

@thehiddennepali
Copy link

Hi I am trying to disable the section option first which depends on first selected value.

So I am trying to use editable option 'disabled'=>true but it does not worked out.

Code I had used is show below

array(
    'name' => 'district',
    'editable' => array(
        'emptytext' => 'no value',
        'apply' => true,
        'disabled' => true,
        'htmlOptions' => array('data-elementid' => 'district'),
        'type' => 'select',
        'url' => array('site/updateProfile'),
        'source' => Editable::source(District::model()->findAll(
            array(
                'select' => 'No,DistrictName',

            )),
            'No', 'DistrictName'
        ),
        'placement' => 'right'
    )
)
@rahulthackkar
Copy link

To disable inline edit , just _ set property 'apply' to 'false'_ (no need of 'disabled' property even).


array(
    'name' => 'district',
    'editable' => array(
        'emptytext' => 'no value',
        'apply' => false,
        'htmlOptions' => array('data-elementid' => 'district'),
        'type' => 'select',
        'url' => array('site/updateProfile'),
        'source' => Editable::source(District::model()->findAll(
            array(
                'select' => 'No,DistrictName',

```
        )),
        'No', 'DistrictName'
    ),
    'placement' => 'right'
)
```

)

It will work!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants