小编Lav*_*ixu的帖子

使用Deface预填充帐单地址

我正在尝试使用预先填充的值填充我的帐单邮寄地址.我写了一个污点:

Deface::Override.new(:virtual_path => 'spree/address/_form',
                                  :name => 'prepopulate_billing_address',
                                  :set_attributes => 'p#order_bill_address_attributes_phone',
                                  :attributes => {:value => "122344"}
                                  )
Run Code Online (Sandbox Code Playgroud)

而内容属于 app/overrides/autofill_billing_address.rb

我正在尝试替换此视图 Spree表单视图

以上污点,但破损日志说

Deface: 'prepopulate_billing_address' matched 0 times with 'p#order_bill_address_attributes_phone'
Run Code Online (Sandbox Code Playgroud)

来自spree实例运行的id是order_bill_address_attributes_phone并且被包装<p>.任何的想法?谢谢您的帮助!

ruby-on-rails spree deface

0
推荐指数
1
解决办法
332
查看次数

标签 统计

deface ×1

ruby-on-rails ×1

spree ×1