notifyEnable method
通知启用状态
skuIds
启用sku id
currSkuValue
当前选择sku
Implementation
@override
void notifyEnable(List<Set<String>> skuIds, String currSkuValue) {
int pos = 0;
flowItems.forEach((element) {
var entry = _itemElements[pos];
if (entry != null) {
var msValue = currSkuValue.split("_");
var refsValue = element.specSkuMapping?.split("_") ?? [];
//同一规格下sku不作处理
if (msValue.isNotEmpty && refsValue.isNotEmpty) {
if (msValue[0] != refsValue[0]) {
if (hasEffectiveValue(skuIds, element.specSkuMapping ?? "")) {
element.enable = true;
} else {
element.enable = false;
}
entry.controller.notifyEnable(element.enable);
} else {
element.enable != element.enable;
entry.controller.notifyEnable(element.enable);
}
}
}
pos++;
});
}