2011-02-04 117 views
0

我試圖做的是設置3個不同的onepage結帳過程實例,我想最簡單的方法是創建3個新的cms頁面,使用以下內容覆蓋xml(從checkout.xml中獲取,請參閱發佈代碼底部)並且完成這項工作。onepage結帳的自定義實例,可能在magento中?

這加載所有內容的罰款,但作爲一個客人時,它會觸發一些失敗重定向(位於onepage.phtml我相信)的步驟,它看起來不明白什麼/ checkout/onepage/saveMethod是(在瀏覽器中返回403錯誤),我假設是因爲我真的在cms頁面的某個實例中,而不是結帳頁面,因爲在某些情況下不會在幕後加載。

我希望能夠使用這種方法來定製這個過程,因爲我覺得它看起來像最乾淨的方式去做它,而不必改變太多,但我不知道究竟是什麼沒有被加載在這裏來做到這一點工作以及如何加載它。我試圖找到一種方法來調用mage_checkout通過xml的東西或其他通過cms頁面來識別它爲結帳,並讓它工作,但無法找到任何東西。

如果這是一個更簡單的方法來做到這一點,我的最終目標實際上是擁有3個獨立的/ template/checkout/onepage/phtml模板集合,因爲它們會變得不同,附屬於3個不同的url (我打算只隱藏默認/ onepage/checkout)。

<!-- Mage_Checkout --> 
    <remove name="left"/> 

    <reference name="root"> 
     <action method="setTemplate"><template>page/2columns-right.phtml</template></action> 
    </reference> 
    <reference name="right"> 
     <action method="unsetChildren"></action> 

     <block type="checkout/onepage_progress" name="checkout.progress" before="-" template="checkout/onepage/progress.phtml"/> 
     <block type="livechat/template" before="checkout.progress" name="livechat.chat" template="livechat/chat.phtml"/> 
    </reference> 
    <reference name="content"> 
     <block type="checkout/onepage" name="checkout.onepage" template="checkout/onepage.phtml"> 
      <block type="checkout/onepage_login" name="checkout.onepage.login" as="login" template="checkout/onepage/login.phtml"/> 
      <block type="checkout/onepage_billing" name="checkout.onepage.billing" as="billing" template="checkout/onepage/billing.phtml"/> 
      <block type="checkout/onepage_shipping" name="checkout.onepage.shipping" as="shipping" template="checkout/onepage/shipping.phtml"/> 
      <block type="checkout/onepage_shipping_method" name="checkout.onepage.shipping_method" as="shipping_method" template="checkout/onepage/shipping_method.phtml"> 
       <block type="checkout/onepage_shipping_method_available" name="checkout.onepage.shipping_method.available" as="available" template="checkout/onepage/shipping_method/available.phtml"/> 
       <block type="checkout/onepage_shipping_method_additional" name="checkout.onepage.shipping_method.additional" as="additional" template="checkout/onepage/shipping_method/additional.phtml"/> 
      </block> 
      <block type="checkout/onepage_payment" name="checkout.onepage.payment" as="payment" template="checkout/onepage/payment.phtml"> 
       <block type="checkout/onepage_payment_methods" name="checkout.payment.methods" as="methods" template="checkout/onepage/payment/methods.phtml"> 
        <action method="setMethodFormTemplate"><method>purchaseorder</method><template>payment/form/purchaseorder.phtml</template></action> 
       </block> 
      </block> 
      <block type="checkout/onepage_review" name="checkout.onepage.review" as="review" template="checkout/onepage/review.phtml"> 
       <block type="checkout/agreements" name="checkout.onepage.agreements" as="agreements" template="checkout/onepage/agreements.phtml"/> 
      </block> 
     </block> 
    </reference> 
+1

請說明一切的重點,以便我們真正理解問題 – 2011-02-04 08:28:27

回答

0

要做到這一點,最好的方法是在您的管理區域設置三個網站或商店。然後您必須根據文檔爲每個主題設置一個主題。您可以根據需要單獨修改每個主題/視圖。

相關問題