How to access the data for Custom created table in merchant portal gui module.

aashutosh.namdeo
aashutosh.namdeo Posts: 33 🧑🏻‍🚀 - Cadet

I have created a custom database table in TestArticle Module → PyzTestArticle now i want to fetch data for that table in Merchant portal Gui module i have setup all the things using facade dependency but always i get 0 data row from that table not able to acess the data for that table .

what ACL entity or ACL metrchant portal configuration i have to do for using that.

Tagged:

Answers

  • Hidran Arias
    Hidran Arias Senior Technical Trainer Sprykee Posts: 81 🏛 - Council (mod)

    We have a dedicated course to the Merchant portal: https://sprykee-safari.spryker.com/learn/course/667/play/4119/spryker-marketplace-frontend-development

    The backend part is the same as for any backoffice module. You need to have a controller to provide the data to the view.

    The course goes step by step on the frontend part but also shows you how to create a new module, customer´s orders, and show that data in an angular table

  • aashutosh.namdeo
    aashutosh.namdeo Posts: 33 🧑🏻‍🚀 - Cadet

    Thanks for replying , i am facing issue while creting a new component in existing module name SalesMerchantPortalGui want to create a new component so what process i have to follow for that i have extended entry.ts and created mp.public-api . The content of entry.ts us import { registerNgModule } from '@mp/zed-ui';
    import { ComponentsModule } from './app/components.module';
    registerNgModule(ComponentsModule);

    and mp.public-api is
    export * from './app/test-article-table/test-article-table.module';export * from './app/components.module';

    and This is my component.module.ts : -

    import { NgModule } from '@angular/core';import { WebComponentsModule } from '@spryker/web-components';import { ButtonAjaxComponent, ButtonAjaxModule } from '@spryker/button';import { ChipsComponent, ChipsModule } from '@spryker/chips';import { CardModule, CardComponent } from '@spryker/card';import { TabsModule, TabsComponent, TabComponent } from '@spryker/tabs';
    import { TestArticleTableComponent } from './test-article-table/test-article-table.component'; import { TestArtileTableModule } from './test-article-table/test-article-table.module'; import { ComponentsModule as CoreComponentsModule } from '@mp/sales-merchant-portal-gui';
    @NgModule({    imports: [        CoreComponentsModule,        WebComponentsModule.withComponents([            TestArticleTableComponent        ]),        ButtonAjaxModule,        ChipsModule,        CardModule,        TabsModule,        TestArtileTableModule    ],})export class ComponentsModule {}

    i created one component also render this in view but the component is not apearing in my view when i load on browser only conponent tag is there not the conent inside that coponent , what procedure i have to follow if want to create new component in existing module.

  • Hidran Arias
    Hidran Arias Senior Technical Trainer Sprykee Posts: 81 🏛 - Council (mod)

    it's pretty hard to see if there is any issue in the code. In the course, we do exactly what you're trying to accomplish. Follow that example where we create the component and render it: