UIView* backGround = [[UIView alloc]init];
[self.view addSubview:backGround];
backGround.backgroundColor = [UIColor colorWithHex:0xffffff];
backGround.frame = CGRectMake(15, 15, [UIScreen mainScreen].bounds.size.width-15*2, 180);//8
backGround.layer.cornerRadius = 10;
//添加阴影
backGround.layer.shadowOpacity=1;
backGround.layer.shadowColor = [UIColor colorWithHex:0x000000].CGColor;
backGround.layer.borderWidth = 1;//距离2px
backGround.layer.borderColor = [UIColor colorWithHex:0xFFFFFF].CGColor;
backGround.layer.opaque = 0.06;//透明度6%
backGround.layer.masksToBounds = YES;//是否裁剪
backGround.layer.shadowOffset = CGSizeZero;//投影偏移
backGround.layer.shadowRadius = 4;//大小为8px