if (order.equals("time")) {
// 原本就是按照时间排序的
} else {
Collections.sort(ambiguities);
}
Ambiguity ambiguity = new Ambiguity();
int allnum = 0;
int num0 = 0;
buffer
.append("<TABLE class=f9 id=newsTable cellSpacing=0 cellPadding=0 width=\"100%\" align=center bgColor=#ffffff border=0><TBODY>");
buffer
.append("<TR bgColor=#f3f3f3><TD class=tdline28 noWrap width=\"5%\"></TD> <TD class=tdline28 width=\"14%\" height=30><b>有歧义</b></TD><TD class=tdline28 width=\"1%\"> </TD><TD class=tdline28><B>用户疑问概要</B></TD><TD class=tdline28 width=\"15%\"><B> </B></TD></TR>");
for (int i = 0; i < ambiguities.size(); i++) {
ambiguity = (Ambiguity) ambiguities.get(i);
if (ambiguity.getIsoverdue().equals("N")
&& ambiguity.getAmbiguityTypeId().intValue() == 0) {
num0++;
buffer
.append("<TR id=trBG"
+ allnum
+ "><TD class=tdline28 noWrap align=left ><INPUT onclick=\"Problem.changeTRbg(this,'trBG"
+ allnum
+ "')\" type=\"checkbox\" value=\""
+ ambiguity.getAmbiguityId()
+ "\" name=\"overdue_ambiguity\"></TD><TD class=tdline28 align=left>"
+ num0 + "</TD>");
if (ambiguity.getAmbiguityContent().length() > 10) {
buffer
.append("<TD class=tdline28 align=right> </TD><TD class=tdline28 align=left >"
+ ambiguity.getAmbiguityContent()
.substring(0, 9) + "....</TD>");
} else {
buffer
.append("<TD class=tdline28 align=right> </TD><TD class=tdline28 align=left >"
+ ambiguity.getAmbiguityContent() + "</TD>");
}
buffer
.append("<TD class=tdline28 noWrap align=left><A class=\"bluelink \" href=\"javascript:Problem.newsShowHide('ambiguity"
+ allnum + "');\">查看详细描述</A></TD></TR> ");
buffer
.append("<TR><TD class=tdline28 id=ambiguity"
+ allnum
+ " style=\"DISPLAY: none\" noWrap align=left colSpan=5><BR><TABLE class=zh cellSpacing=0 cellPadding=0 width=\"96%\" align=center border=0><TBODY><TR><TD>");
buffer
.append("<DIV id=MSGcontent"
+ allnum
+ "><div id=\"Lg\"></div><div class=\"f14 p90 pl10\" class=\"answer_content\" ><span style=\"color:#FF0000\">详细描述:</span><br>"
+ ambiguity.getAmbiguityContent());
buffer
.append("<br><IMG src=\"/image/flower.gif\">(共<SPAN id=\"flower_num\">"
+ ambiguity.getGoodNum() + "</SPAN>支)");
buffer
.append("<IMG height=15 src=\"/image/badegg.gif\" width=16>(共<SPAN class=orange12>"
+ ambiguity.getBadNum() + "</SPAN>个)");
buffer
.append("</DIV><BR></TD><TD vAlign=top noWrap align=right width=50><FONT id=close0><A class=bluelink onclick=\"Problem.newsShowHide('ambiguity"
+ allnum
+ "')\" href=\"#\">关闭</A></FONT></TD></TR></TBODY></TABLE>");
allnum++;
}
}
if (num0 == 0) {
buffer
.append("<TR ><TD class=tdline28 noWrap width=\"5%\"></TD> <TD class=tdline28 width=\"14%\" height=30><b></b></TD><TD class=tdline28 width=\"1%\"> </TD><TD class=tdline28><B>评论已失效或无此类评论</B></TD><TD class=tdline28 width=\"15%\"><B> </B></TD></TR>");
buffer
.append("</TBODY></TABLE><DIV id=rt0></DIV><BR></TD></TR></TBODY></TABLE>");
} else {
buffer.append("<DIV id=rt0></DIV><BR></TD></TR></TBODY></TABLE>");
}
int num1 = 0;
buffer
.append("<TABLE class=f9 id=newsTable cellSpacing=0 cellPadding=0 width=\"100%\" align=center bgColor=#ffffff border=0><TBODY>");
buffer
.append("<TR bgColor=#f3f3f3><TD class=tdline28 noWrap width=\"5%\"></TD> <TD class=tdline28 width=\"14%\" height=30><b>不易理解</b></TD><TD class=tdline28 width=\"1%\"> </TD><TD class=tdline28><B>用户疑问概要</B></TD><TD class=tdline28 width=\"15%\"><B> </B></TD></TR>");
for (int i = 0; i < ambiguities.size(); i++) {
ambiguity = (Ambiguity) ambiguities.get(i);
if (ambiguity.getIsoverdue().equals("N")
&& ambiguity.getAmbiguityTypeId().intValue() == 1) {
num1++;
buffer
.append("<TR id=trBG"
+ allnum
+ "><TD class=tdline28 noWrap align=left ><INPUT onclick=\"Problem.changeTRbg(this,'trBG"
+ allnum
+ "')\" type=\"checkbox\" value=\""
+ ambiguity.getAmbiguityId()
+ "\" name=\"overdue_ambiguity\"></TD><TD class=tdline28 align=left>"
+ num1 + "</TD>");
if (ambiguity.getAmbiguityContent().length() > 10) {
buffer
.append("<TD class=tdline28 align=right> </TD><TD class=tdline28 align=left >"
+ ambiguity.getAmbiguityContent()
.substring(0, 9) + "....</TD>");
} else {
buffer
.append("<TD class=tdline28 align=right> </TD><TD class=tdline28 align=left >"
+ ambiguity.getAmbiguityContent() + "</TD>");
}
buffer
.append("<TD class=tdline28 noWrap align=left><A class=\"bluelink \" href=\"javascript:Problem.newsShowHide('ambiguity"
+ allnum + "');\">查看详细描述</A></TD></TR> ");
buffer
.append("<TR><TD class=tdline28 id=ambiguity"
+ allnum
+ " style=\"DISPLAY: none\" noWrap align=left colSpan=5><BR><TABLE class=zh cellSpacing=0 cellPadding=0 width=\"96%\" align=center border=0><TBODY><TR><TD>");
buffer
.append("<DIV id=MSGcontent"
+ allnum
+ "><div id=\"Lg\"></div><div class=\"f14 p90 pl10\" class=\"answer_content\" ><span style=\"color:#FF0000\">详细描述:</span><br>"
+ ambiguity.getAmbiguityContent());
buffer
.append("<br><IMG src=\"/image/flower.gif\">(共<SPAN id=\"flower_num\">"
+ ambiguity.getGoodNum() + "</SPAN>支)");
buffer
.append("<IMG height=15 src=\"/image/badegg.gif\" width=16>(共<SPAN class=orange12>"
+ ambiguity.getBadNum() + "</SPAN>个)");
buffer
.append("</DIV><BR></TD><TD vAlign=top noWrap align=right width=50><FONT id=close0><A class=bluelink onclick=\"Problem.newsShowHide('ambiguity"
+ allnum
+ "')\" href=\"#\">关闭</A></FONT></TD></TR></TBODY></TABLE>");
allnum++;
}
}
if (num1 == 0) {
buffer
.append("<TR ><TD class=tdline28 noWrap width=\"5%\"></TD> <TD class=tdline28 width=\"14%\" height=30><b></b></TD><TD class=tdline28 width=\"1%\"> </TD><TD class=tdline28><B>评论已失效或无此类评论</B></TD><TD class=tdline28 width=\"15%\"><B> </B></TD></TR>");
buffer
.append("</TBODY></TABLE><DIV id=rt0></DIV><BR></TD></TR></TBODY></TABLE>");
} else {
buffer.append("<DIV id=rt0></DIV><BR></TD></TR></TBODY></TABLE>");
}
int num2 = 0;
buffer
.append("<TABLE class=f9 id=newsTable cellSpacing=0 cellPadding=0 width=\"100%\" align=center bgColor=#ffffff border=0><TBODY>");
buffer
.append("<TR bgColor=#f3f3f3><TD class=tdline28 noWrap width=\"5%\"></TD> <TD class=tdline28 width=\"14%\" height=30><b>易理解</b></TD><TD class=tdline28 width=\"1%\"> </TD><TD class=tdline28><B>用户疑问概要</B></TD><TD class=tdline28 width=\"15%\"><B> </B></TD></TR>");
for (int i = 0; i < ambiguities.size(); i++) {
ambiguity = (Ambiguity) ambiguities.get(i);
if (ambiguity.getIsoverdue().equals("N")
&& ambiguity.getAmbiguityTypeId().intValue() == 2) {
num2++;
buffer
.append("<TR id=trBG"
+ allnum
+ "><TD class=tdline28 noWrap align=left ><INPUT onclick=\"Problem.changeTRbg(this,'trBG"
+ allnum
+ "')\" type=\"checkbox\" value=\""
+ ambiguity.getAmbiguityId()
+ "\" name=\"overdue_ambiguity\"></TD><TD class=tdline28 align=left>"
+ num2 + "</TD>");
if (ambiguity.getAmbiguityContent().length() > 10) {
buffer
.append("<TD class=tdline28 align=right> </TD><TD class=tdline28 align=left >"
+ ambiguity.getAmbiguityContent()
.substring(0, 9) + "....</TD>");
} else {
buffer
.append("<TD class=tdline28 align=right> </TD><TD class=tdline28 align=left >"
+ ambiguity.getAmbiguityContent() + "</TD>");
}
buffer
.append("<TD class=tdline28 noWrap align=left><A class=\"bluelink \" href=\"javascript:Problem.newsShowHide('ambiguity"
+ allnum + "');\">查看详细描述</A></TD></TR> ");
buffer
.append("<TR><TD class=tdline28 id=ambiguity"
+ allnum
+ " style=\"DISPLAY: none\" noWrap align=left colSpan=5><BR><TABLE class=zh cellSpacing=0 cellPadding=0 width=\"96%\" align=center border=0><TBODY><TR><TD>");
buffer
.append("<DIV id=MSGcontent"
+ allnum
+ "><div id=\"Lg\"></div><div class=\"f14 p90 pl10\" class=\"answer_content\" ><span style=\"color:#FF0000\">详细描述:</span><br>"
+ ambiguity.getAmbiguityContent());
buffer
.append("<br><IMG src=\"/image/flower.gif\">(共<SPAN id=\"flower_num\">"
+ ambiguity.getGoodNum() + "</SPAN>支)");
buffer
.append("<IMG height=15 src=\"/image/badegg.gif\" width=16>(共<SPAN class=orange12>"
+ ambiguity.getBadNum() + "</SPAN>个)");
buffer
.append("</DIV><BR></TD><TD vAlign=top noWrap align=right width=50><FONT id=close0><A class=bluelink onclick=\"Problem.newsShowHide('ambiguity"
+ allnum
+ "')\" href=\"#\">关闭</A></FONT></TD></TR></TBODY></TABLE>");
allnum++;