Jump to content
zonetown

[Contribution] QTpro - Quantity Tracking Professional

Recommended Posts

Anyone know how to set up Actual Attributes price with this?

 

-Thanks


Search the forum and contributions before posting. If that doesn't work, keep looking, then post. The forum is for seeking help and advice NOT for someone to do your work for you. Try to do something on your on, if you are going to run a shop then learn how it works.

Share this post


Link to post
Share on other sites

Still interested in setting up and displaying actually attributes price as I am only able to set it up the old way with +1.00 etc.

 

Any help?

 

-Thanks


Search the forum and contributions before posting. If that doesn't work, keep looking, then post. The forum is for seeking help and advice NOT for someone to do your work for you. Try to do something on your on, if you are going to run a shop then learn how it works.

Share this post


Link to post
Share on other sites

Is it possible to make an TABLE with my Product Options?

with QTPro 4.3 (Never have more than 2 "axis")

 

Example for T-Shirts in 5 Sizes and 3 Colors

 

................XS.....S......M......L.....XL

red............ o .... o .... o ..... o ... o

navy.......... o .... o .... o ..... o ... o

green......... o .... o .... o ..... o ... o

 

If you could solve this I would very happy and to make me

satisfied I need a solution with different CSS-styles for

products in and out of Stock.

Share this post


Link to post
Share on other sites

I've got QTPro installed and have searched this forum, but haven't been able to locate the answer... When I edit an order and add a product to the order, the column orders_products.products_stock_attributes is not properly filled in. Is there a fix for this??

Share this post


Link to post
Share on other sites
I've got QTPro installed and have searched this forum, but haven't been able to locate the answer... When I edit an order and add a product to the order, the column orders_products.products_stock_attributes is not properly filled in. Is there a fix for this??

 

 

That is a issue with the manual order editor. See that thread for a fix.


Search the forum and contributions before posting. If that doesn't work, keep looking, then post. The forum is for seeking help and advice NOT for someone to do your work for you. Try to do something on your on, if you are going to run a shop then learn how it works.

Share this post


Link to post
Share on other sites

Still interested in setting up and displaying actually attributes price if this is possible as I am only able to set it up the old way with +1.00 etc.

 

Any help? Anyone?

 

-Thanks


Search the forum and contributions before posting. If that doesn't work, keep looking, then post. The forum is for seeking help and advice NOT for someone to do your work for you. Try to do something on your on, if you are going to run a shop then learn how it works.

Share this post


Link to post
Share on other sites
Still interested in setting up and displaying actually attributes price if this is possible as I am only able to set it up the old way with +1.00 etc.

 

Any help? Anyone?

 

-Thanks

 

 

Anyone know if this is possible? I think this is lacking if it's not possible.


Search the forum and contributions before posting. If that doesn't work, keep looking, then post. The forum is for seeking help and advice NOT for someone to do your work for you. Try to do something on your on, if you are going to run a shop then learn how it works.

Share this post


Link to post
Share on other sites

Hi

 

In need of help

 

Has any one got this working with More Pics 6

 

I have QTpro up and running im just having a problem getting it working with my product_info

 

could some point me in the right direction.

 

 

 

thanks

 

rob

Share this post


Link to post
Share on other sites

Still interested in setting up and displaying actually attributes price if this is possible as I am only able to set it up the old way with +1.00 etc.

 

Any help? Anyone?

 

-Thanks


Search the forum and contributions before posting. If that doesn't work, keep looking, then post. The forum is for seeking help and advice NOT for someone to do your work for you. Try to do something on your on, if you are going to run a shop then learn how it works.

Share this post


Link to post
Share on other sites

Hi, this is a great contribution - thanks to the author!

 

However i've one question...

 

When using a simple attribute like size, and a dropdown combo box, is it possible to give the combo box a default value, that is not selectable by the user?

 

Such as this?

 

dropdown.gif

Edited by sjwdavies

Share this post


Link to post
Share on other sites
Hi, this is a great contribution - thanks to the author!

 

However i've one question...

 

When using a simple attribute like size, and a dropdown combo box, is it possible to give the combo box a default value, that is not selectable by the user?

 

Such as this?

 

dropdown.gif

 

 

Managed to do it, using the following java script:

 

<script language="JavaScript" type="text/javascript">
function check_size_selected(form) {
if (document.getElementById('id[1]').options[document.getElementById('id[1]').selectedIndex].value == "do_not_submit") {
alert("You haven't selected a size - please make your choice before adding to the basket.");
return false;
}
form.submit();
}
</script>

 

