zengh
2021-06-11 5514c2e037485210c497dab59862fb94b913e7a3
安卓端初版
5 files modified
17 ■■■■■ changed files
pages/loging/loging.vue 4 ●●● patch | view | raw | blame | history
pages/myself/childen/xinxi.vue 7 ●●●● patch | view | raw | blame | history
pages/workbench/workbench.vue 2 ●●● patch | view | raw | blame | history
store/actions.js 1 ●●●● patch | view | raw | blame | history
store/mutations.js 3 ●●●● patch | view | raw | blame | history
pages/loging/loging.vue
@@ -48,11 +48,13 @@
            judgeUse() {
                var login = WxStorage.get("init") //重复登入
                var name = WxStorage.get("name")
                var userID = WxStorage.get("ids")
                // console.log(login);
                if (login == "true" && name != '') {
                    //获取用户信息
                    var data = {
                        userName: name
                        userName: name,
                        userID:userID
                    }
                    this.$store.commit('getUse', data)
                    wx.reLaunch({
pages/myself/childen/xinxi.vue
@@ -48,6 +48,7 @@
</template>
<script>
    import WxStorage from "../../../static/lib/wxStorage.js" //微信Storage
export default{
    data(){
        return{
@@ -74,9 +75,11 @@
        //获取客户信息
        getUserInfo(){
            var that = this;
            var id = JSON.stringify(this.$store.state.puserID);
            var id = JSON.stringify(that.$store.state.puserID);
            var userID = WxStorage.get("ids")
            console.log(userID)
            uni.request({
                url: 'https://web.byisf.com/api/blade-user/details?id='+this.$store.state.puserID,
                url: 'https://web.byisf.com/api/blade-user/details?id='+userID,
                method:'POST',
                success: (res) => {
                    that.user=res.data.data;
pages/workbench/workbench.vue
@@ -105,7 +105,7 @@
                        securityId: id
                    } : '',
                    that = this;
                    console.log(this.$store.state.puserID)
                    console.log(this.$store.state.puserID,'worke')
                wx.request({
                    url: url,
                    data: data,
store/actions.js
@@ -51,7 +51,6 @@
                    // data.userPhon = res.user_id;
                    store.commit('login', data);
                } 
                console.log(res)
            },
            fail: (res) => {
                console.log('失去连接 请稍等');
store/mutations.js
@@ -12,6 +12,7 @@
        //储存用户
        WxStorage.set("init", "true");
        WxStorage.set("name", data.userName);
        WxStorage.set("ids", data.userID);
    },
    loginReset(state) { //重置
        state.loging = false;
@@ -20,7 +21,7 @@
    },
    getUse(state,data){
        state.puserName = data.userName;
        // console.log(state.puserName)
        state.puserID = data.userID;
    },
    getUserData(state,data){
        state.UserData = data;