Package cn.edu.pku.dr.requirement.elicitation.data

Examples of cn.edu.pku.dr.requirement.elicitation.data.ProblemreasonEvaluation


    }

    public String getProblemreasonNotByGroup(Long userId,
            ArrayList problemreasons) throws EasyJException {
        StringBuffer buffer = new StringBuffer();
        ProblemreasonEvaluation pre = new ProblemreasonEvaluation();
        Problemreason pr = new Problemreason();
        SingleDataProxy sdp = SingleDataProxy.getInstance();
        ProblemreasonSolution prs = new ProblemreasonSolution();
        ProblemreasonSolution prs2 = new ProblemreasonSolution();
        buffer.append("<div class=\"bc0\" style=\"padding:0px 0pt;\">");
        String solution = "";
        if (problemreasons.size() > 0) {
            for (int i = 0; i < problemreasons.size(); i++) {
                pr = (Problemreason) problemreasons.get(i);
                prs.setProblemreasonId(pr.getProblemreasonId());
                ArrayList prss = sdp.query(prs);
                if (prss.size() > 0) {
                    for (int j = 0; j < prss.size(); j++) {
                        prs2 = (ProblemreasonSolution) prss.get(j);
                        solution = solution + ","
                                + prs2.getProblemreasonSolutionId();
                    }
                    buffer
                            .append("<div class=\"f14 p90 pl10\" class=\"answer_content\">"
                                    + pr.getProblemreasonContent() + "</div>");
                    buffer.append("<p></p>共有" + sdp.getCount(prs)
                            + "个解决方案,对应的解决方案为" + solution + "<p></p>");
                    solution = "";

                } else {
                    buffer
                            .append("<div id=\"Lg\" ></div><div class=\"f14 p90 pl10\" class=\"answer_content\">"
                                    + pr.getProblemreasonContent()
                                    + "</div><p></p>目前无该原因的解决方案,<A class=brown12  href=\"javascript:Problemsolution.loadNewSolution("
                                    + pr.getProblemId()
                                    + ")\">添加一个?</A><p></p>");

                }

                boolean flag = true;
                int j = 0;
                ArrayList pres = pr.getProblemreasonEvaluations();
                while (flag == true && j < pres.size()) {
                    pre = (ProblemreasonEvaluation) pres.get(j);
                    if (pre.getCreatorId().intValue() == userId.intValue()) {
                        flag = false;

                    }
                    j++;
                }
View Full Code Here


    public void problemreasonUpdate() throws EasyJException, IOException {
        ProblemReasonImpl targetObject = new ProblemReasonImpl();
        ProblemReasonInterface problemreasonInterface = null;
        Object proxy = ProblemReasonProxyFactory.getProxy(targetObject);
        problemreasonInterface = (ProblemReasonInterface) proxy;
        ProblemreasonEvaluation pre = new ProblemreasonEvaluation();
        pre = (ProblemreasonEvaluation) object;
        response.setContentType("text/xml");
        response.getWriter().write(
                problemreasonInterface.problemreasonUpdate(pre, this.request,
                        response).toString());
View Full Code Here

TOP

Related Classes of cn.edu.pku.dr.requirement.elicitation.data.ProblemreasonEvaluation

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.