소스 검색

fix:健康问卷优化

magic v 3 년 전
부모
커밋
4a79fdcbca

+ 1 - 1
src/common/scss/bl-flex.scss

@@ -232,7 +232,7 @@
   // 强制换行
   &[wrap], [wrap] {
     word-wrap: break-word;
-    word-wrap: break-all;
+    word-break: break-all;
   }
 
   // 字体大小

+ 3 - 0
src/main.js

@@ -32,6 +32,9 @@ Vue.mixin({
       if (to.name === this.vueRouteName) {
         this.vueWatchRoute && this.vueWatchRoute(to, from)
       }
+    },
+    TITLE () {
+      this.$store.commit('SET_HEADER_TITLE', this.TITLE)
     }
   },
   created () {

+ 4 - 4
src/pages/FormResult/index.vue

@@ -23,8 +23,8 @@
             <div class="bl-flex" between margin-top-md margin-bottom-md
               v-for="(item, index) in it.result.slice(0, 4)"
               :key="index">
-              <div color-des>{{ item.title }}</div>
-              <div>{{ item.val }}</div>
+              <div color-des padding-right-md>{{ item.title }}</div>
+              <div wrap flex1>{{ item.val }}</div>
             </div>
             <div class="bl-flex" between margin-top-md margin-bottom-md
               :color-warning="it.temperature === 37.3"
@@ -37,8 +37,8 @@
             <div class="bl-flex" between margin-top-md margin-bottom-md color-error
               v-for="(item, index) in it.result.filter(item => item.type === 'radio' && item.val === '是')"
               :key="'a' + index">
-              <div>{{ item.title }}</div>
-              <div>{{ item.val }}</div>
+              <div wrap>{{ item.title }}</div>
+              <div wrap>{{ item.val }}</div>
             </div>
             <div class="bl-flex" between margin-top-md margin-bottom-md>
               <div color-des>提交时间</div>

+ 11 - 10
src/pages/FormVolume/Layout1/index.vue

@@ -1,5 +1,5 @@
 <template>
-<div class="volume-container">
+<div class="volume-container bl-flex">
   <div class="body scroll-view">
     <div class="head">
       <h1 v-if="data.topic.is_name && data.topic.name">{{ data.topic.name }}</h1>
@@ -11,11 +11,11 @@
         :key="index + 1"
         :class="{ cur: edataItem === item }"
         @click="$emit('selectItem', item)">
-        <p>
+        <p size-md>
           <label v-if="item.required">*</label>
           <span>{{index + 1}}. </span>
-          <span>{{ item.title }}</span>
-          <span v-if="configType[item.type]">【{{ configType[item.type] }}】</span>
+          <span bold>{{ item.title }}</span>
+          <span v-if="configType[item.type]" color-label>【{{ configType[item.type] }}】</span>
         </p>
         <div :class="{'align-right': (item.layout_align || data.topic.layout_align) === 'right'}">
 
@@ -86,7 +86,7 @@
               <input v-model="item.area" not-border
                 placeholder="选择区域"
                 readonly />
-              <i class="font-ileads ileads-icon-jiantou" color-des></i>
+              <i class="font-ileads ileads-icon-jiantou bl-flex" center size-md color-des></i>
             </div>
 
             <input v-model="item.val1" margin-bottom-lg
@@ -114,7 +114,7 @@
                 <span color-des v-if="!item.certificate">证件类型</span>
                 <span color-text v-else>{{ item.certificate }}</span>
               </div>
-              <i class="font-ileads ileads-icon-iconfontjiantou" color-des size-sm></i>
+              <i class="font-ileads ileads-icon-iconfontjiantou bl-flex" center color-des size-sm></i>
             </div>
 
             <input v-model="item.val" not-border
@@ -143,15 +143,16 @@
   <van-popup v-model="show.area" position="bottom" round>
     <van-area title="选择区域" 
       :area-list="areaList"
-      @confirm="onConfirmArea" />
+      @confirm="onConfirmArea"
+      @cancel="openArea()" />
   </van-popup>
 
-  <van-popup v-model="show.certificate" round
+  <van-popup v-model="show.certificate" round style="width: 86vw;"
     @closed="closeCertificate()">
     <div>
       <div class="bl-flex" center padding-top-lg>选择证件类型</div>
-      <div class="bl-flex" flex-wrap padding-lg size-sm v-if="certificateCom.item">
-        <div padding-md padding-left-lg padding-right-lg border round margin-sm bg-color-6 active
+      <div class="bl-flex" flex-wrap padding-lg size-sm center v-if="certificateCom.item">
+        <div padding-md padding-left-lg padding-right-lg border round margin-xs bg-color-6 touch
           :bg-color="certificateCom.item.certificate === item.name"
           :color-f="certificateCom.item.certificate === item.name"
           v-for="(item, index) in options.certificate"

+ 1 - 0
src/pages/FormVolume/Layout1/style.scss

@@ -56,6 +56,7 @@
           border: 0;
           border-bottom: 1px solid $color-5;
           width: 100%;
+          padding: $sp-xs 0;
           &[not-border] {
             border-bottom: 0;
           }

+ 7 - 1
src/pages/FormVolume/mixins/index.js

@@ -83,7 +83,7 @@ export default {
         return new Date(item.timer).toString('yyyyMMdd') === d1
       }
     })
-    if (data.length && !this.$route.query.jump) {
+    if (data.length && !this.$route.query.jump && !this.isEdit) {
       this.$router.replace({ name: 'FormResult', query: this.$route.query })
     } else {
       this.vueWatchRoute()
@@ -155,12 +155,18 @@ export default {
         
         this.inTopicComponent(data, Custom)
         this.$set(this, 'data', data)
+        this.inTITLE()
       } catch (error) {
         this.loading.empty = true
         console.log(error)
       }
       this.loading.data = false
     },
+    inTITLE () {
+      if (this.data) {
+        this.TITLE = this.data.topic.name
+      }
+    },
     // 问卷组件初始化
     inTopicComponent(data, callback) {
       data = data || this.data