Skip to content
Discussion options

You must be logged in to vote

The CriteriaBase type is deprecated and should no longer be necessary now that the data portal accepts multiple parameters. So you would normally have something like this:

  public class Example
  {
    public async Task<string> RunMyCommand()
    {
      var cmd = await DataPortal.CreateAsync<MyCommand>(42, "12345");
      cmd = await DataPortal.ExecuteAsync(cmd);
      return cmd.Result;
    }
  }

  [Serializable]
  public class MyCommand : CommandBase<MyCommand>
  {
    public static readonly PropertyInfo<int> IdProperty = RegisterProperty<int>(nameof(Id));
    public int Id
    {
      get => ReadProperty(IdProperty);
      private set => LoadProperty(IdProperty, value);
    }

    p…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@firoz186
Comment options

Answer selected by rockfordlhotka
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants