示例#1
0
        internal UpdateSite(NetlifyClient client, string siteId, SiteSetup siteSetup)
            : base(client, NetlifyClient.SitesEndpoint.Append(siteId), new HttpMethod("PATCH"))
        {
            if (string.IsNullOrEmpty(siteId))
            {
                throw new ArgumentException("A site ID must be provided", nameof(siteId));
            }

            Body        = siteSetup ?? throw new ArgumentNullException(nameof(siteSetup));
            _getRequest = ct => base.GetRequest(ct);
        }
示例#2
0
        private void dxNavBarItemSiteSetup_LinkClicked(object sender, DevExpress.XtraNavBar.NavBarLinkEventArgs e)
        {
            for (int i = 0; i < this.MdiChildren.Length; i++)
            {
                if (this.MdiChildren[i].Name == "SiteSetup")
                {
                    this.MdiChildren[i].BringToFront();
                    return;
                }
            }

            SiteSetup frm = new SiteSetup();

            frm.MdiParent = this;
            frm.Show();
        }
示例#3
0
 internal CreateSite(NetlifyClient client, SiteSetup siteSetup)
     : base(client, NetlifyClient.SitesEndpoint, HttpMethod.Post)
 {
     Body = siteSetup;
 }
示例#4
0
 public UpdateSite UpdateSite(string siteId, SiteSetup siteSetup) => new UpdateSite(this, siteId, siteSetup);
示例#5
0
 public CreateSite CreateSite(SiteSetup siteSetup) => new CreateSite(this, siteSetup);