当前位置: 首页>>代码示例>>C#>>正文


C# Feature.getID方法代码示例

本文整理汇总了C#中Feature.getID方法的典型用法代码示例。如果您正苦于以下问题:C# Feature.getID方法的具体用法?C# Feature.getID怎么用?C# Feature.getID使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Feature的用法示例。


在下文中一共展示了Feature.getID方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: getFeatureLines

 private string getFeatureLines(Feature ftr)
 {
     string retString = "";
     if (ftr.myChildren.Count > 0)
     {
         if (ftr.getPercentComplete() == 100)
         {
             retString += "<li title=\"" + ftr.getFeatureDescription() + "\"><table width=\"100%\"><tr><td align=\"left\">" + ftr.getFeatureName() + "&nbsp;&nbsp;<font color=\"green\"><i>" + ftr.getPercentComplete() + "%</i></font></td><td align=\"right\"><a class=\"google button blue\" href=\"?ID=" + ID + "&feat=" + ftr.getID() + "#addChildFeature\" title=\"Add New Sub-Objective\">+</a><a class=\"google button\" href=\"?ID=" + ID + "&feat=" + ftr.getID() + "#editChildFeature\" title=\"Edit Objective\">E</a></td></tr></table><ul><hr style=\"height:1px; margin:2px;\" />";
         }
         else
         {
             retString += "<li title=\"" + ftr.getFeatureDescription() + "\"><table width=\"100%\"><tr><td align=\"left\">" + ftr.getFeatureName() + "&nbsp;&nbsp;<font color=\"red\"><i>" + ftr.getPercentComplete() + "%</i></font></td><td align=\"right\"><a class=\"google button blue\" href=\"?ID=" + ID + "&feat=" + ftr.getID() + "#addChildFeature\" title=\"Add New Sub-Objective\">+</a><a class=\"google button\" href=\"?ID=" + ID + "&feat=" + ftr.getID() + "#editChildFeature\" title=\"Edit Objective\">E</a></td></tr></table><ul><hr style=\"height:1px; margin:2px;\" />";
         }
         foreach (Feature child in ftr.myChildren)
         {
             retString += getFeatureLines(child);
         }
         retString += "</ul></li>";
     }
     else
     {
         if (ftr.getPercentComplete() == 100)
         {
             retString += "<li title=\"" + ftr.getFeatureDescription() + "\"><table width=\"100%\"><tr><td align=\"left\">" + ftr.getFeatureName() + "&nbsp;&nbsp;<font color=\"green\"><i>" + ftr.getPercentComplete() + "%</i></font></td><td align=\"right\"><a class=\"google button blue\" href=\"?ID=" + ID + "&feat=" + ftr.getID() + "#addChildFeature\" title=\"Add New Sub-Objective\">+</a><a class=\"google button\" href=\"?ID=" + ID + "&feat=" + ftr.getID() + "#editChildFeature\" title=\"Edit Objective\">E</a><a class=\"google button red\" href=\"?ID=" + ID + "&feat=" + ftr.getID() + "#removeChildFeature\" title=\"Remove Objective\">&#215;</a></li></td></tr></table><hr style=\"height:1px; margin:2px;\" />";
         }
         else
         {
             retString += "<li title=\"" + ftr.getFeatureDescription() + "\"><table width=\"100%\"><tr><td align=\"left\">" + ftr.getFeatureName() + "&nbsp;&nbsp;<font color=\"red\"><i>" + ftr.getPercentComplete() + "%</i></font></td><td align=\"right\"><a class=\"google button blue\" href=\"?ID=" + ID + "&feat=" + ftr.getID() + "#addChildFeature\" title=\"Add New Sub-Objective\">+</a><a class=\"google button\" href=\"?ID=" + ID + "&feat=" + ftr.getID() + "#editChildFeature\" title=\"Edit Objective\">E</a><a class=\"google button red\" href=\"?ID=" + ID + "&feat=" + ftr.getID() + "#removeChildFeature\" title=\"Remove Objective\">&#215;</a><a class=\"google button green\" href=\"?ID=" + ID + "&feat=" + ftr.getID() + "#quickComplete\" title=\"Complete Objective\">&#x2713;</a></li></td></tr></table><hr style=\"height:1px; margin:2px;\" />";
         }
     }
     return retString;
 }
开发者ID:Ravai,项目名称:honey-badger,代码行数:32,代码来源:ViewTask.aspx.cs

