CreolePriceSelectionView 0.1.1

CreolePriceSelectionView 0.1.1

测试已测试
语言语言 Obj-CObjective C
许可证 MIT
发布最后发布2017年6月

Nirmalsinh Rathod 维护。



  • NirmalsinhRathod

示例

要运行示例项目,请克隆存储库,然后从 Example 目录中首先运行 pod install

手动安装

只需将文件拖到您的项目中,并使用以下代码

    CreolePriceSelectionView *objCreolePriceSelectionView = [[CreolePriceSelectionView alloc] initWithFrame:CGRectMake(YOUR_FRAME)];
    [objCreolePriceSelectionView setDefaultColor]; // It will set defualt color for text and background.
    
    /*
     You can set text color manually also.
     
     objCreolePriceSelectionView.selectItemColor = YOUR_SELECTED_ITEM_COLOR.
     objCreolePriceSelectionView.normalItemColor  = YOUR_NORMAL_ITEM_COLOR.
     objCreolePriceSelectionView.selectedTextColor = YOUR_SELECTED_TEXT_COLOR
     objCreolePriceSelectionView.normalTextColor = YOUR_NORMAL_TEXT_COLOR
     
     */
    
    // You can pass your array for price like this:
    [objCreolePriceSelectionView setup:[[NSMutableArray alloc] initWithObjects:@"10", @"20", @"30", @"40", @"50", @"60", @"70", @"80", @"90", @"100", nil]];
    
    // Its directlly select the
    // This is optional steps to do. If you don't do this one, then it will set first automatically.
    [objCreolePriceSelectionView setPriceForItem:@"30"];
    
    // Set delegate to get access of current index
    objCreolePriceSelectionView.delegate = self;
    [self.view addSubview:objCreolePriceSelectionView];
    
    
    // DELEGATE 
    -(void)getPriceForSelectedIndex :(NSString *)strPrice
    {
     NSLog(@"Current selected price is :%@",strPrice);
    }

安装

CreolePriceSelectionView 通过 CocoaPods 提供。要安装它,只需将以下行添加到您的 Podfile 中

pod "CreolePriceSelectionView"

作者

NirmalsinhRathod, [email protected]

许可证

CreolePriceSelectionView 在 MIT 许可证下可用。有关更多信息,请参阅 LICENSE 文件。