GithubHelp home page GithubHelp logo

Comments (6)

Jwhiles avatar Jwhiles commented on August 28, 2024

Hey Sankar,
do you mean that you are using one of our libraries inside your own codebase? Or is this a feature request for the apps that we maintain?

from apps.

sankar9659 avatar sankar9659 commented on August 28, 2024

@Jwhiles Thanks for your response.

I mean, I m using the ecommerce app base package (https://www.npmjs.com/package/@contentful/ecommerce-app-base) to populate the products in contentful dialogue modal.
like the below image,

newimg

I want to customize the design and need to add some functionality like the below image,
I want to add some checkbox fields like product types and categories, When I click the product type checkbox, I want to show the products based on the product type key. Is this possible with this package?
or Is there any other way to implement this design?

image

from apps.

Jwhiles avatar Jwhiles commented on August 28, 2024

Hey @sankar9659 thanks for the detailed explanation.

I think it's unlikely at this point that we'll add functionality like this to the ecommerce app base packages. However, the setup method of the package accepts a renderDialogMethod which you can use to create your own custom dialog. You could base a custom dialog on the the existing renderSkuPicker code.

Cheers,
John

from apps.

sankar9659 avatar sankar9659 commented on August 28, 2024

Yes, I have passed some props to the render sku picker like below code,

renderSkuPicker(DIALOG_ID, {
    sdk,
    fetchProductPreviews,
    fetchProducts: async (search, pagination) => {
      const result = await fetchSKUs(
        sdk.parameters.installation,
        search,
        pagination
      );

      return {
        pagination: {
          count: PREVIEWS_PER_PAGE,
          limit: PREVIEWS_PER_PAGE,
          total: 10, // as of now we are not getting total products in API so given static total.
          offset: 1,
        },
        products: result.data.map(multipleProductdataTransformers()),
      };
    },
  });

You mean I dont need use the renderSkuPicker and I will create a custom design and functionality right?

from apps.

sankar9659 avatar sankar9659 commented on August 28, 2024

But I need the existing functionality also, (when i select a product, the product id stored in contentful, then I can save the selected products and publish that), Can you please give a documentation or example code to implement this?

from apps.

sankar9659 avatar sankar9659 commented on August 28, 2024

@Jwhiles Any possible to implement this?

from apps.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.