Joomla.it Forum

Componenti per Joomla! => Gestione e-commerce => : peppeirace 03 Feb 2014, 12:27:33

: [RISOLTO]eliminare pulsnte e link dettagli prodoto virtuemart
: peppeirace 03 Feb 2014, 12:27:33
Salve
...sto cercando di convincere virtuemart a fare quello che mi serve

ho già fatto in modo di avere il pulsante aggiungi al carrello nella vista prodotti e ora vorrei eliminare  il pulsante "dettagli prodotto e il link sull'immagine, in modo da concludere l'acquisto senza passare per i dettagli

qualche consiglio?

grazie a tutti
peppe

: Re:eliminare pulsnte e link dettagli prodoto virtuemart
: maxzilla 03 Feb 2014, 14:10:05
Ciao
con Virtuemart 2.0.26

per il bottone "dettagli" dall'elenco dei prodotti della categoria, ho disabilitato la riga

echo JHTML::link ($product->link, JText::_ ('COM_VIRTUEMART_PRODUCT_DETAILS'), array('title' => $product->product_name, 'class' => 'product-details'));

dal file default.php -> cartella category

: Re:eliminare pulsnte e link dettagli prodoto virtuemart
: mmleoni 03 Feb 2014, 15:24:49
ovviamente sempre con un bell'override del template della view!

ciao peppe!
marco


: Re:eliminare pulsnte e link dettagli prodoto virtuemart
: peppeirace 03 Feb 2014, 15:46:30
come is disabilita la riga?
...nel frattempo si è aggiunto un'altra questione
nella vista prodotti come ho detto sono riuscito (seguendo un post) a mostrare "aggiungi al carrello e quantità, ma non visualizzo però le altre caratteristiche del prodotto (campi personalizzati)

grazie
peppe

...ciao marco
: Re:eliminare pulsnte e link dettagli prodoto virtuemart
: maxzilla 03 Feb 2014, 15:52:37
devi mettere // prima di echo

oppure elimini le 3 righe

<?php // Product Details Button
 echo JHTML::link ($product->link, JText::_ ('COM_VIRTUEMART_PRODUCT_DETAILS'), array('title' => $product->product_name, 'class' => 'product-details'));
?>
: Re:eliminare pulsnte e link dettagli prodoto virtuemart
: maxzilla 03 Feb 2014, 15:55:24
nella vista prodotti come ho detto sono riuscito (seguendo un post) a mostrare "aggiungi al carrello e quantità, ma non visualizzo però le altre caratteristiche del prodotto (campi personalizzati)

dove hai messo il form che gestisce il bottone "aggiungi al carrello"?
: Re:eliminare pulsnte e link dettagli prodoto virtuemart
: maxzilla 03 Feb 2014, 15:58:36
...ma i campi personalizzati nell'elenco dei prodotti di una categoria non sono previsti
: Re:eliminare pulsnte e link dettagli prodoto virtuemart
: peppeirace 03 Feb 2014, 16:00:34
nel php in questo modo

<?php // Product Details Button
                        echo JHTML::link ($product->link, JText::_ ('COM_VIRTUEMART_PRODUCT_DETAILS'), array('title' => $product->product_name, 'class' => 'product-details'));
                        ?>
                        <form method="post" class="product" action="index.php" id="addtocartproduct<?php echo $product->virtuemart_product_id ?>">
    <div class="addtocart-bar">

            <?php // Display the quantity box ?>
            <!-- <label for="quantity<?php echo $this->product->virtuemart_product_id;?>" class="quantity_box"><?php echo JText::_('COM_VIRTUEMART_CART_QUANTITY'); ?>: </label> -->
            <span class="quantity-box">
                <input  type="text" class="quantity-input" name="quantity[]" value="1" />
            </span>
            <span class="quantity-controls">
                <input type="button" class="quantity-controls quantity-plus" />
                <input type="button" class="quantity-controls quantity-minus" />
            </span>
            <?php // Display the quantity box END ?>

            <?php // Add the button
            $button_lbl = JText::_('COM_VIRTUEMART_CART_ADD_TO');
            $button_cls = ''; //$button_cls = 'addtocart_button';
            if (VmConfig::get('check_stock') == '1' && !$this->product->product_in_stock) {
                $button_lbl = JText::_('COM_VIRTUEMART_CART_NOTIFY');
                $button_cls = 'notify-button';
            } ?>

            <?php // Display the add to cart button ?>
            <span class="addtocart-button">
                <input type="submit" name="addtocart"  class="addtocart-button" value="<?php echo $button_lbl ?>" title="<?php echo $button_lbl ?>" />
            </span>

        <div class="clear"></div>
        </div>

        <?php // Display the add to cart button END ?>
        <input type="hidden" class="pname" value="<?php echo $product->product_name ?>">
        <input type="hidden" name="option" value="com_virtuemart" />
        <input type="hidden" name="view" value="cart" />
        <noscript><input type="hidden" name="task" value="add" /></noscript>
        <input type="hidden" name="virtuemart_product_id[]" value="<?php echo $product->virtuemart_product_id ?>" />
        <?php /** @todo Handle the manufacturer view */ ?>
        <input type="hidden" name="virtuemart_manufacturer_id" value="<?php echo $product->virtuemart_manufacturer_id ?>" />
        <input type="hidden" name="virtuemart_category_id[]" value="<?php echo $product->virtuemart_category_id ?>" />
</form>
: Re:eliminare pulsnte e link dettagli prodoto virtuemart
: maxzilla 03 Feb 2014, 16:14:16
si esatto,
ma nel codice non sono previsti i campi personalizzati
: Re:eliminare pulsnte e link dettagli prodoto virtuemart
: peppeirace 03 Feb 2014, 16:15:20
e secondo te si possono inserire?


: Re:eliminare pulsnte e link dettagli prodoto virtuemart
: maxzilla 03 Feb 2014, 16:22:58
penso di si, bisognerebbe vedere nella pagina "dettaglio prodotto" come vengono caricati.
Ma non avendo mai provato, eviterei di dare indicazioni approssimative.
: Re:eliminare pulsnte e link dettagli prodoto virtuemart
: maxzilla 03 Feb 2014, 16:25:25
Forse e' meglio aprire un nuovo topic e mettere "risolto" su questo che riguarda il pulsante
: Re:eliminare pulsnte e link dettagli prodoto virtuemart
: peppeirace 03 Feb 2014, 16:28:47
OK

grazie