createOne method

Future<QuickbooksVendor> createOne({
  1. required String accessToken,
  2. required String companyId,
  3. required QuickbooksVendor data,
})

Creates a QuickbooksVendor with the given accessToken and companyId

Implementation

Future<QuickbooksVendor> createOne({
  required String accessToken,
  required String companyId,
  required QuickbooksVendor data,
}) async {
  var result = await post(
    accessToken: accessToken,
    companyId: companyId,
    data: data.toMap(withId: false),
    location: 'Vendor',
  );

  var newData = QuickbooksVendor.fromMap(result);
  return newData;
}