And by adding a PHP if statement to the part where it draws the 'Add to Cart' button, and also using this:

 

<td class="main" align="right"><?php echo tep_draw_hidden_field('products_id', $product_info['products_id']) . tep_image_submit('button_in_cart.gif', IMAGE_BUTTON_IN_CART, 'onclick="java script: check_size_selected(this.form); return false;"'); ?></td

Share this post


Link to post
Share on other sites

*Showing out of stock products while using QTpro*

 

Thanks for the great contrib, I installed it and everything is just fine.

 

I'm trying to use it with a modified code of not setting a product out of stock by commenting the line in catalog/checkout_process.php like this

if ( ($stock_left < 1) && (STOCK_ALLOW_CHECKOUT == 'false') ) {
           //tep_db_query("update " . TABLE_PRODUCTS . " set products_status = '0' where products_id = '" . tep_get_prid($order->products[$i]['id']) . "'");
         }

 

this is so far working amazing as it doesn't interfer with product stock. Until I noticed that QTpro doesn't behave correctly to decide if a product is in stock or not when there is only 1 attributes combination.

 

so if a product has 2 options and both are out of stock, then it will work ok and give the out of stock message.

 

but if a product has only 1 option and it's out of stocks, it will simply add it to the cart. (while I really want it to give the out of stock message because I want to keep products shown but still have the control provided with QTpro)

 

So basically...QTpro says that a product combination is out of stock ONLY when there are other combinations regardless being in or out of stock!

 

