管理员端查询条件优化,用户库存/选品界面新增查询功能
This commit is contained in:
1 parent
77ec460f4d
commit
9bbdddefb6
14 files changed
+1165
-548
No files matched your search
@@ -24,11 +24,20 @@ namespace TemuKJD.KJDForms.AdminForms
|
||||
{
|
||||
public partial class AdminShopListForm : BaseForm
|
||||
{
|
||||
static AdminShopListForm inst = null;
|
||||
public static AdminShopListForm Instance
|
||||
{
|
||||
get { if (inst == null) inst = new AdminShopListForm(); return inst; }
|
||||
set { inst = value; }
|
||||
}
|
||||
|
||||
public static List<ShopLoginInfo> lstAdminShopInfo { get; set; } = new List<ShopLoginInfo>();
|
||||
|
||||
public AdminShopListForm()
|
||||
{
|
||||
InitializeComponent();
|
||||
|
||||
Instance = this;
|
||||
}
|
||||
|
||||
private void AdminShopForm_Load(object sender, EventArgs e)
|
||||
@@ -333,16 +342,16 @@ namespace TemuKJD.KJDForms.AdminForms
|
||||
|
||||
private List<string> GetCheckedList()
|
||||
{
|
||||
List<string> shopNameList = new List<string>();
|
||||
List<string> shopLoginNameList = new List<string>();
|
||||
for (int i = 0; i < dgvShop.Rows.Count; i++)
|
||||
{
|
||||
if (dgvShop.Rows[i].Cells["colSelect"].Value.ParseToBool())
|
||||
{
|
||||
string shopName = dgvShop.Rows[i].Cells["colLoginName"].Value.ParseToString();
|
||||
shopNameList.Add(shopName);
|
||||
shopLoginNameList.Add(shopName);
|
||||
}
|
||||
}
|
||||
return shopNameList;
|
||||
return shopLoginNameList;
|
||||
}
|
||||
|
||||
private List<string> GetCheckedShopIdList()
|
||||
@@ -556,8 +565,8 @@ namespace TemuKJD.KJDForms.AdminForms
|
||||
{
|
||||
if (this.btnCheck.Text == "检测选中")
|
||||
{
|
||||
List<string> shopNameList = GetCheckedList();
|
||||
if (!shopNameList.Any())
|
||||
List<string> shopLoginNameList = GetCheckedList();
|
||||
if (!shopLoginNameList.Any())
|
||||
{
|
||||
BaseMsgForm.ShowError("请选择需要检测的店铺");
|
||||
return;
|
||||
@@ -565,7 +574,7 @@ namespace TemuKJD.KJDForms.AdminForms
|
||||
|
||||
Task.Run(() =>
|
||||
{
|
||||
CheckShopListLogin(shopNameList.Distinct().ToArray());
|
||||
CheckShopListLogin(shopLoginNameList.Distinct().ToArray());
|
||||
SearchShop(this.ucSplitPage1.CurrentPage);
|
||||
});
|
||||
}
|
||||
@@ -574,9 +583,9 @@ namespace TemuKJD.KJDForms.AdminForms
|
||||
/// <summary>
|
||||
/// 检测店铺授权状态
|
||||
/// </summary>
|
||||
/// <param name="shopNames"></param>
|
||||
/// <param name="shopLoginNames"></param>
|
||||
/// <param name="isShowProgress"></param>
|
||||
public void CheckShopListLogin(string[] shopNames, bool isShowProgress = true)
|
||||
public void CheckShopListLogin(string[] shopLoginNames, bool isShowProgress = true)
|
||||
{
|
||||
if (isShowProgress)
|
||||
{
|
||||
@@ -584,12 +593,12 @@ namespace TemuKJD.KJDForms.AdminForms
|
||||
{
|
||||
this.pbLoading.Visible = true;
|
||||
this.statusBar.lblTaskStatus.Text = "正在检测...";
|
||||
this.statusBar.pgbTaskProgress.Maximum = shopNames.Length;
|
||||
this.statusBar.pgbTaskProgress.Maximum = shopLoginNames.Length;
|
||||
this.statusBar.UpdateProgressBar(0);
|
||||
}));
|
||||
}
|
||||
|
||||
var shops = lstAdminShopInfo.Where(s => shopNames.Contains(s.LoginName));
|
||||
var shops = lstAdminShopInfo.Where(s => shopLoginNames.Contains(s.LoginName));
|
||||
CheckShopLogin(shops.ToArray(), isShowProgress);
|
||||
|
||||
if (this.Created && isShowProgress)
|
||||
|
||||
Reference in new issue
Block a user