diff --git a/B3WeChat/Rpcs/ClientRpc.cs b/B3WeChat/Rpcs/ClientRpc.cs index eee813b..a2c32ef 100644 --- a/B3WeChat/Rpcs/ClientRpc.cs +++ b/B3WeChat/Rpcs/ClientRpc.cs @@ -49,10 +49,10 @@ namespace BWP.B3WeChat.Rpcs static string GetOpenId(string username) { string customer = GetDeviceNumber(); - var query = new DQueryDom(new JoinAlias(typeof(QRCode))); - query.Columns.Add(DQSelectColumn.Field("OppenId")); - query.Where.Conditions.Add(DQCondition.EQ("Customer", customer)); - query.Where.Conditions.Add(DQCondition.EQ("UserId", username)); + var query = new DQueryDom(new JoinAlias(typeof(CustomerUser))); + query.Columns.Add(DQSelectColumn.Field("OpenID")); + query.Where.Conditions.Add(DQCondition.EQ("CustomerCode", customer)); + query.Where.Conditions.Add(DQCondition.EQ("CustomerUsername", username)); query.Range = SelectRange.Top(1); var OppenId = query.EExecuteScalar(); if (string.IsNullOrEmpty(OppenId))