少年修仙传客户端代码仓库
client_Wu Xijin
2018-10-16 bc9ede28042d902a744db99da026d84c8554e12a
4121  【前端】【1.2.0】登录界面新增客服中心入口和功能界面
3个文件已修改
56 ■■■■ 已修改文件
System/Launch/LaunchWin.cs 12 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Login/LoginWin.cs 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/UserHelp/UserHelpWin.cs 42 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/Launch/LaunchWin.cs
@@ -60,17 +60,7 @@
            m_Version.text = StringUtility.Contact(VersionConfig.Get().version, "_", VersionConfig.Get().buildIndex);
            m_BuildTime.text = VersionConfig.Get().debugVersion ? VersionConfig.Get().buildTime : "";
            var hasContact = false;
            foreach (var item in Config.Instance.GetAllValues<ContactConfig>())
            {
                if (item.appid == VersionConfig.Get().appId)
                {
                    hasContact = true;
                    break;
                }
            }
            m_UserHelp.gameObject.SetActive(hasContact);
            m_UserHelp.gameObject.SetActive(Config.Instance.ContainKey<ContactConfig>(VersionConfig.Get().appId));
            if (Application.platform == RuntimePlatform.IPhonePlayer)
            {
System/Login/LoginWin.cs
@@ -66,6 +66,8 @@
            m_AlphaTween.SetStartState();
            m_SwitchAccount.gameObject.SetActive(VersionConfig.Get().versionAuthority == VersionAuthority.Release && !VersionConfig.Get().isBanShu);
            m_UserHelp.gameObject.SetActive(Config.Instance.ContainKey<ContactConfig>(VersionConfig.Get().appId));
            m_WaitServerList.gameObject.SetActive(!ServerListCenter.Instance.serverListGot);
            m_ContainerEnterGame.gameObject.SetActive(ServerListCenter.Instance.serverListGot);
            m_ContainerAccount.gameObject.SetActive(ServerListCenter.Instance.serverListGot
System/UserHelp/UserHelpWin.cs
@@ -16,10 +16,11 @@
    public class UserHelpWin : Window
    {
        [SerializeField] Button m_Close;
        [SerializeField] FunctionButton m_Issues;
        [SerializeField] FunctionButton m_Contact;
        [SerializeField] Toggle m_Issues;
        [SerializeField] Toggle m_Contact;
        [SerializeField] RectTransform m_IssueContainer;
        [SerializeField] ScrollRect m_IssueScrollRect;
        [SerializeField] UserIssueBehaviour m_IssueBehaviourPattern;
        [SerializeField] RectTransform m_ContactContainer;
        [SerializeField] Text m_QQ;
@@ -27,6 +28,7 @@
        [SerializeField] Button m_CopyQQ;
        [SerializeField] Button m_CopyPhone;
        bool inited = false;
        #region Built-in
        protected override void BindController()
        {
@@ -43,8 +45,17 @@
        protected override void OnPreOpen()
        {
            InitIssues();
            InitContact();
            if (!inited)
            {
                inited = true;
                InitIssues();
                InitContact();
            }
            m_Issues.isOn = true;
            m_Contact.isOn = false;
            DisplayIssues(true);
            DisplayContact(false);
        }
        protected override void OnAfterOpen()
@@ -58,8 +69,12 @@
        protected override void OnAfterClose()
        {
        }
        #endregion
        protected override void OnActived()
        {
            base.OnActived();
        }
        #endregion
        private void InitIssues()
        {
@@ -75,7 +90,7 @@
                var behaviour = instance.GetComponent<UserIssueBehaviour>();
                behaviours.Add(behaviour);
                behaviour.transform.SetParentEx(m_IssueContainer, Vector3.zero, Vector3.zero, Vector3.one);
                behaviour.transform.SetParentEx(m_IssueScrollRect.content, Vector3.zero, Vector3.zero, Vector3.one);
            }
            for (var i = 0; i < behaviours.Count; i++)
@@ -87,21 +102,18 @@
        private void InitContact()
        {
            var config = Config.Instance.Get<ContactConfig>(VersionConfig.Get().appId);
            m_QQ.text = config.qq;
            m_Phone.text = config.phone;
            m_QQ.text = Language.GetFromLocal(31, config.qq);
            m_Phone.text = Language.GetFromLocal(32, config.phone);
        }
        private void DisplayIssues()
        private void DisplayIssues(bool display)
        {
            m_IssueContainer.gameObject.SetActive(true);
            m_ContactContainer.gameObject.SetActive(false);
            m_IssueContainer.gameObject.SetActive(display);
        }
        private void DisplayContact()
        private void DisplayContact(bool display)
        {
            m_IssueContainer.gameObject.SetActive(false);
            m_ContactContainer.gameObject.SetActive(true);
            m_ContactContainer.gameObject.SetActive(display);
        }
        private void CopyQQ()