Base solution for your next web application
Starts in:
01 DAYS
01 HRS
01 MIN
01 SEC

Activities of "BobIngham"

Question

Zoho has a really neat "Run in Postman" button in the their REST API documentation: It would be a great feature to add to Zero and maybe at little cost.

Question

I am opening a discussion on this forum about documentation.
I believe both the Zero framework and support to be exceptional and I thank the guys at Volosoft. I have read both this forum and subscribed to the github repository for many months and I have said, many times, there is nowhere to share our code. I will gladly start any blog with an entry about how to use Mongo Atlas for audit log and entity change history, my front end is angular. I would also like to know about anyone who would want to use the new Ionic 4 framework as an alternative to the Xamarin project. If anyone is interested in dynamic json forms I would like to share my experiences. And I also promised to share my code to use Azure blob storage for images, audio and video which is no problem, though my code is not the best. This is not a job offer, this is to the community I know exists in both the forum and the github repository.

We want a blog... We want to share code... All together now....

It would be nice to allow tenants to change the background image and splash message of the login page through settings -> appearance functionality. We would need a single image of a given size and two lines of text (the first of which could default to the tenant's invoice name and the second of which could default to tenantName. That way every tenant appears to have their own system.

dotnet-core, angular;5.4.1 I have a tab sheet with several tabs defined, for example, as below:

<tab *ngIf="true && (isGranted('Pages.NcEntity.NcWarnings') || isGranted('Pages.NcEntity.NcWarning.Read'))" heading="{{l('Warnings')}}" customClass="m-tabs__item">
    <app-warnings _="id"></app-warnings>
</tab>

I have several of these tabs and many are very heavy on data retrieval. How do I activate the embedded component on click? I have tried the following:

<tab *ngIf="true && (isGranted('Pages.NcEntity.NcWarnings') || isGranted('Pages.NcEntity.NcWarning.Read'))" heading="{{l('Warnings')}}" customClass="m-tabs__item">
    <app-warnings *ngIf="warningsActivated" (click)="activateWarnings()" [id]="id"></app-warnings>
</tab>

But the component is not activated. I have also tried wrapping the component declaration in a [i:3bipxxbr]div_ with the same method to activate but it still does not show. Anyone?

A general question, guys. Is anyone recently having problems with yarn? I have had to resort to npm install --save due to an error reading "there appears to be problems with your network connection" when running yarn, even with a timeout setting of 60000. I have googled it and it seems many other people seem to be having the same problem. The general jabberwockery solution suggested in this link [https://github.com/yarnpkg/yarn/issues/5259#issuecomment-379769451]) didn't work for me and my yarn-error.log reads

Error: https://registry.yarnpkg.com/rxjs/-/rxjs-6.2.2.tgz: ESOCKETTIMEDOUT
      at ClientRequest.<anonymous> (C:\Program Files (x86)\Yarn\lib\cli.js:135306:19)
      at Object.onceWrapper (events.js:313:30)
      at emitNone (events.js:106:13)
      at ClientRequest.emit (events.js:208:7)
      at TLSSocket.emitTimeout (_http_client.js:708:34)
      at Object.onceWrapper (events.js:313:30)
      at emitNone (events.js:106:13)
      at TLSSocket.emit (events.js:208:7)
      at TLSSocket.Socket._onTimeout (net.js:407:8)
      at ontimeout (timers.js:475:11)

This is not a Zero problem but I was wondering if anyone was experiencing similar problems and had found any work arounds?

aspnet-core, angular; 5.4.1 I have used Kendo grids for many years in my MVC projects and my users love the functionality of the grids for data analysis. To implement similar functionality using the Zero framework results in far too much code for filtering, grouping (I'm not even sure it's possible), export to Excel, PDF etc. Kendo grids use a DataSourceRequest object to carry out the vase majority of this functionality and to this end I have created a new controller in the [projectname].Web.Host project to implement this functionality:

using Abp.Auditing;
using Kendo.Mvc.Extensions;
using Kendo.Mvc.UI;
using Microsoft.AspNetCore.Mvc;
using Nuagecare.NcEntity;
using Nuagecare.Web.Controllers;
using System.Threading.Tasks;

namespace Nuagecare.Web.Host.Controllers
{
    [Produces("application/json")]
    [ApiExplorerSettings(IgnoreApi = true)]
    [DisableAuditing]
    public class KendoController :  NuagecareControllerBase
    {
        private readonly INcEntityAppService _ncEntityAppService;

        public KendoController(INcEntityAppService ncEntityAppService)
        {
            _ncEntityAppService = ncEntityAppService;
        }

        public async Task<ActionResult> GetEntities([DataSourceRequest]DataSourceRequest request)
        {
            var model = await _ncEntityAppService.GetAllForKendoGrid();
            return Json(model.ToDataSourceResult(request));
        }
    }
}

Next I implement a new service in my angular project:

import { Injectable, Inject, Optional, InjectionToken } from '@angular/core';
import { HttpClient } from '@angular/common/http';
import { toDataSourceRequestString, translateDataSourceResultGroups, translateAggregateResults, DataResult, DataSourceRequestState } from '@progress/kendo-data-query';
import { GridDataResult } from '@progress/kendo-angular-grid';

import { Observable } from 'rxjs';
import 'rxjs/add/operator/map';

export const API_BASE_URL = new InjectionToken<string>('API_BASE_URL');

@Injectable({
  providedIn: 'root'
})
export class KendoGridService {
  private http: HttpClient;
  private baseUrl: string;

  constructor(@Inject(HttpClient) http: HttpClient, @Optional() @Inject(API_BASE_URL) baseUrl?: string) {
    this.http = http;
    this.baseUrl = baseUrl ? baseUrl : '';
  }

  getEntities(state: DataSourceRequestState): Observable<DataResult> {
    let url_ = this.baseUrl + 'kendo/getentities';
    url_ = url_.replace(/[?&]$/, '');

    const queryStr = `${toDataSourceRequestString(state)}`; // Serialize the state
    const hasGroups = state.group && state.group.length;

    return this.http
      .get(`${url_}?${queryStr}`) // Send the state to the server
      .map(({ data, total/*, aggregateResults*/ }: GridDataResult) => // Process the response
        (<GridDataResult>{
          // If there are groups, convert them to a compatible format
          data: hasGroups ? translateDataSourceResultGroups(data) : data,
          total: total,
          // Convert the aggregates if such exist
          //aggregateResult: translateAggregateResults(aggregateResults)
        })
      );
  }
}

All is working well except the injection of the API_BASE_URL (copied from the dynamically created service-proxies.ts) results in an empty value.

How do I properly inject API_BASE_URL to a new service?

aspnet-core, angular - 5.4.1 I have implemented subdomain control which is working well (subdomain.projectname.com...) but when I go to register a new tenant through the public facing register-new-tenant page (the visitor selects the "free trial" on the editions page) recaptcha is informing me:

ERROR for site owner:
Invalid domain for site key

What do I have to do to get recaptcha working again?

Question

aspnet-core, angular 5.4.1 I am trying to use Metronic's portlet tools. I believe that to get the expand/collapse close etc functionality to work I need to include the portlet.js library. How do i go about including this for an individual page in Zero? If i can't do it for an individual page how do i import across the board?

aspnet-core, angular, 5.4.1 In the angular project OrganizationTreeComponent contains a JQuery tree component. Is this a plugin and, if so, is there any documentation beyond the 300 lines of code in the typescript file?

aspnet-core, angular: 5.4.1 Can anyone tell me what the purpose of the following lines are? [https://github.com/aspnetzero/aspnet-zero-core/blob/dev/angular/src/app/admin/audit-logs/audit-log-detail-modal.component.html#L55-L61]) In the same modal can anyone tell me why we have (ngSubmit)="save()" on the form declaration at line 5 when there is no corresponding method in the component and the fact that this is a display only modal? The value AuditLogImpersonatedOperationInfo is not populated anywhere, can anyone tell me what's meant to be there?

Showing 91 to 100 of 142 entries