export function getDataRowId(data) {
  return data?.id || data?.line_id;
}

export function getRowId(row) {
  return getDataRowId(row.original.data);
}

export function isVspRow(row) {
  if (row?.original?.data?.id) {
    return true;
  }
  return false;
}
export function isVspNewRow(rowData) {
  if (!rowData) return false;
  const newRow = rowData[3];
  return !!newRow.id;
}

export function getParentId(data){
  return data.project_id || data.expense_item_id || null;
}
