Browse Source

居民编辑与查看兼容老版本,vant组件恢复

dev
mk 1 year ago
parent
commit
b7b0297d49
  1. 6
      app.json
  2. 16
      miniprogram_npm/@vant/weapp/steps/index.js
  3. 14
      miniprogram_npm/@vant/weapp/steps/index.wxml
  4. 2
      miniprogram_npm/@vant/weapp/steps/index.wxss
  5. 2
      pages/index/index.js
  6. 4
      pages/login/login.js
  7. 131
      subpages/addResi/component/expandForm/index.js
  8. 4
      subpages/addResi/component/expandForm/index.json
  9. 54
      subpages/addResi/component/expandForm/index.wxml
  10. 112
      subpages/addResi/component/expandForm/index.wxss
  11. 713
      subpages/addResi/pages/addResi/addResi.js
  12. 4
      subpages/addResi/pages/addResi/addResi.json
  13. 63
      subpages/addResi/pages/addResi/addResi.wxml
  14. 22
      subpages/addResi/pages/addResi/addResi.wxss
  15. 1426
      subpages/addResi/pages/editResi/editResi.js
  16. 8
      subpages/addResi/pages/editResi/editResi.json
  17. 271
      subpages/addResi/pages/editResi/editResi.wxml
  18. 190
      subpages/addResi/pages/editResi/editResi.wxss
  19. 14
      subpages/searchResult/pages/punchCard/punchCard.js
  20. 2
      utils/request.js

6
app.json

