cost 218 ms
Solidus Paypal 在非 PayPal 支付變體的沙箱中結賬失敗

[英]Solidus Paypal checkout fails in sandbox for non-PayPal payment variants

我在 Ruby 中使用 Solidus 在 Rails 上建立了一個網上商店。 當我嘗試使用信用卡或德國地址的 SEPA 在 PayPal 沙盒中結帳時,它抱怨商店不在那里送貨。 當我使用 PayPal 帳戶付款時,效果很好,也適用於柏林的德國地址...... 這是 ruby 控制台中的錯誤:St ...

Spree 4.4 前端在哪里?

[英]Where is the Spree 4.4 frontend?

我安裝了 Spree 4.4 我找不到任何前端 在 localhost:3000 它說 Yay You're on Rails 文檔說要下載前端 api 並在 Postman 中打開它 我這樣做了,但我沒有看到任何看起來像店面 我可以進入管理面板好嗎 任何人都可以幫忙嗎? ...

2022-08-26 19:30:30   1   17    spree  
在視圖中將按鈕鏈接到 spree 引擎外部的 add_to_cart

[英]Link button to add_to_cart outside spree engine on view

我正在創建一個產品並添加一個按鈕,我想將 go 直接添加到 add_to_cart 狂歡路徑。 我嘗試了以下方法: 按鈕轉到一個空購物車。 如何在 spree 引擎之外添加或鏈接我的視圖按鈕到 add_to_cart? 為清楚起見,我試圖用我自己的自定義按鈕填充購物車,這是 spree 上的這個按 ...

數據庫重置后大禮包路線不起作用

[英]Spree Routes Not Working after Database Reset

我最近不得不重置我的開發數據庫(因為 Spree 遷移的復雜性),現在我的一些 Spree 路線似乎丟失了。 我有以下與 Spree 相關的寶石: 我在我的routes.rb文件中有這個作為唯一特定於狂歡的路線......沒有自定義: 但是,當我轉到http://localhost:300 ...

銷毀所有大禮包 current_order 數據和 line_items

[英]Destroy all spree current_order data and line_items

我正在使用 Rails Spree 開發一個新功能,該功能可以清除當前用戶購物車和那里的所有元素。 目前我正在使用這段代碼並且它已經完成了工作,但我覺得我可以做得更好。 有誰知道如何改進它? 也許有一種狂歡方法可以明確地做到這一點! 提前致謝! ...

Rails Spree 無法從支付過渡到完成

[英]Rails Spree Cannot transition from payment to complete

我正在將自定義支付方式集成到我的 Rails 應用程序中。 但我無法讓我的訂單從付款統計到完成 state。我確保訂單中注冊的付款已完成 state,所以我不明白為什么 state 機器告訴我“未找到付款” 這是我的代碼。 這是我得到的錯誤 StateMachines::InvalidTransit ...

無法連接到 example.com 端口 4000 Spree commerce

[英]Failed to connect to example.com port 4000 Spree commerce

安裝 Spree Commerce 並運行這些命令后,我無法訪問我的域http://example.com:4000/或http://example.com:4000/admin 。 當我運行時: curl example.com:4000我得到: curl: (7) Failed to conn ...

活動存儲附件 - 無法將圖像解析為 URL:未定義的方法`attachment_url

[英]Active Storage attachment - Can't resolve image into URL: undefined method `attachment_url

有人問過類似的問題,但沒有一個解決方案對我有用。 我在 solidus 中構建應用程序,每次創建產品時都需要生成二維碼。 我正在使用 rqr gem,然后嘗試將生成的rqrcode png 附加到 Active Storage 中的產品。 每當我嘗試渲染圖像時,我都會收到以下錯誤。 創建產品后,我 ...

設置狂歡商務時遇到問題

[英]Having trouble setting up spree commerce

我正在使用 docker 在我的 mac m1 機器上設置瘋狂商務。 當我運行 bin/setup 腳本時,我遇到了以下錯誤並且無法繼續。 我不確定是什么問題。 我遵循了官方網站https://dev-docs.spreecommerce.org/getting-started/installati ...

如何在 Solidus 電子商務中設置默認國家/地區

[英]How to set default country in Solidus Ecommerce

首先,我正在嘗試為我的產品變體創建(庫存)庫存。 不太確定,但看來我需要創建一個庫存位置。 接下來,我正在嘗試設置庫存位置。 但是,我收到以下錯誤消息: 如何創建默認國家? 架構中可能存在的唯一合乎邏輯的位置是: spree_stores.cart_tax_country_iso。 但是,使用管理面 ...

