商品选品 更新类目 子账户单独批量修改 及其他功能

This commit is contained in:
wule committed 2026-03-23 20:34:05 +08:00
1 parent 8e919b0bd7
commit 52220daa8b
46 files changed
+4960 -211

No files matched your search

+36 -7
View File
@@ -72,7 +72,36 @@ namespace TemuKJD.UserComponent
this.Move += UcComboBoxMutiSelect_Move;
this.Resize += UcComboBoxMutiSelect_Resize;
this.SizeChanged += UcComboBoxMutiSelect_SizeChanged;
this.VisibleChanged += UcComboBoxMutiSelect_VisibleChanged;
this.ParentChanged += UcComboBoxMutiSelect_ParentChanged;
this.Disposed += UcComboBoxMutiSelect_Disposed;
});
}
private void UcComboBoxMutiSelect_Disposed(object sender, EventArgs e)
{
if (lblX != null)
lblX.Dispose();
}
private void UcComboBoxMutiSelect_ParentChanged(object sender, EventArgs e)
{
//lblX.Parent.Controls.Remove(lblX);
//lblX.Dispose();
//lblX = null;
if (this != null && !this.IsDisposed && this.Parent != null)
{
this.GetParentNotTable().Controls.Add(lblX);
UpdateClearLabel();
}
}
private void UcComboBoxMutiSelect_VisibleChanged(object sender, EventArgs e)
{
if (lblX != null && lblX.Visible != this.Visible)
lblX.Visible = this.Visible;
}
private void UcComboBoxMutiSelect_SizeChanged(object sender, EventArgs e)
@@ -92,7 +121,7 @@ namespace TemuKJD.UserComponent
private void UpdateClearLabel()
{
if (lblX == null)
if (lblX == null || lblX.Disposing || lblX.IsDisposed)
{
lblX = new Label();
lblX.Click += LblX_Click;
@@ -106,11 +135,11 @@ namespace TemuKJD.UserComponent
lblX.Width = 15;
lblX.Height = 19;
lblX.SendToBack();
Form form = this.FindForm();
form.Controls.Add(lblX);
//Form form = this.FindForm();
//form.Controls.Add(lblX);
this.GetParentNotTable().Controls.Add(lblX);
}
Point relativeLocation = this.GetRelativePosition();
//lblX.Location = new Point(relativeLocation.X + this.Width - 19 - lblX.Width, relativeLocation.Y + (this.Height - lblX.Height) / 2);
Point relativeLocation = this.GetRelativePosition(this.GetParentNotTable());
lblX.Location = new Point(relativeLocation.X + this.Width - 19 - lblX.Width, relativeLocation.Y + (this.Height - lblX.Height) / 2);
lblX.BringToFront();
}
@@ -125,7 +154,7 @@ namespace TemuKJD.UserComponent
else
{
this.lblX.Text = "×";
this.Text = "全部";
this.Text = DefaultText;
}
}
@@ -176,7 +205,7 @@ namespace TemuKJD.UserComponent
for (int index = 0; index < checkedListBox.Items.Count; index++)
{
var item = checkedListBox.Items[index];
if (this.Text == "全部" || this.Text.Split(new string[] { ";", ";", ",", "," }, StringSplitOptions.RemoveEmptyEntries).Contains(item.ParseToString()))
if (this.Text == DefaultText || this.Text.Split(new string[] { ";", ";", ",", "," }, StringSplitOptions.RemoveEmptyEntries).Contains(item.ParseToString()))
checkedListBox.SetItemChecked(index, true);
else
checkedListBox.SetItemChecked(index, false);