Sfoglia il codice sorgente

上传文件至 ''

Joey 1 mese fa
parent
commit
a7589e66b6
3 ha cambiato i file con 79 aggiunte e 59 eliminazioni
  1. 6 2
      UICompany.cs
  2. 57 56
      UIFund.Designer.cs
  3. 16 1
      UIFund.cs

+ 6 - 2
UICompany.cs

@@ -569,6 +569,9 @@ namespace DataManager
     {
         protected override void OnPaint(PaintEventArgs e)
         {
+
+            //this.BackColor = Color.White;
+
             base.OnPaint(e);
             Graphics g = e.Graphics;
             g.SmoothingMode = System.Drawing.Drawing2D.SmoothingMode.AntiAlias;
@@ -587,8 +590,9 @@ namespace DataManager
                 g.DrawEllipse(deletePen, center.X - innerRadius, center.Y - innerRadius, diameter, diameter);
 
                 // 绘制两条相交的对角线
-                g.DrawLine(deletePen, center.X - innerRadius, center.Y + innerRadius, center.X + innerRadius, center.Y - innerRadius);
-                g.DrawLine(deletePen, center.X - innerRadius, center.Y - innerRadius, center.X + innerRadius, center.Y + innerRadius);
+                int offset = (int)Math.Floor(innerRadius / 1.4);
+                g.DrawLine(deletePen, center.X - innerRadius - offset, center.Y + innerRadius + offset, center.X + innerRadius + offset, center.Y - innerRadius - offset);
+                g.DrawLine(deletePen, center.X - innerRadius - offset, center.Y - innerRadius - offset, center.X + innerRadius + offset, center.Y + innerRadius + offset);
             }
 
         }

+ 57 - 56
UIFund.Designer.cs

@@ -57,6 +57,10 @@
             this.label9 = new System.Windows.Forms.Label();
             this.label7 = new System.Windows.Forms.Label();
             this.gpbFundEditing = new System.Windows.Forms.GroupBox();
+            this.cmbAssetFrequency = new System.Windows.Forms.ComboBox();
+            this.cmbNavFrequency = new System.Windows.Forms.ComboBox();
+            this.label12 = new System.Windows.Forms.Label();
+            this.label14 = new System.Windows.Forms.Label();
             this.cmbManagers = new System.Windows.Forms.ComboBox();
             this.cmbStrategy = new System.Windows.Forms.ComboBox();
             this.chkAuthorized = new System.Windows.Forms.CheckBox();
@@ -71,6 +75,7 @@
             this.label2 = new System.Windows.Forms.Label();
             this.tbpNav = new System.Windows.Forms.TabPage();
             this.panel1 = new System.Windows.Forms.Panel();
+            this.lblNavFrequency = new System.Windows.Forms.Label();
             this.label10 = new System.Windows.Forms.Label();
             this.dtpNavEndDate = new System.Windows.Forms.DateTimePicker();
             this.dtpNavStartDate = new System.Windows.Forms.DateTimePicker();
@@ -80,11 +85,6 @@
             this.grdNav = new System.Windows.Forms.DataGridView();
             this.tbpAsset = new System.Windows.Forms.TabPage();
             this.tbpRating = new System.Windows.Forms.TabPage();
