OpenCart: Standard Opium theory (North from Warehouse)



  • How do OpenCart: 2.1.0.1 on the standard have the value of the option to deduct from the warehouse?

    Sold this:

    \admin\controller\catalog\product.php approximately line 869 $this-statedata['subtract'] = 1; change to $this-statedata['subtract'] = 0;

    I've tried it, too.

    html += '    <td class="left"><select name="product_option[' + option_row + '][product_option_value][' + option_value_row + '][subtract]">';
        html += '      <option value="1"><?php echo $text_yes; ?></option>';
        html += '      <option value="0"><?php echo $text_no; ?></option>';
        html += '    </select></td>';

    It doesn't help, it's always about "yes."



  • In the file.

    /admin/controller/catalog/product.php
    

    Find it.

    $data['subtract'] = 1;
    

    Replace by

    $data['subtract'] = 0;
    

    Consider that it's default, that parameter has to be wrapped in manual or through OBD, or imported, as a matter of fact.


Log in to reply
 


Suggested Topics

  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2