async void OnAddUser(object sender, Mi e) { var dlg = new SelectUserDlg(); long roleID = _lvRole.SelectedRow.ID; if (await dlg.Show(roleID, e)) { List <long> users = new List <long>(); foreach (var row in dlg.SelectedItems.OfType <Row>()) { users.Add(row.ID); } if (users.Count > 0 && await AtCm.AddRoleUser(roleID, users)) { _lvUser.Data = await AtCm.Query("角色-关联用户", new { roleid = roleID }); } } }