public List <HistoricalTradeViewModel> AssignableExerciseDetail(string QryPos, string QryNum)
        {
            AssignableExerciseDetailArguments arguments = new AssignableExerciseDetailArguments
            {
                QueryPosition       = QryPos,
                QueryNumer          = QryNum,
                CustomerCode        = FCIdentity.CustomerCode,
                CustomerAccountCode = FCIdentity.CustomerAccountCode,
            };
            EntityResponse <List <AssignableExerciseDetail> > result = _orderManager.AssignableExerciseDetail(arguments);

            return(Mapper.Map <List <HistoricalTradeViewModel> >(result.Entity));
        }
        public EntityResponse <List <AssignableExerciseDetail> > AssignableExerciseDetail(AssignableExerciseDetailArguments assignableExerciseDetailArguments)
        {
            List <SZKingdomArgument> arguments = new List <SZKingdomArgument>();

            arguments.Add(SZKingdomArgument.CustomerCode(assignableExerciseDetailArguments.CustomerCode));
            arguments.Add(SZKingdomArgument.CustomerAccountCode(assignableExerciseDetailArguments.CustomerAccountCode));
            arguments.Add(SZKingdomArgument.Currency(assignableExerciseDetailArguments.Currency));
            arguments.Add(SZKingdomArgument.StockBoard(assignableExerciseDetailArguments.StockBoard));

            arguments.Add(SZKingdomArgument.TradeAccount(assignableExerciseDetailArguments.TradeAccount));
            arguments.Add(SZKingdomArgument.OptionNumber(assignableExerciseDetailArguments.OptionNumber));
            arguments.Add(SZKingdomArgument.OptionUnderlyingCode(assignableExerciseDetailArguments.OptionUnderlyingCode));
            arguments.Add(SZKingdomArgument.OptionType(assignableExerciseDetailArguments.OptionType));
            arguments.Add(SZKingdomArgument.OptionCoveredFlag(assignableExerciseDetailArguments.OptionCoveredFlag));
            arguments.Add(SZKingdomArgument.ExerciseSide(assignableExerciseDetailArguments.ExerciseSide));
            arguments.Add(SZKingdomArgument.QueryPosition(assignableExerciseDetailArguments.QueryPosition));
            arguments.Add(SZKingdomArgument.QueryNumer(assignableExerciseDetailArguments.QueryNumer));



            //if (orderArguments.SecurityLevel != SecurityLevel.NoSecurity)
            //{
            //    if (!string.IsNullOrWhiteSpace(orderArguments.SecurityInfo))
            //    {
            //        arguments.Add(SZKingdomArgument.SecurityInfo(orderArguments.SecurityInfo));
            //    }
            //    else if (!string.IsNullOrWhiteSpace(orderArguments.Password))
            //    {
            //        orderArguments.SecurityInfo = _marketDataLibrary.EncryptPassword(orderArguments.CustomerAccountCode, orderArguments.Password);
            //    }
            //    else
            //    {
            //        EntityResponse<OptionOrderInformation> entityResponse = EntityResponse<OptionOrderInformation>
            //            .Error(ErrorCode.SZKingdomLibraryError, "No security info");
            //        return entityResponse;
            //    }
            //}

            EntityResponse <List <AssignableExerciseDetail> > result =
                _marketDataLibrary.ExecuteCommandList <AssignableExerciseDetail>(SZKingdomRequest.AssignableExerciseDetail, arguments);

            return(result);
        }