disable selected value in md-select

646 Views Asked by At

I have a table which has md-select in all the rows which come dynamically from ng-repeat. how to restrict the selected value from md-options in one row to not to get visible in other rows.. here is the code I used for md-select

<tbody>
<tr ng-repeat="receiver in receivers">
    <td>
        <md-select ng-model="receiver.product">
            <md-option ng-repeat="product in products" value="{{product}}">
                {{product.name}}
            </md-option>
        </md-select>
    </td>
</tr>

here is my Plunker http://plnkr.co/edit/1gM6GKPWRou7dLYDDRgi?p=preview if i select product1 in first row and click on + to add new row , then product1 should be disabled.

I have tried these answers but no luck. https://jsfiddle.net/rdkqw5gt/10/ & http://plnkr.co/edit/E0yu9XAxqjxpwArBfDbK?p=preview

they have used ng-options how to achieve this in md-options?? thanks in advance

0

There are 0 best solutions below