diff --git a/README.md b/README.md index 65d0ed5c..9c4da54b 100644 --- a/README.md +++ b/README.md @@ -38,6 +38,16 @@ * Submit a pull request ## 2.0 +### 2.0.4 / 2018-05-27 + +- 新增了微信登录 +- 新增了用户反馈 +- 新增了退出登录 +- 新增了删除通知的功能 +- 美化了样式 +- 修复了情绪曲线的显示问题 +- 修复了更新日记时多出空白图的 bug(感谢 @煜寒了 的pr) + ### 2.0.3 / 2018-05-20 - 增加了对 emoji 的支持 diff --git a/ios/twolife.xcodeproj/project.pbxproj b/ios/twolife.xcodeproj/project.pbxproj index 983f1b3f..e39a099a 100644 --- a/ios/twolife.xcodeproj/project.pbxproj +++ b/ios/twolife.xcodeproj/project.pbxproj @@ -396,13 +396,6 @@ remoteGlobalIDString = 86D238421BD0BB9E00C75D01; remoteInfo = RCTWeChat; }; - A0FB14E920BA7DB500E71FFF /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 05901D607EDC466A94BCA43E /* RCTWeChat.xcodeproj */; - proxyType = 2; - remoteGlobalIDString = 10D6D7A41F160C250066F0F3; - remoteInfo = RCTWeChatTests; - }; /* End PBXContainerItemProxy section */ /* Begin PBXCopyFilesBuildPhase section */ @@ -878,7 +871,6 @@ isa = PBXGroup; children = ( A0FB14E820BA7DB500E71FFF /* libRCTWeChat.a */, - A0FB14EA20BA7DB500E71FFF /* RCTWeChatTests.xctest */, ); name = Products; sourceTree = ""; @@ -1372,13 +1364,6 @@ remoteRef = A0FB14E720BA7DB500E71FFF /* PBXContainerItemProxy */; sourceTree = BUILT_PRODUCTS_DIR; }; - A0FB14EA20BA7DB500E71FFF /* RCTWeChatTests.xctest */ = { - isa = PBXReferenceProxy; - fileType = wrapper.cfbundle; - path = RCTWeChatTests.xctest; - remoteRef = A0FB14E920BA7DB500E71FFF /* PBXContainerItemProxy */; - sourceTree = BUILT_PRODUCTS_DIR; - }; /* End PBXReferenceProxy section */ /* Begin PBXResourcesBuildPhase section */ diff --git a/ios/twolife.xcodeproj/project.xcworkspace/xcuserdata/airing.xcuserdatad/UserInterfaceState.xcuserstate b/ios/twolife.xcodeproj/project.xcworkspace/xcuserdata/airing.xcuserdatad/UserInterfaceState.xcuserstate index b3317482..a1369551 100644 Binary files a/ios/twolife.xcodeproj/project.xcworkspace/xcuserdata/airing.xcuserdatad/UserInterfaceState.xcuserstate and b/ios/twolife.xcodeproj/project.xcworkspace/xcuserdata/airing.xcuserdatad/UserInterfaceState.xcuserstate differ diff --git a/ios/twolife.xcodeproj/xcshareddata/xcschemes/twolife.xcscheme b/ios/twolife.xcodeproj/xcshareddata/xcschemes/twolife.xcscheme index 0d994835..32f1615d 100644 --- a/ios/twolife.xcodeproj/xcshareddata/xcschemes/twolife.xcscheme +++ b/ios/twolife.xcodeproj/xcshareddata/xcschemes/twolife.xcscheme @@ -81,7 +81,7 @@ - LSApplicationQueriesSchemes - - weixin - wechat - CFBundleDevelopmentRegion en CFBundleDisplayName @@ -22,7 +17,7 @@ CFBundlePackageType APPL CFBundleShortVersionString - 2.0.3 + 2.0.4 CFBundleSignature ???? CFBundleURLTypes @@ -39,7 +34,12 @@ CFBundleVersion - 3 + 1 + LSApplicationQueriesSchemes + + weixin + wechat + LSRequiresIPhoneOS NSAppTransportSecurity diff --git a/src/containers/login/Gender.js b/src/containers/login/Gender.js index 4abb7a9b..5aa4f3d5 100644 --- a/src/containers/login/Gender.js +++ b/src/containers/login/Gender.js @@ -49,10 +49,11 @@ export default class Gender extends Component { badges: -1 } const res = await updateUser(this.props.user, data) - + console.log(res) if (res.code === 0) { + console.log(res) - JPushModule.setAlias(this.props.user.id.toString(), success => { + JPushModule.setAlias(res.data.user.id.toString(), success => { console.log(success) }) diff --git a/src/containers/login/Options.js b/src/containers/login/Options.js index 0f883f53..caba1f4d 100644 --- a/src/containers/login/Options.js +++ b/src/containers/login/Options.js @@ -20,7 +20,7 @@ import { WIDTH, getResponsiveHeight, } from '../../common/styles' -import { SCENE_LOGIN_SIGNIN, SCENE_LOGIN_SIGNUP, SCENE_LOGIN_NICKNAME } from '../../constants/scene' +import { SCENE_LOGIN_SIGNIN, SCENE_LOGIN_SIGNUP, SCENE_LOGIN_NICKNAME, SCENE_INDEX } from '../../constants/scene' import Storage from '../../common/storage' import HttpUtils from '../../network/HttpUtils' @@ -34,7 +34,7 @@ export default class Options extends Component { } componentDidMount() { - WeChat.isWXAppInstalled().then(isWXAppInstalled => this.setState({ isWXAppInstalled: true })) + WeChat.isWXAppInstalled().then(isWXAppInstalled => this.setState({ isWXAppInstalled })) } wechat_login() { @@ -65,10 +65,10 @@ export default class Options extends Component { // 用户未绑定 if (res.code === 404) { const openid = res.data - HttpUtils.post(USERS.bind_account, { account: openid, openid}).then(res => { - if (res.code === 0) { - Actions.reset(SCENE_LOGIN_NICKNAME, { user: res.data }) - } + HttpUtils.post(USERS.bind_account, { account: openid, openid }).then(res => { + const { uid, token, timestamp } = res.key + setToken({ uid, token, timestamp }) + Actions.reset(SCENE_LOGIN_NICKNAME, { user: res.data }) }) } })