Quellcode durchsuchen

修改曲目ID字段根据字符串接收

Steven vor 9 Monaten
Ursprung
Commit
e6a0db0744
21 geänderte Dateien mit 50 neuen und 50 gelöschten Zeilen
  1. 1 1
      KulexiuForTeacher/KulexiuForTeacher/Module/Chat/Controller/TXCustom/KSTXBaseChatViewController.m
  2. 3 3
      KulexiuForTeacher/KulexiuForTeacher/Module/Chat/Model/ChatUserInfo/RecentPracticeModel.h
  3. 5 5
      KulexiuForTeacher/KulexiuForTeacher/Module/Chat/Model/ChatUserInfo/RecentPracticeModel.m
  4. 1 1
      KulexiuForTeacher/KulexiuForTeacher/Module/Chat/View/ChatUserInfo/RecentMusicView.m
  5. 1 1
      KulexiuForTeacher/KulexiuForTeacher/Module/Chat/View/ChatUserInfo/UserDetailBodyView.h
  6. 1 1
      KulexiuForTeacher/KulexiuForTeacher/Module/Home/Model/HomeMusicModel.h
  7. 4 4
      KulexiuForTeacher/KulexiuForTeacher/Module/Home/Model/HomeMusicModel.m
  8. 1 1
      KulexiuForTeacher/KulexiuForTeacher/Module/Home/Music/Model/MusicMessageModel.h
  9. 5 5
      KulexiuForTeacher/KulexiuForTeacher/Module/Home/Music/Model/MusicMessageModel.m
  10. 4 4
      KulexiuForTeacher/KulexiuForTeacher/Module/Home/Music/View/MyMusicBodyView.m
  11. 1 1
      KulexiuForTeacher/KulexiuForTeacher/Module/Home/MyCourse/View/MyVideoCourseBodyView.m
  12. 1 1
      KulexiuForTeacher/KulexiuForTeacher/Module/Home/View/HomeMusic/HomeHotMusicCellView.m
  13. 1 1
      KulexiuForTeacher/KulexiuForTeacher/Module/Mine/LiveList/Model/LiveListModel.h
  14. 5 5
      KulexiuForTeacher/KulexiuForTeacher/Module/Mine/LiveList/Model/LiveListModel.m
  15. 1 1
      KulexiuForTeacher/KulexiuForTeacher/Module/Mine/LiveList/Model/LiveVideoModel.h
  16. 5 5
      KulexiuForTeacher/KulexiuForTeacher/Module/Mine/LiveList/Model/LiveVideoModel.m
  17. 1 1
      KulexiuForTeacher/KulexiuForTeacher/Module/Mine/MinePage/View/MinePageCourseView.m
  18. 1 1
      KulexiuForTeacher/KulexiuForTeacher/Module/Mine/MinePage/View/MinePageVideoView.m
  19. 1 1
      KulexiuForTeacher/KulexiuForTeacher/Module/Mine/VideoCourse/Model/VideoCourseModel.h
  20. 5 5
      KulexiuForTeacher/KulexiuForTeacher/Module/Mine/VideoCourse/Model/VideoCourseModel.m
  21. 2 2
      KulexiuForTeacher/KulexiuForTeacher/Module/Mine/VideoCourse/View/VideoListBodyView.m

+ 1 - 1
KulexiuForTeacher/KulexiuForTeacher/Module/Chat/Controller/TXCustom/KSTXBaseChatViewController.m

@@ -148,7 +148,7 @@ static UIView *gCustomTopView;
     }
     [parm setValue:owner forKey:@"teacherName"];
     [parm setValue:musicModel.subjectNames forKey:@"musicTagNames"];
-    [parm setValue:[NSString stringWithFormat:@"%.0f",musicModel.internalBaseClassIdentifier] forKey:@"songId"];
+    [parm setValue:musicModel.internalBaseClassIdentifier forKey:@"songId"];
     
     NSData *data = [NSJSONSerialization dataWithJSONObject:parm options:0 error:nil];
     V2TIMMessage *message = [[V2TIMManager sharedInstance] createCustomMessage:data];

+ 3 - 3
KulexiuForTeacher/KulexiuForTeacher/Module/Chat/Model/ChatUserInfo/RecentPracticeModel.h

@@ -14,7 +14,7 @@
 @property (nonatomic, strong) NSString *metronomeUrl;
 @property (nonatomic, strong) NSString *musicSheetName;
 @property (nonatomic, assign) double albumNums;
-@property (nonatomic, assign) double internalBaseClassIdentifier;
+@property (nonatomic, strong) NSString *internalBaseClassIdentifier;
 @property (nonatomic, strong) NSString *xmlFileUrl;
 @property (nonatomic, assign) double showFingering;
 @property (nonatomic, assign) double albumSortNumber;
@@ -28,7 +28,7 @@
 @property (nonatomic, assign) double musicPrice;
 @property (nonatomic, assign) double sortNumber;
 @property (nonatomic, assign) double exquisiteFlag;
-@property (nonatomic, assign) id play;
+@property (nonatomic, strong) NSString *play;
 @property (nonatomic, strong) NSString *addUserAvatar;
 @property (nonatomic, strong) NSString *audioType;
 @property (nonatomic, assign) double canEvaluate;
