Commit 78548095 authored by 曹云霄's avatar 曹云霄

设置角标问题

parent 0cf0f7f8
......@@ -137,6 +137,7 @@
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
{
ForumItemTableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:@"ForumItemTableViewCell" forIndexPath:indexPath];
cell.backgroundColor = RGB(237, 238, 239, 1);
cell.indexPath = indexPath;
cell.topicEntity = self.datasArray[indexPath.row];
cell.imageBackView.delegate = self;
......
......@@ -433,6 +433,7 @@
topic.posterName = [Shoppersmanager manager].Shoppers.employee.userName;
topic.posterRealName = [Shoppersmanager manager].Shoppers.employee.realName;
topic.posterPosition = [Shoppersmanager manager].Shoppers.employee.positionsName;
topic.posterPicture = [Shoppersmanager manager].Shoppers.employee.picture;
topic.postTime = [[self class] getTimeby:0];
topic.category = self.category.fid;
topic.backEnd = NO;
......
......@@ -157,6 +157,7 @@
return;
}
}
[Shoppersmanager manager].Shoppers.employee.isComplete = NO;
self.navigationItem.rightBarButtonItem.enabled = YES;
}
......@@ -166,6 +167,9 @@
if ([Shoppersmanager manager].Shoppers.employee.isComplete) {
[self dismissViewControllerAnimated:YES completion:nil];return;
}
if (![HENLENSONG isValidateMobile:self.informationArray[1][3]]) {
[XBLoadingView showHUDViewWithText:@"手机号码格式不正确"];return;
}
WS(weakSelf);
[XBLoadingView showHUDViewWithDefault];
RsEmployeeRequest *employ = [[RsEmployeeRequest alloc]init];
......
......@@ -99,6 +99,7 @@
}
[self.buttonArray addObject:button];
}
[self setBadge];
//创建下划线
CustomButton *Newbutton = (CustomButton *)[self viewWithTag:104];
self.underlineView = [[UIView alloc]initWithFrame:CGRectMake(Newbutton.frame.origin.x+(ButtonWIDTH-50)/2, ButtonRIGHT+8, 50, 2)];
......@@ -166,6 +167,8 @@
CustomButton *button = (CustomButton *)[self viewWithTag:102];
NSInteger number = [object.object integerValue];
button.instructionsNumber -= number;
[Shoppersmanager manager].Shoppers.hasNotReadAffiche -= number;
[self setBadge];
}
#pragma mark - 未读消息
......@@ -174,6 +177,8 @@
CustomButton *button = (CustomButton *)[self viewWithTag:101];
NSInteger number = [object.object integerValue];
button.instructionsNumber -= number;
[Shoppersmanager manager].Shoppers.hasNotReadNotice -= number;
[self setBadge];
}
#pragma mark -更改当前用户名
......@@ -205,6 +210,14 @@
[self buttonClick:button];
}
#pragma mark -设置系统 Badge角标值
- (void)setBadge
{
NSInteger count = [Shoppersmanager manager].Shoppers.hasNotReadNotice + [Shoppersmanager manager].Shoppers.hasNotReadAffiche;
[JPUSHService setBadge:count];
[UIApplication sharedApplication].applicationIconBadgeNumber = count;
}
#pragma mark -二维码扫描码
- (void)qrCodeButtonClickAction
......
......@@ -12,14 +12,6 @@
#import <Bugly/Bugly.h>
#import "UMMobClick/MobClick.h"
// 引入JPush功能所需头文件
#import "JPUSHService.h"
// iOS10注册APNs所需头文件
#ifdef NSFoundationVersionNumber_iOS_9_x_Max
#import <UserNotifications/UserNotifications.h>
#endif
@interface AppDelegate ()<JPUSHRegisterDelegate>
......@@ -65,8 +57,6 @@
channel:@"蒲公英"
apsForProduction:NO
advertisingIdentifier:nil];
[JPUSHService resetBadge];
}
- (UIInterfaceOrientationMask)application:(UIApplication *)application supportedInterfaceOrientationsForWindow:(nullable UIWindow *)window
......
......@@ -56,6 +56,12 @@
#import "CustomTOAfficheEntity.h"
#import "ICRPlaceholderTextView.h"
#import "YXAlertController.h"
// 引入JPush功能所需头文件
#import "JPUSHService.h"
// iOS10注册APNs所需头文件
#ifdef NSFoundationVersionNumber_iOS_9_x_Max
#import <UserNotifications/UserNotifications.h>
#endif
/**
......
......@@ -1981,7 +1981,7 @@ extern NSString * const GRADEMETHOD_MANUL;
/**
是否置顶
*/
@property (nonatomic,assign) NSInteger top;
@property (nonatomic,copy) NSString *top;
/**
* 方法: 取得回复数
*
......
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