[ABD] Shop Mod (0.4.1)

Any abandoned MODs will be moved to this forum.

WARNING: MODs in this forum are not currently being supported or maintained by the original MOD author. Proceed at your own risk.
Forum rules
IMPORTANT: MOD Development Forum rules

WARNING: MODs in this forum are not currently being supported nor updated by the original MOD author. Proceed at your own risk.
Locked
User avatar
Phantom784
Registered User
Posts: 290
Joined: Wed Aug 08, 2007 3:09 am
Location: State College, PA
Contact:

Re: [ALPHA] Shop Mod (0.4.0b)

Post by Phantom784 »

Okay, I (re)re-released it, hopefully solving the auto-detection problem.
MOD Download: http://radoncube.com/mods/shop_mod_0.4.0b.zip

The problem was that when it auto-detected, it used the variable $old_version, but then when it went to give the notice, it used $oldversion.
Want to contact me? Find out how at http://francisfisher.com/contact.php
User avatar
Gleasonator
Registered User
Posts: 652
Joined: Tue Jun 05, 2007 2:19 pm
Location: Texas
Contact:

Re: [ALPHA] Shop Mod (0.4.0b)

Post by Gleasonator »

Phantom784 wrote:Okay, I (re)re-released it, hopefully solving the auto-detection problem.
MOD Download: http://radoncube.com/mods/shop_mod_0.4.0b.zip

The problem was that when it auto-detected, it used the variable $old_version, but then when it went to give the notice, it used $oldversion.
Ah hah! Now the installer works! Thank you. :D It is now running and I'm doing some testing with the new version.

So far I do notice that you forgot to define "ACP_PHANTOMS_MODS" (the ACP category name) in a language file, but that seems to be all. I'll reply again with feedback as soon as I test this stuff out.

Once again, thank you. :)
Sorry for my bad Engrish !
gleason|design

Image
User avatar
Gleasonator
Registered User
Posts: 652
Joined: Tue Jun 05, 2007 2:19 pm
Location: Texas
Contact:

Re: [ALPHA] Shop Mod (0.4.0b)

Post by Gleasonator »

OK, here's a bug.

When I update my shelf, all users shelfs look like mine. See here: http://gleasonator.com/forums/viewtopic ... 16&p=18977

It seems that there's only one shelf.

EDIT:

Also a small bug...

In the ACP when you're in the Shop Item Management page, if you type the name of your item into the box and click "Add object" the name doesn't carry over to the next page where you specify all your options. But if you retype it and submit, it works fine.

Not trying to be critical, by the way... I think you've done an amazing job. Just reporting anything I find so that you don't have to search for bugs yourself.
Sorry for my bad Engrish !
gleason|design

Image
ihermit
Registered User
Posts: 251
Joined: Wed Mar 05, 2008 4:26 am

Re: [ALPHA] Shop Mod (0.4.0b)

Post by ihermit »

Gleasonator wrote:OK, here's a bug.

When I update my shelf, all users shelfs look like mine. See here: http://gleasonator.com/forums/viewtopic ... 16&p=18977

It seems that there's only one shelf.

EDIT:

Also a small bug...

In the ACP when you're in the Shop Item Management page, if you type the name of your item into the box and click "Add object" the name doesn't carry over to the next page where you specify all your options. But if you retype it and submit, it works fine.

Not trying to be critical, by the way... I think you've done an amazing job. Just reporting anything I find so that you don't have to search for bugs yourself.
Yup, I was just about to post these :)
Also, Thanks for the help yesterday phantom, you went above and beyond!
robdec
Registered User
Posts: 65
Joined: Thu Jan 18, 2007 3:00 am

Re: [ALPHA] Shop Mod (0.4.0b)

Post by robdec »

I have downloaded 4.0 and 4.0b and they both seem to be missing this file per your install doc. I don't see this file in the zip anywhere.

root/language/en/mods/info_ucp_shop.php,
User avatar
Phantom784
Registered User
Posts: 290
Joined: Wed Aug 08, 2007 3:09 am
Location: State College, PA
Contact:

Re: [ALPHA] Shop Mod (0.4.0b)

Post by Phantom784 »

robdec wrote:I have downloaded 4.0 and 4.0b and they both seem to be missing this file per your install doc. I don't see this file in the zip anywhere.

root/language/en/mods/info_ucp_shop.php,
Don't worry about that file, you don't need it. I was using it at one point and accidentally left its in the installer file, and it must have been carried over to the new version.

