在集合中,我需要将值设置为属性之一,但我找不到如何做到这一点
products.models[i].set({'category.name':'some_value'})
其余的 api 看起来像这样
{
"category": {
"id": 3,
"name": "Drink",
"icon": "staging/main/category/icon-drinks.png"
},
"id": 1,
"name": "Sugar54",
"dashboard": 1,
"last_buy": "2013-10-02",
"price": "102",
"buy_period": 7
},
我怎么做 ?