@@ -52,7 +52,7 @@
 @property (nonatomic, strong) NSString *sourceType;
 @property (nonatomic, strong) NSString *firstPassAuditTime;
 @property (nonatomic, strong) NSString *mp3Type;
-@property (nonatomic, assign) id hotFlag;
+@property (nonatomic, strong) NSString *hotFlag;
 @property (nonatomic, strong) NSString *createTime;
 @property (nonatomic, assign) double playSpeed;
 @property (nonatomic, strong) NSString *audioFileUrl;

+ 5 - 5
KulexiuForTeacher/KulexiuForTeacher/Module/Chat/Model/ChatUserInfo/RecentPracticeModel.m

@@ -137,7 +137,7 @@ NSString *const kRecentPracticeModelSubmitAuditTime = @"submitAuditTime";
             self.metronomeUrl = [self objectOrNilForKey:kRecentPracticeModelMetronomeUrl fromDictionary:dict];
             self.musicSheetName = [self objectOrNilForKey:kRecentPracticeModelMusicSheetName fromDictionary:dict];
             self.albumNums = [[self objectOrNilForKey:kRecentPracticeModelAlbumNums fromDictionary:dict] doubleValue];
-            self.internalBaseClassIdentifier = [[self objectOrNilForKey:kRecentPracticeModelId fromDictionary:dict] doubleValue];
+            self.internalBaseClassIdentifier = [self objectOrNilForKey:kRecentPracticeModelId fromDictionary:dict];
             self.xmlFileUrl = [self objectOrNilForKey:kRecentPracticeModelXmlFileUrl fromDictionary:dict];
             self.showFingering = [[self objectOrNilForKey:kRecentPracticeModelShowFingering fromDictionary:dict] doubleValue];
             self.albumSortNumber = [[self objectOrNilForKey:kRecentPracticeModelAlbumSortNumber fromDictionary:dict] doubleValue];
@@ -198,7 +198,7 @@ NSString *const kRecentPracticeModelSubmitAuditTime = @"submitAuditTime";
     [mutableDict setValue:self.metronomeUrl forKey:kRecentPracticeModelMetronomeUrl];
     [mutableDict setValue:self.musicSheetName forKey:kRecentPracticeModelMusicSheetName];
     [mutableDict setValue:[NSNumber numberWithDouble:self.albumNums] forKey:kRecentPracticeModelAlbumNums];
-    [mutableDict setValue:[NSNumber numberWithDouble:self.internalBaseClassIdentifier] forKey:kRecentPracticeModelId];
+    [mutableDict setValue:self.internalBaseClassIdentifier forKey:kRecentPracticeModelId];
     [mutableDict setValue:self.xmlFileUrl forKey:kRecentPracticeModelXmlFileUrl];
     [mutableDict setValue:[NSNumber numberWithDouble:self.showFingering] forKey:kRecentPracticeModelShowFingering];
     [mutableDict setValue:[NSNumber numberWithDouble:self.albumSortNumber] forKey:kRecentPracticeModelAlbumSortNumber];
@@ -276,7 +276,7 @@ NSString *const kRecentPracticeModelSubmitAuditTime = @"submitAuditTime";
     self.metronomeUrl = [aDecoder decodeObjectForKey:kRecentPracticeModelMetronomeUrl];
     self.musicSheetName = [aDecoder decodeObjectForKey:kRecentPracticeModelMusicSheetName];
     self.albumNums = [aDecoder decodeDoubleForKey:kRecentPracticeModelAlbumNums];
-    self.internalBaseClassIdentifier = [aDecoder decodeDoubleForKey:kRecentPracticeModelId];
+    self.internalBaseClassIdentifier = [aDecoder decodeObjectForKey:kRecentPracticeModelId];
     self.xmlFileUrl = [aDecoder decodeObjectForKey:kRecentPracticeModelXmlFileUrl];
     self.showFingering = [aDecoder decodeDoubleForKey:kRecentPracticeModelShowFingering];
     self.albumSortNumber = [aDecoder decodeDoubleForKey:kRecentPracticeModelAlbumSortNumber];
@@ -333,7 +333,7 @@ NSString *const kRecentPracticeModelSubmitAuditTime = @"submitAuditTime";
     [aCoder encodeObject:_metronomeUrl forKey:kRecentPracticeModelMetronomeUrl];
     [aCoder encodeObject:_musicSheetName forKey:kRecentPracticeModelMusicSheetName];
     [aCoder encodeDouble:_albumNums forKey:kRecentPracticeModelAlbumNums];
-    [aCoder encodeDouble:_internalBaseClassIdentifier forKey:kRecentPracticeModelId];
+    [aCoder encodeObject:_internalBaseClassIdentifier forKey:kRecentPracticeModelId];
     [aCoder encodeObject:_xmlFileUrl forKey:kRecentPracticeModelXmlFileUrl];
     [aCoder encodeDouble:_showFingering forKey:kRecentPracticeModelShowFingering];
     [aCoder encodeDouble:_albumSortNumber forKey:kRecentPracticeModelAlbumSortNumber];
@@ -392,7 +392,7 @@ NSString *const kRecentPracticeModelSubmitAuditTime = @"submitAuditTime";
         copy.metronomeUrl = [self.metronomeUrl copyWithZone:zone];
         copy.musicSheetName = [self.musicSheetName copyWithZone:zone];
         copy.albumNums = self.albumNums;