@ -32,7 +32,8 @@
"root": "subpages/addResi",
"name": "addResi",
"pages": [
"pages/addResi/addResi"
"pages/addResi/addResi",
"pages/editResi/editResi"
]
},
{
@ -96,7 +97,8 @@
"pages": [
"pages/index/index"
]
},{
},
{
"root": "subpages/myTroubleshootDemand",
"name": "myTroubleshootDemand",
"pages": [

16
miniprogram_npm/@vant/weapp/steps/index.js

@ -1,8 +1,6 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
var component_1 = require("../common/component");
var color_1 = require("../common/color");
(0, component_1.VantComponent)({
import { VantComponent } from '../common/component';
import { GREEN, GRAY_DARK } from '../common/color';
VantComponent({
classes: ['desc-class'],
props: {
icon: String,
@ -14,11 +12,11 @@ var color_1 = require("../common/color");
},
activeColor: {
type: String,
value: color_1.GREEN,
value: GREEN,
},
inactiveColor: {
type: String,
value: color_1.GRAY_DARK,
value: GRAY_DARK,
},
activeIcon: {
type: String,
@ -27,8 +25,8 @@ var color_1 = require("../common/color");
inactiveIcon: String,
},
methods: {
onClick: function (event) {
var index = event.currentTarget.dataset.index;
onClick(event) {
const { index } = event.currentTarget.dataset;
this.$emit('click-step', index);
},
},

14
miniprogram_npm/@vant/weapp/steps/index.wxml

@ -26,23 +26,15 @@
wx:else
class="van-step__circle"
style="{{ 'background-color: ' + (index < active ? activeColor : inactiveColor) }}"
>{{index < active ? '√' : ''}}</view>
/>
</block>
<view
wx:else
class="van-step__circle"
style="{{ 'background-color:#3974f6' }}"
>
<view class="van-step__circle__center"></view>
</view>
<!-- <van-icon wx:else name="{{ item.activeIcon || activeIcon }}" color="{{ activeColor }}" class="van-step__icon" /> -->
<van-icon wx:else name="{{ item.activeIcon || activeIcon }}" color="{{ activeColor }}" class="van-step__icon" />
</view>
<view
wx:if="{{ index !== steps.length - 1 }}"
class="van-step__line" style="{{ 'background-color: ' + (index < active ? activeColor : inactiveColor) }}"
/>
<!-- -->
</view>
</view>
</view>

2
miniprogram_npm/@vant/weapp/steps/index.wxss

@ -1 +1 @@
@import '../common/index.wxss';.van-steps{background-color:var(--steps-background-color,#fff);overflow:hidden}.van-steps--horizontal{padding:10px;box-sizing: border-box;}.van-steps--horizontal .van-step__wrapper{display:flex;overflow:hidden;position:relative;padding: 10rpx;box-sizing: border-box;}.van-steps--vertical{padding-left:10px}.van-steps--vertical .van-step__wrapper{padding:0 0 0 20px}.van-step{color:var(--step-text-color,#969799);flex:1;font-size:var(--step-font-size,14px);position:relative}.van-step--finish{color:var(--step-finish-text-color,#323233)}.van-step__circle{text-align:center;background-color:var(--step-circle-color,#98a8c7);color:#fff;border-radius:50%;height:var(--step-circle-size,15px);font-size:24rpx;text-algin:center;width:var(--step-circle-size,15px);}.van-step--horizontal{padding-bottom:14px}.van-step--horizontal:first-child .van-step__title{transform:none}.van-step--horizontal:first-child .van-step__circle-container{padding:0 8px 0 0;transform:translate3d(0,50%,0);}.van-step__circle__center{position: absolute;left:50%;top:50%;transform: translate(-50%,-50%);width: 23px;height: 23px;background-color:#d0e2fb;border-radius: 50%;z-index: -1;}.van-step--horizontal:last-child{position:absolute;right:0;width:auto}.van-step--horizontal:last-child .van-step__title{text-align:right;transform:none}.van-step--horizontal:last-child .van-step__circle-container{right:0;transform:translate3d(0,50%,0)}.van-step--horizontal .van-step__circle-container{background-color:#fff;bottom:6px;padding:0;position:absolute;transform:translate3d(-50%,50%,0);z-index:1}.van-step--horizontal .van-step__title{display:inline-block;font-size:var(--step-horizontal-title-font-size,12px);transform:translate3d(-50%,0,0)}.van-step--horizontal .van-step__line{background-color:var(--step-line-color,#ebedf0);bottom:6px;height:5px;left:0;position:absolute;right:0;transform:translate3d(0,50%,0)}.van-step--horizontal.van-step--process{color:var(--step-process-text-color,#323233)}.van-step--horizontal.van-step--process .van-step__icon{display:block;font-size:var(--step-icon-size,12px);line-height:1}.van-step--vertical{line-height:18px;padding:10px 10px 10px 0}.van-step--vertical:after{border-bottom-width:1px}.van-step--vertical:last-child:after{border-bottom-width:none}.van-step--vertical:first-child:before{background-color:#fff;content:"";height:20px;left:-15px;position:absolute;top:0;width:1px;z-index:1}.van-step--vertical .van-step__circle,.van-step--vertical .van-step__icon,.van-step--vertical .van-step__line{left:-14px;position:absolute;top:19px;transform:translate3d(-50%,-50%,0);z-index:2}.van-step--vertical .van-step__icon{background-color:var(--steps-background-color,#fff);font-size:var(--step-icon-size,12px);line-height:1}.van-step--vertical .van-step__line{background-color:var(--step-line-color,#ebedf0);height:100%;transform:translate3d(-50%,0,0);width:1px;z-index:1}
@import '../common/index.wxss';.van-steps{background-color:var(--steps-background-color,#fff);overflow:hidden}.van-steps--horizontal{padding:10px}.van-steps--horizontal .van-step__wrapper{display:flex;overflow:hidden;position:relative}.van-steps--vertical{padding-left:10px}.van-steps--vertical .van-step__wrapper{padding:0 0 0 20px}.van-step{color:var(--step-text-color,#969799);flex:1;font-size:var(--step-font-size,14px);position:relative}.van-step--finish{color:var(--step-finish-text-color,#323233)}.van-step__circle{background-color:var(--step-circle-color,#969799);border-radius:50%;height:var(--step-circle-size,5px);width:var(--step-circle-size,5px)}.van-step--horizontal{padding-bottom:14px}.van-step--horizontal:first-child .van-step__title{transform:none}.van-step--horizontal:first-child .van-step__circle-container{padding:0 8px 0 0;transform:translate3d(0,50%,0)}.van-step--horizontal:last-child{position:absolute;right:0;width:auto}.van-step--horizontal:last-child .van-step__title{text-align:right;transform:none}.van-step--horizontal:last-child .van-step__circle-container{padding:0 0 0 8px;right:0;transform:translate3d(0,50%,0)}.van-step--horizontal .van-step__circle-container{background-color:#fff;bottom:6px;padding:0 var(--padding-xs,8px);position:absolute;transform:translate3d(-50%,50%,0);z-index:1}.van-step--horizontal .van-step__title{display:inline-block;font-size:var(--step-horizontal-title-font-size,12px);transform:translate3d(-50%,0,0)}.van-step--horizontal .van-step__line{background-color:var(--step-line-color,#ebedf0);bottom:6px;height:1px;left:0;position:absolute;right:0;transform:translate3d(0,50%,0)}.van-step--horizontal.van-step--process{color:var(--step-process-text-color,#323233)}.van-step--horizontal.van-step--process .van-step__icon{display:block;font-size:var(--step-icon-size,12px);line-height:1}.van-step--vertical{line-height:18px;padding:10px 10px 10px 0}.van-step--vertical:after{border-bottom-width:1px}.van-step--vertical:last-child:after{border-bottom-width:none}.van-step--vertical:first-child:before{background-color:#fff;content:"";height:20px;left:-15px;position:absolute;top:0;width:1px;z-index:1}.van-step--vertical .van-step__circle,.van-step--vertical .van-step__icon,.van-step--vertical .van-step__line{left:-14px;position:absolute;top:19px;transform:translate3d(-50%,-50%,0);z-index:2}.van-step--vertical .van-step__icon{background-color:var(--steps-background-color,#fff);font-size:var(--step-icon-size,12px);line-height:1}.van-step--vertical .van-step__line{background-color:var(--step-line-color,#ebedf0);height:100%;transform:translate3d(-50%,0,0);width:1px;z-index:1}

2
pages/index/index.js

@ -147,7 +147,7 @@ onScrollToLower(e){
this.clearOneMessage(e.currentTarget.dataset.item.id)
if(e.currentTarget.dataset.item.msgType == 'resident_base_info'){
wx.navigateTo({
url: `/subpages/addResi/pages/addResi/addResi?type=edit&resiId=${e.currentTarget.dataset.item.targetId}`,
url: `/subpages/addResi/pages/editResi/editResi?type=edit&resiId=${e.currentTarget.dataset.item.targetId}`,
})
}else{
wx.navigateTo({

4
pages/login/login.js

@ -103,7 +103,6 @@ Page({
console.log(parm.wxCode);
userLoginlog(parm).then((res)=>{
console.log(res);
wx.hideLoading()
if(res.code == 0){
wx.switchTab({
url: '/pages/index/index',
@ -111,7 +110,6 @@ Page({
wx.setStorageSync('token', res.data.token)
}
}).catch(err=>{
wx.hideLoading()
wx.showToast({
title: res.msg,
icon:'none',
@ -119,6 +117,8 @@ Page({
})
console.log(err);
})
wx.hideLoading()
},
})
},

131
subpages/addResi/component/expandForm/index.js

@ -0,0 +1,131 @@
// subpages/addResi/com/expandForm.js
Component({
/**
* 组件的属性列表
*/
properties: {
"formList": {
"type": Array,
"value": []
},
"popupTitle":{
"type": String,
"value": ""
}
},
/**
* 组件的初始数据
*/
data: {
form:{
// 党员信息
parymemberInfoDto: {
joinTime: null,
positiveTime: null,
partyOrgId: null,
flowFlag: null,
flowActNum: null,
partyJob: null,
duty: null,
retiredFlag: null,
centerFlag: null,
studyNotNeed: null,
joinBranchName: null,
joinCommunityTime: null
},
// 残疾信息
healthDto: {
disabilityCategoryCode: null,
disabilityLevel: null,
disabilityNum: null,
disabilityDesc: null,
guardianFlag: null,
guardianName: null,
guardianMobile:null,
specialSkillFlag: null,
workCapacityFlag: null
},
// 大病信息
seriousIllnessDto: {
illnessCodes: []
},
// 慢病信息
chronicDiseaseDto: {
chronicDiseaseCodes: []
},
// 死亡信息
deathDto: {
deathTime: null
},
// 老年人
oldPeopleDto: {
oldPeopleCategories: [],
resideSituation: null,
oldSubsidy: null
},
// 低保人员
subsistenceAllowanceDto: {
reasons: [],
category:null ,
},
// 退役军人
veteranDto: {
joinArmyTime: null,
leaveArmyTime: null,
serviceUnit: null,
receiveUnit: null,
settlementAmount: null,
trainDesc: null,
employmentSituation: null,
pubWelfareJobFlag: null
},
// 保障房人员
ensureHouseDto: {
liveCommunity: null,
housingNature: null
},
// 统战人员
unitedFrontDto: {
unitedFrontType: null
},
//特扶人员
specialSupportDto: {
specialSupportType: null,//特扶类别
childName: null,//子女姓名
childGender: null,//子女性别
childDeathDate: null,//子女死亡日期
childDisabilityCategoryCode: null,//伤残类别
childDisabilityLevel: null,//伤残等级
},
// 志愿者
volunteerDto: {
volunteerCategory: []
},
},
},
// onReady(){
// },
ready: async function () {
console.log(this.data.formList);
},
/**
* 组件的方法列表
*/
methods: {
updata(){
},
hideForm(){
this.triggerEvent('hideExpandForm')
},
confirm(){
this.triggerEvent('confirmExpandForm')
},
}
})

4
subpages/addResi/component/expandForm/index.json

@ -0,0 +1,4 @@
{
"component": true,
"usingComponents": {}
}

54
subpages/addResi/component/expandForm/index.wxml

@ -0,0 +1,54 @@
<view class="title">
<text class="tag"></text> {{popupTitle}}
</view>
<view class="form_card">
<view wx:for="{{formList}}" wx:key="idnex" wx:for-item="itemP">
<view class="form_item" wx:if="{{itemP.itemType == 'select'}}">
<view class="form_item_label">{{itemP.label}}</view>
<view class="form_item_input" >
<picker bindchange="bindPicker" range-key="label" value="{{index}}" range="{{itemP.opction}}" class="gray">
请选择
</picker>
<image src="../../../../images/right.png" mode="" />
</view>
</view>
<view class="form_item" wx:if="{{itemP.itemType == 'radio'}}">
<view class="form_item_label">{{itemP.label}}</view>
<radio-group bindchange="radioChange" class="form_item_input_radio">
<label class="weui-cell weui-check__label" wx:for="{{itemP.opction}}" wx:key="{{itemP.value}}">
<view class="weui-cell__hd">
<radio value="{{item.value}}" checked="true" />
</view>
<view class="weui-cell__bd">{{item.label}}</view>
</label>
</radio-group>
</view>
<view class="form_item" wx:if="{{itemP.itemType == 'input'}}">
<view class="form_item_label">{{itemP.label}}</view>
<view class="form_item_input">
<input confirm-type="next" bindblur="bindinput" bindinput="bindinput" value="{{form[itemP.id][itemP.formName]}}" placeholder-class="gray" placeholder="请输入" />
</view>
</view>
<view class="form_item" wx:if="{{itemP.itemType == 'checkbox'}}">
<view class="form_item_label">{{itemP.label}}</view>
<view class="form_item_input">
<checkbox-group bindchange="checkboxChange">
<label class="weui-cell weui-check__label" wx:for="{{itemP.opction}}" wx:key="{{item.value}}">
<view class="weui-cell__hd">
<checkbox value="{{item.value}}" color="#3974f6" checked="{{item.checked}}"/>
</view>
<view class="weui-cell__bd">{{item.label}}</view>
</label>
</checkbox-group>
</view>
</view>
</view>
</view>
<view class="bot_btn">
<button type="default" plain="true" class="bottom_btn bottom_btn_close" bind:tap="hideForm">关闭</button>
<button type="primary" class="btn_bule bottom_btn" bind:tap="confirm">确认</button>
</view>

112
subpages/addResi/component/expandForm/index.wxss

@ -0,0 +1,112 @@
/* subpages/addResi/com/expandForm.wxss */
.title{
height: 90rpx;
line-height: 90rpx;
font-size: 34rpx;
font-family: PingFang SC;
font-weight: bold;
padding-left: 30rpx;
box-sizing: border-box;
color: #333333;
position: relative;
}
.gray{
color: #808080;
}
.form_card{
height: calc(100% - 235rpx);
overflow-y: scroll;
padding: 0 10px;
box-sizing: border-box;
}
.title .tag{
width: 10rpx;
height: 28rpx;
background: #3A80E7;
border-radius: 4rpx;
position: absolute;
left: 0rpx;
top: 50%;
transform: translateY(-14rpx);
}
.form_item{
display: flex;
align-items: center;
border-top: 1px solid #EAEAEA;
min-height: 100rpx;
}
.form_item .form_item_label{
min-width: 130rpx;
height: 100%;
line-height: 100rpx;
font-size: 32rpx;
font-family: PingFang SC;
font-weight: 500;
color: #666666;
position: relative;
}
.form_item .form_item_input{
flex: 1;
display: flex;
justify-content: space-around;
align-items: center;
margin-left: 51rpx;
overflow: hidden;
}
.form_card .form_item .form_item_input picker,
.form_card .form_item .form_item_input input{
flex: 1;
height: 100rpx;
line-height: 100rpx;
}
.form_card .form_item .form_item_input image{
height: 22rpx;
width: 22rpx;
}
.form_item .form_item_input_radio{
display: flex;
}
.form_item .weui-cell{
display: flex;
margin-left: 20rpx;
align-items: center;
}
.bot_btn{
display: flex;
background-color: #fff;
z-index: 10;
width: 100%;
justify-content: space-between;
position: fixed;
bottom: 40rpx;
left: 50%;
box-sizing: border-box;
transform: translateX(-50%);
padding: 12rpx 90rpx;
box-sizing: border-box;
padding-bottom: constant(safe-area-inset-bottom);
padding-bottom: env(safe-area-inset-bottom);
}
.bot_btn .bottom_btn{
width: 240rpx;
height: 76rpx;
border-radius: 43rpx;
text-align: center;
line-height: 76rpx;
font-size: 32rpx;
}
.bot_btn .btn_bule{
background:#3974F6;
color: #fff;
}
.bottom_btn_close{
border-color:#999999 !important;
}
.weui-cell__bd{
font-size: 24rpx;
}
.form_item_input checkbox-group{
display: flex;
flex-wrap: wrap;
}

713
subpages/addResi/pages/addResi/addResi.js

@ -1,6 +1,7 @@
// subpages/addResi/pages/addResi/addResi.js
import api from "../../../../utils/api"
var http = require('../../../../utils/request.js')
var fly = require('../../../../utils/request')
import {
cardHide
@ -28,21 +29,29 @@ Page({
stepsList: [{
text: '居住房屋',
desc: '',
inactiveIcon: 'checked',
activeIcon: 'arrow',
},
{
text: '基础信息',
desc: '',
inactiveIcon: 'checked',
activeIcon: 'arrow',
},
{
text: '拓展信息',
desc: '',
inactiveIcon: 'checked',
activeIcon: 'arrow',
},
{
text: '人员标签',
desc: '',
inactiveIcon: 'checked',
activeIcon: 'arrow',
},
], //步骤条数据
activeForm: 2,
activeForm: 0,
/** 步骤条状态 */
form: {
baseInfoDto: {
@ -141,28 +150,28 @@ Page({
employmentHardFlag: null, //是否就业困难对象;1是0不是
employmentWish: null, //劳动能力就业愿望
},
healthyDto:{ //健康状况
disabilityFlag:null, //残疾
seriousIllnessFlag:null, //大病
chronicDiseaseFlag:null, //慢病
deathFlag:null, //死亡
healthyDto: { //健康状况
disabilityFlag: null, //残疾
seriousIllnessFlag: null, //大病
chronicDiseaseFlag: null, //慢病
deathFlag: null, //死亡
},
attentionResiDto:{// 关注人群
oldPeopleFlag:null, //老年人
subsistenceAllowanceFlag:null, //低保
veteranFlag:null, //退役军人
ensureHouseFlag:null, //保障房人员
fertileWomanFlag:null, //育龄妇女
specialSupportFlag:null, //特扶人员
attentionResiDto: { // 关注人群
oldPeopleFlag: null, //老年人
subsistenceAllowanceFlag: null, //低保
veteranFlag: null, //退役军人
ensureHouseFlag: null, //保障房人员
fertileWomanFlag: null, //育龄妇女
specialSupportFlag: null, //特扶人员
},
specialResiDto:{ //特殊人群
specialResiFlag:null,
specialResiDto: { //特殊人群
specialResiFlag: null,
},
identityDto:{ //身份信息
volunteerFlag:null, //志愿者
buildingChiefFlag:null, //楼长
unitChiefFlag:null, //单元长
publicWelfareFlag:null, //公益岗
identityDto: { //身份信息
volunteerFlag: null, //志愿者
buildingChiefFlag: null, //楼长
unitChiefFlag: null, //单元长
publicWelfareFlag: null, //公益岗
},
economyDto: {
monthIncome: null, //月收入
@ -190,9 +199,14 @@ Page({
spouseSituationList: [], //配偶情况
unemploymentReasonList: [], //失业原因
employmentWishList: [], //就业意愿
genderList: [{ label: '男', value: '1' }, { label: '女', value: '2' }],
idTypeList : [
{
genderList: [{
label: '男',
value: '1'
}, {
label: '女',
value: '2'
}],
idTypeList: [{
label: '其他',
value: 0
},
@ -217,8 +231,7 @@ Page({
value: 5
}
],
binaryOptionList : [
{
binaryOptionList: [{
label: '是',
value: 1
},
@ -228,7 +241,459 @@ Page({
}
]
},
showExpand: false,
expandFormList: [],
orgList: [{
id: 'healthDto',
children: [{
label: "残疾类别",
itemType: "select",
formName: "disabilityCategoryCode",
opctionUrl: 'sys/dict/data/dictlist',
opctionParams: {
dictType: 'disability_category_code'
},
opction: []
},
{
label: "残疾等级",
itemType: "select",
formName: "disabilityLevel",
opctionUrl: 'sys/dict/data/dictlist',
opctionParams: {
dictType: 'disability_level'
},
opction: []
},
{
label: "残疾证号",
itemType: "input",
formName: "disabilityNum",
},
{
label: "残疾说明",
itemType: "input",
formName: "disabilityDesc",
},
{
label: "监护人",
itemType: "radio",
formName: "guardianFlag",
opction: [{
label: '有',
formName: '',
value: 1
},
{
label: '无',
formName: '',
value: 0
}
]
},
{
label: "监护人姓名",
itemType: "input",
formName: "guardianName",
},
{
label: "监护人联系电话",
itemType: "input",
formName: "guardianMobile",
},
{
label: "技能特长",
itemType: "radio",
formName: "specialSkillFlag",
opction: [{
label: '有',
formName: '',
value: 1
},
{
label: '无',
formName: '',
value: 0
}
]
},
{
label: "劳动能力",
itemType: "radio",
formName: "workCapacityFlag",
opction: [{
label: '有',
formName: '',
value: 1
},
{
label: '无',
formName: '',
value: 0
}
]
},
]
},
{
id: 'seriousIllnessDto',
children: [{
label: "所患大病",
itemType: "checkbox",
formName: "illnessCodes",
opctionUrl: 'sys/dict/data/dictlist',
opctionParams: {
dictType: 'illness_code'
},
opction: []
}, ]
},
{
id: 'chronicDiseaseDto',
children: [{
label: "所患慢病",
itemType: "checkbox",
formName: "chronicDiseaseCodes",
opctionUrl: 'sys/dict/data/dictlist',
opctionParams: {
dictType: 'chronic_disease_code'
},
opction: []
}, ]
},
{
id: 'deathDto',
children: [{
label: "死亡时间",
itemType: "datepicker1",
formName: "deathTime",
}, ]
},
{
id: 'oldPeopleDto',
children: [{
label: "老年人分类",
itemType: "checkbox",
formName: "oldPeopleCategories",
opctionUrl: 'sys/dict/data/dictlist',
opctionParams: {
dictType: 'oldPeople_categories'
},
opction: []
},
{
label: "居住情况",
itemType: "select",
formName: "resideSituation",
opctionUrl: 'sys/dict/data/dictlist',
opctionParams: {
dictType: 'reside_situation'
},
},
{
label: "高龄补助",
itemType: "inputNum",
formName: "oldSubsidy",
},
]
},
{
id: 'subsistenceAllowanceDto',
children: [{
label: "低保类别",
itemType: "select",
formName: "category",
opctionUrl: 'sys/dict/data/dictlist',
opctionParams: {
dictType: 'subsistence_allowance_category'
},
},
{
label: "低保享受原因",
itemType: "checkbox",
formName: "reasons",
opctionUrl: 'sys/dict/data/dictlist',
opctionParams: {
dictType: 'subsistence_allowance_reasons'
},
opction: []
},
]
},
{
id: "parymemberInfoDto",
children: [{
label: "入党时间",
itemType: "datepicker1",
formName: "joinTime",
opction: []
},
{
label: "转正时间",
itemType: "datepicker1",
formName: "positiveTime",
opction: []
},
{
label: "所属党组织",
itemType: "cascader1",
formName: "partyOrgId",
opction: []
},
{
label: "流动党员",
itemType: "radio",
formName: "flowFlag",
opction: [{
label: '是',
value: 1
},
{
label: '否',
value: 0
},
]
},
{
label: "流动党员活动证号",
itemType: "input",
formName: "flowActNum",
},
{
label: "职务",
itemType: "select",
formName: "partyJob",
opctionUrl: 'sys/dict/data/dictlist',
opctionParams: {
dictType: 'party_job'
},
opction: []
},
{
label: "工作职责",
itemType: "input",
formName: "duty",
},
{
label: "是否退休",
itemType: "radio",
formName: "retiredFlag",
opction: [{
label: '是',
value: 1
},
{
label: '否',
value: 0
},
]
}, {
label: "党员中心户",
itemType: "radio",
formName: "centerFlag",
opction: [{
label: '是',
value: 1
},
{
label: '否',
value: 0
},
]
}, {
label: "免学习",
itemType: "radio",
formName: "studyNotNeed",
opction: [{
label: '是',
value: 1
},
{
label: '否',
value: 0
},
]
}, {
label: "入党时所在党支部",
itemType: "input",
formName: "joinBranchName",
}, {
label: "组织关系转入社区时间",
itemType: "datepicker1",
formName: "joinCommunityTime",
opction: []
},
]
},
{
id: 'ensureHouseDto',
children: [{
label: "所在社区",
itemType: "input",
formName: "liveCommunity",
},
{
label: "住房性质",
itemType: "select",
formName: "housingNature",
opctionUrl: 'sys/dict/data/house',
opctionParams: {
formCode: "resi_base_info"
},
opction: []
}
]
},
{
id: 'veteranDto',
children: [{
label: "入伍时间",
itemType: "datepicker1",
formName: "joinArmyTime",
opction: []
},
{
label: "退伍时间",
itemType: "datepicker1",
formName: "leaveArmyTime",
opction: []
},
{
label: "服役单位",
itemType: "input",
formName: "serviceUnit",
},
{
label: "接收单位",
itemType: "input",
formName: "receiveUnit",
},
{
label: "待安置补助金",
itemType: "inputNum",
formName: "settlementAmount",
opction: [
]
},
{
label: "培训状况",
itemType: "input",
formName: "trainDesc",
},
{
label: "现就业情况",
itemType: "input",
formName: "employmentSituation",
},
{
label: "是否办理公益性岗位",
itemType: "radio",
formName: "pubWelfareJobFlag",
opction: [{
label: '是',
value: 1
},
{
label: '否',
value: 0
},
]
}
]
},
{
id: 'unitedFrontDto',
children: [{
label: "统战类型",
itemType: "input",
formName: "unitedFrontType",
}]
},
{
id: 'volunteerDto',
children: [{
label: "志愿者类别",
itemType: "checkbox",
formName: "volunteerCategory",
opctionUrl: 'sys/dict/data/dictlist',
opctionParams: {
dictType: "VOLUNTEER_CATEGORY"
},
opction: []
}]
},
{
id: 'specialSupportDto',
children: [
{ //0
label: "特扶类别",
itemType: "select",
formName: "specialSupportType",
opction: [{
value: '1',
label: '失独'
},
{
value: '2',
label: '伤残'
}
]
},
{ //1
label: "子女姓名",
itemType: "input",
formName: "childName",
opction: []
},
{ //2
label: "子女性别",
itemType: "select",
formName: "childGender",
opction: [{
value: '1',
label: '男'
},
{
value: '2',
label: '女'
}
]
},
{
label: "子女死亡日期",
itemType: "datepicker1",
formName: "certificateDate",
opction: [],
},
{
label: "子女伤残类别",
itemType: "select",
formName: "childDisabilityCategoryCode",
opctionUrl: 'sys/dict/data/dictlist',
opctionParams: {
dictType: 'disability_category_code'
},
opction: []
},
{
label: "子女伤残等级",
itemType: "select",
formName: "childDisabilityLevel",
opctionUrl: 'sys/dict/data/dictlist',
opctionParams: {
dictType: 'disability_level'
},
opction: []
}
]
},
],
popupTitle: '新增'
},
/**
@ -619,84 +1084,87 @@ Page({
['form.resideInfoDtos[' + e.currentTarget.dataset.indexp + '].currentResidence']: e.detail.value,
})
},
bindPlaceOfDomicileInput(e){
bindPlaceOfDomicileInput(e) {
this.setData({
['form.resideInfoDtos[' + e.currentTarget.dataset.indexp + '].placeOfDomicile']: e.detail.value,
})
},
bindOutOfTimeChange(e){
bindOutOfTimeChange(e) {
this.setData({
['form.resideInfoDtos[' + e.currentTarget.dataset.indexp + '].outOfTime']: e.detail.value,
})
},
delHouse(e){
delHouse(e) {
this.data.form.resideInfoDtos = this.data.form.resideInfoDtos.filter((item, index) => index != e.currentTarget.dataset.indexp)
this.setData({
'form.resideInfoDtos':this.data.form.resideInfoDtos
})
},
addHouse(){
this.data.form.resideInfoDtos.push(
{
// agencyName: this.$store.state.user.agencyName,
// agencyId: this.$store.state.user.agencyId,
gridId: null,//所属网格id
villageId: null,//小区id
buildId: null,//楼栋id
unitId: null,//单元id
moveOutFlag: null,
outOfTime: null,//迁出时间
homeId: null, //房屋id
placeOfDomicile: null,//户籍所在地
currentResidence: null,//现居住地
householdSituation: null,//人户状况
houseHolderRel: null,//与户主关系
resiHouseRel: null,//人房关系
optionsV: [],
optionsB: [],
optionsH: [],
optionsD: [],
}
)
this.setData({
'form.resideInfoDtos':this.data.form.resideInfoDtos
})
'form.resideInfoDtos': this.data.form.resideInfoDtos
})
},
addHouse() {
this.data.form.resideInfoDtos.push({
// agencyName: this.$store.state.user.agencyName,
// agencyId: this.$store.state.user.agencyId,
gridId: null, //所属网格id
villageId: null, //小区id
buildId: null, //楼栋id
unitId: null, //单元id
moveOutFlag: null,
outOfTime: null, //迁出时间
homeId: null, //房屋id
placeOfDomicile: null, //户籍所在地
currentResidence: null, //现居住地
householdSituation: null, //人户状况
houseHolderRel: null, //与户主关系
resiHouseRel: null, //人房关系
optionsV: [],
optionsB: [],
optionsH: [],
optionsD: [],
})
this.setData({
'form.resideInfoDtos': this.data.form.resideInfoDtos
})
},
close(){
wx.navigateBack({
delta:1
})
},
//**房屋逻辑end */
//**基础信息start */
bindNameInput(e){
bindNameInput(e) {
this.setData({
['form.baseInfoDto.name']: e.detail.value,
})
},
bindPickerChangeIdType(e){
bindPickerChangeIdType(e) {
const selectedIndex = e.detail.value;
const selectedVillage = this.data.dicts.idTypeList[selectedIndex]
this.setData({
idTypeName:selectedVillage.label,
'form.baseInfoDto.idType':selectedVillage.value
idTypeName: selectedVillage.label,
'form.baseInfoDto.idType': selectedVillage.value
})
},
bindIdNumInput(e){
bindIdNumInput(e) {
this.setData({
'form.baseInfoDto.name': e.detail.value,
})
},
bindPickerChangeNationality(e){
bindPickerChangeNationality(e) {
const selectedIndex = e.detail.value;
const selectedVillage = this.data.dicts.nationalityList[selectedIndex]
this.setData({
nationalityName:selectedVillage.label,
'form.baseInfoDto.nationality':selectedVillage.value
nationalityName: selectedVillage.label,
'form.baseInfoDto.nationality': selectedVillage.value
})
},
bindMobileInput(e){
bindMobileInput(e) {
this.setData({
'form.baseInfoDto.mobile': e.detail.value,
})
},
bindPickerChangeGender(){
bindPickerChangeGender() {
this.setData({
genderName: this.data.genderList[e.detail.value].label,
"form.gender": this.data.genderList[e.detail.value].value
@ -707,13 +1175,13 @@ Page({
'form.baseInfoDto.birthday': e.detail.value
})
},
bindPickerChangeNation(e) {
this.setData({
"form.baseInfoDto.nation": this.data.dicts.nationList[e.detail.value].value
})
},
bindPickerChangeEducation(e){
bindPickerChangeEducation(e) {
this.setData({
"form.eduInfoDto.cultureLevel": this.data.dicts.educationList[e.detail.value].value
})
@ -724,7 +1192,7 @@ Page({
marriageName: this.data.dicts.marriageList[e.detail.value].label,
})
},
bindPickerChangeSpouse(e){
bindPickerChangeSpouse(e) {
this.setData({
"form.familyInfoDto.spouseSituation": this.data.dicts.spouseSituationList[e.detail.value].value,
spouseSituationName: this.data.dicts.spouseSituationList[e.detail.value].label,
@ -735,7 +1203,7 @@ Page({
'form.baseInfoDto.nativePlace': e.detail.value
})
},
bindLocalResidenceFlag(e){
bindLocalResidenceFlag(e) {
this.setData({
'form.baseInfoDto.localResidenceFlag': e.detail.value
})
@ -748,81 +1216,81 @@ Page({
"form.religionDto.religion": e.detail.value
})
},
bindCareerStatus(e){
bindCareerStatus(e) {
this.setData({
"form.workInfoDto.careerStatus":this.data.dicts.careerStatusList[e.detail.value].value,
careerStatusName:this.data.dicts.careerStatusList[e.detail.value].label
"form.workInfoDto.careerStatus": this.data.dicts.careerStatusList[e.detail.value].value,
careerStatusName: this.data.dicts.careerStatusList[e.detail.value].label
})
},
bindWorkUnit(e){
bindWorkUnit(e) {
this.setData({
"form.workInfoDto.workUnit": e.detail.value
})
},
bindWorkOccupation(e){
bindWorkOccupation(e) {
this.setData({
"form.workInfoDto.occupation": e.detail.value
})
},
bindMonthIncome(e){
bindMonthIncome(e) {
this.setData({
"form.economyDto.monthIncome": e.detail.value
})
},
bindOriginWorkUnit(e){
bindOriginWorkUnit(e) {
this.setData({
"form.unemployedDto.originWorkUnit": e.detail.value
})
},
bindUnemploymentTime(e){
bindUnemploymentTime(e) {
this.setData({
"form.unemployedDto.unemploymentTime": e.detail.value
})
},
bindUnemploymentNum(e){
bindUnemploymentNum(e) {
this.setData({
"form.unemployedDto.unemploymentNum": e.detail.value
})
},
bindUnemploymentReason(e){
bindUnemploymentReason(e) {
this.setData({
"form.unemployedDto.unemploymentReason":this.data.dicts.unemploymentReasonList[e.detail.value].value,
unemploymentReasonName:this.data.dicts.unemploymentReasonList[e.detail.value].label
"form.unemployedDto.unemploymentReason": this.data.dicts.unemploymentReasonList[e.detail.value].value,
unemploymentReasonName: this.data.dicts.unemploymentReasonList[e.detail.value].label
})
},
bindEmploymentNum(e){
bindEmploymentNum(e) {
this.setData({
"form.unemployedDto.employmentNum": e.detail.value
})
},
bindSpecialSkill(e){
bindSpecialSkill(e) {
this.setData({
"form.unemployedDto.specialSkill": e.detail.value
})
},
bindUnempCompensationFlag(e){
bindUnempCompensationFlag(e) {
this.setData({
"form.unemployedDto.unempCompensationFlag": Number(e.detail.value)
})
},
bindEmploymentHardFlag(e){
bindEmploymentHardFlag(e) {
this.setData({
"form.unemployedDto.employmentHardFlag": Number(e.detail.value)
})
},
bindEmploymentWish(e){
bindEmploymentWish(e) {
this.setData({
"form.unemployedDto.employmentWish":this.data.dicts.employmentWishList[e.detail.value].value,
employmentWishName:this.data.dicts.employmentWishList[e.detail.value].label
"form.unemployedDto.employmentWish": this.data.dicts.employmentWishList[e.detail.value].value,
employmentWishName: this.data.dicts.employmentWishList[e.detail.value].label
})
},
bindElderlyRelation(e){
bindElderlyRelation(e) {
this.setData({
"form.familyInfoDto.elderlyRelation":this.data.dicts.houseHolderRelList[e.detail.value].value,
elderlyRelationName:this.data.dicts.houseHolderRelList[e.detail.value].label
"form.familyInfoDto.elderlyRelation": this.data.dicts.houseHolderRelList[e.detail.value].value,
elderlyRelationName: this.data.dicts.houseHolderRelList[e.detail.value].label
})
},
bindDependantMobile(e){
bindDependantMobile(e) {
this.setData({
"form.familyInfoDto.dependantMobile": e.detail.value
})
@ -830,14 +1298,61 @@ Page({
//**拓展信息end */
//**人员标签start */
bindResiLabelFlag(e){
onCloseExpandForm() {
this.setData({
showExpand: false
})
},
bindResiLabelFlag(e) {
let flagLabel = e.currentTarget.dataset.field.toString();
this.setData({
[flagLabel]: Number(e.detail.value)
[flagLabel]: Number(e.detail.value)
})
},
showDetailForm(e){
console.log(e.currentTarget.dataset.field);
showDetailForm(e) {
let arr = this.data.orgList.filter(item => item.id === e.currentTarget.dataset.dto)
const promises = arr[0].children.map(async (item) => {
const acc = {};
if (item.opctionUrl) {
try {
const data = await this.getDictDataForm(item.opctionUrl, item.opctionParams);
item.opction = data;
} catch (error) {
console.error('Error fetching options:', error);
}
}
return acc;
});
Promise.all(promises).then((results) => {
this.setData({
popupTitle: e.currentTarget.dataset.title,
expandFormList: [...arr[0].children],
showExpand: true,
})
}).catch((error) => {
console.error('Error fetching options:', error);
});
},
async getDictDataForm(url, params) {
try {
const {
data
} = await fly.post(url, params);
return data;
} catch (error) {
console.log(error, `获取 ${opctionParams.dictType} 字典`);
}
},
hideExpandForm() {
this.setData({
showExpand: false
})
},
confirmExpandForm() {
this.setData({
showExpand: false
})
}
//**人员标签end */
})

4
subpages/addResi/pages/addResi/addResi.json

@ -4,6 +4,8 @@
"wux-select": "../../../../components/dist/select",
"DynamicForms": "../../../../components/DynamicForms/DynamicForms",
"van-icon": "@vant/weapp/icon/index",
"van-steps": "@vant/weapp/steps/index"
"van-steps": "@vant/weapp/steps/index",
"van-popup":"@vant/weapp/popup/index",
"expand-form":"../../component/expandForm"
}
}

63
subpages/addResi/pages/addResi/addResi.wxml

@ -1,6 +1,6 @@
<view class="content">
<view class="form_card">
<van-steps steps="{{ stepsList }}" custom-class="steps" inactive-color="" active-color="#3974f6" active="{{ activeForm }}"></van-steps>
<view class="form_card" style="height: 100rpx;overflow: hidden;">
<van-steps steps="{{ stepsList }}" custom-class="steps" inactive-color="" active-color="#3974f6" active="{{ activeForm }}" :></van-steps>
</view>
<view class="house_box" wx:if="{{activeForm === 0}}">
<view class=" form_height_all" wx:for="{{form.resideInfoDtos}}" class="form_card" style="margin-bottom: 20rpx;" wx:for-index="indexP">
@ -543,8 +543,9 @@
</view>
</view>
<view wx:if="{{form.healthyDto.disabilityFlag === 1}}">
<view class="detail" bindtap="showDetailForm" data-field="form.healthyDto.disabilityFlag">
残疾信息
<view class="detail" data-field="form.healthyDto.disabilityFlag" bindtap="showDetailForm" data-dto="healthDto" data-title="残疾信息">
<text>残疾信息</text>
<image src="../../../../images/right.png" mode=""/>
</view>
</view>
@ -562,8 +563,9 @@
</view>
</view>
<view wx:if="{{form.healthyDto.seriousIllnessFlag === 1}}">
<view class="detail" bindtap="showDetailForm" data-field="form.healthyDto.seriousIllnessFlag">
大病信息
<view class="detail" bindtap="showDetailForm" data-field="form.healthyDto.seriousIllnessFlag" data-title="大病信息" data-dto="seriousIllnessDto">
<text>大病信息</text>
<image src="../../../../images/right.png" mode=""/>
</view>
</view>
@ -581,8 +583,9 @@
</view>
</view>
<view wx:if="{{form.healthyDto.chronicDiseaseFlag === 1}}">
<view class="detail" bindtap="showDetailForm" data-field="form.healthyDto.chronicDiseaseFlag">
慢病信息
<view class="detail" bindtap="showDetailForm" data-field="form.healthyDto.chronicDiseaseFlag" data-title="慢病信息" data-dto="chronicDiseaseDto">
<text>慢病信息</text>
<image src="../../../../images/right.png" mode=""/>
</view>
</view>
@ -600,8 +603,9 @@
</view>
</view>
<view wx:if="{{form.healthyDto.deathFlag === 1}}">
<view class="detail" bindtap="showDetailForm" data-field="form.healthyDto.deathFlag">
死亡信息
<view class="detail" bindtap="showDetailForm" data-field="form.healthyDto.deathFlag" data-dto="deathDto">
<text>死亡信息</text>
<image src="../../../../images/right.png" mode=""/>
</view>
</view>
</view>
@ -616,15 +620,16 @@
<view class="title">老年人</view>
</view>
<view class="input">
<radio-group class="radio_group" bindchange="bindResiLabelFlag" data-field="form.attentionResiDto.oldPeopleFlag">
<radio-group class="radio_group" bindchange="bindResiLabelFlag" data-field="form.attentionResiDto.oldPeopleFlag" >
<radio value="1" checked="true" color="#3974f6" />是
<radio value="0" checked="true" color="#3974f6" />否
</radio-group>
</view>
</view>
<view wx:if="{{form.attentionResiDto.oldPeopleFlag === 1}}">
<view class="detail" bindtap="showDetailForm" data-field="form.attentionResiDto.oldPeopleFlag">
老年人信息
<view class="detail" bindtap="showDetailForm" data-field="form.attentionResiDto.oldPeopleFlag" data-dto="oldPeopleDto">
<text>老年人信息</text>
<image src="../../../../images/right.png" mode=""/>
</view>
</view>
@ -640,8 +645,9 @@
</view>
</view>
<view wx:if="{{form.attentionResiDto.subsistenceAllowanceFlag === 1}}">
<view class="detail" bindtap="showDetailForm" data-field="form.attentionResiDto.subsistenceAllowanceFlag">
低保信息
<view class="detail" bindtap="showDetailForm" data-field="form.attentionResiDto.subsistenceAllowanceFlag" data-dto="subsistenceAllowanceDto">
<text>低保信息</text>
<image src="../../../../images/right.png" mode=""/>
</view>
</view>
@ -657,8 +663,9 @@
</view>
</view>
<view wx:if="{{form.attentionResiDto.veteranFlag === 1}}">
<view class="detail" bindtap="showDetailForm" data-field="form.attentionResiDto.veteranFlag">
退役军人信息
<view class="detail" bindtap="showDetailForm" data-field="form.attentionResiDto.veteranFlag" data-dto="veteranDto">
<text>退役军人信息</text>
<image src="../../../../images/right.png" mode=""/>
</view>
</view>
@ -674,8 +681,9 @@
</view>
</view>
<view wx:if="{{form.attentionResiDto.ensureHouseFlag === 1}}">
<view class="detail" bindtap="showDetailForm" data-field="form.attentionResiDto.ensureHouseFlag">
保障房人员信息
<view class="detail" bindtap="showDetailForm" data-field="form.attentionResiDto.ensureHouseFlag" data-dto="ensureHouseDto">
<text>保障房人员信息</text>
<image src="../../../../images/right.png" mode=""/>
</view>
</view>
@ -703,8 +711,9 @@
</view>
</view>
<view wx:if="{{form.attentionResiDto.specialSupportFlag === 1}}">
<view class="detail" bindtap="showDetailForm" data-field="form.attentionResiDto.specialSupportFlag">
特扶人员信息
<view class="detail" bindtap="showDetailForm" data-field="form.attentionResiDto.specialSupportFlag" data-dto="specialSupportDto">
<text>特扶人员信息</text>
<image src="../../../../images/right.png" mode=""/>
</view>
</view>
@ -714,7 +723,6 @@
<view class="title">
<text class="tag"></text> 特殊人群
</view>
<view class="form_item">
<view class="label">
<view class="title">安置帮教</view>
@ -830,8 +838,9 @@
</view>
</view>
<view wx:if="{{form.identityDto.volunteerFlag === 1}}">
<view class="detail" bindtap="showDetailForm" data-field="form.identityDto.volunteerFlag">
志愿者信息
<view class="detail" bindtap="showDetailForm" data-field="form.identityDto.volunteerFlag" data-dto="volunteerDto">
<text>志愿者信息</text>
<image src="../../../../images/right.png" mode=""/>
</view>
</view>
@ -874,9 +883,12 @@
</view>
</view>
</view>
</view>
</view>
<van-popup show="{{ showExpand }}" round custom-style="width:90%;height:90%;" bind:close="onCloseExpandForm" wx:if="{{showExpand}}">
<expand-form bind:hideExpandForm="hideExpandForm" formList="{{expandFormList}}" popupTitle="{{popupTitle}}" bind:confirmExpandForm="confirmExpandForm"></expand-form>
</van-popup>
<view class="bot_btn">
<button type="default" plain="true" class="bottom_btn bottom_btn_close" bind:tap="close" wx:if="{{activeForm === 0}}">取消</button>
<button type="default" plain="true" class="bottom_btn bottom_btn_close" bind:tap="backStep" wx:else>上一步</button>
@ -885,5 +897,4 @@
</view>
<wux-select id="wux-select3" />
<!-- <DynamicForms show="{{isShowDynamicForms}}" title="{{dynamicFormsTitle}}" bind:close="closeDynamicForms" bind:ok="okDynamicForms" formController="{{formController}}" /> -->

22
subpages/addResi/pages/addResi/addResi.wxss

@ -19,7 +19,7 @@ page {
width: 100%;
padding: 0 20rpx;
box-sizing: border-box;
height:calc(100vh - 120rpx ) ;
height:calc(100vh - 160rpx ) ;
overflow-y: scroll;
@ -28,7 +28,7 @@ page {
background-color: #fff;
border-radius: 10rpx;
padding: 0 30rpx;
margin-bottom: 20rpx;
margin-top: 20rpx;
box-sizing: border-box;
}
@ -37,9 +37,7 @@ page {
margin-top: 20rpx;
overflow-y: scroll;
} */
.house_box{
height:calc(100% - 120rpx ) ;
}
.house_box .house_btn{
height: 80rpx;
width: 50%;
@ -146,21 +144,31 @@ page {
font-family: PingFang SC;
font-weight: 500;
color: #666666;
position: relative;
margin-left: 50rpx;
display: flex;
justify-content: space-between;
align-items: center;
}
.form_card .detail image{
width:20rpx;
height: 20rpx;
}
.bot_btn{
display: flex;
background-color: #fff;
z-index: 10;
width: 100%;
justify-content: space-between;
position: fixed;
bottom: 0;
left: 50%;
box-sizing: border-box;
transform: translateX(-50%);
padding: 12rpx 90rpx;
box-sizing: border-box;
padding-bottom: constant(safe-area-inset-bottom);
padding-bottom: env(safe-area-inset-bottom);
}
.bot_btn .bottom_btn{
width: 240rpx;

1426
subpages/addResi/pages/editResi/editResi.js

File diff suppressed because it is too large

8
subpages/addResi/pages/editResi/editResi.json

@ -0,0 +1,8 @@
{
"usingComponents": {
"wux-select": "../../../../components/dist/select",
"DynamicForms": "../../../../components/DynamicForms/DynamicForms",
"van-icon": "@vant/weapp/icon/index"
},
"navigationStyle": "custom"
}

271
subpages/addResi/pages/editResi/editResi.wxml

@ -0,0 +1,271 @@
<!--subpages/addResi/pages/addResi/addResi.wxml-->
<view class="header">
<image src="../../../../images/back.png" class="back" style=" top: {{statusHeight}}px;width: 50rpx;height: 50rpx;" bindtap="back" mode="" />
<image class="header-bg" src="../images/header.png" mode="widthFix" />
<view class="navigation" style="height: {{navigationHeight}}px; top: {{statusHeight}}px;">
{{formType == 'edit' ? '修改人口信息' : '新增人口信息'}}
</view>
<view class="content">
<view class="h2">填写居民信息</view>
<view class="tag">带 <b>*</b> 号为必填项
</view>
</view>
</view>
<view class="content">
<view class="form_card">
<view class="title">
<text class="tag"></text> 基本信息
</view>
<view class="form_item">
<view class="label">
<text class="must">*</text>
<view class="title">所在网格</view>
</view>
<view class="input">
<picker bindchange="bindPickerChangeGrid" range-key="label" value="{{index}}" range="{{gridList}}">
<view class="{{form.gridName?'':'gray'}}">
{{form.gridName ? form.gridName : '请选择'}}
</view>
</picker>
<image src="../../../../images/right.png" mode="" />
</view>
</view>
<view class="form_item">
<view class="label">
<text class="must">*</text>
<view class="title">所在小区</view>
</view>
<view class="input">
<picker bindchange="bindPickerChangevillageId" range-key="label" value="{{index}}" range="{{villageList}}">
<view class="{{villageName?'':'gray'}}">
{{villageName ? villageName : '请选择'}}
</view>
</picker>
<image src="../../../../images/right.png" mode="" />
</view>
</view>
<view class="form_item">
<view class="label">
<text class="must">*</text>
<view class="title">所在楼栋</view>
</view>
<view class="input">
<picker bindchange="bindPickerChangebuilding" range-key="label" value="{{index}}" range="{{buildingList}}">
<view class="{{buildingName?'':'gray'}}">
{{buildingName ? buildingName : '请选择'}}
</view>
</picker>
<image src="../../../../images/right.png" mode="" />
</view>
</view>
<view class="form_item">
<view class="label">
<text class="must">*</text>
<view class="title">所在单元</view>
</view>
<view class="input">
<picker bindchange="bindPickerChangeUnit" range-key="label" value="{{index}}" range="{{unitList}}">
<view class="{{unitName?'':'gray'}}">
{{unitName ? unitName : '请选择'}}
</view>
</picker>
<image src="../../../../images/right.png" mode="" />
</view>
</view>
<view class="form_house">
<view class="form_item">
<view class="label ">
<text class="must">*</text>
<view class="title">所在房屋</view>
</view>
<view class="input">
<picker bindchange="bindPickerChangeHouse" range-key="label" value="{{index}}" range="{{houseList}}">
<view class="{{houseName?'':'gray'}}">
{{houseName ? houseName : '请选择'}}
</view>
</picker>
<image src="../../../../images/right.png" mode="" />
</view>
</view>
<view class="form_bottom">选项中如无该房屋,请先
<text bind:tap="handelJump">新增房屋</text>
</view>
</view>
<view class="form_item">
<view class="label">
<text class="must">*</text>
<view class="title">姓名</view>
</view>
<view class="input">
<input confirm-type="next" bindblur="bindNameInput" bindinput="bindNameInput" value="{{form.name}}" placeholder-class="gray" placeholder="请输入" />
</view>
</view>
<view class="form_item">
<view class="label">
<text class="must">*</text>
<view class="title">性别</view>
</view>
<view class="input">
<picker bindchange="bindPickerChangeGender" range-key="label" value="{{index}}" range="{{genderList}}">
<view class="{{form.gender?'':'gray'}}">
{{genderName ? genderName : '请选择'}}
</view>
</picker>
<image src="../../../../images/right.png" mode="" />
</view>
</view>
<view class="form_item">
<view class="label">
<text class="must">*</text>
<view class="title">出生日期</view>
</view>
<view class="input">
<picker mode="date" value="{{form.birthday}}" end="{{day}}" bindchange="bindDateChange">
<view class="{{form.birthday?'':'gray'}}">
{{form.birthday ? form.birthday : '请选择'}}
</view>
</picker>
<image src="../../../../images/right.png" mode="" />
</view>
</view>
<view class="form_item">
<view class="label">
<text class="must">*</text>
<view class="title">证件号</view>
</view>
<view class="input">
<input confirm-type="next" bindblur="bindIdNumInput" bindinput="bindidNumInput" value="{{form.idNum}}" placeholder-class="gray" placeholder="请输入" />
<block wx:if="{{resiId}}">
<view bind:tap="showData" wx:if="{{isShowIdNum}}" data-key='idNum'>
<van-icon name="closed-eye" />
</view>
<view bind:tap="hideData" wx:else data-key='idNum'>
<van-icon name="eye-o" />
</view>
</block>
</view>
</view>
<view class="form_item">
<view class="label">
<text class="must">*</text>
<view class="title">联系电话</view>
</view>
<view class="input">
<input confirm-type="next" bindblur="bindMobileInput" bindinput="bindmobileInput" value="{{form.mobile}}" placeholder-class="gray" placeholder="请输入" />
<block wx:if="{{resiId}}">
<view bind:tap="showData" wx:if="{{isShowIdTel}}" data-key='mobile'>
<van-icon name="closed-eye" />
</view>
<view bind:tap="hideData" wx:else data-key='mobile'>
<van-icon name="eye-o" />
</view>
</block>
</view>
</view>
</view>
<view class="form_card m-top20">
<view class="title">
<text class="tag"></text> 详细信息
</view>
<view class="form_item">
<view class="label">
<view class="title">户籍地</view>
</view>
<view class="input">
<input confirm-type="next" bindblur="bindPlaceOfDomicileInput" bindinput="bindPlaceOfDomicileInput" value="{{form.resideInfoDto.placeOfDomicile}}" placeholder-class="gray" placeholder="请输入" />
</view>
</view>
<view class="form_item">
<view class="label">
<view class="title">现居地</view>
</view>
<view class="input">
<input confirm-type="next" bindblur="bindCurrentResidenceInput" bindinput="bindCurrentResidenceInput" value="{{form.resideInfoDto.currentResidence}}" placeholder-class="gray" placeholder="请输入" />
</view>
</view>
<view class="form_item">
<view class="label">
<view class="title">民族</view>
</view>
<view class="input">
<picker bindchange="bindPickerChangeNation" range-key="label" value="{{index}}" range="{{nation}}">
<view class="{{form.nation?'':'gray'}}">
{{form.nation ? nation[form.nation].label : '请选择'}}
</view>
</picker>
<image src="../../../../images/right.png" mode="" />
</view>
</view>
<view class="form_item">
<view class="label">
<view class="title">籍贯</view>
</view>
<view class="input">
<input confirm-type="next" bindblur="bindNativePlaceInput" bindinput="bindNativePlaceInput" value="{{form.resideInfoDto.nativePlace}}" placeholder-class="gray" placeholder="请输入" />
</view>
</view>
<view class="form_item">
<view class="label">
<view class="title">文化程度</view>
</view>
<view class="input">
<picker bindchange="bindPickerChangeEducation" range-key="label" value="{{index}}" range="{{education}}">
<view class="{{form.eduInfoDto.cultureLevel?'':'gray'}}">
{{form.eduInfoDto.cultureLevel ? education[form.eduInfoDto.cultureLevel].label : '请选择'}}
</view>
</picker>
<image src="../../../../images/right.png" mode="" />
</view>
</view>
<view class="form_item">
<view class="label">
<view class="title">婚姻状况</view>
</view>
<view class="input">
<picker bindchange="bindPickerChangemarriage" range-key="label" value="{{index}}" range="{{marriageList}}">
<view class="{{form.familyInfoDto.marriage?'':'gray'}}">
{{marriageName ? marriageName : '请选择'}}
</view>
</picker>
<image src="../../../../images/right.png" mode="" />
</view>
</view>
<view class="form_item ">
<view class="label">
<view class="title">宗教信仰</view>
</view>
<view class="input">
<input confirm-type="next" bindblur="bindReligionInput" bindinput="bindReligionInput" value="{{form.religionDto.religion}}" placeholder-class="gray" placeholder="请输入" />
</view>
</view>
</view>
<view class="form_card m-top20">
<view class="title">
<text class="tag"></text> 居民类别
</view>
<view class="form_item">
<view class="label">
<view class="title">居民类别</view>
</view>
<view class="input" bind:tap="onClick3">
<view class="residentCategorySty {{residentCategorySty?'':'gray'}}" style="text-align: left;">
{{residentCategorySty ? residentCategorySty : '请选择'}}
</view>
<image src="../../../../images/right.png" mode="" />
</view>
</view>
<view class="form_item" wx:for="{{residentTypeFormCell}}" :key="index" bind:tap="openDynamicForms" data-title="{{item.title}}" data-formtype="{{item.value}}">
<view class="label">
<view class="title">{{item.title}}</view>
</view>
<view class="input text-right">
<image src="../../../../images/right.png" mode="" />
</view>
</view>
</view>
<view class="bottom_btn" bind:tap="submit">提交</view>
</view>
<wux-select id="wux-select3" />
<DynamicForms show="{{isShowDynamicForms}}" title="{{dynamicFormsTitle}}" bind:close="closeDynamicForms" bind:ok="okDynamicForms" formController="{{formController}}" />

190
subpages/addResi/pages/editResi/editResi.wxss

@ -0,0 +1,190 @@
/* subpages/addResi/pages/addResi/addResi.wxss */
page {
width: 100%;
min-height: 100vh;
overflow-y: auto;
background-color: #f7f7f7;
}
.gray{
color: #C1C1C1;
}
.m-top20{
margin-top: 20rpx;
}
.header {
width: 100%;
height: 444rpx;
overflow: hidden;
/* position: fixed;
top: 0;
left: 0;
z-index: 1000; */
}
.header .header-bg {
width: 100%;
height: 444rpx;
position: absolute;
height: 100%;
z-index: -999;
}
.back {
width: 30rpx;
height: 30rpx;
margin-left: 20rpx;
position: absolute;
margin-top: 20rpx;
border-radius: 0rpx;
z-index: 101;
}
.header .navigation {
width: 100%;
display: flex;
align-items: center;
justify-content: center;
color: #333333;
font-size: 32rpx;
position: relative;
z-index: 100;
}
.header .content{
margin: 160rpx 0 0 50rpx;
}
.header .content .h2{
font-size: 44rpx;
font-family: PingFang SC;
font-weight: 800;
color: #333333;
margin-bottom: 28rpx;
}
.header .content .tag{
width: 200rpx;
height: 50rpx;
position: relative;
line-height: 48rpx;
font-size: 28rpx;
font-family: PingFang SC;
font-weight: 500;
color: #94A6C2;
padding-left: 15rpx;
}
.header .content .tag b {
color: #FF2A00;
}
.header .content .tag image {
width: 170rpx;
height: 50rpx;
position: absolute;
top: 0;
left: 0;
z-index: -888;
}
.content{
width: 100%;
height: auto;
padding: 0 20rpx;
box-sizing: border-box;
position: relative;
top: -30rpx;
}
.form_card {
background-color: #fff;
border-radius: 10rpx;
padding: 0 30rpx;
box-sizing: border-box;
height: auto;
}
.form_card > .title{
height: 90rpx;
line-height: 90rpx;
font-size: 34rpx;
font-family: PingFang SC;
font-weight: bold;
color: #333333;
position: relative;
}
.form_card .title .tag{
width: 10rpx;
height: 28rpx;
background: #3A80E7;
border-radius: 4rpx;
position: absolute;
left: -30rpx;
top: 50%;
transform: translateY(-14rpx);
}
.form_card .form_item{
display: flex;
align-items: center;
border-top: 1px solid #EAEAEA;
height: 100rpx;
}
.form_card .form_house{
height: 139rpx;
display: flex;
flex-direction: column;
}
.form_card .form_house .form_bottom{
font-size: 24rpx;
color:#C1C1C1;
position: relative;
top: -10rpx;
}
.form_card .form_house .form_bottom text{
color:#3A80E7 ;
}
.form_card .form_item .label{
min-width: 130rpx;
height: 100%;
line-height: 100rpx;
font-size: 32rpx;
font-family: PingFang SC;
font-weight: 500;
color: #666666;
position: relative;
}
.form_card .form_item .label .must{
font-size: 32rpx;
font-weight: 500;
color: #FF2A00;
position: absolute;
left: -18rpx;
top: 50%;
transform: translateY(-50rpx);
}
.form_card .form_item .input{
flex: 1;
display: flex;
justify-content: space-around;
align-items: center;
margin-left: 51rpx;
overflow: hidden;
}
.form_card .form_item .input .residentCategorySty{
flex: 1;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.form_card .form_item .input picker,
.form_card .form_item .input input{
flex: 1;
}
.form_card .form_item .input image{
height: 22rpx;
width: 22rpx;
}
.bottom_btn{
width: 600rpx;
height: 86rpx;
background: linear-gradient(87deg, #81B5FB 0%, #3E92FF 100%);
border-radius: 43rpx;
text-align: center;
color: #fff;
margin: 30rpx auto 0;
line-height: 86rpx;
}
.text-right {
text-align: right!important;
justify-content: flex-end!important;
}

14
subpages/searchResult/pages/punchCard/punchCard.js

@ -65,12 +65,12 @@ Page({
let res = await api.getResiDetail(this.data.resiId);
const {birthday,mobile,name,houseInfo,genderName} = res.data;
this.setData({
'form.name':name,
'form.birthday':birthday,
'form.mobile':mobile,
'form.gridName' :houseInfo.gridName,
'form.homeName' :houseInfo.homeName,
'form.genderName' :genderName,
'form.name':name|| '--',
'form.birthday':birthday|| '--',
'form.mobile':mobile|| '--',
'form.gridName' :'--',
'form.homeName' : '--',
'form.genderName' :genderName|| '--',
});
console.log(this.data.form);
} catch(err) {
@ -109,7 +109,7 @@ Page({
},
toAddResi(){
wx.navigateTo({
url: `/subpages/addResi/pages/addResi/addResi?type=edit&resiId=${this.data.resiId}`,
url: `/subpages/addResi/pages/editResi/editResi?type=edit&resiId=${this.data.resiId}`,
})
},
toWebView(){

2
utils/request.js

@ -14,7 +14,7 @@ const request = function (url, options) {
'Authorization': token
},
success (response) {
console.log(response);
// console.log(response);
if (response.statusCode === 200) {
if(response.data.code===0){
resolve(response.data)

Loading…
Cancel
Save