Start a new topic
Answered

Installation with empty Database

 Hello;


I realized some changes on the default Virto Commerce developper version application and now i'm looking to reinstall this solution with an empty database in order to create new store and have my own products before deploying in the Cloud.


I've already followed this tutorial :

To setup database go to ~\src\Extensions\Setup\VirtoCommerce.PowerShell\ folder and run Powershell script below.

without sample data:

setup-database.ps1 -useSample:$false

 

I've created one catalog, one store and now I get this error :

Server Error in '/store' Application.
The resource cannot be found.
Description: HTTP 404. The resource you are looking for (or one of its dependencies) could have been removed, had its name changed, or is temporarily unavailable.  Please review the following URL and make sure that it is spelled correctly.

Requested URL: /store/

 

Is there something missing ? Do I need to create items, products etc.. before?

Thank you in advance for your anwsers. Stephane

Edit: I think it's a rooting problem because when I launch the solution from Visual Studio, I have an exception in the StoreHttpModule.cs file:
protected virtual void OnBeginRequest(HttpContext context)
        {
            var store = GetStore(context);

            if (store == null)
            {
                throw new HttpException(404, "Store Not Found");
            }

 GetStore sets the store variable to null: it's why I have this exception.


Then, if I try to understand how this function works, I can see that the function try to know what the DefaultStore is...

The default store, which is "SampleStore", seems to be defined in the web.config. I change with the name of my store but it changes nothing... But finally I change with my Store ID and it works!


BUT... I wanted to have my store in french and to be on my store... the url looks like this:

http://localhost:2359/en-us/electronics


(why electronics? my database was empty except my things...)


If I try to go on my store I have the same error that I had before... HOW CAN I GO DIRECTLY ON THE STORE THAT I DEFINED? (

e.g http://localhost:2359/fr-fr/mystore)


EDIT2: Finally I succeed to configure my store in french. but now I have an other problem: I can't display the product I created before with VirtoCommerce Manager...





Best Answer

Hi, Stephane,
"New products" content is generated dynamically and it's configured separately. 

You can set up it manualy:

  1. create "HomeNewProducts" content place in Settings-> Content places 
  2. create "New Products" dynamic content in Marketing -> Dynamic content 
  3. create "New Products" content publishing in Marketing -> Content publishing 
  4. "New products" should appear where expected. 

You can connect to http://virtocommerce-test.cloudapp.net/ and use the data as a reference.

We'll include this script for "empty database" in upcoming VirtoCommerce release.



Can you explain what problem you have displaying the product? Is not visible when browsing the category or you can't open it directly, can you explain?

Hello,
My issue is that my product is not displayed in the Home Page on "Newest" area whereas we can see this same product on our category page : http://localhost/store/fr-fr/storename/category/test

 

It might be due product not being indexed by the search. To make sure indexing works, open commerce manager, go to settings, then search tab, select index called "catalogitem" and click REBUILD button. That should cause the index to rebuild. The status will change to "Never Started" at first. If you running store on your local machine, open the store website (it will kick off indexing) and check the status in the Commerce Manager, it should change to "started", after some time it will say completed. See if that fixes your issues.


No this don't fix my issue. I followed all your instructions, I got all status after Rebuild and now I don't see products in the Home Page on "Newest" area.You can see on attached files my index and category page where my products are listed.



index.jpg
(224 KB)
cat.jpg
(195 KB)

This now might be due to caching (you can modify web.config to reset caching or use Cache reset funcitonality in 1.10 version of VC). What version of VC do you have?

 I've the 1.9 version of VC manager. So I need to download the latest ?

No, 1.9 is fine since 1.10 hasn't been officially released yet. Just modify web.config (add remove space and save it). It will reset the cache, otherwise you might need to wait for 5 minutes or so before cache is auto reset.

I waited for 3 days so I don't think that it's the solution...

But when you talk about "remove space", what kind of code do I have to write?

 

Just add and remove any character, just as long as the file has been modified it will cause IIS to reset and refresh cache.

No it doesn't work sorry :/
Maybe there is an other solution?

 

Are you using ElasticSearch or Lucene as a search? It is specified inside connectionStrings.config file.

I use ElacticSearch

 

The dynamic content displaying new items simply executes the search where startdate is within 1 month of  today date. Can you check what is the StartDate for the new product?

I've already check the StartDate and it's ok... :/

 

Login or Signup to post a comment