vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.6 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=194)
-   -   Major Additions - VBay! Transform your vbulletin into an auctionhouse! (https://vborg.vbsupport.ru/showthread.php?t=132544)

realdx 10-08-2009 04:46 PM

you canT edit the product once published.. :)

godarmy 10-12-2009 08:36 PM

installed on 3.8.4 pl 1...and it's work...but...need some new feature...hope that u can modif it again...

like what realdx say...it cannot be edited if the product is published...

AfterWorldForum 10-14-2009 09:58 AM

Installed, and running it in admin-only mode now.

I just seem to have trouble with my thumbnails. Only a red X shown. In the database, the thumbdata field is empty. I tried taking a peek at the vbaytn.php page, but saw nothing out of the ordinary in there.

Also tried rerunning the vbaytn page with the simple_reset option for the specific item, but no luck with that either.

Any pointers? I tried turning on logging to file in order to hopefully get more info, but nothing there, either :(

Thanks in advance.

Edit: Some nice extra features I'd love:

- Easily adjust the address fields. Took me quite some time to manually edit out everything to suit my needs.
- Ability to adjust an auction as long as no bids were made yet.
- Subcategories
- Ability to add displayorder to categories
- Starting price should be possible to bid while no bids made yet (I suspect I can handle this myself)
- Move thumbnails and images to the filesystem, or better support for galleries

Other than that, works fine for now, with the exception of the thumbnails not shoiwng up.

Edit2:
Tried with a different picture, and that worked fine. Maybe it's only due to my first image being .bmp? Will have to test a bit more later.

Edit3:
When the bmp image was converted to JPG, the thumbnail showed up. I ended up removing bmp from the allowed image types.
I also managed to hack the mod a little so it is now possible to actually bid the startprice rather than the startprice + inc only (if you want to do this yourself, edit vbay.php and look for:

Code:

$lowest_bid = $item['price'] + $item['inc'];
Change to:

Code:

      if($item[bids] == 0) {
                        $lowest_bid = $item['price'];
                } else {
                        $lowest_bid = $item['price'] + $item['inc'];
                }

And another edit further down. Look for:

Code:

                      if ($item['price'] + $item['inc'] > $vbulletin->GPC['bid']) {
                          eval(standard_error(fetch_error('vbay_bid_higher')));
                      }
              if ($item['bids'] > 0) {

Replace with:
Code:

              if ($item['bids'] > 0) {
                      if ($item['price'] + $item['inc'] > $vbulletin->GPC['bid']) {
                          eval(standard_error(fetch_error('vbay_bid_higher')));
                      }

I *think* that does the trick, though I might have made a template change as well. Sorry for not being more clear than that, but I've been editing and tidying up the code and adjusting it for my personal needs (which, due to being virtual items included removing all references of shipping and external payments, were quite substantial).

Should you be trying this and my solution turns out not to be complete, please let me know and I will see if I can find the rest.

I also am trying to see if I can finish up the BuyOut option, which does not work as intended atm (i.e. if I create an auction with a startbid of 1, a reserve of 10, a buyout of 100 and an increment of 1, it's possible to straight away after creation hit buyout. The closing price then will be 2 (or 1 after the change above), rather than 100, and you'll see a message stating the reserve was not met).

Blaine0002 10-14-2009 06:03 PM

thanks for the tips people can use.
as for suggestions

- Easily adjust the address fields. Took me quite some time to manually edit out everything to suit my needs.
Its a little bit hard to code, but ill take a look into it.
- Ability to adjust an auction as long as no bids were made yet.
Already coded into next version
- Subcategories
Already coded into next version (forum system is used)
- Ability to add displayorder to categories
Since forum system is used, this is easily achievable.
- Starting price should be possible to bid while no bids made yet (I suspect I can handle this myself)
you handled it, ill put it in the next version.
- Move thumbnails and images to the filesystem, or better support for galleries
Attachment system used. already coded into next version

ive said before, and im sorry that i seem like a broken record, but the next version is coming.
Its almost finished, its practically a complete rewrite, so that on top of school (which is my main priority) its moving fairly slowly. Just like to let you guys know!

AfterWorldForum 10-14-2009 06:16 PM

Awesone news. If you're looking to handle the BuyOut options, I think I came up with a way that does part of the work.

in vbay_info_View, find:

Code:

<a href="vbay.php?do=buy&id={$item[id]}">$vbphrase[vbay_auction_buy_it_now_bang]</a>
Replace with:
Code:

<a href="vbay.php?do=buy&id={$item[id]}&buyout=true">$vbphrase[vbay_auction_buy_it_now_bang]</a>
In vbay_buy_confirm, replace:

Code:

<form action="vbay.php?$session[sessionurl]do=dobuy" method='post' enctype='multipart/form-data'>
<input type="hidden" name="id" value="{$vbulletin->GPC['id']}">

with:

Code:

<form action="vbay.php?$session[sessionurl]do=dobuy" method='post' enctype='multipart/form-data'>
<input type="hidden" name="id" value="{$vbulletin->GPC['id']}">
<input type="hidden" name="buyout" value="{$vbulletin->GPC['buyout']}">

In vBay.php, under BUYOUT, replace:

Code:

      $vbulletin->input->clean_array_gpc('p', array('id' => TYPE_INT));
with:

Code:

      $vbulletin->input->clean_array_gpc('p', array('id' => TYPE_INT, 'buyout' => TYPE_BOOL));
    $buyout = $vbulletin->GPC['buyout'];

and

Code:

      } else {
          $db->query("update " . TABLE_PREFIX . "vbay_items SET highbidder = " . $vbulletin->userinfo['userid'] . ", bids = bids+'1', completetime = '0' WHERE id=" . $vbulletin->GPC['id'] . "");
          $vbulletin->url = "vbay.php?do=item&viewitem=" . $vbulletin->GPC['id'] . $vbulletin->session->vars['sessionurl'] . "";
          eval(print_standard_redirect('vbay_buy_success', true, true));
      }

with

Code:

                        if ($vbulletin->GPC['buyout']) {
                  $db->query("update " . TABLE_PREFIX . "vbay_items SET highbidder = " . $vbulletin->userinfo['userid'] . ", price=buyitnowprice, bids = bids+'1', completetime = '0' WHERE id=" . $vbulletin->GPC['id'] . "");
                  $vbulletin->url = "vbay.php?do=item&viewitem=" . $vbulletin->GPC['id'] . $vbulletin->session->vars['sessionurl'] . "";
                  eval(print_standard_redirect('vbay_buy_success', true, true));
                    } else {
                  $db->query("update " . TABLE_PREFIX . "vbay_items SET highbidder = " . $vbulletin->userinfo['userid'] . ", bids = bids+'1', completetime = '0' WHERE id=" . $vbulletin->GPC['id'] . "");
                  $vbulletin->url = "vbay.php?do=item&viewitem=" . $vbulletin->GPC['id'] . $vbulletin->session->vars['sessionurl'] . "";
                  eval(print_standard_redirect('vbay_buy_success', true, true));
      }

Which ensures the price will equal the buyout price. Crude, but it works. I'm playing with the idea of adding another field to the database called BuyOutUsed for items bought with buyout.

Left would be automatically closing an auction as soon as the regular bidding price equals the buyout price.

Blaine0002 10-14-2009 06:19 PM

if the auction type is only buyout and the auction has ended, buyout price should be used automatically.

fairly sure i tested it... but you know how that goes...

vbulletin..pssssssh

AfterWorldForum 10-14-2009 06:49 PM

Quote:

Originally Posted by Blaine0002 (Post 1899866)
if the auction type is only buyout and the auction has ended, buyout price should be used automatically.

fairly sure i tested it... but you know how that goes...

vbulletin..pssssssh

Ah. I mostly tested with "both".

Blaine0002 10-14-2009 09:09 PM

Seeing as the new price range for vbulletin 4 is rediculously unrealistic... i will be releasing a final version for 3.8 then probably selling the rights and code to a coder who wants to continue to release it for newer versions of vbulletin.

Seeing as I dont run my own forum, there would be no reason to pay for it just to continue support on my addons.

DolphinEcho 10-16-2009 08:25 PM

I delete my other post as it changed so much, so thought I do a new one

Features I would like to see
  • When someone wins can the private message be change to include something about payment for example 'Contact the seller for payment details'
  • How about multiple options for payment methods for Example 'PayPal and Cash' etc... so maybe a tick box instead of a radio button maybe.
  • Would it be possible to have the Bid Increment start from 0.50 instal or 1.00 ?
  • Would it be possible to add a report feature like report a post ?
  • Would it be possible to add the thumbnail image if there is one to the bit with the title, price, type. etc...
  • Be able to search for items even if it only just by the title
  • User able to delete there advert

Is there any chance of, see any of these features in the final version ?


Thanks for a great mod :)

AfterWorldForum 10-21-2009 03:40 PM

Quick revision to my edit in post 1523.

One of my users found that someone had been able to bid less than the starting price, and it's due to me having been sloppy.

Quote:

And another edit further down. Look for:


Code:
Code:

                      if ($item['price'] + $item['inc'] > $vbulletin->GPC['bid']) {
                          eval(standard_error(fetch_error('vbay_bid_higher')));
                      }
              if ($item['bids'] > 0) {

Replace with:

Code:
Code:

              if ($item['bids'] > 0) {
                      if ($item['price'] + $item['inc'] > $vbulletin->GPC['bid']) {
                          eval(standard_error(fetch_error('vbay_bid_higher')));
                      }


I intended this to work and only insist the price + inc would be required after an initial bid was made. After all, if you're the first bidder on Ebay, you perfectly well can make an offer equal to the quoted startbid.

But my fix was incomplete. When there were no bids, it would be possible to bid whatever one liked. EVEN if that price was below the start price.

Luckily, the fix is also easy:

If you made the fix mentioned above, find this in the code:
Code:

              if ($item['bids'] > 0)
                                {
                      if ($item['price'] + $item['inc'] > $vbulletin->GPC['bid']) {
                          eval(standard_error(fetch_error('vbay_bid_higher')));
                      }
                  $pmhigh_bidder = $vbulletin->db->query("select * from " . TABLE_PREFIX . "user where userid='{$item['highbidder']}'");
                  $pmbidder = $vbulletin->db->fetch_array($pmhigh_bidder);
                  $title = "$vbphrase[vbay_pm_you_have_been_outbid] {$item['name']}";
                  $message = $vbphrase['vbay_pm_you_have_been_outbid_message'];
                  send_pm($vbulletin->userinfo['username'], $vbulletin->userinfo['userid'], $pmbidder['username'], $title, $message);
              }

Below that, add:
Code:

                          // Ensure that bid is higher thandesired opening bid
                          else
                          {
                                        if ($item['price'] > $vbulletin->GPC['bid']) {
                          eval(standard_error(fetch_error('vbay_bid_higher')));
                      }
                          }

A thousand pardons to everyone.

Still a great mod, though. Anxiously awaiting the next version. I might throw in some loggin features when the next version is available, but I figured I'd wait before going down that road.

By the way, will it be possible to somehow skip reimporting the languages and phrases? I reworded quite a bit, and would prefer keeping my edits :)


All times are GMT. The time now is 11:04 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.02271 seconds
  • Memory Usage 1,795KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (16)bbcode_code_printable
  • (2)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (4)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete