Base solution for your next web application

Activities of "thechrismarsh"

  • What is your product version? v9.1.0
  • What is your product type (Angular or MVC)? Angular
  • What is product framework type (.net framework or .net core)? .Net Core

Problem

I just downloaded a fresh implementation and got it running using all the defaults, EXCEPT I changed the MultiTenancy to false, putting the application into single-tenant mode.

However, when I run the site (localhost:4200) I cannot login to the HOST, I can only login to the DEFAULT TENANT. The login page does not give me any options for changing (or blanking out) the tenant so that the TenantId is null on the authorization request.

How do I login to the HOST tenant in single-tenant mode?

I Already Tried

Logging in using emails instead of usernames (since they both are admin). Trying to login with the email [email protected] which is the default email for the HOST admin failed. Logging in with the email [email protected] which is the default for the DEFAULT TENANT admin worked just fine.

I used the RAD tool to create a new Entity "RealEstate".

The RAD tool does not seem to be creating the <span style="color:#000000">RealEstateServiceProxy</span> class and associated methods like getAll, getRealEstateForEdit, createOrEdit, delete. I assume these should be created in the <span style="color:#000000">service-proxies.ts</span> file.

The RAD tool does update <span style="color:#000000">service-proxy.module.ts</span> and tried to import ApiServiceProxies.RealEstateServiceProxy — but it fails.

FYI ... There is a pull request at the datamaps repo that fixes this, but it had not been merged. The code hasn't had a commit to master in over 5 months. It looks stale.

I tried to accept it back in October 2017 but don't have write access to merge the pull request ... <a class="postlink" href="https://github.com/markmarkoh/datamaps/pull/378">https://github.com/markmarkoh/datamaps/pull/378</a>

Since this solution uses datamaps, there is an issue building or renaming these files on windows.

Windows does not allow certain filenames ([https://msdn.microsoft.com/en-us/library/windows/desktop/aa365247(v=vs.85).aspx])) ... which includes files named <span style="color:#0000FF">NUL.*</span>

This issue has been raised ([https://github.com/markmarkoh/datamaps/issues/337])), but not resolved.

Can the ASP.NET Zero team create a fix for this issue until it is resolved in the datamaps repo?

Make sure you inject the location provider to the config ...

appModule.config([
    '$stateProvider', '$urlRouterProvider', '$locationProvider',
    function ($stateProvider, $urlRouterProvider, $locationProvider) {

        $locationProvider.html5Mode(true);

Also make sure you add this to the head of the layout.cshtml view ...

<head>
	<base href="/">

following these two steps alone worked for me ... <ins><span style="color:#0040FF">/Application#/host/tenants</span></ins> turns into <ins><span style="color:#0040FF">/host/tenants</span></ins>

Showing 1 to 5 of 5 entries