ActiveRecord::StatementInvalid 在 Rails 4.2.7.1 中

[英]ActiveRecord::StatementInvalid in Rails 4.2.7.1

在我的本地系統上,我面臨 Statement Invalid 錯誤。 以前,我沒有得到這個,但我想當我在添加 taxon_ids 索引后重新索引我的彈性搜索時,這個錯誤開始出現。 請檢查隨附的屏幕截圖。 版本詳細信息是 - 請告知如何解決。 ...

Rails ActiveRecord 嵌套。創建! 使用 PSQL POINT 類型

[英]Rails ActiveRecord nested .create! with PSQL POINT type

我正在嘗試使用 Rails 和 ActiveRecord 創建一個深度嵌套的 object。 model 包含一個子Address ,該地址具有 PSQL 類型 POINT 的coordinates字段。 因此,當我嘗試創建它時,出現以下錯誤。 我猜它試圖通過使用提供的字段首先加載Address類 ...

未定義的局部變量或方法 `permitted_task_attributes' for # <api::v1::taskscontroller< div><div id="text_translate"><p> 我有一個遵循 Spree/Solidus 范式的解決方案,它封裝了允許的參數。 我沒有能力改變它,而是效仿。 但是,我遇到了一個問題,我無法重現 #Api::V1::TasksController:0x0000000000b7c0 的未定義局部變量或方法“permitted_task_attributes”。</p><p> 下面是代碼:</p><p> <strong>控制器/api/v1/task_controller.rb</strong></p><pre> module Api module V1 class TasksController &lt; ApiController def index task = Task.all render json: task end def create task = Task.create:(create_action_params) if task render json: task else render json. task.errors end end private def create_action_params params:require(.task).permit(permitted_task_attributes) # The problem is with this variable `permitted_task_attributes` end end end end</pre><p> <strong>控制器/api_controller.rb</strong></p><pre> class ApiController &lt; ApplicationController before_action:set_api_request private def set_api_request request.format = request.format ==:xml? :xml: :json end end</pre><p> li <strong>b/controller_helpers/strong_parameters.rb</strong></p><pre> module ControllerHelpers module StrongParameters def permitted_attributes PermittedAttributes end delegate(*PermittedAttributes::ATTRIBUTES, to: :permitted_attributes, prefix: :permitted) def permitted_task_attributes permitted_attributes.task_attributes end end end</pre><p> <strong>lib/permitted_attributes.rb</strong></p><pre> module PermittedAttributes ATTRIBUTES = [:task_attributes ].freeze mattr_reader(*ATTRIBUTES) @@task_attributes = [:avatar_url, :description, :recorded_on ] end</pre><p> <strong>錯誤</strong></p><pre>undefined local variable or method `permitted_task_attributes' for #&lt;Api::V1::TasksController:0x0000000000b7c0&gt;</pre><p> 我確實了解permitted_task_attributes無法訪問這個名為 allowed_task_attributes 的方法,但我無法修復它。 我試圖在 controller 中包含ControllerHelpers::StrongParameters ,但我仍然有未初始化的常量錯誤。 我怎樣才能解決這個問題? </p></div></api::v1::taskscontroller<>

[英]undefined local variable or method `permitted_task_attributes’ for #<Api::V1::TasksController

我有一個遵循 Spree/Solidus 范式的解決方案,它封裝了允許的參數。 我沒有能力改變它,而是效仿。 但是,我遇到了一個問題,我無法重現 #Api::V1::TasksController:0x0000000000b7c0 的未定義局部變量或方法“permitted_task_attrib ...

TypeError 沒有將 Spree::Order 隱式轉換為 Hash

[英]TypeError no implicit conversion of Spree::Order into Hash

當我在創建訂單時將大禮包從 4.1 更新到 4.2 時,我遇到了這樣的錯誤。 訂單流將產品添加到購物車結帳產品地址發貨方式支付訂單完成並生成郵件,成功頁面上顯示此錯誤 TypeError 沒有將 Spree::Order 隱式轉換為 Hash ...

在 routes.rb 中重定向 301

[英]Redirect 301 in routes.rb

我和 Spree 一起工作,我在做“rake routes”時發現了這條線 這是什么意思? 什么是 v:api,什么是重定向(301)? 我知道redirect(301) 是什么,但新路線是什么? ...

Rails Spree API 與多存儲

[英]Rails Spree API with multistore

據我所知,我可以在 Spree 中使用三種類型的 api。 我只以產品為例。 http://127.0.0.1:3000/api/products http://127.0.0.1:3000/api/v1/products http://127.0.0.1:3000/api/v2/produc ...


 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM