|
|
@@ -3,68 +3,60 @@
|
|
|
<div class="right-block-bd ng-scope" ui-view="myStudyContent" style="position: relative;">
|
|
|
<div class="panel-tit clear">
|
|
|
<p class="fl">推荐课程</p>
|
|
|
- <ul class="fr tips-intro" style="color:royalblue" @mouseover="showTip=true" @mouseleave="showTip=false" >
|
|
|
- <li class="fs15 tit">
|
|
|
- <i class="p-ico questiong-ico" style="margin-right: 0px;"/> 已将近退休年龄,是否还需要参加继续教育?
|
|
|
+ <ul class="fr tips-intro" style="color:royalblue" @mouseover="showTip=true" @mouseleave="showTip=false">
|
|
|
+ <li class="fs15 tit" style="margin-right: 20px;">
|
|
|
+ <i class="p-ico questiong-ico" style="margin-right: 0px;" /> 温馨提醒
|
|
|
</li>
|
|
|
</ul>
|
|
|
|
|
|
- <div class="fr tip-card" v-show="showTip" >
|
|
|
+ <div class="fr tip-card" v-show="showTip">
|
|
|
<div class="p20">
|
|
|
- <h3 >一、建设从业人员:</h3>
|
|
|
- <h5 style="margin: 8px;">1、安管人员:</h5>
|
|
|
- <h5 style="margin-left: 16px;">①企业主要负责人(A证):年龄18周岁以上,分管安全的技术负责人、安全总监到60岁,法定代表人没有年龄限制。</h5>
|
|
|
- <h5 style="margin-left: 16px;">②项目负责人(B证):年龄18周岁以上,65周岁以下。</h5>
|
|
|
- <h5 style="margin-left: 16px;">③安全生产管理人员(C证):年龄18周岁以上,60周岁以下。</h5>
|
|
|
- <h4 style="margin: 8px;">2、特种作业人员:年龄18周岁以上,男性55周岁以下,女性50周岁以下。</h4>
|
|
|
- <h4 style="margin: 8px;">3、八大员:年龄20周岁以上,60周岁以下。</h4>
|
|
|
-
|
|
|
- <h2 style="margin:8px 0 16px 0px;">二、执业注册人员:</h2>
|
|
|
- <h4 style="margin: 8px;">1、注册建造师(一级、二级)、注册监理工程师:年龄65周岁以下;</h4>
|
|
|
- <h4 style="margin: 8px;">2、其他执业资格注册证件无年龄要求。</h4>
|
|
|
+ <h3>温馨提醒:</h3>
|
|
|
+ <h2 style="margin: 8px; 0 16px 0px;">一、福建省内可报</h2>
|
|
|
+ <h4 style="margin: 8px;">1.施工现场专业人员</h4>
|
|
|
+ <h4 style="margin: 8px;">2.20周岁以上,且男性小于60周岁,女性小于55周岁。</h4>
|
|
|
+
|
|
|
+ <h2 style="margin:8px 0 16px 0px;">二、宁德内可报:</h2>
|
|
|
+ <h4 style="margin: 8px;">1.安全生产管理人员</h4>
|
|
|
+ <h4 style="margin: 8px;">2.建筑施工特种作业人员</h4>
|
|
|
+ <h4 style="margin: 8px;">3.企业安全生产培训</h4>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
|
<el-row class="pt-line mt20">
|
|
|
- <el-col :span="6" v-for="item in typeList" :key="item.id" v-if="item.isOpen && !item.isNew && !item.link">
|
|
|
- <span :class="{active:item.name==type }" class="nav-btn w220" @click="type=item.name">{{item.name}} </span>
|
|
|
+ <el-col :span="4" :xs="12">
|
|
|
+ <el-button :class="{type_active : type==''}" class="type_item" type="text" @click="type=''">所有</el-button>
|
|
|
</el-col>
|
|
|
+
|
|
|
+ <el-col :span="item.span" :xs="12" v-for="item in typeList" :key="item.id" v-if="item.isOpen && !item.link">
|
|
|
+ <el-button :class="{type_active:item.name==type }" class="type_item" type="text"
|
|
|
+ @click="type=item.name">{{item.name}}</el-button>
|
|
|
+ </el-col>
|
|
|
+
|
|
|
+
|
|
|
</el-row>
|
|
|
- <div class="mt10" v-if="type=='施工现场专业人员'">
|
|
|
- <p style="color: red;font-size: 16px;">
|
|
|
- 报名对象为:2020年度及以后由培训单位核发的和2021年度换发的“电子培训合格证”且每年度需参加继续教育人员
|
|
|
- </p>
|
|
|
- <p style="color: red;font-size: 16px;">
|
|
|
- 注意:继续教育学员请先下载
|
|
|
- <a style="color: blue;cursor: hand;" href="https://sm.hqedust.com/cdn/%E7%BB%A7%E7%BB%AD%E6%95%99%E8%82%B2%E5%A7%94%E6%89%98%E5%9F%B9%E8%AE%AD%E3%80%81%E6%89%BF%E8%AF%BA%E5%87%BD.doc">
|
|
|
- 《继续教育委托培训、承诺函》
|
|
|
- </a>
|
|
|
- ,填写并加盖单位公章后,在申请开通课程界面上传扫描件、并缴费
|
|
|
- </p>
|
|
|
- </div>
|
|
|
- <div class="mt10" v-if="type=='燃气经营企业'">
|
|
|
- <p style="color: red;font-size: 16px;">
|
|
|
- 注意:继续教育学员请先下载
|
|
|
- <a style="color: blue;cursor: hand;" href="https://sm.hqedust.com/cdn/%E7%87%83%E6%B0%94%E4%BA%BA%E5%91%98%E4%BA%BA%E5%91%98%E5%B2%97%E4%BD%8D%E7%BB%A7%E7%BB%AD%E6%95%99%E8%82%B2%E5%A7%94%E6%89%98%E5%9F%B9%E8%AE%AD%E3%80%81%E6%89%BF%E8%AF%BA%E5%87%BD.doc">
|
|
|
- 《燃气人员人员岗位继续教育委托培训、承诺函》
|
|
|
- </a>
|
|
|
- ,填写并加盖单位公章后,在申请开通课程界面上传扫描件、并缴费
|
|
|
- </p>
|
|
|
- </div>
|
|
|
|
|
|
|
|
|
<ul class="pt-line mt20" v-if="ndList.length>1">
|
|
|
- <li style="float: left;font-size: 16px;margin: 4px;padding: 4px;" >
|
|
|
- <span>课程年度:</span>
|
|
|
+ <li style="float: left;font-size: 16px;margin: 4px;padding: 4px;">
|
|
|
+ <span>课程年度:</span>
|
|
|
+ </li>
|
|
|
+ <li style="float: left;">
|
|
|
+ <span :class="{type_active:nd==''}" class="nav-btn-years" @click="nd=''">所有</span>
|
|
|
</li>
|
|
|
<li v-for="item in ndList" style="float: left;">
|
|
|
- <span :class="{active:item==nd }" class="nav-btn-years" @click="nd=item">{{item}} </span>
|
|
|
+ <span :class="{type_active:item==nd }" class="nav-btn-years" @click="nd=item">{{item}} </span>
|
|
|
+ </li>
|
|
|
+ <li style="float: left;">
|
|
|
+ <input type="text" style="line-height: 1;padding: 10px" v-model="filterName"
|
|
|
+ class="ui-ipt ng-pristine ng-valid filterName" placeholder="输入名字查找">
|
|
|
</li>
|
|
|
</ul>
|
|
|
|
|
|
<ul class="m-course-list clear mt10 classlist">
|
|
|
- <li v-for="(item,index) in list.slice(page*size-size, page*size)" :key="item.course_id" class="pt-sola mt20 pb10">
|
|
|
+ <li v-for="(item,index) in list.slice(page*size-size, page*size)" :key="item.course_id"
|
|
|
+ class="pt-sola mt20 pb10">
|
|
|
<div>
|
|
|
<span v-if="item.isFinish==1" class="p-ico2 ico-passed"></span>
|
|
|
<div class="img">
|
|
|
@@ -73,27 +65,35 @@
|
|
|
<span v-if="item.is_pay==0 && item.buyImg =='' && item.payNo == ''">
|
|
|
还未购买
|
|
|
</span>
|
|
|
+ <span v-else-if="item.is_pay == 2 && item.is_import ==9">
|
|
|
+ 预购买中
|
|
|
+ </span>
|
|
|
<span v-else-if="item.is_pay==0" style="background-color: orange;">
|
|
|
等待审核
|
|
|
</span>
|
|
|
<span v-else-if="item.is_pay==2" style="background-color: #78335F;">申请驳回</span>
|
|
|
- <span v-else-if="!item.is_pass" style="background-color: blue;padding: 2px;border-radius: 2px;">在学习中</span>
|
|
|
+ <span v-else-if="!item.is_pass"
|
|
|
+ style="background-color: blue;padding: 2px;border-radius: 2px;">在学习中</span>
|
|
|
<span v-else style="background-color: green;padding: 2px;border-radius: 2px;">已经完成</span>
|
|
|
</div>
|
|
|
|
|
|
<div class="hover-block">
|
|
|
<div class="mask-bg"></div>
|
|
|
- <el-button @click="gotoPlay(item.course_id)" v-if="item.is_pay==1" class="ui-btn btn-blue">进入学习</el-button>
|
|
|
- <el-button @click="goPay(item)" v-else-if="item.is_pay==2 || !!item.buyImg" class="ui-btn btn-w">补充材料</el-button>
|
|
|
+ <el-button @click="gotoPlay(item.course_id)" v-if="item.is_pay==1"
|
|
|
+ class="ui-btn btn-blue">进入学习</el-button>
|
|
|
+ <el-button @click="goPay(item)" v-else-if="item.is_pay==2 || !!item.buyImg"
|
|
|
+ class="ui-btn btn-w">补充材料</el-button>
|
|
|
<el-button @click="goPay(item)" v-else-if="item.payErr" class="ui-btn btn-gr">申请购买</el-button>
|
|
|
<el-button @click="goPay(item)" v-else class="ui-btn btn-o">购买课程</el-button>
|
|
|
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
|
- <div class="tit"><a>{{item.name}}</a></div>
|
|
|
+ <div class="tit"><a>{{item.displayName || item.name}}</a>
|
|
|
+ </div>
|
|
|
+
|
|
|
<div class="info">
|
|
|
- <p class="w1"><span class="p-ico c1"></span> {{item.type}}</p>
|
|
|
+ <p class="w1"><span class="p-ico c1"></span> {{item.type}} </p>
|
|
|
<p class="w2"><span class="p-ico c2"></span>{{item.nd||'2020'}}</p>
|
|
|
<p class="w1">
|
|
|
<span class="p-ico c5"></span> ¥{{item.fee/100}}元
|
|
|
@@ -105,161 +105,112 @@
|
|
|
</div>
|
|
|
</li>
|
|
|
</ul>
|
|
|
+ <div v-if="list.length==0" class="tc mt20 red">
|
|
|
+ <span style="color: red;padding:40px;font-size: 26px;">已经最后一页了</span>
|
|
|
+ </div>
|
|
|
|
|
|
- <el-pagination class="m-pages"
|
|
|
- @current-change="(page)=>{this.page=page}"
|
|
|
- :current-page="page"
|
|
|
- :page-size="size"
|
|
|
- layout="total, prev, pager, next"
|
|
|
- :total="list.length">
|
|
|
+ <el-pagination class="m-pages" @current-change="(page)=>{this.page=page}" :current-page="page" :page-size="size"
|
|
|
+ layout="total, prev, pager, next" :total="list.length">
|
|
|
</el-pagination>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
- <el-dialog class="fc tc" :visible.sync="loginDialog" :close-on-click-modal="false" width="500px" @close="loginDialog=false">
|
|
|
- <div class="login-dialog m-login">
|
|
|
- <un-login @login="login"></un-login>
|
|
|
- </div>
|
|
|
- </el-dialog>
|
|
|
+ <el-dialog title="申请开通课程" :visible.sync="buyCourseDialog" width="550px" top="100px" align="left">
|
|
|
+ <template v-if="!showPay">
|
|
|
+ <el-form label-width="100px" :inline="false" :model="buyForm" :rules="rules"
|
|
|
+ ref="refBuyCourse">
|
|
|
+ <el-form-item label="账户余额" prop="balance" >
|
|
|
+ <p style="margin-left: 20px;font-size: 16px;">
|
|
|
+ <span v-if="userInfo.balance>=buyForm.fee" style="color: green;"> ¥{{userInfo.balance/100}}元</span>
|
|
|
+ <span v-else style="color: red;"> ¥{{userInfo.balance/100}}元</span>
|
|
|
+ </p>
|
|
|
+ </el-form-item>
|
|
|
|
|
|
+ <el-form-item label="报考岗位" prop="courseName">
|
|
|
+ <el-input type="text" placeholder="报考岗位" v-model="buyForm.courseName+'-'+buyForm.nd"
|
|
|
+ style="width: 360px;" />
|
|
|
+ </el-form-item>
|
|
|
|
|
|
- <el-dialog title="申请开通课程" :visible.sync="buyCourseDialog"
|
|
|
- width="800px" top="20px" align="center">
|
|
|
- <el-form label-width="80px" label-position="right" :inline="true" :model="buyForm" status-icon :rules="rules" ref="elForm">
|
|
|
- <el-row align="left">
|
|
|
- <el-col :lg="12" class="pl20 pr20">
|
|
|
- <el-form-item lable="报考岗位" prop="courseName">
|
|
|
- <label slot="label">报考岗位</label>
|
|
|
- <el-input v-model="buyForm.courseName" type="text" placeholder="报考岗位" style="width: 220px;"></el-input>
|
|
|
- </el-form-item>
|
|
|
|
|
|
- </el-col>
|
|
|
+ <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-col :lg="12" class="pl20 pr20">
|
|
|
- <el-form-item lable="证书编号" prop="rzCode">
|
|
|
- <label slot="label">证书编号</label>
|
|
|
- <el-input v-model="buyForm.rzCode" type="text" placeholder="证书编号" style="width: 220px;"></el-input>
|
|
|
+ <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-col>
|
|
|
-
|
|
|
-<!-- <el-row>
|
|
|
- <span style="color: red;padding:10px"> 请认真核实报考岗位与证书编号,本课程不支持退款</span>
|
|
|
- </el-row> -->
|
|
|
-
|
|
|
- <el-col :lg="12" class="pl20 pr20">
|
|
|
- <el-form-item lable="邮箱地址" prop="email">
|
|
|
- <label slot="label">邮箱地址</label>
|
|
|
- <el-input v-model="buyForm.email" type="textarea" placeholder="邮箱地址" style="width: 220px;"></el-input>
|
|
|
+ <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-col>
|
|
|
-
|
|
|
-
|
|
|
- <el-col :span="12" class="pl20 pr20">
|
|
|
- <el-form-item lable="订单号" prop="payNo">
|
|
|
- <label slot="label">订单编号</label>
|
|
|
- <el-input v-model="buyForm.payNo" placeholder="输入订单编号后6位" style="width: 220px;" :minlength="6" :maxlength="6" show-word-limit ></el-input>
|
|
|
+ <el-form-item label="手机号码" prop="phone">
|
|
|
+ <el-input v-model="buyForm.phone" placeholder="请输入手机号码" style="width: 360px;"></el-input>
|
|
|
</el-form-item>
|
|
|
- </el-col>
|
|
|
- </el-row>
|
|
|
- <el-row>
|
|
|
- <el-col :span="12" class="pl20 pr20">
|
|
|
- <el-form-item lable="工作单位" prop="company">
|
|
|
- <label slot="label">工作单位</label>
|
|
|
- <el-input v-model="buyForm.company" type="textarea" placeholder="工作单位" style="width: 220px;"></el-input>
|
|
|
- </el-form-item>
|
|
|
- </el-col>
|
|
|
- <el-col :span="12" class="pl20 pr20">
|
|
|
- <el-form-item lable="备注信息" prop="marks">
|
|
|
- <label slot="label">备注信息</label>
|
|
|
- <el-input v-model="buyForm.marks" type="textarea" placeholder="姓名+工种名称,例:张三+土建施工员" style="width: 220px;"></el-input>
|
|
|
+ <el-form-item label="邮箱地址" prop="email">
|
|
|
+ <el-input v-model="buyForm.email" placeholder="请输入邮箱地址" style="width: 360px;"></el-input>
|
|
|
</el-form-item>
|
|
|
- </el-col>
|
|
|
- </el-row>
|
|
|
- <el-row v-if="hasPromise(type)">
|
|
|
- <div style="width: 700px;margin: 0 auto;text-align: left;color: red;">
|
|
|
- 提示:继续教育承诺函企业名称应与个人报名系统企业名称一致,如已变更单位的,
|
|
|
- 请先在个人系统帐号设置进入额外信息栏进行修改工作单位与报名承诺函工作单位相符后方可上传承诺函确认
|
|
|
- </div>
|
|
|
- <img :src="buyForm.buyImg" :onerror="errorImg" style="width: 160px;text-align: center;">
|
|
|
- <do-upload @onFinish="(url)=>{buyForm.buyImg=url}" placeholder="上传承诺书" width="160px"> </do-upload>
|
|
|
- </el-row>
|
|
|
+ </template>
|
|
|
|
|
|
-
|
|
|
- <el-row>
|
|
|
+ <el-divider></el-divider>
|
|
|
<h2 class="tc"> 本课程费用: <strong style="color: red;"> {{buyForm.fee/100}} 元 </strong> </h2>
|
|
|
- <div style="width: 300px; margin: 0px auto;">
|
|
|
- <img src="/static/images/wxpay.jpg" width="300px" @click="showImg(buyForm.buyImg)">
|
|
|
- </div>
|
|
|
- </el-row>
|
|
|
|
|
|
- <el-row class="tc fc">
|
|
|
- <el-form-item >
|
|
|
+ <el-form-item label-width="0" style="margin: 30px auto;text-align: center;">
|
|
|
<el-button @click="cancelBuyCourse">取 消</el-button>
|
|
|
- <el-button @click="buyCourse" type="primary">确 定</el-button>
|
|
|
+ <el-button @click="generatePayQrcode" type="primary">提交订单</el-button>
|
|
|
+ <el-button v-if="userInfo.balance >= buyForm.fee" @click="doAccountPay" type="success">余额付款</el-button>
|
|
|
</el-form-item>
|
|
|
- </el-row>
|
|
|
-
|
|
|
- </el-form>
|
|
|
-
|
|
|
- </el-dialog>
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
- <el-dialog title="承诺书" class="fc tc" :visible.sync="commitmentDialog">
|
|
|
-
|
|
|
- <div>
|
|
|
- <div v-if="hasPromise(type)">
|
|
|
- <div class="commitment-header"> 致:三明市城市建设项目服务中心 </div>
|
|
|
- <div class="tl commitment">
|
|
|
- {{promise.promise_edu}}
|
|
|
- </div>
|
|
|
- <div class="commitment-footer">
|
|
|
- 特此诺书!
|
|
|
- </div>
|
|
|
- </div>
|
|
|
-
|
|
|
- <div v-else-if="type=='建筑施工企业特种作业人员'">
|
|
|
- <div class="tl commitment">
|
|
|
- {{promise.promise_special}}
|
|
|
- </div>
|
|
|
-
|
|
|
- </div>
|
|
|
|
|
|
+ </el-form>
|
|
|
+ </template>
|
|
|
|
|
|
- <div v-else-if="type=='园林绿化技术工人'">
|
|
|
- <div class="tl commitment">
|
|
|
- {{promise.promise_plant}}
|
|
|
- </div>
|
|
|
- </div>
|
|
|
-
|
|
|
- <div v-else>
|
|
|
- <div class="tl commitment">
|
|
|
- {{promise.promise_other}}
|
|
|
- </div>
|
|
|
- </div>
|
|
|
+ <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>
|
|
|
+ </template>
|
|
|
|
|
|
|
|
|
- <div class="tl commitment-content mt20">
|
|
|
- <el-radio-group v-model="isCommitment">
|
|
|
- <el-row class="mt10">
|
|
|
- <el-radio :label="true">本人作出上述承诺</el-radio>
|
|
|
- </el-row>
|
|
|
- <el-row class="mt10">
|
|
|
- <el-radio :label="false">本人不作出上述承诺</el-radio>
|
|
|
- </el-row>
|
|
|
- </el-radio-group>
|
|
|
- </div>
|
|
|
+ </el-dialog>
|
|
|
|
|
|
- <span slot="footer" class="dialog-footer">
|
|
|
- <el-button @click="commitmentDialog = false">取 消</el-button>
|
|
|
- <el-button type="primary" :disabled="isCommitment?false:true" @click="buyCourseDialog=true">确 定</el-button>
|
|
|
- </span>
|
|
|
- </div>
|
|
|
|
|
|
+ <el-dialog append-to-body close-on-click-modal :visible.sync="showImgDialog" style="margin-top: 0px;"
|
|
|
+ :width="width">
|
|
|
+ <img :src="imgUrl" @load="onLoad" alt="" />
|
|
|
</el-dialog>
|
|
|
|
|
|
- <el-dialog append-to-body close-on-click-modal :visible.sync="showImgDialog" style="margin-top: 0px;" :width="width">
|
|
|
- <img :src="imgUrl" @load="onLoad" alt="" />
|
|
|
+ <el-dialog append-to-body close-on-click-modal :visible.sync="showAllRzcodeDialog" width="1024px">
|
|
|
+ <el-table v-if="buyForm.list.length>0" :data="buyForm.list" border>
|
|
|
+ <el-table-column label="证书编号" prop="certificateNum" align="center" />
|
|
|
+ <el-table-column label="岗位名称" prop="positionName" align="center" />
|
|
|
+ <el-table-column label="证书状态" prop="certificateStatus" align="center" />
|
|
|
+ <el-table-column label="发证机关" prop="certificateOrgan" align="center" />
|
|
|
+ <el-table-column label="发证时间" prop="startTime" align="center" />
|
|
|
+ <el-table-column label="选择" prop="reviewTime" align="center">
|
|
|
+ <template slot-scope="{row}">
|
|
|
+ <el-button @click="selectRzcode(row)" type="primary">选择</el-button>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ </el-table>
|
|
|
</el-dialog>
|
|
|
</div>
|
|
|
</template>
|
|
|
@@ -269,17 +220,15 @@
|
|
|
httpServer
|
|
|
} from "@/components/httpServer/httpServer.js";
|
|
|
|
|
|
- import promise from "./promise.js";
|
|
|
import {
|
|
|
MessageBox
|
|
|
} from "element-ui";
|
|
|
- import unLogin from "../../login/components/unLogin.vue";
|
|
|
import {
|
|
|
parseTime
|
|
|
} from "@/utils";
|
|
|
import DoUpload from '@/components/upload/index.vue'
|
|
|
import exampleImg from '@/assets/template.png'
|
|
|
-
|
|
|
+ import {curDatetime} from '@/utils/date.js'
|
|
|
|
|
|
import {
|
|
|
mapGetters,
|
|
|
@@ -298,35 +247,40 @@
|
|
|
showTip: false,
|
|
|
width: "",
|
|
|
type: '',
|
|
|
+ filterName: '',
|
|
|
list: [],
|
|
|
- nd: new Date().getFullYear()+'',
|
|
|
- ndList:[],
|
|
|
- allList:[],
|
|
|
+ nd: new Date().getFullYear() + '',
|
|
|
+ ndList: [],
|
|
|
+ allList: [],
|
|
|
isCommitment: "",
|
|
|
buyCourseDialog: false,
|
|
|
showExample: false,
|
|
|
showImgDialog: false,
|
|
|
+ showAllRzcodeDialog: false,
|
|
|
+ showPay: false,
|
|
|
buyForm: {
|
|
|
- marks: '',
|
|
|
+ payType:'wx',
|
|
|
rzCode: '',
|
|
|
- payNo:'',
|
|
|
- email:'',
|
|
|
- company:'',
|
|
|
- buyImg:'',
|
|
|
- name:'',
|
|
|
- courseName: ''
|
|
|
+ email: '',
|
|
|
+ title: '',
|
|
|
+ phone: '',
|
|
|
+ courseName: '',
|
|
|
+ list: [],
|
|
|
+ fee: 0,
|
|
|
+ courseId: '',
|
|
|
+ needInvoice: 0,
|
|
|
+ invoiceType: 'personal'
|
|
|
},
|
|
|
- promise,
|
|
|
imgUrl: '',
|
|
|
qrcodeUrl: "",
|
|
|
+ wxPayUrl:"",
|
|
|
+ aliPayUrl:"",
|
|
|
outTradeNo: "",
|
|
|
courseFee: 0,
|
|
|
title: '',
|
|
|
timer: null,
|
|
|
tickCount: 0,
|
|
|
listLoading: false,
|
|
|
- loginDialog: false,
|
|
|
- isLoginOk: false,
|
|
|
media: {},
|
|
|
commitmentDialog: false,
|
|
|
exampleImg: exampleImg,
|
|
|
@@ -335,18 +289,14 @@
|
|
|
required: true,
|
|
|
message: '请输入证书编号'
|
|
|
}],
|
|
|
- payNo:[
|
|
|
- {
|
|
|
- required: true,
|
|
|
- message: '请输入订单编号后六位'
|
|
|
- }
|
|
|
- ],
|
|
|
- marks:[
|
|
|
- {
|
|
|
- required: true,
|
|
|
- message: '请输入备注信息'
|
|
|
- }
|
|
|
- ],
|
|
|
+ payNo: [{
|
|
|
+ required: true,
|
|
|
+ message: '请输入订单编号后六位'
|
|
|
+ }],
|
|
|
+ title: [{
|
|
|
+ required: true,
|
|
|
+ message: '抬头必须填写'
|
|
|
+ }],
|
|
|
email: [{
|
|
|
required: true,
|
|
|
message: '请输入有效邮箱'
|
|
|
@@ -356,6 +306,7 @@
|
|
|
message: '邮箱格式不正确',
|
|
|
trigger: 'blur',
|
|
|
transform(value) {
|
|
|
+ value = value.trim();
|
|
|
if (!/^\w+((-\w+)|(\.\w+))*@[A-Za-z0-9]+((\.|-)[A-Za-z0-9]+)*\.[A-Za-z0-9]+$/.test(value)) {
|
|
|
return true
|
|
|
} else {}
|
|
|
@@ -364,7 +315,15 @@
|
|
|
],
|
|
|
company: [{
|
|
|
required: true,
|
|
|
- message: '请输入所在企业'
|
|
|
+ message: '请输入单位名称'
|
|
|
+ }],
|
|
|
+ phone: [{
|
|
|
+ required: true,
|
|
|
+ message: '请输入手机号码'
|
|
|
+ }, {
|
|
|
+ pattern: /^1[3-9]\d{9}$/,
|
|
|
+ message: '手机号码格式不正确',
|
|
|
+ trigger: 'blur'
|
|
|
}],
|
|
|
courseName: [{
|
|
|
required: true,
|
|
|
@@ -378,7 +337,6 @@
|
|
|
...mapGetters("user", ["typeList", "userInfo"])
|
|
|
},
|
|
|
components: {
|
|
|
- unLogin,
|
|
|
DoUpload
|
|
|
},
|
|
|
filters: {
|
|
|
@@ -389,33 +347,22 @@
|
|
|
watch: {
|
|
|
type(val) {
|
|
|
this.page = 1
|
|
|
- this.nd = new Date().getFullYear()+''
|
|
|
- this.getData()
|
|
|
+ this.nd = new Date().getFullYear() + ''
|
|
|
+ this.filterData()
|
|
|
},
|
|
|
- nd(val){
|
|
|
+ nd(val) {
|
|
|
this.filterData()
|
|
|
},
|
|
|
- isCommitment(val) {
|
|
|
- console.log(val)
|
|
|
+ filterName() {
|
|
|
+ this.page = 1
|
|
|
+ this.filterData()
|
|
|
}
|
|
|
},
|
|
|
beforeMount() {
|
|
|
- this.type = this.$route.query.type||''
|
|
|
- if( this.type ){
|
|
|
- this.getData();
|
|
|
- }
|
|
|
- },
|
|
|
- mounted(){
|
|
|
- if (!this.type && this.typeList.length > 0) {
|
|
|
- for( let i in this.typeList){
|
|
|
- let item = this.typeList[i];
|
|
|
- if(item.isOpen && !item.isNew ){
|
|
|
- this.type = item.name;
|
|
|
- break;
|
|
|
- }
|
|
|
- }
|
|
|
- }
|
|
|
+ this.type = this.$route.query.type || ''
|
|
|
+ this.getData();
|
|
|
},
|
|
|
+
|
|
|
beforeDestroy() {
|
|
|
if (this.timer) window.clearInterval(this.timer);
|
|
|
},
|
|
|
@@ -436,131 +383,150 @@
|
|
|
}
|
|
|
this.width = width + "px";
|
|
|
},
|
|
|
+ initTimer() {
|
|
|
+ if (this.timer) window.clearInterval(this.timer);
|
|
|
+ this.tickCount = 0;
|
|
|
+ this.timer = window.setInterval(() => {
|
|
|
+ this.tickCount++;
|
|
|
+ this.tickTimer();
|
|
|
+ }, 3000);
|
|
|
+ },
|
|
|
+ tickTimer() {
|
|
|
+ if (this.tickCount > 100) {
|
|
|
+ if (this.timer) window.clearInterval(this.timer);
|
|
|
+ this.$message.warning("支付超时,请重新支付");
|
|
|
+ this.buyCourseDialog = false;
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ let outTradeNo = this.outTradeNo;
|
|
|
+ httpServer("weixin.isPayOk", { outTradeNo }).then((res) => {
|
|
|
+ if (res.code == 200 && !!res.data) {
|
|
|
+ if (this.timer) window.clearInterval(this.timer);
|
|
|
+ this.$message.successMsg("支付成功", 2);
|
|
|
+ this.buyCourseDialog = false;
|
|
|
+ this.getData();
|
|
|
+ }
|
|
|
+ });
|
|
|
+ },
|
|
|
+ doAccountPay(){
|
|
|
+ let param = Object.assign({}, this.buyForm);
|
|
|
+ httpServer("weixin.doAccountPay", {courseId}).then((res) => {
|
|
|
+ if (res.code != 200) return;
|
|
|
+ this.$message.successMsg("支付成功", 2);
|
|
|
+ this.buyCourseDialog = false;
|
|
|
+ this.getData();
|
|
|
+ });
|
|
|
+ },
|
|
|
+ generatePayQrcode() {
|
|
|
+ this.$refs["refBuyCourse"].validate((valid) => {
|
|
|
+ if(!valid) return;
|
|
|
+ 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,
|
|
|
+ title,
|
|
|
+ phone,
|
|
|
+ email,
|
|
|
+ needInvoice,
|
|
|
+ invoiceType
|
|
|
+ };
|
|
|
+ httpServer(apiName, param).then((res) => {
|
|
|
+ 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() {
|
|
|
- if (!this.type) return;
|
|
|
let param = {
|
|
|
- size: 100,
|
|
|
- type: this.type,
|
|
|
+ size: 1000,
|
|
|
+ trainType: 2,
|
|
|
from: 0
|
|
|
}
|
|
|
httpServer("course.getcoursemarket", param).then((res) => {
|
|
|
if (res.code == 200) {
|
|
|
this.allList = res.data.list;
|
|
|
- this.ndList = [];
|
|
|
- for( let i in this.allList ){
|
|
|
- let nd = this.allList[i].nd;
|
|
|
- if(this.ndList.indexOf( nd ) == -1 ) this.ndList.push( nd );
|
|
|
- }
|
|
|
this.filterData()
|
|
|
}
|
|
|
});
|
|
|
},
|
|
|
- filterData(){
|
|
|
- let nd = this.nd;
|
|
|
- this.list = this.allList.filter( res=>{
|
|
|
- return res.nd == nd;
|
|
|
- })
|
|
|
- },
|
|
|
- cancelBuyCourse(){
|
|
|
- this.$refs["elForm"].resetFields();
|
|
|
- this.buyCourseDialog=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;
|
|
|
+ filterData() {
|
|
|
+ let nd = this.nd || '';
|
|
|
+ let filterName = this.filterName || '';
|
|
|
+ let type = this.type || ''
|
|
|
+ this.ndList = [];
|
|
|
+ this.list = [];
|
|
|
+ for (let i in this.allList) {
|
|
|
+ let item = this.allList[i];
|
|
|
+ if (type != '' && item.type != type) continue;
|
|
|
+ if (this.ndList.indexOf(item.nd) == -1) {
|
|
|
+ this.ndList.push(item.nd);
|
|
|
}
|
|
|
- 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
|
|
|
- }
|
|
|
- });
|
|
|
- })
|
|
|
+ if (filterName!='' && item.name.indexOf(filterName) == -1) continue;
|
|
|
+ if (nd != '' && item.nd != nd) continue;
|
|
|
+ this.list.push(item)
|
|
|
+ }
|
|
|
},
|
|
|
- gotoDetail(courseId) {
|
|
|
- this.$router.push(`/main/course/${courseId}`);
|
|
|
+ cancelBuyCourse() {
|
|
|
+ if (this.timer) window.clearInterval(this.timer);
|
|
|
+ this.$refs["elForm"] && this.$refs["elForm"].resetFields();
|
|
|
+ this.buyCourseDialog = false
|
|
|
+ this.showPay = false;
|
|
|
},
|
|
|
- uploadBuyImg(url) {
|
|
|
- this.buyForm.buyImg = url;
|
|
|
+ openShowAllRzcodeDialog() {
|
|
|
+ this.showAllRzcodeDialog = true;
|
|
|
},
|
|
|
- hasPromise( type ){
|
|
|
- return type == '施工现场专业人员' || type == '燃气经营企业'
|
|
|
+ selectRzcode(row) {
|
|
|
+ this.buyForm.rzCode = row.certificateNum;
|
|
|
+ this.showAllRzcodeDialog = false;
|
|
|
},
|
|
|
- testBuyOK(item){
|
|
|
- this.stage = 2;
|
|
|
- this.isCompanyPay = 1;
|
|
|
- this.isCommitment=''
|
|
|
- this.buyForm.rzCode = item.rzCode;
|
|
|
- this.buyForm.company = 'ssss';
|
|
|
- this.buyForm.courseName = item.courseName;
|
|
|
- this.buyCourseDialog = true;
|
|
|
+ gotoDetail(courseId) {
|
|
|
+ this.$router.push(`/main/course/${courseId}`);
|
|
|
},
|
|
|
- goPay( item ) {
|
|
|
+ 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;
|
|
|
- let isEdu = this.hasPromise(item.type);
|
|
|
- // this.testBuyOK(item)
|
|
|
- // return;
|
|
|
+ this.buyForm.courseId = item.course_id;
|
|
|
+ this.buyForm.fee = item.fee;
|
|
|
// 检查
|
|
|
- item.payErr = true;
|
|
|
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);
|
|
|
-
|
|
|
- if( isEdu){
|
|
|
- this.buyCourseDialog = true;
|
|
|
- }else{
|
|
|
- this.commitmentDialog = true;
|
|
|
- }
|
|
|
- }else{
|
|
|
- console.log("payErr")
|
|
|
- item.payErr = true;
|
|
|
- }
|
|
|
+ if (res.code != 200) return;
|
|
|
+ Object.assign(this.buyForm, res.data);
|
|
|
+ this.buyCourseDialog = true;
|
|
|
});
|
|
|
},
|
|
|
- gotoPlay(courseId) {
|
|
|
- this.$router.push(`/center/class/train`);
|
|
|
+ gotoPlay(item) {
|
|
|
+ let courseId = item.courseId;
|
|
|
+ if( curDatetime() < item.startDate){
|
|
|
+ this.$message.warning("还未到学习时间");
|
|
|
+ return
|
|
|
+ }
|
|
|
+ this.$router.push({name:'play', params:{courseId}})
|
|
|
},
|
|
|
handleCurrentChange(page) {
|
|
|
this.page = page;
|
|
|
- this.getData()
|
|
|
- },
|
|
|
- login(param) {
|
|
|
- httpServer("Auth.LoginStudy", param).then(res => {
|
|
|
- if (res.code == 200) {
|
|
|
- let {
|
|
|
- nickname,
|
|
|
- token,
|
|
|
- uid
|
|
|
- } = res.data;
|
|
|
- localStorage.nickname = nickname;
|
|
|
- localStorage.token = token;
|
|
|
- localStorage.uid = uid
|
|
|
- this.user = {
|
|
|
- nickname,
|
|
|
- token,
|
|
|
- uid
|
|
|
- };
|
|
|
- this.loginOk = true
|
|
|
- this.loginDialog = false
|
|
|
- }
|
|
|
- })
|
|
|
+ this.filterData()
|
|
|
}
|
|
|
},
|
|
|
};
|
|
|
@@ -598,21 +564,23 @@
|
|
|
.commitment-content {
|
|
|
font-size: 16px;
|
|
|
}
|
|
|
- .tip-card{
|
|
|
+
|
|
|
+ .tip-card {
|
|
|
border-radius: 20px;
|
|
|
- font-size:14px;
|
|
|
+ font-size: 14px;
|
|
|
float: right;
|
|
|
width: 420px;
|
|
|
right: 20px;
|
|
|
position: absolute;
|
|
|
- top:50px;
|
|
|
+ top: 50px;
|
|
|
color: white;
|
|
|
- background-color: #7fbae4 ;
|
|
|
+ background-color: #7fbae4;
|
|
|
z-index: 1000;
|
|
|
}
|
|
|
+
|
|
|
.tips-intro {
|
|
|
- color: #468cf2;
|
|
|
- cursor: pointer;
|
|
|
- position: relative;
|
|
|
+ color: #468cf2;
|
|
|
+ cursor: pointer;
|
|
|
+ position: relative;
|
|
|
}
|
|
|
</style>
|