数据格式
reportList: [{
date:
""
,
projectCode: ""
,
hours: 4,
content:
""
,
status:
""
,
matterItem: [{
matterCode:
""
,
hours:
}]
}]
var idex = e.currentTarget.dataset.code;
var reportList = this.data.reportList;
for (var i = 0; i < reportList.length;i++){
if (reportList[i].matterItem) {
for (var j = 0; j < reportList[i].matterItem.length;j++){
if (reportList[i].matterItem[j].matterCode == idex) {
reportList[i].matterItem = reportList[i].matterItem[j];
var datas=reportList[i];
}
}
}
}