-        copy.internalBaseClassIdentifier = self.internalBaseClassIdentifier;
+        copy.internalBaseClassIdentifier = [self.internalBaseClassIdentifier copyWithZone:zone];
         copy.xmlFileUrl = [self.xmlFileUrl copyWithZone:zone];
         copy.showFingering = self.showFingering;
         copy.albumSortNumber = self.albumSortNumber;

+ 1 - 1
KulexiuForTeacher/KulexiuForTeacher/Module/Chat/View/ChatUserInfo/RecentMusicView.m

@@ -170,7 +170,7 @@
 
 - (IBAction)buttonAction:(id)sender {
     if (self.callback) {
-        NSString *songId = [NSString stringWithFormat:@"%.0f",self.model.internalBaseClassIdentifier];
+        NSString *songId = self.model.internalBaseClassIdentifier;
         self.callback(songId);
     }
 }

+ 1 - 1
KulexiuForTeacher/KulexiuForTeacher/Module/Chat/View/ChatUserInfo/UserDetailBodyView.h

@@ -8,7 +8,7 @@
 #import <UIKit/UIKit.h>
 #import "ChatUserInfo.h"
 
-typedef void(^RecentMusicCallback)(NSString *songId);
+typedef void(^RecentMusicCallback)(NSString * _Nonnull songId);
 
 NS_ASSUME_NONNULL_BEGIN
 

+ 1 - 1
KulexiuForTeacher/KulexiuForTeacher/Module/Home/Model/HomeMusicModel.h

@@ -14,7 +14,7 @@
 @property (nonatomic, strong) NSString *metronomeUrl;
 @property (nonatomic, strong) NSString *musicSheetName;
 @property (nonatomic, assign) double albumNums;
-@property (nonatomic, assign) double internalBaseClassIdentifier;
+@property (nonatomic, strong) NSString *internalBaseClassIdentifier;
 @property (nonatomic, strong) NSString *xmlFileUrl;
 @property (nonatomic, assign) double showFingering;
 @property (nonatomic, assign) double albumSortNumber;

+ 4 - 4
KulexiuForTeacher/KulexiuForTeacher/Module/Home/Model/HomeMusicModel.m

@@ -137,7 +137,7 @@ NSString *const kHomeMusicModelSubmitAuditTime = @"submitAuditTime";
             self.metronomeUrl = [self objectOrNilForKey:kHomeMusicModelMetronomeUrl fromDictionary:dict];
             self.musicSheetName = [self objectOrNilForKey:kHomeMusicModelMusicSheetName fromDictionary:dict];
             self.albumNums = [[self objectOrNilForKey:kHomeMusicModelAlbumNums fromDictionary:dict] doubleValue];
-            self.internalBaseClassIdentifier = [[self objectOrNilForKey:kHomeMusicModelId fromDictionary:dict] doubleValue];
+            self.internalBaseClassIdentifier = [self objectOrNilForKey:kHomeMusicModelId fromDictionary:dict];
             self.xmlFileUrl = [self objectOrNilForKey:kHomeMusicModelXmlFileUrl fromDictionary:dict];
             self.showFingering = [[self objectOrNilForKey:kHomeMusicModelShowFingering fromDictionary:dict] doubleValue];
             self.albumSortNumber = [[self objectOrNilForKey:kHomeMusicModelAlbumSortNumber fromDictionary:dict] doubleValue];
@@ -198,7 +198,7 @@ NSString *const kHomeMusicModelSubmitAuditTime = @"submitAuditTime";
     [mutableDict setValue:self.metronomeUrl forKey:kHomeMusicModelMetronomeUrl];
     [mutableDict setValue:self.musicSheetName forKey:kHomeMusicModelMusicSheetName];
     [mutableDict setValue:[NSNumber numberWithDouble:self.albumNums] forKey:kHomeMusicModelAlbumNums];
-    [mutableDict setValue:[NSNumber numberWithDouble:self.internalBaseClassIdentifier] forKey:kHomeMusicModelId];
+    [mutableDict setValue:self.internalBaseClassIdentifier forKey:kHomeMusicModelId];
     [mutableDict setValue:self.xmlFileUrl forKey:kHomeMusicModelXmlFileUrl];
     [mutableDict setValue:[NSNumber numberWithDouble:self.showFingering] forKey:kHomeMusicModelShowFingering];
     [mutableDict setValue:[NSNumber numberWithDouble:self.albumSortNumber] forKey:kHomeMusicModelAlbumSortNumber];
@@ -276,7 +276,7 @@ NSString *const kHomeMusicModelSubmitAuditTime = @"submitAuditTime";
     self.metronomeUrl = [aDecoder decodeObjectForKey:kHomeMusicModelMetronomeUrl];
     self.musicSheetName = [aDecoder decodeObjectForKey:kHomeMusicModelMusicSheetName];
     self.albumNums = [aDecoder decodeDoubleForKey:kHomeMusicModelAlbumNums];
-    self.internalBaseClassIdentifier = [aDecoder decodeDoubleForKey:kHomeMusicModelId];
+    self.internalBaseClassIdentifier = [aDecoder decodeObjectForKey:kHomeMusicModelId];
     self.xmlFileUrl = [aDecoder decodeObjectForKey:kHomeMusicModelXmlFileUrl];
     self.showFingering = [aDecoder decodeDoubleForKey:kHomeMusicModelShowFingering];
     self.albumSortNumber = [aDecoder decodeDoubleForKey:kHomeMusicModelAlbumSortNumber];
