本文整理汇总了TypeScript中entcore._.find方法的典型用法代码示例。如果您正苦于以下问题:TypeScript _.find方法的具体用法?TypeScript _.find怎么用?TypeScript _.find使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类entcore._
的用法示例。
在下文中一共展示了_.find方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的TypeScript代码示例。
示例1: fromJSON
fromJSON(page) {
this.hasGrids = _.find(page.rows, (r) => _.find(r.cells, (c) => c.media.type === 'grid') !== undefined) !== undefined;
this.rows = new Rows(this, Mix.castArrayAs(Row, JSON.parse(JSON.stringify(page.rows)), this));
if (page.published === undefined) {
this.published = true;
}
}
示例2: function
return _.filter(this.all, function(school){
var words = search.split(' ');
return _.find(words, function(word){
var formattedOption = lang.removeAccents(school.name).toLowerCase();
var formattedWord = lang.removeAccents(word).toLowerCase();
return formattedOption.indexOf(formattedWord) === -1
}) === undefined;
});
示例3:
this.hasGrids = _.find(page.rows, (r) => _.find(r.cells, (c) => c.media.type === 'grid') !== undefined) !== undefined;
示例4:
$scope.can = (right: string) => {
let folder: Folder = $scope.currentFolder;
return _.find(folder.websites.sel.selected, (w: Website) => !w.myRights[right]) === undefined;
};
示例5: function
return _.filter(Birthday.birthdays, function(birthday){
return _.find(birthday.classes, function(b){ return b[0] === Birthday.currentClass.id }) !== undefined;
});