protected void Page_Load(object sender, EventArgs e)
        {
            string buildNumber = this.Request.QueryString[BUILD_NUMBER_QUERY_STRING_KEY];
            if (buildNumber != null) {
                this.Build = DataProvider.Instance.GetBuild(buildNumber);
            }

            if (this.Build == null) {
                this.Response.Redirect("~/Builds.aspx");
            }
        }
Example #2
0
        /// <summary>
        /// Occurs when the page loads.
        /// </summary>
        protected void Page_Load(object sender, EventArgs e)
        {
            _buildsDataGrid.Columns[6].Visible = AuthenticationHelper.IsAuthenticated;

            this.LatestStableBuild = DataProvider.Instance.GetLatestStableBuild();
            _downloadAreaPlaceholder.Visible = this.LatestStableBuild != null;

            BindingList<Build> builds = DataProvider.Instance.GetBuilds(20);
            _buildsDataGrid.DataSource = builds;
            _buildsDataGrid.DataBind();
        }
        protected void Page_Load(object sender, EventArgs e)
        {
            string buildNumber = this.Request.QueryString[BUILD_NUMBER_QUERY_STRING_KEY];
            if (buildNumber != null) {
                this.Build = DataProvider.Instance.GetBuild(buildNumber);
            }

            if (this.Build == null) {
                this.Response.Redirect("~/Builds.aspx");
            }

            if (!this.IsPostBack) {
                _publicCheckbox.Checked = this.Build.IsPublic;
                _successfulCheckBox.Checked = this.Build.IsSuccessful;
            }
        }
        public void UploadBuild(string username, string password, string buildNumber, DateTime buildDate, bool isSuccessful, string buildStatus, string version, bool isPublic, string releaseNotes, 
            string sourceCodeUrl, 
            string installerUrl,
            string clickOnceUrl)
        {
            Authenticate(username, password);

            Build build = new Build();
            build.BuildNumber = buildNumber;
            build.BuildDate = buildDate;
            build.Downloads = 0;
            build.BuildStatus = buildStatus;
            build.SourceCodeUrl = sourceCodeUrl;
            build.InstallerUrl = installerUrl;
            build.ClickOnceUrl = clickOnceUrl;
            build.IsPublic = isPublic;
            build.IsSuccessful = isSuccessful;
            build.ReleaseNotes = releaseNotes;
            build.Version = new Version(version);

            DataProvider.Instance.SaveBuild(build);
        }
 public void SaveBuild(Build build)
 {
     Helper.ExecuteNonQuery(
         Helper.CreateCommand("[TrialBalanceBuildSystem].[SaveBuild]",
             Helper.CreateParameter("@buildNumber", build.BuildNumber),
             Helper.CreateParameter("@buildDate", build.BuildDate),
             Helper.CreateParameter("@isSuccessful", build.IsSuccessful),
             Helper.CreateParameter("@buildStatus", build.BuildStatus),
             Helper.CreateParameter("@releaseNotes", build.ReleaseNotes),
             Helper.CreateParameter("@majorVersion", build.MajorVersion),
             Helper.CreateParameter("@minorVersion", build.MinorVersion),
             Helper.CreateParameter("@buildVersion", build.BuildVersion),
             Helper.CreateParameter("@revisionVersion", build.RevisionVersion),
             Helper.CreateParameter("@downloads", build.Downloads),
             Helper.CreateParameter("@isPublic", build.IsPublic),
             Helper.CreateParameter("@sourceCodeUrl", build.SourceCodeUrl),
             Helper.CreateParameter("@installerUrl", build.InstallerUrl),
             Helper.CreateParameter("@clickOnceUrl", build.ClickOnceUrl)
         ));
 }