@@ -333,7 +333,7 @@ NSString *const kHomeMusicModelSubmitAuditTime = @"submitAuditTime";
     [aCoder encodeObject:_metronomeUrl forKey:kHomeMusicModelMetronomeUrl];
     [aCoder encodeObject:_musicSheetName forKey:kHomeMusicModelMusicSheetName];
     [aCoder encodeDouble:_albumNums forKey:kHomeMusicModelAlbumNums];
-    [aCoder encodeDouble:_internalBaseClassIdentifier forKey:kHomeMusicModelId];
+    [aCoder encodeObject:_internalBaseClassIdentifier forKey:kHomeMusicModelId];
     [aCoder encodeObject:_xmlFileUrl forKey:kHomeMusicModelXmlFileUrl];
     [aCoder encodeDouble:_showFingering forKey:kHomeMusicModelShowFingering];
     [aCoder encodeDouble:_albumSortNumber forKey:kHomeMusicModelAlbumSortNumber];

+ 1 - 1
KulexiuForTeacher/KulexiuForTeacher/Module/Home/Music/Model/MusicMessageModel.h

@@ -13,7 +13,7 @@
 
 @property (nonatomic, strong) NSString *metronomeUrl;
 @property (nonatomic, strong) NSString *musicSheetName;
-@property (nonatomic, assign) double internalBaseClassIdentifier;
+@property (nonatomic, strong) NSString *internalBaseClassIdentifier;
 @property (nonatomic, strong) NSString *xmlFileUrl;
 @property (nonatomic, assign) double showFingering;
 @property (nonatomic, strong) NSString *remark;

+ 5 - 5
KulexiuForTeacher/KulexiuForTeacher/Module/Home/Music/Model/MusicMessageModel.m

