RQHomeSubPageListItemViewModel.m 1.1 KB

12345678910111213141516171819202122232425262728293031323334
  1. //
  2. // RQHomeSubPageListItemViewModel.m
  3. // SDJK
  4. //
  5. // Created by 张嵘 on 2021/8/4.
  6. //
  7. #import "RQHomeSubPageListItemViewModel.h"
  8. @interface RQHomeSubPageListItemViewModel ()
  9. /// closeCommand
  10. @property (nonatomic, readwrite, strong) RACCommand *gotoLocalTopicsCommand;
  11. @end
  12. @implementation RQHomeSubPageListItemViewModel
  13. - (instancetype)init {
  14. self = [super init];
  15. if (self) {
  16. [self initialize];
  17. }
  18. return self;
  19. }
  20. - (void)initialize {
  21. self.gotoLocalTopicsCommand = [[RACCommand alloc] initWithSignalBlock:^RACSignal *(id input) {
  22. RQHomeSubPageLocalTopicListViewModel *homeSubPageLocalTopicListViewModel = [[RQHomeSubPageLocalTopicListViewModel alloc] initWithServices:RQSharedAppDelegate.services params:@{
  23. RQHomePageCarTypeKey : @(self.homePageCarType),
  24. RQHomePageSubjectTypeKey : @(self.homePageSubjectType),
  25. RQHomeSubPageTypeKey : @(RQHomeSubPageType_LocalTopics)}];
  26. [RQSharedAppDelegate.services pushViewModel:homeSubPageLocalTopicListViewModel animated:YES];
  27. return [RACSignal empty];
  28. }];
  29. }
  30. @end