What are the Slack Archives?
It’s a history of our time together in the Slack Community! There’s a ton of knowledge in here, so feel free to search through the archives for a possible answer to your question.
Because this space is not active, you won’t be able to create a new post or comment here. If you have a question or want to start a discussion about something, head over to our categories and pick one to post in! You can always refer back to a post from Slack Archives if needed; just copy the link to use it as a reference..
Hello Everyone , I had already extend the database column for custom fields in product table (databa
Hello Everyone ,
I had already extend the database column for custom fields in product table (database).
But, when I am trying to get (render) these custom field in the product section in Backoffice, we are not able to show the fields .
I have attached the screenshot where we want to show the custom field.
I have followed this documentation ("https://docs.spryker.com/docs/scos/dev/tutorials-and-howtos/advanced-tutorials/tutorial-creating-a-table-view.html#create-the-twig-template") But its not give any result. This documentation working fine in custom module table.
Do you have any idea related to add custom field in the product table?
Thanks
Comments
-
@florian.scholz @UL6DGRULR Can you please help?
0 -
fsmeier Senior Software Engineer & Developer Enablement Advocate Sprykee Posts: 1,084 ⚖️ - Guardians (admin)
What did you try so far?
0 -
Product Management already provides new plugin interfaces to extend the table: https://github.com/spryker/product-management-extension/blob/master/src/Spryker/Ze[…]ncy/Plugin/ProductTableConfigurationExpanderPluginInterface.php, https://github.com/spryker/product-management-extension/blob/master/src/Spryker/Ze[…]n/Dependency/Plugin/ProductTableDataExpanderPluginInterface.php and https://github.com/spryker/product-management-extension/blob/master/src/Spryker/Ze[…]ncy/Plugin/ProductTableQueryCriteriaExpanderPluginInterface.php try implementing those.
you can also try if it's a cache issue by cleaning the Zed cache:
docker/sdk console cache:empty-all
0 -
@UL6DGRULR We had added one column in order table so how to render it in backend and front end? Which file will be used for Zed and Yues
0 -
For Zed/Backend implement the plugins I've mentioned above and wire them in the right dependency provider (
\Pyz\Zed\ProductManagement\ProductManagementDependencyProvider
).For Yves, add a field to the right transfer objects (
ProductAbstractTransfer
generated fromproduct.transfer.xml
andProductAbstractStorageTransfer
generated fromproduct_storage.transfer.xml
) and adapt the product detail page (https://github.com/spryker-shop/product-detail-page/blob/master/src/SprykerShop/Yv[…]default/components/molecules/product-detail/product-detail.twig).0 -
@UL6DGRULR Can you please let me know how we can create new table in database with primary key value and autoincrement for a column ?
0 -
Create a propel schema file in your module at
src/Pyz/Zed/<YourModule>/Persistence/Propel/pyz_<your_module>.schema.xml
and have a read in the propel documentation: http://propelorm.org/documentation/02-buildtime.html#describing-your-database-as-xml-schema and http://propelorm.org/documentation/reference/schema.html. After you've written your schema just runconsole propel:install
<?xml version="1.0"?> <database xmlns:xsi="<http://www.w3.org/2001/XMLSchema-instance>" name="zed" namespace="Orm\Zed\<YourModule>\Persistence" package="src.Orm.Zed.<YourModule>.Persistence"> <table name="pyz_<your_table>"> <column name="id_<your_table>" type="INTEGER" required="true" autoIncrement="true" primaryKey="true" /> <column name="<your_column_1>" type="VARCHAR" required="true" /> </table> </database>
0 -
-
@UL6DGRULR Thanks!! 🙂
0 -
@UL6DGRULR We have one more scenario :-
We had created a new table in database as mentioned in given screen shot. We have assign a foreign key on this table that is primary key of products, So that we can make a relationship with our custom table. Now our main goal is insert the data in our custom table using a form. So can you please let me know how we can create a form to insert data in this table.(we are using a custom module for it.)0 -
https://docs.spryker.com/docs/scos/dev/back-end-development/forms/creating-forms.html and a quick search for "form" would have brought it up.
I'm happy to help here as much as I can, but please try to find answers, especially if they are easy to find, on your own first, before asking for help.
0
Categories
- All Categories
- 42 Getting Started & Guidelines
- 7 Getting Started in the Community
- 8 Additional Resources
- 7 Community Ideas and Feedback
- 76 Spryker News
- 930 Developer Corner
- 788 Spryker Development
- 89 Spryker Dev Environment
- 362 Spryker Releases
- 3 Oryx frontend framework
- 35 Propel ORM
- 68 Community Projects
- 3 Community Ideation Board
- 30 Hackathon
- 3 PHP Bridge
- 6 Gacela Project
- 26 Job Opportunities
- 3.2K 📜 Slack Archives
- 116 Academy
- 5 Business Users
- 370 Docker
- 551 Slack General
- 2K Help
- 75 Knowledge Sharing
- 6 Random Stuff
- 4 Code Testing
- 32 Product & Business Questions
- 70 Spryker Safari Questions
- 50 Random