@@ -117,7 +117,7 @@ NSString *const kMusicMessageModelAlbumNums = @"albumNums";
     if(self && [dict isKindOfClass:[NSDictionary class]]) {
             self.metronomeUrl = [self objectOrNilForKey:kMusicMessageModelMetronomeUrl fromDictionary:dict];
             self.musicSheetName = [self objectOrNilForKey:kMusicMessageModelMusicSheetName fromDictionary:dict];
-            self.internalBaseClassIdentifier = [[self objectOrNilForKey:kMusicMessageModelId fromDictionary:dict] doubleValue];
+            self.internalBaseClassIdentifier = [self objectOrNilForKey:kMusicMessageModelId fromDictionary:dict];
             self.xmlFileUrl = [self objectOrNilForKey:kMusicMessageModelXmlFileUrl fromDictionary:dict];
             self.showFingering = [[self objectOrNilForKey:kMusicMessageModelShowFingering fromDictionary:dict] doubleValue];
             self.remark = [self objectOrNilForKey:kMusicMessageModelRemark fromDictionary:dict];
@@ -168,7 +168,7 @@ NSString *const kMusicMessageModelAlbumNums = @"albumNums";
     NSMutableDictionary *mutableDict = [NSMutableDictionary dictionary];
     [mutableDict setValue:self.metronomeUrl forKey:kMusicMessageModelMetronomeUrl];
     [mutableDict setValue:self.musicSheetName forKey:kMusicMessageModelMusicSheetName];
-    [mutableDict setValue:[NSNumber numberWithDouble:self.internalBaseClassIdentifier] forKey:kMusicMessageModelId];
+    [mutableDict setValue:self.internalBaseClassIdentifier forKey:kMusicMessageModelId];
     [mutableDict setValue:self.xmlFileUrl forKey:kMusicMessageModelXmlFileUrl];
     [mutableDict setValue:[NSNumber numberWithDouble:self.showFingering] forKey:kMusicMessageModelShowFingering];
     [mutableDict setValue:self.remark forKey:kMusicMessageModelRemark];
@@ -236,7 +236,7 @@ NSString *const kMusicMessageModelAlbumNums = @"albumNums";
 
     self.metronomeUrl = [aDecoder decodeObjectForKey:kMusicMessageModelMetronomeUrl];
     self.musicSheetName = [aDecoder decodeObjectForKey:kMusicMessageModelMusicSheetName];
-    self.internalBaseClassIdentifier = [aDecoder decodeDoubleForKey:kMusicMessageModelId];
+    self.internalBaseClassIdentifier = [aDecoder decodeObjectForKey:kMusicMessageModelId];
     self.xmlFileUrl = [aDecoder decodeObjectForKey:kMusicMessageModelXmlFileUrl];
     self.showFingering = [aDecoder decodeDoubleForKey:kMusicMessageModelShowFingering];
     self.remark = [aDecoder decodeObjectForKey:kMusicMessageModelRemark];
@@ -284,7 +284,7 @@ NSString *const kMusicMessageModelAlbumNums = @"albumNums";
 
     [aCoder encodeObject:_metronomeUrl forKey:kMusicMessageModelMetronomeUrl];
     [aCoder encodeObject:_musicSheetName forKey:kMusicMessageModelMusicSheetName];
-    [aCoder encodeDouble:_internalBaseClassIdentifier forKey:kMusicMessageModelId];
+    [aCoder encodeObject:_internalBaseClassIdentifier forKey:kMusicMessageModelId];
     [aCoder encodeObject:_xmlFileUrl forKey:kMusicMessageModelXmlFileUrl];
     [aCoder encodeDouble:_showFingering forKey:kMusicMessageModelShowFingering];
     [aCoder encodeObject:_remark forKey:kMusicMessageModelRemark];
@@ -334,7 +334,7 @@ NSString *const kMusicMessageModelAlbumNums = @"albumNums";
 
         copy.metronomeUrl = [self.metronomeUrl copyWithZone:zone];
         copy.musicSheetName = [self.musicSheetName copyWithZone:zone];
-        copy.internalBaseClassIdentifier = self.internalBaseClassIdentifier;
+        copy.internalBaseClassIdentifier = [self.internalBaseClassIdentifier copyWithZone:zone];
         copy.xmlFileUrl = [self.xmlFileUrl copyWithZone:zone];
         copy.showFingering = self.showFingering;
         copy.remark = [self.remark copyWithZone:zone];

+ 4 - 4
KulexiuForTeacher/KulexiuForTeacher/Module/Home/Music/View/MyMusicBodyView.m

@@ -233,7 +233,7 @@
 }
 
 - (void)musicOffAction:(MusicMessageModel *)songMessage {
-    [KSNetworkingManager musicOffRequest:KS_POST musicId:[NSString stringWithFormat:@"%.0f",songMessage.internalBaseClassIdentifier] success:^(NSDictionary * _Nonnull dic) {
+    [KSNetworkingManager musicOffRequest:KS_POST musicId:songMessage.internalBaseClassIdentifier success:^(NSDictionary * _Nonnull dic) {
         if ([dic ks_integerValueForKey:@"code"] == 200 && [dic ks_boolValueForKey:@"status"]) {
             [LOADING_MANAGER KSShowMsg:@"下架成功" promptCompletion:^{
                 [self refreshAndRequestData];
@@ -248,17 +248,17 @@
 }
 
 - (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath {
-    if (self.selectIndex == 2 || self.selectIndex == 3) {
+    if (self.selectIndex == 1 || self.selectIndex == 2 || self.selectIndex == 3) {
         MusicMessageModel *model = self.dataArray[indexPath.row];
         KSBaseWKWebViewController *webCtrl = [[KSBaseWKWebViewController alloc] init];
-        webCtrl.url = [NSString stringWithFormat:@"%@/#/music-upload/%.0f/edit", WEBHOST, model.internalBaseClassIdentifier];
+        webCtrl.url = [NSString stringWithFormat:@"%@/#/music-upload/%@/edit", WEBHOST, model.internalBaseClassIdentifier];
         [self.naviController pushViewController:webCtrl animated:YES];
     }
     else { // 播放曲谱
         MusicMessageModel *model = self.dataArray[indexPath.row];
         
         KSBaseWKWebViewController *ctrl = [[KSBaseWKWebViewController alloc] init];
-        ctrl.url = [NSString stringWithFormat:@"%@%@%.0f", WEBHOST, @"/#/music-detail?id=",model.internalBaseClassIdentifier];
+        ctrl.url = [NSString stringWithFormat:@"%@%@%@", WEBHOST, @"/#/music-detail?id=",model.internalBaseClassIdentifier];
         [self.naviController pushViewController:ctrl animated:YES];
     }
 }

+ 1 - 1
KulexiuForTeacher/KulexiuForTeacher/Module/Home/MyCourse/View/MyVideoCourseBodyView.m

@@ -223,7 +223,7 @@
 
 - (void)collectionView:(UICollectionView *)collectionView didSelectItemAtIndexPath:(NSIndexPath *)indexPath {
     VideoCourseModel *model = [self.dataArray objectAtIndex:indexPath.row];
-    NSString *url = [NSString stringWithFormat:@"%@%@%.0f", WEBHOST, @"/#/videoDetail?groupId=",model.internalBaseClassIdentifier];
+    NSString *url = [NSString stringWithFormat:@"%@%@%@", WEBHOST, @"/#/videoDetail?groupId=",model.internalBaseClassIdentifier];
     KSBaseWKWebViewController *ctrl = [[KSBaseWKWebViewController alloc] init];
     ctrl.url = url;
     [self.naviController pushViewController:ctrl animated:YES];

+ 1 - 1
KulexiuForTeacher/KulexiuForTeacher/Module/Home/View/HomeMusic/HomeHotMusicCellView.m

@@ -168,7 +168,7 @@
 }
 - (IBAction)buttonAction:(id)sender {
     if (self.callback) {
-        NSString *songId = [NSString stringWithFormat:@"%.0f",self.model.internalBaseClassIdentifier];
+        NSString *songId = self.model.internalBaseClassIdentifier;
         self.callback(songId);
     }
 }

+ 1 - 1
KulexiuForTeacher/KulexiuForTeacher/Module/Mine/LiveList/Model/LiveListModel.h

@@ -12,7 +12,7 @@
 @interface LiveListModel : NSObject <NSCoding, NSCopying>
 
 @property (nonatomic, strong) NSString *courseGroupId;
-@property (nonatomic, assign) double internalBaseClassIdentifier;
+@property (nonatomic, strong) NSString *internalBaseClassIdentifier;
 @property (nonatomic, strong) NSString *createdTime;
 @property (nonatomic, strong) NSString *updatedTime;
 @property (nonatomic, strong) NSString *roomTitle;

+ 5 - 5
KulexiuForTeacher/KulexiuForTeacher/Module/Mine/LiveList/Model/LiveListModel.m

@@ -67,7 +67,7 @@ NSString *const kLiveListModelCreatedBy = @"createdBy";
     // passed into the model class doesn't break the parsing.
     if(self && [dict isKindOfClass:[NSDictionary class]]) {
             self.courseGroupId = [self objectOrNilForKey:kLiveListModelCourseGroupId fromDictionary:dict];
-            self.internalBaseClassIdentifier = [[self objectOrNilForKey:kLiveListModelId fromDictionary:dict] doubleValue];
+            self.internalBaseClassIdentifier = [self objectOrNilForKey:kLiveListModelId fromDictionary:dict];
             self.createdTime = [self objectOrNilForKey:kLiveListModelCreatedTime fromDictionary:dict];
             self.updatedTime = [self objectOrNilForKey:kLiveListModelUpdatedTime fromDictionary:dict];
             self.roomTitle = [self objectOrNilForKey:kLiveListModelRoomTitle fromDictionary:dict];
@@ -94,7 +94,7 @@ NSString *const kLiveListModelCreatedBy = @"createdBy";
 {
     NSMutableDictionary *mutableDict = [NSMutableDictionary dictionary];
     [mutableDict setValue:self.courseGroupId forKey:kLiveListModelCourseGroupId];
-    [mutableDict setValue:[NSNumber numberWithDouble:self.internalBaseClassIdentifier] forKey:kLiveListModelId];
+    [mutableDict setValue:self.internalBaseClassIdentifier forKey:kLiveListModelId];
     [mutableDict setValue:self.createdTime forKey:kLiveListModelCreatedTime];
     [mutableDict setValue:self.updatedTime forKey:kLiveListModelUpdatedTime];
     [mutableDict setValue:self.roomTitle forKey:kLiveListModelRoomTitle];
@@ -138,7 +138,7 @@ NSString *const kLiveListModelCreatedBy = @"createdBy";
     self = [super init];
 
     self.courseGroupId = [aDecoder decodeObjectForKey:kLiveListModelCourseGroupId];
-    self.internalBaseClassIdentifier = [aDecoder decodeDoubleForKey:kLiveListModelId];
+    self.internalBaseClassIdentifier = [aDecoder decodeObjectForKey:kLiveListModelId];
     self.createdTime = [aDecoder decodeObjectForKey:kLiveListModelCreatedTime];
     self.updatedTime = [aDecoder decodeObjectForKey:kLiveListModelUpdatedTime];
     self.roomTitle = [aDecoder decodeObjectForKey:kLiveListModelRoomTitle];
@@ -161,7 +161,7 @@ NSString *const kLiveListModelCreatedBy = @"createdBy";
 {
 
     [aCoder encodeObject:_courseGroupId forKey:kLiveListModelCourseGroupId];
-    [aCoder encodeDouble:_internalBaseClassIdentifier forKey:kLiveListModelId];
+    [aCoder encodeObject:_internalBaseClassIdentifier forKey:kLiveListModelId];
     [aCoder encodeObject:_createdTime forKey:kLiveListModelCreatedTime];
     [aCoder encodeObject:_updatedTime forKey:kLiveListModelUpdatedTime];
     [aCoder encodeObject:_roomTitle forKey:kLiveListModelRoomTitle];
@@ -186,7 +186,7 @@ NSString *const kLiveListModelCreatedBy = @"createdBy";
     if (copy) {
 
         copy.courseGroupId = [self.courseGroupId copyWithZone:zone];
-        copy.internalBaseClassIdentifier = self.internalBaseClassIdentifier;
+        copy.internalBaseClassIdentifier = [self.internalBaseClassIdentifier copyWithZone:zone];
         copy.createdTime = [self.createdTime copyWithZone:zone];
         copy.updatedTime = [self.updatedTime copyWithZone:zone];
         copy.roomTitle = [self.roomTitle copyWithZone:zone];

+ 1 - 1
KulexiuForTeacher/KulexiuForTeacher/Module/Mine/LiveList/Model/LiveVideoModel.h

@@ -12,7 +12,7 @@
 @interface LiveVideoModel : NSObject <NSCoding, NSCopying>
 
 @property (nonatomic, assign) double courseGroupId;
-@property (nonatomic, assign) double internalBaseClassIdentifier;
+@property (nonatomic, strong) NSString *internalBaseClassIdentifier;
 @property (nonatomic, strong) NSString *roomUid;
 @property (nonatomic, strong) NSString *endTime;
 @property (nonatomic, assign) double courseId;

+ 5 - 5
KulexiuForTeacher/KulexiuForTeacher/Module/Mine/LiveList/Model/LiveVideoModel.m

@@ -53,7 +53,7 @@ NSString *const kLiveVideoModelUrl = @"url";
     // passed into the model class doesn't break the parsing.
     if(self && [dict isKindOfClass:[NSDictionary class]]) {
             self.courseGroupId = [[self objectOrNilForKey:kLiveVideoModelCourseGroupId fromDictionary:dict] doubleValue];
-            self.internalBaseClassIdentifier = [[self objectOrNilForKey:kLiveVideoModelId fromDictionary:dict] doubleValue];
+            self.internalBaseClassIdentifier = [self objectOrNilForKey:kLiveVideoModelId fromDictionary:dict];
             self.roomUid = [self objectOrNilForKey:kLiveVideoModelRoomUid fromDictionary:dict];
             self.endTime = [self objectOrNilForKey:kLiveVideoModelEndTime fromDictionary:dict];
             self.courseId = [[self objectOrNilForKey:kLiveVideoModelCourseId fromDictionary:dict] doubleValue];
@@ -73,7 +73,7 @@ NSString *const kLiveVideoModelUrl = @"url";
 {
     NSMutableDictionary *mutableDict = [NSMutableDictionary dictionary];
     [mutableDict setValue:[NSNumber numberWithDouble:self.courseGroupId] forKey:kLiveVideoModelCourseGroupId];
-    [mutableDict setValue:[NSNumber numberWithDouble:self.internalBaseClassIdentifier] forKey:kLiveVideoModelId];
+    [mutableDict setValue:self.internalBaseClassIdentifier forKey:kLiveVideoModelId];
     [mutableDict setValue:self.roomUid forKey:kLiveVideoModelRoomUid];
     [mutableDict setValue:self.endTime forKey:kLiveVideoModelEndTime];
     [mutableDict setValue:[NSNumber numberWithDouble:self.courseId] forKey:kLiveVideoModelCourseId];
@@ -110,7 +110,7 @@ NSString *const kLiveVideoModelUrl = @"url";
     self = [super init];
 
     self.courseGroupId = [aDecoder decodeDoubleForKey:kLiveVideoModelCourseGroupId];
-    self.internalBaseClassIdentifier = [aDecoder decodeDoubleForKey:kLiveVideoModelId];
+    self.internalBaseClassIdentifier = [aDecoder decodeObjectForKey:kLiveVideoModelId];
     self.roomUid = [aDecoder decodeObjectForKey:kLiveVideoModelRoomUid];
     self.endTime = [aDecoder decodeObjectForKey:kLiveVideoModelEndTime];
     self.courseId = [aDecoder decodeDoubleForKey:kLiveVideoModelCourseId];
@@ -126,7 +126,7 @@ NSString *const kLiveVideoModelUrl = @"url";
 {
 
     [aCoder encodeDouble:_courseGroupId forKey:kLiveVideoModelCourseGroupId];
-    [aCoder encodeDouble:_internalBaseClassIdentifier forKey:kLiveVideoModelId];
+    [aCoder encodeObject:_internalBaseClassIdentifier forKey:kLiveVideoModelId];
     [aCoder encodeObject:_roomUid forKey:kLiveVideoModelRoomUid];
     [aCoder encodeObject:_endTime forKey:kLiveVideoModelEndTime];
     [aCoder encodeDouble:_courseId forKey:kLiveVideoModelCourseId];
@@ -144,7 +144,7 @@ NSString *const kLiveVideoModelUrl = @"url";
     if (copy) {
 
         copy.courseGroupId = self.courseGroupId;
-        copy.internalBaseClassIdentifier = self.internalBaseClassIdentifier;
+        copy.internalBaseClassIdentifier = [self.internalBaseClassIdentifier copyWithZone:zone];
         copy.roomUid = [self.roomUid copyWithZone:zone];
         copy.endTime = [self.endTime copyWithZone:zone];
         copy.courseId = self.courseId;

+ 1 - 1
KulexiuForTeacher/KulexiuForTeacher/Module/Mine/MinePage/View/MinePageCourseView.m

@@ -387,7 +387,7 @@
     else if (self.selectIndex == 4) { // 曲谱详情
         MusicMessageModel *model = self.dataArray[indexPath.row];
         KSBaseWKWebViewController *ctrl = [[KSBaseWKWebViewController alloc] init];
-        ctrl.url = [NSString stringWithFormat:@"%@%@%.0f", WEBHOST, @"/#/music-detail?id=",model.internalBaseClassIdentifier];
+        ctrl.url = [NSString stringWithFormat:@"%@%@%@", WEBHOST, @"/#/music-detail?id=",model.internalBaseClassIdentifier];
         [self.naviController pushViewController:ctrl animated:YES];
     }
 }

+ 1 - 1
KulexiuForTeacher/KulexiuForTeacher/Module/Mine/MinePage/View/MinePageVideoView.m

@@ -183,7 +183,7 @@
 - (void)collectionView:(UICollectionView *)collectionView didSelectItemAtIndexPath:(NSIndexPath *)indexPath {
     VideoCourseModel *model = [self.dataArray objectAtIndex:indexPath.row];
     KSBaseWKWebViewController *ctrl = [[KSBaseWKWebViewController alloc] init];
-    ctrl.url = [NSString stringWithFormat:@"%@%@%.0f", WEBHOST, @"/#/videoDetail?groupId=",model.internalBaseClassIdentifier];
+    ctrl.url = [NSString stringWithFormat:@"%@%@%@", WEBHOST, @"/#/videoDetail?groupId=",model.internalBaseClassIdentifier];
     [self.naviController pushViewController:ctrl animated:YES];
 }
 

+ 1 - 1
KulexiuForTeacher/KulexiuForTeacher/Module/Mine/VideoCourse/Model/VideoCourseModel.h

@@ -11,7 +11,7 @@
 
 @interface VideoCourseModel : NSObject <NSCoding, NSCopying>
 
-@property (nonatomic, assign) double internalBaseClassIdentifier;
+@property (nonatomic, strong) NSString *internalBaseClassIdentifier;
 @property (nonatomic, strong) NSString *lessonCoverUrl;
 @property (nonatomic, assign) double lessonCount;
 @property (nonatomic, strong) NSString *lessonDesc;

+ 5 - 5
KulexiuForTeacher/KulexiuForTeacher/Module/Mine/VideoCourse/Model/VideoCourseModel.m

@@ -70,7 +70,7 @@ NSString *const kVideoCourseModelPayType = @"payType";
     // This check serves to make sure that a non-NSDictionary object
     // passed into the model class doesn't break the parsing.
     if(self && [dict isKindOfClass:[NSDictionary class]]) {
-            self.internalBaseClassIdentifier = [[self objectOrNilForKey:kVideoCourseModelId fromDictionary:dict] doubleValue];
+            self.internalBaseClassIdentifier = [self objectOrNilForKey:kVideoCourseModelId fromDictionary:dict];
             self.lessonCoverUrl = [self objectOrNilForKey:kVideoCourseModelLessonCoverUrl fromDictionary:dict];
             self.lessonCount = [[self objectOrNilForKey:kVideoCourseModelLessonCount fromDictionary:dict] doubleValue];
             self.lessonDesc = [self objectOrNilForKey:kVideoCourseModelLessonDesc fromDictionary:dict];
@@ -99,7 +99,7 @@ NSString *const kVideoCourseModelPayType = @"payType";
 - (NSDictionary *)dictionaryRepresentation
 {
     NSMutableDictionary *mutableDict = [NSMutableDictionary dictionary];
-    [mutableDict setValue:[NSNumber numberWithDouble:self.internalBaseClassIdentifier] forKey:kVideoCourseModelId];
+    [mutableDict setValue:self.internalBaseClassIdentifier forKey:kVideoCourseModelId];
     [mutableDict setValue:self.lessonCoverUrl forKey:kVideoCourseModelLessonCoverUrl];
     [mutableDict setValue:[NSNumber numberWithDouble:self.lessonCount] forKey:kVideoCourseModelLessonCount];
     [mutableDict setValue:self.lessonDesc forKey:kVideoCourseModelLessonDesc];
@@ -145,7 +145,7 @@ NSString *const kVideoCourseModelPayType = @"payType";
 {
     self = [super init];
 
-    self.internalBaseClassIdentifier = [aDecoder decodeDoubleForKey:kVideoCourseModelId];
+    self.internalBaseClassIdentifier = [aDecoder decodeObjectForKey:kVideoCourseModelId];
     self.lessonCoverUrl = [aDecoder decodeObjectForKey:kVideoCourseModelLessonCoverUrl];
     self.lessonCount = [aDecoder decodeDoubleForKey:kVideoCourseModelLessonCount];
     self.lessonDesc = [aDecoder decodeObjectForKey:kVideoCourseModelLessonDesc];
@@ -172,7 +172,7 @@ NSString *const kVideoCourseModelPayType = @"payType";
 - (void)encodeWithCoder:(NSCoder *)aCoder
 {
 
-    [aCoder encodeDouble:_internalBaseClassIdentifier forKey:kVideoCourseModelId];
+    [aCoder encodeObject:_internalBaseClassIdentifier forKey:kVideoCourseModelId];
     [aCoder encodeObject:_lessonCoverUrl forKey:kVideoCourseModelLessonCoverUrl];
     [aCoder encodeDouble:_lessonCount forKey:kVideoCourseModelLessonCount];
     [aCoder encodeObject:_lessonDesc forKey:kVideoCourseModelLessonDesc];
@@ -200,7 +200,7 @@ NSString *const kVideoCourseModelPayType = @"payType";
     
     if (copy) {
 
-        copy.internalBaseClassIdentifier = self.internalBaseClassIdentifier;
+        copy.internalBaseClassIdentifier = [self.internalBaseClassIdentifier copyWithZone:zone];
         copy.lessonCoverUrl = [self.lessonCoverUrl copyWithZone:zone];
         copy.lessonCount = self.lessonCount;
         copy.lessonDesc = [self.lessonDesc copyWithZone:zone];

+ 2 - 2
KulexiuForTeacher/KulexiuForTeacher/Module/Mine/VideoCourse/View/VideoListBodyView.m

@@ -224,10 +224,10 @@
     VideoCourseModel *model = [self.dataArray objectAtIndex:indexPath.row];
     NSString *url = @"";
     if (self.selectIndex == 2 || self.selectIndex == 3) {
-        url = [NSString stringWithFormat:@"%@%@%.0f", WEBHOST, @"/#/videoCreate?groupId=",model.internalBaseClassIdentifier];
+        url = [NSString stringWithFormat:@"%@%@%@", WEBHOST, @"/#/videoCreate?groupId=",model.internalBaseClassIdentifier];
     }
     else {
-        url = [NSString stringWithFormat:@"%@%@%.0f", WEBHOST, @"/#/videoDetail?groupId=",model.internalBaseClassIdentifier];
+        url = [NSString stringWithFormat:@"%@%@%@", WEBHOST, @"/#/videoDetail?groupId=",model.internalBaseClassIdentifier];
     }
     KSBaseWKWebViewController *ctrl = [[KSBaseWKWebViewController alloc] init];
     ctrl.url = url;