日期:2014-05-17 浏览次数:20988 次
//初始化
function initWorkDetailInfo(){
var workNo = '<%=request.getAttribute("workNo")%>';
var sIndex = 0;
$.get("<%=request.getContextPath()%>/<%=PFMConstants.PFM_MODULE_WORKS_ASSIGN%>/initWorkDetailInfo.htm",//URL
{workNo:workNo},//傳入的參數
function(data, textStatus){//回調方法
var workDetailLists = JSON.parse(data);
var html = "";
if(workDetailLists.length > 0){
//隱藏列標題
document.getElementById("headTitle").style.display = "";
}
$.each(workDetailLists,function(index,comm){
[color=#FF0000]alert(comm.subWorkStatus == '230002');[/color]
html+="<tr class='table-odd-row' id='shihuangzhe'>"
+"<td class='table-other-column'><a href='javascript:void(0)' onclick='remove(this,\""+workDetailLists[index].responsiblePersonAccount+"\", \""+workDetailLists[index].responsiblePerson+"\")'><img src='${ctx}/images/u78.png' width='16' height='16' border='0' alt='刪除'></a></td>"
+"<td class='table-string-column'><input type='text' class='textbox_char_120' name='workDetailInfoList["+sIndex+"].responsiblePerson' value='"+workDetailLists[index].responsiblePerson+"' readonly='readonly'><input type='hidden' name='workDetailInfoList["+sIndex+"].responsiblePersonAccount' value='"+workDetailLists[index].responsiblePersonAccount+"'></td>"
+"<td class='table-string-column'><input type='text' class='textbox_char_120' name='workDetailInfoList["+sIndex+"].subWorkName' value='"+workDetailLists[index].subWorkName+"'></td>"
+"<td class='table-string-column'><input type='text' class='textbox_char_120' name='workDetailInfoList["+sIndex+"].subEstimateEffort' value='"+workDetailLists[index].subEstimateEffort+"'></td>"
+"<td class='table-num-column'><select name='workDetailInfoList["+sIndex+"].subWorkStatus' class='dropdownlist'><option value='230001' <c:if test="${comm.subWorkStatus == '230001'}">selected</c:if>>未完成</option><option value='230002' [color=#FF0000]<c:if test="${comm.subWorkStatus == '230002'}">selected</c:if>[/color]>已完成</option></select></td>"
+"<td class='table-string-column'><input type='text' class='textbox_char_120' name='workDetailInfoList["+sIndex+"].subComment' value='"+workDetailLists[index].subComment+"'></td>"
+"</tr>";
});
$("#tab1 tbody").html(html);
});
return false;
}