execute method

Future execute({
  1. required int recordId,
  2. required String method,
  3. dynamic args = const [],
  4. Map<String, dynamic> kwargs = const {},
  5. bool awaited = false,
})

Executes method on recordId of current modelName. It places call to queue that is processed either immediately if network is online or when network state will be changed to online.

Implementation

Future<dynamic> execute(
    {required int recordId,
    required String method,
    dynamic args = const [],
    Map<String, dynamic> kwargs = const {},
    bool awaited = false}) async {
  final rpcCall = buildRpcCall(method, recordId, args, kwargs);
  await env.queueCall(rpcCall, awaited: awaited);
}