// // OnlineLearningViewController.m // Lighting // // Created by 曹云霄 on 2016/11/16. // Copyright © 2016年 上海勾芒科技有限公司. All rights reserved. // #import "OnlineLearningViewController.h" #import "OnlineLearningTableViewCell.h" @interface OnlineLearningViewController () @end @implementation OnlineLearningViewController - (void)viewDidLoad { [super viewDidLoad]; [self setUpCollectionView]; } #pragma mark - UICollectionView - (void)setUpCollectionView { self.onlineLearningFlowLayout.itemSize = CGSizeMake((ScreenWidth-100)/4.0, ((ScreenWidth-100)/4.0-50)); self.onlineLearningFlowLayout.sectionInset = UIEdgeInsetsMake(20, 20, 20, 20); self.onlineLearningFlowLayout.minimumLineSpacing = 20; self.onlineLearningFlowLayout.minimumInteritemSpacing = 20; } #pragma mark - 学习模块数据 - (void)getLearningModuleData { } #pragma mark - - (NSInteger)collectionView:(UICollectionView *)collectionView numberOfItemsInSection:(NSInteger)section { return 10; } - (UICollectionViewCell *)collectionView:(UICollectionView *)collectionView cellForItemAtIndexPath:(NSIndexPath *)indexPath { OnlineLearningTableViewCell *learningCell = [collectionView dequeueReusableCellWithReuseIdentifier:@"OnlineLearningTableViewCell" forIndexPath:indexPath]; return learningCell; } - (void)didReceiveMemoryWarning { [super didReceiveMemoryWarning]; } /* #pragma mark - Navigation // In a storyboard-based application, you will often want to do a little preparation before navigation - (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender { // Get the new view controller using [segue destinationViewController]. // Pass the selected object to the new view controller. } */ @end