0
我具有核 - 選擇內紙複選框元件這樣聚合物0.5芯 - 選擇器如何獲得選擇具有紙複選框
<core-selector id="moduleSelector" multi="true" valueattr="label" notap?="{{true}}" on-core-select="{{selectionSelect}}>
<template repeat="{{modules in moduleslist}}">
<core-label horizontal layout>
<paper-checkbox id="modulecheckbox" checked="{{modules.checked}}" label="{{modules.pname}}"
on-change={{checkboxHandler}} noink></paper-checkbox>
</core-label>
<br>
</template>
</core-selector>
的列表值予想獲得選定的紙張的陣列使用這個.checkbox標籤$。moduleSelector.selected但我只得到一些索引值,這是不正確的每個模塊列表索引。我需要獲取標籤名稱。
如果我使用紙質的物品,而不是複選框像下面
<core-selector id="moduleSelector" valueattr="label" multi="true" notap?="{{false}}">
<template repeat="{{modules in moduleslist}}">
<paper-item label="{{modules}}"></paper-item>
</template>
</core-selector>
然後我用這個。$可以得到適當的數組值。moduleSelector.selected
任何幫助將不勝感激。
這不是問題的答案。評論會更適合這一點。 –