Base solution for your next web application

Activities of "omkarchoudhari"

I need to display data from the database on the Home page . I created the service and could successfully call the data from the Browser Console after logging in to the application. I created the angular controller in the Views/Home/Index.js file and added data binding code to Index.cstml. However i am unable to bind the data to angular controls. My data should be displayed in the host and not related to any tenant.

Index.js:

(function () {

appModule.controller('Views.Home.Index', [
    '$scope', 'abp.services.app.plan',
    function ($scope, planService) {
        var vm = this;
       
        vm.plans = [];

        planService.GetPlans({}).success(function (result) {
            vm.plans = result.items;
        });
    }
]);

})();

Index.cshtml:

<div ng-controller="Views.Home.Index as vm"> <h3>All Plans</h3>

    &lt;div class=&quot;list-group&quot;&gt;
        &lt;a href=&quot;javascript:;&quot; class=&quot;list-group-item&quot; ng-repeat=&quot;plan in vm.plans&quot;&gt;
            &lt;h4 class=&quot;list-group-item-heading&quot;&gt;
                {{plan.PlanName}} {{plan.RatePerUser}}
              
            &lt;/h4&gt;
            &lt;p class=&quot;list-group-item-text&quot;&gt;
                {{plan.Features}}
            &lt;/p&gt;
        &lt;/a&gt;
    &lt;/div&gt;
&lt;/div&gt;

================================

I have carried out the steps correctly as per the PhoneBook application. My Record entity has exactly same fields as Person. As per other similar thread on this blog , i have cleared the history, Disabled the cache etc. , bit still the Records link does not show up in the admin role settings page. Please review and help.

AppAuthorizationProvider class: pages.CreateChildPermission(AppPermissions.Pages_Tenant_Records, L("Records"), multiTenancySides: MultiTenancySides.Tenant);

AppPermissions.cs : public const string Pages_Tenant_Records = "Pages.Tenant.Records";

ABPAUTHORIZE ATTRIBUTE :

[AbpAuthorize(AppPermissions.Pages_Tenant_Records)] public class RecordAppService :C2CAppServiceBase, IRecordAppService {}

AppNavigationProvider .cs :

.AddItem(new MenuItemDefinition(
                PageNames.App.Tenant.Records,
                L("Records"),
                url: "tenant.records",
                icon: "icon-grid"
                requiredPermissionName: AppPermissions.Pages_Tenant_Records
                )

App.js :

if (abp.auth.hasPermission('Pages.Tenant.Records')) { $stateProvider.state('tenant.records', { url: '/records', templateUrl: '~/App/tenant/views/Records/index.cshtml', menu: 'Records' }); }

I seem to be doing everything ok, and there is no error , but the permission does not show up	under Tenants.

I need it resolved ASAP.

I have added a delete icon on the grid on Index.cshtml page. But i am not able to open the Delete modal on clicking the icon. help ? Here is my Delete controller :

(function () { appModule.controller('tenant.views.records.deleteRecord', [ '$scope', '$uibModalInstance', 'abp.services.app.record', function ($scope, $uibModalInstance, recordService) { //----------delete record =====================
vm.deleteRecord = function (record) { abp.message.confirm( app.localize('AreYouSureToDeleteRecord', record.name), function (isConfirmed) { if (isConfirmed) { recordService.deleteRecord({ id: record.id }).success(function () { abp.notify.success(app.localize('SuccessfullyDeleted')); getRecords(); }); } } ); }; } ]); })();

This is my ColumnDef attribute :

  {
                 name: app.localize('Delete'),
                 field: '',
                 cellFilter: 'momentFormat: \'L\'',
                 cellTemplate: '&lt;button &#39;+ 
                 &#39;ng-click=&quot;vm.deleteRecord(record)&quot; &#39;+
                 &#39;title = &quot;@L(&quot;Delete&quot;)&quot;&#39;+ 
                 &#39;class=&quot;btn btn-circle btn-icon-only red delete-record&quot;&#39;+ 
                &#39; href =&quot;javascript:;&quot;&gt;&lt;i class=&quot;icon-trash&quot;&gt;&lt;/i&gt;&lt;/button&gt;'
             }

My RecordAppService :

public async Task DeleteRecord(IdInput<Guid> input) {

        await _recordRepository.DeleteAsync(input.Id);//Check and confirm this
    }

Nothing happens when i click the delete icon and there is no eror.

[attachment=1:2g9v0hmd]delete.png[/attachment:2g9v0hmd]

Grid Shows up as :

yes !! Got it. Thank you so much.

No. I want this link to appear on tenant side. It should appear the way it does for PhoneBook application. i.e

The link you have provided for reference is not working. Getting page not found error.

i want to add a checkbox column to the ui-grid. This grid is bound to data , and i would like to use the check box to 1. Select all columns or 2. select particular columns or 3. Deselect all columns. I also want to be able to select rows and collect these selected rows for further processing.

Please suggest the best way to go ahead with the approach.

I want to be able to imports records from csv file into grid. I have tried using ui-grid-importer , but i cannot inject it into my controllers scope. it gives me injector error.

How can i use ui-grid importer, or any other approach for the grid ?

Many of our customers are likely to use IE 8, so we need to support that browser.. If IE8 is not supported , then what steps can we take in code to achieve compatibility ?

Are there any workarounds or tools that would help avoid rework for supporting IE8 ?

UI grid Data displays square characters for default data in IE 11. Data displays well when column is expanded. Also shows up on modal pop ups. Please see image attached. This displays well in chrome and firefox.

How do i enable the application to run with https ? I have already added the SSL Certificate to my web application on Azure ? What steps do i take to redirect to any page using https ?

Showing 1 to 10 of 146 entries