guhongwei %!s(int64=4) %!d(string=hai) anos
pai
achega
b476d1635b
Modificáronse 2 ficheiros con 80 adicións e 6 borrados
  1. 72 5
      src/views/technical/detail/inddetail.vue
  2. 8 1
      src/views/technical/list.vue

+ 72 - 5
src/views/technical/detail/inddetail.vue

@@ -1,14 +1,31 @@
 <template>
-  <div id="expdetail">
-    <p>expdetail</p>
+  <div id="inddetail">
+    <el-row>
+      <el-col :span="24" class="main">
+        <div class="detailtop">
+          <span>{{ detailinfo.title }}</span>
+        </div>
+        <div class="detailtopleft">
+          <span>时间:{{ detailinfo.publish_time }}&nbsp;&nbsp;&nbsp;&nbsp;来源:{{ detailinfo.orgin }}</span>
+        </div>
+        <div class="detailimage" v-if="detailinfo.picture">
+          <img :src="detailinfo.picture" class="detailimg" />
+        </div>
+        <div class="detailcontext">
+          <p v-html="detailinfo.content"></p>
+        </div>
+      </el-col>
+    </el-row>
   </div>
 </template>
 
 <script>
 import { mapState, createNamespacedHelpers } from 'vuex';
 export default {
-  name: 'expdetail',
-  props: {},
+  name: 'inddetail',
+  props: {
+    detailinfo: { type: Object },
+  },
   components: {},
   data: function() {
     return {};
@@ -24,4 +41,54 @@ export default {
 };
 </script>
 
-<style lang="less" scoped></style>
+<style lang="less" scoped>
+.main {
+  .detailtop {
+    padding: 20px 0px;
+    font-size: 18px;
+    line-height: 40px;
+    font-weight: normal;
+    text-align: left;
+    margin: 0;
+    text-align: center;
+    color: #005293;
+  }
+  .detailtopleft {
+    text-align: center;
+    padding: 0 0 10px 0;
+    border-bottom: 1px solid #ccc;
+    font-size: 16px;
+    color: #666666;
+  }
+  .detailimage {
+    text-align: center;
+    padding: 20px 0 0 0;
+  }
+  .detailimg {
+    width: 500px;
+    height: 300px;
+  }
+  .detailcontext {
+    padding: 20px 0;
+    min-height: 370px;
+  }
+  .development {
+    height: 50px;
+    border: 1px dashed red;
+    padding: 0 30px;
+    p:first-child {
+      text-align: center;
+      font-size: 18px;
+      color: red;
+      font-weight: bold;
+    }
+    p:last-child {
+      text-align: center;
+      height: 25px;
+      line-height: 25px;
+      font-size: 16px;
+      font-weight: bold;
+    }
+  }
+}
+</style>

+ 8 - 1
src/views/technical/list.vue

@@ -39,7 +39,7 @@
                   <el-button type="primary" size="mini" @click="display = 'list'">返回</el-button>
                 </el-col>
                 <el-col :span="24">
-                  <inddetail></inddetail>
+                  <inddetail :detailinfo="inddetail"></inddetail>
                 </el-col>
               </span>
               <span v-else-if="column_name == '嘉宾访谈'">
@@ -125,6 +125,8 @@ export default {
       roadshowTotal: 0,
       // 专家详情
       expdetail: {},
+      // 行业研究
+      inddetail: {},
     };
   },
   async created() {
@@ -200,6 +202,11 @@ export default {
         if (this.$checkRes(res)) {
           this.$set(this, `expdetail`, res.data);
         }
+      } else if (columnName == '行业研究') {
+        let res = await this.newsFetch(id);
+        if (this.$checkRes(res)) {
+          this.$set(this, `inddetail`, res.data);
+        }
       }
     },
     // 点击查看详情