Commit 8b05af81 authored by zhangshuai's avatar zhangshuai

内容

parent 982d47cb
//
// WelfareCenterCell.h
// GYDemo
//
// Created by zhangshuai on 2020/11/17.
//
#import <UIKit/UIKit.h>
NS_ASSUME_NONNULL_BEGIN
@interface WelfareCenterCell : UITableViewCell
@property (weak, nonatomic) IBOutlet UILabel *title;
@property (weak, nonatomic) IBOutlet UILabel *subTitle;
@property (weak, nonatomic) IBOutlet UIButton *awardNum;
@property (weak, nonatomic) IBOutlet UIButton *buttonState;
- (IBAction)stateButtonClick:(UIButton *)sender;
@property (nonatomic ,copy) void (^buttonBlock)(WelfareCenterCell * thisCell);
@property (nonatomic ,assign)NSInteger status; // 按钮状态
@end
NS_ASSUME_NONNULL_END
//
// WelfareCenterCell.m
// GYDemo
//
// Created by zhangshuai on 2020/11/17.
//
#import "WelfareCenterCell.h"
@implementation WelfareCenterCell
- (void)awakeFromNib {
[super awakeFromNib];
// Initialization code
}
- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
[super setSelected:selected animated:animated];
// Configure the view for the selected state
}
- (void)setStatus:(NSInteger)status{
//0 : 去完成 1: 明日再来 2: 立即领取
_status = status;
if (status == 0) {
[self.buttonState setTitle:@"去完成" forState:UIControlStateNormal];
[self.buttonState setBackgroundImage:[UIImage imageNamed:@"ToFinishRed"] forState:UIControlStateNormal];
}else if(status == 1){
[self.buttonState setTitle:@"明日再来" forState:UIControlStateNormal];
[self.buttonState setBackgroundImage:[UIImage imageNamed:@"CollectedGrey"] forState:UIControlStateNormal];
}else if (status == 2){
[self.buttonState setTitle:@"立即领取" forState:UIControlStateNormal];
[self.buttonState setBackgroundImage:[UIImage imageNamed:@"GetItNow"] forState:UIControlStateNormal];
}else{
[self.buttonState setTitle:@"明日再来" forState:UIControlStateNormal];
[self.buttonState setBackgroundImage:[UIImage imageNamed:@"CollectedGrey"] forState:UIControlStateNormal];
}
}
- (IBAction)stateButtonClick:(UIButton *)sender {
if (self.buttonBlock) {
self.buttonBlock(self);
}
}
@end
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="17156" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<device id="retina6_1" orientation="portrait" appearance="light"/>
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="17125"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<objects>
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner"/>
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
<tableViewCell contentMode="scaleToFill" selectionStyle="default" indentationWidth="10" rowHeight="126" id="KGk-i7-Jjw" customClass="WelfareCenterCell">
<rect key="frame" x="0.0" y="0.0" width="320" height="126"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="KGk-i7-Jjw" id="H2p-sc-9uM">
<rect key="frame" x="0.0" y="0.0" width="320" height="126"/>
<autoresizingMask key="autoresizingMask"/>
<subviews>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="pr8-hQ-LpE">
<rect key="frame" x="0.0" y="0.0" width="320" height="126"/>
<subviews>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="nDA-SS-B2Z">
<rect key="frame" x="10" y="0.0" width="300" height="114"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="红包赢不停" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="1Hi-6u-Z8f">
<rect key="frame" x="14" y="14" width="91" height="26"/>
<fontDescription key="fontDescription" name="PingFangSC-Semibold" family="PingFang SC" pointSize="18"/>
<color key="textColor" red="0.20000000000000001" green="0.20000000000000001" blue="0.20000000000000001" alpha="1" colorSpace="calibratedRGB"/>
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="浏览60秒领取奖励" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Go5-7x-zg8">
<rect key="frame" x="14" y="46" width="118" height="17"/>
<fontDescription key="fontDescription" type="system" pointSize="14"/>
<color key="textColor" red="0.59215686274509804" green="0.32941176470588235" blue="0.13725490196078433" alpha="1" colorSpace="calibratedRGB"/>
<nil key="highlightedColor"/>
</label>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="system" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="dyx-aR-S4p">
<rect key="frame" x="200" y="73" width="86" height="34"/>
<fontDescription key="fontDescription" name="PingFangSC-Medium" family="PingFang SC" pointSize="16"/>
<state key="normal" title="立即领取" backgroundImage="GetItNow">
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="calibratedRGB"/>
</state>
<connections>
<action selector="stateButtonClick:" destination="KGk-i7-Jjw" eventType="touchUpInside" id="aP1-iP-3jo"/>
</connections>
</button>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="hkj-qT-nh4">
<rect key="frame" x="223.5" y="53" width="39" height="20"/>
<fontDescription key="fontDescription" type="system" pointSize="16"/>
<state key="normal" title=" +1" image="MissionDiamond">
<color key="titleColor" red="1" green="0.3529411764705882" blue="0.26666666666666666" alpha="1" colorSpace="calibratedRGB"/>
</state>
</button>
</subviews>
<color key="backgroundColor" red="0.99607843137254903" green="0.9882352941176471" blue="0.88627450980392153" alpha="1" colorSpace="calibratedRGB"/>
<constraints>
<constraint firstItem="hkj-qT-nh4" firstAttribute="centerX" secondItem="dyx-aR-S4p" secondAttribute="centerX" id="8HW-1s-Wwg"/>
<constraint firstAttribute="bottom" relation="greaterThanOrEqual" secondItem="Go5-7x-zg8" secondAttribute="bottom" constant="14" id="9Yq-a9-JYg"/>
<constraint firstItem="Go5-7x-zg8" firstAttribute="leading" secondItem="1Hi-6u-Z8f" secondAttribute="leading" id="BQB-Lx-flj"/>
<constraint firstAttribute="bottom" secondItem="dyx-aR-S4p" secondAttribute="bottom" constant="7" id="Ghm-cq-BfQ"/>
<constraint firstItem="Go5-7x-zg8" firstAttribute="top" secondItem="1Hi-6u-Z8f" secondAttribute="bottom" constant="6" id="Nph-zt-FH0"/>
<constraint firstAttribute="trailing" secondItem="dyx-aR-S4p" secondAttribute="trailing" constant="14" id="RAT-h5-XPA"/>
<constraint firstItem="1Hi-6u-Z8f" firstAttribute="top" secondItem="nDA-SS-B2Z" secondAttribute="top" constant="14" id="ffd-c9-ZHj"/>
<constraint firstItem="dyx-aR-S4p" firstAttribute="top" secondItem="hkj-qT-nh4" secondAttribute="bottom" id="mf8-KH-zK4"/>
<constraint firstItem="1Hi-6u-Z8f" firstAttribute="leading" secondItem="nDA-SS-B2Z" secondAttribute="leading" constant="14" id="qLo-LC-ZZ0"/>
</constraints>
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttribute type="boolean" keyPath="masksToBounds" value="YES"/>
<userDefinedRuntimeAttribute type="number" keyPath="cornerRadius">
<integer key="value" value="8"/>
</userDefinedRuntimeAttribute>
</userDefinedRuntimeAttributes>
</view>
</subviews>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstItem="nDA-SS-B2Z" firstAttribute="top" secondItem="pr8-hQ-LpE" secondAttribute="top" id="8fC-07-6l8"/>
<constraint firstAttribute="trailing" secondItem="nDA-SS-B2Z" secondAttribute="trailing" constant="10" id="HBU-ub-jyU"/>
<constraint firstItem="nDA-SS-B2Z" firstAttribute="leading" secondItem="pr8-hQ-LpE" secondAttribute="leading" constant="10" id="bZF-4f-w2W"/>
<constraint firstAttribute="bottom" secondItem="nDA-SS-B2Z" secondAttribute="bottom" constant="12" id="zmj-Lz-4EQ"/>
</constraints>
</view>
</subviews>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstAttribute="trailing" secondItem="pr8-hQ-LpE" secondAttribute="trailing" id="IfP-kb-S0R"/>
<constraint firstItem="pr8-hQ-LpE" firstAttribute="leading" secondItem="H2p-sc-9uM" secondAttribute="leading" id="Ih7-S3-ByO"/>
<constraint firstAttribute="bottom" secondItem="pr8-hQ-LpE" secondAttribute="bottom" id="T5W-Hc-m07"/>
<constraint firstItem="pr8-hQ-LpE" firstAttribute="top" secondItem="H2p-sc-9uM" secondAttribute="top" id="tc0-qz-yHg"/>
</constraints>
</tableViewCellContentView>
<viewLayoutGuide key="safeArea" id="aW0-zy-SZf"/>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<connections>
<outlet property="awardNum" destination="hkj-qT-nh4" id="xia-dl-dpr"/>
<outlet property="buttonState" destination="dyx-aR-S4p" id="CpN-7w-eAq"/>
<outlet property="subTitle" destination="Go5-7x-zg8" id="UZH-Pl-fPU"/>
<outlet property="title" destination="1Hi-6u-Z8f" id="LHG-Gl-5H3"/>
</connections>
<point key="canvasLocation" x="-343" y="69"/>
</tableViewCell>
</objects>
<resources>
<image name="GetItNow" width="86" height="34"/>
<image name="MissionDiamond" width="17" height="15"/>
</resources>
</document>
//
// WelfareCenterVC.h
// GYDemo
//
// Created by zhangshuai on 2020/11/17.
//
#import <UIKit/UIKit.h>
NS_ASSUME_NONNULL_BEGIN
@interface WelfareCenterVC : BaseViewController
@end
NS_ASSUME_NONNULL_END
//
// WelfareCenterVC.m
// GYDemo
//
// Created by zhangshuai on 2020/11/17.
//
#import "WelfareCenterVC.h"
#import "WelfareCenterData.h"
#import "WelfareBoxData.h"
#import "DGUniversalAlertView.h"
#import "WelfareCenterCell.h"
#define Identifier @"WelfareCenterCell"
#import "AppDelegate.h"
#define MAXProcess (6)
@interface WelfareCenterVC ()
@property (nonatomic, strong) NSMutableArray * dataArray;
@property (weak, nonatomic) IBOutlet UITableView *tableView;
@property (strong, nonatomic) IBOutletCollection(UIImageView) NSArray *diamondimages;
@property (weak, nonatomic) IBOutlet UIStackView *stackProcess;
@property (weak, nonatomic) IBOutlet UIImageView *imageLine;
@property (weak, nonatomic) IBOutlet UIButton *treasureBox;
@property (weak, nonatomic) IBOutlet UILabel *currentText;
@property (nonatomic ,assign)NSInteger maxProcess;
@property (nonatomic ,assign)NSInteger coinsProcess;
@property (nonatomic ,assign)NSInteger showA;
@property (nonatomic ,retain)WelfareCenterData *currentData;
- (IBAction)treasureBoxClick:(UIButton *)sender;
@end
@implementation WelfareCenterVC
- (void)dealloc{
[[NSNotificationCenter defaultCenter]removeObserver:self.tableView];
}
- (NSMutableArray * )dataArray{
if (_dataArray == nil) {
_dataArray = [[NSMutableArray alloc]init];
}
return _dataArray;
}
- (void)viewDidLoad {
[super viewDidLoad];
[self addLeftItme:[UIImage imageNamed:@"arrow_left"] selecedImage:nil orText:@" " selectedText:nil];
self.title = @"福利中心";
[self loadData];
[self initTableView];
[self navbarClearShadow];
self.view.backgroundColor = [UIColor colorWithHexString:@"#F7BD7C"];
UIImage *image = [UIImage imageNamed:@"DottedLine"];
UIImage *newImage = [UIImage imageWithCGImage:[image CGImage] scale:image.scale orientation:image.imageOrientation];
[self.imageLine setBackgroundColor:[UIColor colorWithPatternImage:newImage]];
// Do any additional setup after loading the view from its nib.
}
- (void)initTableView{
self.tableView.rowHeight = UITableViewAutomaticDimension;
self.tableView.estimatedRowHeight = UITableViewAutomaticDimension;
self.tableView.backgroundColor = UIColor.clearColor;//kColorFromHex(0xFAFAFA);
UINib * nib = [UINib nibWithNibName:Identifier bundle:nil];
[self.tableView registerNib:nib forCellReuseIdentifier:Identifier];
self.tableView.separatorStyle = UITableViewCellSeparatorStyleNone;
}
#pragma - mark 返回
- (void)leftBarButtonItemAction:(UIButton *)btn{
[self dismissViewControllerAnimated:YES completion:^{
}];
}
- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView{
return 1;
}
- (NSInteger)tableView:(nonnull UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
return self.dataArray.count;
}
- (nonnull UITableViewCell *)tableView:(nonnull UITableView *)tableView cellForRowAtIndexPath:(nonnull NSIndexPath *)indexPath {
WelfareCenterData * data = [self.dataArray objectAtIndex:indexPath.row];
WelfareCenterCell * cell = [tableView dequeueReusableCellWithIdentifier:Identifier forIndexPath:indexPath];
cell.selectionStyle = UITableViewCellSelectionStyleNone;
cell.title.text = data.title;
cell.subTitle.text = data.description_Content;
cell.status = data.status;
[cell.awardNum setTitle:[NSString stringWithFormat:@"+%@",data.awardCoins] forState:UIControlStateNormal];
WEAKSELF;
cell.buttonBlock = ^(WelfareCenterCell * _Nonnull thisCell) {
NSInteger status = thisCell.status;
NSIndexPath * indexP = [weakSelf.tableView indexPathForCell:thisCell];
WelfareCenterData * data = [weakSelf.dataArray objectAtIndex:indexP.row];
if (status == 0) {
[weakSelf showAD:data];
}else if(status == 1){
[MBProgressHUD showMessage:@"明日再来"];
}else if (status == 2){ //立即领取
[weakSelf receiveThePrize:data];
}else{
[MBProgressHUD showMessage:@"明日再来"];
}
};
return cell;
}
-(void)tableView:(UITableView *)tableView willDisplayCell:(UITableView *)cell forRowAtIndexPath:(NSIndexPath *)indexPath{
}
-(CGFloat)tableView:(UITableView *)tableView heightForHeaderInSection:(NSInteger)section{
return 0;
}
-(UIView *)tableView:(UITableView *)tableView viewForHeaderInSection:(NSInteger)section{
UIView*header = [[UIView alloc]initWithFrame:CGRectMake(0, 0, KScreenWidth, 40)];
UILabel * label = [[UILabel alloc]initWithFrame:CGRectMake(20, 12, KScreenWidth, 20)];
label.text = @"Explore Meditation";
label.textColor = UIColor.whiteColor;
label.font = [UIFont fontWithName:PF_SC_M size:20];
[header addSubview:label];
return header;
}
-(UIView *)tableView:(UITableView *)tableView viewForFooterInSection:(NSInteger)section{
UIView * sectionView = [[UIView alloc]initWithFrame:CGRectMake(0, 0, KScreenWidth,4 )];
return sectionView;
}
-(CGFloat)tableView:(UITableView *)tableView heightForFooterInSection:(NSInteger)section{
return 0;
}
-(void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath{
[tableView deselectRowAtIndexPath:indexPath animated:NO];
[tableView reloadData];
}
- (void)loadData{
WEAKSELF;
// [MBProgressHUD showLoading:@"loading"];
NSMutableDictionary * dic = [[NSMutableDictionary alloc]init];
[dic setObject:@"1" forKey:@"type"];
//请求进度
[[CGNetworkTools shared] getWithAction:task_process parameters:dic success:^(id _Nonnull response) {
// [MBProgressHUD hideHUD];
NSDictionary * dic = response[@"result"][@"data"];
if (dic.count) {
weakSelf.maxProcess = [[dic valueForKey:@"max"] integerValue];
weakSelf.coinsProcess = [[dic valueForKey:@"coins"] integerValue];
weakSelf.showA = [[dic valueForKey:@"show"] integerValue];
[weakSelf updateUI];
}
} failure:^(NSError * _Nonnull error) {
// [MBProgressHUD hideHUD];
}];
NSMutableDictionary * dicStat = [[NSMutableDictionary alloc]init];
[dicStat setObject:@"welfare_center_task_list" forKey:@"slotName"];
// 请求列表
[[CGNetworkTools shared] getWithAction:taskListWithStat parameters:dicStat success:^(id _Nonnull response) {
// [MBProgressHUD hideHUD];
if (response) {
NSArray * array = response[@"result"][@"data"][@"userTask"];
if (array) {
weakSelf.dataArray = [WelfareCenterData mj_objectArrayWithKeyValuesArray:array];
[weakSelf.tableView reloadData];
}
}
} failure:^(NSError * _Nonnull error) {
// [MBProgressHUD hideHUD];
}];
}
//MARK: 更新UI
- (void)updateUI{
for (UIImageView *imageView in self.diamondimages) {
if (imageView.tag <= 1000 + self.coinsProcess) {
[imageView setImage:[UIImage imageNamed:@"FinishedDiamonds"]];
} else {
[imageView setImage:[UIImage imageNamed:@"UnfinishedDiamond"]];
}
if (imageView.tag <= 1000 + MAXProcess) { //[1,10]
imageView.hidden = NO;
}else{
imageView.hidden = YES;
}
}
if (self.coinsProcess >= 6) {
[self.treasureBox setImage:[UIImage imageNamed:@"OpenTreasureChest"] forState:UIControlStateNormal];
}else{
[self.treasureBox setImage:[UIImage imageNamed:@"TreasureChestClose"] forState:UIControlStateNormal];
}
self.currentText.text = [NSString stringWithFormat:@"%ld",self.coinsProcess];
[self.tableView reloadData];
}
//MARK: 看广告
- (void)showAD:( WelfareCenterData * ) data{
self.currentData = data;
WEAKSELF;
[IOSADManager shareADManager].advertisingSpace = @"play_adVideo_end_welfareTask";
[[IOSADManager shareADManager] showADType:ADType_Video resultBlock:^(BOOL success) {
if (success) {
//2462
[[CGUserManager shared] addLocCollection:@"play_adVideo_end_welfareTask" value:@""];
if (weakSelf.currentData.sid.length > 0) {
[MBProgressHUD showLoading:@"loading"];
[[CGNetworkTools shared] postWithAction:welfareVideoReport parameters:@{@"sid": weakSelf.currentData.sid} success:^(id _Nonnull response) {
[MBProgressHUD hideHUD];
if ([[response objectForKey:@"status"] integerValue] == 200) {
//
NSLog(@"welfare_video_report success");
weakSelf.currentData.status = 2;
[weakSelf.tableView reloadData];
}
} failure:^(NSError * _Nonnull error) {
[MBProgressHUD hideHUD];
}];
}
} else {
// [MBProgressHUD showError:@"抱歉, 请重试"];
}
}];
}
//MARK: 获取奖励
- (void)receiveThePrize:(WelfareCenterData *) data{
self.currentData = data;
WEAKSELF;
[MBProgressHUD showLoading:@"loading"];
[[CGNetworkTools shared] postWithAction:complete_task parameters:@{@"id": weakSelf.currentData.sid} success:^(id _Nonnull response) {
[MBProgressHUD hideHUD];
if ([[response objectForKey:@"status"] integerValue] == 200) {
NSLog(@"welfare_video_report success");
weakSelf.currentData.status = 1;
weakSelf.coinsProcess += 1;
[weakSelf updateUI];
}
} failure:^(NSError * _Nonnull error) {
[MBProgressHUD hideHUD];
}];
}
//MARK: 打开宝箱
- (IBAction)treasureBoxClick:(UIButton *)sender {
// NSMutableArray * array = [NSMutableArray new];
// WelfareBoxData * data = [[WelfareBoxData alloc]init];
// data.awardNum = 1;
// data.awardType = 1;
// data.boxID = 1;
// data.subType = 2;
// [array addObject:data];
//
// data = [[WelfareBoxData alloc]init];
// data.awardNum = 154;
// data.awardType = 2;
// data.boxID = 2;
// data.subType = 0;
// [array addObject:data];
//
// data = [[WelfareBoxData alloc]init];
// data.awardNum = 8;
// data.awardType = 3;
// data.boxID = 3;
// data.subType = 0;
// [array addObject:data];
//
// DGUniversalAlertView * alertView = [DGUniversalAlertView loadFromNib];
// [alertView configWithWelfareBoxModel:array];
// [alertView showAlertToView:[(AppDelegate *)[UIApplication sharedApplication].delegate getMainWindow]];
//
// return;
WEAKSELF;
[[CGNetworkTools shared] postWithAction:welfare_task_box parameters:@{} success:^(id _Nonnull response) {
if (response) {
if(weakSelf.coinsProcess >= 6){
weakSelf.coinsProcess -= 6;
}
[weakSelf updateUI];
NSArray * array = response[@"result"][@"data"];
NSMutableArray * dataArray = [WelfareBoxData mj_objectArrayWithKeyValuesArray:array];
DGUniversalAlertView * alertView = [DGUniversalAlertView loadFromNib];
[alertView configWithWelfareBoxModel:dataArray];
[alertView showAlertToView:weakSelf.view];
}
} failure:^(NSError * _Nonnull error) {
}];
}
@end
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="17156" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES">
<device id="retina4_7" orientation="portrait" appearance="light"/>
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="17125"/>
<capability name="Safe area layout guides" minToolsVersion="9.0"/>
<capability name="System colors in document resources" minToolsVersion="11.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<objects>
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="WelfareCenterVC">
<connections>
<outlet property="currentText" destination="3ar-1p-GGl" id="FTa-d6-TLA"/>
<outlet property="imageLine" destination="eOX-rq-v0m" id="nQi-CD-Le5"/>
<outlet property="stackProcess" destination="S8p-gf-4z7" id="cFK-Aa-zoG"/>
<outlet property="tableView" destination="cLQ-3z-U9W" id="lrz-YI-VgV"/>
<outlet property="treasureBox" destination="PvX-s8-Pxm" id="CFC-be-Iwr"/>
<outlet property="view" destination="i5M-Pr-FkT" id="sfx-zR-JGt"/>
<outletCollection property="diamondimages" destination="kBi-Eb-3V8" id="275-Zc-bCZ"/>
<outletCollection property="diamondimages" destination="1z4-3O-sod" id="QnW-xd-fu7"/>
<outletCollection property="diamondimages" destination="bNv-QM-tgZ" id="79A-7j-6mc"/>
<outletCollection property="diamondimages" destination="Rvp-NU-SUN" id="ewG-56-kBw"/>
<outletCollection property="diamondimages" destination="hBp-he-bnq" id="kcd-7r-v3k"/>
<outletCollection property="diamondimages" destination="Jj2-BA-D4N" id="vgd-VO-AIQ"/>
<outletCollection property="diamondimages" destination="bwc-i7-rSf" id="Dyt-A2-bGp"/>
<outletCollection property="diamondimages" destination="H5W-Ga-MKH" id="Wtz-4Z-QhQ"/>
<outletCollection property="diamondimages" destination="Kx6-a8-hM2" id="7fD-hw-ReK"/>
<outletCollection property="diamondimages" destination="IZK-xN-ed9" id="GvK-gQ-bhe"/>
</connections>
</placeholder>
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
<view clearsContextBeforeDrawing="NO" contentMode="scaleToFill" id="i5M-Pr-FkT">
<rect key="frame" x="0.0" y="0.0" width="375" height="667"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="BottomOfTheBackground" translatesAutoresizingMaskIntoConstraints="NO" id="Hz0-KR-A7M">
<rect key="frame" x="0.0" y="539" width="375" height="128"/>
</imageView>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="D2D-AV-eup">
<rect key="frame" x="0.0" y="0.0" width="375" height="85"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="集齐6颗钻石可获得宝箱奖励" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="CdA-K9-h8P">
<rect key="frame" x="11" y="10" width="214.5" height="24"/>
<fontDescription key="fontDescription" name="PingFangSC-Regular" family="PingFang SC" pointSize="17"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="eOX-rq-v0m">
<rect key="frame" x="15" y="54.5" width="300" height="1"/>
<constraints>
<constraint firstAttribute="height" constant="1" id="0Br-kg-Mkw"/>
</constraints>
</imageView>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="BackgroundLight" translatesAutoresizingMaskIntoConstraints="NO" id="CTR-NW-hAk">
<rect key="frame" x="297.5" y="12.5" width="85" height="85"/>
<constraints>
<constraint firstAttribute="height" constant="85" id="isH-zN-fKh"/>
<constraint firstAttribute="width" secondItem="CTR-NW-hAk" secondAttribute="height" multiplier="1:1" id="z6A-10-2ER"/>
</constraints>
</imageView>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="PvX-s8-Pxm">
<rect key="frame" x="315" y="35" width="50" height="40"/>
<constraints>
<constraint firstAttribute="width" constant="50" id="AqL-sD-MtI"/>
<constraint firstAttribute="width" relation="greaterThanOrEqual" constant="50" id="EQP-m9-4dB"/>
<constraint firstAttribute="height" constant="40" id="pK3-VH-oEx"/>
</constraints>
<state key="normal" image="TreasureChestClose"/>
<connections>
<action selector="treasureBoxClick:" destination="-1" eventType="touchUpInside" id="g16-Zg-dOx"/>
</connections>
</button>
<stackView opaque="NO" contentMode="scaleToFill" distribution="equalSpacing" alignment="center" translatesAutoresizingMaskIntoConstraints="NO" id="S8p-gf-4z7">
<rect key="frame" x="15" y="35" width="280" height="40"/>
<subviews>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" tag="1001" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="UnfinishedDiamond" translatesAutoresizingMaskIntoConstraints="NO" id="1z4-3O-sod">
<rect key="frame" x="0.0" y="6.5" width="27" height="27"/>
</imageView>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" tag="1002" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="UnfinishedDiamond" translatesAutoresizingMaskIntoConstraints="NO" id="bNv-QM-tgZ">
<rect key="frame" x="28" y="6.5" width="27" height="27"/>
</imageView>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" tag="1003" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="UnfinishedDiamond" translatesAutoresizingMaskIntoConstraints="NO" id="Rvp-NU-SUN">
<rect key="frame" x="56" y="6.5" width="27" height="27"/>
</imageView>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" tag="1004" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="UnfinishedDiamond" translatesAutoresizingMaskIntoConstraints="NO" id="kBi-Eb-3V8">
<rect key="frame" x="84.5" y="6.5" width="27" height="27"/>
</imageView>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" tag="1005" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="UnfinishedDiamond" translatesAutoresizingMaskIntoConstraints="NO" id="hBp-he-bnq">
<rect key="frame" x="112.5" y="6.5" width="27" height="27"/>
</imageView>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" tag="1006" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="UnfinishedDiamond" translatesAutoresizingMaskIntoConstraints="NO" id="Jj2-BA-D4N">
<rect key="frame" x="140.5" y="6.5" width="27" height="27"/>
</imageView>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" tag="1007" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="UnfinishedDiamond" translatesAutoresizingMaskIntoConstraints="NO" id="bwc-i7-rSf">
<rect key="frame" x="168.5" y="6.5" width="27" height="27"/>
</imageView>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" tag="1008" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="UnfinishedDiamond" translatesAutoresizingMaskIntoConstraints="NO" id="H5W-Ga-MKH">
<rect key="frame" x="197" y="6.5" width="27" height="27"/>
</imageView>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" tag="1009" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="UnfinishedDiamond" translatesAutoresizingMaskIntoConstraints="NO" id="Kx6-a8-hM2">
<rect key="frame" x="225" y="6.5" width="27" height="27"/>
</imageView>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" tag="1010" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="UnfinishedDiamond" translatesAutoresizingMaskIntoConstraints="NO" id="IZK-xN-ed9">
<rect key="frame" x="253" y="6.5" width="27" height="27"/>
</imageView>
</subviews>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstAttribute="height" constant="40" id="FH1-a1-QJK"/>
</constraints>
</stackView>
<stackView opaque="NO" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="RPC-kr-Miv">
<rect key="frame" x="316" y="6.5" width="48" height="20.5"/>
<subviews>
<imageView clipsSubviews="YES" userInteractionEnabled="NO" contentMode="scaleAspectFit" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="MissionDiamond" translatesAutoresizingMaskIntoConstraints="NO" id="siR-JQ-5Ee">
<rect key="frame" x="0.0" y="0.0" width="17" height="20.5"/>
</imageView>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text=":" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="sAl-Iv-fIQ">
<rect key="frame" x="17" y="0.0" width="5" height="20.5"/>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="3" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="3ar-1p-GGl">
<rect key="frame" x="22" y="0.0" width="10.5" height="20.5"/>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" red="1" green="0.35294117650000001" blue="0.2666666667" alpha="1" colorSpace="calibratedRGB"/>
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="/6" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="8j4-7J-gwL">
<rect key="frame" x="32.5" y="0.0" width="15.5" height="20.5"/>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
</subviews>
</stackView>
</subviews>
<color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstItem="PvX-s8-Pxm" firstAttribute="leading" secondItem="S8p-gf-4z7" secondAttribute="trailing" constant="20" id="89X-7k-ijZ"/>
<constraint firstItem="eOX-rq-v0m" firstAttribute="centerY" secondItem="S8p-gf-4z7" secondAttribute="centerY" id="FCp-gm-wYP"/>
<constraint firstItem="S8p-gf-4z7" firstAttribute="leading" secondItem="D2D-AV-eup" secondAttribute="leading" constant="15" id="Hob-ud-Gi2"/>
<constraint firstItem="S8p-gf-4z7" firstAttribute="centerY" secondItem="PvX-s8-Pxm" secondAttribute="centerY" id="J7o-Gj-r1w"/>
<constraint firstItem="PvX-s8-Pxm" firstAttribute="leading" secondItem="eOX-rq-v0m" secondAttribute="trailing" id="L1t-z1-uiU"/>
<constraint firstItem="PvX-s8-Pxm" firstAttribute="top" secondItem="RPC-kr-Miv" secondAttribute="bottom" constant="8" id="Q76-5G-gA0"/>
<constraint firstItem="CTR-NW-hAk" firstAttribute="centerY" secondItem="PvX-s8-Pxm" secondAttribute="centerY" id="WfN-EX-VKW"/>
<constraint firstItem="RPC-kr-Miv" firstAttribute="centerX" secondItem="PvX-s8-Pxm" secondAttribute="centerX" id="ZnZ-nM-S50"/>
<constraint firstItem="CdA-K9-h8P" firstAttribute="top" secondItem="D2D-AV-eup" secondAttribute="top" constant="10" id="i4a-bl-9sN"/>
<constraint firstItem="CTR-NW-hAk" firstAttribute="centerX" secondItem="PvX-s8-Pxm" secondAttribute="centerX" id="ptb-gv-XiT"/>
<constraint firstAttribute="bottom" secondItem="PvX-s8-Pxm" secondAttribute="bottom" constant="10" id="qm8-6b-fpD"/>
<constraint firstAttribute="height" constant="85" id="s0L-kX-UPf"/>
<constraint firstItem="eOX-rq-v0m" firstAttribute="leading" secondItem="S8p-gf-4z7" secondAttribute="leading" id="skH-3l-nIp"/>
<constraint firstItem="CdA-K9-h8P" firstAttribute="leading" secondItem="D2D-AV-eup" secondAttribute="leading" constant="11" id="w1v-b0-Oo6"/>
<constraint firstAttribute="trailing" secondItem="PvX-s8-Pxm" secondAttribute="trailing" constant="10" id="wDk-D9-G2s"/>
</constraints>
</view>
<tableView clipsSubviews="YES" contentMode="scaleToFill" misplaced="YES" alwaysBounceVertical="YES" style="plain" separatorStyle="default" rowHeight="-1" estimatedRowHeight="-1" sectionHeaderHeight="28" sectionFooterHeight="28" translatesAutoresizingMaskIntoConstraints="NO" id="cLQ-3z-U9W">
<rect key="frame" x="0.0" y="74" width="375" height="582"/>
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
<color key="sectionIndexBackgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<connections>
<outlet property="dataSource" destination="-1" id="YN3-rf-K4G"/>
<outlet property="delegate" destination="-1" id="ifg-sF-Ftu"/>
</connections>
</tableView>
</subviews>
<viewLayoutGuide key="safeArea" id="Q5M-cg-NOt"/>
<color key="backgroundColor" systemColor="systemBackgroundColor"/>
<constraints>
<constraint firstItem="Q5M-cg-NOt" firstAttribute="trailing" secondItem="cLQ-3z-U9W" secondAttribute="trailing" id="028-KM-XZz"/>
<constraint firstItem="cLQ-3z-U9W" firstAttribute="top" secondItem="D2D-AV-eup" secondAttribute="bottom" id="5wn-Zp-bTJ"/>
<constraint firstItem="cLQ-3z-U9W" firstAttribute="leading" secondItem="Q5M-cg-NOt" secondAttribute="leading" id="7pf-5Q-Gok"/>
<constraint firstAttribute="bottom" secondItem="cLQ-3z-U9W" secondAttribute="bottom" id="8VV-5W-bB8"/>
<constraint firstItem="Hz0-KR-A7M" firstAttribute="leading" secondItem="Q5M-cg-NOt" secondAttribute="leading" id="RcL-5a-amf"/>
<constraint firstItem="Q5M-cg-NOt" firstAttribute="trailing" secondItem="Hz0-KR-A7M" secondAttribute="trailing" id="VHd-ye-32S"/>
<constraint firstItem="Q5M-cg-NOt" firstAttribute="bottom" secondItem="Hz0-KR-A7M" secondAttribute="bottom" id="dhz-m5-vd3"/>
<constraint firstItem="Q5M-cg-NOt" firstAttribute="trailing" secondItem="D2D-AV-eup" secondAttribute="trailing" id="dvA-wT-3C2"/>
<constraint firstItem="D2D-AV-eup" firstAttribute="leading" secondItem="Q5M-cg-NOt" secondAttribute="leading" id="jnl-OE-fh8"/>
<constraint firstItem="D2D-AV-eup" firstAttribute="top" secondItem="Q5M-cg-NOt" secondAttribute="top" id="xa4-d3-lOH"/>
</constraints>
<point key="canvasLocation" x="-143.19999999999999" y="62.518740629685162"/>
</view>
</objects>
<resources>
<image name="BackgroundLight" width="147.5" height="150"/>
<image name="BottomOfTheBackground" width="375" height="128"/>
<image name="MissionDiamond" width="17" height="15"/>
<image name="TreasureChestClose" width="48" height="40"/>
<image name="UnfinishedDiamond" width="27" height="27"/>
<systemColor name="systemBackgroundColor">
<color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</systemColor>
</resources>
</document>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment