Logging In

Now you can log into your server with the newly added user, SupplierUser (password is password):

If you execute the Books by Title view, you will see that no records are returned - this is because there are no Books where the Supplier organization matches SupplierUser's parent organization.

Now let's add a new book which has this supplier's organization indicated as the supplier. Open data/Books.xml from within the Bookstore_dataset project then add the following XML to the file after the existing <Book> element before </ModelList>.

<Book xmlns="http://www.mybooks.com/Bookstore">
<ValueChainId>9123</ValueChainId>
<Title>SDK : Advanced Concepts</Title>
<ISBN>9788175257670</ISBN>
<Author>Greg Merrill</Author>
<Publisher>One Network Publishing Inc.</Publisher>
<PublishedDate>2021-01-25T00:00:00-00:00</PublishedDate>
<PublisherAddress>
<vc:Country>US</vc:Country>
<vc:Component Type="STREET1">4055 Valley View Lane</vc:Component>
<vc:Component Type="STREET2">Suite 400</vc:Component>
<vc:Component Type="CITY">Dallas</vc:Component>
<vc:Component Type="STATE">TX</vc:Component>
<vc:Component Type="ZIP">75244</vc:Component>
</PublisherAddress>
<PublisherWebsite>&lt;a href=&quot;http://www.onenetwork.com&quot;&gt;www.onenetwork.com&lt;/a&gt;</PublisherWebsite>
<QuantitySold>5000</QuantitySold>
<PriceAmount>29.99</PriceAmount>
<PriceUOM>USD</PriceUOM>
<PromotionalPeriodStartDate>2006-02-15T00:00:00-00:00</PromotionalPeriodStartDate>
<PromotionalPeriodEndDate>2006-03-15T00:00:00-00:00</PromotionalPeriodEndDate>
<Rating>9.7</Rating>
<ReturnPolicy>P30D</ReturnPolicy>
<SalesRepName>BookstoreUser</SalesRepName>
<SalesRepEnterpriseName>SampleEnterprise</SalesRepEnterpriseName>
<SupplierName>SampleBookSupply</SupplierName>
<SupplierEnterpriseName>SampleBookSupply</SupplierEnterpriseName>
<Genre>Non-Fiction</Genre>
</Book>

Note the SupplierName and SupplierEnterpriseName in the XML above - this identifies the Supplier org (whose key is name + parent enterprise name, thus SupplierName + SupplierEnterpriseName).

After submitting this Book via load-data, you should be able to access this using the Books by Title view:

Also, we should see the same Book (and only that Book) from the All Books report, thanks to the customModelPermissionsWhere macro we applied to that report.