How to use the xrm-mock.LookupValueMock function in xrm-mock

To help you get started, we’ve selected a few xrm-mock examples, based on popular ways it is used in public projects.

github camelCaseDave / xrm-mock-generator / src / xrm-mock-generator / attribute.js View on Github external
Attribute.prototype.createLookup = function (name, lookup) {
        var attribute = createAttribute(name || "", [new XrmMock.LookupValueMock(
            lookup.id,
            lookup.entityType,
            lookup.name)]);
        var lookupAttribute = new XrmMock.LookupAttributeMock(attribute, false);

        addAttribute(lookupAttribute);
        return lookupAttribute
    };