And for the bug with only "one shelf", it looks like, for whoever is logged in, they will see their own shelf under every user's posts. To fix, find the line

Code: Select all

$items = $shop->get_item_list_user(null, 'shelf_display = true');
in viewtopic.php and replace it with

Code: Select all

$items = $shop->get_item_list_user($poster_id, 'shelf_display = true');
Want to contact me? Find out how at http://francisfisher.com/contact.php
ihermit
Registered User
Posts: 251
Joined: Wed Mar 05, 2008 4:26 am

Re: [ALPHA] Shop Mod (0.4.0b)

Post by ihermit »

Thanks for the fix :)

Also, maybe in the next version you could make it so that you can buy items for other people, with a message?
That'd be great!
robdec
Registered User
Posts: 65
Joined: Thu Jan 18, 2007 3:00 am

Re: [ALPHA] Shop Mod (0.4.0b)

Post by robdec »

OK I have it all working but when I display an item on the shelf the page loads very slow or I get this error

Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 71 bytes) in /home/mysite/domains/mysite.com/public_html/includes/template.php on line 345
User avatar
Phantom784
Registered User
Posts: 290
Joined: Wed Aug 08, 2007 3:09 am
Location: State College, PA
Contact:

Re: [ALPHA] Shop Mod (0.4.0b)

Post by Phantom784 »

robdec wrote:OK I have it all working but when I display an item on the shelf the page loads very slow or I get this error

Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 71 bytes) in /home/mysite/domains/mysite.com/public_html/includes/template.php on line 345
are you using the latest release, 0.4.0b?
Want to contact me? Find out how at http://francisfisher.com/contact.php
User avatar
Gleasonator
Registered User
Posts: 652
Joined: Tue Jun 05, 2007 2:19 pm
Location: Texas
Contact:

Re: [ALPHA] Shop Mod (0.3.0)

Post by Gleasonator »

Gleasonator wrote:Sorry about my last post. That was an issue with the cash mod that I resolved.

I have a bug to submit, though. I've found that, using a simple URL query, anyone can obtain cash points by selling items that they don't have to the shop, and they can also drain the quantity of items.

If you submit the query: http://yoursite.com/forums/shop.php?mode=buy&item=item_id

Then choose that you would like to purchase the item, it will tell you that you cannot and wont let you, but the stock of the item still decreases by 1.

What's worse, though, is that with this query: http://yoursite.com/forums/ucp.php?i=shop&mode=inventory&action=sellback&item=item_id

A user can "sell" back an item that he or she doesn't have. It will increase the stock of that item in the shop by 1 point, and will give the user who submitted that query as much cash as the item is worth. This is especially bad when the item has a very large sellback price. Any user could take over the whole shop by using this method.

EDIT: I think the best way to resolve this is to a make seperate PHP file for the shop, and one for actually purchasing the item.
Hm... these bugs still exist.

Let me be more specific...

Here's an item in my shop:

Image
(Click for full image)

Notice that it has a quantity of 1, and I don't have the sufficient money to purchase it. Because of this, there is no "Buy" link. However, there is a buy link above it:

Image

And if I right-click the "Buy" link above it and click "Properties" I get this:

Image

Notice how "item=4" in the URL. Logically, if that item=4 and the item below the one we're dealing with, item=6, the one we want MUST be 5.

So we type this in:

Image

And it leads us to:

Image

Click yes:

Image

It did not let me purchase it. It does NOT show up in my UCP. However, look at it back in the shop:

Image

The quantity is now 0 and it's sold out.

Something similar to this can be done via a user's UCP, and they can sell back items that they don't have by replacing item ID's in the URL.
Sorry for my bad Engrish !
gleason|design

Image
MydnyteSyn
Registered User
Posts: 383
Joined: Sun Oct 07, 2007 10:02 am

Re: [ALPHA] Shop Mod (0.4.0b)

Post by MydnyteSyn »

I'm paying attention to the development of this mod as I hope to use it one day. I have a question though. With this mod, can admins set a shop or item to be group-specific only so only members of a particular group are allowed to 'purchase' certain items?

My husband and I have a role-playing community that is set in a medieval/fantasy world. We have quite a few guilds. Mages, for example, will need to buy spell components, scrolls, etc for their potions and magics, but we only want members of the mages guild to be able to purchase these items. A thief in the thieves guild, for example, would not have any uses for spell components or magic potions so we don't want them to be able to purchase these.
robdec
Registered User
Posts: 65
Joined: Thu Jan 18, 2007 3:00 am

Re: [ALPHA] Shop Mod (0.4.0b)