I think the problem comes from catalog/includes/classes/pad_single_dropdown.php in these lines

  function _draw_out_of_stock_message_js($attributes) {
     $out='';
     $out.="<tr><td> </td><td> \n";

     if (($this->show_out_of_stock == 'True') && ($this->no_add_out_of_stock == 'True')) {
       $out.="<script LANGUAGE=\"JavaScript\"><!--\n";
       $combinations = array();
       $selected_combination = 0;
       $this->_build_attributes_combinations($attributes, false, 'None', $combinations, $selected_combination);

       $out.="  function chkstk(frm) {\n";

       // build javascript array of in stock combinations of the form
       // {optval1:{optval2:{optval3:1,optval3:1}, optval2:{optval3:1}}, optval1:{optval2:{optval3:1}}};
       $out.="    var stk=".$this->_draw_js_stock_array($combinations).";\n";
       $out.="    var instk=false;\n";

       // build javascript to extract attribute values and check stock  
       $out.="    if (frm.attrcomb.type=='select-one') {\n";
       $out.="      var attrs=frm.attrcomb.value.split(',');\n";
       $out.="    }\n";
       $out.="    else {\n";
       $out.="      for (i=0; i,frm.attrcomb.length; i++) {\n";
       $out.="        if (frm.attrcomb[i].checked) {\n";
       $out.="          var attrs=frm.attrcomb[i].value.split(',');\n";
       $out.="          break;\n";
       $out.="        }\n";
       $out.="      }\n";
       $out.="    }\n";
       $out.="    var id=Array(" . sizeof($attributes) . ");\n";
       $out.="    for (i=0; i<attrs.length; i++) {\n";
       $out.="      id[i]=attrs[i].split('-')[1];\n";
       $out.="    }\n";
       $out.='    ';
       for ($i=0; $i<sizeof($attributes); $i++) {
         $out.='if (stk';
         for ($j=0; $j<=$i; $j++) {
           $out.="[id[".$j."]]";
         }
         $out.=') ';
       }

       $out.="instk=true;\n";
       $out.="  return instk;\n";
       $out.="  }\n";

       if ($this->no_add_out_of_stock == 'True') {
         // js to not allow add to cart if selection is out of stock
         $out.="  function chksel() {\n";
         $out.="    var instk=chkstk(document.cart_quantity);\n";
         $out.="    if (!instk) alert('".TEXT_OUT_OF_STOCK_MESSAGE."');\n";
         $out.="    return instk;\n";
         $out.="  }\n";
         $out.="  document.cart_quantity.onsubmit=chksel;\n";
       }
       $out.="//--></SCRIPT>\n";
     }
     $out.="</td></tr>\n";

     return $out;

 

I think the checking fails for a product with 1 option only but I can't spot :blink:

 

ideas...anyone?

Share this post


Link to post
Share on other sites

Still interested in setting up and displaying actually attributes price if this is possible as I am only able to set it up the old way with +1.00 etc.

 

Any help? Anyone?

 

-Thanks


Search the forum and contributions before posting. If that doesn't work, keep looking, then post. The forum is for seeking help and advice NOT for someone to do your work for you. Try to do something on your on, if you are going to run a shop then learn how it works.

Share this post


Link to post
Share on other sites

I'm having the same problem with FILENAME_LOGIN when going in to the admin section... A brand new installation of OSC 2.2 and QTPro 4.3 - any help greatly appreciated - am doing this to use the atandra t-hub + quickbooks point of sale combination... should be fairly cool if it works :)

Edited by alohav2

Share this post


Link to post
Share on other sites

great news - looks like the only issue was adding

 

define('FILENAME_LOGIN', 'login.php');

 

into the catalog/admin/filenames.php file

 

thanks for the helpful contribution ya'll :)

Share this post


Link to post
Share on other sites

is this a bug?

 

my settings are like this:

 

Check stock level true

Subtract stock true

Allow Checkout false

Mark product out of stock ***

Stock Re-order level 0

 

Product Info Attribute Display Plugin single_radioset

Show Out of Stock Attributes True

Mark Out of Stock Attributes Right

Display Out of Stock Message Line True

Prevent Adding Out of Stock to Cart True

 

now let's say you have an item with 1 option only and it went out of stock but you need to have showing on the website so you go to Catalog>Categories / Products and click the green active button.

 

now if you go to the product and try to add it, it will be added normally to the cart, while if you use Product Info Attribute Display Plugin -> single_dropdown it will give you the out of stock popup! I though single_radioset inherets from single_dropdown...but it doesn't seem to work.

 

any one can confirm it?

Share this post


Link to post
Share on other sites

Hi there,

I'm new to this, but I succeeded in doing a fresh install of RC1.

I tried to implement QTPro 4.3, but after several attempts.. I still didn't succeed.

I have done all the four steps as instructed, checked the DB if everything was there and it was, but after copying the files from the zip to the server I don't see anything happening in de admin-panel.

For instance.. I don't get the 'stock-button', not even when I just add 1 new product with 2 newly added attributes.

So, I was just wondering if someone allready succeeded in adding QTPro 4.3 to RC1, and if so.. could you give me (or anyone else offcourse) some hints or a working manual?

Thanks in advance,

Daros

Share this post


Link to post
Share on other sites

Hello,

 

I have the exact same problem with the mod BUNDLE :-( Did anyone change the code for these two mods ?

 

I have a problem. This contribution and BUNDLE PRODUCT overlape at the file of CHECKOUT_PROCCESS.PHP. Have anybody can combine them? Thanks very much!

Share this post


Link to post
Share on other sites

Exactly same problem that Alley Kat in deleting case !!

Have you fix it ?

That seem it is a bug, author had forget to delete value product_stock in product_attribute.php for the 3 cases : delete options, attibute or value.

 

 

 

 

 

 

** PLS IGNORE ABOVE POST No way of editing/removing, sorry. Current questions here:

 

I've added 4.3 and noticed a couple of things:

 

1) After deleting Products Attributes: qty update fails

We delete all options for a product (Catalog > Options Attributes). The "Stock" button against the product then shows a Quantity field and "Update" button.

But this only allows us to change the value once....? Further adjustments don't work...

Changing the value in the normal Edit Product screen works fine though.

 

2) If we re-add any of the options we'd previously deleted (Catalog > Options Attributes), *all* previous options re-appear also in the item, when you hit the Stock button. If they had Stock Quantities before, they re-appear too....

This is a bad one. It probably means having to dive into phpMyAdmin, which a client certainly won't and shouldn't do.

 

So it seems that deleting Products Attributes doesn't actually delete their associated stock info

 

Any help much appreciated folks!

Edited by Jin Kazuya

Share this post


Link to post
Share on other sites

Chances of getting support for this module is slim. You probably have better luck of getting hit by a meteoroid.

 

What a shame....


Search the forum and contributions before posting. If that doesn't work, keep looking, then post. The forum is for seeking help and advice NOT for someone to do your work for you. Try to do something on your on, if you are going to run a shop then learn how it works.

Share this post


Link to post
Share on other sites
getting hit by a meteoroid.
:lol: :lol: :'(

 

I am not bad in logical search, but really newbies in coding...

The solution should be in product_attribute.php, case : delete attribute :

 

[...] anymore [...]

