【发布时间】:2016-09-12 03:50:54
【问题描述】:
我有一个如下所示的数组。当我使用this.itemsgroupcustomer.indexOf("Perorangan") 时,它返回-1。我不知道为什么这是错误的。请帮忙。
viewModel.itemsgroupcustomer = [
{title: "Perusahaan"},
{title: "Perorangan"}
];
【问题讨论】:
-
因为数组不包含
Perorangan字符串的元素。