Skip to content

Resolving types from sap.cds.common #52

@ThymeScript

Description

@ThymeScript

Hello :)

Thank you for providing this feature, it helps us a ton!

In our development we've noticed that the type Currency from @sap.cds.common is missing the import upon typescript generation. For better understanding I'll provide this code example:

using {
  Currency
} from '@sap/cds/common';
entity Books {
title: String;
price: Currency
}

this generates following typescript

export interface IBooks {
  title: string;
  price: Currencies;
  price_code?: string;
}

This is misses import { ICurrencies } from "./sap.common";. We've bypassed this for now by using Association to one Currencies instead of Currency. Might be an interesting feature to add in the future :)

Kind Regards,
Tanja

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions