| | |
| | | parentCode |
| | | } |
| | | }) |
| | | } |
| | | |
| | | export const regionTree = () => { |
| | | return http.request({ |
| | | url: '/blade-system/region/getBaseTree', |
| | | method: 'GET' |
| | | }) |
| | | } |
| | |
| | | iconPath: '/static/img/tabbar-01.png', |
| | | url: '/pages/home/index' |
| | | }, |
| | | // { |
| | | // name: '圈子', |
| | | // iconPathSelected: '/static/img/tabbar-02-selected.png', |
| | | // iconPath: '/static/img/tabbar-02.png', |
| | | // url: '/pages/circle/index' |
| | | // }, |
| | | { |
| | | name: '圈子', |
| | | iconPathSelected: '/static/img/tabbar-02-selected.png', |
| | | iconPath: '/static/img/tabbar-02.png', |
| | | url: '/pages/circle/index' |
| | | }, |
| | | { |
| | | name: '我的', |
| | | iconPathSelected: '/static/img/tabbar-03-selected.png', |
| | |
| | | iconPath: '/static/img/tabbar-04.png', |
| | | url: '/pages/home/index' |
| | | }, |
| | | // { |
| | | // name: '圈子', |
| | | // iconPathSelected: '/static/img/tabbar-08-selected.png', |
| | | // iconPath: '/static/img/tabbar-08.png', |
| | | // url: '/pages/circle/index' |
| | | // }, |
| | | { |
| | | name: '圈子', |
| | | iconPathSelected: '/static/img/tabbar-08-selected.png', |
| | | iconPath: '/static/img/tabbar-08.png', |
| | | url: '/pages/circle/index' |
| | | }, |
| | | { |
| | | name: '驾驶舱', |
| | | iconPathSelected: '/static/img/tabbar-05-selected.png', |
| | |
| | | iconPath: '/static/img/tabbar-01.png', |
| | | url: '/pages/home/index' |
| | | }, |
| | | // { |
| | | // name: '圈子', |
| | | // iconPathSelected: '/static/img/tabbar-02-selected.png', |
| | | // iconPath: '/static/img/tabbar-02.png', |
| | | // url: '/pages/circle/index' |
| | | // }, |
| | | { |
| | | name: '圈子', |
| | | iconPathSelected: '/static/img/tabbar-02-selected.png', |
| | | iconPath: '/static/img/tabbar-02.png', |
| | | url: '/pages/circle/index' |
| | | }, |
| | | { |
| | | name: '驾驶舱', |
| | | iconPathSelected: '/static/img/tabbar-07-selected.png', |
| | |
| | | iconPath: '/static/img/tabbar-01.png', |
| | | url: '/pages/home/index' |
| | | }, |
| | | // { |
| | | // name: '圈子', |
| | | // iconPathSelected: '/static/img/tabbar-02-selected.png', |
| | | // iconPath: '/static/img/tabbar-02.png', |
| | | // url: '/pages/circle/index' |
| | | // }, |
| | | { |
| | | name: '圈子', |
| | | iconPathSelected: '/static/img/tabbar-02-selected.png', |
| | | iconPath: '/static/img/tabbar-02.png', |
| | | url: '/pages/circle/index' |
| | | }, |
| | | { |
| | | name: '驾驶舱', |
| | | iconPathSelected: '/static/img/tabbar-07-selected.png', |
| | |
| | | "navigationStyle": "custom" |
| | | } |
| | | }, |
| | | // { |
| | | // "path": "pages/circle/index", |
| | | // "style": { |
| | | // "enablePullDownRefresh": false, |
| | | // "navigationStyle": "custom" |
| | | // } |
| | | // }, |
| | | // { |
| | | // "path": "pages/circle/publish", |
| | | // "style": { |
| | | // "navigationBarTitleText": "发布", |
| | | // "navigationBarBackgroundColor": "#fff", |
| | | // "navigationBarTextStyle": "black" |
| | | // } |
| | | // }, |
| | | { |
| | | "path": "pages/circle/index", |
| | | "style": { |
| | | "enablePullDownRefresh": false, |
| | | "navigationStyle": "custom" |
| | | } |
| | | }, |
| | | { |
| | | "path": "pages/circle/publish", |
| | | "style": { |
| | | "navigationBarTitleText": "发布", |
| | | "navigationBarBackgroundColor": "#fff", |
| | | "navigationBarTextStyle": "black" |
| | | } |
| | | }, |
| | | { |
| | | "path": "pages/home/selectSite", |
| | | "style": { |
| | |
| | | "navigationBarTitleText": "资料管理", |
| | | "navigationBarBackgroundColor": "#fff", |
| | | "navigationBarTextStyle": "black", |
| | | "enablePullDownRefresh": false |
| | | "enablePullDownRefresh": false, |
| | | "usingComponents": { |
| | | "ocr-navigator": "plugin://ocr-plugin/ocr-navigator" |
| | | } |
| | | } |
| | | }, |
| | | { |
| | |
| | | "navigationBarTitleText": "人口采集", |
| | | "navigationBarBackgroundColor": "#fff", |
| | | "navigationBarTextStyle": "black", |
| | | "enablePullDownRefresh": false |
| | | "enablePullDownRefresh": false, |
| | | "usingComponents": { |
| | | "ocr-navigator": "plugin://ocr-plugin/ocr-navigator" |
| | | } |
| | | } |
| | | }, |
| | | { |
| | |
| | | "pages": [{ |
| | | "path": "add", |
| | | "style": { |
| | | "navigationBarTitleText": "反诈宣传", |
| | | "navigationBarTitleText": "反诈宣防", |
| | | "navigationBarBackgroundColor": "#fff", |
| | | "navigationBarTextStyle": "black", |
| | | "enablePullDownRefresh": false, |
| | |
| | | }, { |
| | | "path": "propagateRecord", |
| | | "style": { |
| | | "navigationBarTitleText": "反诈宣传记录", |
| | | "navigationBarTitleText": "反诈宣防记录", |
| | | "navigationBarBackgroundColor": "#fff", |
| | | "navigationBarTextStyle": "black", |
| | | "enablePullDownRefresh": false |
| | |
| | | { |
| | | "path": "propagateDetail", |
| | | "style": { |
| | | "navigationBarTitleText": "反诈宣传详情", |
| | | "navigationBarTitleText": "反诈宣防详情", |
| | | "navigationBarBackgroundColor": "#fff", |
| | | "navigationBarTextStyle": "black", |
| | | "enablePullDownRefresh": false |
| | |
| | | "iconPath": "static/img/tabbar-01.png", |
| | | "text": "首页" |
| | | }, |
| | | // { |
| | | // "pagePath": "pages/circle/index", |
| | | // "iconPath": "static/img/tabbar-02.png", |
| | | // "selectedIconPath": "static/img/tabbar-02-selected.png", |
| | | // "text": "圈子" |
| | | // }, |
| | | { |
| | | "pagePath": "pages/circle/index", |
| | | "iconPath": "static/img/tabbar-02.png", |
| | | "selectedIconPath": "static/img/tabbar-02-selected.png", |
| | | "text": "圈子" |
| | | }, |
| | | { |
| | | "pagePath": "pages/statistics/index", |
| | | "iconPath": "static/img/tabbar-02.png", |
| | |
| | | } = uni.getStorageSync("activeRole"); |
| | | if (roleName == "网格员") { |
| | | this.tabList = getTabbarList(3); |
| | | this.tabbarIndex = 1; |
| | | // this.tabbarIndex = 2; |
| | | // this.tabbarIndex = 1; |
| | | this.tabbarIndex = 2; |
| | | } |
| | | if (roleName == "民警") { |
| | | this.tabList = getTabbarList(2); |
| | | this.tabbarIndex = 1; |
| | | // this.tabbarIndex = 2; |
| | | // this.tabbarIndex = 1; |
| | | this.tabbarIndex = 2; |
| | | } |
| | | |
| | | if (roleName == "系统管理员") { |
| | | this.tabList = getTabbarList(4); |
| | | this.tabbarIndex = 1; |
| | | // this.tabbarIndex = 2; |
| | | // this.tabbarIndex = 1; |
| | | this.tabbarIndex = 2; |
| | | } |
| | | |
| | | this.refreshData(); |
| | |
| | | <u-cell v-if="roleType == 2" title="切换角色" isLink url="/subPackage/user/role/index"> |
| | | <image slot="icon" src="/static/icon/menu-center-05.png" class="icon" mode=""></image> |
| | | </u-cell> |
| | | <u-cell v-if="siteInfo.addressType == 1" title="我的网格" isLink |
| | | url="/subPackage/grid/comprehensive?from=center"> |
| | | <image slot="icon" src="/static/icon/menu-center-01.png" class="icon" mode=""></image> |
| | | </u-cell> |
| | | <u-cell v-if="siteInfo.addressType == 1" title="我的事件" isLink |
| | | url="/subPackage/bs/views/repairList?from=center"> |
| | | <image slot="icon" src="/static/icon/menu-center-01.png" class="icon" mode=""></image> |
| | |
| | | this.tabbarList = getTabbarList(1) |
| | | this.roleType = 1 |
| | | this.color = "#017BFC" |
| | | this.tabbarIndex = 1; |
| | | // this.tabbarIndex = 2 |
| | | // this.tabbarIndex = 1; |
| | | this.tabbarIndex = 2 |
| | | } else if (role.roleName == "民警") { |
| | | this.tabbarList = getTabbarList(2) |
| | | this.roleType = 2; |
| | | this.color = "#003399" |
| | | this.tabbarIndex = 2; |
| | | // this.tabbarIndex = 3; |
| | | // this.tabbarIndex = 2; |
| | | this.tabbarIndex = 3; |
| | | } else if (role.roleName == "系统管理员") { |
| | | this.tabbarList = getTabbarList(4) |
| | | this.roleType = 1 |
| | | this.color = "#017BFC"; |
| | | this.tabbarIndex = 2; |
| | | // this.tabbarIndex = 3; |
| | | // this.tabbarIndex = 2; |
| | | this.tabbarIndex = 3; |
| | | } else if (role.roleName == "网格员") { |
| | | this.tabbarList = getTabbarList(3) |
| | | this.roleType = 1 |
| | | this.color = "#017BFC"; |
| | | this.tabbarIndex = 2; |
| | | // this.tabbarIndex = 3; |
| | | // this.tabbarIndex = 2; |
| | | this.tabbarIndex = 3; |
| | | } |
| | | this.addressType = uni.getStorageSync("siteInfo").addressType; |
| | | }, |
| | |
| | | placeholderClass="f-28 c-99" inputAlign="right"></u-textarea> |
| | | </u-form-item> |
| | | |
| | | <u-form-item label="宣传内容" borderBottom prop="pubContent"> |
| | | <u-form-item label="宣防内容" borderBottom prop="pubContent"> |
| | | <u-textarea type="textarea" v-model="info.pubContent" border="none" placeholderClass="f-28 c-99" |
| | | inputAlign="right" placeholder="请输入宣传内容"> |
| | | inputAlign="right" placeholder="请输入宣防内容"> |
| | | </u-textarea> |
| | | </u-form-item> |
| | | |
| | | <!-- <u-form-item label="是否下载国家反诈app" labelWidth="120" prop="isFzApp"> |
| | | <u-form-item label="是否下载国家反诈app" labelWidth="120" prop="isFzApp"> |
| | | <u-radio-group v-model="info.isFzApp"> |
| | | <u-radio :customStyle="{marginBottom: '8px'}" v-for="(item, index) in statusList" :key="index" |
| | | :label="item.name" :name="item.id"> |
| | |
| | | :label="item.name" :name="item.id"> |
| | | </u-radio> |
| | | </u-radio-group> |
| | | </u-form-item> --> |
| | | </u-form-item> |
| | | </view> |
| | | <view class="upload bgc-ff"> |
| | | <view class="f-28">宣传佐证照片</view> |
| | | <view class="f-28">宣防佐证照片</view> |
| | | <view class="mt-20"> |
| | | <u-upload :fileList="form.images" :previewFullImage="uploadConfig.previewFullImage" |
| | | :accept="uploadConfig.acceptImg" :multiple="uploadConfig.multiple" |
| | |
| | | </view> |
| | | </view> |
| | | |
| | | <view class="info mt-20 bgc-ff" v-if="isScan"> |
| | | <view class="info mt-20 bgc-ff" v-if="isScan && houseHoldInfo.name"> |
| | | <caption-row title="房屋信息" /> |
| | | <view class="info-row flex j-c-s-b a-i-c f-28"> |
| | | <text>业主姓名</text> |
| | |
| | | </view> |
| | | </view> |
| | | |
| | | <view class="info mt-20 bgc-ff" v-if="false"> |
| | | <view class="info mt-20 bgc-ff" v-if="isScan && principalInfo.principal"> |
| | | <caption-row title="场所负责人信息" /> |
| | | <view class="info-row flex j-c-s-b a-i-c f-28"> |
| | | <text>负责人姓名</text> |
| | | <text>{{principalInfo.principal}}</text> |
| | | </view> |
| | | <view class="info-row flex j-c-s-b a-i-c f-28"> |
| | | <text>负责人手机号</text> |
| | | <text>{{principalInfo.principalPhone}}</text> |
| | | </view> |
| | | </view> |
| | | |
| | | <view class="info mt-20 bgc-ff"> |
| | | <caption-row title="宣防对象" /> |
| | | <view v-for="(item, index) in info.backblastPubPersonEntityList" :key="index"> |
| | | <view class="flex a-i-c j-c-s-b" style="padding:20rpx;"> |
| | |
| | | <u-input v-model="info.backblastPubPersonEntityList[index].address" border="none" |
| | | placeholderClass="f-28 c-99" inputAlign="right" placeholder="请输入居住地"></u-input> |
| | | </u-form-item> |
| | | |
| | | |
| | | |
| | | </view> |
| | | <view class="add-person" style="padding:20rpx 30rpx;"> |
| | | <u-button type="success" plain @click="addPerson">再加一人</u-button> |
| | |
| | | id: 2 |
| | | } |
| | | ], |
| | | personList: [] |
| | | personList: [], |
| | | principalInfo: {}, //场所负责人信息 |
| | | placeType: 1 // 1房屋 2场所 3都是 4都不是 |
| | | } |
| | | }, |
| | | // onLoad() { |
| | |
| | | this.$showTips("请选择地址") |
| | | return |
| | | } |
| | | |
| | | // if (!this.info.backblastPubPersonEntityList.length) { |
| | | // this.$showTips("请添加宣防对象") |
| | | // return; |
| | | // } else { |
| | | // for (let i of this.info.backblastPubPersonEntityList) { |
| | | // if (!i.name) { |
| | | // this.$showTips("请完善宣防对象信息") |
| | | // return; |
| | | // } |
| | | // if (!i.telephone) { |
| | | // this.$showTips("请完善宣防对象信息") |
| | | // return; |
| | | // } |
| | | // if (!i.idCard) { |
| | | // this.$showTips("请完善宣防对象信息") |
| | | // return; |
| | | // } |
| | | // } |
| | | // } |
| | | |
| | | if (!this.info.backblastPubPersonEntityList.length) { |
| | | this.$showTips("请添加宣防对象") |
| | | return; |
| | | } else { |
| | | for (let i of this.info.backblastPubPersonEntityList) { |
| | | if (!i.name) { |
| | | this.$showTips("请完善宣防对象信息") |
| | | return; |
| | | } |
| | | if (!i.telephone) { |
| | | this.$showTips("请完善宣防对象信息") |
| | | return; |
| | | } |
| | | if (!i.idCard) { |
| | | this.$showTips("请完善宣防对象信息") |
| | | return; |
| | | } |
| | | } |
| | | } |
| | | if (this.isEdit) { |
| | | this.updateWorkLogRequest() |
| | | } else { |
| | |
| | | let { |
| | | isJur, |
| | | doorplateType, |
| | | addressLevel |
| | | addressLevel, |
| | | addType |
| | | } = res.data; |
| | | if (isJur == 1) { |
| | | if (doorplateType == "户室牌") { |
| | | if (addType && addType != 4) { |
| | | if (res.data.addressType) { |
| | | this.addressType = res.data.addressType |
| | | } |
| | |
| | | this.info.lat = res.data.y; |
| | | this.info.lng = res.data.x; |
| | | this.isScan = true; |
| | | this.getHouseInfo(code) |
| | | if (addType == 1 || addType == 3) { |
| | | if (res.data.householdList.length) { |
| | | this.houseHoldInfo = res.data.householdList[0] |
| | | } else { |
| | | this.houseHoldInfo = {} |
| | | } |
| | | } |
| | | if (addType == 2 || addType == 3) { |
| | | |
| | | if (res.data.place) { |
| | | this.principalInfo = res.data.place; |
| | | } else { |
| | | this.principalInfo = {} |
| | | } |
| | | } else { |
| | | this.principalInfo = {} |
| | | } |
| | | |
| | | // this.getHouseInfo(code) |
| | | } |
| | | } else { |
| | | uni.showModal({ |
| | |
| | | url: `/subPackage/house/roomDetails/index?id=${this.info.houseCode}` |
| | | }) |
| | | }, |
| | | |
| | | |
| | | |
| | | navigatorPage() { |
| | |
| | | }, |
| | | |
| | | |
| | | |
| | | recognizePersonSuccess(e, index) { |
| | | let { |
| | | detail: { |
| | | name, |
| | | id, |
| | | address |
| | | } |
| | | } = e; |
| | | this.info.backblastPubPersonEntityList[index].name = name.text; |
| | | this.info.backblastPubPersonEntityList[index].idCard = id.text; |
| | | this.info.backblastPubPersonEntityList[index].address = address.text; |
| | | } |
| | | |
| | | |
| | |
| | | <template> |
| | | <view class=""> |
| | | <view class="bgc-ff"> |
| | | <view class="box bgc-ff"> |
| | | <view class="item-row flex j-c-s-b a-i-c"> |
| | | <text>地址</text> |
| | | <text class="address">{{detail.address}}</text> |
| | | </view> |
| | | <view class="item-row flex j-c-s-b a-i-c" v-if="detail.pubContent"> |
| | | <text>宣传内容</text> |
| | | <text>宣防内容</text> |
| | | <text class="address">{{detail.pubContent}}</text> |
| | | </view> |
| | | |
| | |
| | | <text>{{detail.createTime}}</text> |
| | | </view> |
| | | </view> |
| | | <!-- <view class="box bgc-ff" v-if="detail.context"> |
| | | <view class="caption f-28"> |
| | | 巡查内容 |
| | | |
| | | <view class="box images bgc-ff" v-if="images.length"> |
| | | <caption-row title="宣防佐证照片" /> |
| | | <view class="ml-20 mt-10"> |
| | | <u-album :urls="images" singleSize="100" multipleSize="100"></u-album> |
| | | </view> |
| | | <view class="f-30"> |
| | | {{detail.context}} |
| | | </view> |
| | | </view> --> |
| | | <view class="box bgc-ff" v-if="images.length"> |
| | | <view class="caption f-28"> |
| | | 宣传佐证照片 |
| | | </view> |
| | | <u-album :urls="images" singleSize="100" multipleSize="100"></u-album> |
| | | |
| | | </view> |
| | | |
| | | <view class="box bgc-ff"> |
| | | <caption-row title="宣防对象" /> |
| | | <view class="" v-for="(i,k) in detail.backblastPubPersonEntityList" :key="k"> |
| | | <view class="index-name f-28 fw"> |
| | | 人员-#{{k+ 1}} |
| | | </view> |
| | | <view class="item-row flex j-c-s-b a-i-c"> |
| | | <text>姓名</text> |
| | | <text>{{i.name}}</text> |
| | | </view> |
| | | <view class="item-row flex j-c-s-b a-i-c"> |
| | | <text>手机号</text> |
| | | <text>{{i.telephone}}</text> |
| | | </view> |
| | | <view class="item-row flex j-c-s-b a-i-c"> |
| | | <text>身份证号</text> |
| | | <text>{{i.idCard}}</text> |
| | | </view> |
| | | <view class="item-row flex j-c-s-b a-i-c"> |
| | | <text>职业</text> |
| | | <text>{{i.occupation}}</text> |
| | | </view> |
| | | <view class="item-row flex j-c-s-b a-i-c"> |
| | | <text>居住地</text> |
| | | <text class="address">{{i.address}}</text> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | <view class="blank"></view> |
| | | |
| | | </view> |
| | | |
| | | </template> |
| | |
| | | minioBaseUrl |
| | | } |
| | | from "@/common/setting.js" |
| | | import captionRow from "@/components/caption/caption.vue" |
| | | export default { |
| | | components: { |
| | | captionRow |
| | | }, |
| | | data() { |
| | | return { |
| | | detail: {}, |
| | |
| | | id |
| | | }).then(res => { |
| | | this.detail = res.data; |
| | | if (res.data.url) { |
| | | this.images = this.setImageUrl(res.data.url); |
| | | if (res.data.pubUrls) { |
| | | this.images = this.setImageUrl(res.data.pubUrls); |
| | | } |
| | | }) |
| | | }, |
| | |
| | | |
| | | .item-row { |
| | | width: 100%; |
| | | padding: 30rpx; |
| | | padding: 20rpx; |
| | | box-sizing: border-box; |
| | | border-bottom: 1px solid #f5f5f5; |
| | | font-size: 28rpx; |
| | |
| | | } |
| | | |
| | | .box { |
| | | padding: 0 30rpx 30rpx; |
| | | margin-top: 20rpx; |
| | | padding: 0 20rpx; |
| | | margin: 20rpx 20rpx 0; |
| | | } |
| | | |
| | | .images { |
| | | padding-bottom: 20rpx; |
| | | } |
| | | |
| | | .caption { |
| | | padding: 30rpx 0; |
| | | } |
| | | |
| | | .index-name { |
| | | padding: 20rpx 0; |
| | | margin-left: 20rpx; |
| | | } |
| | | |
| | | .blank { |
| | | width: 100%; |
| | | height: 100rpx; |
| | | } |
| | | </style> |
| | |
| | | <view class="detail bgc-ff"> |
| | | <caption-row title="网格基本情况" /> |
| | | <view class="detail-content f-28"> |
| | | <text v-for="i in houseList">{{i.aoiName?i.aoiName:''}} {{i.buildingName}} </text> |
| | | <text v-for="i in houseList" v-if="i.aoiName">{{i.aoiName?i.aoiName:''}} {{i.buildingName}} </text> |
| | | </view> |
| | | </view> |
| | | |
| | |
| | | }, |
| | | |
| | | onLoad(option) { |
| | | if (option.from) { |
| | | uni.setNavigationBarTitle({ |
| | | title: "我的网格" |
| | | }) |
| | | } |
| | | this.getDetailInfo() |
| | | }, |
| | | |
| | |
| | | <view class="container"> |
| | | <view class="main"> |
| | | <view class="content"> |
| | | <view style="padding:0 20rpx;"> |
| | | <view class="top flex j-c-s-b a-i-c bgc-ff" @click="onScan()" v-if="!currentId"> |
| | | <view class="top flex j-c-s-b a-i-c"> |
| | | <view class="top-item flex j-c-s-b a-i-c bgc-ff" @click="onScan()"> |
| | | <view class="flex a-i-c"> |
| | | <u-icon name="/static/icon/nav-05.png" width="90rpx" height="90rpx"></u-icon> |
| | | <text class="f-28 ml-10">扫码获取信息</text> |
| | | </view> |
| | | <u-icon name="arrow-right" size="20"></u-icon> |
| | | <!-- <u-icon name="arrow-right" size="20"></u-icon> --> |
| | | </view> |
| | | <ocr-navigator @onSuccess="recognizeSuccess()" certificateType="idCard" :opposite="false" |
| | | style="width:48%;"> |
| | | <view class="top-item flex j-c-s-b a-i-c bgc-ff" style="width:100%;"> |
| | | <view class="flex a-i-c"> |
| | | <u-icon name="/static/icon/nav-05.png" width="90rpx" height="90rpx"></u-icon> |
| | | <text class="f-28 ml-10">身份证信息识别</text> |
| | | </view> |
| | | <!-- <u-icon name="arrow-right" size="20"></u-icon> --> |
| | | </view> |
| | | </ocr-navigator> |
| | | </view> |
| | | |
| | | <u-form labelWidth="70" :model="form" :rules="rules" ref="form"> |
| | |
| | | </view> |
| | | |
| | | |
| | | <view class="footer flex j-c-s-b a-i-c bgc-ff" v-if="type == 2 && from == 'family'"> |
| | | <button class="del-btn footer-btn" @click="delAction">删除</button> |
| | | <button class="save-btn footer-btn" @click="submit">保存</button> |
| | | </view> |
| | | <!-- <view class="footer flex j-c-s-b a-i-c bgc-ff" v-if="(type == 1 && from == 'family') || !from"> |
| | | <ocr-navigator @onSuccess="recognizeSuccess()" certificateType="idCard" :opposite="false" |
| | | style="width:48%;"> |
| | | <view class="del-btn c-main footer-btn flex j-c-c a-i-c" style="width:100%;"> |
| | | <u-icon name="scan" color="#017BFC" size="24"></u-icon> |
| | | <text class="f-26 " style="margin-left: 10rpx;">身份证信息识别</text> |
| | | </view> |
| | | </ocr-navigator> |
| | | <button class="save-btn footer-btn c-ff" @click="submit">保存</button> |
| | | </view> --> |
| | | |
| | | <footer-btn v-if="(type == 1 && from == 'family') || !from" :text="addOrUpdateTitle" @click="submit" /> |
| | | </view> |
| | |
| | | } from '@/api/system/dict.js' |
| | | |
| | | import { |
| | | select |
| | | select, |
| | | regionTree |
| | | } from "@/api/system/region.js" |
| | | |
| | | |
| | |
| | | this.regionList = res.data; |
| | | } |
| | | |
| | | }) |
| | | }, |
| | | |
| | | getRegionTree(callback) { |
| | | regionTree().then(res => { |
| | | console.log("region ==>", res.data) |
| | | callback(res.data); |
| | | }) |
| | | }, |
| | | |
| | |
| | | uni.navigateTo({ |
| | | url: `/subPackage/house/roomControl/index?code=${this.houseCode}&from=home` |
| | | }) |
| | | }, |
| | | |
| | | //识别身份证信息 |
| | | recognizeSuccess(e, index) { |
| | | let { |
| | | detail: { |
| | | name, |
| | | id, |
| | | address, |
| | | gender, |
| | | nationality |
| | | } |
| | | } = e; |
| | | |
| | | this.$set(this.form, "name", name.text); |
| | | this.$set(this.form, "idCard", id.text); |
| | | this.selectDefaultName.gender = gender.text; //性别 |
| | | this.selectDefaultName.ethnicity = `${nationality.text}族`; //民族 |
| | | this.form.gender = this.getValue(this.dataList.gender, gender.text).value; |
| | | this.form.ethnicity = this.getValue(this.dataList.ethnicity, `${nationality.text}族`) |
| | | .value; |
| | | this.selectDefaultIndex.gender = [this.getValue(this.dataList.gender, gender.text).index]; |
| | | this.selectDefaultIndex.ethnicity = [this.getValue(this.dataList.ethnicity, `${nationality.text}族`) |
| | | .index |
| | | ]; |
| | | let { |
| | | province, |
| | | city, |
| | | district |
| | | } = this.extractAddressComponents(address.text); |
| | | // this.residentadDefault = [province, city, district]; //户籍地区 |
| | | // this.residentad = `${province}-${city}-${district}`; |
| | | this.$set(this.form, "hukouRegistration", address.text); |
| | | // this.getRegionTree(data => { |
| | | // for (let i = 0, ii = data.length; i < ii; i++) { |
| | | // if (data[i].name == province) { |
| | | // for (let j = 0, jj = data[i].children.length; j < jj; j++) { |
| | | // for (let k = 0, kk = data[i].children[j].children.length; k < kk; k++) { |
| | | // if (data[i].children[j].children[k].name == district) { |
| | | // this.$set(this.form, "residentAdcode", data[i].children[j].children[k].id); |
| | | // break; |
| | | // } |
| | | // } |
| | | // } |
| | | // } |
| | | // } |
| | | // }) |
| | | |
| | | }, |
| | | |
| | | |
| | | getValue(arr, name) { |
| | | for (let i = 0, ii = arr.length; i < ii; i++) { |
| | | if (arr[i].name == name) { |
| | | return { |
| | | index: i, |
| | | value: arr[i].value |
| | | } |
| | | } |
| | | } |
| | | }, |
| | | |
| | | extractAddressComponents(address) { |
| | | const provinceRegex = /(?<province>[^省]+省|[^自治区]+自治区|[^市]+市)/; |
| | | const cityRegex = /(?<city>[^市]+市|[^县]+县)/; |
| | | const districtRegex = /(?<district>[^区]+区|[^县]+县|[^乡]+乡|[^镇]+镇|[^街]+街)/; |
| | | |
| | | let province, city, district; |
| | | const provinceMatch = address.match(provinceRegex); |
| | | if (provinceMatch && provinceMatch.groups.province) { |
| | | province = provinceMatch.groups.province; |
| | | const cityMatch = address.substring(address.indexOf(province) + province.length).match(cityRegex); |
| | | if (cityMatch && cityMatch.groups.city) { |
| | | city = cityMatch.groups.city; |
| | | const districtMatch = address.substring(address.indexOf(city) + city.length).match(districtRegex); |
| | | if (districtMatch && districtMatch.groups.district) { |
| | | district = districtMatch.groups.district; |
| | | } |
| | | } |
| | | } |
| | | return { |
| | | province, |
| | | city, |
| | | district |
| | | }; |
| | | } |
| | | |
| | | } |
| | |
| | | line-height: 78rpx; |
| | | border-radius: 8rpx 8rpx 8rpx 8rpx; |
| | | font-size: 32rpx; |
| | | color: #fff; |
| | | // color: #fff; |
| | | } |
| | | |
| | | .add-btn { |
| | |
| | | } |
| | | |
| | | .del-btn { |
| | | background: linear-gradient(163deg, #FE6C5C 0%, #EA1F1F 99%); |
| | | // background: linear-gradient(163deg, #FE6C5C 0%, #EA1F1F 99%); |
| | | background-color: transparent; |
| | | border: 1px solid currentColor; |
| | | |
| | | } |
| | | |
| | |
| | | } |
| | | |
| | | .top { |
| | | padding: 20rpx; |
| | | marign: 20rpx 30rpx; |
| | | padding: 0 30rpx; |
| | | marign: 20rpx 0; |
| | | border-radius: 8rpx; |
| | | } |
| | | |
| | | .top-item { |
| | | width: 48%; |
| | | padding: 20rpx; |
| | | border-radius: 8rpx; |
| | | box-sizing: border-box; |
| | | } |
| | | </style> |
| | |
| | | <view class="container"> |
| | | <view class="main"> |
| | | <view class="content"> |
| | | |
| | | <view class="top"> |
| | | <ocr-navigator @onSuccess="recognizeSuccess()" certificateType="idCard" :opposite="false"> |
| | | <view class="top-item flex j-c-s-b a-i-c bgc-ff"> |
| | | <view class="flex a-i-c"> |
| | | <u-icon name="/static/icon/nav-05.png" width="90rpx" height="90rpx"></u-icon> |
| | | <text class="f-28 ml-10">身份证信息识别</text> |
| | | </view> |
| | | <u-icon name="arrow-right" size="20"></u-icon> |
| | | </view> |
| | | </ocr-navigator> |
| | | </view> |
| | | |
| | | |
| | | <u-form labelWidth="70" :model="form" :rules="rules" ref="form"> |
| | | <view class="event-info"> |
| | | <view class="box-title"> |
| | |
| | | <u-icon slot="right" name="arrow-right"></u-icon> |
| | | </u-form-item> |
| | | |
| | | <u-form-item v-if="volunteerOrg == '其他'" required class="form-item" labelWidth="120" label="其他志愿者组织" |
| | | prop="volunteerOrgTemp"> |
| | | <u-form-item v-if="volunteerOrg == '其他'" required class="form-item" labelWidth="120" |
| | | label="其他志愿者组织" prop="volunteerOrgTemp"> |
| | | <u--input border="none" v-model="form.volunteerOrgTemp" placeholder="请输入其他志愿者组织"> |
| | | </u--input> |
| | | </u-form-item> |
| | |
| | | </view> |
| | | |
| | | <footer-btn v-if="(type == 1 && from == 'family') || !from" :text="addOrUpdateTitle" @click="submit" /> |
| | | |
| | | <!-- <view class="footer flex j-c-s-b a-i-c bgc-ff" v-if="(type == 1 && from == 'family') || !from"> |
| | | <ocr-navigator @onSuccess="recognizeSuccess()" certificateType="idCard" :opposite="false" |
| | | style="width:48%;"> |
| | | <view class="recognize-btn c-main footer-btn flex j-c-c a-i-c" style="width:100%;"> |
| | | <u-icon name="scan" color="#017BFC" size="24"></u-icon> |
| | | <text class="f-26 " style="margin-left: 10rpx;">身份证信息识别</text> |
| | | </view> |
| | | </ocr-navigator> |
| | | <button class="save-btn footer-btn c-ff" @click="submit">{{addOrUpdateTitle}}</button> |
| | | </view> --> |
| | | |
| | | |
| | | </view> |
| | | |
| | | <!-- 事件类型下拉框 --> |
| | |
| | | } from '@/api/system/dict.js' |
| | | |
| | | import { |
| | | select |
| | | select, |
| | | regionTree |
| | | } from "@/api/system/region.js" |
| | | |
| | | import boxTitle from '../components/boxTitle/index2.vue' |
| | |
| | | volunteerOrgTypeList: ["信州义警", "蓝天救援", "其他"], |
| | | volunteerOrgTypeIndex: [0], |
| | | volunteerOrg: "", |
| | | volunteerOrgTemp:"", |
| | | volunteerOrgTemp: "", |
| | | showVolunteerOrg: false, |
| | | houseTag: "" |
| | | } |
| | |
| | | }) |
| | | }, |
| | | |
| | | getRegionTree(callback) { |
| | | regionTree().then(res => { |
| | | console.log("region ==>", res.data) |
| | | callback(res.data); |
| | | }) |
| | | }, |
| | | |
| | | |
| | | regionSelect(e) { |
| | | console.log(e); |
| | | const [result] = e.value; |
| | |
| | | .nativePlaceCityAdName, data.nativePlaceAdName |
| | | ] |
| | | } |
| | | if(data.volunteerOrg){ |
| | | if (data.volunteerOrg) { |
| | | // 信州义警", "蓝天救援", "其他 |
| | | if(data.volunteerOrg !='信州义警' && data.volunteerOrg !='蓝天救援'){ |
| | | if (data.volunteerOrg != '信州义警' && data.volunteerOrg != '蓝天救援') { |
| | | this.form.volunteerOrgTemp = data.volunteerOrg; |
| | | this.form.volunteerOrg = '其他' |
| | | this.volunteerOrg = '其他' |
| | | }else{ |
| | | } else { |
| | | this.form.volunteerOrg = data.volunteerOrg |
| | | this.volunteerOrg = data.volunteerOrg |
| | | } |
| | | } |
| | | |
| | | |
| | | if (data.residentAdName) { |
| | | this.residentad = |
| | | `${data.residentProvinceAdName}-${data.residentCityAdName}-${data.residentAdName}` |
| | |
| | | } |
| | | } |
| | | } |
| | | |
| | | |
| | | // 重新赋值 |
| | | if(this.form.volunteerOrgTemp){ |
| | | if (this.form.volunteerOrgTemp) { |
| | | this.form.volunteerOrg = this.form.volunteerOrgTemp |
| | | } |
| | | |
| | |
| | | uni.navigateTo({ |
| | | url: `/subPackage/house/roomControl/index?code=${this.houseCode}&from=house` |
| | | }) |
| | | }, |
| | | |
| | | |
| | | |
| | | //识别身份证信息 |
| | | recognizeSuccess(e, index) { |
| | | let { |
| | | detail: { |
| | | name, |
| | | id, |
| | | address, |
| | | gender, |
| | | nationality |
| | | } |
| | | } = e; |
| | | |
| | | this.$set(this.form, "name", name.text); |
| | | this.$set(this.form, "idCard", id.text); |
| | | this.selectDefaultName.gender = gender.text; //性别 |
| | | this.selectDefaultName.ethnicity = `${nationality.text}族`; //民族 |
| | | this.form.gender = this.getValue(this.dataList.gender, gender.text).value; |
| | | this.form.ethnicity = this.getValue(this.dataList.ethnicity, `${nationality.text}族`) |
| | | .value; |
| | | this.selectDefaultIndex.gender = [this.getValue(this.dataList.gender, gender.text).index]; |
| | | this.selectDefaultIndex.ethnicity = [this.getValue(this.dataList.ethnicity, `${nationality.text}族`) |
| | | .index |
| | | ]; |
| | | let { |
| | | province, |
| | | city, |
| | | district |
| | | } = this.extractAddressComponents(address.text); |
| | | // this.residentadDefault = [province, city, district]; //户籍地区 |
| | | // this.residentad = `${province}-${city}-${district}`; |
| | | this.$set(this.form, "hukouRegistration", address.text); |
| | | // this.getRegionTree(data => { |
| | | // for (let i = 0, ii = data.length; i < ii; i++) { |
| | | // if (data[i].name == province) { |
| | | // for (let j = 0, jj = data[i].children.length; j < jj; j++) { |
| | | // for (let k = 0, kk = data[i].children[j].children.length; k < kk; k++) { |
| | | // if (data[i].children[j].children[k].name == district) { |
| | | // this.$set(this.form, "residentAdcode", data[i].children[j].children[k].id); |
| | | // break; |
| | | // } |
| | | // } |
| | | // } |
| | | // } |
| | | // } |
| | | // }) |
| | | |
| | | }, |
| | | |
| | | |
| | | getValue(arr, name) { |
| | | for (let i = 0, ii = arr.length; i < ii; i++) { |
| | | if (arr[i].name == name) { |
| | | return { |
| | | index: i, |
| | | value: arr[i].value |
| | | } |
| | | } |
| | | } |
| | | }, |
| | | |
| | | extractAddressComponents(address) { |
| | | const provinceRegex = /(?<province>[^省]+省|[^自治区]+自治区|[^市]+市)/; |
| | | const cityRegex = /(?<city>[^市]+市|[^县]+县)/; |
| | | const districtRegex = /(?<district>[^区]+区|[^县]+县|[^乡]+乡|[^镇]+镇|[^街]+街)/; |
| | | |
| | | let province, city, district; |
| | | const provinceMatch = address.match(provinceRegex); |
| | | if (provinceMatch && provinceMatch.groups.province) { |
| | | province = provinceMatch.groups.province; |
| | | const cityMatch = address.substring(address.indexOf(province) + province.length).match(cityRegex); |
| | | if (cityMatch && cityMatch.groups.city) { |
| | | city = cityMatch.groups.city; |
| | | const districtMatch = address.substring(address.indexOf(city) + city.length).match(districtRegex); |
| | | if (districtMatch && districtMatch.groups.district) { |
| | | district = districtMatch.groups.district; |
| | | } |
| | | } |
| | | } |
| | | return { |
| | | province, |
| | | city, |
| | | district |
| | | }; |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | } |
| | |
| | | // height: 0; |
| | | // flex: 1; |
| | | // overflow-y: auto; |
| | | padding-bottom: 160rpx; |
| | | padding: 20rpx 0 160rpx; |
| | | // padding-bottom: 36rpx; |
| | | } |
| | | |
| | |
| | | line-height: 78rpx; |
| | | border-radius: 8rpx 8rpx 8rpx 8rpx; |
| | | font-size: 32rpx; |
| | | color: #fff; |
| | | |
| | | } |
| | | |
| | | .add-btn { |
| | | width: 100%; |
| | | background: linear-gradient(163deg, #01BDFC 0%, #017BFC 100%); |
| | | color: #fff; |
| | | } |
| | | |
| | | .del-btn { |
| | | background: linear-gradient(163deg, #FE6C5C 0%, #EA1F1F 99%); |
| | | color: #fff; |
| | | |
| | | } |
| | | |
| | | .save-btn { |
| | | background: linear-gradient(163deg, #01BDFC 0%, #017BFC 100%); |
| | | color: #fff; |
| | | } |
| | | |
| | | .recognize-btn { |
| | | background-color: transparent; |
| | | border: 1px solid currentColor; |
| | | } |
| | | } |
| | | |
| | | .top { |
| | | padding: 0 30rpx; |
| | | marign: 20rpx 0; |
| | | border-radius: 8rpx; |
| | | } |
| | | |
| | | .top-item { |
| | | width: 100%; |
| | | padding: 20rpx; |
| | | box-sizing: border-box; |
| | | } |
| | | </style> |