Commit c7712495 authored by Sandy's avatar Sandy

绑定微信、提现申请

parent 9e38f03d
......@@ -18,8 +18,98 @@
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>1.0.2</string>
<key>CFBundleURLTypes</key>
<array>
<dict>
<key>CFBundleTypeRole</key>
<string>Editor</string>
<key>CFBundleURLSchemes</key>
<array>
<string>wx39e5b31bb7b479c7</string>
</array>
</dict>
</array>
<key>CFBundleVersion</key>
<string>1.0.2</string>
<key>LSApplicationQueriesSchemes</key>
<array>
<string>wechat</string>
<string>weixin</string>
<string>sinaweibohd</string>
<string>sinaweibo</string>
<string>sinaweibosso</string>
<string>weibosdk</string>
<string>weibosdk2.5</string>
<string>mqqapi</string>
<string>mqq</string>
<string>mqqOpensdkSSoLogin</string>
<string>mqqconnect</string>
<string>mqqopensdkdataline</string>
<string>mqqopensdkgrouptribeshare</string>
<string>mqqopensdkfriend</string>
<string>mqqopensdkapi</string>
<string>mqqopensdkapiV2</string>
<string>mqqopensdkapiV3</string>
<string>mqqopensdkapiV4</string>
<string>mqzoneopensdk</string>
<string>wtloginmqq</string>
<string>wtloginmqq2</string>
<string>mqqwpa</string>
<string>mqzone</string>
<string>mqzonev2</string>
<string>mqzoneshare</string>
<string>wtloginqzone</string>
<string>mqzonewx</string>
<string>mqzoneopensdkapiV2</string>
<string>mqzoneopensdkapi19</string>
<string>mqzoneopensdkapi</string>
<string>mqqbrowser</string>
<string>mttbrowser</string>
<string>alipay</string>
<string>alipayshare</string>
<string>dingtalk</string>
<string>dingtalk-open</string>
<string>laiwangsso</string>
<string>yixin</string>
<string>yixinopenapi</string>
<string>instagram</string>
<string>whatsapp</string>
<string>line</string>
<string>fbapi</string>
<string>fb-messenger-api</string>
<string>fbauth2</string>
<string>fbshareextension</string>
<string>kakaofa63a0b2356e923f3edd6512d531f546</string>
<string>kakaokompassauth</string>
<string>storykompassauth</string>
<string>kakaolink</string>
<string>kakaotalk-4.5.0</string>
<string>kakaostory-2.9.0</string>
<string>pinterestsdk.v1</string>
<string>tumblr</string>
<string>evernote</string>
<string>en</string>
<string>enx</string>
<string>evernotecid</string>
<string>evernotemsg</string>
<string>youdaonote</string>
<string>ynotedictfav</string>
<string>com.youdao.note.todayViewNote</string>
<string>ynotesharesdk</string>
<string>gplus</string>
<string>pocket</string>
<string>readitlater</string>
<string>pocket-oauth-v1</string>
<string>fb131450656879143</string>
<string>en-readitlater-5776</string>
<string>com.ideashower.ReadItLaterPro3</string>
<string>com.ideashower.ReadItLaterPro</string>
<string>com.ideashower.ReadItLaterProAlpha</string>
<string>com.ideashower.ReadItLaterProEnterprise</string>
<string>vk</string>
<string>vk-share</string>
<string>vkauthorize</string>
</array>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>NSAppTransportSecurity</key>
......
This diff is collapsed.
......@@ -54,6 +54,14 @@ didRegisterForRemoteNotificationsWithDeviceToken:(NSData *)deviceToken {
// Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game.
}
- (BOOL)application:(UIApplication *)application openURL:(NSURL *)url sourceApplication:(NSString *)sourceApplication annotation:(id)annotation
{
BOOL result = [[UMSocialManager defaultManager] handleOpenURL:url];
if (!result) {
// 其他如支付等SDK的回调
}
return result;
}
- (void)applicationDidEnterBackground:(UIApplication *)application {
// Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later.
......
{
"images" : [
{
"idiom" : "universal",
"filename" : "state_audit.png",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "state_audit@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "state_audit@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"filename" : "state_complete.png",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "state_complete@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "state_complete@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"filename" : "state_reject.png",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "state_reject@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "state_reject@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
{
"images" : [
{
"idiom" : "universal",
"filename" : "state_transfer_account.png",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "state_transfer_account@2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "state_transfer_account@3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
\ No newline at end of file
This diff is collapsed.
//
// AccountRecordTableViewCell.h
// Car
//
// Created by Javen on 2017/2/10.
// Copyright © 2017年 上海勾芒信息科技. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface AccountRecordTableViewCell : UITableViewCell
/**
单号
*/
@property (weak, nonatomic) IBOutlet UILabel *labelTitle;
/**
提现工分
*/
@property (weak, nonatomic) IBOutlet UILabel *labelCash;
/**
申请时间
*/
@property (weak, nonatomic) IBOutlet UILabel *labelTime;
/**
状态图片
*/
@property (weak, nonatomic) IBOutlet UIImageView *imgState;
/**
转账时间
*/
@property (weak, nonatomic) IBOutlet UILabel *labelTransferTime;
- (void)configCell:(DrawCashBillEntity *)model;
@end
//
// AccountRecordTableViewCell.m
// Car
//
// Created by Javen on 2017/2/10.
// Copyright © 2017年 上海勾芒信息科技. All rights reserved.
//
#import "AccountRecordTableViewCell.h"
#import "AccountStateModel.h"
@implementation AccountRecordTableViewCell
- (void)awakeFromNib {
[super awakeFromNib];
// Initialization code
}
- (void)configCell:(DrawCashBillEntity *)model {
self.labelTitle.text = model.billNumber;
self.imgState.image = [UIImage imageNamed:[AccountStateModel stateFrom:model.state].imgName];
self.labelTime.text = model.createDate;
self.labelCash.text = [NSString stringWithFormat:@"%@分 (金额%@元)",
[CalculateHelper getMoneyStringFrom:model.workpoint],
[CalculateHelper getMoneyStringFrom:model.cash]];
self.labelTransferTime.text = model.finishDate ? model.finishDate : @"__ __ __ __ —:—:—";
}
- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
[super setSelected:selected animated:animated];
// Configure the view for the selected state
}
@end
//
// AccountRecordViewController.h
// Car
//
// Created by Javen on 2017/2/9.
// Copyright © 2017年 上海勾芒信息科技. All rights reserved.
//
#import "BaseViewController.h"
@interface AccountRecordViewController : BaseListViewController
@end
//
// AccountRecordViewController.m
// Car
//
// Created by Javen on 2017/2/9.
// Copyright © 2017年 上海勾芒信息科技. All rights reserved.
//
#import "AccountRecordViewController.h"
#import "AccountRecordTableViewCell.h"
@interface AccountRecordViewController ()
@property (strong, nonatomic) WithdrawQueryDefintion *param;
@end
@implementation AccountRecordViewController
- (void)viewDidLoad {
[super viewDidLoad];
self.title = @"提现记录";
[self httpRequest];
// Do any additional setup after loading the view.
}
- (void)httpRequest {
WS(weakSelf);
[MBProgressHUD j_loading];
[kHttp POST:kUserCashRecord parameters:[self.param toDictionary] complete:^(id _Nullable response, NSError * _Nullable error) {
[MBProgressHUD j_hideLoadingView];
if (kRsSuccess(response)) {
for (NSDictionary *dict in response[@"data"][@"records"]) {
DrawCashBillEntity *model = [[DrawCashBillEntity alloc] initWithDictionary:dict error:nil];
[weakSelf.arrData addObject:model];
}
[weakSelf listTableViewReloadData];
}else{
kFalseHttpTips;
}
}];
}
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
AccountRecordTableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:@"AccountRecordTableViewCell" forIndexPath:indexPath];
DrawCashBillEntity *model = self.arrData[indexPath.row];
[cell configCell:model];
return cell;
}
- (void)listDidSelect:(id)model {
}
- (WithdrawQueryDefintion *)param {
if (!_param) {
_param = [[WithdrawQueryDefintion alloc] init];
QueryOrder *order = [[QueryOrder alloc] init];
order.field = @"createDate";
order.direction = @"desc";
_param.orders = (NSArray<QueryOrder> *)@[order];
_param.userId = kUser.fid;
}
return _param;
}
- (void)didReceiveMemoryWarning {
[super didReceiveMemoryWarning];
// Dispose of any resources that can be recreated.
}
/*
#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
......@@ -7,7 +7,10 @@
//
#import "BaseViewController.h"
typedef NS_ENUM(NSInteger, AccountViewControllerType) {
AccountViewControllerTypeBinding,
AccountViewControllerTypeUnBing
};
@interface AccountViewController : BaseViewController
@property (nonatomic, assign) AccountViewControllerType type;
@end
......@@ -7,21 +7,23 @@
//
#import "AccountViewController.h"
#import "UMSocialManager.h"
#import <UMSocialCore/UMSocialCore.h>
#import "AccountRecordViewController.h"
@interface AccountViewController ()
/**
工分总额
*/
@property (weak, nonatomic) IBOutlet UIView *labelTotalScore;
@property (weak, nonatomic) IBOutlet UILabel *labelTotalScore;
/**
可换
可换
*/
@property (weak, nonatomic) IBOutlet UILabel *labelValidScore;
/**
*/
@property (weak, nonatomic) IBOutlet UITextField *textFieldScore;
......@@ -35,6 +37,12 @@
*/
@property (weak, nonatomic) IBOutlet UILabel *labelToWechatInfo;
@property (weak, nonatomic) IBOutlet UIView *scoreView;
@property (weak, nonatomic) IBOutlet UIButton *btnBottom;
/**
请求体
*/
@property (strong, nonatomic) DrawCashBillEntity *param;
@end
......@@ -42,22 +50,185 @@
- (void)viewDidLoad {
[super viewDidLoad];
// self.scoreView.hidden = YES;
self.title = @"工分提现";
[self configUI];
switch (self.type) {
case AccountViewControllerTypeUnBing:
[self unBinding];
break;
case AccountViewControllerTypeBinding:
[self isBinding];
break;
default:
break;
}
// Do any additional setup after loading the view.
}
- (void)viewWillAppear:(BOOL)animated {
[super viewWillAppear:animated];
[self httpGetWorkPoint];
}
//已绑定
- (void)isBinding {
self.scoreView.hidden = NO;
UIBarButtonItem *rightBtn = [[UIBarButtonItem alloc] initWithTitle:@"提现记录" style:UIBarButtonItemStyleDone target:self action:@selector(actionRecods)];
self.navigationItem.rightBarButtonItem = rightBtn;
[self.btnBottom setTitle:@"提交申请" forState:UIControlStateNormal];
[self httpGetWorkPoint];
}
//未绑定
- (void)unBinding {
self.scoreView.hidden = YES;
}
//界面设置
- (void)configUI {
self.title = @"工分提现";
//未绑定微信的底部的提示
NSString *contentStr = @"亲,您还没有绑定微信哦,工分提现需要先绑定微信哦,我们的提现金额会提到微信钱包中。 ";
NSString *contentStr = @"亲,您还没有绑定微信哦,工分提现需要先绑定微信哦,我们的提现金额会提到微信钱包中。";
NSRange range = [contentStr rangeOfString:@"提现金额会提到微信钱包中"];
NSMutableAttributedString *str = [[NSMutableAttributedString alloc]initWithString:contentStr];
NSMutableAttributedString *str = [[NSMutableAttributedString alloc] initWithString:contentStr];
//设置:在0-3个单位长度内的内容显示成红色
[str addAttribute:NSForegroundColorAttributeName value:kMainColor range:range];
self.labelToWechatInfo.attributedText = str;
//输入工分动态计算金额
[self.textFieldScore addTarget:self action:@selector(textFieldDidChange:) forControlEvents:UIControlEventAllEditingEvents];
}
- (void)textFieldDidChange:(UITextField *)textField {
NSDecimalNumber *number = [CalculateHelper mul:textField.text num2:@(0.01)];
NSString *money = [CalculateHelper getMoneyStringFrom:number];
NSString *info = [NSString stringWithFormat:@"对应金额 %@元", money];
self.labelInfo.text = info;
}
#pragma mark - actions
- (void)actionRecods {
AccountRecordViewController *recordVC = [AccountRecordViewController viewControllerWithStoryBoardType:STORYBOARD_TYPE_MAIN];
[self.navigationController pushViewController:recordVC animated:YES];
}
- (IBAction)actionBottom:(id)sender {
switch (self.type) {
case AccountViewControllerTypeUnBing: {
[self bindWeChat];
} break;
case AccountViewControllerTypeBinding: {
WS(weakSelf);
[self alertTitle:@"确认提交?"
msg:nil
okAction:^(UIAlertAction *_Nullable action) {
[weakSelf httpSubmit];
}
cancelAction:nil];
break;
}
default:
break;
}
}
/**
绑定微信 第三方登录
*/
- (void)bindWeChat {
WS(weakSelf);
[[UMSocialManager defaultManager] getUserInfoWithPlatform:UMSocialPlatformType_WechatSession currentViewController:self completion:^(id result, NSError *error) {
if (error) {
[MBProgressHUD j_error:@"绑定出错,请重试!" complete:nil];
return ;
}
UMSocialUserInfoResponse *resp = result;
// 第三方登录数据(为空表示平台未提供)
// 授权数据
NSLog(@" uid: %@", resp.uid);
[weakSelf httpUploadUnionId:resp.uid];
NSLog(@" openid: %@", resp.openid);
NSLog(@" accessToken: %@", resp.accessToken);
NSLog(@" refreshToken: %@", resp.refreshToken);
NSLog(@" expiration: %@", resp.expiration);
// 用户数据
NSLog(@" name: %@", resp.name);
NSLog(@" iconurl: %@", resp.iconurl);
NSLog(@" gender: %@", resp.gender);
// 第三方平台SDK原始数据
NSLog(@" originalResponse: %@", resp.originalResponse);
}];
}
- (void)httpUploadUnionId:(NSString *)uid {
NSDictionary *param = @{@"userId":kUser.fid,
@"unionId":uid};
WS(weakSelf);
[kHttp POST:kModifyUserWxUid parameters:param complete:^(id _Nullable response, NSError * _Nullable error) {
if (kRsMsg(response)) {
[MBProgressHUD j_success:@"绑定成功!" complete:^{
kUser.wxOpenId = response[@"data"];
[weakSelf isBinding];
}];
}else{
kFalseHttpTips;
}
}];
}
- (void)httpSubmit {
[MBProgressHUD j_loading];
WS(weakSelf);
kCanNotBeNil(self.textFieldScore.text, @"请输入要兑换的工分数!");
[kHttp POST:kCashApply
parameters:[self.param toDictionary]
complete:^(id _Nullable response, NSError *_Nullable error) {
if (kRsSuccess(response)) {
[MBProgressHUD j_success:@"提交成功!" complete:nil];
weakSelf.labelInfo.text = @"对应金额 0.00元";
weakSelf.textFieldScore.text = nil;
[weakSelf httpGetWorkPoint];
} else {
kFalseHttpTips;
}
}];
}
- (void)httpGetWorkPoint {
NSDictionary *param = @{ @"userId" : kUser.fid };
WS(weakSelf);
[kHttp GET:kAccountGetUrl
parameters:param
complete:^(id _Nullable response, NSError *_Nullable error) {
if (kRsSuccess(response)) {
StationUserAcctEntity *acc = [[StationUserAcctEntity alloc] initWithDictionary:response[@"data"] error:nil];
weakSelf.labelTotalScore.text = [NSString stringWithFormat:@"%@", acc.balance];
weakSelf.labelValidScore.text = [NSString stringWithFormat:@"%@", acc.drawBalance];
}
}];
}
- (DrawCashBillEntity *)param {
if (!_param) {
_param = [[DrawCashBillEntity alloc] init];
_param.applicantId = kUser.fid;
_param.applicantName = kUser.realName;
}
_param.workpoint = [NSDecimalNumber decimalNumberWithString:self.textFieldScore.text];
_param.cash = [CalculateHelper mul:self.textFieldScore.text num2:@(0.01)];
return _param;
}
- (void)didReceiveMemoryWarning {
......
//
// AccountStateModel.h
// Car
//
// Created by Javen on 2017/2/10.
// Copyright © 2017年 上海勾芒信息科技. All rights reserved.
//
#import "BaseStateModel.h"
@interface AccountStateModel : BaseStateModel
@end
//
// AccountStateModel.m
// Car
//
// Created by Javen on 2017/2/10.
// Copyright © 2017年 上海勾芒信息科技. All rights reserved.
//
#import "AccountStateModel.h"
@implementation AccountStateModel
+ (BaseStateModel *)stateFrom:(NSString *)state {
BaseStateModel *model = [BaseStateModel stateModel];
if ([state isEqualToString:@"approving"]) {
model.text = @"待审核";
model.imgName = @"state_audit";
}else if ([state isEqualToString:@"approved"]){
model.text = @"转账中";
model.imgName = @"state_transfer_account";
}else if ([state isEqualToString:@"rejected"]){
model.text = @"已拒绝";
model.imgName = @"state_reject";
}else if ([state isEqualToString:@"finished"]){
model.text = @"已完成";
model.imgName = @"state_complete";
}
return model;
}
@end
......@@ -58,6 +58,12 @@
[kGlobal.mainNaVC pushViewController:billVC animated:YES];
}else if (indexPath.row == 1) {//账户
AccountViewController *accoutVC = [AccountViewController viewControllerWithStoryBoardType:STORYBOARD_TYPE_MAIN];
CLog(@"--------->%@",kUser.wxOpenId);
if (kUser.wxOpenId.length > 0) {
accoutVC.type = AccountViewControllerTypeBinding;
}else{
accoutVC.type = AccountViewControllerTypeUnBing;
}
[kGlobal.mainNaVC pushViewController:accoutVC animated:YES];
}else if (indexPath.row == 2) {//核销卡券
[self scanCard];
......
......@@ -12,12 +12,11 @@
#import "WWSideslipViewController.h"
#import "HttpCilent.h"
#import "BMKLocationService.h"
@interface LoginViewController ()<BMKLocationServiceDelegate>
{
@interface LoginViewController () <BMKLocationServiceDelegate> {
BMKLocationService *_locService;
}
@property(weak, nonatomic) IBOutlet UITextField *textFieldUser;
@property(weak, nonatomic) IBOutlet UITextField *textFieldPsw;
@property (weak, nonatomic) IBOutlet UITextField *textFieldUser;
@property (weak, nonatomic) IBOutlet UITextField *textFieldPsw;
@property (strong, nonatomic) NSString *latitute;
@property (strong, nonatomic) NSString *longtitude;
@property (weak, nonatomic) IBOutlet UIButton *btnLogin;
......@@ -30,12 +29,13 @@
[super viewDidLoad];
[self configUI];
//初始化BMKLocationService
_locService = [[BMKLocationService alloc]init];
_locService = [[BMKLocationService alloc] init];
_locService.delegate = self;
//启动LocationService
WS(weakSelf);
[kHttp checkUpdateOnVC:self completeIsLatest:^{
[kHttp checkUpdateOnVC:self
completeIsLatest:^{
weakSelf.btnLogin.enabled = YES;
}];
// Do any additional setup after loading the view.
......@@ -43,17 +43,15 @@
//实现相关delegate 处理位置信息更新
//处理方向变更信息
- (void)didUpdateUserHeading:(BMKUserLocation *)userLocation
{
NSLog(@"heading is %@",userLocation.heading);
- (void)didUpdateUserHeading:(BMKUserLocation *)userLocation {
NSLog(@"heading is %@", userLocation.heading);
}
//处理位置坐标更新
- (void)didUpdateBMKUserLocation:(BMKUserLocation *)userLocation
{
- (void)didUpdateBMKUserLocation:(BMKUserLocation *)userLocation {
self.longtitude = [NSString stringWithFormat:@"%f", userLocation.location.coordinate.longitude];
self.latitute = [NSString stringWithFormat:@"%f", userLocation.location.coordinate.latitude];
[_locService stopUserLocationService];
NSLog(@"didUpdateUserLocation lat %f,long %f",userLocation.location.coordinate.latitude,userLocation.location.coordinate.longitude);
NSLog(@"didUpdateUserLocation lat %f,long %f", userLocation.location.coordinate.latitude, userLocation.location.coordinate.longitude);
}
- (void)viewWillAppear:(BOOL)animated {
......@@ -113,7 +111,7 @@
kGlobal.userPsw = weakSelf.textFieldPsw.text;
sideVC.modalTransitionStyle = UIModalTransitionStyleCrossDissolve;
[self presentViewController:sideVC animated:YES completion:nil];
}else{
} else {
kShowRsMsg(response);
}
}];
......
......@@ -129,7 +129,7 @@
QueryOrder *order = [[QueryOrder alloc] init];
order.field = @"payTime";
order.direction = @"desc";
_param.orders = @[order];
_param.orders = (NSArray<QueryOrder> *)@[order];
_param.userId = kUser.fid;
_param.state = @"paid";
}
......
......@@ -18,8 +18,98 @@
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>1.0.0</string>
<key>CFBundleURLTypes</key>
<array>
<dict>
<key>CFBundleTypeRole</key>
<string>Editor</string>
<key>CFBundleURLSchemes</key>
<array>
<string>wx39e5b31bb7b479c7</string>
</array>
</dict>
</array>
<key>CFBundleVersion</key>
<string>1.0.0</string>
<key>LSApplicationQueriesSchemes</key>
<array>
<string>wechat</string>
<string>weixin</string>
<string>sinaweibohd</string>
<string>sinaweibo</string>
<string>sinaweibosso</string>
<string>weibosdk</string>
<string>weibosdk2.5</string>
<string>mqqapi</string>
<string>mqq</string>
<string>mqqOpensdkSSoLogin</string>
<string>mqqconnect</string>
<string>mqqopensdkdataline</string>
<string>mqqopensdkgrouptribeshare</string>
<string>mqqopensdkfriend</string>
<string>mqqopensdkapi</string>
<string>mqqopensdkapiV2</string>
<string>mqqopensdkapiV3</string>
<string>mqqopensdkapiV4</string>
<string>mqzoneopensdk</string>
<string>wtloginmqq</string>
<string>wtloginmqq2</string>
<string>mqqwpa</string>
<string>mqzone</string>
<string>mqzonev2</string>
<string>mqzoneshare</string>
<string>wtloginqzone</string>
<string>mqzonewx</string>
<string>mqzoneopensdkapiV2</string>
<string>mqzoneopensdkapi19</string>
<string>mqzoneopensdkapi</string>
<string>mqqbrowser</string>
<string>mttbrowser</string>
<string>alipay</string>
<string>alipayshare</string>
<string>dingtalk</string>
<string>dingtalk-open</string>
<string>laiwangsso</string>
<string>yixin</string>
<string>yixinopenapi</string>
<string>instagram</string>
<string>whatsapp</string>
<string>line</string>
<string>fbapi</string>
<string>fb-messenger-api</string>
<string>fbauth2</string>
<string>fbshareextension</string>
<string>kakaofa63a0b2356e923f3edd6512d531f546</string>
<string>kakaokompassauth</string>
<string>storykompassauth</string>
<string>kakaolink</string>
<string>kakaotalk-4.5.0</string>
<string>kakaostory-2.9.0</string>
<string>pinterestsdk.v1</string>
<string>tumblr</string>
<string>evernote</string>
<string>en</string>
<string>enx</string>
<string>evernotecid</string>
<string>evernotemsg</string>
<string>youdaonote</string>
<string>ynotedictfav</string>
<string>com.youdao.note.todayViewNote</string>
<string>ynotesharesdk</string>
<string>gplus</string>
<string>pocket</string>
<string>readitlater</string>
<string>pocket-oauth-v1</string>
<string>fb131450656879143</string>
<string>en-readitlater-5776</string>
<string>com.ideashower.ReadItLaterPro3</string>
<string>com.ideashower.ReadItLaterPro</string>
<string>com.ideashower.ReadItLaterProAlpha</string>
<string>com.ideashower.ReadItLaterProEnterprise</string>
<string>vk</string>
<string>vk-share</string>
<string>vkauthorize</string>
</array>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>NSAppTransportSecurity</key>
......
......@@ -27,8 +27,8 @@
#endif
#define kFalseHttpTips \
if (responseObject) { \
[MBProgressHUD j_error:responseObject[@"message"] complete:nil]; \
if (response) { \
[MBProgressHUD j_error:response[@"message"] complete:nil]; \
}
//获取APP版本
......
......@@ -36,4 +36,11 @@ static NSString *const kGetTicketUrl = @"ticket/get?ticketNumber=";
static NSString *const kCheckTicketUrl = @"ticket/check";
static NSString *const kWatchLogin = @"stationUser/token/send";
//查询用户申请提现记录
static NSString *const kUserCashRecord = @"cash/query";
//提交工分申请
static NSString *const kCashApply = @"cash/apply";
//绑定用户微信unionId
static NSString *const kModifyUserWxUid = @"stationUser/save/openId";
#endif /* URL_h */
This diff is collapsed.
This diff is collapsed.
//
// ZJBaseModel.h
// RealEstateManagement
//
// Created by Javen on 2017/2/9.
// Copyright © 2017年 上海勾芒信息科技. All rights reserved.
//
#import <Foundation/Foundation.h>
#import "JSONModel.h"
@interface ZJBaseModel : JSONModel
{
//搜索的时候显示的名字,可以按需要重写set、get方法
NSString *_zj_displayName;
}
- (NSString *)zj_displayName;
- (void)setZj_displayName:(NSString *)zj_displayName;
/**
字典转模型
@param dic 字典
@return 转换之后的模型类
*/
+ (instancetype)modelWithDic:(NSDictionary *)dic;
/**
模型转模型
@param model 要转换的模型类
@return 转换之后的模型类
*/
- (instancetype)modelWithModel:(id)model;
@end
//
// ZJBaseModel.m
// RealEstateManagement
//
// Created by Javen on 2017/2/9.
// Copyright © 2017年 上海勾芒信息科技. All rights reserved.
//
#import "ZJBaseModel.h"
@implementation ZJBaseModel
/**
字典转模型
@param dic 字典
@return 转换之后的模型类
*/
+ (instancetype)modelWithDic:(NSDictionary *)dic {
id model = [[self alloc] initWithDictionary:dic error:nil];
return model;
}
/**
模型转模型
@param model 要转换的模型类
@return 转换之后的模型类
*/
- (instancetype)modelWithModel:(id)model {
id destinationModel = [[self class] modelWithDic:[model toDictionary]];
return destinationModel;
}
- (void)setZj_displayName:(NSString *)zj_displayName {
_zj_displayName = zj_displayName;
}
- (NSString *)zj_displayName {
return _zj_displayName;
}
@end
//
// StateModel.h
// Car
//
// Created by Javen on 2017/2/10.
// Copyright © 2017年 上海勾芒信息科技. All rights reserved.
// 用于切换状态
#import <Foundation/Foundation.h>
@interface BaseStateModel : NSObject
@property (nonatomic, copy) NSString *imgName;
@property (nonatomic, copy) NSString *text;
@property (nonatomic, copy) NSString *code;
+ (instancetype)stateModel;
//不同单据重写对应方法
+ (BaseStateModel *)stateFrom:(NSString *)state;
@end
//
// StateModel.m
// Car
//
// Created by Javen on 2017/2/10.
// Copyright © 2017年 上海勾芒信息科技. All rights reserved.
//
#import "BaseStateModel.h"
@implementation BaseStateModel
+ (instancetype)stateModel {
id model = [[self alloc] init];
return model;
}
+ (BaseStateModel *)stateFrom:(NSString *)state {
BaseStateModel *model = [self stateModel];
return model;
}
@end
......@@ -14,8 +14,8 @@
#import "GlobalInstance.h"
#import "DateTextField.h"
#import "CalculateHelper.h"
#import "CategoryHeader.h"
#import "HttpCilent.h"
#endif /* ToolHeader_h */
......@@ -7,6 +7,8 @@
//
#import <Foundation/Foundation.h>
#import "UMMobClick/MobClick.h"
#import "UMSocialManager.h"
@interface UMengHelper : NSObject
......
......@@ -7,7 +7,7 @@
//
#import "UMengHelper.h"
#import "UMMobClick/MobClick.h"
@implementation UMengHelper
......@@ -17,5 +17,8 @@
UMConfigInstance.ePolicy = REALTIME;
[MobClick setLogEnabled:YES];
[MobClick startWithConfigure:UMConfigInstance];
[[UMSocialManager defaultManager] setUmSocialAppkey:@"58623721a40fa342b90010f4"];
[[UMSocialManager defaultManager] openLog:YES];
[[UMSocialManager defaultManager] setPlaform:UMSocialPlatformType_WechatSession appKey:@"wx39e5b31bb7b479c7" appSecret:@"85e59656d4798e2c7d75991e005fecaf" redirectURL:@"http://mobile.umeng.com/social"];
}
@end
......@@ -12,8 +12,11 @@ abstract_target 'car_base' do
pod 'BaiduMapKit', '~> 3.0.0'
pod 'JPush', '~> 2.2.0.1'
pod 'ZXingObjC', '~> 3.0'
pod 'UMengUShare/Social/WeChat'
target 'Car' do
end
target 'Car Release' do
end
end
......@@ -25,6 +25,11 @@ PODS:
- SDWebImage/Core (= 3.7.6)
- SDWebImage/Core (3.7.6)
- UMengAnalytics-NO-IDFA (4.1.5)
- UMengUShare/Core (6.2.2):
- UMengUShare/Network
- UMengUShare/Network (6.2.2)
- UMengUShare/Social/WeChat (6.2.2):
- UMengUShare/Core
- ZXingObjC (3.1.0):
- ZXingObjC/All (= 3.1.0)
- ZXingObjC/All (3.1.0)
......@@ -40,6 +45,7 @@ DEPENDENCIES:
- MJRefresh (~> 3.1.2)
- SDWebImage (~> 3.7.5)
- UMengAnalytics-NO-IDFA
- UMengUShare/Social/WeChat
- ZXingObjC (~> 3.0)
SPEC CHECKSUMS:
......@@ -53,8 +59,9 @@ SPEC CHECKSUMS:
MJRefresh: b96cdb21c4aa75a7b07654311ab2f315c497e806
SDWebImage: c325cf02c30337336b95beff20a13df489ec0ec9
UMengAnalytics-NO-IDFA: f1b08b540eba6ebad044a574cae6d988cf40cfda
UMengUShare: fc0a98b8d5297632e82874318fd72a10d17da228
ZXingObjC: bf15b3814f7a105b6d99f47da2333c93a063650a
PODFILE CHECKSUM: 58e948bb390decead177e9dc3d166ca7d699db32
PODFILE CHECKSUM: e9648119590790f6e637a439070d1eeaeac8afa5
COCOAPODS: 1.1.1
COCOAPODS: 1.2.0
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