//
//  ApplicationDetailsHttpGetCmd.m
//  MobilePortal
//
//  Created by caiyang on 2021/12/22.
//  Copyright © 2021 yin chen. All rights reserved.
//

#import "ApplicationDetailsHttpGetCmd.h"
#import "ApplicationDetailsHttpResult.h"

static NSString *kActionUrl1 = @"/newapp/portal/getMyMassage/";

@implementation ApplicationDetailsHttpGetCmd
-(instancetype)initWithVersion:(NSString *)version{
    if ([version isEqualToString:PHttpVersion_v1]) {
        return [[ApplicationDetailsHttpGetCmd alloc]initWithAuthorizationState:AuthorizationNull];
    }else{
        NSAssert(NO, @"Invalid version");
    }
    return nil;
}

- (instancetype)initWithAuthorizationState:(AuthorizationState)state{
    self = [super initWithAuthorizationState:state];
    if (self != nil) {
        self.result = [[ApplicationDetailsHttpResult alloc]init];
    }
    return self;
}

- (NSString *)getActionUrl{
    return [NSString stringWithFormat:@"%@%@",kActionUrl1,self.requestInfo[kHttpApplicationDetailsHttpGetCmd_applicationName]];
//    return kActionUrl1;
}
@end
NSString *const kHttpApplicationDetailsHttpGetCmd_applicationName = @"applicationName";
NSString *const kHttpApplicationDetailsHttpGetCmd_id = @"id";
