Kryptronic Software Support Forum

You are viewing this forum as a guest. Login to an existing account, or create a new account, to reply to topics and to create new topics.

#1 05-28-2003 05:43:09

Jack
Member
Registered: 05-25-2003
Posts: 105

How do you INSERT a new product BETWEEN existing products?

Every so often I want to add a new product and want it to appear on the splash and store home pages BETWEEN certain items that I've previously entered.

How do I do this?

(Please don't tell me the only way is to delete all existing product records from the point of insertion to the end of the product list... That would be TOO lame!)

Nick, If this option if not present in the admin panel oughtta be added to the features list for next version update.

I assume that somehow the order of appearance can be juggled by moving some code around, but I haven't a clue how to do that.

Thanks for any hacks for this!

Jack

Offline

 

#2 05-28-2003 21:49:05

Todd
Member
From: Kitty Hawk, NC
Registered: 04-01-2003
Posts: 553
Website

Re: How do you INSERT a new product BETWEEN existing products?

I don't believe you can do this yet with CCP however there are some hacks to sort items alphabetically.

So as long as you name your stuff with that in mind you can get some sorting control.

See <A HREF="https://forum.kryptronic.com/viewtopic.php?id=987">https://forum.kryptronic.com/viewtopic.php?id=987</A>


there's more than one way to...



Offline

 

#3 05-29-2003 01:00:34

Jack
Member
Registered: 05-25-2003
Posts: 105

Re: How do you INSERT a new product BETWEEN existing products?

Thanks for the comment Todd, that's what I feared.

What I NEED is to be able to CONTROL THE ORDER ITEMS ARE DISPLAYED IN THE STORE, and to be able to EDIT THIS ORDER and by "EDIT" I don't mean deleting 15 items from the product list to add one and then have to RE-enter those 15 items after the fact.

I'm a little amazed no one has requested this feature before.

Thanks again for your comments...

Nick, I hope you read this...
Dude, what IS the hack for being able to do this?

Thanks,
Jack

Offline

 

#4 05-29-2003 16:08:46

BooBoo
Member
From: Anaheim, CA
Registered: 07-25-2003
Posts: 147
Website

Re: How do you INSERT a new product BETWEEN existing products?

Actually,  the way to do this is simple.

If you are using MySQL, change the file to product.csv.  Then modify config_product.csv and at the bottom of the file, add a column, for example, product_sort_order.  You may want to add additional sort columns to give more granular sorting options.

If you are on *nix, please edit the file on a pc with notepad.

Then change the file to be MySQL.  This will import the new field and create it in MySQL.

You can populate the new field with the sort order that you want either in the csv file or in the database.

Then modify the code that displays the products by including the order by statement, which will list the products in the order that you want.


--
Keith Roberts
IT Manager
Laptops For Less, Inc
keith@getadeal.com
<a href="http://www.laptopsforless.com">Your source for laptop batteries, pda batteries, digital camera batteries, cell phone batteries, and accessories</a>

Offline

 

#5 05-29-2003 18:46:30

Jack
Member
Registered: 05-25-2003
Posts: 105

Re: How do you INSERT a new product BETWEEN existing products?

Outstanding!

Thanks ONCE AGAIN for a great tip...

You rock, Boo! :-)

Jack

Offline

 

#6 05-29-2003 18:56:32

Todd
Member
From: Kitty Hawk, NC
Registered: 04-01-2003
Posts: 553
Website

Re: How do you INSERT a new product BETWEEN existing products?

>Actually,  the way to do
>this is simple.
>
>If you are using MySQL, change
>the file to product.csv. 
>Then modify config_product.csv and at
>the bottom of the file,
>add a column, for example,
>product_sort_order.  You may want
>to add additional sort columns
>to give more granular sorting
>options.
>
>If you are on *nix, please
>edit the file on a
>pc with notepad.
>
>Then change the file to be
>MySQL.  This will import
>the new field and create
>it in MySQL.
>
>You can populate the new field
>with the sort order that
>you want either in the
>csv file or in the
>database.
>
>Then modify the code that displays
>the products by including the
>order by statement, which will
>list the products in the
>order that you want.


Wouldn't this mean that you have to constantly go back to your csv file or mysql database table and manually enter in the product numbers?  Is their a hack to have this included in the admin product form so that a person could just add a product number (that would serve as the sorting field) and be done with it?

Sorry... I'm a bit green around here.


there's more than one way to...



Offline

 

#7 05-29-2003 22:31:28

Jack
Member
Registered: 05-25-2003
Posts: 105

Re: How do you INSERT a new product BETWEEN existing products?

Sure sounds like the kind of feature I'd like, to deal with this.

We MUST have "random access" control of the product order, and not just sequential access based on order of entry.

Please, Nick?

Thanks for the post!

JJ

Offline

 

Board footer