-            this.lblNavFrequency = new System.Windows.Forms.Label();
-            this.cmbAssetFrequency = new System.Windows.Forms.ComboBox();
-            this.cmbNavFrequency = new System.Windows.Forms.ComboBox();
-            this.label12 = new System.Windows.Forms.Label();
-            this.label14 = new System.Windows.Forms.Label();
             ((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).BeginInit();
             this.splitContainer1.Panel1.SuspendLayout();
             this.splitContainer1.Panel2.SuspendLayout();
@@ -457,6 +457,48 @@
             this.gpbFundEditing.TabIndex = 0;
             this.gpbFundEditing.TabStop = false;
             // 
+            // cmbAssetFrequency
+            // 
+            this.cmbAssetFrequency.Enabled = false;
+            this.cmbAssetFrequency.FormattingEnabled = true;
+            this.cmbAssetFrequency.Location = new System.Drawing.Point(651, 67);
+            this.cmbAssetFrequency.Name = "cmbAssetFrequency";
+            this.cmbAssetFrequency.Size = new System.Drawing.Size(105, 25);
+            this.cmbAssetFrequency.TabIndex = 17;
+            // 
+            // cmbNavFrequency
+            // 
+            this.cmbNavFrequency.FormattingEnabled = true;
+            this.cmbNavFrequency.Items.AddRange(new object[] {
+            "周",
+            "天",
+            "月",
+            "未知"});
+            this.cmbNavFrequency.Location = new System.Drawing.Point(392, 67);
+            this.cmbNavFrequency.Name = "cmbNavFrequency";
+            this.cmbNavFrequency.Size = new System.Drawing.Size(121, 25);
+            this.cmbNavFrequency.TabIndex = 16;
+            // 
+            // label12
+            // 
+            this.label12.AutoSize = true;
+            this.label12.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.label12.Location = new System.Drawing.Point(583, 72);
+            this.label12.Name = "label12";
+            this.label12.Size = new System.Drawing.Size(56, 17);
+            this.label12.TabIndex = 14;
+            this.label12.Text = "规模频率";
+            // 
+            // label14
+            // 
+            this.label14.AutoSize = true;
+            this.label14.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.label14.Location = new System.Drawing.Point(313, 72);
+            this.label14.Name = "label14";
+            this.label14.Size = new System.Drawing.Size(56, 17);
+            this.label14.TabIndex = 15;
+            this.label14.Text = "净值频率";
+            // 
             // cmbManagers
             // 
             this.cmbManagers.FormattingEnabled = true;
@@ -604,6 +646,15 @@
             this.panel1.Size = new System.Drawing.Size(786, 47);
             this.panel1.TabIndex = 8;
             // 
+            // lblNavFrequency
+            // 
+            this.lblNavFrequency.AutoSize = true;
+            this.lblNavFrequency.Location = new System.Drawing.Point(527, 18);
+            this.lblNavFrequency.Name = "lblNavFrequency";
+            this.lblNavFrequency.Size = new System.Drawing.Size(61, 17);
+            this.lblNavFrequency.TabIndex = 8;
+            this.lblNavFrequency.Text = "Nav Freq";
+            // 
             // label10
             // 
             this.label10.AutoSize = true;
@@ -655,6 +706,7 @@
             this.btnAddNav.TabIndex = 3;
             this.btnAddNav.Text = "添 加";
             this.btnAddNav.UseVisualStyleBackColor = true;
+            this.btnAddNav.Click += new System.EventHandler(this.btnAddNav_Click);
             // 
             // label8
             // 
@@ -698,57 +750,6 @@
             this.tbpRating.Text = "评级";
             this.tbpRating.UseVisualStyleBackColor = true;
             // 
-            // lblNavFrequency
-            // 
-            this.lblNavFrequency.AutoSize = true;
-            this.lblNavFrequency.Location = new System.Drawing.Point(527, 18);
-            this.lblNavFrequency.Name = "lblNavFrequency";
-            this.lblNavFrequency.Size = new System.Drawing.Size(61, 17);
-            this.lblNavFrequency.TabIndex = 8;
-            this.lblNavFrequency.Text = "Nav Freq";
-            // 
-            // cmbAssetFrequency
-            // 
-            this.cmbAssetFrequency.Enabled = false;
-            this.cmbAssetFrequency.FormattingEnabled = true;
-            this.cmbAssetFrequency.Location = new System.Drawing.Point(651, 67);
-            this.cmbAssetFrequency.Name = "cmbAssetFrequency";
-            this.cmbAssetFrequency.Size = new System.Drawing.Size(105, 25);
-            this.cmbAssetFrequency.TabIndex = 17;
-            // 
-            // cmbNavFrequency
-            // 
-            this.cmbNavFrequency.FormattingEnabled = true;
-            this.cmbNavFrequency.Items.AddRange(new object[] {
-            "周",
-            "天",
-            "月",
-            "未知"});
-            this.cmbNavFrequency.Location = new System.Drawing.Point(392, 67);
-            this.cmbNavFrequency.Name = "cmbNavFrequency";
-            this.cmbNavFrequency.Size = new System.Drawing.Size(121, 25);
-            this.cmbNavFrequency.TabIndex = 16;
-            // 
-            // label12
-            // 
-            this.label12.AutoSize = true;
-            this.label12.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label12.Location = new System.Drawing.Point(583, 72);
-            this.label12.Name = "label12";
-            this.label12.Size = new System.Drawing.Size(56, 17);
-            this.label12.TabIndex = 14;
-            this.label12.Text = "规模频率";
-            // 
-            // label14
-            // 
-            this.label14.AutoSize = true;
-            this.label14.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label14.Location = new System.Drawing.Point(313, 72);
-            this.label14.Name = "label14";
-            this.label14.Size = new System.Drawing.Size(56, 17);
-            this.label14.TabIndex = 15;
-            this.label14.Text = "净值频率";
-            // 
             // UIFund
             // 
             this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);

+ 16 - 1
UIFund.cs

@@ -45,6 +45,8 @@ namespace DataManager
 
                 fundInfo = DataAccess.Get_dm_fund_information(fundId, null);
 
+                #region Basic Info
+
                 if (fundInfo == null || fundInfo.Rows.Count <= 0)
                 {
                     lblFundName.Text = string.Format("基金{0}不存在,得跟管理员说一下", fundId);
@@ -105,6 +107,10 @@ namespace DataManager
                 chkRanking.Checked = fundInfo.Rows[0]["is_ranking"].ToString() == "1" ? true : false;
                 chkAuthorized.Checked = fundInfo.Rows[0]["is_authorized"].ToString() == "1" ? true : false;
 
+                #endregion
+
+                #region Nav
+
                 dtpNavStartDate.ShowCheckBox = true;
                 dtpNavStartDate.Checked = false;
                 dtpNavStartDate.Value = DateTime.Parse(lblInceptionDate.Text);
@@ -112,9 +118,13 @@ namespace DataManager
                 dtpNavEndDate.ShowCheckBox = true;
                 dtpNavEndDate.Checked = false;
 
+                lblNavFrequency.Text = navFreq;
+
                 LoadNavGrid(null, null);
+
+                #endregion
             }
-        
+
         }
 
         private void LoadNavGrid(DateTime? startDate, DateTime? endDate)
@@ -163,5 +173,10 @@ namespace DataManager
 
 
         }
+
+        private void btnAddNav_Click(object sender, EventArgs e)
+        {
+
+        }
     }
 }