public Result <int> CalculateOdds(Guid algorithmId) { return(new ServiceDelegator(new ServiceContextOfAlgorithm()).HandleSimpleTransactionEvent(nameof(MSAlgorithm), (session) => { TMSAlgorithm algorithm = new TMSAlgorithm(); algorithm.AlgorithmId = algorithmId; //TODO获取到有效的algorithm return algorithm.CalculateOdds(session); })); }
public Result <int> CalculateOdds(DbSession session, TMSAlgorithm algorithm) { return(algorithm.CalculateOdds(session)); }