line 10 :		case 'delete_attribute':
line 20 :		$attribute_id = tep_db_prepare_input($HTTP_GET_VARS['attribute_id']);
line 30 :		tep_db_query("delete from " . TABLE_PRODUCTS_ATTRIBUTES . " where products_attributes_id = '" . (int)$attribute_id . "'");
line 40 :		// added for DOWNLOAD_ENABLED. Always try to remove attributes, even if downloads are no longer enabled
line 50 :		tep_db_query("delete from " . TABLE_PRODUCTS_ATTRIBUTES_DOWNLOAD . " where products_attributes_id = '" . (int)$attribute_id . "'");
line 60 :		tep_redirect(tep_href_link(FILENAME_PRODUCTS_ATTRIBUTES, $page_info));
line 70 :		break;

[...] anymore [...]

 

When you delete an attribute (line 30) you must before delete this attribute in product_stock table.

But product_stock table do not have an array attribute_id... BUT, there is an array product_stock_attributes who is make of :

options_id . "-" . option_values_id from the product_attributes table.

 

Normaly, a simply adding like :

line 21 :		$options_id = tep_db_prepare_input($HTTP_POST_VARS['options_id']);
line 22 :		$values_id = tep_db_prepare_input($HTTP_POST_VARS['values_id']);
line 23 :		tep_db_query("delete from " . TABLE_PRODUCTS_STOCK . " where products_stock_attributes =  '" . (int)$options_id . "', options_values_id = '" . (int)$values_id . "'");

would be fine, but $options_id and $values_id are always empty... I really don't kwon why, because there is no problem with $attribute_id, and everything is similar...

 

I will try do some select before, assembling this select, etc, etc...

Anyway, as soon I find something clean and really fonctional, I update the contribution.

 

If someone find the SQL solution before me, just update the contribution...

 

 

 

 

Chances of getting support for this module is slim. You probably have better luck of getting hit by a meteoroid.

 

What a shame....

Edited by Jin Kazuya

Share this post


Link to post
Share on other sites

Sorry, but cut and paste...

Please read :

 

line 23 : tep_db_query("delete from " . TABLE_PRODUCTS_STOCK . " where products_stock_attributes = '" . (int)$options_id" . "-" . (int)$values_id . "'");

 

instead of

 

line 23 : tep_db_query("delete from " . TABLE_PRODUCTS_STOCK . " where products_stock_attributes = '" . (int)$options_id . "', options_values_id = '" . (int)$values_id . "'");

Edited by Jin Kazuya

Share this post


Link to post
Share on other sites

I have been asking this question for 3 weeks, still nothing.

 

Still interested in setting up and displaying actually attributes price if this is possible as I am only able to set it up the old way with it displaying +1.00 etc.

 

I want it to show it this way. The original price is lets say $19.99 and the attributes cost $2.00 more then it would show $21.00 not +2.00. Anyway of making this happen. This is a fairly popular way and a lot of people ask for this. So can this be down with QT Pro or not?

 

Any help? Anyone?

 

-Thanks


Search the forum and contributions before posting. If that doesn't work, keep looking, then post. The forum is for seeking help and advice NOT for someone to do your work for you. Try to do something on your on, if you are going to run a shop then learn how it works.

Share this post


Link to post
Share on other sites
great news - looks like the only issue was adding

 

define('FILENAME_LOGIN', 'login.php');

 

into the catalog/admin/filenames.php file

 

thanks for the helpful contribution ya'll :)

 

 

I have the same problem. I added the above code in fileanames.php which is in catalog\admin\includes

 

Now I am getting this message:

1146 - Table 'name of database.table_administrators' doesn't exist

 

select id from TABLE_ADMINISTRATORS limit 1

 

Obviously I have to add the id, username and passsword of osc online shop as administrator of database through phpmyadmin. I dont know how to do this or need to do something different. Any help. Thanks

Share this post


Link to post
Share on other sites
Is it possible to have a quantity selection box in the product_info.php where it was directly linked to the attributes quantity.

 

so, if I clicked the attribute size 2 and I only had 3, the quantity box would have a selection choice of 1, 2, 3 to go to the cart? And the same for the cart, a quantity drop down box where the quantity would pull from the attribute quantity?

 

Thank you all in advance!

 

Is there anyone who knows how this works or if it is supposed to already be there, why I dont see it in my shop?

 

Currently the only way for a customer to select a quantity of more than one is by adding it to their cart then changing it there. It is also not showing the stock error in the cart when the quantity for that attribute is higher than actual stock.

 

In other words, if I only have 1 in a size 5 but a total of 3 in all sizes it is permitting a buyer to checkout with 2 size 5's. It is removing stock correctly for each attribute, just not preventing checkout or showing an error when the quantity for the attribute is less than buyer entered.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×