y595705120 1 週間 前
コミット
536759af2b

+ 2 - 1
src/assets/css/main.css

@@ -200,6 +200,7 @@ input:focus{
 }
 .title-box {
     border-bottom: 1px solid #e6e6e6;
+    margin-top: 20px;
 }
 .clear {
    clear: both;
@@ -279,7 +280,7 @@ a, span {
   z-index: 1;
 }
 .opacity-bg {
-  border-radius: 10px;
+  /* border-radius: 10px; */
   background:rgba(129, 184, 246, 0.9) ;
   /* background: rgba(0,0,0,0.2); */
   /* background: url("../../assets/images/opacity-bg_hash548c17198c.png"); */

+ 21 - 0
src/components/nav/navbar.vue

@@ -7,6 +7,18 @@
       </div>
     </div>
 
+    <div class="m-nav">
+      <div class="p-wrap-full clear">
+        <div class="nav-bd">
+          <a v-for="(item, index) in navList" :key="index"
+             :class="{ current: isActive(item) }"
+             @click="goto(item.path)"
+             v-if="!item.hidden">
+            {{ item.name }}
+          </a>
+        </div>
+      </div>
+    </div>
   </div>
 </template>
 
@@ -15,9 +27,18 @@
     data() {
       return {
         config: window.baseConfig,
+        navList: [
+          { name: '首页', path: '/' },
+          { name: '证书查询', path: '/fj-certificate' },
+          { name: '学时认证', path: '/nd-sign' },
+          { name: '文件通知', path: '/main/postlist/notice' },
+        ]
       };
     },
     methods:{
+      isActive(item) {
+        return this.$route.path === item.path
+      },
       goto( path ){
         if( this.$route.path != path){
           this.$router.push({path})

+ 112 - 185
src/containers/center/market/index.vue

@@ -138,46 +138,71 @@
     </div>
 
     <el-dialog title="申请开通课程" :visible.sync="buyCourseDialog" width="550px" top="100px" align="center">
-      <el-form label-width="100px"  :inline="false" :model="buyForm" :rules="rules"
-        ref="elForm">
-
-        <el-form-item label="报考岗位" prop="courseName">
-          <el-input type="text" placeholder="报考岗位" v-model="buyForm.courseName+'-'+buyForm.nd"
-          style="width: 360px;" />
-        </el-form-item>
-
-        <el-form-item label="证书编号" prop="rzCode">
-          <el-input v-model="buyForm.rzCode" type="text" style="width: 360px;">
-            <template #suffix>
-              <el-button @click="openShowAllRzcodeDialog" type="text" style="margin-right: 10px;">修改</el-button>
-            </template>
-          </el-input>
-        </el-form-item>
-
-<!--        <el-form-item label="支付类型" prop="payType">
-          <div style="text-align: left;margin-left: 20px;">
-            <el-button :type="buyForm.payType === 'wx' ? 'primary' : 'default'" style="margin-right: 30px;" @click="buyForm.payType='wx';onPayTypeChange()">微信</el-button>
-            <el-button :type="buyForm.payType === 'ali' ? 'primary' : 'default'" @click="buyForm.payType='ali';onPayTypeChange()">支付宝</el-button>
-          </div>
-        </el-form-item> -->
+      <template v-if="!showPay">
+        <el-form label-width="100px" :inline="false" :model="buyForm" :rules="rules"
+          ref="elForm">
+
+          <el-form-item label="报考岗位" prop="courseName">
+            <el-input type="text" placeholder="报考岗位" v-model="buyForm.courseName+'-'+buyForm.nd"
+            style="width: 360px;" />
+          </el-form-item>
 
-        <el-row>
+          <el-form-item label="证书编号" prop="rzCode">
+            <el-input v-model="buyForm.rzCode" type="text" style="width: 360px;">
+              <template #suffix>
+                <el-button @click="openShowAllRzcodeDialog" type="text" style="margin-right: 10px;">修改</el-button>
+              </template>
+            </el-input>
+          </el-form-item>
+
+          <el-divider></el-divider>
+          <h3 class="tc" style="margin-bottom: 16px;">发票信息</h3>
+          <el-form-item label="是否需要开票">
+            <el-radio-group v-model="buyForm.needInvoice">
+              <el-radio :label="1">是</el-radio>
+              <el-radio :label="0">否</el-radio>
+            </el-radio-group>
+          </el-form-item>
+          <template v-if="buyForm.needInvoice">
+            <el-form-item label="开票类型">
+              <el-radio-group v-model="buyForm.invoiceType">
+                <el-radio label="personal">个人</el-radio>
+                <el-radio label="enterprise">企业</el-radio>
+              </el-radio-group>
+            </el-form-item>
+            <el-form-item label="发票抬头" prop="title">
+              <el-input v-model="buyForm.title" :placeholder="buyForm.invoiceType === 'enterprise'?'请输入单位名称':'请输入真实名字'" style="width: 360px;"></el-input>
+            </el-form-item>
+            <el-form-item label="手机号码" prop="phone">
+              <el-input v-model="buyForm.phone" placeholder="请输入手机号码" style="width: 360px;"></el-input>
+            </el-form-item>
+            <el-form-item label="邮箱地址" prop="email">
+              <el-input v-model="buyForm.email" placeholder="请输入邮箱地址" style="width: 360px;"></el-input>
+            </el-form-item>
+          </template>
+
+          <el-divider></el-divider>
           <h2 class="tc"> 本课程费用: <strong style="color: red;"> {{buyForm.fee/100}} 元 </strong> </h2>
-          <div style="width: 300px; margin: 0px auto;" v-if="buyForm.payType">
-            <img :src="wxPayUrl" width="300px" @click="showImg(wxPayUrl)">
-          </div>
-          <div style="width: 300px; margin: 0px auto;" v-else>
-            <img :src="aliPayUrl" width="300px" @click="showImg(aliPayUrl)">
-          </div>
-        </el-row>
 
-        <el-row class="tc fc">
-          <el-form-item>
+          <el-form-item label-width="0" style="margin-top: 30px;">
             <el-button @click="cancelBuyCourse">取 消</el-button>
-            <el-button @click="buyCourse" type="primary">确 定</el-button>
+            <el-button @click="generatePayQrcode" type="primary">提交订单</el-button>
           </el-form-item>
+
+        </el-form>
+      </template>
+
+      <template v-if="showPay">
+        <h2 class="tc"> 本课程费用: <strong style="color: red;"> {{buyForm.fee/100}} 元 </strong> </h2>
+        <div style="width: 300px; margin: 20px auto;">
+          <img :src="wxPayUrl" width="300px" @click="showImg(wxPayUrl)">
+        </div>
+        <p class="tc">请使用微信扫码支付</p>
+        <el-row class="tc fc">
+          <el-button @click="cancelBuyCourse">关 闭</el-button>
         </el-row>
-      </el-form>
+      </template>
+
 
     </el-dialog>
 
@@ -246,31 +271,19 @@
         showExample: false,
         showImgDialog: false,
         showAllRzcodeDialog: false,
-        promiseType: {
-          1: '温馨提示',
-          2: '承诺书',
-          3: '委 托 书'
-        },
+        showPay: false,
         buyForm: {
           payType:'wx',
-          marks: '',
           rzCode: '',
-          payNo: '',
           email: '',
-          company: '',
-          buyImg: '',
-          name: '',
+          title: '',
+          phone: '',
           courseName: '',
           list: [],
           fee: 0,
-          course_id: ''
-        },
-        promise: {
-          status: 0,
-          showType: 1
-        },
-        typeInfo:{
-
+          courseId: '',
+          needInvoice: 0,
+          invoiceType: 'personal'
         },
         imgUrl: '',
         qrcodeUrl: "",
@@ -294,9 +307,9 @@
             required: true,
             message: '请输入订单编号后六位'
           }],
-          marks: [{
+          title: [{
             required: true,
-            message: '请输入备注信息'
+            message: '抬头必须填写'
           }],
           email: [{
               required: true,
@@ -316,7 +329,15 @@
           ],
           company: [{
             required: true,
-            message: '请输入所在企业'
+            message: '请输入单位名称'
+          }],
+          phone: [{
+            required: true,
+            message: '请输入手机号码'
+          }, {
+            pattern: /^1[3-9]\d{9}$/,
+            message: '手机号码格式不正确',
+            trigger: 'blur'
           }],
           courseName: [{
             required: true,
@@ -327,7 +348,7 @@
       };
     },
     computed: {
-      ...mapGetters("user", ["typeList", "userInfo", "promiseList"])
+      ...mapGetters("user", ["typeList", "userInfo"])
     },
     components: {
       DoUpload
@@ -349,9 +370,6 @@
       filterName() {
         this.page = 1
         this.filterData()
-      },
-      isCommitment(val) {
-        console.log(val)
       }
     },
     beforeMount() {
@@ -368,11 +386,6 @@
         this.imgUrl = url;
         this.showImgDialog = true;
       },
-      onPayTypeChange() {
-        if (this.buyCourseDialog && this.buyForm.course_id) {
-          this.generatePayQrcode();
-        }
-      },
       closeDialog() {
         if (this.timer) window.clearInterval(this.timer);
       },
@@ -384,29 +397,6 @@
         }
         this.width = width + "px";
       },
-      matchPromise(row) {
-        let {type,name} = row;
-        let isMatch = false
-        for (let i in this.promiseList) {
-          let item = this.promiseList[i];
-          if (name == item.type || item.type == type) {
-            this.promise = Object.assign(this.promise, item);
-            console.log("promise", this.promise);
-            isMatch = true
-          } else if (!isMatch && item.type == '默认类型') {
-            this.promise = Object.assign(this.promise, item);
-          }
-        }
-      },
-      matchType(type) {
-        for (let i in this.typeList) {
-          let item = this.typeList[i];
-          if(item.name == type) {
-            this.typeInfo = Object.assign(this.typeInfo, item);
-            return;
-          }
-        }
-      },
       initTimer() {
         if (this.timer) window.clearInterval(this.timer);
         this.tickCount = 0;
@@ -433,24 +423,38 @@
         });
       },
       generatePayQrcode() {
+        console.log('generatePayQrcode')
         let payType = this.buyForm.payType;
         let apiName = payType === 'wx' ? "weixin.DoWxpay" : "weixin.DoaliPay";
-
+        let {
+          courseId,
+          courseName,
+          title,
+          email,
+          phone,
+          needInvoice,
+          invoiceType
+        } = this.buyForm;
         let param = {
-          courseId: this.buyForm.course_id,
-          rzCode: this.buyForm.rzCode
+          courseId,
+          title,
+          phone,
+          email,
+          needInvoice,
+          invoiceType
         };
         httpServer(apiName, param).then((res) => {
-          if (res.code == 200) {
-            let { outTradeNo, showUrl } = res.data;
-            this.outTradeNo = outTradeNo;
-            if (payType === 'wx') {
-              this.wxPayUrl = showUrl;
-            } else {
-              this.aliPayUrl = showUrl;
-            }
-            this.initTimer();
+          if (res.code != 200) return;
+          let { outTradeNo, showUrl } = res.data;
+          this.outTradeNo = outTradeNo;
+          if (payType === 'wx') {
+            this.wxPayUrl = showUrl;
+          } else {
+            this.aliPayUrl = showUrl;
           }
+          this.showPay = true
+          this.initTimer();
+
         });
       },
       getData() {
@@ -485,9 +489,9 @@
       },
       cancelBuyCourse() {
         if (this.timer) window.clearInterval(this.timer);
-        this.$refs["elForm"].resetFields();
+        this.$refs["elForm"] && this.$refs["elForm"].resetFields();
         this.buyCourseDialog = false
-        this.commitmentDialog = false;
+        this.showPay = false;
       },
       openShowAllRzcodeDialog() {
         this.showAllRzcodeDialog = true;
@@ -496,101 +500,24 @@
         this.buyForm.rzCode = row.certificateNum;
         this.showAllRzcodeDialog = false;
       },
-      buyCourse() {
-        this.$refs["elForm"].validate((valid) => {
-          if (!valid) return;
-          let {
-            marks,
-            company,
-            payNo,
-            course_id,
-            courseName,
-            rzCode,
-            name,
-            email,
-            buyImg
-          } = this.buyForm;
-          if (courseName != name) {
-            this.$message.errorMsg("报考岗位有误", 1)
-            return;
-          }
-          let param = {
-            marks,
-            payNo,
-            company,
-            courseId: course_id,
-            courseName,
-            rzCode,
-            email,
-            buyImg
-          }
-          httpServer("course.buyCourse", param).then((res) => {
-            if (res.code == 200) {
-              this.$message.successMsg("申请购买成功", 1);
-              this.buyForm.temp.marks = this.buyForm.marks
-              Object.assign(this.buyForm.temp, param);
-              this.$refs["elForm"].resetFields();
-              this.buyForm.temp.is_pay = 0
-              this.buyCourseDialog = false;
-              this.commitmentDialog = false;
-            }
-          });
-        })
-      },
       gotoDetail(courseId) {
         this.$router.push(`/main/course/${courseId}`);
       },
-      uploadBuyImg(url) {
-        this.buyForm.buyImg = url;
-      },
-      testBuyOK(item) {
-        this.stage = 2;
-        this.isCompanyPay = 1;
-        this.isCommitment = ''
-        this.buyForm.rzCode = item.rzCode;
-        this.buyForm.company = 'ssss';
-        this.buyForm.name = item.courseName;
-        // let isEdu = this.hasPromise(item.type);
-        if (this.promise.status == 1) {
-          this.commitmentDialog = true;
-          this.buyCourseDialog = false;
-        } else {
-          this.buyCourseDialog = true;
-          this.commitmentDialog = false;
-        }
-        // if( isEdu || this.hasNotice() ){
-        //   this.buyCourseDialog = false;
-        //   this.commitmentDialog = true;
-        // }else{
-        //   this.buyCourseDialog = true;
-        //   this.commitmentDialog = false;
-        // }
-      },
       goPay(item) {
+        this.showPay = false;
         this.buyForm = Object.assign(this.buyForm, item)
-        this.buyForm.company = this.userInfo.company;
+        this.buyForm.phone = this.userInfo.phone;
         this.buyForm.temp = item;
         this.buyForm.courseName = item.name;
-        this.buyForm.course_id = item.course_id;
+        this.buyForm.courseId = item.course_id;
         this.buyForm.fee = item.fee;
-        this.matchType(item.type)
         // 检查
         httpServer("weixin.docheckpay", {
           courseId: item.course_id
         }).then((res) => {
-          if (res.code == 200) {
-            this.stage = 2;
-            this.isCompanyPay = 0;
-            this.isCommitment = ''
-            Object.assign(this.buyForm, res.data);
-            this.buyCourseDialog = true;
-            this.commitmentDialog = false;
-            this.$nextTick(() => {
-              this.generatePayQrcode();
-            });
-          } else {
-            this.$message.error(res.msg || "无法购买该课程");
-          }
+          if (res.code != 200) return;
+          Object.assign(this.buyForm, res.data);
+          this.buyCourseDialog = true;
         });
       },
       gotoPlay(item) {
@@ -599,7 +526,7 @@
           this.$message.warning("还未到学习时间");
           return
         }
-        this.$router.push(`/center/class/train`);
+        this.$router.push({name:'play', params:{courseId}})
       },
       handleCurrentChange(page) {
         this.page = page;

+ 1 - 1
src/containers/center/market/trainIndex.vue

@@ -538,7 +538,7 @@
         });
       },
       gotoPlay(courseId) {
-        this.$router.push(`/center/class/train`);
+        this.$router.push({name:'play', params:{courseId}})
       },
       handleCurrentChange(page) {
         this.page = page;

+ 1 - 1
src/containers/center/setting/index.vue

@@ -28,7 +28,7 @@
 
             <ul class="ul-form">
               <li class="txt-r">
-                <span class="l-t"></span>注:<i></i>所有信息都非必须,你可以选择性上传
+                <span class="l-t"></span>注:<i></i>所有信息都非必须,你可以选择性上传
               </li>
 
               <li>

+ 106 - 0
src/containers/certificate/fjCertificate.css

@@ -0,0 +1,106 @@
+.learning-time-panel-2 .ui-ipt {
+  width: 300px;
+  border: 0;
+  padding: 13px 8px;
+  margin-right: 10px;
+}
+.learning-time-panel-2 .ipt-1 {
+  width: 400px;
+}
+.learning-time-panel-2 .ui-btn {
+  width: 240px;
+  height: 40px;
+  line-height: 40px;
+  background-color: #0e67a6;
+  box-sizing: border-box;
+  vertical-align: middle;
+}
+.learning-time-panel-2 .ui-btn:hover {
+  background-color: #1075be;
+}
+.title-box .goto-sign {
+  float: right;
+  color: #3290d4;
+  cursor: pointer;
+  font-weight: normal;
+}
+.title-box .goto-sign:hover {
+  color: #0e67a6;
+  text-decoration: underline;
+}
+.title-box .tab-switch {
+  float: right;
+  margin-right: 50px;
+}
+.title-box .tab-item {
+  display: inline-block;
+  padding: 4px 24px;
+  font-size: 1.5em;
+  color: #666;
+  cursor: pointer;
+  border-bottom: 2px solid transparent;
+}
+.title-box .tab-item.active {
+  color: #3290d4;
+  border-bottom-color: #3290d4;
+}
+.title-box .tab-item:hover {
+  color: #3290d4;
+}
+
+.cert-card {
+  margin-bottom: 20px;
+  border: 2px solid #c0c4cc !important;
+  border-radius: 8px;
+}
+
+.cert-card .el-card__body {
+  padding: 0 !important;
+}
+
+.cert-card-header {
+  font-size: 16px;
+  font-weight: bold;
+  color: #333;
+}
+
+.cert-card-body {
+  padding: 0;
+}
+
+.cert-row {
+  display: flex;
+  border-bottom: 1px solid #e8e8e8;
+}
+
+.cert-row:last-child {
+  border-bottom: none;
+}
+
+.cert-item {
+  display: flex;
+  flex: 1;
+  min-width: 0;
+}
+
+.cert-item:first-child {
+  border-right: 1px solid #e8e8e8;
+}
+
+.cert-label {
+  width: 100px;
+  min-width: 100px;
+  padding: 10px 12px;
+  background-color: #e6f2ff;
+  font-weight: bold;
+  color: #333;
+  font-size: 14px;
+  box-sizing: border-box;
+}
+
+.cert-value {
+  padding: 10px 12px;
+  font-size: 14px;
+  color: #333;
+  flex: 1;
+}

+ 130 - 0
src/containers/certificate/fjCertificate.vue

@@ -0,0 +1,130 @@
+<template>
+  <div>
+    <navbar></navbar>
+    <div class="p-wrap-full" style="width: 1200px;margin: 20px auto;">
+      <el-card>
+        <el-form :inline="true" :model="periodObj" class="search-form">
+          <el-form-item label="证件号">
+            <el-input v-model="periodObj.cardId" placeholder="请输入证件号" clearable></el-input>
+          </el-form-item>
+          <el-form-item label="姓名">
+            <el-input v-model="periodObj.nickname" placeholder="请输入姓名" clearable></el-input>
+          </el-form-item>
+          <el-form-item>
+            <el-button type="primary" @click="goVerify()">立即查询</el-button>
+          </el-form-item>
+        </el-form>
+      </el-card>
+    </div>
+    <div class="p-wrap-full" style="width: 1200px;margin: 20px auto;min-height: 500px">
+      <el-card class="cert-card" v-for="(item, index) in recodeList" :key="index">
+        <div slot="header" class="cert-card-header">
+          <span>证书【{{ index + 1 }}】</span>
+        </div>
+        <div class="cert-card-body">
+          <div class="cert-row">
+            <div class="cert-item">
+              <span class="cert-label">姓名</span>
+              <span class="cert-value">{{ item.userName }}</span>
+            </div>
+            <div class="cert-item">
+              <span class="cert-label">身份证</span>
+              <span class="cert-value">{{ item.cardId }}</span>
+            </div>
+          </div>
+          <div class="cert-row">
+            <div class="cert-item">
+              <span class="cert-label">证书编号</span>
+              <span class="cert-value">{{ item.certificateNum }}</span>
+            </div>
+            <div class="cert-item">
+              <span class="cert-label">岗位名称</span>
+              <span class="cert-value">{{ item.positionName }}</span>
+            </div>
+          </div>
+          <div class="cert-row">
+            <div class="cert-item">
+              <span class="cert-label">证书状态</span>
+              <span class="cert-value">{{ item.certificateStatus }}</span>
+            </div>
+            <div class="cert-item">
+              <span class="cert-label">证书类型</span>
+              <span class="cert-value">{{ item.certificateType }}</span>
+            </div>
+          </div>
+          <div class="cert-row">
+            <div class="cert-item">
+              <span class="cert-label">岗位编码</span>
+              <span class="cert-value">{{ item.careerCode }}</span>
+            </div>
+            <div class="cert-item">
+              <span class="cert-label">发证机关</span>
+              <span class="cert-value">{{ item.certificateOrgan }}</span>
+            </div>
+          </div>
+          <div class="cert-row">
+            <div class="cert-item">
+              <span class="cert-label">发证时间</span>
+              <span class="cert-value">{{ item.startTime }}</span>
+            </div>
+            <div class="cert-item">
+              <span class="cert-label">生日</span>
+              <span class="cert-value">{{ item.birthday }}</span>
+            </div>
+          </div>
+
+          <div class="cert-row">
+            <div class="cert-item">
+              <span class="cert-label">工作单位</span>
+              <span class="cert-value">{{ item.workUnit }}</span>
+            </div>
+            <div class="cert-item">
+              <span class="cert-label">复核时间</span>
+              <span class="cert-value">{{ item.reviewTime }}</span>
+            </div>
+          </div>
+        </div>
+      </el-card>
+    </div>
+  </div>
+</template>
+
+
+<script>
+  import navbar from "@/components/nav/navbar.vue";
+  import {httpServer} from "@/components/httpServer/httpServer.js";
+  export default {
+    components: { navbar },
+    data(){
+      return {
+        activeTab: 1,
+        periodObj:{
+          nickname:'',
+          cardId:'',
+        },
+        recodeList:[] ,
+      }
+    },
+    methods: {
+      goVerify(){
+        let {nickname,cardId} = this.periodObj;
+        if( !nickname || cardId.length <15 || cardId.length> 18){
+          this.$message({message:'请输入大陆身份证(15-18位)'})
+          return
+        }
+        httpServer("User.ReLoadRzCode", {nickname,cardId}).then( res=>{
+          if( res.code == 200){
+            this.recodeList = res.data;
+          }
+        })
+      },
+      goSign(){
+        this.$router.push({name:'nd-sign'})
+      }
+    }
+  }
+</script>
+
+<style>
+  @import url("fjCertificate.css");
+</style>

+ 1 - 1
src/containers/login/components/loginBase.css

@@ -161,7 +161,7 @@ input[type=radio] {
   z-index: 9;
   background-color: #f9e2e4;
   border: 1px solid #ff914b;
-  border-radius: 5px;
+  /* border-radius: 5px; */
   color: #ff914b;
   padding: 2px 5px;
 }

+ 39 - 0
src/containers/login/login.css

@@ -92,3 +92,42 @@ div {
 /* .login-dialog, .el-dialog__header{
   display: none !important;
 } */
+.banner {
+    background: url(../../assets/images/banner_bg.jpg) no-repeat 0 0;
+    width: 910px;
+    height: 350px;
+    float: left;
+    position: relative;
+}
+
+.banner .category {
+    width: 290px;
+    height: 350px;
+    position: absolute;
+    top: 0;
+    left: 0;
+    background: #000;
+    box-sizing: border-box;
+    padding: 15px 12px;
+}
+
+.banner .category .category-title {
+    text-align: center;
+    font-size: 18px;
+    font-weight: bold;
+    color: #fff;
+    margin-bottom: 10px;
+    line-height: 1.5;
+}
+
+.banner .category .btn-box {
+    width: 100%;
+}
+
+.banner .category .btn-box  {
+    display: inline-block;
+    vertical-align: middle;
+    margin: 2px 10px;
+    padding: 2px 2px;
+    line-height: 1.2;
+}

+ 43 - 74
src/containers/login/login.vue

@@ -4,86 +4,53 @@
       <navbar :user="userInfo" @openLoginDialog="openLoginDialog"></navbar>
     </div>
 
-    <div class="banner-box">
-      <div class="p-wrap-full clear pt30">
-        <el-card class="training-category opacity-bg fl waphide" style="border-radius: 20px;padding-top: -5px;" >
-          <h2 align="center" style="background-color: white; color: #000000;padding-top:5px;">文件通知</h2>
-          <el-table :data="postList"  highlight-current-row
-          :show-header="false" height="240px" >
-            <el-table-column min-width="600px">
-              <template slot-scope="{row, $index}">
-                <span @click="gotoDetail(row.postId)">{{(page*size)-size+$index+1}}、{{ row.title }}</span>
-              </template>
-            </el-table-column>
-            <el-table-column  width="160px">
-              <template slot-scope="{row}">
-                <span>{{ row.publishTime  }}</span>
-              </template>
-            </el-table-column>
-          </el-table>
-          <el-pagination class="tc m-page"
-            @current-change="handlePageChange"
-            :current-page="page"
-            :page-size="size"
-            layout="total, prev, pager, next"
-            :total="total">
-          </el-pagination>
-
-        </el-card>
-
-        <div class="m-login opacity-bg">
-          <is-login v-if="loginOk" :user="userInfo" @logout="logout"></is-login>
-          <un-login v-else @login="login" :err="err"></un-login>
+    <div class="p-wrap-full clear" style="width: 1200px;margin: 0 auto;">
+      <div class="banner">
+        <div class="category">
+          <div class="category-title">培训类别</div>
+          <div class="category-tit clear">
+            <div class="btn-box" v-for="(item, index) in typeList" :key="index">
+              <el-button @click="gotoCategory(item)" type="primary" style="width: 240px;font-size: 20px;">
+                {{ item.name }}
+              </el-button>
+            </div>
+          </div>
         </div>
       </div>
-    </div>
-    <!--  -->
-    <div class="waphide">
-      <learn-time></learn-time>
-    </div>
-
-    <div class="p-wrap-full mb20 ng-scope waphide">
-      <div class="title-box mt5 clear">
-        <h2 class="title">继续教育</h2>
+      <div class="m-login opacity-bg">
+        <is-login v-if="loginOk" :user="userInfo" @logout="logout"></is-login>
+        <un-login v-else @login="login" :err="err"></un-login>
       </div>
-      <el-row :gutter="20" class="shadow p10 mt20" >
-        <el-col :span="+item.span" class="nopad"  v-for="(item, index) in typeList" :key="index" v-if="!item.isNew && item.span>0">
-          <el-card shadow="hover" class="grid-content nopad "  >
-            <div class="mt10 typelist" @click="gotoCourse(item)">
-              <i class="p-ico"  :class="item.icon" style="color:#69c0ff"></i>
-              <p style="font-size: 13px;">{{ item.name }}</p>
-              <p class="mt10" style="font-size: 16px;" v-if="!item.isOpen">(暂未开放)</p>
-              <p class="mt10" style="font-size: 16px;" v-else>{{ item.content }}</p>
-            </div>
-          </el-card>
-        </el-col>
-      </el-row>
     </div>
 
-<!--    <div class="p-wrap-full mb20 ng-scope waphide">
+    <div class="p-wrap-full ng-scope waphide">
       <div class="title-box mt5 clear">
-        <h2 class="title">教育培训</h2>
+        <h2 class="title">文件通知</h2>
       </div>
-      <el-row :gutter="20" class="shadow p10 mt20" >
-        <el-col :span="+item.span" class="nopad" style="flex:1" v-for="(item, index) in typeList" :key="index" v-if="item.isNew==1">
-          <el-card shadow="hover" class="grid-content nopad"  >
-            <div class="mt10 typelist" @click="gotoCourse(item)">
-              <i class="p-ico"  :class="item.icon" style="color:#69c0ff"></i>
-              <p style="font-size: 13px;">{{ item.name }}</p>
-              <p class="mt10" style="font-size: 16px;" v-if="!item.isOpen">(暂未开放)</p>
-              <p class="mt10" style="font-size: 16px;" v-else>{{ item.content }}</p>
-            </div>
-          </el-card>
-        </el-col>
-      </el-row>
-    </div> -->
-
-<!--    <div class="right-nav waphide">
-      <img class="right-img" src="../../assets/wxapp.jpg" alt="">
-      <p>使用小程序</p>
-      <p>学习更轻松</p>
-    </div> -->
+      <el-card style="margin-top: 10px;">
+        <el-table :data="postList"  highlight-current-row
+        :show-header="false" height="240px" >
+          <el-table-column min-width="600px">
+            <template slot-scope="{row, $index}">
+              <span @click="gotoDetail(row.postId)">{{(page*size)-size+$index+1}}、{{ row.title }}</span>
+            </template>
+          </el-table-column>
+          <el-table-column  width="160px">
+            <template slot-scope="{row}">
+              <span>{{ row.publishTime  }}</span>
+            </template>
+          </el-table-column>
+        </el-table>
+        <el-pagination class="tc m-page"
+          @current-change="handlePageChange"
+          :current-page="page"
+          :page-size="size"
+          layout="total, prev, pager, next"
+          :total="total">
+        </el-pagination>
 
+      </el-card>
+    </div>
 
     <div class="p-wrap-full ng-scope waphide">
       <div class="title-box mt5 clear">
@@ -118,7 +85,6 @@ import { mapGetters,mapActions } from "vuex";
 
 export default {
   components: {
-    LearnTime,
     isLogin,
     unLogin,
     Friendlink,
@@ -136,7 +102,7 @@ export default {
       size: 5,
       total:0,
       loginDialog: false,
-      err: {},
+      err: {}
     };
   },
   computed: {
@@ -226,6 +192,9 @@ export default {
     openLoginDialog() {
       this.loginDialog = true
     },
+    gotoCategory(item) {
+      this.$router.push({path: '/center/market', query: {type: item.label}})
+    },
   },
 };
 </script>

+ 0 - 41
src/containers/login/loginData.js

@@ -1,41 +0,0 @@
-export default {
-  category: [
-
-      {
-          label: "建筑施工企业“三类人员”",
-          icon: "el-icon el-icon-setting",
-          name: "authority",
-          color: "#69c0ff",
-      },
-      {
-          label: "建筑施工企业特种作业人员",
-          icon: "el-icon el-icon-menu",
-          name: "menu",
-          color: "#69c0ff",
-      },
-      {
-          label: "专业技术人员",
-          icon: "el-icon el-icon-cpu",
-          name: "autoCode",
-          color: "#69c0ff",
-      },
-      {
-          label: "二级建造师",
-          icon: "el-icon el-icon-document-checked",
-          name: "formCreate",
-          color: "#69c0ff",
-      },
-      {
-          label: "施工现场专业人员-继续教育",
-          icon: "el-icon el-icon-user",
-          name: "about",
-          color: "#5cdbd3",
-      },
-      {
-        label: "园林技工",
-        icon: "el-icon el-icon-user",
-        name: "about",
-        color: "#5cdbd3",
-    }
-  ]
-}

+ 6 - 0
src/router/index.js

@@ -45,6 +45,7 @@ import CenterExamDownload from '@/containers/center/exam/download'
 import CenterUserSeat from '@/containers/center/userSeat/index'
 import CenterUserCert from '@/containers/center/userCert/index'
 import PublicCertificate from '@/containers/certificate/index'
+import FjCertificate from '@/containers/certificate/fjCertificate'
 
 Vue.use(Router)
 
@@ -67,6 +68,11 @@ export default new Router({
       name: 'nd-sign',
       component: PublicCertificate,
     },
+    {
+      path: '/fj-certificate',
+      name: 'fj-certificate',
+      component: FjCertificate,
+    },
     {
       path: '/sign',
       name: 'sign',