guhongwei 5 年 前
コミット
afbc792bb5
2 ファイル変更15 行追加14 行削除
  1. 7 9
      src/layout/master/index/rili.vue
  2. 8 5
      src/views/master/index/index.vue

+ 7 - 9
src/layout/master/index/rili.vue

@@ -1,5 +1,5 @@
 <template>
-  <div id="rili">
+  <div id="calendar">
     <el-row>
       <el-col :span="24" class="rili">
         <div class="w_1200">
@@ -7,8 +7,10 @@
             <el-col :span="24" class="english">{{ rilitop.english }}</el-col>
             <el-col :span="24" class="title">{{ rilitop.title }}</el-col>
           </el-col>
-          <el-col :span="24" class="info">
-            日历组件
+          <el-col :span="24" class="position:relative;float:right;">
+            <el-col :span="24" class="info">
+              <slot></slot>
+            </el-col>
           </el-col>
         </div>
       </el-col>
@@ -18,9 +20,10 @@
 
 <script>
 export default {
-  name: 'rili',
+  name: 'calendar',
   props: {
     rilitop: null,
+    calendar: null,
   },
   components: {},
   data: () => ({}),
@@ -59,9 +62,4 @@ p {
   font-size: 36px;
   font-family: 微软雅黑;
 }
-.info {
-  text-align: center;
-  height: 688px;
-  border: 1px solid #ccc;
-}
 </style>

+ 8 - 5
src/views/master/index/index.vue

@@ -39,9 +39,11 @@
           <other :otherList="otherList"></other>
         </div>
       </el-col>
-      <!-- <el-col :span="24" class="rili">
-        <rili :rilitop="rilitop"></rili>
-      </el-col> -->
+      <el-col :span="24" class="rili">
+        <calendar :rilitop="rilitop">
+          <slot name="rili"></slot>
+        </calendar>
+      </el-col>
       <el-col :span="24" class="fast">
         <div class="w_1200">
           <fast :fasttop="fasttop" :fastlist="fastlist"></fast>
@@ -79,7 +81,7 @@ import login from '../../../layout/master/index/login.vue';
 import huodong from '../../../layout/master/index/huodong.vue';
 import recruit from '../../../layout/master/index/recruit.vue';
 import other from '../../../layout/master/index/other.vue';
-import rili from '../../../layout/master/index/rili.vue';
+import calendar from '../../../layout/master/index/calendar.vue';
 import fast from '../../../layout/master/index/fast.vue';
 import contact from '../../../layout/master/index/contact.vue';
 import yizhan from '../../../layout/master/index/yizhan.vue';
@@ -102,6 +104,7 @@ export default {
     recruitList: null, //吉林省事业单位列表
     otherList: null,
     rilitop: null, //日历头部内容
+    calendar: null, //日历
     fasttop: null, //快速通道头部内容
     fastlist: null, //快速通道列表
     contactinfo: null, //联系我们内容
@@ -121,7 +124,7 @@ export default {
     huodong,
     recruit,
     other,
-    // rili,
+    calendar,
     fast,
     contact,
     yizhan,