• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Tim Cooke
  • Devaka Cooray
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Rob Spoor
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Piet Souris
  • Mikalai Zaikin
Bartenders:
  • Carey Brown
  • Roland Mueller

need help from top Struts experts

 
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
This is app-config.xml file:

<SPCList level="default">
<column headerKey="SPC.hading.articlenr" handlerClass="model.column.ArticleNr" cssClass="spcartnr"/>
<column headerKey="SPC.heading.quantity" handlerClass="model.column.Quantity" cssClass="spcqty"/>
<column headerKey="SPC.heading.description" handlerClass="model.column.Description" cssClass="spcname"/>
<column headerKey="SPC.heading.actions" handlerClass="ACTIONICON" cssClass="spcai"/>
</SPCList>

This is a Model class (ArticleNr):
package model.column;

import ambo.jupiter.model.globalsearch.*;
import ambo.jupiter.model.spc.*;
import ambo.jupiter.model.shoppingcart.*;
import ambo.jupiter.context.UserContextIF;
import ambo.jupiter.model.spc.localsearch.LocalSearchItem;
import ambo.jupiter.util.SearchStringParser;
import ambo.jupiter.model.variant.VariantItem;
import ambo.jupiter.model.history.HistoryItem;

import java.util.List;


public class ArticleNr extends AbstractColumnHandler
{

//------------------------------------------------------------------------------
public ArticleNr()
{
}
//------------------------------------------------------------------------------
public ArticleNr( UserContextIF p_ciContext)
{
super( p_ciContext);
}
//------------------------------------------------------------------------------
public String formatField( VariantItem p_sc)
{
return p_sc.getArticleNr();
}



This is code of displayed page: itemlist.jsp

<!------------------------ result writing --------------------------------->
<c:forEach var="row" items="${SPCList.elements}">
<a name="<c ut value='${row.itemId}' />"></a>
<c:forEach var = "col" items="${ClientState.SPCColumnsLevel}">
<td class="<c ut value="${col.cssClass}" />" >
<c:choose>
<c:when test = "${col.handlerClass !='ACTIONICON' }">
<jupiter:renderColumn row="row" column="col" />
</c therwise>
</c:choose>
</td
</c:forEach>

columns:

| ArticleNr | Description | Quantity
--------------------------------------------------
rows: | 7383 | Servlet Programming | 0
| 7384 | Core Jsp | 0
| ... | ... | ...

Now, i want to add 1 column Quantity contains textboxes & 1 Shopping Cart button.
After i enter data (quantity which customer orders) into textboxes, click shoppingcart button, it will direct to ShoppingCart page with data has just entered from previous page.

Problems: Should i add a form contains Quantity data (in textbox) & a private Action.
If so, it will break app's architecture? I feel equivocal. Please show me.
If question isn't clear, please inform me.
I greatly appreciate your help.
 
If I'd had more time, I would have written a shorter letter. -T.S. Eliot such a short, tiny ad:
We need your help - Coderanch server fundraiser
https://coderanch.com/wiki/782867/Coderanch-server-fundraiser
reply
    Bookmark Topic Watch Topic
  • New Topic