Lou
2024-01-11 a7b2f92da35cc25202265c3f54ab1020fff551f3
签名修改,人口信息采集修改
4 files modified
142 ■■■■■ changed files
common/setting.js 4 ●●●● patch | view | raw | blame | history
pages/login/login-account.vue 51 ●●●●● patch | view | raw | blame | history
subPackage/article/detail.vue 8 ●●●●● patch | view | raw | blame | history
subPackage/house/member/index.vue 79 ●●●●● patch | view | raw | blame | history
common/setting.js
@@ -10,8 +10,8 @@
    version: '2.0.0',
    // 开发环境接口Url
    // devUrl: 'http://z4042833u6.wicp.vip',
    devUrl: 'http://192.168.0.109:9528',
    // devUrl: 'https://srgdjczzxtpt.com:2080/api',
    // devUrl: 'http://192.168.0.109:9528',
    devUrl: 'https://srgdjczzxtpt.com:2080/api',
    // devUrl: 'https://kt39592615.goho.co',
    minioBaseUrl: "https://srgdjczzxtpt.com:2080/gminio/jczz/",
    // minioBaseUrl:"http://192.168.0.103:9528/",
pages/login/login-account.vue
@@ -37,18 +37,27 @@
            <view class="">
                <u-form labelPosition="top" labelWidth="60" :model="form" :rules="rules" ref="form">
                    <u-form-item borderBottom ref="phone">
                    <u-form-item :borderBottom="false" ref="phone">
                        <u-input placeholder="请输入用户名" prefixIcon="account"
                            prefixIconStyle="font-size: 28px;color: #017BFC"
                            placeholderStyle="font-size:28rpx;color:#ABABAB;"
                            customStyle="background:#fff;width:634rpx;height:120rpx;" v-model="form.phone"></u-input>
                            customStyle="background:#fff;width:634rpx;" type="number" v-model="form.phone"></u-input>
                    </u-form-item>
                    <u-form-item prop="password" borderBottom ref="password">
                        <u-input placeholder="请输入密码" prefixIcon="lock" prefixIconStyle="font-size: 28px;color: #017BFC"
                    <u-form-item prop="password" :borderBottom="false" ref="password">
                        <u-input v-if="passwordProps.passwordType == 'password'" placeholder="请输入密码" prefixIcon="lock"
                            prefixIconStyle="font-size: 28px;color: #017BFC"
                            placeholderStyle="font-size:28rpx;color:#ABABAB;"
                            customStyle="background:#fff;width:634rpx;height:120rpx;" :type="passwordProps.passwordType"
                            v-model="form.password">
                            customStyle="background:#fff;width:634rpx;" type="password" v-model="form.password">
                            <template slot="suffix">
                                <u-icon @click="showPassword" :name="passwordProps.passwordIcon" size="24"
                                    color="#9FA5C0"></u-icon>
                            </template>
                        </u-input>
                        <u-input v-if="passwordProps.passwordType == 'text'" placeholder="请输入密码" prefixIcon="lock"
                            prefixIconStyle="font-size: 28px;color: #017BFC"
                            placeholderStyle="font-size:28rpx;color:#ABABAB;"
                            customStyle="background:#fff;width:634rpx;" type="text" v-model="form.password">
                            <template slot="suffix">
                                <u-icon @click="showPassword" :name="passwordProps.passwordIcon" size="24"
                                    color="#9FA5C0"></u-icon>
@@ -56,7 +65,7 @@
                        </u-input>
                    </u-form-item>
                </u-form>
                <button class="submit-btn f-28 mt-190" @click="submit" :disabled="disabled">登录</button>
                <button class="submit-btn f-30 mt-190" @click="submit" :disabled="disabled">登录</button>
            </view>
@@ -110,7 +119,9 @@
<script>
    import md5 from '@/utils/md5.js'
    import loginMixin from '@/mixin/loginMixin'
    import { fetchUserInfo } from "@/api/user.js"
    import {
        fetchUserInfo
    } from "@/api/user.js"
    export default {
        onLoad(option) {
            const {
@@ -189,7 +200,7 @@
                        })
                        .catch(err => {
                            this.$u.func.showToast({
                                title: err.data.error_description  ||  "服务器错误"
                                title: err.data.error_description || "服务器错误"
                            })
                        })
                })
