简体   繁体   English

用Deface改变狂欢业务

[英]Change Spree commerce with Deface

I'm learning Spree because I want to create an ecommerce with it. 我正在学习Spree,因为我想用它创建一个电子商务。 I installed successfully Spree and now I would like to customize the standard spree template with deface. 我已经成功安装了Spree,现在我想用deface定制标准的spree模板。 I'm trying to delete the table with "product-properties" id in the products page. 我试图在产品页面中删除带有“ product-properties” ID的表。

我要删除的表是“属性”下的表,并具有3行:“大小”,“类型”和“材料”

I've done this way, but it doesn't work: 我已经这样做了,但是不起作用:

Deface::Override.new(:virtual_path => 'spree/layouts/spree_application',
         :name => 'product_page',
         :remove => '#product-properties'
        )

I think the virtual path is wrong. 我认为虚拟路径是错误的。

The template which contains #product-properties is: 包含#product-properties的模板为:

https://github.com/spree/spree/blob/v3.0.1/frontend/app/views/spree/products/_properties.html.erb https://github.com/spree/spree/blob/v3.0.1/frontend/app/views/spree/products/_properties.html.erb

so the virtual path you want is: 所以您想要的虚拟路径是:

spree/products/_properties

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM