diff --git a/pages.json b/pages.json index d0a52358830f040573b28afce8a7dfcb37635a1f..10a1e7e4a242205cdb73047c8e4ebe1a9cc77cc5 100644 --- a/pages.json +++ b/pages.json @@ -3,7 +3,7 @@ { "path": "pages/index/index", "style": { - "navigationBarTitleText": "疫情登记", + "navigationBarTitleText": "", "app-plus": { "bounce": "none" } diff --git a/pages/fillIn/fillIn.vue b/pages/fillIn/fillIn.vue index a4d37198abee7e5f4d59352e61c5a2928f2f864e..03d094a3619056e7f53d6b8873f03f6253b6c0f0 100644 --- a/pages/fillIn/fillIn.vue +++ b/pages/fillIn/fillIn.vue @@ -61,6 +61,7 @@ *{{item.label}} + {{form[item.value]?form[item.value]:'请选择'}} @@ -98,13 +99,16 @@ + @@ -142,6 +146,24 @@ -->

根据中华人民共和国国家卫生健康委员会2020年第1号公告要求以及《国际卫生条例(2005)》、《中华人民共和国传染病防治法》等有关法律规定,并按照国务院常务会议提出的“分类有序复工复产”和上海疫情防控办及市政府《关于进一步落实各项疫情防控措施的通告》的相关要求,为做好新型冠状病毒感染的肺炎疫情防控工作,保障广大人民群众生命健康,现面向使用本系统的所有用户,特告知如下:

+ + + + + + + + + + + + 知情同意书 + + + + + +

 

本系统将对所有注册使用的用户信息进行记录,必要时将与执法部门进行信息对接,请积极配合并确保所填信息真实、有效。如若有任何瞒报情况被查出,将被有关部门依法追究法律责任并被列为失信人员,敬请配合。

 

@@ -151,6 +173,7 @@ + @@ -170,6 +193,7 @@ data() { return { modalName: false, + isRead:false, list: [{ label: '单位名称', @@ -180,6 +204,7 @@ opts: [] }, { + label: '所在部门(选填)', value: 'department', titleClass: 'title', @@ -187,6 +212,7 @@ type: 'input', }, { + label: '职务(选填)', value: 'position', titleClass: 'title', @@ -206,6 +232,7 @@ required: true, value: 'phone', titleClass: 'title', + placeholder: '请输入11位数字手机号', type: 'input', validator:validate.isPhone @@ -1043,6 +1070,7 @@ required: true, value: 'householdAddress', titleClass: 'title', + placeholder: '例:**路**号**小区**号楼**室', type: 'input', num: 8, @@ -1053,6 +1081,7 @@ required: true, value: 'residenceAddress', titleClass: 'title', + placeholder: '例:**路**号**小区**号楼**室', type: 'input', }, @@ -1587,6 +1616,7 @@ hidden: true }, { + label: '当日症状', required: true, value: 'symptom', @@ -1652,6 +1682,7 @@ methods: { openModal() { if (!this.form.agree) { + this.form.agree = 1 } else { this.form.agree = 0 @@ -1755,6 +1786,7 @@ const prop = item.value const type = item.type if (type === 'radio') { + const val = evt.value || evt.target.value this.$set(this.form, prop, val) for (let i = 0; i < this.list.length; i++) { @@ -1773,6 +1805,7 @@ } // 复选框展示和隐藏 if (type === 'pickerMore') { + let val = evt.value || evt.detail.value; const showList = item.showList if (showList && showList.length > 0) { @@ -1790,6 +1823,7 @@ } if (type === 'picker') { + let val = evt.value || item.opts[evt.detail.value].value; for (let i = 0; i < this.list.length; i++) { const current = this.list[i] diff --git a/pages/index/index.vue b/pages/index/index.vue index 2d0b623cf573556b7610b8288f4ee54b3283f6ce..915672e285f8c3e795daf9f64ee61b7720d38f83 100644 --- a/pages/index/index.vue +++ b/pages/index/index.vue @@ -2,9 +2,9 @@ - - - + + + 入园请向门卫出示健康码 @@ -37,15 +37,12 @@ imgSrc:'', modalName:'', flag:true, - option:{ - userId:'' - } + securityFlag:false, + userId:'' }; }, onLoad: function(option) { - const scene = decodeURIComponent(option.scene) - console.log(scene) - this.option = option + this.userId = option.u let that = this // #ifdef MP-WEIXIN wx.login({ @@ -84,16 +81,36 @@ }, // 安保跳转 - security() { - uni.navigateTo({ - url: `/pages/security/security` + // security() { + // uni.navigateTo({ + // url: `/pages/security/security?userId=${this.userId}` + // }) + // }, + getScancode(){ + var _this = this; + // 允许从相机和相册扫码 + wx.scanCode({ + success: (res) => { + var result = res.result; + + _this.setData({ + result: result, + + }) + } }) }, fillInDay() { - console.log(232) - uni.navigateTo({ - url:`/pages/fillInDay/fillInDay` - }) + if(!this.$store.state.user.userInfo.idCard){ + uni.showToast({ + icon: 'none', + title: '请先上报个人资料!' + }) + }else{ + uni.navigateTo({ + url:`/pages/fillInDay/fillInDay` + }) + } }, // 获取用户信息 getUserInfo(code) { @@ -101,8 +118,8 @@ const d = res.data if (d.code == 1) { let userInfo = d.object - if(userInfo.idCard){ - this.flag=false + if(userInfo.roleId == '1003'){ + this.securityFlag=true } let obj = Object.assign({}, this.$store.getters.userInfo) if (obj.avatarUrl) { @@ -111,6 +128,9 @@ this.$store.dispatch('user/setInfo', Object.assign(obj, userInfo)) this.$store.dispatch('user/setToken', d.result) this.getImg() + if(this.userId){ + this.security() + } } }).catch(err => { console.log(err) diff --git a/pages/security/security.vue b/pages/security/security.vue index 83d4a9481fc8afcba5ef97c96c49ca2aab1f7c44..126b81d2546486825d8f850342aebf60107c8d55 100644 --- a/pages/security/security.vue +++ b/pages/security/security.vue @@ -34,19 +34,21 @@ }; }, onLoad: function(option) { - console.log(option) + this.form.userId = option.userId }, onShow() {}, methods: { // 体温正常 normal() { this.form.heatNomal = 0 - this.form.userId = this.$store.state.user.userInfo.id this.form.heat = '' this.$http.post(`/sict-ncov/report/daily/heat`,this.form).then(res => { const d = res.data if (d.code == 1) { - console.log(d) + uni.showToast({ + icon: 'success', + title: d.object + }) } }).catch(err => { console.log(err) @@ -64,15 +66,13 @@ submit(){ this.form.heatNomal = this.form.heat<37.2?0:1 this.form.userId = this.$store.state.user.userInfo.id - console.log(this.form) - // uni.showToast({ - // icon: 'none', - // title: "提交异常体温!" - // }) this.$http.post(`/sict-ncov/report/daily/heat`,this.form).then(res => { const d = res.data if (d.code == 1) { - console.log(d) + uni.showToast({ + icon: 'none', + title: d.object + }) } }).catch(err => { console.log(err)