@@ -203,16 +214,16 @@
                this.passwordProps.passwordType == "password" ? this.$set(this.passwordProps, "passwordType", "text") :
                    this.$set(this.passwordProps, "passwordType", "password")
            },
            getUserInfo(data){
               fetchUserInfo(data.user_id).then(res=>{
                   console.log(res)
                   if(res.code == 200){
                           this.$u.vuex('userInfo',JSON.parse(res.data))
                    }
               })
            getUserInfo(data) {
                fetchUserInfo(data.user_id).then(res => {
                    console.log(res)
                    if (res.code == 200) {
                        this.$u.vuex('userInfo', JSON.parse(res.data))
                    }
                })
            },
        }
    }
</script>
@@ -480,4 +491,4 @@
        width: 634rpx;
        margin: 37rpx auto 0;
    }
</style>
</style>
subPackage/article/detail.vue
@@ -367,7 +367,7 @@
                this.$set(this.voteTopicList, index, item);
            },
            getParams() {
            getParams(signPath) {
                let list = JSON.parse(JSON.stringify(this.voteTopicList));
                let arr = [];
                for (let i of list) {
@@ -376,6 +376,7 @@
                        i.selected = JSON.stringify(i.selected)
                        i.articleId = this.params.id
                        i.houseCode = uni.getStorageSync("siteInfo").houseCode
                        i.signaturePath = signPath ? signPath : ""
                        arr.push(i)
                    }
                }
@@ -410,10 +411,7 @@
            },
            voteRequest(signPath) {
                let data = this.getParams()
                if (signPath) {
                    data.signaturePath = signPath
                }
                let data = this.getParams(signPath)
                communityModel.addVoteOperate(data).then(res => {
                    if (res.code == 200) {
                        uni.showToast({
subPackage/house/member/index.vue
@@ -14,7 +14,6 @@
                            </u--input>
                            <u-icon slot="right" name="arrow-right"></u-icon>
                        </u-form-item> -->
                        <u-form-item @click="showSelectBus('与业主关系','relationship')" class="form-item" labelWidth="100"
                            label="与业主关系" required prop="relationship">
                            <u--input border="none" v-model="selectDefaultName.relationship" disabled
@@ -22,20 +21,10 @@
                            </u--input>
                            <u-icon slot="right" name="arrow-right"></u-icon>
                        </u-form-item>
                        <u-form-item class="form-item" labelWidth="100" label="姓名" required prop="name">
                            <u--input border="none" v-model="form.name" placeholder="请输入姓名">
                            </u--input>
                        </u-form-item>
                        <u-form-item class="form-item" labelWidth="100" label="出生日期" prop="birthday"
                            @click="showSelectBirthday = true">
                            <u--input border="none" v-model="form.birthday" disabled disabledColor="#ffffff"
                                placeholder="请选择出生日期">
                            </u--input>
                            <u-icon slot="right" name="arrow-right"></u-icon>
                        </u-form-item>
                        <u-form-item @click="showSelectBus('证件类型','cardType')" class="form-item" labelWidth="100"
                            label="证件类型" prop="gender">
                            <u--input border="none" v-model="selectDefaultName.cardType" disabled
@@ -43,8 +32,6 @@
                            </u--input>
                            <u-icon slot="right" name="arrow-right"></u-icon>
                        </u-form-item>
                        <u-form-item v-if="form.cardType == 111" class="form-item" labelWidth="100" label="身份证号码"
                            prop="idCard">
                            <u--input border="none" type="idcard " v-model="form.idCard" placeholder="请输入身份证号码">
@@ -57,7 +44,13 @@
                            </u--input>
                        </u-form-item>
                        <u-form-item v-if="form.cardType && form.cardType != 111" class="form-item" labelWidth="100"
                            label="出生日期" prop="birthday" @click="showSelectBirthday = true">
                            <u--input border="none" v-model="form.birthday" disabled disabledColor="#ffffff"
                                placeholder="请选择出生日期">
                            </u--input>
                            <u-icon slot="right" name="arrow-right"></u-icon>
                        </u-form-item>
                        <u-form-item @click="showSelectBus('性别','gender')" class="form-item" labelWidth="100" label="性别"
                            prop="gender">
                            <u--input border="none" v-model="selectDefaultName.gender" disabled disabledColor="#ffffff"
@@ -152,8 +145,8 @@
                            </u--input>
                            <u-icon slot="right" name="arrow-right"></u-icon>
                        </u-form-item>
                        <u-form-item class="form-item" labelWidth="100" label="户籍登记地" prop="hukouRegistration">
                            <u--input border="none" v-model="form.hukouRegistration" placeholder="请输入户籍登记地">
                        <u-form-item class="form-item" labelWidth="100" label="户籍地址" prop="hukouRegistration">
                            <u--input border="none" v-model="form.hukouRegistration" placeholder="请输入户籍地址">
                            </u--input>
                        </u-form-item>
@@ -297,7 +290,7 @@
            @confirm="confirmDate" @cancel="showSelectDate = false"></u-datetime-picker>
        <u-datetime-picker :show="showSelectBirthday" v-model="currentTime" mode="date" @confirm="confirmBirthday"
            @cancel="showSelectBirthday = false"></u-datetime-picker>
            @cancel="showSelectBirthday = false" :minDate="minDate"></u-datetime-picker>
        <u-picker :defaultIndex="[homeIndex]" :closeOnClickOverlay="true" :show="showRegion" :columns="[regionList]"
            @close="showRegion = false" @cancel="showRegion = false" keyName="name" @confirm="regionSelect"></u-picker>
@@ -490,6 +483,7 @@
                id: "",
                showSelectBirthday: false,
                currentTime: Number(new Date()),
                minDate: ""
            }
        },
        created() {
@@ -498,23 +492,24 @@
        onReady() {
            this.$refs.form.setRules(this.rules)
        },
        onLoad(option) {
        async onLoad(option) {
            this.minDate = Number(new Date('1900-01-01')); //设置出生日期选择器最小值
            const data = JSON.parse(option.data)
            console.log("data==>", data)
            this.houseCode = data.houseCode;
            this.getRegionList()
            this.type = data.type;
            if (data.id) {
                this.id = data.id;
            }
            if (data.type == 1) {
                this.isEdit = false;
                this.addOrUpdateTitle = "保存"
                this.getAllBizDict()
                uni.setNavigationBarTitle({
                    title: "添加成员"
                })
                this.isEdit = false;
                this.addOrUpdateTitle = "保存"
                await this.getAllBizDict()
                this.setCardTypeDefault()
            }
            if (data.type == 2) {
                this.isEdit = true;
@@ -592,6 +587,25 @@
                this.showRegion = false;
            },
            setCardTypeDefault() {
                this.$set(this.form, "cardType", 111)
                this.$set(this.selectDefaultIndex, "cardType", 0)
                this.$set(this.selectDefaultName, "cardType", "居民身份证")
            },
            //获取身份证中的出生日期
            getBirthday(idCard) {
                // 提取出生年月日的部分
                let birthday = idCard.substring(6, 14);
                // 将八位数字转换为年月日格式
                let year = birthday.substring(0, 4);
                let month = birthday.substring(4, 6);
                let day = birthday.substring(6);
                // 返回出生日期
                return `${year}-${month}-${day}`;
            },
            async getAllBizDict() {
                // 获取角色关系字典
@@ -647,10 +661,12 @@
                            this.selectDefaultName[i] = name;
                        }
                        if (data.idCard && !data.cardType) {
                            this.$set(this.form, "cardType", this.dataList.cardType[0].dictKey)
                            this.$set(this.selectDefaultIndex, "cardType", 0)
                            this.$set(this.selectDefaultName, "cardType", "居民身份证")
                        if ((data.idCard && !data.cardType) || (!data.idCard && !data.cardType)) {
                            this.setCardTypeDefault()
                        }
                        if (data.idCard && !data.birthday) {
                            this.form.birthday = this.getBirthday(data.idCard)
                        }
                        if (data.nativePlaceAdName) {
                            this.nativePlace =
@@ -724,6 +740,13 @@
                                icon: "none"
                            })
                            return;
                        } else {
                            if (this.form.cardNo) {
                                this.form.cardNo = "";
                            }
                        }
                        if (this.form.idCard && !this.form.birthday) {
                            this.form.birthday = this.getBirthday(this.form.idCard)
                        }
                    } else {
                        if (!this.form.cardNo) {
@@ -732,6 +755,10 @@
                                icon: "none"
                            })
                            return;
                        } else {
                            if (this.form.idCard) {
                                this.form.idCard = "";
                            }
                        }
                    }
                }