Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

Backend Integration
 
Rolf Bachmann
Jr. Member
 
Total Posts:  7
Joined:  2007-12-20
 

Hi
Based on the PDF Documentation written by php | architects I’ve started to implement my first backend module. The goal of this module is to read, write and update orders, costumers and products from magento into our own system. As they have documented, the system works via REST philosophie which I like.

The first example, reading, updating the orders works well. Unfortunately I stuck now with the products. i’d like to CRUD the products with all available basic infos, image references, attribute datas and of course the tier - price data.
can give someone a hint how i can get the info out of Magento.

the code could look like this

public function readAction() {
        $collection 
Mage::getResourceModel('sales/order_collection')->addAttributeToSelect('*');
.....

1. but how can I do the same for the products ?

2. Whats the difference between this two functions

$collection Mage::getResourceModel
and
$collection Mage::Model

3. To active my own module I wrote a config file

...
<
routers
<
adminrest
<use>
admin</use> 
<
args
<
module>DQ_AdminRest</module
<
frontName>adminrest</frontName
</
args
</
adminrest>
</
routers
...
There you can see the <use> tag where you say only users who have logged in can use this module. However for testing purpose, i’d like to keep it open. How can I do that or what must be written instead of “admin” ?

thx for any help
rolf

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top