示例2: Page_Load

    protected void Page_Load(object sender, EventArgs e)
    {
        MaintainScrollPositionOnPostBack = true;

        if (Request.QueryString["ID"] != null)
        {
            updateProjectPercent();

            ID = Request.QueryString["ID"].ToString();
            string IP = Request.ServerVariables["HTTP_X_FORWARDED_FOR"] ?? Request.ServerVariables["REMOTE_ADDR"];
            currentProject = new Project(int.Parse(ID));
            //DataTable DT = theCake.getTask(Int32.Parse(ID), theCake.getActiveUserName(IP));

            if (!currentProject.isValid)
            {
                Response.Redirect("Home.aspx");
            }

            //string ownerAlias = userClass.getUserAlias(Int32.Parse(DT.Rows[0]["ownerID"].ToString()));
            userClass projOwner = new userClass(currentProject.getOwnerID());
            if (theCake.getActiveUserName(IP) != projOwner.getOwnerAlias())
            {
                int userID = theCake.getUserID(theCake.getActiveUserName(IP));
                DataTable permissionChecker = theCake.getUserProjectPermissions(userID, Int32.Parse(ID));
                if (permissionChecker.Rows[0]["permission_Project_Write"].ToString() == "0")
                    ProjectWrite = false;
                if (permissionChecker.Rows[0]["permission_Board_Write"].ToString() == "0")
                    BoardWrite = false;
            }

            if (!ProjectWrite)
            {
                pnl_EditOperations.Visible = false;
                pnl_SpecialOptions.Visible = false;
            }
            if (!BoardWrite)
            {
                btn_AddComment.Visible = false;
            }

            lbl_TaskName.Text = currentProject.getTaskName(); //DT.Rows[0]["taskName"].ToString();
            lbl_Description.Text = currentProject.getTaskDescription(); //DT.Rows[0]["taskDescription"].ToString();
            lbl_projectOwner.Text = "<a href=\"UserProfile.aspx?userID=" + currentProject.getOwnerID() + "\">" + projOwner.getDisplayName();

            btn_ViewProjectReport.PostBackUrl = "printProjectReport.aspx?ID=" + Request.QueryString["ID"].ToString();
            btn_ViewMemberReport.PostBackUrl = "printMemberReport.aspx?ID=" + Request.QueryString["ID"].ToString();

            if (!IsPostBack)
            {
                txt_Edit_TaskName.Text = currentProject.getTaskName();
                txt_Edit_TaskDescription.Text = currentProject.getTaskDescription(); //DT.Rows[0]["taskDescription"].ToString();
            }
            lbl_ExpectedStart.Text = currentProject.getExpectedStart().ToShortDateString();
            lbl_ExpectedStop.Text = currentProject.getExpectedStop().ToShortDateString();

            if (currentProject.getActualStart() == DateTime.MinValue) lbl_ActualStart.Text = "Not Yet Started";
            else lbl_ActualStart.Text = currentProject.getActualStart().ToShortDateString();

            if (currentProject.getActualStop() == DateTime.MinValue) lbl_ActualStop.Text = "Not Yet Completed";
            else lbl_ActualStop.Text = currentProject.getActualStop().ToShortDateString();

            if (currentProject.getDoneFlag())
            {
                btn_markDone.Visible = false;
                btn_markWip.Visible = true;
                btn_UpgradeSize.Visible = false;

                AddComments.Visible = false;

                FillMilestones();
                getallBoards();
            }
            else
            {
                if (Request.QueryString["feat"] != null)
                {
                    if (!IsPostBack)
                    {
                        Feature ftr = new Feature(int.Parse(Request.QueryString["feat"].ToString()));
                        lbl_remChildFeature_Name.Text = ftr.getFeatureName();
                        lbl_remChildFeature_Description.Text = ftr.getFeatureDescription();
                        lbl_remChildFeature_PercentComplete.Text = ftr.getPercentComplete().ToString() + "%";
                        btnRemFeature.CommandArgument = ftr.getID().ToString();

                        txt_editChildFeature_Name.Text = ftr.getFeatureName();
                        txt_editChildFeature_Description.Text = ftr.getFeatureDescription();
                        for (int i = 0; i <= 100; i++)
                        {
                            ddl_editChildFeature_PercentComplete.Items.Add(i.ToString());
                        }
                        for (int i = 1; i <= 5; i++)
                        {
                            ddl_editChildFeature_Weight.Items.Add(i.ToString());
                            ddl_addChildFeature_Weight.Items.Add(i.ToString());
                        }
                        ddl_editChildFeature_PercentComplete.SelectedIndex = ftr.getPercentComplete();
                        ddl_editChildFeature_Weight.SelectedIndex = ftr.getWeight() - 1;

                        if (ftr.hasChildren)
                        {
//.........这里部分代码省略.........
开发者ID:Ravai,项目名称:honey-badger,代码行数:101,代码来源:ViewTask.aspx.cs


注:本文中的Feature.getID方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。