Post by robdec »

Phantom784 wrote:
robdec wrote:OK I have it all working but when I display an item on the shelf the page loads very slow or I get this error

Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 71 bytes) in /home/mysite/domains/mysite.com/public_html/includes/template.php on line 345
are you using the latest release, 0.4.0b?

Yes I went from 3.0 to 4.0b . Any idea on what can be causing it?

If I open a thread that only has 1 reply from me then it works but if it has 4 or more replys I get that error.
User avatar
Scriptmaster10
Registered User
Posts: 107
Joined: Mon Aug 29, 2005 5:47 pm
Location: The Heart of England

Re: [ALPHA] Shop Mod (0.4.0b)

Post by Scriptmaster10 »

Updated to 4b - can't actually see anything in the ACP to do with shops. When I had version 3 there were tabs at the top. I readded the modules via the "System" tab but still nothing is showing up....

UPDATE::

I cleared the cache and now the links show up. When I try to configure:
[phpBB Debug] PHP Notice: in file /includes/acp/acp_shop_mod.php on line 545: Undefined index: points_enable
Second update:

I changed

if ($config['points_enable'])

to

Else if ($config['points_enable'])

In acp_shop_mod.php and its smoothed out. Now I have a new problem - sig shelf is not displaying

Third Update

When I try to add an "Object" I get:

Code: Select all

[phpBB Debug] PHP Notice: in file /adm/index.php on line 276: Undefined index: name
[phpBB Debug] PHP Notice: in file /adm/index.php on line 276: Undefined index: description
[phpBB Debug] PHP Notice: in file /adm/index.php on line 345: Undefined index: backend
[phpBB Debug] PHP Notice: in file /adm/index.php on line 345: Undefined index: icon
[phpBB Debug] PHP Notice: in file /adm/index.php on line 276: Undefined index: price
[phpBB Debug] PHP Notice: in file /adm/index.php on line 276: Undefined index: sell_price
[phpBB Debug] PHP Notice: in file /adm/index.php on line 276: Undefined index: quantity
[phpBB Debug] PHP Notice: in file /adm/index.php on line 294: Undefined index: can_trash
[phpBB Debug] PHP Notice: in file /adm/index.php on line 295: Undefined index: can_trash
[phpBB Debug] PHP Notice: in file /adm/index.php on line 294: Undefined index: can_sellback
[phpBB Debug] PHP Notice: in file /adm/index.php on line 295: Undefined index: can_sellback
[phpBB Debug] PHP Notice: in file /adm/index.php on line 294: Undefined index: instant_use
[phpBB Debug] PHP Notice: in file /adm/index.php on line 295: Undefined index: instant_use
[phpBB Debug] PHP Notice: in file /adm/index.php on line 294: Undefined index: can_display
[phpBB Debug] PHP Notice: in file /adm/index.php on line 295: Undefined index: can_display
azzam
Registered User
Posts: 345
Joined: Sat May 03, 2008 11:33 am

Re: [ALPHA] Shop Mod (0.4.0b)

Post by azzam »

I want to ask some questions .

Can i use this mod as this>

I select some things like < mobile,Computer any thing in real > And select the amount of item.

and if user has amount for that thing so he can buy that and he get his/her item in control panel....

And when any user buy any item < Forum founder automatically receive message.

IS MOD CATEGORY AND SUB CATEGORY WISE?
Azzam Malik
I love mods :)
User avatar
Gleasonator
Registered User
Posts: 652
Joined: Tue Jun 05, 2007 2:19 pm
Location: Texas
Contact:

Re: [ALPHA] Shop Mod (0.4.0b)

Post by Gleasonator »

azzam wrote:I want to ask some questions .

Can i use this mod as this>

I select some things like < mobile,Computer any thing in real > And select the amount of item.

and if user has amount for that thing so he can buy that and he get his/her item in control panel....

And when any user buy any item < Forum founder automatically receive message.

IS MOD CATEGORY AND SUB CATEGORY WISE?
1. You can add any kind of item you want to the shop. You just need to find an icon for each item.

2. You can set an amount to be paid. But in order to do this, you must also have the Cash Mod or Simple Points System mod installed.

3. If the user has the amount, they can buy it from a new page called shop.php and can manage items in their control panel.

4. At the moment, the founder can NOT receive a message when a user purchases an item.

5. No, neither. Right now there is only one main category. But in the future it is likely that there will be categories.
Sorry for my bad Engrish !
gleason|design

Image
Locked

Return to “[3.0.x] Abandoned MODs”