old mode 100755
new mode 100644
Binary files differ
old mode 100755
new mode 100644
Binary files differ
| | |
| | | 72=The address of the residence |
| | | 73=Floor Management |
| | | 74=Room Management |
| | | 75=Administrator migration |
| | | 76=Administrator privilege migration |
| | | 75=Admin Migration |
| | | 76=Privilege Migration |
| | | 77=Debugging privilege |
| | | 78=The administrator is migrated to other user. |
| | | 79=All of the data for the residence is migrated to new user. |
| | | 79=All residence data are migrated to new user. |
| | | 80=Allow the staff to visit your home remotely |
| | | 81=Floor |
| | | 82=Add floor |
| | |
| | | 1140=Expire time should not be more than 72 hours |
| | | 1141=Expire time should not be less than 1 hour |
| | | 1142=Fail to set, please try again |
| | | |
| | | 1143=Fail to verify administrator ID, please log in again account |
| | | 1144=Your residence is being migrated to other HDL |
| | | 1145=Note: |
| | | 1146=1. All of your residence data will be migrate to new user.{0}2. After migration, original member will be{0}automatically unbound from this residence.{0}3. The new account is a valid HDL one.{0}4. The account from receiver cannot be the same{0}as that from migration side. |
| | | 1147=Confirm |
| | | 1148=Input receiver's account |
| | | 1149=Profile |
| | | 1150=Confirm admin migration from {0} to {1} |
| | | 1151=The account does not exist. |
| | | 1152=Fail to Transfer Ownership to Yourself |
| | | 1153=Terminate |
| | | 1154=正在过户给用户,请稍后... |
| | | |
| | | 5000=Music |
| | | 5001=Group |
| | |
| | | 1140=失效时间不能大于72小时 |
| | | 1141=失效时间不能小于1小时 |
| | | 1142=常开模式关闭设置失效,请重试 |
| | | 1143=管理员身份验证失败,请重新登录 |
| | | 1144=您的住宅将过户给其他HDL账号 |
| | | 1145=请注意: |
| | | 1146=1.该住宅您的数据(云端数据)将全部转移给新的户主{0}2.过户后,原有的成员将自动解绑该住宅{0}3.新户主账号为有效的HDL账号{0}4.接收方账号与转移方账号不可为同一个账号 |
| | | 1147=确认过户 |
| | | 1148=请输入接收方账号 |
| | | 1149=个人资料 |
| | | 1150=确认过户{0}的管理员账号给账号{1} |
| | | 1151=目标账号并不存在 |
| | | 1152=不能自己过户给自己 |
| | | 1153=终止 |
| | | 1154=正在过户给用户,请稍后... |
| | | |
| | | 4000=可视对讲 |
| | | 4001=通话记录 |
| | |
| | | /// 常开模式关闭设置失效,请重试 |
| | | /// </summary> |
| | | public const int AlwayOnFailTimeSettionFailMsg = 1142; |
| | | |
| | | /// <summary> |
| | | /// 管理员身份验证失败,请重新登录 |
| | | /// </summary> |
| | | public const int CheckAdminFailAndLoginAgain = 1143;
|
| | | /// <summary> |
| | | /// 您的住宅将过户给其他HDL账号 |
| | | /// </summary> |
| | | public const int YourHomeWillBeTransferredToOtherAccounts = 1144;
|
| | | /// <summary> |
| | | /// 请注意: |
| | | /// </summary> |
| | | public const int Attention = 1145;
|
| | | /// <summary> |
| | | /// 1.该住宅您的数据(云端数据)将全部转移给新的户主{0}2.过户后,原有的成员将自动解绑该住宅{0}3.新户主账号为有效的HDL账号{0}4.接收方账号与转移方账号不可为同一个账号 |
| | | /// </summary> |
| | | public const int TransferreConfirmMsg1 = 1146;
|
| | | /// <summary>
|
| | | /// 确认过户
|
| | | /// </summary>
|
| | | public const int ConfirmTransferre = 1147;
|
| | | /// <summary>
|
| | | /// 请输入接收方账号
|
| | | /// </summary>
|
| | | public const int PleaseInputReceiverAccount = 1148; |
| | | /// <summary>
|
| | | /// 个人资料
|
| | | /// </summary> |
| | | public const int Profile = 1149;
|
| | | /// <summary>
|
| | | /// 确认过户{0}的管理员账号给账号{1}
|
| | | /// </summary> |
| | | public const int TransferreConfirmMsg2 = 1150;
|
| | | /// <summary>
|
| | | /// 目标账号并不存在
|
| | | /// </summary> |
| | | public const int TargetAcountDoesNotExist = 1151;
|
| | | /// <summary> |
| | | /// 不能自己过户给自己 |
| | | /// </summary> |
| | | public const int YouCannotTransferOwnershipToYourself = 1152; |
| | | /// <summary>
|
| | | /// 终止
|
| | | /// </summary> |
| | | public const int Terminate = 1153;
|
| | | /// <summary>
|
| | | /// 正在过户给用户,请稍后...
|
| | | /// </summary> |
| | | public const int IsTransferingPleaseWaitting = 1154; |
| | | |
| | | |
| | | public const int keshiduijiang = 4000; |
| | |
| | | return HttpUtil.RequestHttpsPost(NewAPI.API_POST_Member_UnbindWithAccount, requestJson).Code; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 根据账号,获取账号信息 |
| | | /// </summary> |
| | | /// <param name="i_account">指定账号</param> |
| | | /// <returns></returns> |
| | | public ResponsePackNew GetMemberInfoByAccount(string i_account) |
| | | { |
| | | var pra = new { account = i_account }; |
| | | var requestJson = HttpUtil.GetSignRequestJson(pra); |
| | | return HttpUtil.RequestHttpsPost(NewAPI.API_POST_Member_GetMemberInfoByAccount, requestJson); |
| | | } |
| | | |
| | | #endregion |
| | | |
| | | #region 住宅部分 |
| | |
| | | isAllowCreateScene = isAllow, |
| | | }); |
| | | return HttpUtil.RequestHttpsPostFroHome(NewAPI.API_POST_Child_Update, requestJson); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 过户 |
| | | /// </summary> |
| | | /// <param name="i_account">对方账号</param> |
| | | /// <returns></returns> |
| | | public bool TransferResidence(string i_account) |
| | | { |
| | | var pra2 = new |
| | | { |
| | | homeId = Entity.DB_ResidenceData.Instance.CurrentRegion.id, |
| | | account = i_account |
| | | }; |
| | | var requestJson = HttpUtil.GetSignRequestJson(pra2); |
| | | var result = HttpUtil.RequestHttpsPost(NewAPI.API_Post_TransferResidence, requestJson); |
| | | |
| | | return result != null && result.Code == StateCode.SUCCESS; |
| | | } |
| | | |
| | | #region 新数据分享 |
| | |
| | | } |
| | | #endregion |
| | | |
| | | #region ■ 门锁历史记录________________________ |
| | | #region ■ 门锁相关____________________________ |
| | | |
| | | /// <summary> |
| | | /// 获取门锁历史记录(按日期降序) |
| | |
| | | /// <returns></returns> |
| | | public List<Stan.DoorHistoryLog> GetDoorHistoryLogs(Function i_device) |
| | | { |
| | | //var dicPra = new Dictionary<string, object>(); |
| | | //dicPra.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id); |
| | | //dicPra.Add("deviceId", i_device.deviceId); |
| | | //dicPra.Add("logType", "OPEN_DOOR"); |
| | | //dicPra.Add("pageSize", "200"); |
| | | //var requestJson = HttpUtil.GetSignRequestJson(dicPra); |
| | | //var packData = HttpUtil.RequestHttpsPostFroHome(NewAPI.API_POST_DoorHistory, requestJson); |
| | | //if (packData.Code != StateCode.SUCCESS) |
| | | //{ |
| | | // return null; |
| | | //} |
| | | |
| | | |
| | | //测试 |
| | | var listLog = new List<Stan.DoorHistoryLog>(); |
| | | for (int i = 1; i <= 3; i++) |
| | |
| | | /// 更新个人信息 |
| | | /// </summary> |
| | | public const string API_POST_Member_UpdateMemberInfo = "/smart-footstone/member/memberInfo/updateMemberInfo"; |
| | | /// <summary> |
| | | /// 根据账号获取个人信息 |
| | | /// </summary> |
| | | public const string API_POST_Member_GetMemberInfoByAccount = "/smart-footstone/member/memberInfo/getMemberInfoByAccount"; |
| | | ///// <summary> |
| | | ///// 上传头像 |
| | | ///// </summary> |
| | |
| | | /// 更改住宅权限 |
| | | /// </summary> |
| | | public const string API_Post_Home_UpdateDebugPerm = "/home-wisdom/app/home/updateDebugPerm"; |
| | | /// <summary> |
| | | /// 过户 |
| | | /// </summary> |
| | | public const string API_Post_TransferResidence = "/home-wisdom/app/home/transfer"; |
| | | |
| | | #endregion |
| | | |
| | | #region ■ 子账号 -- 添加住宅成员___________________________ |
| | |
| | | public const string API_POST_FL_QRcode = "http://112.74.164.111:180/api.php/Device/setdynamicpwd"; |
| | | #endregion |
| | | |
| | | #region ■ -- 门锁相关接口_______________________________ |
| | | |
| | | /// <summary> |
| | | /// 判断门锁是否第一使用 |
| | | /// </summary> |
| | | public const string API_POST_DoorisFirstUse = "/home-wisdom/app/device/door/isUserBind"; |
| | | /// <summary> |
| | | /// 门锁第一次使用时,绑定的密码 |
| | | /// </summary> |
| | | public const string API_POST_DoorBindFirstUsePsw = "/home-wisdom/app/device/door/userBind"; |
| | | /// <summary> |
| | | /// 获取门锁所有的密码 |
| | | /// </summary> |
| | | public const string API_POST_GetDoorAllPsw = "/home-wisdom/app/device/door/getPwds"; |
| | | /// <summary> |
| | | /// 门锁分配密码给用户 |
| | | /// </summary> |
| | | public const string API_POST_DoorAssignPswToUser = "/home-wisdom/app/device/door/pwdAllot"; |
| | | /// <summary> |
| | | /// 门锁的历史记录 |
| | | /// </summary> |
| | | public const string API_POST_DoorHistory = "/home-wisdom/app/device/door/logs"; |
| | | |
| | | #endregion |
| | | } |
| | | |
| | | ///// <summary> |
| | |
| | | <Compile Include="$(MSBuildThisFileDirectory)UI\UI0-Stan\Logic\HdlBluetoothIOSLogic.cs" />
|
| | | <Compile Include="$(MSBuildThisFileDirectory)UI\UI0-Stan\Logic\HdlCheckLogic.cs" />
|
| | | <Compile Include="$(MSBuildThisFileDirectory)UI\UI0-Stan\Logic\HdlCommonLogic.cs" />
|
| | | <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\4-PersonalCenter\RoomListManage\Transfer\TransferingResidencePage.cs" />
|
| | | <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\4-PersonalCenter\RoomListManage\Transfer\TransferResidenceResultPage.cs" />
|
| | | <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\FuntionControlView\DoorLock\DoorLockAlwaysOnManagerPage.cs" />
|
| | | <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\FuntionControlView\DoorLock\DoorLockAlwaysOnListPage.cs" />
|
| | | <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\FuntionControlView\DoorLock\DoorLockExpireTimeSettionPage.cs" />
|
| | |
| | | <Folder Include="$(MSBuildThisFileDirectory)DAL\DriverLayer\" />
|
| | | <Folder Include="$(MSBuildThisFileDirectory)UI\UI2\4-PersonalCenter\AboutOn\" />
|
| | | <Folder Include="$(MSBuildThisFileDirectory)UI\UI2\4-PersonalCenter\GetSupport\" />
|
| | | <Folder Include="$(MSBuildThisFileDirectory)UI\UI2\4-PersonalCenter\RoomListManage\Transfer\" />
|
| | | <Folder Include="$(MSBuildThisFileDirectory)UI\UI2\4-PersonalCenter\RoomListManage\AddRoom\" />
|
| | | <Folder Include="$(MSBuildThisFileDirectory)UI\BindingResidence\" />
|
| | | <Folder Include="$(MSBuildThisFileDirectory)Common\Utlis\" />
|
| | |
| | | |
| | | namespace HDL_ON.Stan |
| | | { |
| | | #region ■ 成员信息类__________________________ |
| | | |
| | | /// <summary> |
| | | /// 获取账号的信息的结果 |
| | | /// </summary> |
| | | public class AccountInfoResult |
| | | { |
| | | /// <summary> |
| | | /// 账号(如果是长度为0的字符串,则代表这个账号在云端不存在,需要手动赋值) |
| | | /// </summary> |
| | | public string Account = string.Empty; |
| | | /// <summary> |
| | | /// 账号的id(应该是主键) |
| | | /// </summary> |
| | | public string MemberId = string.Empty; |
| | | /// <summary> |
| | | /// 用户昵称 |
| | | /// </summary> |
| | | public string MemberName = string.Empty; |
| | | /// <summary> |
| | | /// 地区码 |
| | | /// </summary> |
| | | public string MemberPhonePrefix = string.Empty; |
| | | /// <summary> |
| | | /// 邮箱 |
| | | /// </summary> |
| | | public string MemberEmail = string.Empty; |
| | | /// <summary> |
| | | /// 手机号 |
| | | /// </summary> |
| | | public string MemberPhone = string.Empty; |
| | | /// <summary> |
| | | /// 头像地址 |
| | | /// </summary> |
| | | public string MemberHeadIcon = string.Empty; |
| | | } |
| | | |
| | | #endregion |
| | | |
| | | #region ■ 常开自动化信息_____________________ |
| | | |
| | | /// <summary> |
| | |
| | | //密码输入框 |
| | | this.txtPassword = new EditText(); |
| | | txtPassword.IsNumberKeyboardType = true; |
| | | txtPassword.Height = 0; |
| | | txtPassword.Height = 1; |
| | | bodyFrameLayout.AddChidren(txtPassword); |
| | | txtPassword.Foucs = true; |
| | | txtPassword.TextChangeEventHandler = (sender, e) => |
| | |
| | | #region ■ 添加列表消息显示控件_______________
|
| | |
|
| | | /// <summary>
|
| | | /// 添加列表消息显示控件,返回的是最后一个控件的底部坐标(没看懂这个函数前,请勿使用)
|
| | | /// 添加列表消息显示控件,返回生成的控件(没看懂这个函数前,请勿使用,它不会帮计算换行)
|
| | | /// </summary>
|
| | | /// <param name="frameTable">桌布容器控件</param>
|
| | | /// <param name="i_msg">显示的消息(换行请使用【{0}】进行分割)</param>
|
| | |
| | | /// </param>
|
| | | /// <param name="i_width">文本宽度,真实值,当为-1时,内部自动计算</param>
|
| | | /// <returns></returns>
|
| | | public int AddListMsgControls(FrameLayout frameTable, string i_msg, int i_fontSize, uint i_fontColor, int i_height,
|
| | | public List<NormalViewControl> AddListMsgControls(FrameLayout frameTable, string i_msg, int i_fontSize, uint i_fontColor, int i_height,
|
| | | int i_yy, TextAlignment alignment = TextAlignment.Center, bool special = false, int i_width = -1)
|
| | | {
|
| | | var listMsg = i_msg.Split(new string[] { "{0}" }, StringSplitOptions.RemoveEmptyEntries);
|
| | |
| | | }
|
| | |
|
| | | //特殊处理
|
| | | if (special == true && alignment == TextAlignment.Center)
|
| | | if (special == true)
|
| | | {
|
| | | //设置它的真实宽度(对special变量有用)
|
| | | int realWidth = btnMsg.GetRealWidthByText();
|
| | |
| | | i_yy = btnMsg.Bottom + Application.GetRealHeight(4);
|
| | | }
|
| | | //特殊处理
|
| | | if (special == true && alignment == TextAlignment.Center)
|
| | | if (special == true)
|
| | | {
|
| | | foreach (var contr in listContr)
|
| | | {
|
| | |
| | | }
|
| | | }
|
| | |
|
| | | return i_yy - Application.GetRealHeight(4);
|
| | | return listContr;
|
| | | }
|
| | |
|
| | | #endregion
|
| | |
| | | public void RemoveBackButton() |
| | | { |
| | | //移除返回键 |
| | | var back = (NormalViewControl)topFrameLayout.GetTagByKey("btnBack"); |
| | | var back = (PicViewControl)topFrameLayout.GetTagByKey("btnBack"); |
| | | topFrameLayout.RemoveTag("btnBack"); |
| | | back?.RemoveFromParent();
|
| | |
|
| | |
| | | return m_Current; |
| | | } |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 验证认证的次数 |
| | | /// </summary> |
| | | private int checkSecurityCount = 3; |
| | | |
| | | #endregion |
| | | |
| | | #region ■ 验证解锁认证_______________________ |
| | |
| | | /// 验证解锁认证 |
| | | /// </summary> |
| | | /// <param name="addTopFrame">验证界面是否添加头部Frame(只对手势密码和数字密码有效)</param> |
| | | /// <param name="successEvent">验证成功之后的回调函数,失败不会回调</param> |
| | | /// <param name="successEvent">验证成功之后的回调函数,失败不会回调(0:没有设置有验证 1:验证成功)</param> |
| | | /// <param name="loadPageBeforEvent">加载指定解锁认证界面之前的事件,0:取消当前验证并切换到其他方式,1:数字密码,2:手势密码,3:指纹密码,4:面容ID</param> |
| | | public void CheckUnlockSecurity(bool addTopFrame, Action successEvent, Action<string> loadPageBeforEvent = null) |
| | | public void CheckUnlockSecurity(bool addTopFrame, Action<int> successEvent, Action<string> loadPageBeforEvent = null) |
| | | { |
| | | //验证指纹和面容id都使用指纹验证 |
| | | if (UserInfo.Current.appUnlockType.Contains("3") || UserInfo.Current.appUnlockType.Contains("4")) |
| | |
| | | { |
| | | if (e2 == TouchIDUtils.TouchIDState.Success) |
| | | { |
| | | //次数还原 |
| | | this.checkSecurityCount = 3; |
| | | |
| | | //TouchID验证成功 |
| | | successEvent?.Invoke(); |
| | | successEvent?.Invoke(1); |
| | | successEvent = null; |
| | | loadPageBeforEvent = null; |
| | | TouchIDUtils.Instance.OnHDLTouchIDStateBackEvent = null; |
| | |
| | | /// 使用密码或者手势密码解锁认证 |
| | | /// </summary> |
| | | /// <param name="addTopFrame">验证界面是否添加头部Frame(只对手势密码和数字密码有效)</param> |
| | | /// <param name="successEvent">验证成功之后的回调函数,失败不会回调</param> |
| | | /// <param name="successEvent">验证成功之后的回调函数,失败不会回调(0:没有设置有验证 1:验证成功)</param> |
| | | /// <param name="loadPageBeforEvent">加载指定解锁认证界面之前的事件,1:数字密码,2:手势密码,3:指纹密码,4:面容ID</param> |
| | | private void CheckUnlockSecurityByPassword(bool addTopFrame, Action successEvent, Action<string> loadPageBeforEvent = null) |
| | | private void CheckUnlockSecurityByPassword(bool addTopFrame, Action<int> successEvent, Action<string> loadPageBeforEvent = null) |
| | | { |
| | | if (UserInfo.Current.appUnlockType.Contains("1")) |
| | | { |
| | |
| | | //显示手势密码解锁认证界面 |
| | | this.ShowAppGestureSecurityForm(addTopFrame, successEvent); |
| | | } |
| | | else |
| | | { |
| | | //没有设置有验证 |
| | | successEvent?.Invoke(0); |
| | | successEvent = null; |
| | | } |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 显示数字密码解锁认证界面 |
| | | /// </summary> |
| | | /// <param name="addTopFrame">验证界面是否添加头部Frame(只对手势密码和数字密码有效)</param> |
| | | /// <param name="successEvent">验证成功之后的回调函数,失败不会回调</param> |
| | | private void ShowAppNumPasswordSecurityForm(bool addTopFrame, Action successEvent) |
| | | /// <param name="successEvent">验证成功之后的回调函数,失败不会回调(0:没有设置有验证 1:验证成功)</param> |
| | | private void ShowAppNumPasswordSecurityForm(bool addTopFrame, Action<int> successEvent) |
| | | { |
| | | var form = new AppNumPasswordSecurityForm(); |
| | | form.AddForm(addTopFrame, Language.StringByID(StringId.PlsEntryPassword), string.Empty); |
| | |
| | | //密码正确 |
| | | if (UserInfo.Current.appUnlockPasswrod == password) |
| | | { |
| | | //次数还原 |
| | | this.checkSecurityCount = 3; |
| | | |
| | | form.CloseForm(); |
| | | //回调 |
| | | successEvent?.Invoke(); |
| | | successEvent?.Invoke(1); |
| | | successEvent = null; |
| | | } |
| | | else |
| | | { |
| | | this.checkSecurityCount--; |
| | | if (this.checkSecurityCount == 0) |
| | | { |
| | | //管理员身份验证失败,请重新登录 |
| | | HdlMessageLogic.Current.ShowMassage(ShowMsgType.Tip, Language.StringByID(StringId.CheckAdminFailAndLoginAgain)); |
| | | HDLCommon.Current.Logout(); |
| | | |
| | | this.checkSecurityCount = 3; |
| | | return; |
| | | } |
| | | //验证失败,密码错误. |
| | | form.ShowErrorMsg(Language.StringByID(StringId.AuthenticationFailedPasswordError)); |
| | | } |
| | |
| | | /// 显示手势密码解锁认证界面 |
| | | /// </summary> |
| | | /// <param name="addTopFrame">验证界面是否添加头部Frame(只对手势密码和数字密码有效)</param> |
| | | /// <param name="successEvent">验证成功之后的回调函数,失败不会回调</param> |
| | | private void ShowAppGestureSecurityForm(bool addTopFrame, Action successEvent) |
| | | /// <param name="successEvent">验证成功之后的回调函数,失败不会回调(0:没有设置有验证 1:验证成功)</param> |
| | | private void ShowAppGestureSecurityForm(bool addTopFrame, Action<int> successEvent) |
| | | { |
| | | var form = new AppGestureSecurityForm(); |
| | | form.AddForm(addTopFrame, Language.StringByID(StringId.VerifyGesturePassword), string.Empty); |
| | |
| | | //密码正确 |
| | | if (UserInfo.Current.appUnlockPasswrod == password) |
| | | { |
| | | //次数还原 |
| | | this.checkSecurityCount = 3; |
| | | |
| | | form.CloseForm(); |
| | | //回调 |
| | | successEvent?.Invoke(); |
| | | successEvent?.Invoke(1); |
| | | successEvent = null; |
| | | } |
| | | else |
| | | { |
| | | this.checkSecurityCount--; |
| | | if (this.checkSecurityCount == 0) |
| | | { |
| | | //管理员身份验证失败,请重新登录 |
| | | HdlMessageLogic.Current.ShowMassage(ShowMsgType.Tip, Language.StringByID(StringId.CheckAdminFailAndLoginAgain)); |
| | | HDLCommon.Current.Logout(); |
| | | |
| | | this.checkSecurityCount = 3; |
| | | return; |
| | | } |
| | | |
| | | //验证失败,密码错误. |
| | | form.ShowErrorMsg(Language.StringByID(StringId.AuthenticationFailedPasswordError)); |
| | | } |
| | |
| | | /// </summary>
|
| | | public static int XXLeft = Application.GetRealWidth(16);
|
| | | /// <summary>
|
| | | /// VerticalScrolViewLayout控件一行的高度(只针对标准型列表式画面)
|
| | | /// VerticalScrolViewLayout控件一行的高度(只针对标准型列表式画面,,44高度)
|
| | | /// </summary>
|
| | | public static int ListViewRowHeight = Application.GetRealHeight(44);
|
| | | /// <summary>
|
| | |
| | | |
| | | //长按红外遥控器按钮10秒,指示灯蓝色快闪 |
| | | var strMsg = Language.StringByID(StringId.AddInfraredRemoteControlMsg1); |
| | | var intYY = this.AddListMsgControls(bodyFrameLayout, strMsg, CSS.CSS_FontSize.TextFontSize, |
| | | var listContr = this.AddListMsgControls(bodyFrameLayout, strMsg, CSS.CSS_FontSize.TextFontSize, |
| | | CSS.CSS_Color.FirstLevelTitleColor, Application.GetRealHeight(20), Application.GetRealHeight(408)); |
| | | |
| | | //请确保您的蓝牙已开启并处于可以被搜索状态 |
| | | strMsg = Language.StringByID(StringId.AddInfraredRemoteControlMsg2); |
| | | this.AddListMsgControls(bodyFrameLayout, strMsg, CSS.CSS_FontSize.PromptFontSize_FirstLevel, |
| | | CSS.CSS_Color.PromptingColor1, Application.GetRealHeight(18), intYY + Application.GetRealHeight(4)); |
| | | CSS.CSS_Color.PromptingColor1, Application.GetRealHeight(18), listContr[listContr.Count - 1].Bottom + Application.GetRealHeight(4)); |
| | | |
| | | //下一步 |
| | | var btnNext = this.AddBottomClickButton(Language.StringByID(StringId.Next)); |
| | |
| | | //目前只支持2.4G WiFi网络 |
| | | //暂不支持带有中文字符的WiFi名称 |
| | | var strMsg = Language.StringByID(StringId.AddInfraredRemoteControlMsg4); |
| | | int yy = this.AddListMsgControls(bodyFrameLayout, strMsg, CSS.CSS_FontSize.TextFontSize, CSS.CSS_Color.TextualColor, |
| | | var listContr = this.AddListMsgControls(bodyFrameLayout, strMsg, CSS.CSS_FontSize.TextFontSize, CSS.CSS_Color.TextualColor, |
| | | Application.GetRealHeight(20), btnWifi.Bottom + Application.GetRealHeight(16), TextAlignment.CenterLeft); |
| | | |
| | | //wifi行 |
| | | var rowWifi = new RowLayoutControl(); |
| | | rowWifi.Y = yy + Application.GetRealHeight(32); |
| | | rowWifi.Y = listContr[listContr.Count - 1].Bottom + Application.GetRealHeight(32); |
| | | bodyFrameLayout.AddChidren(rowWifi); |
| | | //wifi名字 |
| | | var txtWifi = rowWifi.frameTable.AddLeftInput(wifiName, 200); |
| | |
| | | |
| | | //可以开始使用红外遥控功能! |
| | | var strMsg = Language.StringByID(StringId.AddInfraredRemoteControlMsg7); |
| | | int yy = this.AddListMsgControls(bodyFrameLayout, strMsg, CSS.CSS_FontSize.TextFontSize, CSS.CSS_Color.TextualColor, |
| | | var listContr = this.AddListMsgControls(bodyFrameLayout, strMsg, CSS.CSS_FontSize.TextFontSize, CSS.CSS_Color.TextualColor, |
| | | Application.GetRealHeight(20), btnFail.Bottom + Application.GetRealHeight(8)); |
| | | |
| | | //开始使用 |
| | | var btnUse = new BottomClickButton(220); |
| | | btnUse.Y = yy + Application.GetRealHeight(60); |
| | | btnUse.Y = listContr[listContr.Count - 1].Bottom + Application.GetRealHeight(60); |
| | | btnUse.TextID = StringId.StartUse; |
| | | bodyFrameLayout.AddChidren(btnUse); |
| | | btnUse.ButtonClickEvent += (sender, e) => |
| | |
| | | /// </summary> |
| | | Button btnCommissioningAuthoritySwitchIcon; |
| | | |
| | | #region F3阶段 |
| | | #region 管理员权限迁移 |
| | | //FrameLayout administratorPermissionMigrationRow; |
| | | //Button btnAdministratorPermissionMigrationTitle; |
| | | //Button btnAdministratorPermissionMigrationExplan; |
| | | //Button btnAdministratorPermissionMigrationSkinIcon; |
| | | FrameLayout administratorPermissionMigrationRow; |
| | | Button btnAdministratorPermissionMigrationTitle; |
| | | Button btnAdministratorPermissionMigrationExplan; |
| | | Button btnAdministratorPermissionMigrationSkinIcon; |
| | | #endregion |
| | | |
| | | #region 过户 |
| | | ///// <summary> |
| | | ///// |
| | | ///// </summary> |
| | | //FrameLayout transferRow; |
| | | ///// <summary> |
| | | ///// |
| | | ///// </summary> |
| | | //Button btnTransferTitle; |
| | | ///// <summary> |
| | | ///// |
| | | ///// </summary> |
| | | //Button btnTrasferExplan; |
| | | ///// <summary> |
| | | ///// |
| | | ///// </summary> |
| | | //Button btnTrasferSkinIcon; |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | FrameLayout transferRow; |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | Button btnTransferTitle; |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | Button btnTrasferExplan; |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | Button btnTrasferSkinIcon; |
| | | #endregion |
| | | #endregion |
| | | |
| | | #endregion |
| | | /// <summary> |
| | | /// 更新住宅名称的回调函数 |
| | |
| | | roomManagementRow.AddChidren(btnRoomManagementSkinIcon); |
| | | #endregion |
| | | |
| | | |
| | | #region F3阶段 |
| | | #region 管理员权限迁移 |
| | | //contentView.AddChidren(new Button() { Height = Application.GetRealHeight(8) }); |
| | | //administratorPermissionMigrationRow = new FrameLayout() |
| | | //{ |
| | | // Height = Application.GetRealHeight(65), |
| | | // BackgroundColor = CSS_Color.MainBackgroundColor, |
| | | //}; |
| | | //contentView.AddChidren(administratorPermissionMigrationRow); |
| | | contentView.AddChidren(new Button() { Height = Application.GetRealHeight(8) }); |
| | | administratorPermissionMigrationRow = new FrameLayout() |
| | | { |
| | | Height = Application.GetRealHeight(65), |
| | | BackgroundColor = CSS_Color.MainBackgroundColor, |
| | | }; |
| | | contentView.AddChidren(administratorPermissionMigrationRow); |
| | | |
| | | //btnAdministratorPermissionMigrationTitle = new Button() |
| | | //{ |
| | | // X = Application.GetRealWidth(16), |
| | | // Y = Application.GetRealHeight(10), |
| | | // Width = Application.GetRealWidth(308), |
| | | // Height = Application.GetRealHeight(24), |
| | | // TextID = StringId.AdministratorPermissionMigration, |
| | | // TextAlignment = TextAlignment.CenterLeft, |
| | | // TextSize = CSS_FontSize.SubheadingFontSize, |
| | | // TextColor = CSS_Color.FirstLevelTitleColor, |
| | | //}; |
| | | //administratorPermissionMigrationRow.AddChidren(btnAdministratorPermissionMigrationTitle); |
| | | btnAdministratorPermissionMigrationTitle = new Button() |
| | | { |
| | | X = Application.GetRealWidth(16), |
| | | Y = Application.GetRealHeight(10), |
| | | Width = Application.GetRealWidth(308), |
| | | Height = Application.GetRealHeight(24), |
| | | TextID = StringId.AdministratorPermissionMigration, |
| | | TextAlignment = TextAlignment.CenterLeft, |
| | | TextSize = CSS_FontSize.SubheadingFontSize, |
| | | TextColor = CSS_Color.FirstLevelTitleColor, |
| | | }; |
| | | administratorPermissionMigrationRow.AddChidren(btnAdministratorPermissionMigrationTitle); |
| | | |
| | | //btnAdministratorPermissionMigrationExplan = new Button() |
| | | //{ |
| | | // X = Application.GetRealWidth(16), |
| | | // Y = btnAdministratorPermissionMigrationTitle.Bottom, |
| | | // Width = Application.GetRealWidth(308), |
| | | // Height = Application.GetRealHeight(21), |
| | | // TextID = StringId.AdministratorPermissionMigrationExPlan, |
| | | // TextAlignment = TextAlignment.CenterLeft, |
| | | // TextSize = CSS_FontSize.PromptFontSize_FirstLevel, |
| | | // TextColor = CSS_Color.PromptingColor1, |
| | | //}; |
| | | //administratorPermissionMigrationRow.AddChidren(btnAdministratorPermissionMigrationExplan); |
| | | btnAdministratorPermissionMigrationExplan = new Button() |
| | | { |
| | | X = Application.GetRealWidth(16), |
| | | Y = btnAdministratorPermissionMigrationTitle.Bottom, |
| | | Width = Application.GetRealWidth(308), |
| | | Height = Application.GetRealHeight(21), |
| | | TextID = StringId.AdministratorPermissionMigrationExPlan, |
| | | TextAlignment = TextAlignment.CenterLeft, |
| | | TextSize = CSS_FontSize.PromptFontSize_FirstLevel, |
| | | TextColor = CSS_Color.PromptingColor1, |
| | | }; |
| | | administratorPermissionMigrationRow.AddChidren(btnAdministratorPermissionMigrationExplan); |
| | | |
| | | |
| | | //btnAdministratorPermissionMigrationSkinIcon = new Button() |
| | | //{ |
| | | // X = Application.GetRealWidth(343), |
| | | // Gravity = Gravity.CenterVertical, |
| | | // Width = Application.GetMinRealAverage(16), |
| | | // Height = Application.GetMinRealAverage(16), |
| | | // UnSelectedImagePath = "Public/RightIcon.png", |
| | | //}; |
| | | //administratorPermissionMigrationRow.AddChidren(btnAdministratorPermissionMigrationSkinIcon); |
| | | btnAdministratorPermissionMigrationSkinIcon = new Button() |
| | | { |
| | | X = Application.GetRealWidth(343), |
| | | Gravity = Gravity.CenterVertical, |
| | | Width = Application.GetMinRealAverage(16), |
| | | Height = Application.GetMinRealAverage(16), |
| | | UnSelectedImagePath = "Public/RightIcon.png", |
| | | }; |
| | | administratorPermissionMigrationRow.AddChidren(btnAdministratorPermissionMigrationSkinIcon); |
| | | |
| | | //administratorPermissionMigrationRow.AddChidren( |
| | | // new Button() |
| | | // { |
| | | // Gravity = Gravity.CenterHorizontal, |
| | | // Y = Application.GetRealHeight(64), |
| | | // Height = Application.GetRealHeight(1), |
| | | // Width = Application.GetRealWidth(343), |
| | | // BackgroundColor = CSS_Color.DividingLineColor, |
| | | // }); |
| | | #endregion |
| | | administratorPermissionMigrationRow.AddChidren( |
| | | new Button() |
| | | { |
| | | Gravity = Gravity.CenterHorizontal, |
| | | Y = Application.GetRealHeight(64), |
| | | Height = Application.GetRealHeight(1), |
| | | Width = Application.GetRealWidth(343), |
| | | BackgroundColor = CSS_Color.DividingLineColor, |
| | | }); |
| | | #endregion |
| | | |
| | | #region F3阶段 |
| | | #region 过户 |
| | | //transferRow = new FrameLayout() |
| | | //{ |
| | | // Y = administratorPermissionMigrationRow.Bottom, |
| | | // Height = Application.GetRealHeight(65), |
| | | // BackgroundColor = CSS_Color.MainBackgroundColor, |
| | | //}; |
| | | //contentView.AddChidren(transferRow); |
| | | transferRow = new FrameLayout() |
| | | { |
| | | Y = administratorPermissionMigrationRow.Bottom, |
| | | Height = Application.GetRealHeight(65), |
| | | BackgroundColor = CSS_Color.MainBackgroundColor, |
| | | }; |
| | | //有网关才能过户 |
| | | if (DB_ResidenceData.Instance.HomeGateway != null && string.IsNullOrEmpty(DB_ResidenceData.Instance.HomeGateway.gatewayId) == false |
| | | && DB_ResidenceData.Instance.CurrentRegion.isOtherShare == false) |
| | | { |
| | | contentView.AddChidren(transferRow); |
| | | } |
| | | |
| | | //btnTransferTitle = new Button() |
| | | //{ |
| | | // X = Application.GetRealWidth(16), |
| | | // Y = Application.GetRealHeight(10), |
| | | // Width = Application.GetRealWidth(308), |
| | | // Height = Application.GetRealHeight(24), |
| | | // TextID = StringId.Transfer, |
| | | // TextAlignment = TextAlignment.CenterLeft, |
| | | // TextSize = CSS_FontSize.SubheadingFontSize, |
| | | // TextColor = CSS_Color.FirstLevelTitleColor, |
| | | //}; |
| | | //transferRow.AddChidren(btnTransferTitle); |
| | | btnTransferTitle = new Button() |
| | | { |
| | | X = Application.GetRealWidth(16), |
| | | Y = Application.GetRealHeight(10), |
| | | Width = Application.GetRealWidth(308), |
| | | Height = Application.GetRealHeight(24), |
| | | TextID = StringId.Transfer, |
| | | TextAlignment = TextAlignment.CenterLeft, |
| | | TextSize = CSS_FontSize.SubheadingFontSize, |
| | | TextColor = CSS_Color.FirstLevelTitleColor, |
| | | }; |
| | | transferRow.AddChidren(btnTransferTitle); |
| | | |
| | | //btnTrasferExplan = new Button() |
| | | //{ |
| | | // X = Application.GetRealWidth(16), |
| | | // Y = btnTransferTitle.Bottom, |
| | | // Width = Application.GetRealWidth(308), |
| | | // Height = Application.GetRealHeight(21), |
| | | // TextID = StringId.TransferExPlan, |
| | | // TextAlignment = TextAlignment.CenterLeft, |
| | | // TextSize = CSS_FontSize.PromptFontSize_FirstLevel, |
| | | // TextColor = CSS_Color.PromptingColor1, |
| | | //}; |
| | | //transferRow.AddChidren(btnTrasferExplan); |
| | | btnTrasferExplan = new Button() |
| | | { |
| | | X = Application.GetRealWidth(16), |
| | | Y = btnTransferTitle.Bottom, |
| | | Width = Application.GetRealWidth(308), |
| | | Height = Application.GetRealHeight(21), |
| | | TextID = StringId.TransferExPlan, |
| | | TextAlignment = TextAlignment.CenterLeft, |
| | | TextSize = CSS_FontSize.PromptFontSize_FirstLevel, |
| | | TextColor = CSS_Color.PromptingColor1, |
| | | }; |
| | | transferRow.AddChidren(btnTrasferExplan); |
| | | |
| | | //btnTrasferSkinIcon = new Button() |
| | | //{ |
| | | // X = Application.GetRealWidth(343), |
| | | // Gravity = Gravity.CenterVertical, |
| | | // Width = Application.GetMinRealAverage(16), |
| | | // Height = Application.GetMinRealAverage(16), |
| | | // UnSelectedImagePath = "Public/RightIcon.png", |
| | | //}; |
| | | //transferRow.AddChidren(btnTrasferSkinIcon); |
| | | #endregion |
| | | btnTrasferSkinIcon = new Button() |
| | | { |
| | | X = Application.GetRealWidth(343), |
| | | Gravity = Gravity.CenterVertical, |
| | | Width = Application.GetMinRealAverage(16), |
| | | Height = Application.GetMinRealAverage(16), |
| | | UnSelectedImagePath = "Public/RightIcon.png", |
| | | }; |
| | | transferRow.AddChidren(btnTrasferSkinIcon); |
| | | #endregion |
| | | |
| | | #region 调试权限 |
| | |
| | | LoadEvent_SkipRoomsPage(); |
| | | LoadEvent_EditResidencName(); |
| | | LoadEvent_EditResidencAddress(); |
| | | //LoadEvent_SkipAdminMigrationConfirmPage(); |
| | | //LoadEvent_SkipTransferConfirmPage(); |
| | | LoadEvent_SkipAdminMigrationConfirmPage(); |
| | | LoadEvent_SkipTransferConfirmPage(); |
| | | } |
| | | |
| | | /// <summary> |
| | |
| | | // }; |
| | | //} |
| | | |
| | | ///// <summary> |
| | | ///// 跳转管理员权限迁移页面 |
| | | ///// </summary> |
| | | //void LoadEvent_SkipAdminMigrationConfirmPage() |
| | | //{ |
| | | // EventHandler<MouseEventArgs> eventHandler = (sender, e) => { |
| | | // var skipPage = new AdminMigrationConfirmPage(); |
| | | // MainPage.BasePageView.AddChidren(skipPage); |
| | | // skipPage.LoadPage(); |
| | | // MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1; |
| | | // }; |
| | | /// <summary> |
| | | /// 跳转管理员权限迁移页面 |
| | | /// </summary> |
| | | void LoadEvent_SkipAdminMigrationConfirmPage() |
| | | { |
| | | EventHandler<MouseEventArgs> eventHandler = (sender, e) => |
| | | { |
| | | var skipPage = new AdminMigrationConfirmPage(); |
| | | MainPage.BasePageView.AddChidren(skipPage); |
| | | skipPage.LoadPage(); |
| | | MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1; |
| | | }; |
| | | |
| | | // administratorPermissionMigrationRow.MouseUpEventHandler = eventHandler; |
| | | // btnAdministratorPermissionMigrationTitle.MouseUpEventHandler = eventHandler; |
| | | // btnAdministratorPermissionMigrationExplan.MouseUpEventHandler = eventHandler; |
| | | // btnAdministratorPermissionMigrationSkinIcon.MouseUpEventHandler = eventHandler; |
| | | //} |
| | | administratorPermissionMigrationRow.MouseUpEventHandler = eventHandler; |
| | | btnAdministratorPermissionMigrationTitle.MouseUpEventHandler = eventHandler; |
| | | btnAdministratorPermissionMigrationExplan.MouseUpEventHandler = eventHandler; |
| | | btnAdministratorPermissionMigrationSkinIcon.MouseUpEventHandler = eventHandler; |
| | | } |
| | | |
| | | ///// <summary> |
| | | ///// 跳转过户页面 |
| | | ///// </summary> |
| | | //void LoadEvent_SkipTransferConfirmPage() |
| | | //{ |
| | | // EventHandler<MouseEventArgs> eventHandler = (sender, e) => { |
| | | // var skipPage = new TransferConfirmPage(); |
| | | // MainPage.BasePageView.AddChidren(skipPage); |
| | | // skipPage.LoadPage(); |
| | | // MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1; |
| | | // }; |
| | | /// <summary> |
| | | /// 跳转过户页面 |
| | | /// </summary> |
| | | void LoadEvent_SkipTransferConfirmPage() |
| | | { |
| | | EventHandler<MouseEventArgs> eventHandler = (sender, e) => |
| | | { |
| | | var from = new TransferConfirmPage(); |
| | | from.AddForm(); |
| | | }; |
| | | |
| | | // transferRow.MouseUpEventHandler = eventHandler; |
| | | // btnTrasferExplan.MouseUpEventHandler = eventHandler; |
| | | // btnTrasferSkinIcon.MouseUpEventHandler = eventHandler; |
| | | // btnTransferTitle.MouseUpEventHandler = eventHandler; |
| | | //} |
| | | transferRow.MouseUpEventHandler = eventHandler; |
| | | btnTrasferExplan.MouseUpEventHandler = eventHandler; |
| | | btnTrasferSkinIcon.MouseUpEventHandler = eventHandler; |
| | | btnTransferTitle.MouseUpEventHandler = eventHandler; |
| | | } |
| | | #endregion |
| | | |
| | | } |
| | |
| | | using System; |
| | | using Shared; |
| | | using HDL_ON.UI.CSS; |
| | | using HDL_ON.Stan; |
| | | |
| | | namespace HDL_ON.UI |
| | | { |
| | | /// <summary> |
| | | /// 过户确认提醒界面 |
| | | /// </summary> |
| | | public class TransferConfirmPage : FrameLayout |
| | | public class TransferConfirmPage : EditorCommonForm |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | FrameLayout bodyView; |
| | | |
| | | public TransferConfirmPage() |
| | | { |
| | | bodyView = this; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public void LoadPage() |
| | | { |
| | | BackgroundColor = CSS_Color.MainBackgroundColor; |
| | | |
| | | new TopViewDiv(bodyView, Language.StringByID(StringId.Transfer)).LoadTopView(); |
| | | |
| | | #region 头像 |
| | | FrameLayout headView = new FrameLayout() |
| | | { |
| | | Y = Application.GetRealHeight(72), |
| | | Height = Application.GetRealHeight(132), |
| | | }; |
| | | bodyView.AddChidren(headView); |
| | | |
| | | |
| | | ImageView myHeadImage = new ImageView() |
| | | { |
| | | X = Application.GetRealWidth(48), |
| | | Y = Application.GetRealHeight(96), |
| | | Width = Application.GetRealWidth(84), |
| | | Height = Application.GetRealWidth(84), |
| | | Radius = (uint)Application.GetRealWidth(42), |
| | | ImagePath = UserInfo.Current.headImagePagePath, |
| | | Gravity = Gravity.CenterVertical, |
| | | }; |
| | | headView.AddChidren(myHeadImage); |
| | | |
| | | ImageView transferImage = new ImageView() |
| | | { |
| | | X = Application.GetRealWidth(144), |
| | | Y = Application.GetRealHeight(96), |
| | | Width = Application.GetRealWidth(84), |
| | | Height = Application.GetRealWidth(32), |
| | | ImagePath = "PersonalCenter/Transfer.png", |
| | | Gravity = Gravity.Center, |
| | | }; |
| | | headView.AddChidren(transferImage); |
| | | |
| | | ImageView otherHeadImage = new ImageView() |
| | | { |
| | | X = Application.GetRealWidth(231), |
| | | Y = Application.GetRealHeight(96), |
| | | Width = Application.GetRealWidth(101), |
| | | Height = Application.GetRealWidth(101), |
| | | ImagePath = "PersonalCenter/Head.png", |
| | | Gravity = Gravity.CenterVertical, |
| | | }; |
| | | headView.AddChidren(otherHeadImage); |
| | | #region ■ 变量声明___________________________ |
| | | |
| | | #endregion |
| | | |
| | | var btnTip = new Button() |
| | | #region ■ 初始化_____________________________ |
| | | |
| | | /// <summary> |
| | | /// 画面显示(底层会固定调用此方法,借以完成画面创建) |
| | | /// </summary> |
| | | public void ShowForm() |
| | | { |
| | | Y = headView.Bottom, |
| | | X = Application.GetRealWidth(16), |
| | | Width = Application.GetRealWidth(343), |
| | | Height = Application.GetRealHeight(22), |
| | | TextAlignment = TextAlignment.Center, |
| | | TextColor = CSS_Color.FirstLevelTitleColor, |
| | | TextSize = CSS_FontSize.SubheadingFontSize, |
| | | Text = "您的住宅将过户给其他HDL账号", |
| | | }; |
| | | bodyView.AddChidren(btnTip); |
| | | //过户 |
| | | base.SetTitleText(Language.StringByID(StringId.Transfer)); |
| | | |
| | | |
| | | //请注意 |
| | | var btnPleaseNote = new Button() |
| | | { |
| | | Y = btnTip.Bottom + Application.GetRealHeight(38), |
| | | X = Application.GetRealWidth(16), |
| | | Width = Application.GetRealWidth(343), |
| | | Height = Application.GetRealHeight(17), |
| | | TextAlignment = TextAlignment.CenterLeft, |
| | | TextColor = CSS_Color.FirstLevelTitleColor, |
| | | TextSize = CSS_FontSize.PromptFontSize_FirstLevel, |
| | | Text = "请注意:", |
| | | }; |
| | | bodyView.AddChidren(btnPleaseNote); |
| | | |
| | | //请注意的内容 |
| | | var btnPleaseNoteStr = new Button() |
| | | { |
| | | Y = btnPleaseNote.Bottom + Application.GetRealHeight(8), |
| | | X = Application.GetRealWidth(16), |
| | | Width = Application.GetRealWidth(343), |
| | | Height = Application.GetRealHeight(170), |
| | | TextAlignment = TextAlignment.TopLeft, |
| | | TextColor = CSS_Color.TextualColor, |
| | | TextSize = CSS_FontSize.PromptFontSize_FirstLevel, |
| | | IsMoreLines = true, |
| | | Text = "1.该住宅您的数据(云端数据)将全部转移给新的户主 \n\n2.过户后,原有的成员将自动解绑该住宅 \n\n3.新户主账号为有效的HDL账号 \n\n4.接收方账号与转移方账号不可为同一个账号 (绑定的其他登录)", |
| | | }; |
| | | bodyView.AddChidren(btnPleaseNoteStr); |
| | | |
| | | // |
| | | var btnConfirm = new ConfirmButton() |
| | | { |
| | | Y = Application.GetRealHeight(456), |
| | | Text = "确认过户", |
| | | }; |
| | | bodyView.AddChidren(btnConfirm); |
| | | |
| | | btnConfirm.MouseUpEventHandler = (sender, e) => { |
| | | //Utlis.ShowTip("暂不支持"); |
| | | |
| | | var skipPage = new TransferInputPage(); |
| | | MainPage.BasePageView.AddChidren(skipPage); |
| | | skipPage.LoadPage(); |
| | | MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1; |
| | | |
| | | }; |
| | | |
| | | //初始化中部信息 |
| | | this.InitMiddleFrame(); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 初始化中部信息 |
| | | /// </summary> |
| | | private void InitMiddleFrame() |
| | | { |
| | | //清空bodyFrame |
| | | this.ClearBodyFrame(); |
| | | |
| | | //账号自己的头像 |
| | | var btnHeadImage = new ImageView(); |
| | | btnHeadImage.X = Application.GetRealWidth(48); |
| | | btnHeadImage.Y = Application.GetRealHeight(32); |
| | | btnHeadImage.Width = Application.GetRealWidth(84); |
| | | btnHeadImage.Height = Application.GetRealWidth(84); |
| | | btnHeadImage.Radius = (uint)Application.GetRealWidth(42); |
| | | btnHeadImage.ImagePath = UserInfo.Current.headImagePagePath; |
| | | bodyFrameLayout.AddChidren(btnHeadImage); |
| | | |
| | | //箭头 |
| | | var btnArrow = new PicViewControl(84, 32); |
| | | btnArrow.X = btnHeadImage.Right + Application.GetRealWidth(12); |
| | | btnArrow.Y = Application.GetRealHeight(58); |
| | | btnArrow.UnSelectedImagePath = "PersonalCenter/Transfer.png"; |
| | | bodyFrameLayout.AddChidren(btnArrow); |
| | | |
| | | //一个默认头像 |
| | | var btnHead2 = new IconViewControl(102); |
| | | btnHead2.X = btnArrow.Right + Application.GetRealWidth(3); |
| | | btnHead2.Y = Application.GetRealHeight(26); |
| | | btnHead2.UnSelectedImagePath = "PersonalCenter/Head.png"; |
| | | bodyFrameLayout.AddChidren(btnHead2); |
| | | |
| | | //您的住宅将过户给其他HDL账号 |
| | | this.AddListMsgControls(bodyFrameLayout, Language.StringByID(StringId.YourHomeWillBeTransferredToOtherAccounts), CSS_FontSize.SubheadingFontSize, |
| | | CSS_Color.FirstLevelTitleColor, Application.GetRealHeight(23), btnHead2.Bottom + Application.GetRealHeight(12)); |
| | | |
| | | //请注意: |
| | | var btnAttention = new NormalViewControl(200, 18, true); |
| | | btnAttention.X = HdlControlResourse.XXLeft; |
| | | btnAttention.Y = btnHeadImage.Bottom + Application.GetRealHeight(84); |
| | | btnAttention.TextID = StringId.Attention; |
| | | btnAttention.TextSize = CSS_FontSize.PromptFontSize_FirstLevel; |
| | | btnAttention.TextColor = CSS_Color.FirstLevelTitleColor; |
| | | bodyFrameLayout.AddChidren(btnAttention); |
| | | |
| | | //1.该住宅的数据(云端数据)将全部转移给新的户主 |
| | | //2.过户后,原有的成员将自动解绑该住宅 |
| | | //3.新户主账号为有效的HDL账号 |
| | | //4.接收方账号与转移方账号不可为同一个账号 |
| | | var listContr = this.AddListMsgControls(bodyFrameLayout, Language.StringByID(StringId.TransferreConfirmMsg1), CSS_FontSize.PromptFontSize_FirstLevel, |
| | | CSS_Color.TextualColor, Application.GetRealHeight(18), btnAttention.Bottom + Application.GetRealHeight(8), TextAlignment.CenterLeft); |
| | | |
| | | //确认 |
| | | var btnConfirm = new BottomClickButton(220); |
| | | btnConfirm.Y = listContr[listContr.Count - 1].Bottom + Application.GetRealHeight(75); |
| | | btnConfirm.TextID = StringId.ConfirmTransferre; |
| | | bodyFrameLayout.AddChidren(btnConfirm); |
| | | btnConfirm.ButtonClickEvent += (sender, e) => |
| | | { |
| | | var form = new TransferInputPage(); |
| | | form.AddForm(); |
| | | }; |
| | | } |
| | | |
| | | #endregion |
| | | } |
| | | } |
| | |
| | | using System; |
| | | using Shared; |
| | | using HDL_ON.UI.CSS; |
| | | using HDL_ON.Stan; |
| | | |
| | | namespace HDL_ON.UI |
| | | { |
| | | /// <summary> |
| | | /// 过户输入账号界面 |
| | | /// </summary> |
| | | public class TransferInputPage : FrameLayout |
| | | public class TransferInputPage : EditorCommonForm |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | FrameLayout bodyView; |
| | | #region ■ 变量声明___________________________ |
| | | |
| | | public TransferInputPage() |
| | | #endregion |
| | | |
| | | #region ■ 初始化_____________________________ |
| | | |
| | | /// <summary> |
| | | /// 画面显示(底层会固定调用此方法,借以完成画面创建) |
| | | /// </summary> |
| | | public void ShowForm() |
| | | { |
| | | bodyView = this; |
| | | //过户 |
| | | base.SetTitleText(Language.StringByID(StringId.Transfer)); |
| | | |
| | | //初始化中部信息 |
| | | this.InitMiddleFrame(); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// |
| | | /// 初始化中部信息 |
| | | /// </summary> |
| | | public void LoadPage() |
| | | private void InitMiddleFrame() |
| | | { |
| | | BackgroundColor = CSS_Color.BackgroundColor; |
| | | //清空bodyFrame |
| | | this.ClearBodyFrame(); |
| | | |
| | | new TopViewDiv(bodyView, Language.StringByID(StringId.Transfer)).LoadTopView(); |
| | | //白色背景 |
| | | var frameBack = new FrameLayout(); |
| | | frameBack.Y = Application.GetRealHeight(8); |
| | | frameBack.BackgroundColor = CSS_Color.MainBackgroundColor; |
| | | bodyFrameLayout.AddChidren(frameBack); |
| | | |
| | | #region 账号填写 |
| | | var accountView = new FrameLayout() |
| | | //请输入接收方账号 |
| | | var rowInput = new FrameRowControl(); |
| | | rowInput.Height = Application.GetRealHeight(50); |
| | | frameBack.AddChidren(rowInput); |
| | | //图标 |
| | | rowInput.AddLeftIcon(24, "LoginIcon/AccountIcon.png"); |
| | | //输入框 |
| | | var txtInput = rowInput.AddLeftInput(string.Empty, 300); |
| | | txtInput.PlaceholderText = Language.StringByID(StringId.PleaseInputReceiverAccount); |
| | | //底线 |
| | | rowInput.AddBottomLine(); |
| | | //变更容器高度 |
| | | frameBack.Height = rowInput.Bottom + Application.GetRealHeight(10); |
| | | |
| | | //过户 |
| | | var btnMigrate = new BottomClickButton(220); |
| | | btnMigrate.TextID = StringId.Transfer; |
| | | btnMigrate.Y = frameBack.Bottom + Application.GetRealHeight(79); |
| | | bodyFrameLayout.AddChidren(btnMigrate); |
| | | btnMigrate.ButtonClickEvent += (sender, e) => |
| | | { |
| | | Y = Application.GetRealHeight(72), |
| | | Height = Application.GetRealHeight(50), |
| | | BackgroundColor = CSS_Color.MainBackgroundColor |
| | | }; |
| | | bodyView.AddChidren(accountView); |
| | | |
| | | var btnAccountIcon = new Button() |
| | | string account = txtInput.Text.Trim(); |
| | | if (account == string.Empty) |
| | | { |
| | | X = Application.GetRealWidth(16), |
| | | Gravity = Gravity.CenterVertical, |
| | | Width = Application.GetMinRealAverage(24), |
| | | Height = Application.GetMinRealAverage(24), |
| | | UnSelectedImagePath = "LoginIcon/AccountIcon.png", |
| | | }; |
| | | accountView.AddChidren(btnAccountIcon); |
| | | |
| | | var etAccount = new EditText() |
| | | return; |
| | | } |
| | | if (account == UserInfo.Current.userEmailInfo || account == UserInfo.Current.userMobileInfo) |
| | | { |
| | | X = Application.GetRealWidth(52), |
| | | Width = Application.GetRealWidth(307), |
| | | TextAlignment = TextAlignment.CenterLeft, |
| | | TextColor = CSS_Color.FirstLevelTitleColor, |
| | | TextSize = CSS_FontSize.TextFontSize, |
| | | PlaceholderTextColor = CSS_Color.PromptingColor1, |
| | | PlaceholderText = "请输入接收方账号", |
| | | }; |
| | | accountView.AddChidren(etAccount); |
| | | |
| | | var btnLine = new Button() |
| | | //不能自己过户给自己 |
| | | HdlMessageLogic.Current.ShowMassage(ShowMsgType.Tip, Language.StringByID(StringId.YouCannotTransferOwnershipToYourself)); |
| | | return; |
| | | } |
| | | //搜索账号信息 |
| | | var accountInfo = this.SearchAccountInfoByAccount(account); |
| | | if (accountInfo == null) |
| | | { |
| | | BackgroundColor = CSS_Color.DividingLineColor, |
| | | Height = Application.GetRealHeight(1), |
| | | Y = accountView.Height - Application.GetRealHeight(1), |
| | | X = Application.GetRealWidth(16), |
| | | Width = Application.GetRealWidth(343), |
| | | }; |
| | | accountView.AddChidren(btnLine); |
| | | #endregion |
| | | |
| | | #region 账号填写 |
| | | var accountConfirmView = new FrameLayout() |
| | | { |
| | | Y = accountView.Bottom, |
| | | Height = Application.GetRealHeight(50), |
| | | BackgroundColor = CSS_Color.MainBackgroundColor |
| | | }; |
| | | bodyView.AddChidren(accountConfirmView); |
| | | |
| | | var btnAccountConfirmIcon = new Button() |
| | | { |
| | | X = Application.GetRealWidth(16), |
| | | Gravity = Gravity.CenterVertical, |
| | | Width = Application.GetMinRealAverage(24), |
| | | Height = Application.GetMinRealAverage(24), |
| | | UnSelectedImagePath = "LoginIcon/AccountIcon.png", |
| | | }; |
| | | accountConfirmView.AddChidren(btnAccountConfirmIcon); |
| | | |
| | | var etAccountConfirm = new EditText() |
| | | { |
| | | X = Application.GetRealWidth(52), |
| | | Width = Application.GetRealWidth(307), |
| | | TextAlignment = TextAlignment.CenterLeft, |
| | | TextColor = CSS_Color.FirstLevelTitleColor, |
| | | TextSize = CSS_FontSize.TextFontSize, |
| | | PlaceholderTextColor = CSS_Color.PromptingColor1, |
| | | PlaceholderText = "请再次输入接收方账号", |
| | | }; |
| | | accountConfirmView.AddChidren(etAccountConfirm); |
| | | |
| | | //var btnLine2 = new Button() |
| | | //{ |
| | | // BackgroundColor = CSS_Color.DividingLineColor, |
| | | // Height = Application.GetRealHeight(1), |
| | | // Y = accountConfirmView.Height - Application.GetRealHeight(1), |
| | | //}; |
| | | //accountConfirmView.AddChidren(btnLine2); |
| | | #endregion |
| | | |
| | | var btnTip = new Button() |
| | | { |
| | | Y = accountConfirmView.Bottom + Application.GetRealHeight(12), |
| | | X = Application.GetRealWidth(16), |
| | | Width = Application.GetRealWidth(343), |
| | | TextAlignment = TextAlignment.TopLeft, |
| | | TextColor = CSS_Color.AuxiliaryColor2, |
| | | TextSize = CSS_FontSize.PromptFontSize_FirstLevel, |
| | | Text = "*请确认账号无误,在数据转移过程中不可取消操作", |
| | | IsMoreLines = true |
| | | |
| | | }; |
| | | bodyView.AddChidren(btnTip); |
| | | |
| | | var btnConfirm = new ConfirmButton() |
| | | { |
| | | Y = Application.GetRealHeight(251), |
| | | Text = "过户", |
| | | }; |
| | | bodyView.AddChidren(btnConfirm); |
| | | |
| | | btnConfirm.MouseUpEventHandler = (sender, e) => { |
| | | var skipPage = new TransferUserConfirmPage(); |
| | | MainPage.BasePageView.AddChidren(skipPage); |
| | | skipPage.LoadPage(); |
| | | MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1; |
| | | }; |
| | | |
| | | Button btnEmailOption = new Button() |
| | | { |
| | | Y = btnConfirm.Bottom + Application.GetRealWidth(6), |
| | | Width = Application.GetRealWidth(220), |
| | | Height = Application.GetRealWidth(32), |
| | | TextSize = CSS_FontSize.TextFontSize, |
| | | TextColor = CSS_Color.MainColor, |
| | | Gravity = Gravity.CenterHorizontal, |
| | | TextAlignment = TextAlignment.Center, |
| | | Text = "扫描二维码过户" |
| | | }; |
| | | bodyView.AddChidren(btnEmailOption); |
| | | |
| | | |
| | | return; |
| | | } |
| | | |
| | | this.CloseForm(); |
| | | |
| | | var form = new TransferUserConfirmPage(); |
| | | form.AddForm(accountInfo); |
| | | }; |
| | | |
| | | //扫描二维码 |
| | | var btnQrcode = new NormalViewControl(220, 32, true); |
| | | btnQrcode.Y = btnMigrate.Bottom + Application.GetRealWidth(6); |
| | | btnQrcode.TextColor = CSS_Color.MainColor; |
| | | btnQrcode.Gravity = Gravity.CenterHorizontal; |
| | | btnQrcode.TextAlignment = TextAlignment.Center; |
| | | btnQrcode.TextID = StringId.ScanQRCoden; |
| | | bodyFrameLayout.AddChidren(btnQrcode); |
| | | btnQrcode.ButtonClickEvent += (sender, e) => |
| | | { |
| | | Scan.OpenScan((scanString) => |
| | | { |
| | | if (string.IsNullOrEmpty(scanString) == true) |
| | | { |
| | | return; |
| | | } |
| | | if (scanString == UserInfo.Current.userEmailInfo || scanString == UserInfo.Current.userMobileInfo) |
| | | { |
| | | //不能自己过户给自己 |
| | | HdlMessageLogic.Current.ShowMassage(ShowMsgType.Tip, Language.StringByID(StringId.YouCannotTransferOwnershipToYourself)); |
| | | return; |
| | | } |
| | | //搜索账号信息 |
| | | var accountInfo = this.SearchAccountInfoByAccount(scanString); |
| | | if (accountInfo == null) |
| | | { |
| | | return; |
| | | } |
| | | this.CloseForm(); |
| | | |
| | | var form = new TransferUserConfirmPage(); |
| | | form.AddForm(accountInfo); |
| | | }); |
| | | }; |
| | | } |
| | | |
| | | #endregion |
| | | |
| | | #region ■ 搜索账号___________________________ |
| | | |
| | | /// <summary> |
| | | /// 搜索账号信息 |
| | | /// </summary> |
| | | /// <param name="i_account">搜索的账号</param> |
| | | /// <returns></returns> |
| | | private AccountInfoResult SearchAccountInfoByAccount(string i_account) |
| | | { |
| | | var result = new DAL.Server.HttpServerRequest().GetMemberInfoByAccount(i_account); |
| | | if (result.Code == DAL.Server.StateCode.ACCOUNT_NOT_EXIST) |
| | | { |
| | | //目标账号并不存在 |
| | | HdlMessageLogic.Current.ShowMassage(ShowMsgType.Tip, Language.StringByID(StringId.TargetAcountDoesNotExist)); |
| | | return null; |
| | | } |
| | | if (result.Code != DAL.Server.StateCode.SUCCESS) |
| | | { |
| | | DAL.Server.IMessageCommon.Current.ShowErrorInfoAlter(result.Code); |
| | | return null; |
| | | } |
| | | var accountInfo = Newtonsoft.Json.JsonConvert.DeserializeObject<AccountInfoResult>(result.Data.ToString()); |
| | | accountInfo.Account = i_account; |
| | | if (accountInfo.MemberName == string.Empty) |
| | | { |
| | | accountInfo.MemberName = accountInfo.Account; |
| | | } |
| | | return accountInfo; |
| | | } |
| | | |
| | | #endregion |
| | | } |
| | | } |
New file |
| | |
| | | using System; |
| | | using Shared; |
| | | using HDL_ON.UI.CSS; |
| | | using HDL_ON.Stan; |
| | | |
| | | namespace HDL_ON.UI |
| | | { |
| | | /// <summary> |
| | | /// 过户结果界面 |
| | | /// </summary> |
| | | public class TransferResidenceResultPage : EditorCommonForm |
| | | { |
| | | #region ■ 变量声明___________________________ |
| | | |
| | | /// <summary> |
| | | /// 结束事件 |
| | | /// </summary> |
| | | public Action FinishEvent = null; |
| | | |
| | | #endregion |
| | | |
| | | #region ■ 初始化_____________________________ |
| | | |
| | | /// <summary> |
| | | /// 画面显示(底层会固定调用此方法,借以完成画面创建) |
| | | /// </summary> |
| | | /// <param name="i_accountResult">对方账号信息</param> |
| | | /// <param name="i_success">是否成功</param> |
| | | public void ShowForm(AccountInfoResult i_accountResult, bool i_success) |
| | | { |
| | | this.ScrollLeftEnabled = false; |
| | | //过户 |
| | | base.SetTitleText(Language.StringByID(StringId.Transfer)); |
| | | |
| | | //初始化中部信息 |
| | | this.InitMiddleFrame(); |
| | | |
| | | //移除返回键 |
| | | base.RemoveBackButton(); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 初始化中部信息 |
| | | /// </summary> |
| | | private void InitMiddleFrame() |
| | | { |
| | | //清空bodyFrame |
| | | this.ClearBodyFrame(); |
| | | |
| | | //确认 |
| | | var btnConfirm = new BottomClickButton(220); |
| | | btnConfirm.TextID = StringId.Complete; |
| | | bodyFrameLayout.AddChidren(btnConfirm); |
| | | btnConfirm.ButtonClickEvent += (sender, e) => |
| | | { |
| | | this.CloseForm(); |
| | | //回调函数 |
| | | this.FinishEvent?.Invoke(); |
| | | this.FinishEvent = null; |
| | | }; |
| | | } |
| | | |
| | | #endregion |
| | | } |
| | | } |
| | |
| | | using System; |
| | | using Shared; |
| | | using HDL_ON.UI.CSS; |
| | | using HDL_ON.Stan; |
| | | |
| | | namespace HDL_ON.UI |
| | | { |
| | | /// <summary> |
| | | /// 过户账号确认界面 |
| | | /// 个人资料 |
| | | /// 过户账号个人资料确认界面 |
| | | /// </summary> |
| | | public class TransferUserConfirmPage : FrameLayout |
| | | public class TransferUserConfirmPage : EditorCommonForm |
| | | { |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | FrameLayout bodyView; |
| | | #region ■ 变量声明___________________________ |
| | | |
| | | public TransferUserConfirmPage() |
| | | /// <summary> |
| | | /// 账号信息 |
| | | /// </summary> |
| | | private AccountInfoResult accountInfo = null; |
| | | |
| | | #endregion |
| | | |
| | | #region ■ 初始化_____________________________ |
| | | |
| | | /// <summary> |
| | | /// 画面显示(底层会固定调用此方法,借以完成画面创建) |
| | | /// </summary> |
| | | /// <param name="i_accountInfo"></param> |
| | | public void ShowForm(AccountInfoResult i_accountInfo) |
| | | { |
| | | bodyView = this; |
| | | this.accountInfo = i_accountInfo; |
| | | |
| | | //个人资料 |
| | | base.SetTitleText(Language.StringByID(StringId.Profile)); |
| | | |
| | | //初始化中部信息 |
| | | this.InitMiddleFrame(); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// |
| | | /// 初始化中部信息 |
| | | /// </summary> |
| | | public void LoadPage() |
| | | private void InitMiddleFrame() |
| | | { |
| | | BackgroundColor = CSS_Color.BackgroundColor; |
| | | //清空bodyFrame |
| | | this.ClearBodyFrame(); |
| | | |
| | | new TopViewDiv(bodyView, "个人资料").LoadTopView(); |
| | | //上部的白色背景 |
| | | var frameBack1 = new FrameLayout(); |
| | | frameBack1.BackgroundColor = CSS_Color.MainBackgroundColor; |
| | | frameBack1.Height = Application.GetRealHeight(204); |
| | | bodyFrameLayout.AddChidren(frameBack1); |
| | | |
| | | var headView = new FrameLayout() |
| | | //头像 |
| | | var btnHeadImage = new ImageView(); |
| | | btnHeadImage.Y = Application.GetRealHeight(32); |
| | | btnHeadImage.Gravity = Gravity.CenterHorizontal; |
| | | btnHeadImage.Width = Application.GetRealWidth(84); |
| | | btnHeadImage.Height = Application.GetRealWidth(84); |
| | | btnHeadImage.Radius = (uint)Application.GetRealWidth(42); |
| | | btnHeadImage.ImagePath = "LoginIcon/2.png"; |
| | | frameBack1.AddChidren(btnHeadImage); |
| | | |
| | | //昵称 |
| | | var btnName = new NormalViewControl(frameBack1.Width - HdlControlResourse.XXLeft * 2, Application.GetRealHeight(24), false); |
| | | btnName.Y = btnHeadImage.Bottom + Application.GetRealHeight(11); |
| | | btnName.Gravity = Gravity.CenterHorizontal; |
| | | btnName.IsBold = true; |
| | | btnName.TextSize = CSS_FontSize.SubheadingFontSize; |
| | | btnName.TextColor = CSS_Color.FirstLevelTitleColor; |
| | | btnName.Text = accountInfo.MemberName; |
| | | btnName.TextAlignment = TextAlignment.Center; |
| | | frameBack1.AddChidren(btnName); |
| | | |
| | | //账号 |
| | | var btnAccount = new NormalViewControl(frameBack1.Width - HdlControlResourse.XXLeft * 2, Application.GetRealHeight(16), false); |
| | | btnAccount.Y = btnName.Bottom + Application.GetRealHeight(7); |
| | | btnAccount.Gravity = Gravity.CenterHorizontal; |
| | | btnAccount.TextSize = CSS_FontSize.PromptFontSize_FirstLevel; |
| | | btnAccount.TextAlignment = TextAlignment.Center; |
| | | btnAccount.Text = accountInfo.Account; |
| | | frameBack1.AddChidren(btnAccount); |
| | | |
| | | //确认的白色背景 |
| | | var frameBack2 = new FrameLayout(); |
| | | frameBack2.Y = frameBack1.Bottom + Application.GetRealHeight(8); |
| | | frameBack2.Height = Application.GetRealHeight(50); |
| | | frameBack2.BackgroundColor = CSS_Color.MainBackgroundColor; |
| | | bodyFrameLayout.AddChidren(frameBack2); |
| | | //确认过户 |
| | | var btnConform = new NormalViewControl(200, 24, true); |
| | | btnConform.Gravity = Gravity.Center; |
| | | btnConform.TextSize = CSS_FontSize.SubheadingFontSize; |
| | | btnConform.TextAlignment = TextAlignment.Center; |
| | | btnConform.TextColor = CSS_Color.MainColor; |
| | | btnConform.TextID = StringId.ConfirmTransferre; |
| | | frameBack2.AddChidren(btnConform); |
| | | btnConform.ButtonClickEvent += (sender, e) => |
| | | { |
| | | Y = Application.GetRealHeight(64), |
| | | Height = Application.GetRealHeight(204), |
| | | BackgroundColor = CSS_Color.MainBackgroundColor, |
| | | //如果设置有安全验证,则需要验证 |
| | | HdlCheckLogic.Current.CheckUnlockSecurity(true, (div) => |
| | | { |
| | | var form = new TransferingResidenceForm(); |
| | | form.AddForm(this.accountInfo); |
| | | }); |
| | | }; |
| | | bodyView.AddChidren(headView); |
| | | |
| | | ImageView myHeadImage = new ImageView() |
| | | HdlThreadLogic.Current.RunThread(() => |
| | | { |
| | | Y = Application.GetRealHeight(32), |
| | | Width = Application.GetRealWidth(84), |
| | | Height = Application.GetRealWidth(84), |
| | | Radius = (uint)Application.GetRealWidth(42), |
| | | ImagePath = UserInfo.Current.headImagePagePath, |
| | | Gravity = Gravity.CenterHorizontal, |
| | | }; |
| | | headView.AddChidren(myHeadImage); |
| | | |
| | | var btnConfirm = new Button() |
| | | //用线程去下载头像 |
| | | var headImageBytes = ImageUtlis.Current.DownHeadImageByImageKey(this.accountInfo.MemberHeadIcon, true); |
| | | if (headImageBytes != null && headImageBytes.Length > 0) |
| | | { |
| | | Y = headView.Bottom + Application.GetRealHeight(8), |
| | | Height = Application.GetRealHeight(50), |
| | | TextAlignment = TextAlignment.Center, |
| | | TextColor = CSS_Color.MainColor, |
| | | TextSize = CSS_FontSize.SubheadingFontSize, |
| | | BackgroundColor = CSS_Color.MainBackgroundColor, |
| | | Text = "确认过户" |
| | | |
| | | }; |
| | | bodyView.AddChidren(btnConfirm); |
| | | |
| | | HdlThreadLogic.Current.RunMain(() => |
| | | { |
| | | btnHeadImage.ImageBytes = headImageBytes; |
| | | }, ShowErrorMode.NO); |
| | | } |
| | | }); |
| | | } |
| | | |
| | | #endregion |
| | | } |
| | | |
| | | } |
New file |
| | |
| | | using System; |
| | | using Shared; |
| | | using HDL_ON.UI.CSS; |
| | | using HDL_ON.Stan; |
| | | using System.Collections.Generic; |
| | | |
| | | namespace HDL_ON.UI |
| | | { |
| | | /// <summary> |
| | | /// 执行过户操作的界面 |
| | | /// </summary> |
| | | public class TransferingResidenceForm : EditorCommonForm |
| | | { |
| | | #region ■ 变量声明___________________________ |
| | | |
| | | /// <summary> |
| | | /// 成员信息 |
| | | /// </summary> |
| | | private AccountInfoResult accountResult = null; |
| | | |
| | | #endregion |
| | | |
| | | #region ■ 初始化_____________________________ |
| | | |
| | | /// <summary> |
| | | /// 画面显示(底层会固定调用此方法,借以完成画面创建) |
| | | /// </summary> |
| | | /// <param name="i_accountResult">账号信息</param> |
| | | public void ShowForm(AccountInfoResult i_accountResult) |
| | | { |
| | | this.ScrollLeftEnabled = false; |
| | | |
| | | this.accountResult = i_accountResult; |
| | | |
| | | //过户 |
| | | base.SetTitleText(Language.StringByID(StringId.Transfer)); |
| | | |
| | | |
| | | //初始化中部信息 |
| | | this.InitMiddleFrame(); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 初始化中部信息 |
| | | /// </summary> |
| | | private void InitMiddleFrame() |
| | | { |
| | | //清空bodyFrame |
| | | this.ClearBodyFrame(); |
| | | |
| | | //住宅的图标 |
| | | var btnHouseIcon = new PicViewControl(93, 93); |
| | | btnHouseIcon.Y = Application.GetRealHeight(127); |
| | | btnHouseIcon.X = Application.GetRealWidth(48); |
| | | btnHouseIcon.BackgroundColor = CSS_Color.MainColor; |
| | | bodyFrameLayout.AddChidren(btnHouseIcon); |
| | | //住宅名字 (以中间为基准,左右间距16) |
| | | var btnHouseName = new NormalViewControl(bodyFrameLayout.Width / 2 - Application.GetRealWidth(16 * 2), Application.GetRealHeight(48), false); |
| | | btnHouseName.X = Application.GetRealWidth(16); |
| | | btnHouseName.Y = btnHouseIcon.Bottom + Application.GetRealHeight(10); |
| | | btnHouseName.IsBold = true; |
| | | btnHouseName.IsMoreLines = true; |
| | | btnHouseName.TextAlignment = TextAlignment.TopCenter; |
| | | btnHouseName.TextSize = CSS_FontSize.SubheadingFontSize; |
| | | btnHouseName.Text = Entity.DB_ResidenceData.Instance.CurrentRegion.homeName; |
| | | bodyFrameLayout.AddChidren(btnHouseName); |
| | | |
| | | //头像 |
| | | var imageByte = ImageUtlis.Current.ReadFile(this.accountResult.MemberHeadIcon); |
| | | var btnUserIcon = new ImageView(); |
| | | btnUserIcon.Y = btnHouseIcon.Y; |
| | | btnUserIcon.X = bodyFrameLayout.Width - Application.GetRealWidth(48) - this.GetPictrueRealSize(93); |
| | | btnUserIcon.Height = this.GetPictrueRealSize(93); |
| | | btnUserIcon.Width = this.GetPictrueRealSize(93); |
| | | btnUserIcon.Radius = (uint)this.GetPictrueRealSize(93) / 2; |
| | | if (imageByte != null && imageByte.Length > 0) |
| | | { |
| | | btnUserIcon.ImageBytes = imageByte; |
| | | } |
| | | else |
| | | { |
| | | btnUserIcon.ImagePath = "LoginIcon/2.png"; |
| | | } |
| | | bodyFrameLayout.AddChidren(btnUserIcon); |
| | | |
| | | //昵称 (以中间为基准,左右间距50) |
| | | var btnName = new NormalViewControl(btnHouseName.Width, btnHouseName.Height, false); |
| | | btnName.X = bodyFrameLayout.Width - btnHouseName.X - btnHouseName.Width; |
| | | btnName.Y = btnHouseName.Y; |
| | | btnName.IsBold = true; |
| | | btnName.IsMoreLines = true; |
| | | btnName.TextAlignment = TextAlignment.TopCenter; |
| | | btnName.TextSize = CSS_FontSize.SubheadingFontSize; |
| | | btnName.Text = accountResult.MemberName; |
| | | bodyFrameLayout.AddChidren(btnName); |
| | | |
| | | //开启连接的假想动画效果线程 |
| | | this.StartConcetionAnimeteThread(btnHouseIcon.Right + Application.GetRealWidth(10)); |
| | | |
| | | //终止 |
| | | var btnCancel = new BottomClickButton(); |
| | | btnCancel.Y = Application.GetRealHeight(392); |
| | | btnCancel.TextID = StringId.Terminate; |
| | | bodyFrameLayout.AddChidren(btnCancel); |
| | | btnCancel.ButtonClickEvent += (sender, e) => |
| | | { |
| | | this.CloseForm(); |
| | | }; |
| | | |
| | | //初始化消息控件 |
| | | this.InitMsgControl(); |
| | | |
| | | } |
| | | |
| | | #endregion |
| | | |
| | | #region ■ 假想动画___________________________ |
| | | |
| | | /// <summary> |
| | | /// 开启连接的假想动画效果线程 |
| | | /// </summary> |
| | | private void StartConcetionAnimeteThread(int XX) |
| | | { |
| | | //生成点号图样 |
| | | int pointXX = XX; |
| | | int pointWidth = Application.GetRealWidth(6); |
| | | int pointSpace = Application.GetRealWidth(5); |
| | | for (int i = 0; i < 7; i++) |
| | | { |
| | | var btnPoint = new NormalViewControl(pointWidth, Application.GetRealHeight(4), false); |
| | | btnPoint.Radius = (uint)Application.GetRealHeight(4) / 2; |
| | | btnPoint.BackgroundColor = 0xffd5d5d5; |
| | | btnPoint.Y = Application.GetRealHeight(170); |
| | | btnPoint.X = pointXX; |
| | | bodyFrameLayout.AddChidren(btnPoint); |
| | | pointXX = btnPoint.Right + Application.GetRealWidth(5); |
| | | } |
| | | |
| | | var listPoint = new List<int>(); |
| | | //跳动的间距 |
| | | int jumpSpace = pointWidth + pointSpace; |
| | | for (int i = 0; i < 7; i++) |
| | | { |
| | | //X轴+Index*(图标大小+间距) |
| | | listPoint.Add(XX + i * jumpSpace); |
| | | } |
| | | |
| | | var btnRound = new IconViewControl(8); |
| | | btnRound.Radius = (uint)btnRound.IconSize / 2; |
| | | btnRound.BackgroundColor = CSS_Color.AuxiliaryColor2; |
| | | btnRound.X = listPoint[0] - (btnRound.IconSize - pointWidth) / 2; |
| | | btnRound.Y = Application.GetRealHeight(169); |
| | | bodyFrameLayout.AddChidren(btnRound); |
| | | |
| | | HdlThreadLogic.Current.RunThread(() => |
| | | { |
| | | int index = 1; |
| | | while (this.Parent != null) |
| | | { |
| | | System.Threading.Thread.Sleep(500); |
| | | HdlThreadLogic.Current.RunMain(() => |
| | | { |
| | | if (btnRound != null) |
| | | { |
| | | btnRound.X = listPoint[index]; |
| | | index++; |
| | | if (index == listPoint.Count) |
| | | { |
| | | index = 0; |
| | | } |
| | | } |
| | | }); |
| | | } |
| | | }); |
| | | } |
| | | |
| | | #endregion |
| | | |
| | | #region ■ 执行过户___________________________ |
| | | |
| | | /// <summary> |
| | | /// 执行过户 |
| | | /// </summary> |
| | | private void DoTransferResidence() |
| | | { |
| | | this.ShowProgressBar(); |
| | | System.Threading.Thread.Sleep(1500); |
| | | //过户 |
| | | bool success = new DAL.Server.HttpServerRequest().TransferResidence(this.accountResult.Account); |
| | | |
| | | this.CloseProgressBar(); |
| | | HdlThreadLogic.Current.RunMain(() => |
| | | { |
| | | var form = new TransferResidenceResultPage(); |
| | | form.AddForm(this.accountResult, success); |
| | | form.FinishEvent += () => |
| | | { |
| | | if (success == false) |
| | | { |
| | | //重试 |
| | | HdlThreadLogic.Current.RunThread(() => |
| | | { |
| | | //执行过户 |
| | | this.DoTransferResidence(); |
| | | }); |
| | | } |
| | | else |
| | | { |
| | | for (int i = 0; i < UserInfo.Current.regionList.Count; i++) |
| | | { |
| | | //移除当前住宅Id |
| | | if (UserInfo.Current.regionList[i].id == Entity.DB_ResidenceData.Instance.CurrentRegion.id) |
| | | { |
| | | UserInfo.Current.regionList.RemoveAt(i); |
| | | UserInfo.Current.SaveUserInfo(); |
| | | break; |
| | | } |
| | | } |
| | | //关闭所有界面 |
| | | HdlFormLogic.Current.CloseAllOpenForm(); |
| | | |
| | | if (UserInfo.Current.regionList.Count == 0) |
| | | { |
| | | //没有住宅了,返回登陆界面 |
| | | HDLCommon.Current.Logout(); |
| | | } |
| | | else |
| | | { |
| | | Entity.DB_ResidenceData.Instance.CurrentRegion = UserInfo.Current.regionList[0]; |
| | | Entity.DB_ResidenceData.Instance.SaveResidenceData(); |
| | | //刷新住宅数据 |
| | | Common.ApiUtlis.Ins.DownloadData(); |
| | | |
| | | //获取主页的那个容器 |
| | | var userPage = MainPage.BasePageView.GetChildren(MainPage.BasePageView.ChildrenCount - 1) as UserPage; |
| | | if (userPage != null) |
| | | { |
| | | //刷新个人中心界面 |
| | | MainPage.CurPageIndex = 1; |
| | | userPage.ChoosePersonalCenter(); |
| | | } |
| | | } |
| | | } |
| | | }; |
| | | }); |
| | | } |
| | | |
| | | #endregion |
| | | |
| | | #region ■ 一般方法___________________________ |
| | | |
| | | /// <summary> |
| | | /// 初始化消息控件 |
| | | /// </summary> |
| | | private void InitMsgControl() |
| | | { |
| | | string msg = Language.StringByID(StringId.IsTransferingPleaseWaitting); |
| | | |
| | | //正在过户给用户,请稍后... |
| | | var btnMsg = new NormalViewControl(bodyFrameLayout.Width, Application.GetRealHeight(20), false); |
| | | btnMsg.Y = Application.GetRealHeight(300); |
| | | btnMsg.TextAlignment = TextAlignment.Center; |
| | | btnMsg.TextSize = CSS_FontSize.PromptFontSize_FirstLevel; |
| | | btnMsg.Text = msg; |
| | | bodyFrameLayout.AddChidren(btnMsg); |
| | | |
| | | HdlThreadLogic.Current.RunThread(() => |
| | | { |
| | | int timeOut = 15; |
| | | while (timeOut >= 0 && this.Parent != null) |
| | | { |
| | | HdlThreadLogic.Current.RunMain(() => |
| | | { |
| | | btnMsg.Text = msg + timeOut + "s"; |
| | | if (timeOut == 0) |
| | | { |
| | | btnMsg.Text = msg; |
| | | } |
| | | }, ShowErrorMode.NO); |
| | | System.Threading.Thread.Sleep(1000); |
| | | timeOut--; |
| | | } |
| | | if (timeOut <= 0) |
| | | { |
| | | //执行过户操作 |
| | | this.DoTransferResidence(); |
| | | } |
| | | }); |
| | | } |
| | | |
| | | #endregion |
| | | } |
| | | } |
| | |
| | | etPassword = new EditText() |
| | | { |
| | | Y = Application.GetRealWidth(100), |
| | | Height = Application.GetRealWidth(0), |
| | | Height = 1, |
| | | Foucs = true, |
| | | //Visible = false, |
| | | IsNumberKeyboardType = true, |
| | |
| | | if (UserInfo.Current.appUnlockPage.Contains("3") == true) |
| | | { |
| | | //调起安全认证 |
| | | HdlCheckLogic.Current.CheckUnlockSecurity(true, () => |
| | | HdlCheckLogic.Current.CheckUnlockSecurity(true, (div) => |
| | | { |
| | | //锁已打开 |
| | | if (div == 1) |
| | | { |
| | | HdlMessageLogic.Current.ShowMassage(ShowMsgType.TipSuccess, Language.StringByID(StringId.LockIsOpened), null, null, null, 2); |
| | | } |
| | | else |
| | | { |
| | | //为了安全,请跳转至个人中心{0}设置个人密码,并应用于门锁开锁 |
| | | HdlMessageLogic.Current.ShowMassage(ShowMsgType.Confirm, Language.StringByID(StringId.JumpToPersonalCentetToSetPasswordMsg), () => |
| | | { |
| | | var page = new AppUnlockSettingsPage(); |
| | | MainPage.BasePageView.AddChidren(page); |
| | | page.LoadPage(); |
| | | MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1; |
| | | |
| | | }, Language.StringByID(StringId.Jump)); |
| | | } |
| | | }); |
| | | } |
| | | else |
| | |
| | | /// <summary> |
| | | /// 切换到个人中心界面 |
| | | /// </summary> |
| | | void ChoosePersonalCenter() |
| | | public void ChoosePersonalCenter() |
| | | { |
| | | #if DEBUG |
| | | if(MainPage.NoLoginMode) |