I want to do following things in dashcommerce.(as a beginner).
Admin can add the products.
Customers can select these products and them to there cart.
After
that i'll write a webservice that will get all the latest orders from
the dashcommerce DB and display it in a desktop application
I made following steps:
1)Add some Products in the Databse using Admin Role (Done).
2)Now i want to login as a customer so i rgisterd myself as a customer. After login I Choose One of the products that was displayed on the left side of the page. (Done)
3)Now I want to add this and some other products in my cart for this I clicked on the "Add To Cart" Button on the top right side of the page.(At this point i am unsuccessfull to add this to the cart and cart contains a value of 0.
also
I added some of the products there manufatcurers and categories. I set all the attributes for the product. Store_Product_Category_Map,
Store_Product, Store_ProductStatusDescriptor, Store_ProductType,Store_Category,Store_Image,Store_Manufacturer, tables are properly filled with the data supplied during the add product cycle.
Now the problem is that when i login and choose some products and click on the "Add To Cart" button it doesn't add anything to code. Neither the table
Store_Order nor relted tables are updated. How can i achieve that.
I modidfied this method in J:\Bilal Haider\Dashcommerce\dc_3.0_Source_B\Store\Controllers\Generated\OrderController.cs which is readonly.
I undo those changes but still the code is not debugging due to change. How can i rebuild the dll's after change. How can i modify these. I know these are generated through subsonic. I think there should be a way to modify code. As the Following procedure always return 0. (What could be problem?).
public OrderCollection FetchByQuery(Query qry)
{
OrderCollection coll = new OrderCollection();
coll.LoadAndCloseReader(qry.ExecuteReader());
// I modified here then undo those changes.
return coll;
}
Also i modified following method in the J:\Bilal Haider\Dashcommerce\dc_3.0_Source_B\Store\Controllers\Generated\OrderController.cs which is readonly.
public Order FetchOrder(string userName) {
Order order = new Order();
Query query = new Query(Order.Schema).
AddWhere(Order.Columns.UserName, userName);
// AddWhere(Order.Columns.OrderStatusId, (int)OrderStatus.NotProcessed);
//OrderCollection orderCollection = this.FetchByQuery(query);
DataSet ds = new DataSet();
ds = query.ExecuteDataSet();
if(ds.Tables[0].Rows.Count>1)
{
//if(orderCollection.Count > 1){
throw new InvalidOperationException(EXCEPTION_TOO_MANY_CARTS);
}
//if(orderCollection.Count == 1) {
if(ds.Tables[0].Rows.Count==1)
{
DataTable dt = new DataTable();
dt.Rows.Add(ds.Tables[0].Rows[0]);
int count = dt.Rows.Count;
}
return order;
}
Now the problem is that i can't debug the code in these methods. And how can i achive the above mentioned goals?
Please help me. 