提交 c1cd724d 编写于 作者: guangjun.yang's avatar guangjun.yang

职称考项目

上级 a1e4d916
......@@ -146,12 +146,12 @@ export default {
// 如果是考试,将根据appVersion判断是新考试还是老考试,如果是301或之前的,都是老考试
gotoExamOrCourse(item) {
// 埋点:去学习、继续学习、复习、去考试、重考
let actionCode = sendBuriedDataMap[item.status];
if(actionCode) {
this.$sendBuriedData({
component_tag: `882#${actionCode}#${this.projectId}`
});
}
// let actionCode = sendBuriedDataMap[item.status];
// if(actionCode) {
// this.$sendBuriedData({
// component_tag: `882#${actionCode}#${this.projectId}`
// });
// }
let appVersion = getAppVersion(this.userInfo.appVersion);
if (item.useFlag == 2) return;
if (window.__isWeb) {
......
......@@ -5,8 +5,6 @@
class="cell-detail"
v-for="(component , index) in projectComponent"
:key="index">
<!-- <CommonTitle :fontWeight="500" :title="component.name" :isShowCert="true" :isShowExplain="true" @showDialog="showDialog(component.introduce)"></CommonTitle> -->
<!-- <MergeTitle :fontWeight="500" :title="component.name" :isShowCert="component.status" :isShowExplain="true" @showDialog="showDialog(component.introduce)"></MergeTitle> -->
<van-collapse v-model="activeNames" @change="changeCollapse">
<van-collapse-item
v-for="(portalModule, index) in component.portalModuleDTOS"
......@@ -17,7 +15,6 @@
:disabled="portalModule.disabled"
@click.native="chooseItem(portalModule)"
>
<!-- @click.native="chooseItem(item)" -->
<article @click.stop="deleteFlow()" class="cell-container">
<span class="" v-for="(item, index) in portalModule.contentList" :key="index">
<div v-if="index > 0 && portalModule.contentList[index].templetId!= portalModule.contentList[index-1].templetId" class="bottom-line"></div>
......@@ -38,31 +35,24 @@
>
{{getActionText(item.status, item.type)}}
</span>
<!-- <img @click="toastToBuy" class="key" v-show="!hasBindCard" src="../../images/cme/phrase2/key.png" alt=""> -->
<div class="foot-line"
v-if="index+1 < portalModule.contentList.length && portalModule.contentList[index].templetId == portalModule.contentList[index+1].templetId">
</div>
</div>
<span v-if="item.certificateFlag == 2">
<!-- <span v-if="item.certificateFlag == 2">
<img class="cert-img" :class="{'space2': item.height == 2 }" src="../../images/has-cert-new.png">
</span>
</span> -->
</span>
</article>
</van-collapse-item>
</van-collapse>
</div>
<van-dialog
v-model="dialogState"
title="标题"
>
</van-dialog>
</section>
</template>
<script>
import MergeTitle from "@/components/business/merge-title";
import NoMoreContent from "@/components/business/no-more-content";
import CertShow from "@/components/business/cert-show";
import { Collapse, CollapseItem, Dialog, Toast } from 'vant';
import { mapGetters } from "vuex";
import { getAppVersion } from "@/utils";
......@@ -92,7 +82,6 @@ export default {
appVersion: "200",
hocImg: require("../../images/has-owner-cert.png"),
activeNames: [1],
dialogState: false,
projectId: 1
};
},
......@@ -127,7 +116,6 @@ export default {
},
components: {
MergeTitle,
CertShow,
NoMoreContent,
Dialog,
},
......@@ -149,22 +137,16 @@ export default {
// 如果是考试,将根据appVersion判断是新考试还是老考试,如果是301或之前的,都是老考试
gotoExamOrCourse(item) {
// 埋点:去学习、继续学习、复习、去考试、重考
let actionCode = sendBuriedDataMap[item.status];
if(actionCode) {
this.$sendBuriedData({
component_tag: `882#${actionCode}#${this.projectId}`
});
}
// let actionCode = sendBuriedDataMap[item.status];
// if(actionCode) {
// this.$sendBuriedData({
// component_tag: `882#${actionCode}#${this.projectId}`
// });
// }
let appVersion = getAppVersion(this.userInfo.appVersion);
if (item.useFlag == 2) return;
// if (window.__isWeb) {
// // this.$refs.toastTitle.toast("请您下载App");
// Toast('请您下载App');
// return;
// }
if (item.type == 1) {
if (appVersion <= 300) {
// this.$refs.toastTitle.toast("请您下载新版本App");
Toast('请您下载新版本App');
return;
} else {
......@@ -175,7 +157,8 @@ export default {
}
},
// 跳转到课程
// 跳转到课程
// TODO 查看课程是否是最后一节课, 如果是,则要查找到相应的考试,并传递给原生端
gotoCourse: function(courseId) {
let appVersion = getAppVersion(this.userInfo.appVersion);
// 弹框提示下载新版本可以试看
......
<template>
<!-- 项目组件列表项 -->
<section>
<article v-for="(item, index) in paramData" :key="item.id">
<CommonTitle :title="item.name" :isShowCert="item.status == 2"></CommonTitle>
<article class="comp-container">
<div class="comp-container-item"
:class="{'ht-for-m16': model.moduleName.length > 16}"
v-for="model in paramData[index].portalModulesModels" :key="model.id">
<span class="name">{{model.moduleName}}</span>
<!-- <span class="name">{{model.moduleName | shortName(10)}}</span> -->
<span v-if="model.status == 2" class="action" @click="showModule(model, item.id)">查看</span>
<span v-else class="action-no" >即将开始</span>
</div>
</article>
</article>
</section>
</template>
<script>
import CommonTitle from "@/components/common/common-title";
import NoMoreContent from "@/components/business/no-more-content";
import { getWebPageUrl } from "@/utils/index"
export default {
name: "comp-list-item",
data() {
return {};
},
props: {
paramData: {
type: Array,
default: () => []
},
projectId: {
type: String | Number,
default: 1
},
courseRequire: {
type: Number,
default: 0
}
},
components: {
CommonTitle,
NoMoreContent
},
mounted() {},
methods: {
// // 跳转到模块内容页面
// showModule(item, id) {
// this.$router.push({
// path: "/comp",
// query: {
// componentId: id,
// // projectId: this.projectId,
// moduleId: item.moduleId,
// moduleName: item.moduleName
// }
// });
// },
// 跳转到模块内容页面
showModule(item, id) {
if (window.__isWeb) {
this.$router.push({
path: "/comp2",
query: {
componentId: id,
projectId: this.projectId,
moduleId: item.moduleId,
moduleName: item.moduleName,
courseRequire: this.courseRequire,
}
});
return;
}
let pageUrl = getWebPageUrl('cme/#/comp2');
let moduleName = encodeURIComponent(item.moduleName)
let paramList = [
{
key: "pageUrl",
value: pageUrl + `?componentId=${id}&moduleId=${item.moduleId}&moduleName=${moduleName}&projectId=${this.projectId}&courseRequire=${this.courseRequire}`,
type: 4,
seqNo: 1
}
]
rocNative.dispatchEventByModuleCode({
modeCode: "M300",
jsonString: paramList
});
}
}
};
</script>
<style lang="scss" scoped>
@import "../../style/mixin";
.comp-container {
display: flex;
flex-direction: column;
margin: 0 px2rem(15px);
&-item {
display: flex;
flex-direction: row;
margin: px2rem(6px) px2rem(0px);
height: px2rem(51px);
// line-height: px2rem(51px);
font-size: px2rem(15px);
padding: px2rem(0px) px2rem(15px);
background: rgba(248, 249, 250, 1);
border-radius: px2rem(6px);
justify-content: space-between;
align-items: center;
.name {
max-width: px2rem(240px);
font-size: px2rem(15px);
line-height: px2rem(25px) !important;
color: #676869;
}
.action {
width: px2rem(60px);
height: px2rem(25px);
line-height: px2rem(25px);
text-align: center;
font-size: px2rem(12px);
font-weight: 700;
border-radius: px2rem(15px);
// font-family: "PingFangSC-Medium", "PingFangSC", "Microsoft Yahei";
// opacity: 0.45;
border: 1px solid rgba(68, 146, 132, 0.6);
color: rgba(68, 146, 132, 1);
}
.action-no {
width: px2rem(60px);
height: px2rem(25px);
line-height: px2rem(25px);
text-align: center;
font-size: px2rem(12px);
font-weight: 700;
border-radius: px2rem(15px);
// font-family: "PingFangSC-Medium", "PingFangSC", "Microsoft Yahei";
// opacity: 0.45;
border: 1px solid #E7E8E9;
color: #C7C8C9;
}
// span {
// width: 100%;
// }
}
}
.ht-for-m16 {
height: px2rem(66px);
}
</style>
<template>
<!-- 专项合作列表 -->
<section class="coop-container">
<div
v-show="paramData.length && isShow"
v-for="(item , index) in paramData"
:key="index"
class="coop-item"
@click="coopDetails(item)"
>
<div class="coop-item-left">
<img :src="item.imgUrl" />
<span
v-if="item.projectStatusValue"
class="coop-container-status"
:style="{'background': cBgColor(item)}"
>{{item.projectStatusValue | statusText}}</span>
</div>
<div class="coop-item-right">
<span class="coop-item-right-title">{{item.name}}</span>
<span v-if="item.cmeType == 2" class="coop-item-right-other">{{item.level}} | {{item.scope}}</span>
<span v-if="item.cmeType != 2" class="coop-item-right-other">{{item.level}} | {{item.credit}} | {{item.scope}}</span>
<span class="coop-item-right-other">{{item.startDate | formatTime('{y}.{m}.{d}')}}{{item.endDate | formatTime('{y}.{m}.{d}')}} <span v-if="item.cardStatus == 1" class="active"><span>已激活</span></span></span>
</div>
</div>
<NoMoreContent v-show="paramData.length > 9"></NoMoreContent>
<NoContent v-show="!paramData.length && isShow" :tabNum="tabTo"></NoContent>
</section>
</template>
<script>
import NoMoreContent from "@/components/business/no-more-content";
import NoContent from "@/components/business/no-content";
import UpdateDialog from "@/components/business/update-dialog";
import { setEventByModuleCode, deepCopy, getWebPageUrl } from "@/utils/index";
import { getAppVersion } from "@/utils";
import { mapActions, mapGetters } from "vuex";
import { Popup, Toast } from "vant";
export default {
name: "coop-list-item",
data() {
return {
bgColor: "green",
statusText: "进行中",
showGoUpdate: false
};
},
props: {
paramData: {
type: Array,
default: () => []
},
coopType: {
type: Number,
default: 1
},
isShow: {
type: Boolean,
default: false
},
tabTo: {
type: Number,
default: 1
},
userMobile: {
type: String,
default: ""
},
provinceId: {
type: String | Number,
default: 0
},
organizationId: {
type: String | Number,
default: 0
},
},
computed: {
...mapGetters(["userInfo"])
},
components: {
NoMoreContent,
NoContent,
UpdateDialog
},
mounted() {},
filters: {
statusText(status) {
if (status === 1) {
return "参加中";
} else if (status === 5) {
return "进行中";
} else if (status === 10) {
return "已结束";
} else {
return "已结束";
}
}
},
methods: {
...mapActions(["setProjectTabIndex"]),
cBgColor(item) {
if (item.projectStatusValue === 1) {
return "#5890DD";
} else if (item.projectStatusValue === 5) {
return "#449284";
} else if (item.projectStatusValue === 10) {
return "#373839";
} else {
return "#5890DD";
}
},
coopDetails(item) {
this.$sendBuriedData({
component_tag: `880#8803#${item.id}#${item.name}` //'210#210002#0#'+item.projectName
});
let appVersion = this.userInfo.appVersion;
let appVersionNum = appVersion.split('.').join('');
console.log('appVersionNum', appVersionNum);
if(appVersionNum < 341) {
Toast('请您下载新版本App');
return;
}
// 临时添加
if(window.__isWeb) {
this.$router.push({
path: "/coop",
query: {
id: item.id,
coopType: this.coopType,
courseRequire: item.courseRequire,
provinceId: this.provinceId,
organizationId: this.organizationId
}
});
return;
}
if (this.userMobile) {
let paramList = [
{
key: "pageUrl",
value: getWebPageUrl(`cme/#/coop?id=${item.id}&courseRequire=${item.courseRequire}&provinceId=${this.provinceId}&organizationId=${this.organizationId}`),
type: 4,
seqNo: 1
}
];
rocNative.dispatchEventByModuleCode({
modeCode: "M300",
jsonString: paramList
});
} else {
rocNative.gotoLogin();
}
},
goToPage(item) {
let _this = this;
// 如果是湖北考试项目,则做相应权限判断 湖北的projectId=3
if (item.id == "3") {
if (!_this.userInfo.userToken) {
rocNative.gotoLogin();
return;
}
let param = {
type: 1,
token: _this.userInfo.userToken || _this.token,
setEntry: true
};
this.GET("portal/portalApp/role/3", param).then(res => {
if (res.code == "000000") {
// {
// "data": 0, // 0就是无权限,1有权限
// "code": "000000",
// "message": "成功"
// }
if (res.data == 0) {
rocNative.showNativeToast({
message: "您不属于该项目,无法查看"
});
return;
}
} else {
rocNative.gotoLogin();
return;
}
_this.goToPage1(item.contentListModel);
});
} else {
_this.goToPage1(item.contentListModel);
}
},
// 跳转
goToPage1(itemData) {
let paramList = deepCopy(setEventByModuleCode(itemData));
let isStrokeUrl =
paramList[0] &&
paramList[0]["value"] &&
paramList[0]["value"].indexOf("stroke.js") !== -1;
let strokeUrl = "";
if (isStrokeUrl) {
strokeUrl =
paramList[0]["value"] + "&token=" + this.userInfo.userToken ||
_this.token;
paramList[0]["value"] = strokeUrl;
}
rocNative.dispatchEventByModuleCode({
modeCode: itemData.appModuleInfo.code,
jsonString: paramList
});
// this.appBuryingPointEntrust({
// ...activity_action,
// labelId: itemData.id,
// functionCode: this.id == 1 ? "c_project" : "f_activity",
// actionCode: this.id == 1 ? "c_project_tab" : "c_activity_tab",
// labelValue: itemData.title,
// createdTime: new Date().getTime()
// });
},
goUpdateHandler() {
//去更新
rocNative.upGradeVersion();
this.showGoUpdate = false;
}
}
};
</script>
<style lang="scss" scoped>
@import "../../style/mixin";
.coop-container {
position: relative;
margin: px2rem(0px) px2rem(15px);
&-status {
position: absolute;
top: px2rem(6px);
left: 0;
// display: block;
width: px2rem(44px);
height: px2rem(18px);
line-height: px2rem(18px);
padding: px2rem(0px) 0 0 px2rem(4px);
background: rgba(88, 144, 221, 1);
color: #fff;
font-size: px2rem(11px);
border-top-right-radius: px2rem(3px);
border-bottom-right-radius: px2rem(3px);
}
}
.coop-item {
display: flex;
width: 100%;
height: px2rem(128px);
border-bottom: 1px solid #f0f0f0;
background: #fff;
flex-direction: row;
justify-content: center;
align-items: center;
img {
width: px2rem(115px);
height: px2rem(86px);
margin-right: px2rem(15px);
border-radius: px2rem(3px);
}
&-left {
display: flex;
position: relative;
top: 0;
}
&-right {
display: flex;
width: px2rem(215px);
flex-direction: column;
padding-top: px2rem(4px);
&-title {
height: px2rem(50px);
line-height: px2rem(20px);
font-size: px2rem(16px);
font-weight: 700;
color: rgba(55, 56, 57, 1);
}
&-other {
height: px2rem(21px);
line-height: px2rem(20px);
font-size: px2rem(13px);
font-weight: 400;
color: rgba(151, 152, 153, 1);
width: px2rem(210px);
overflow : hidden;
text-overflow: ellipsis;
white-space:nowrap;
.active {
position: absolute;
z-index: 1;
right: 0;
height: px2rem(18px);
line-height: px2rem(18px);
color: #CAA861;
border-radius: px2rem(3px);
border: 1px solid rgba(202,168,97,1);
span {
position: relative;
top: px2rem(-1.1px);
z-index: 2;
font-size: px2rem(11px);
padding: 0 px2rem(4px);
}
}
}
}
}
.update-dialog-content {
padding: 0 px2rem(15px);
box-sizing: border-box;
.title {
text-align: center;
color: #373839;
font-size: px2rem(18px);
padding: px2rem(15px) 0;
line-height: px2rem(25px);
}
.update-btn {
text-align: center;
height: px2rem(55px);
line-height: px2rem(55px);
font-size: px2rem(16px);
color: #979899;
&.confirm-btn {
color: #449284;
}
&.v-hairline-top::after {
border-top-width: 1px;
}
}
}
</style>
<style>
.van-overlay {
background-color: rgba(0, 0, 0, 0.5);
}
</style>
<template>
<div v-show="isShow && needShow" class="pop-sign-box">
<div class="pop-mask"></div>
<div class="pop-box">
<img src="../../images/tankuang.png">
<div class="pop-text">
<p class="pop-text-joy">恭喜你获得</p>
<p class="pop-text-tips">{{popText}}</p>
</div>
<span class="pop-box-btn" @click="gotoCertDetail">查看证书</span>
<div class="sin-close" @click="close">
<img src="../../images/close.png">
</div>
</div>
<Toast ref="toastTitle"></Toast>
</div>
</template>
<script>
import Toast from "@/components/common/common-toast";
import { mapGetters } from "vuex";
import { getAppVersion } from "@/utils";
export default {
data() {
return {
isShow: true,
// appVersion: "200",
// certUrl: '',
// certId: '',
textTips:
"国家公共卫生办公室高血压慢病管理资格国家公共卫生办公室高血压慢病管理资格"
};
},
props: {
certUrl: {
type: String,
default: ""
},
certId: {
type: String || Number,
default: ""
},
popText: {
type: String,
default: ""
},
needShow: {
type: Boolean,
default: false
}
},
computed: {
...mapGetters(["userInfo"])
},
components: {
Toast
},
mounted() {
},
methods: {
// 显示组件
show() {
this.isShow = true;
},
// 关闭组件
close() {
this.isShow = false;
},
// 设置组件文本内容,并根据条件进行显示
// setCertInfo(tips, certUrl, certId, isShow = true) {
// this.textTips = tips;
// this.certUrl = certUrl;
// this.certId = ticertIdps;
// if (this.isShow) {
// this.isShow = isShow;
// }
// },
// 跳转到证书详情页面
gotoCertDetail: function() {
let _this = this;
let param = {
id: _this.certId,
token: _this.userInfo.userToken
};
if (window.__isWeb) {
_this.$refs.toastTitle.toast("请您下载App");
return;
}
let appVersion = getAppVersion(_this.userInfo.appVersion);
if (appVersion <= 300) {
_this.$refs.toastTitle.toast("请您下载新版本App");
return;
}
_this.API_GET("app/certificate/downLoad", param).then(res => {
if (res.respCode == 200) {
// id=418644
let paramList = [
{
key: "className",
value:
"com.picahealth.yunque.activitys.honor.CheckCertificatesActivity###YQWebView",
type: 4,
seqNo: 1
},
{
key: "url",
value: res.certificateUrl,
type: 4,
seqNo: 2
},
{
key: "id",
value: _this.certId,
type: 4,
seqNo: 3
},
{
key: "navTitle",
value: _this.popText,
type: 4,
seqNo: 4
},
{
key: "isNotTab",
value: true,
type: 4,
seqNo: 5
},
{
key: "isShowDownload",
value: true,
type: 4,
seqNo: 6
}
];
rocNative.dispatchEventByModuleCode({
modeCode: "M200",
jsonString: paramList
});
}
});
}
}
};
</script>
<style lang="scss" scoped>
@import "../../style/mixin";
.pop-sign-box {
position: fixed;
width: 100%;
height: 100%;
left: 0;
top: 0;
z-index: 110;
.pop-box {
background: #fff;
// background: #00FF00 url(../../images/tankuang.png) no-repeat center center ;
width: px2rem(280px);
height: px2rem(312px);
border-radius: px2rem(7px);
position: absolute;
z-index: 112;
text-align: center;
left: 50%;
top: 50%;
margin: px2rem(-180px) 0 0 px2rem(-140px);
img {
width: px2rem(280px);
height: px2rem(312px);
vertical-align: middle;
}
&-btn {
position: relative;
top: px2rem(-62px);
display: inline-block;
width: px2rem(215px);
height: px2rem(44px);
line-height: px2rem(44px);
// font-family: "PingFangSC-Medium", "PingFangSC", "Microsoft Yahei";
font-size: px2rem(16px);
background: linear-gradient(
360deg,
rgba(255, 227, 97, 1) 0%,
rgba(255, 217, 121, 1) 100%
);
box-shadow: 0px px2rem(4px) px2rem(4px) 0px rgba(0, 0, 0, 0.09);
border-radius: px2rem(22px);
color: #a78400;
font-weight: 700;
}
}
.pop-text {
position: absolute;
top: px2rem(160px);
width: 100%;
text-align: center;
&-joy {
color: #ff9a4b;
font-size: px2rem(24px);
// font-family: "PingFangSC-Medium", "PingFangSC", "Microsoft Yahei";
font-weight: 700;
}
&-tips {
// font-family: "PingFangSC-Medium", "PingFangSC", "Microsoft Yahei";
color: #ff9a4b;
font-size: px2rem(14px);
font-weight: 400;
padding: px2rem(8px) px2rem(10px) px2rem(24px) px2rem(10px);
}
}
// .si-joy {
// color: #ff7c26;
// font-size: px2rem(18px);
// }
// .si-tips {
// color: #666;
// font-size: px2rem(14px);
// padding: px2rem(8px) px2rem(10px) px2rem(24px) px2rem(10px);
// }
.pop-mask {
position: absolute;
background: rgba(0, 0, 0, 0.5);
width: 100%;
height: 100%;
z-index: 111;
}
.sin-close {
position: absolute;
width: px2rem(30px);
height: px2rem(30px);
bottom: px2rem(-50px);
margin-left: px2rem(-15px);
left: 50%;
img {
width: px2rem(30px);
height: px2rem(30px);
display: block;
}
}
// font-size:px2rem(12px) ;
}
</style>
<template>
<section @click="jumpToCardList" class="I-card-item-wrapper">
<article class="item">
<img class="left-icon" src="../../images/cme/phrase2/I-img.png" alt />
<article class="center">
<span class="top">国家级继续医学教育项目(远程)</span>
<span class="bottom">上百个项目持续更新上线</span>
</article>
<img class="right-icon" src="../../images/cme/phrase2/arr-right.png" alt />
</article>
</section>
</template>
<script>
import { Toast } from 'vant';
import { getWebPageUrl } from "@/utils/index";
import { mapGetters } from "vuex";
export default {
data() {
return {};
},
props: {
oneLevelUrl: {
type: String,
default: ""
},
provinceId: {
type: String | Number,
default: ""
},
organizationId: {
type: String | Number,
default: ""
},
cmeToken: {
type: String,
default: ""
}
},
computed: {
...mapGetters(["userInfo"])
},
methods: {
// 跳转I类学习详情(介绍)页面
jumpToCardList() {
this.$sendBuriedData({
component_tag: "880#8802"
});
let appVersion = this.userInfo.appVersion;
let appVersionNum = appVersion.split('.').join('');
console.log('appVersionNum', appVersionNum);
if(appVersionNum < 341) {
Toast('请您下载新版本App');
return;
}
if (!this.userInfo.userMobile) {
rocNative.gotoLogin();
return;
}
if (window.__isWeb) {
console.log("in jumpToCardList");
return;
} else {
let pageUrl = getWebPageUrl("cme/#/icredit-detail");
let paramList = [
{
key: "pageUrl",
value: `${pageUrl}?provinceId=${this.provinceId}&organizationId=${this.organizationId}&cmeToken=${this.cmeToken}&oneLevelUrl=` + encodeURIComponent(this.oneLevelUrl),
type: 4,
seqNo: 1
}
];
rocNative.dispatchEventByModuleCode({
modeCode: "M300",
jsonString: paramList
});
}
}
}
};
</script>
<style lang="scss" scoped>
@import "../../style/mixin";
.I-card-item-wrapper {
// width: 100%;
margin: 0 px2rem(15px);
.item {
// width: 100%;
display: flex;
height: px2rem(72px);
flex-direction: row;
align-content: space-between;
align-items: center;
// box-sizing: border-box;
padding: 0 px2rem(15px);
background: #f8f9fa;
border-radius: px2rem(6px);
.left-icon {
width: px2rem(40px);
height: px2rem(40px);
margin-right: px2rem(15px);
}
.center {
position: relative;
top: -4px;
left: 0;
display: flex;
flex-direction: column;
flex: 1;
height: px2rem(40px);
align-content: flex-start;
text-align: left;
.top {
height: px2rem(26px);
line-height: px2rem(26px);
font-size: px2rem(16px);
font-weight: 700;
color: rgba(55, 56, 57, 1);
}
.bottom {
font-size: px2rem(14px);
font-weight: 400;
color: rgba(151, 152, 153, 1);
}
}
.right-icon {
width: px2rem(15px);
height: px2rem(15px);
}
}
}
</style>
\ No newline at end of file
......@@ -8,32 +8,17 @@
<div class="pro-name">
<span class="title">项目名称</span>
<span class="name">{{projectName}}</span>
</div>
<!-- <div class="content"> -->
<!-- <span>学习收获</span>
<span>
{{level}}
<b v-show="cmeType !=2" class="split"></b>
{{ cmeType !=2 ? projectCredit : ''}}
</span> -->
<!-- <span>{{level}} | {{projectCredit}}</span> -->
<!-- </div> -->
</div>
<div class="content">
<!-- <span>申请范围</span> -->
<span>学习范围</span>
<span>{{scope}}</span>
</div>
<div class="remind" v-if="remind && cmeType != 2">
<span>{{remind}}</span>
</div>
<div class="content">
<span>起止时间</span>
<span>{{startDate | formatTime('{y}.{m}.{d}')}}{{endDate | formatTime('{y}.{m}.{d}')}}</span>
</div>
<div class="content">
<!-- <span>{{cmeType == 2 ? '主办单位' : '发起机构'}}</span> -->
<!-- <span>主办单位</span> -->
<span>申办单位</span>
<span>主办单位</span>
<span>{{organName}}</span>
</div>
</div>
......@@ -77,10 +62,6 @@ export default {
type: String,
default: ""
},
cmeType: {
type: String | Number,
default: 2
},
projectName: {
type: String,
default: ""
......
......@@ -31,9 +31,9 @@ export default {
jumpToCardList() {
// 如果没有登录,则要去登录页面
// 打开页面埋点
this.$sendBuriedData({
component_tag: "880#8801"
});
// this.$sendBuriedData({
// component_tag: "880#8801"
// });
let appVersion = this.userInfo.appVersion;
let appVersionNum = appVersion.split('.').join('');
console.log('appVersionNum', appVersionNum);
......
<template>
<section class="card-popup-wrapper">
<van-popup
v-model="isShow"
position="center"
@click-overlay="clickOverlay"
>
<article class="content">
<p class="title">学分项目必须使用学习卡</p>
<p class="title">请先购买学习卡</p>
<section class="card-info">
<img v-if="cardInfo.cardType == 1" class="icon" src="../../images/cme/phrase2/I-card-icon.png" alt />
<img v-else class="icon" src="../../images/cme/phrase2/II-card-icon.png" alt />
<div class="info2">
<span class="name">{{cardInfo.goodsName}}</span>
<p>
<span class="price">{{(cardInfo.preferentialPrice || cardInfo.costPrice) | formatMoney}}</span><span v-show="cardInfo.preferentialPrice" class="discount"><del> 原价¥{{cardInfo.costPrice | formatMoney}}</del></span>
</p>
</div>
<!-- <div class="info2">
<span class="name">已购买去学习已购买去学购买去学习买</span>
<p>
<span class="price">¥100</span><span class="discount"><del> 原价¥120</del></span>
</p>
</div> -->
</section>
<div class="line"></div>
<div class="btn">
<span class="left" @click="cancle">已购买去学习</span>
<span class="vert-line"></span>
<span class="right" @click="confirm">去购买</span>
</div>
</article>
</van-popup>
</section>
</template>
<script>
import { Popup } from "vant";
export default {
data() {
return {
}
},
props: {
isShow: {
type: Boolean,
default: false,
},
cardInfo: {
id: 10031,
goodsVersion: 1,
cardType: 1,
costPrice: 0,
preferentialPrice: 0,
goodsDesc: "",
goodsName: "学习卡",
goodsType: 2,
isSale: 1,
}
},
methods: {
clickOverlay() {
this.$emit('clickOverlay');
},
cancle() {
this.$emit('cancle');
},
confirm() {
this.$emit('confirm');
}
},
}
</script>
<style lang="scss" scoped>
@import "../../style/mixin";
.card-popup-wrapper {
.content {
font-size: px2rem(14px);
width: px2rem(300px);
// height: px2rem(245px);
padding-top: px2rem(30px);
.title {
text-align: center;
font-size: px2rem(18px);
font-weight: 700;
}
.card-info {
display: flex;
flex-direction: row;
align-items: center;
height: px2rem(76px);
margin: px2rem(15px);
padding: 0 px2rem(8px);
background: #F8F9FA;
border-radius: px2rem(6px);
font-size: px2rem(14px);
.icon {
width: px2rem(60px);
height: px2rem(60px);
margin-right: px2rem(8px);
}
.info {
width: 100%;
position: relative;
top: 0;
left: 0;
.name {
position: absolute;
top: px2rem(-30px);
left: px2rem(4px);
}
p {
position: absolute;
bottom: px2rem(-34px);
left: 0px;
display: flex;
align-items: center;
.price {
color: #FB5B52;
font-size: px2rem(18px);
font-weight: 700;
margin-right: px2rem(8px);
}
.discount {
color: #979899;
}
}
}
.info2 {
display: flex;
flex-direction: column;
.name {
// position: absolute;
// top: px2rem(-30px);
// left: px2rem(4px);
}
p {
display: flex;
align-items: center;
height: px2rem(24px);
line-height: px2rem(24px);
.price {
color: #FB5B52;
font-size: px2rem(18px);
font-weight: 700;
margin-right: px2rem(8px);
}
.discount {
color: #979899;
}
}
}
}
.line {
margin-top: px2rem(30px);
height: px2rem(1px);
background: #F0F1F2;
}
.btn {
width: 100%;
display: flex;
flex-direction: row;
// justify-content: space-between;
align-items: center;
height: px2rem(50px);
// margin-top: px2rem(15px);
font-size: px2rem(17px);
.left {
flex: 1;
text-align: center;
color: #979899;
// border-right: 1px solid #F0F1F2;
}
.vert-line {
border-right: 1px solid #F0F1F2;
// width: px2rem(1px);
height: 100%;
}
.right {
flex: 1;
text-align: center;
color: #449284;
}
}
}
.van-popup.van-popup--center {
border-radius: px2rem(4px);
}
}
</style>
<template>
<van-popup
v-model="isShow"
@click-overlay="cancle"
position="bottom"
>
<section class="bind-cart-wrapper">
<article class="title">
<span>激活详情</span>
<img @click="cancle" src="../../images/cme/close.png" />
</article>
<article class="tip">
<div class="left">
<img src="../../images/cme/phrase2/info.png" />
<span>激活码用于学习课程,您可以从订单详情或您的实体卡查看激活码。激活码一旦使用,不可退回。</span>
</div>
</article>
<section class="input-wrapper">
<article class="code-new">
<!-- <van-field
maxlength="26"
v-model="activationCode"
label="激活码"
placeholder="请输入激活码"
/> -->
<!-- <span>激活码</span>
<input type="text" maxlength="26" v-model="activationCode" placeholder="请输入激活码"> -->
</article>
<span class="error">{{errorMsg}}</span>
<img v-show="!!activationCode" @click="clear" src="../../images/cme/phrase2/close.png" />
</section>
<article class="bottom">
<van-button @click="confirm" size="large" round color="#449284">确认激活</van-button>
</article>
</section>
</van-popup>
</template>
<script>
export default {
props: {
isShow: {
type: Boolean,
default: true
},
changeErrorMsg: {
type: String,
default: ''
}
},
data() {
return {
activationCode: '',
errorMsg: ''
};
},
//
watch: {
activationCode(val) {
if(!val) {
this.errorMsg = '请输入激活码';
} else {
this.errorMsg = '';
}
this.$nextTick(() => {
this.activationCode = val.replace(/\s/g,'').replace(/.....(?!$)/g,'$& ');
});
},
changeErrorMsg(val) {
if(val) {
this.errorMsg = val;
}
},
isShow(val) {
this.activationCode = '';
this.errorMsg = '';
}
},
methods: {
cancle() {
this.$emit("cancle");
},
confirm() {
if(!this.activationCode) {
this.errorMsg = '请输入激活码';
return;
};
if(this.activationCode.length != 23) {
this.errorMsg = '请输入正确的激活码';
return;
}
let aCode = JSON.parse(JSON.stringify(this.activationCode));
aCode = aCode.replace(/\s/g,'');
this.$emit("confirm", aCode);
},
clear() {
this.activationCode = ''
}
}
};
</script>
<style lang="scss" scoped>
@import "../../style/mixin";
.bind-cart-wrapper {
width: 100%;
display: flex;
line-height: 1;
padding: px2rem(10px) px2rem(15px);
display: flex;
flex-direction: column;
background: rgba(255, 255, 255, 1);
// box-shadow: 0px -2px 10px 0px rgba(0, 0, 0, 0.1);
.title {
display: flex;
flex-direction: row;
font-size: 18px;
font-weight: 700;
align-items: center;
justify-content: center;
width: 100%;
margin-top: px2rem(20px);
img {
position: relative;
top: 0;
right: px2rem(-120px);
width: px2rem(12px);
height: px2rem(12px);
}
}
.tip {
display: flex;
margin-top: px2rem(40px);
.left {
display: flex;
line-height: 1.2;
font-size: px2rem(12px);
img {
position: relative;
top: px2rem(1px);
width: px2rem(12px);
height: px2rem(12px);
// margin: px2rem(2px) px2rem(4px) 0 px2rem(1px);
}
span {
margin-left: px2rem(4px);
}
color: #979899;
}
}
.input-wrapper {
position: relative;
.code {
display: flex;
flex-direction: column;
padding: px2rem(20px) 0;
padding-top: 0;
}
.error {
position: absolute;
top: px2rem(66px);
left: px2rem(56px);
display: inline-block;
color: red;
font-size: px2rem(12px);
}
img {
position: absolute;
top: px2rem(33px);
right: px2rem(12px);
width: px2rem(15px);
height: px2rem(15px);
}
}
.bottom {
display: flex;
margin-bottom: px2rem(40px);
}
}
</style>
\ No newline at end of file
<template>
<div class="step-content">
<p class="step-text step1-text" v-if="step1">学习进度{{studyProgress}}</p>
<div class="step-item">
<span :class="{'actived': step1 || step2 || step3 || step4}">1</span>
<p :class="{'actived': step1 || step2 || step3 || step4}">项目学习</p>
</div>
<div class="step-line step-one-line" :class="{'actived': step2 || step3 || step4}"></div>
<p class="step-text step2-text" v-if="step2" @click="applyFor">
立即申请
<img src="../../images/cme/step-right-arrow.png"/>
</p>
<div class="step-item">
<span :class="{'actived': step2 || step3 || step4}">2</span>
<p :class="{'actived': step2 || step3 || step4}">申请学分</p>
</div>
<div class="step-line step-two-line" :class="{'actived': step3 || step4}"></div>
<p class="step-text step3-text" v-if="step3" @click="verifyResult">
{{progressText}}
<img src="../../images/cme/step-right-arrow.png"/>
</p>
<div class="step-item">
<span :class="{'actived': step3 || step4}">3</span>
<p :class="{'actived': step3 || step4}">学分审核</p>
</div>
<div class="step-line step-three-line" :class="{'actived': step4}"></div>
<p class="step-text step4-text" v-if="step4" @click="getScore">
获得{{credit}}
<img src="../../images/cme/step-right-arrow.png"/>
</p>
<div class="step-item">
<span :class="{'actived': step4}">4</span>
<p :class="{'actived': step4}">申请成功</p>
</div>
<!-- 申请学分提示框 -->
<div class="apply-score-content" v-if="showTip">
<div class="lm">
<img src="../../images/cme/hand.png" />
</div>
<div class="title">恭喜您完成该项目学习及考试,快去申请学分</div>
<div class="line"></div>
<div class="rm" @click="closeTip">
<img src="../../images/cme/delete.png" />
</div>
</div>
</div>
</template>
<script>
import { getWebPageUrl, gotoPage } from "@/utils/index";
export default {
props: {
currentProgress: {
type: Number,
default: 0
},
studyProgress: {
type: String,
default: "0%"
},
credit: {
type: String,
default: ""
},
creditId: {
type: Number,
default: 0
},
certificateUrl: {
type: String,
default: ""
},
certificateId: {
type: String,
default: ""
},
projectId: {
type: String | Number,
default: "1"
},
inScope: {
type: Number,
default: 0
}
},
data() {
return {
step1: false,
step2: false,
step3: false,
step4: false,
progressText: "",
showTip: false,
btnDisabled: true
};
},
watch: {
currentProgress(n,o) {
let _this = this;
if(n == 1) { // 项目学习
_this.step1 = true;
_this.step2 = false;
_this.step3 = false;
_this.step4 = false;
}else if(n == 2) { // 申请学分
_this.step1 = false;
_this.step2 = true;
_this.step3 = false;
_this.step4 = false;
_this.showTip = true;
setInterval(() => {
_this.showTip = false;
},5000)
}else if(n == 3) { // 学分审核
_this.step1 = false;
_this.step2 = false;
_this.step3 = true;
_this.step4 = false;
_this.progressText = "审核中";
}else if(n == 4) { // 审核失败
_this.step1 = false;
_this.step2 = false;
_this.step3 = true;
_this.step4 = false;
_this.progressText = "审核失败";
}else if(n == 5 || n == 6) { // 申请成功
_this.step1 = false;
_this.step2 = false;
_this.step3 = false;
_this.step4 = true;
}
}
},
created() {},
methods: {
// 立即申请
applyFor() {
this.$sendBuriedData({
component_tag: `211#211001#${this.projectId}`
});
this.$emit("applicationCredit");
},
// 关闭提示
closeTip() {
this.showTip = false;
},
// 审核
verifyResult() {
if(this.currentProgress == 3) {
this.$sendBuriedData({
component_tag: `211#211003#${this.projectId}`
});
}else if(this.currentProgress == 4) {
this.$sendBuriedData({
component_tag: `211#211005#${this.projectId}`
});
}
gotoPage(this,`cme/#/credit-detail?creditId=${this.creditId}&projectId=${this.projectId}`);
},
// 获得学分--下载证书
getScore() {
let paramList = [
{
key: "className",
value:
"com.picahealth.yunque.activitys.honor.CheckCertificatesActivity###YQWebView",
type: 4,
seqNo: 1
},
{
key: "url",
value: this.certificateUrl,
type: 4,
seqNo: 2
},
{
key: "id",
value: this.certificateId,
type: 4,
seqNo: 3
},
{
key: "navTitle",
value: "学分详情",
type: 4,
seqNo: 4
},
{
key: "isNotTab",
value: true,
type: 4,
seqNo: 5
},
{
key: "isShowDownload",
value: true,
type: 4,
seqNo: 6
}
];
rocNative.dispatchEventByModuleCode({
modeCode: "M200",
jsonString: paramList
});
this.$sendBuriedData({
component_tag: `211#211004#${this.projectId}`
});
}
}
};
</script>
<style lang="scss" scoped>
@import "../../style/mixin";
.step-content {
position: relative;
height: px2rem(110px);
background: rgba(248, 249, 250, 1);
display: flex;
flex-direction: row;
justify-content: flex-start;
align-items: center;
.step-item {
flex-grow: 1;
text-align: center;
padding-top: px2rem(20px);
line-height: px2rem(20px);
span {
display: inline-block;
width: px2rem(20px);
height: px2rem(20px);
line-height: px2rem(17px);
border-radius: 50%;
background: #676869;
border: 2px solid rgba(255, 255, 255, 1);
color: #fff;
font-size: px2rem(12px);
font-weight: 700;
}
span.actived {
background: #449284;
}
p {
font-size: px2rem(13px);
color: #373839;
}
p.actived {
color: #449284;
}
}
.step-line {
position: absolute;
top: px2rem(58px);
width: px2rem(75px);
height: px2rem(3px);
background: #dadde1;
}
.step-one-line {
left: px2rem(56px);
}
.step-two-line {
left: px2rem(150px);
}
.step-three-line {
right: px2rem(56px);
}
.step-one-line.actived,
.step-two-line.actived,
.step-three-line.actived {
background: #449284;
}
.step-text {
position: absolute;
top: px2rem(25px);
padding: px2rem(4px) px2rem(6px);
background: #449284;
border-radius: px2rem(10px);
font-size: px2rem(12px);
line-height: px2rem(12px);
color: #fff;
img {
display: inline-block;
width: px2rem(6px);
height: px2rem(9px);
padding-left: px2rem(4px);
}
}
.step1-text {
left: px2rem(20px);
}
.step1-text:after {
content: "";
width: px2rem(0px);
height: px2rem(0px);
border-top: px2rem(7px) solid #449284;
border-left: px2rem(7px) solid transparent;
border-right: px2rem(7px) solid transparent;
position: absolute;
top: px2rem(18px);
left: px2rem(21px);
}
.step2-text {
left: px2rem(106px);
}
.step2-text:after,
.step3-text:after {
content: "";
width: px2rem(0px);
height: px2rem(0px);
border-top: px2rem(7px) solid #449284;
border-left: px2rem(7px) solid transparent;
border-right: px2rem(7px) solid transparent;
position: absolute;
top: px2rem(18px);
left: px2rem(29px);
}
.step3-text {
left: px2rem(207px);
}
.step3-text:after {
content: "";
width: px2rem(0px);
height: px2rem(0px);
border-top: px2rem(7px) solid #449284;
border-left: px2rem(7px) solid transparent;
border-right: px2rem(7px) solid transparent;
position: absolute;
top: px2rem(18px);
left: px2rem(21px);
}
.step4-text {
right: px2rem(20px);
}
.step4-text:after {
content: "";
width: px2rem(0px);
height: px2rem(0px);
border-top: px2rem(7px) solid #449284;
border-left: px2rem(7px) solid transparent;
border-right: px2rem(7px) solid transparent;
position: absolute;
top: px2rem(18px);
right: px2rem(20px);
}
.apply-score-content {
display: flex;
position: absolute;
left: px2rem(105px);
top: px2rem(-42px);
background: #000;
opacity: 0.6;
width: px2rem(236px);
height: px2rem(51px);
border-radius: px2rem(6px);
.title {
font-size: px2rem(12px);
color: rgba(255, 255, 255, 1);
margin: px2rem(7px) px2rem(11px) 0 px2rem(0px);
width: px2rem(133px);
}
.lm {
width: px2rem(41px);
img {
display: inline-block;
width: px2rem(20px);
padding: 0 0 px2rem(7px) px2rem(15px);
}
}
.line {
width: px2rem(1px);
height: px2rem(51px);
background: #fff;
opacity: 0.18;
}
.rm {
width: px2rem(41px);
img {
display: inline-block;
width: px2rem(15px);
padding: 0 px2rem(15px) px2rem(7px);
}
}
}
}
</style>
\ No newline at end of file
......@@ -9,15 +9,15 @@ import '@/utils/yqy-bridge' // 移动端服务
// import FastClick from 'fastclick'
import vueFilters from '@/utils/filter'
import VConsole from 'vconsole/dist/vconsole.min.js'
import BuriedPoint,{ sendBuriedData} from 'web-buried-point';
import BuriedPoint, { sendBuriedData } from 'web-buried-point';
import Vant from 'vant';
import 'vant/lib/index.css';
import clipboard from 'clipboard';
//注册到vue原型上
Vue.prototype.clipboard = clipboard;
if(!(process.env.BUILD_ENV === 'uat' || process.env.BUILD_ENV === 'pro')) {
// if(!(process.env.BUILD_ENV === 'pro')) {
if (!(process.env.BUILD_ENV === 'uat' || process.env.BUILD_ENV === 'pro')) {
// if(!(process.env.BUILD_ENV === 'pro')) {
let vConsole = new VConsole() // 初始化
}
......@@ -25,9 +25,8 @@ if(!(process.env.BUILD_ENV === 'uat' || process.env.BUILD_ENV === 'pro')) {
// Vue.config.devtools = true;
// 注册所有公用过滤器
for(let key in vueFilters) {
for (let key in vueFilters) {
Vue.filter(key, vueFilters[key])
}
......@@ -42,14 +41,14 @@ const router = new VueRouter({
routes,
mode: 'hash',
strict: process.env.NODE_ENV !== 'production',
scrollBehavior (to, from, savedPosition) {
if (savedPosition) {
return savedPosition
scrollBehavior(to, from, savedPosition) {
if (savedPosition) {
return savedPosition
} else {
if (from.meta.keepAlive) {
from.meta.savedPosition = document.body.scrollTop;
}
return { x: 0, y: to.meta.savedPosition || 0 }
return { x: 0, y: to.meta.savedPosition || 0 }
}
}
})
......@@ -63,20 +62,20 @@ Vue.mixin({
// import { buriedURL } from './apiConfig';
let domain = '';
if (process.env.BUILD_ENV === 'pro') {
domain = 'https://sc.yunqueyi.com';
domain = 'https://sc.yunqueyi.com';
} else if (process.env.BUILD_ENV === 'test') {
domain = 'https://test1-sc.yunqueyi.com';
domain = 'https://test1-sc.yunqueyi.com';
} else if (process.env.BUILD_ENV === 'uat') {
domain = 'https://uat-sc.yunqueyi.com';
domain = 'https://uat-sc.yunqueyi.com';
} else if (process.env.BUILD_ENV === 'dev') {
domain = 'https://dev-sc.yunqueyi.com';
domain = 'https://dev-sc.yunqueyi.com';
} else {
domain = 'https://dev-sc.yunqueyi.com';
domain = 'https://dev-sc.yunqueyi.com';
}
Vue.use(BuriedPoint, {
class_name: 'web_app_cme',
url: `${domain}/file/log/trace1`
class_name: 'web_app_professional_exam',
url: `${domain}/file/log/trace1`
});
Vue.prototype.$sendBuriedData = sendBuriedData;
......
import App from '../App'
const index = r => require.ensure([], () => r(require('../views/index')), 'index')
const complist = r => require.ensure([], () => r(require('../views/component-details')), 'complist')
const parent = r => require.ensure([], () => r(require('../views/parent-page')), 'parent')
const merge = r => require.ensure([], () => r(require('../views/merge-detail')), 'merge')
const test = r => require.ensure([], () => r(require('../views/test-components')), 'test-components')
export default [{
path: '/',
component: App,
children: [
{
path: '',
redirect: '/index'
},
{
path: '/index',
component: index
},
{
path: '/home',
component: index
},
{
path: '/comp2',
component: complist
},
{
path: '/parent',
component: parent
},
{
path: '/coop',
component: merge
},
{
path: '/test',
component: test
},
]
}]
import App from '../App'
const index = r => require.ensure([], () => r(require('../views/index')), 'index')
const complist = r => require.ensure([], () => r(require('../views/component-details')), 'complist')
const cooplist = r => require.ensure([], () => r(require('../views/cooperation-details')), 'cooplist')
const parent = r => require.ensure([], () => r(require('../views/parent-page')), 'parent')
const merge = r => require.ensure([], () => r(require('../views/merge-detail')), 'merge')
const test = r => require.ensure([], () => r(require('../views/test-components')), 'test-components')
const creditedit = r => require.ensure([], () => r(require('../views/credit-edit')), 'credit-edit')
const creditdetail = r => require.ensure([], () => r(require('../views/credit-detail')), 'credit-detail')
const excgtips = r => require.ensure([], () => r(require('../views/exchange-tips')), 'exchange-tips')
const icreditdetail = r => require.ensure([], () => r(require('../views/I-credit-detail')), 'I-credit-detail')
export default [{
path: '/',
......@@ -27,18 +20,6 @@ export default [{
path: '/home',
component: index
},
// {
// path: '/coop',
// component: cooplist
// },
{
path: '/comp2',
component: complist
},
{
path: '/parent',
component: parent
},
{
path: '/coop',
component: merge
......@@ -47,23 +28,5 @@ export default [{
path: '/test',
component: test
},
{
path: '/credit-edit',
component: creditedit
},
{
path: '/credit-detail',
component: creditdetail
},
{
path: '/excg-tips',
component: excgtips
},
{
path: '/icredit-detail',
component: icreditdetail
},
]
}]
<template>
<section class="cd-wrapper">
<CommonNavbar
:bgColor="bgColor"
v-show="showNavBar"
title
:isFixNavbar="isFixNavbar"
borderStyle="0px solid #fff"
></CommonNavbar>
<img class="img" src="https://file.yunqueyi.com/h5/images/tinified/I-detail-1.png" />
<img class="img" src="https://file.yunqueyi.com/h5/images/tinified/I-detail-2.png" />
<img class="img" src="https://file.yunqueyi.com/h5/images/tinified/I-detail-3.png" />
<img class="img" src="https://file.yunqueyi.com/h5/images/tinified/I-detail-4.png" />
<img class="img" src="https://file.yunqueyi.com/h5/images/tinified/I-detail-5.png" />
<img class="img" src="https://file.yunqueyi.com/h5/images/tinified/I-detail-6.png" />
<!-- <img class="img" src="https://file.yunqueyi.com/h5/images/tinified/I-detail-7.png" /> -->
<ExjumperButton @btnClick="isBuy(1)" btnText="立即学习" type="primary"></ExjumperButton>
<!-- <img @click="isBuy(1)" class="img" src="https://file.yunqueyi.com/h5/images/tinified/i-detail-8.png"> -->
<CardPopup
:cardInfo="cardInfo"
:isShow="isShowPopup"
@clickOverlay="clickOverlay"
@cancle="jumpToCardList"
@confirm="confirm"
></CardPopup>
<Loading v-if="showLoading" />
</section>
</template>
<script>
import ExjumperButton from "@/components/cme/exjumper-button";
import CommonNavbar from "@/components/common/common-navbar";
import CardPopup from "@/components/cme/card-popup";
import Loading from "@/components/common/common-loading";
import { Toast } from "vant";
export default {
data() {
return {
bgColor: "#fff",
bgColor: "none",
showNavBar: true,
isShowPopup: false,
isFixNavbar: true,
oneLevelUrl: "",
provinceId: 0,
organizationId: 0,
cardInfo: {
id: 0
},
cmeToken: "",
showLoading: false
};
},
components: {
CommonNavbar,
CardPopup,
ExjumperButton,
Loading
},
created() {
let _this = this;
window.__getPositionData = function(param) {
console.log(param);
// _this.showLoading = false;
param.setEntry = true;
_this.getProvinceIdByPosition(param);
};
this.oneLevelUrl = decodeURIComponent(
(this.$route.query && this.$route.query.oneLevelUrl) || ""
);
this.provinceId = (this.$route.query && this.$route.query.provinceId) || 0;
this.organizationId =
(this.$route.query && this.$route.query.organizationId) || 0;
this.cmeToken = (this.$route.query && this.$route.query.cmeToken) || "";
// this.getProvinceIdByPosition();
},
methods: {
// 点击弹层
clickOverlay() {
console.log("clickOverlay");
this.isShowPopup = false;
},
// 判断用户是否购买过I类学习卡
isBuy(cardType) {
this.$sendBuriedData({
component_tag: `881#8811`
});
this.showLoading = true;
let param = {
cardType: cardType,
token: this.cmeToken,
setEntry: true
};
this.GET("trade/storage/card/isBuy", param).then(res => {
if (res.code == "000000") {
// 如果购买过,则直接跳转到中华医学会页面
if (res.data) {
this.jumpToCardList();
} else {
this.preJumper();
}
}
// else {
// Toast(res.message);
// }
});
},
// 跳转前判断是否有机构,否则使用定位信息
preJumper() {
if (this.organizationId != 0 && this.provinceId != 0) {
this.getCardInfoByProvinceId(this.provinceId);
} else {
this.getPositionData();
}
},
// 获取地理位置信息
getPositionData() {
console.log("getPositionData");
rocNative.getPositionData({
__funcName: "__getPositionData"
});
},
// 根据省ID,获取学习卡信息
getCardInfoByProvinceId(provinceId) {
let param = {
area: provinceId + "",
cardType: 1,
pageNum: 1,
pageSize: 1
};
this.POST("trade/goods/cardList", param).then(res => {
if (res.code == "000000") {
this.showLoading = false;
this.isShowPopup = true;
this.cardInfo = (res.data && res.data[0]) || { id: 0 };
}
});
},
// 根据位置信息获取省ID
getProvinceIdByPosition(param) {
param.setEntry = true;
this.POST("aggregate/cme/convertLocationToProvinceId", param).then(
res => {
if (res.code == "000000") {
this.getCardInfoByProvinceId(res.data || 0);
} else {
this.getCardInfoByProvinceId(0);
}
}
);
},
// 跳转到原生的购买页面
confirm() {
this.isShowPopup = false;
let paramList = [
{
key: "className",
value:
"com.picahealth.yunque.activitys.studycard.StudyCardDetailActivity###PicaDo.LearningCardVC",
type: 4,
seqNo: 1
},
{
key: "goodId",
value: this.cardInfo.id,
type: 4,
seqNo: 1
},
{
key: "courseUrl",
value: encodeURIComponent(this.oneLevelUrl),
type: 4,
seqNo: 1
}
];
rocNative.dispatchEventByModuleCode({
modeCode: "M200",
jsonString: paramList
});
},
// 跳转I类学习详情页面(中华医学会项目列表页面)
jumpToCardList() {
this.showLoading = false;
this.isShowPopup = false;
if (window.__isWeb) {
return;
} else {
let pageUrl = this.oneLevelUrl;
let paramList = [
{
key: "pageUrl",
value: pageUrl,
type: 4,
seqNo: 1
},
// 此字段不配置,则用原来的逻辑
{
key: "needCache",
value: "1", // 0不缓存,其它值都做缓存
type: 4,
seqNo: 1
}
];
rocNative.dispatchEventByModuleCode({
modeCode: "M300",
jsonString: paramList
});
}
}
}
};
</script>
<style lang="scss" scoped>
@import "../style/mixin";
.cd-wrapper {
background: #f8f9fa;
padding-bottom: 80px;
.img {
margin-top: -15px;
width: 100%;
}
}
</style>
<template>
<div class="page-container">
<CommonNavbar
:bgColor="bgColor"
v-show="isShowNavbar"
:title="navTitle"
:isFixNavbar="isFixNavbar"
:burialPoint="pointStyle"
></CommonNavbar>
<div class="page-content">
<img
class="banner-img"
src="https://files.yunqueyi.com/image/jpeg/common/20190214153449966.jpg"
>
<CommonBannerVideo></CommonBannerVideo>
<CommonDescription :descTitle="descTitle" :value="description"></CommonDescription>
<CommonSpliteLine></CommonSpliteLine>
<CommonTitle :title="compTitle"></CommonTitle>
<TempListItem class="flex fs10"></TempListItem>
<CertShow class="flex fs10"></CertShow>
</div>
</div>
</template>
<script>
import CommonNavbar from "@/components/common/common-navbar";
import CommonDescription from "@/components/common/common-description";
import CommonSpliteLine from "@/components/common/common-splite-line";
import CommonTitle from "@/components/common/common-title";
import TempListItem from "@/components/business/temp-list-item";
import CertShow from "@/components/business/cert-show";
import CommonBannerVideo from "@/components/common/common-banner-video";
export default {
data() {
return {
bgColor: "none",
navTitle: "activity",
compTitle: "组件名称",
isShowNavbar: true,
isFixNavbar: true,
pointStyle: "activity",
descTitle: "规定从何处开始选取。如果是负数",
description:
"必需。规定从何处开始选取。如果是负数,那么它规定从数组尾部开始算起的位置那么它规定从数组尾部开始算起的位置那么它规定从数组尾部开始算起的位置那么它规定从数组尾部开始算起的位置。也就是说那么它规定从数组尾部开始算起的位置。也就是说那么它规定从数组尾部开始算起的位置。也就是说那么它规定从数组尾部开始算起的位置。也就是说那么它规定从数组尾部开始算起的位置。" +
" 也就是说那么它规定从数组尾部开始算起的位置。也就是说,必需。规定从何处开始选取。如果是负数,那么它规定从数组尾部开始算起的位置。也就是说,必需。规定从何处开始选取。如果是负数,那么它规定从数组尾部开始算起的位置。也就是说,必需。规定从何处开始选取。如果是负数,那么它规定从数组尾部开始算起的位置。也就是说,必需。规定从何处开始选取。如果是负数,那么它规定从数组尾部开始算起的位置。也就是说,必需。规定从何处开始选取。如果是负数,那么它规定从数组尾部开始算起的位置。也就是说,-1 指最后一个元素,-2 指倒数第二个元素,以此类推第二个元素。"
};
},
components: {
CommonNavbar,
CommonDescription,
CommonSpliteLine,
CommonTitle,
TempListItem,
CertShow,
CommonBannerVideo
},
mounted() {},
beforeDestroyed() {},
methods: {}
};
</script>
<style lang="scss" scoped>
@import "../style/mixin";
.banner-img {
display: inherit;
width: px2rem(375px);
height: px2rem(243px);
}
</style>
<template>
<!-- 组件详情页面:模块列表及其下面的元件列表 -->
<div class="page-container-comp">
<CommonNavbar
:bgColor="bgColor"
v-show="isShowNavbar"
:isBlack="isBlack"
:title="navTitle"
:isFixNavbar="isFixNavbar"
:burialPoint="pointStyle"
borderStyle="0px solid #fff"
:backMethod="from"
></CommonNavbar>
<div class="page-content list-container">
<!-- <img
v-if="bannerType == 1"
class="banner-img"
src="https://files.yunqueyi.com/image/jpeg/common/20190214153449966.jpg"
>-->
<!-- <div v-if="bannerType == 1" class="page-content-img-container"> -->
<div v-if="bannerType == 1" class="page-content-img-container">
<img class="banner-img" :src="attachmentUrl">
<img v-show="pStatus == 1" class="banner-img-1" src="../images/status-join.png">
<img v-show="pStatus == 5" class="banner-img-5" src="../images/status-keep-on.png">
<img v-show="pStatus == 10" class="banner-img-10" src="../images/status-end.png">
</div>
<!-- <CommonBannerVideo v-if="bannerType == 1" :videoOptions="videoOptions"></CommonBannerVideo> -->
<CommonTcPlayer v-if="bannerType == 2" style="flex" :options="videoOptions"></CommonTcPlayer>
<CommonDescription :descTitle="projectName" :value="projectIntro"></CommonDescription>
<CommonSpliteLine></CommonSpliteLine>
<CellListItem :paramData="contentList" :moduleName="moduleName" :courseRequire="courseRequire"></CellListItem>
<!-- <CellListDetail :paramData="contentList" :moduleName="moduleName"></CellListDetail> -->
</div>
<Loading v-show="showLoading"/>
</div>
</template>
<script>
import CommonNavbar from "@/components/common/common-navbar";
import CommonDescription from "@/components/common/common-description";
import CommonSpliteLine from "@/components/common/common-splite-line";
import CommonTitle from "@/components/common/common-title";
import CellListItem from "@/components/business/cell-list-item";
import CellListDetail from "@/components/business/cell-list-detail";
import CommonBannerVideo from "@/components/common/common-banner-video";
import CommonTcPlayer from "@/components/common/common-tcplayer";
import Loading from "@/components/common/common-loading";
import { mapGetters, mapActions } from "vuex";
import vueFilters from '@/utils/filter'
export default {
data() {
return {
from: "inner",
isBlack: false,
showLoading: false,
projectId: 1,
courseRequire: 0,
componentId: 1,
moduleId: 1,
contentList: [],
moduleName: "",
bannerType: 1,
videoOptions: {
mp4: "",
// mp4: "https://pica-pro.oss-cn-shanghai.aliyuncs.com/2019/03/05/movie.mp4",
// "mp4": "http://1258717429.vod2.myqcloud.com/24a74910vodcq1258717429/7c37c18f5285890786204547811/9BFIyaoXYAcA.mp4",
// "m3u8": "http://2157.liveplay.myqcloud.com/2157_358535a.m3u8",
// "flv": "http://2157.liveplay.myqcloud.com/live/2157_358535a.flv", //增加了一个flv的播放地址,用于PC平台的播放 请替换成实际可用的播放地址
autoplay: false, //iOS下safari浏览器,以及大部分移动端浏览器是不开放视频自动播放这个能力的
coverpic: require("../images/video-cover.png"),
width: "415", //视频的显示宽度,请尽量使用视频分辨率宽度
height: "210" //视频的显示高度,请尽量使用视频分辨率高度
},
// projectStatus: 1, //1没有获得证书 2是获得全部证书
pStatus: 0, // 项目状态 1是参加中 5是进行中 10是已结束
projectIntro: "",
projectName: "",
attachmentUrl: require("../images/banner-default.png"),
bgColor: "none",
navTitle: "",
compTitle: "组件名称",
isShowNavbar: true,
isFixNavbar: true,
pointStyle: "activity",
descTitle: "规定从何处开始选取。如果是负数",
description:
"必需。规定从何处开始选取。如果是负数,那么它规定从数组尾部开始算起的位置那么它规定从数组尾部开始算起的位置那么它规定从数组尾部开始算起的位置那么它规定从数组尾部开始算起的位置。也就是说那么它规定从数组尾部开始算起的位置。也就是说那么它规定从数组尾部开始算起的位置。也就是说那么它规定从数组尾部开始算起的位置。也就是说那么它规定从数组尾部开始算起的位置。" +
" 也就是说那么它规定从数组尾部开始算起的位置。也就是说,必需。规定从何处开始选取。如果是负数,那么它规定从数组尾部开始算起的位置。也就是说,必需。规定从何处开始选取。如果是负数,那么它规定从数组尾部开始算起的位置。也就是说,必需。规定从何处开始选取。如果是负数,那么它规定从数组尾部开始算起的位置。也就是说,必需。规定从何处开始选取。如果是负数,那么它规定从数组尾部开始算起的位置。也就是说,必需。规定从何处开始选取。如果是负数,那么它规定从数组尾部开始算起的位置。也就是说,-1 指最后一个元素,-2 指倒数第二个元素,以此类推第二个元素。"
};
},
components: {
CommonNavbar,
CommonDescription,
CommonSpliteLine,
CommonTitle,
CellListItem,
CellListDetail,
CommonBannerVideo,
Loading,
CommonTcPlayer
},
computed: {
...mapGetters(["userInfo"])
},
created() {
let _this = this;
this.from = this.$route.query.from || this.from || "native";
this.projectId = this.$route.query.projectId;
this.componentId = this.$route.query.componentId;
this.moduleId = this.$route.query.moduleId;
this.moduleName = this.$route.query.moduleName;
this.courseRequire = this.$route.query.courseRequire;
window.__getUserInfo4Comp = function(param) {
_this.token = param.userToken;
_this.setUserInfo(param);
_this.getContentList(_this.moduleId);
_this.getComponentInfoById(_this.componentId);
};
// this.getCoopInfo(this.projectId);
window.__refresh = function() {
_this.getContentList(_this.moduleId);
};
_this.getUserInfo();
},
mounted() {
window.addEventListener("scroll", this.scrollFun);
},
beforeDestroyed() {
window.removeEventListener("scroll", this.scrollFun);
},
methods: {
...mapActions(["setUserInfo"]),
//获取用户信息
getUserInfo() {
rocNative.getUserInfo({
__funcName: "__getUserInfo4Comp"
});
if (window.__isWeb && process.env.BUILD_ENV == "development") {
console.log('projectId',this.projectId);
let param = {
userToken: 'ED9F3381362641858B2B1F90C92A8050',
};
__getUserInfo4Comp(param);
}
},
// 获取单个模块信息
getComponentInfoById(componentId) {
let _this = this;
let param = {
componentId: componentId,
token: _this.userInfo.userToken,
setEntry: true
};
this.GET("portal/portalApp/component", param).then(res => {
if (res.code == "000000") {
_this.attachmentUrl = res.data.imageUrl;
_this.projectIntro = res.data.introduce;
_this.projectName = res.data.name;
}
});
},
// 获取单个项目信息
getCoopInfo(projectId) {
let _this = this;
let param = {
portalProjectId: projectId,
token: _this.userInfo.userToken,
setEntry: true
};
this.GET("portal/portalApp/queryProjectParticulars", param).then(res => {
if (res.code == "000000") {
// 先设置视频URL再显示视频组件 ------------ BEGIN
if (res.data.attachmentType == 2) {
_this.videoOptions.mp4 = res.data.attachmentUrl;
} else {
_this.attachmentUrl = res.data.attachmentUrl;
}
_this.bannerType = res.data.attachmentType;
// 先设置视频URL再显示视频组件 ------------ END
_this.projectIntro = res.data.projectIntro;
_this.projectName = res.data.projectName;
_this.pStatus = res.data.status;
}
});
},
setContent(data) {
let list = data;
for(let i=0;i<list.length;i++) {
let len = vueFilters.strLength(list[i].name);
let certificate = list[i].certificateFlag;
if(len > 30 && certificate == 2) {
list[i].height = "2";
} else if (len > 30 && certificate != 2) {
list[i].height = 2;
} else if (len <= 30 && certificate == 2) {
list[i].height = "1";
} else if(len <= 30 && certificate != 2) {
list[i].height = 1;
}
}
console.log('contentList!',list);
return list;
},
// 获取内容列表
getContentList(moduleId) {
let _this = this;
let param = {
moduleId: _this.moduleId,
token: _this.userInfo.userToken,
setEntry: true,
projectId: _this.projectId,
};
_this.showLoading = true;
this.GET("portal/portalApp/contentList", param).then(res => {
_this.showLoading = false;
if (res.code == "000000") {
_this.contentList = _this.setContent(res.data.contentList);
}
});
},
scrollFun() {
let scrollTop =
document.body.scrollTop || document.documentElement.scrollTop;
if (scrollTop > 20) {
this.isBlack = true;
this.bgColor = "#fff";
} else {
this.isBlack = false;
this.bgColor = "none";
}
}
}
};
</script>
<style lang="scss" >
@import "../style/mixin";
.page-container-comp {
.nav-top .nav-title {
height: px2rem(0px);
padding: px2rem(18px);
}
.banner-img {
display: inherit;
width: px2rem(375px);
height: px2rem(210px);
&-1 {
position: absolute;
left: 0;
top: px2rem(180px);
width: px2rem(76px);
height: px2rem(30px);
}
&-5 {
position: absolute;
left: 0;
top: px2rem(180px);
width: px2rem(76px);
height: px2rem(30px);
}
&-10 {
position: absolute;
left: 0;
top: px2rem(180px);
width: px2rem(148px);
height: px2rem(30px);
}
}
.list-container {
margin-bottom: px2rem(40px);
}
}
</style>
<template>
<!-- 专项合作详情页面: 组件列表页面 -->
<div class="page-container">
<CommonNavbar
:bgColor="bgColor"
v-show="isShowNavbar"
:isBlack="isBlack"
:title="navTitle"
:isFixNavbar="isFixNavbar"
:burialPoint="pointStyle"
borderStyle="0px solid #fff"
:backMethod="from"
></CommonNavbar>
<div class="page-content">
<div v-if="bannerType == 1" class="page-content-img-container">
<img class="banner-img" :src="attachmentUrl">
<img v-show="pStatus == 1" class="banner-img-1" src="../images/status-join.png">
<img v-show="pStatus == 5" class="banner-img-5" src="../images/status-keep-on.png">
<img v-show="pStatus == 10" class="banner-img-10" src="../images/status-end.png">
</div>
<!-- <CommonBannerVideo v-if="bannerType == 2" :videoOptions="videoOptions"></CommonBannerVideo> -->
<CommonTcPlayer v-if="bannerType == 2" :pStatus="pStatus" :options="videoOptions"></CommonTcPlayer>
<CommonDescription :descTitle="projectName" :value="projectIntro"></CommonDescription>
<CommonSpliteLine></CommonSpliteLine>
<section v-if="coopType == 1" class="list-container">
<CertShow v-if="projectStatus == 2"/>
<CompListItem :paramData="projectComponentModels" :projectId="projectId" :courseRequire="courseRequire"></CompListItem>
<MaterialListItem v-if="meterList.length" :paramData="meterList" :projectId="projectId"></MaterialListItem>
<!-- <NoMoreContent/> -->
<PopCert
ref="popCert"
:popText="item.certificateName"
:certId="item.certificateId"
:certUrl="item.certificateImgUrl"
:needShow="true"
v-for="(item, index) in certList"
:key="index"
/>
</section>
<NoPermContent v-if="coopType == 2"></NoPermContent>
</div>
<Loading v-show="showLoading"/>
<!-- <img v-gallery="false" src="../images/has-owner-all-cert.png"> -->
</div>
</template>
<script>
import CommonNavbar from "@/components/common/common-navbar";
import CommonDescription from "@/components/common/common-description";
import CommonSpliteLine from "@/components/common/common-splite-line";
import CommonTitle from "@/components/common/common-title";
import CompListItem from "@/components/business/comp-list-item";
import MaterialListItem from "@/components/business/material-list-item";
import NoPermContent from "@/components/business/no-perm-content";
import CertShow from "@/components/business/cert-show";
import CommonBannerVideo from "@/components/common/common-banner-video";
import NoMoreContent from "@/components/business/no-more-content";
import PopCert from "@/components/business/pop-cert";
import Loading from "@/components/common/common-loading";
import CommonTcPlayer from "@/components/common/common-tcplayer";
import { mapGetters, mapActions } from "vuex";
export default {
data() {
return {
from: "inner",
isBlack: false,
showLoading: false,
needShowVideo: false,
videoOptions: {
mp4: "",
// mp4: "https://pica-pro.oss-cn-shanghai.aliyuncs.com/2019/03/05/movie.mp4",
// "mp4": this.cVideoUrl,
// "mp4": "http://1258717429.vod2.myqcloud.com/24a74910vodcq1258717429/7c37c18f5285890786204547811/9BFIyaoXYAcA.mp4",
// "m3u8": "http://2157.liveplay.myqcloud.com/2157_358535a.m3u8",
// "flv": "http://2157.liveplay.myqcloud.com/live/2157_358535a.flv", //增加了一个flv的播放地址,用于PC平台的播放 请替换成实际可用的播放地址
autoplay: false, //iOS下safari浏览器,以及大部分移动端浏览器是不开放视频自动播放这个能力的
coverpic: require("../images/video-cover.png"),
// x5_fullscreen: false,
fuScrnEnabled: false,
width: "375", //视频的显示宽度,请尽量使用视频分辨率宽度
height: "210" //视频的显示高度,请尽量使用视频分辨率高度,
},
bannerType: 1,
projectId: 1,
projectStatus: 1, //1没有获得证书 2是获得全部证书
pStatus: 0, // 项目状态 1是参加中 5是进行中 10是已结束
projectIntro: "",
projectName: "",
attachmentUrl: require("../images/banner-default.png"),
videoUrl:
"https://pica-pro.oss-cn-shanghai.aliyuncs.com/2019/03/05/movie.mp4",
projectComponentModels: [],
coopType: 1,
tabTo: 1,
courseRequire: 0,
// coopInfo: {},
certList: [],
meterList: [],
bgColor: "none",
navTitle: "",
compTitle: "组件名称",
isShowNavbar: true,
isFixNavbar: true,
pointStyle: "activity",
descTitle: "规定从何处开始选取。如果是负。如果是负。如果是负数",
description:
"必需。规定从何处开始选取。如果是负数,那么它规定从数组尾部开始算起的位置那么它规定从数组尾部开始算起的位置那么它规定从数组尾部开始算起的位置那么它规定从数组尾部开始算起的位置。也就是说那么它规定从数组尾部开始算起的位置。也就是说那么它规定从数组尾部开始算起的位置。也就是说那么它规定从数组尾部开始算起的位置。也就是说那么它规定从数组尾部开始算起的位置。" +
" 也就是说那么它规定从数组尾部开始算起的位置。也就是说,必需。规定从何处开始选取。如果是负数,那么它规定从数组尾部开始算起的位置。也就是说,必需。规定从何处开始选取。如果是负数,那么它规定从数组尾部开始算起的位置。也就是说,必需。规定从何处开始选取。如果是负数,那么它规定从数组尾部开始算起的位置。也就是说,必需。规定从何处开始选取。如果是负数,那么它规定从数组尾部开始算起的位置。也就是说,必需。规定从何处开始选取。如果是负数,那么它规定从数组尾部开始算起的位置。也就是说,-1 指最后一个元素,-2 指倒数第二个元素,以此类推第二个元素。"
};
},
computed: {
...mapGetters(["userInfo"])
},
components: {
CommonNavbar,
CommonDescription,
CommonSpliteLine,
CommonTitle,
CompListItem,
CertShow,
CommonBannerVideo,
NoPermContent,
NoMoreContent,
MaterialListItem,
PopCert,
Loading,
CommonTcPlayer
},
created() {
let _this = this;
this.from = this.$route.query.from || this.from || "native";
this.projectId = this.$route.query.id;
this.coopType = this.$route.query.coopType;
this.tabTo = this.$route.query.tabTo;
this.courseRequire = this.$route.query.courseRequire;
window.__getUserInfo4Coop = function(param) {
_this.token = param.userToken;
_this.setUserInfo(param);
_this.getCoopInfo(_this.projectId);
if (_this.coopType == 1) {
_this.getCertList(_this.projectId);
_this.getMeterList(_this.projectId);
}
}
window.__refresh = function() {
_this.getCoopInfo(_this.projectId);
if (_this.coopType == 1) {
_this.getCertList(_this.projectId);
_this.getMeterList(_this.projectId);
}
};
_this.getUserInfo()
},
mounted() {
// this.$refs.popCert.setTextTips("我想我是海");
// this.$refs.popCert.show();
window.addEventListener("scroll", this.scrollFun);
},
beforeDestroyed() {
window.removeEventListener("scroll", this.scrollFun);
},
methods: {
...mapActions(["setUserInfo"]),
//获取用户信息
getUserInfo() {
rocNative.getUserInfo({
__funcName: "__getUserInfo4Coop"
});
if (window.__isWeb && process.env.BUILD_ENV == "development") {
console.log('projectId',this.projectId);
let param = {
userToken: 'ED9F3381362641858B2B1F90C92A8050',
};
__getUserInfo4Coop(param);
}
},
// 获取单个项目信息
getCoopInfo(projectId) {
let _this = this;
let param = {
portalProjectId: projectId,
token: _this.userInfo.userToken || _this.token,
setEntry: true
};
_this.showLoading = true;
this.GET("portal/portalApp/queryProjectParticulars", param).then(res => {
_this.showLoading = false;
if (res.code == "000000") {
if(_this.tabTo == 2) {
_this.coopType = res.data.learnableFlag;
}
// 先设置视频URL再显示视频组件 ------------ BEGIN
if (res.data.attachmentType == 2) {
_this.videoOptions.mp4 = res.data.attachmentUrl;
// _this.videoOptions.mp4 = 'https://pica-pro.oss-cn-shanghai.aliyuncs.com/2019/03/05/movie.mp4'
} else {
_this.attachmentUrl = res.data.attachmentUrl;
}
_this.bannerType = res.data.attachmentType;
// 先设置视频URL再显示视频组件 ------------ END
// "projectStatus": 1////1没有获得证书 2是获得全部证书
_this.projectStatus = res.data.projectStatus;
_this.projectIntro = res.data.projectIntro;
_this.projectName = res.data.projectName;
_this.pStatus = res.data.status;
_this.projectComponentModels = res.data.projectComponentModels;
}
});
},
// 获取已经获取的所有证书
getCertList(projectId) {
let _this = this;
let param = {
portalProjectId: projectId,
token: _this.userInfo.userToken || _this.token,
setEntry: true
};
this.GET("portal/portalApp/queryCertificateInfo", param).then(res => {
if (res.code == "000000") {
_this.certList = res.data;
// _this.certList.forEach(item => {
// // console.log(4444, item.certificateName);
// _this.$refs.popCert.setTextTips(item.certificateName, item.certificateImgUrl, item.certificateId);
// // _this.$refs.popCert.show();
// });
console.log(res);
}
});
},
// 获取项目相关资料列表
getMeterList(projectId) {
let _this = this;
let param = {
portalProjectId: projectId,
token: _this.userInfo.userToken || _this.token,
pageNo: 1,
pageSize: 4,
setEntry: true
};
this.GET("portal/portalApp/queryProjectFiles", param).then(res => {
if (res.code == "000000") {
_this.meterList = res.data.portalFileListModels;
}
});
},
scrollFun() {
let scrollTop =
document.body.scrollTop || document.documentElement.scrollTop;
if (scrollTop > 20) {
this.isBlack = true;
this.bgColor = "#fff";
} else {
this.isBlack = false;
this.bgColor = "none";
}
}
}
};
</script>
<style lang="scss" scoped>
@import "../style/mixin";
.banner-img {
display: inherit;
width: px2rem(375px);
height: px2rem(210px);
&-1 {
position: absolute;
left: 0;
top: px2rem(180px);
width: px2rem(76px);
height: px2rem(30px);
}
&-5 {
position: absolute;
left: 0;
top: px2rem(180px);
width: px2rem(76px);
height: px2rem(30px);
}
&-10 {
position: absolute;
left: 0;
top: px2rem(180px);
width: px2rem(148px);
height: px2rem(30px);
}
}
.list-container {
margin-bottom: px2rem(40px);
}
</style>
<!-- 学分:个人信息编辑页面 -->
<template>
<section class="credit-detail-wrapper">
<CommonNavbar
:bgColor="bgColor"
v-show="isShowNavbar"
:isBlack="isBlack"
:title="navTitle"
:isFixNavbar="isFixNavbar"
:burialPoint="pointStyle"
borderStyle="0px solid #fff"
:backMethod="from"
></CommonNavbar>
<section class="info">
<div class="credit-basic">
<ul>
<li>
<span>项目名称</span>
<span>{{formData.projectName}}</span>
</li>
<li>
<span>学分等级</span>
<span>{{formData.grade}}</span>
</li>
<li>
<span>学分</span>
<span>{{formData.value}}</span>
</li>
<li>
<span>申请范围</span>
<span>{{formData.applyRange}}</span>
</li>
<li>
<span>状态</span>
<!-- <span :class="statusStyle">{{statusText}}</span> -->
<span :class="statusStyle">{{formData.statusDesc}}</span>
</li>
</ul>
<div v-show="needShowTips" class="tips">
<span class="triangle"></span>
{{formData.tips}}
<!-- 您提交的信息不准确,请重新提交或联系云鹊医官方客服 -->
</div>
</div>
<CommonSpliteLine v-if="needShowUserInfo"></CommonSpliteLine>
<div v-if="needShowUserInfo" class="credit-user">
<ul>
<li>
<span>申请人</span>
<span>{{formData.name}}</span>
</li>
<li>
<span>身份证号</span>
<span>{{formData.idCardNumber}}</span>
</li>
<li>
<span>继续医学教育IC卡号</span>
<span>{{formData.icCardNumber}}</span>
</li>
<li>
<span>申请时间</span>
<span>{{formData.applyTime | formatTime('{y}年{m}月{d}日 {h}:{i}:{s}')}}</span>
</li>
</ul>
</div>
</section>
<CommonButton v-if="needShowBtn" @btnClick="btnClick" :btnText="btnText"></CommonButton>
<CommonBottomInfo></CommonBottomInfo>
<CommonDialog
:isShowDialog="isShowDialog"
:isSingle="isSingle"
:cancleBtnText="cancleBtnText"
:confirmBtnText="confirmBtnText"
:content="dialogContent"
@handlerAction="handlerAction"
/>
</section>
</template>
<script>
import CommonNavbar from "@/components/common/common-navbar";
import CommonButton from "@/components/cme/common-button";
import CommonSpliteLine from "@/components/common/common-splite-line";
import CommonBottomInfo from "@/components/cme/common-bottom-info";
import CommonDialog from "@/components/cme/common-dialog";
import { gotoPage } from "@/utils/index";
export default {
components: {
CommonNavbar,
CommonButton,
CommonSpliteLine,
CommonBottomInfo,
CommonDialog
},
data() {
return {
isSingle: false,
dialogContent: "", // 弹框内容
confirmBtnText: "", // 弹框按钮
cancleBtnText: "",
isShowDialog: false,
from: "native",
isBlack: true,
bgColor: "#fff",
navTitle: "学分详情",
isShowNavbar: true,
isFixNavbar: false,
pointStyle: "activity",
// buttonStyleType: "primary",
// 我的进度状态 0: 未学习 1: 学习中 2:待申请 3:已申请审核中 4:审核失败 5:审核成功 6: 已获证
// 1: 学习中 continue 不显示用户信息 不显示提示信息
// 2: 学习已经完成 completed 不显示用户信息 不显示提示信息
// 3:审核中 continue 显示用户信息 预计2019年12月10日前有反馈结果
// 4: 审核失败 error 显示用户信息 您提交的信息不准确,请重新提交或联系云鹊医官方客服
// 5: 审核通过 continue 不显示用户信息 不显示提示信息
status: 1,
statusStyle: "continue",
statusText: "学习中",
// statusDescText: "",
needShowTips: false,
needShowUserInfo: false,
needShowBtn: false,
btnText: "去学习",
formData: {
applyAgain: 0,
applyRange: "",
applyTime: "",
creditId: 0,
grade: "",
icCardNumber: "",
idCardNumber: "",
name: "",
projectName: "",
status: 1,
statusDesc: "",
tips: "",
value: 0,
},
projectId: 1,
token: "9B62E5874DA94979A54DB3E9DFC1443F"
};
},
created() {
let _this = this;
window.__getUserInfoInCDetail = function(param) {
_this.token = param.userToken;
_this.getLatestApplyRecord();
};
window.__refresh = function() {
_this.getUserInfo();
};
// this.projectId =
// (this.$route && this.$route.query && this.$route.query.projectId) || this.projectId;
this.from =
(this.$route && this.$route.query && this.$route.query.from) || this.from;
this.creditId =
(this.$route && this.$route.query && this.$route.query.creditId) || 393;
this.token =
(this.$route && this.$route.query && this.$route.query.token) ||
this.token;
this.status =
(this.$route && this.$route.query && this.$route.query.status) || 1; // 测试用
if (__isWeb) {
this.getLatestApplyRecord();
} else {
this.getUserInfo();
}
},
methods: {
// 获取用户信息
getUserInfo() {
rocNative.getUserInfo({
__funcName: "__getUserInfoInCDetail"
});
},
// 根据状态显示不同的文本
statusChanged(status) {
this.needShowUserInfo = false;
this.needShowTips = false;
// this.statusDescText = '';
this.statusText = "学习中";
this.statusStyle = "continue";
this.needShowBtn = true;
this.btnText = "去学习";
if (status == 1) {
} else if (status == 2) {
this.statusText = "学习已经完成";
this.btnText = "申请学分";
this.statusStyle = "completed";
} else if (status == 3) {
this.needShowUserInfo = true;
this.needShowTips = true;
this.needShowBtn = false;
this.statusText = "审核中";
// this.statusDescText = '预计2019年12月10日前有反馈结果';
} else if (status == 4) {
this.needShowUserInfo = true;
this.needShowTips = true;
this.statusText = "审核失败";
this.statusStyle = "error";
// 如果applyAgain为0时,则不显示按钮
if(this.formData.applyAgain == 0) {
this.needShowBtn = false;
}
this.btnText = "重新提交";
// this.statusDescText = '您提交的信息不准确,请重新提交或联系云鹊医官方客服';
} else if (status == 5) {
this.needShowUserInfo = true;
this.needShowBtn = false;
this.statusText = "审核通过";
}
},
btnClick() {
if (this.formData.status == 1 || this.formData.status == 0) {
gotoPage(this, `cme/#/coop?id=${this.projectId}`);
// 判断是否加入机构
// 判断加入机构与学习范围是否一致
// this.permission();
// alert("去学习");
this.$sendBuriedData({
component_tag: `416#212005#${this.creditId}#`
});
} else if (this.formData.status == 2) {
// alert("调用申请学分的接口");
this.$sendBuriedData({
component_tag: `416#212004#${this.creditId}#`
});
this.applicationCredit();
} else if (this.formData.status == 4) {
// alert("调用重新提交的接口");
this.$sendBuriedData({
component_tag: `211#211006#${this.projectId}`
});
gotoPage(this, `cme/#/credit-edit?creditId=${this.creditId}`);
}
},
// 弹框按钮事件
handlerAction(data) {
// alert(data)
if(this.formData.status == 1) {
gotoPage(this, `cme/#/coop?id=${this.projectId}`);
} else if(this.formData.status == 2) {
if (window.__isWeb) {
this.$router.back(-1);
} else {
rocNative.goBack();
}
}
},
// 立即申请学分
applicationCredit() {
let _this = this;
let param = {
creditId: _this.creditId || 1,
token: _this.token,
setEntry: true
};
_this.POST("cme/credit/applyCheck", param).then(res => {
if (res.code == "000000") {
gotoPage(_this, `cme/#/credit-edit?creditId=${this.creditId}`);
} else if (res.code == "219004" || res.code == "219005") {
// 未加入机构 219004 未身份认证 219005 不在申请范围 219012
let params = {
__funcName: "__checkPermissions",
permCode: "009014"
};
rocNative.checkPermissions(params);
} else {
this.dialogContent = res.message;
// this.dialogContent = `您的所属机构不在可申请范围(${_this.formData.applyRange})内`;
this.cancleBtnText = "我知道了";
this.isShowDialog = true;
this.isSingle = true;
}
});
},
// 最后一次提交信息
getLatestApplyRecord() {
let param = {
token: this.token,
setEntry: true
};
this.POST("cme/credit/latestApplyRecord/" + this.creditId, param).then(
res => {
this.formData = res.data;
this.projectId = this.formData.projectId;
this.statusChanged(this.formData.status);
// this.statusChanged(5);
}
);
}
}
};
</script>
<style lang="scss" scoped>
@import "../style/mixin";
.credit-detail {
&-wrapper {
.tips {
position: relative;
top: 0;
left: 0;
margin: px2rem(10px) 0 px2rem(10px);
border-radius: px2rem(4px);
padding: px2rem(10px);
font-weight: 400;
font-size: px2rem(12px);
// height: px2rem(32px);
line-height: px2rem(12px);
color: #979899;
background: #f8f9fa;
.triangle {
position: absolute;
top: px2rem(-5px);
transform: rotateZ(45deg);
right: px2rem(10px);
width: px2rem(10px);
height: px2rem(10px);
background: #f8f9fa;
}
}
.info {
font-size: px2rem(14px);
font-weight: 400;
margin-bottom: px2rem(50px);
.credit-basic {
margin: px2rem(20px) px2rem(15px);
}
.credit-user {
margin: px2rem(20px) px2rem(15px);
}
ul {
li {
display: flex;
flex-direction: row;
justify-content: space-between;
height: px2rem(30px);
line-height: px2rem(30px);
span {
&:nth-child(1) {
color: #979899;
}
&:nth-child(2) {
color: #373839;
}
&.continue {
color: #449284;
}
&.error {
color: #fb5b52;
}
&.completed {
color: #373839;
}
}
}
}
}
}
}
</style>
<!-- 学分:个人信息编辑页面 -->
<template>
<section class="credit-edit-wrapper">
<CommonNavbar
:bgColor="bgColor"
v-show="isShowNavbar"
:isBlack="isBlack"
:title="navTitle"
:isFixNavbar="isFixNavbar"
:burialPoint="pointStyle"
borderStyle="0px solid #fff"
:backMethod="from"
></CommonNavbar>
<van-cell-group class="group">
<van-field label-width="150" disabled v-model="formData.name" label="姓名" placeholder="" />
<van-field label-width="150" v-model="formData.idCardNumber" label="身份证号" maxlength=18 placeholder="请填写您的真实身份证号" />
<van-field label-width="150" v-model="formData.icCardNumber" label="继续医学教育IC卡号" maxlength=9 placeholder="请填写您的IC卡号" />
</van-cell-group>
<div class="tips">
您的身份证号将用于生成项目学分证书对应的编号,请确保您所填写的身份证号的真实性
</div>
<CommonButton :type="buttonStyleType" @btnClick="applyCredit" btnText="提交"></CommonButton>
<CommonDialog content="提交成功" subContent="您可在“个人中心-证书与学分”中查看审核结果" cancleBtnText="我知道了" isSingle needSubContent :isShowDialog="isShowDialog" @handlerAction="handlerDialogAction"></CommonDialog>
</section>
</template>
<script>
import CommonNavbar from "@/components/common/common-navbar";
import CommonButton from "@/components/cme/common-button";
import CommonDialog from "@/components/cme/common-dialog";
export default {
components: {
CommonNavbar,
CommonButton,
CommonDialog
},
data() {
return {
formData: {
creditId: "",
id: "",
name: "",
idCardNumber: "",
icCardNumber: "",
},
// projectId: "",
token: "9B62E5874DA94979A54DB3E9DFC1443F",
buttonStyleType: 'disabled',
from: "native",
isBlack: true,
bgColor: "#fff",
navTitle: "申请学分",
isShowNavbar: true,
isFixNavbar: false,
pointStyle: "activity",
isShowDialog: false,
creditId: 0
};
},
watch: {
formData: {
handler(newVal) {
let idCardReg = /^[1-9]{1}[0-9]{14}$|^[1-9]{1}[0-9]{16}([0-9]|[xX])$/;
let icCardReg = /^[a-zA-Z0-9]{9}$/;
if(newVal.name && newVal.idCardNumber && newVal.icCardNumber
&& idCardReg.test(newVal.idCardNumber)
&& icCardReg.test(newVal.icCardNumber)) {
this.buttonStyleType = 'primary';
} else {
this.buttonStyleType = 'disabled';
}
},
deep: true
}
},
created() {
let _this = this;
window.__getUserInfoInCEdit = function(param) {
_this.token = param.userToken;
_this.getUserInfoByToken();
_this.getLatestApplyRecord();
};
window.__refresh = function() {
_this.getUserInfo();
};
// 前一页面传creditId
// this.projectId = this.$route && this.$route.query && this.$route.query.projectId || '';
this.from = this.$route && this.$route.query && this.$route.query.from || this.from;
this.creditId = this.$route && this.$route.query && this.$route.query.creditId || this.creditId;
// this.formData.id = this.projectId;
this.formData.creditId = this.creditId;
this.token = this.$route && this.$route.query && this.$route.query.token || this.token || ''
if (__isWeb) {
this.getUserInfoByToken();
this.getLatestApplyRecord();
} else {
this.getUserInfo()
}
},
methods: {
getUserInfo() {
rocNative.getUserInfo({
__funcName: "__getUserInfoInCEdit"
});
},
// 提交申请
applyCredit() {
let param = {
...this.formData,
token: this.token,
setEntry: true
};
this.POST("cme/credit/apply", param).then(res => {
if(res.code == '000000') {
this.isShowDialog = true
} else {
this.$toast({message: res.message});
}
})
},
// 最后一次提交信息:获取用户的idCardNumber
getLatestApplyRecord() {
let param = {
token: this.token,
setEntry: true
};
this.POST("cme/credit/latestApplyRecord/" + this.creditId, param).then(res => {
this.formData.icCardNumber = res.data.icCardNumber;
})
},
// 根据token获取用户信息
getUserInfoByToken() {
let param = {
token: this.token,
setEntry: true
};
this.GET("cme/credit/doctor/info", param).then(res => {
this.formData.name = res.data.name;
this.formData.idCardNumber = res.data.card;
// this.isShowDialog = true
})
},
// 显示提交成功的提示信息
handlerDialogAction(type) {
this.isShowDialog = false;
// 跳转到前一页面
if (window.__isWeb) {
this.$router.back(-1);
} else {
rocNative.goBack();
}
},
},
};
</script>
<style lang="scss">
@import "../style/mixin";
.credit-edit-wrapper {
.group {
margin: 10px 15px;
}
.tips {
margin: px2rem(10px) px2rem(15px) px2rem(50px);
font-weight: 400;
font-size: px2rem(14px);
line-height: px2rem(21px);
color: #979899;
}
.van-cell__title .van-field__label {
line-height: px2rem(30px) !important;
height: px2rem(20px) !important;
}
.van-cell {
padding: px2rem(20px) 0 !important;
font-size: px2rem(15px) !important;
color: #373839 !important;
}
.van-cell__title span {
font-weight: 400 !important;
}
.van-field__body {
line-height: px2rem(30px) !important;
height: px2rem(20px) !important;
}
.van-field__control {
padding-top: px2rem(8px) !important;
line-height: px2rem(20px) !important;
font-size: px2rem(15px);
}
}
</style>
\ No newline at end of file
<template>
<div>
<header class="header">
<span>兑换须知</span>
<!-- <img src="../images/cme/close.png" alt=""> -->
</header>
<div class="exchange-tips-wrapper fixed">
<div class="content">
<p class="title">一、云鹊医课程的版权归属何方?</p>
<p class="text">云鹊医平台所有的在线课程版权归云鹊医所有,任何以录屏或其它方式进行的盗版或盗版售卖行为均属侵权行为,一经发现,云鹊医将采取最严厉的措施进行打击并维权,包括但不限于:起诉侵权人、发函侵权人学校或单位、云鹊医全平台公示侵权人所有信息、在一定时间内或永久限制该侵权人购买、观看课程的权利。</p>
<p class="title">二、我应该如何兑换课程?</p>
<p class="text">点击课程页面上的“点击兑换”,即可通过云鹊豆兑换等值的课程。如果云鹊豆不足,可以通过云鹊豆中心的任务列表赚取。目前仅支持完整课程的兑换,暂不支持单独章节的兑换。在云鹊豆系统上线以前、用户已经加入学习的课程不受影响。</p>
<p class="title">三、兑换课程以后如何看课?</p>
<p class="text">打开云鹊医app,进入“个人中心”- “我的课程”,在“学习中”即可看到兑换成功的课程。课程兑换成功以后,用户可以永久收看该门课程。</p>
<p class="title">四、我兑换课程以后后悔了,可以退课吗?</p>
<p class="text">目前云鹊医平台不支持通过云鹊豆兑换的课程退货,即不支持退回云鹊豆的动作,所以请在兑换成功前自行确认是否要用云鹊豆兑换该课程。对于用户自主消费云鹊豆的行为产生的云鹊豆减少,云鹊医平台不作后续处理。</p>
<p class="title">五、其它提示:</p>
<p class="text">由于学员较多,如有问题请直接留言,客服会在24小时以内回复,请谅解。 如果事件过于紧急,请联系云鹊医客服电话:4009208877。</p>
</div>
</div>
</div>
</template>
<style lang="scss" scoped>
@import "../style/mixin";
.header {
width: 100%;
position: fixed;
top: 0;
left: 0;
text-align: center;
padding: px2rem(26px) 0 px2rem(20px);
font-size: px2rem(18px);
line-height: px2rem(18px);
color: #333333;
background: #fff;
// img {
// position: absolute;
// right: px2rem(20px);
// width: px2rem(13px);
// height: px2rem(13px);
// }
}
.exchange-tips-wrapper {
padding-top: px2rem(40px);
margin: px2rem(20px);
font-size: px2rem(16px);
.content {
.title {
line-height: px2rem(18px);
font-weight: 700;
color: #373839;
margin: px2rem(12px) 0;
}
.text {
color: #676869;
// text-align-last: justify;
text-align: justify;
}
}
}
</style>
\ No newline at end of file
<template>
<!-- 专项合作首页: 我参与的,其它项目 -->
<div class="page-container">
<CommonNavbar
:bgColor="bgColor"
v-show="isShowNavbar"
:title="navTitle"
:isFixNavbar="isFixNavbar"
:burialPoint="pointStyle"
borderStyle="1px solid #fff"
></CommonNavbar>
<section class="page-content">
<table class="page-content-table">
<tr>
<td @click="changeTab(1)" :class="{'active': tabIndex === 1}">
<div class="tap-title">
<span :style="{'color': tabIndex === 1 ? '#333' : '#999'}">我的项目</span>
<span :class="{'android': isAndroid, 'ios': isIOS}"></span>
</div>
</td>
<td @click="changeTab(2)" :class="{'active': tabIndex === 2}">
<div class="tap-title">
<span :style="{'color': tabIndex === 2 ? '#333' : '#999'}">全部项目</span>
<span :class="{'android': isAndroid, 'ios': isIOS}"></span>
</div>
</td>
</tr>
</table>
<!-- <article v-show="isShow" class="cb-wrapper" :class="{'padding-top-111': !isWeb}">
<CardBanner :userMobile="userMobile"></CardBanner>
</article> -->
<article class="page-content-list">
<CommonTitle title="国家级继续医学教育项目(远程)" :isShowCert="false"></CommonTitle>
<ICardItem :oneLevelUrl="oneLevelUrl" :provinceId="provinceId" :organizationId="organizationId" :cmeToken="token"></ICardItem>
<CommonTitle
class="mt-10"
v-show="isShow && ((tabIndex === 1 && joinProjectList.length) || (tabIndex === 2 && otherProjectList.length))"
:title="tabIndex === 1 ? '我的继续医学教育课程' : '继续医学教育课程'"
:isShowCert="false"
/>
<section v-if="tabIndex === 1">
<CoopListItem
:paramData="joinProjectList"
:coopType="1"
:tabTo="1"
:isShow="isShow"
:userMobile="userMobile"
:provinceId="provinceId"
:organizationId="organizationId"
></CoopListItem>
</section>
<section v-if="tabIndex === 2">
<CoopListItem
:paramData="otherProjectList"
:coopType="1"
:tabTo="2"
:isShow="isShow"
:userMobile="userMobile"
:provinceId="provinceId"
:organizationId="organizationId"
></CoopListItem>
</section>
</article>
</section>
<!-- <div>
<iframe src="https://www.baidu.com" id="mobsf" frameborder="0" style="width:100%;height:500px;"></iframe>
</div>-->
<!-- <discuss-topic-stencil /> -->
<transition name="fade">
<article v-show="needShowBackup" @click="scrollTop" class="back-up-icon">
<img src="../images/cme/phrase2/back-top.png" alt />
</article>
</transition>
<Loading v-if="showLoading" />
</div>
</template>
<script>
import CommonNavbar from "@/components/common/common-navbar";
import CoopListItem from "@/components/business/coop-list-item";
import Loading from "@/components/common/common-loading";
import CardBanner from "@/components/cme/card-banner";
import ICardItem from "@/components/cme/I-card-item";
import CommonTitle from "@/components/common/common-title";
import { mapGetters, mapActions } from "vuex";
export default {
data() {
return {
showLoading: false,
isWeb: window.__isWeb,
isAndroid: window.__isAndroid,
isIOS: window.__isIOS,
bgColor: "#fff",
isShow: false,
navTitle: "继教课程",
compTitle: "组件名称",
isShowNavbar: true,
isFixNavbar: false,
pointStyle: "activity",
descTitle: "规定从何处开始选取。如果是负数",
tabIndex: 1,
joinProjectList: [], // 我的项目
otherProjectList: [], // 全部项目
token: "",
toastTitle: "",
userMobile: "",
needShowBackup: false,
showGoUpdate: false,
oneLevelUrl: '',
provinceId: 0,
organizationId: 0,
};
},
computed: {
...mapGetters(["projectTabIndex", "organizationInfo"])
},
components: {
// DiscussTopicStencil,
CommonNavbar,
CoopListItem,
Loading,
CardBanner,
CommonTitle,
ICardItem,
},
created() {
var _this = this;
window.__getUserInfo = function(param) {
_this.setUserInfo(param);
_this.token = param.userToken;
_this.userMobile = param.userMobile;
_this.getCoopData();
console.log('__getUserInfo', param);
};
_this.getUserInfo();
if (__isWeb) {
_this.getCoopData();
}
window.__refresh = function() {
//_this.tabIndex = _this.projectTabIndex;
_this.getUserInfo();
};
// 打开页面埋点
// this.$sendBuriedData({
// component_tag: "210#0#0#0"
// });
// TEST
// window.__getPositionData = function(param) {
// console.log(param)
// }
// TEST
// this.getPositionData();
window.addEventListener("scroll", this.scrollFun);
},
mounted() {
var _this = this;
this.tabIndex = this.projectTabIndex;
},
methods: {
...mapActions(["setUserInfo", "setOrganizationInfo", "setJumpURLForI"]),
// //获取位置信息 测试代码 TEST
// getPositionData() {
// console.log('getPositionData');
// rocNative.getPositionData({
// __funcName: "__getPositionData"
// });
// },
//获取版本号
getUserInfo() {
rocNative.getUserInfo({
__funcName: "__getUserInfo"
});
},
// 切换列表
changeTab(index) {
let tag = index == 1 ? "210#210001#0" : "210#210001#1";
this.tabIndex = index;
if (index == 1 && !this.userMobile) {
rocNative.gotoLogin();
this.tabIndex = 2;
}
// this.$sendBuriedData({
// component_tag: tag
// });
},
// 获取所有项目:我的项目、其它项目
getCoopData() {
let _this = this;
let param = {
token: _this.token,
setEntry: true
};
_this.joinProjectList = [];
_this.otherProjectList = [];
_this.showLoading = true;
this.GET("cme/project/list", param).then(res => {
_this.showLoading = false;
if (res.code == "000000") {
// let organizationInfo = {}
_this.joinProjectList = res.data.myCMEProjectListDtoList;
_this.otherProjectList = res.data.allCMEProjectListDtoList;
_this.provinceId = res.data.provinceId;
_this.organizationId = res.data.organizationId;
_this.oneLevelUrl = res.data.oneLevelUrl; // I类学习卡列表地址
// 不做相应判断
if (_this.userMobile) {
_this.tabIndex = 1;
} else {
_this.tabIndex = 2;
}
if (_this.joinProjectList && _this.joinProjectList.length === 0) {
_this.tabIndex = 2;
}
_this.isShow = true;
}
});
},
// 监听滚动事件
scrollFun() {
let scrollTop = window.scrollY;
if (scrollTop >= 500) {
this.needShowBackup = true;
} else {
this.needShowBackup = false;
}
},
// 滚动到顶部
scrollTop() {
window.scrollTo(0, 0);
},
}
};
</script>
<style lang="scss" scoped>
@import "../style/mixin";
.page-content {
&-table {
position: fixed;
z-index: 100;
width: 100%;
text-align: center;
border-bottom: 1px solid #e7e7e7;
background: #fff;
tr {
font-size: px2rem(15px);
font-weight: 700;
height: px2rem(44px);
td {
width: 50%;
padding-top: px2rem(6px);
.tap-title {
display: flex;
flex-direction: column;
align-items: center;
color: #999;
span:nth-child(2) {
position: relative;
left: 0;
bottom: px2rem(-8px);
z-index: 2;
width: px2rem(10px);
height: px2rem(3px);
background: rgba(255, 255, 255, 1);
border-radius: px2rem(3px);
}
}
&.active {
span:nth-child(2) {
background: rgba(68, 146, 132, 1);
}
span.android:nth-child(2) {
bottom: px2rem(-12px);
}
span.ios:nth-child(2) {
bottom: px2rem(-10px);
}
}
}
}
}
.cb-wrapper {
width: 100%;
position: fixed;
top: px2rem(49px);
left: 0;
z-index: 90;
// margin-bottom: 30px;
&.padding-top-111 {
top: px2rem(111px);
}
}
&-list {
padding-top: px2rem(50px);
.mt-10 {
margin-bottom: px2rem(-10px);
}
}
}
.back-up-icon {
position: fixed;
bottom: px2rem(50px);
right: px2rem(15px);
img {
width: px2rem(35px);
height: px2rem(35px);
}
}
.fade-enter-active,
.fade-leave-active {
transition: opacity 0.5s;
}
.fade-enter,
.fade-leave-active {
opacity: 0;
}
</style>
......@@ -10,78 +10,20 @@
borderStyle="1px solid #fff"
></CommonNavbar>
<section class="page-content">
<table class="page-content-table">
<tr>
<td @click="changeTab(1)" :class="{'active': tabIndex === 1}">
<div class="tap-title">
<span :style="{'color': tabIndex === 1 ? '#333' : '#999'}">我的项目</span>
<span :class="{'android': isAndroid, 'ios': isIOS}"></span>
</div>
</td>
<td @click="changeTab(2)" :class="{'active': tabIndex === 2}">
<div class="tap-title">
<span :style="{'color': tabIndex === 2 ? '#333' : '#999'}">全部项目</span>
<span :class="{'android': isAndroid, 'ios': isIOS}"></span>
</div>
</td>
</tr>
</table>
<!-- <article v-show="isShow" class="cb-wrapper" :class="{'padding-top-111': !isWeb}">
<CardBanner :userMobile="userMobile"></CardBanner>
</article> -->
<article class="page-content-list">
<CommonTitle title="国家级继续医学教育项目(远程)" :isShowCert="false"></CommonTitle>
<ICardItem :oneLevelUrl="oneLevelUrl" :provinceId="provinceId" :organizationId="organizationId" :cmeToken="token"></ICardItem>
<CommonTitle
class="mt-10"
v-show="isShow && ((tabIndex === 1 && joinProjectList.length) || (tabIndex === 2 && otherProjectList.length))"
:title="tabIndex === 1 ? '我的继续医学教育课程' : '继续医学教育课程'"
:isShowCert="false"
/>
<section v-if="tabIndex === 1">
<CoopListItem
:paramData="joinProjectList"
:coopType="1"
:tabTo="1"
:isShow="isShow"
:userMobile="userMobile"
:provinceId="provinceId"
:organizationId="organizationId"
></CoopListItem>
</section>
<section v-if="tabIndex === 2">
<CoopListItem
:paramData="otherProjectList"
:coopType="1"
:tabTo="2"
:isShow="isShow"
:userMobile="userMobile"
:provinceId="provinceId"
:organizationId="organizationId"
></CoopListItem>
</section>
</article>
wefwef
</section>
<!-- <div>
<iframe src="https://www.baidu.com" id="mobsf" frameborder="0" style="width:100%;height:500px;"></iframe>
</div>-->
<!-- <discuss-topic-stencil /> -->
<transition name="fade">
<article v-show="needShowBackup" @click="scrollTop" class="back-up-icon">
<img src="../images/cme/phrase2/back-top.png" alt />
</article>
</transition>
<Loading v-if="showLoading" />
<!-- <CardPopup :showGoUpdate="showGoUpdate"></CardPopup> -->
</div>
</template>
<script>
import CommonNavbar from "@/components/common/common-navbar";
import CoopListItem from "@/components/business/coop-list-item";
import Loading from "@/components/common/common-loading";
import CardBanner from "@/components/cme/card-banner";
import ICardItem from "@/components/cme/I-card-item";
// import CardPopup from "@/components/cme/card-popup";
import CommonTitle from "@/components/common/common-title";
import { mapGetters, mapActions } from "vuex";
......@@ -99,16 +41,12 @@ export default {
isShowNavbar: true,
isFixNavbar: false,
pointStyle: "activity",
descTitle: "规定从何处开始选取。如果是负数",
tabIndex: 1,
joinProjectList: [], // 我的项目
otherProjectList: [], // 全部项目
token: "",
toastTitle: "",
userMobile: "",
needShowBackup: false,
showGoUpdate: false,
oneLevelUrl: '',
provinceId: 0,
organizationId: 0,
};
......@@ -120,12 +58,8 @@ export default {
components: {
// DiscussTopicStencil,
CommonNavbar,
CoopListItem,
Loading,
CardBanner,
CommonTitle,
ICardItem,
// CardPopup
},
created() {
var _this = this;
......@@ -141,27 +75,20 @@ export default {
_this.getCoopData();
}
window.__refresh = function() {
//_this.tabIndex = _this.projectTabIndex;
_this.getUserInfo();
};
// 打开页面埋点
this.$sendBuriedData({
component_tag: "210#0#0#0"
});
// this.$sendBuriedData({
// component_tag: "210#0#0#0"
// });
// TEST
// window.__getPositionData = function(param) {
// console.log(param)
// }
// TEST
// this.getPositionData();
window.addEventListener("scroll", this.scrollFun);
},
mounted() {
var _this = this;
this.tabIndex = this.projectTabIndex;
// this.tabIndex = this.projectTabIndex;
},
methods: {
......@@ -190,9 +117,9 @@ export default {
rocNative.gotoLogin();
this.tabIndex = 2;
}
this.$sendBuriedData({
component_tag: tag
});
// this.$sendBuriedData({
// component_tag: tag
// });
},
// 获取所有项目:我的项目、其它项目
......@@ -213,7 +140,7 @@ export default {
_this.otherProjectList = res.data.allCMEProjectListDtoList;
_this.provinceId = res.data.provinceId;
_this.organizationId = res.data.organizationId;
_this.oneLevelUrl = res.data.oneLevelUrl; // I类学习卡列表地址
// _this.oneLevelUrl = res.data.oneLevelUrl; // I类学习卡列表地址
// 不做相应判断
if (_this.userMobile) {
......@@ -251,67 +178,7 @@ export default {
@import "../style/mixin";
.page-content {
&-table {
position: fixed;
z-index: 100;
width: 100%;
text-align: center;
border-bottom: 1px solid #e7e7e7;
background: #fff;
tr {
font-size: px2rem(15px);
font-weight: 700;
height: px2rem(44px);
td {
width: 50%;
padding-top: px2rem(6px);
.tap-title {
display: flex;
flex-direction: column;
align-items: center;
color: #999;
span:nth-child(2) {
position: relative;
left: 0;
bottom: px2rem(-8px);
z-index: 2;
width: px2rem(10px);
height: px2rem(3px);
background: rgba(255, 255, 255, 1);
border-radius: px2rem(3px);
}
}
&.active {
span:nth-child(2) {
background: rgba(68, 146, 132, 1);
}
span.android:nth-child(2) {
bottom: px2rem(-12px);
}
span.ios:nth-child(2) {
bottom: px2rem(-10px);
}
}
}
}
}
.cb-wrapper {
width: 100%;
position: fixed;
top: px2rem(49px);
left: 0;
z-index: 90;
// margin-bottom: 30px;
&.padding-top-111 {
top: px2rem(111px);
}
}
&-list {
padding-top: px2rem(50px);
.mt-10 {
margin-bottom: px2rem(-10px);
}
}
}
.back-up-icon {
position: fixed;
......
<template>
<!-- 组件详情页面:模块列表及其下面的元件列表 -->
<div class="page-container-merge" :style="{'position': isShowEJDialog ? 'fixed' : 'static'}">
<div class="page-container-merge">
<CommonNavbar
id="header"
:bgColor="bgColor"
......@@ -32,20 +32,6 @@
:subject="project.subject"
/>
<CommonAdertImg :advertInfoList="advertInfoList" position="0" />
<!-- 步骤条 -->
<div v-if="project.cmeType != 2">
<CmeStep
:currentProgress="project.currentProgress"
:studyProgress="project.studyProgress"
:credit="project.credit"
:creditId="project.creditId"
:certificateUrl="project.certificateUrl"
:inScope="project.inScope"
:projectId="projectId"
:certificateId="project.certificateId"
@applicationCredit="applicationCredit"
/>
</div>
<!-- 简介和目录 -->
<div class="intro-catalogue-container">
<div
......@@ -68,7 +54,6 @@
:organName="project.organName"
:remind="project.remind"
:projectCredit="project.projectCredit"
:cmeType="project.cmeType"
:projectName="project.projectName"
/>
<LearnKnow :mustKnow="project.mustKnow"></LearnKnow>
......@@ -100,35 +85,17 @@
<NoMoreContent />
<div v-if="detailNum <= 9" class="no-more-bottom"></div>
</div>
<!-- 弹框 -->
<CommonDialog
:isShowDialog="isShowDialog"
:isSingle="isSingle"
:cancleBtnText="cancleBtnText"
:confirmBtnText="confirmBtnText"
:content="dialogContent"
@handlerAction="handlerAction"
/>
<!-- 弹框 -->
<ExjumperDialog
:isShowDialog="isShowEJDialog"
isSingle
needSubContent
content="请确保您已经在云鹊平台购买学员优惠学习卡"
subContent="1. 跳转后点击“购买学习”,注册登录“中华医学教育在线”平台(首次登录需用手机号注册)<br/>2. 支付方式选择 “学习卡支付”,输入在云鹊平台已购学习卡的激活码,即可参加考试申请学分"
cancleBtnText="我知道了"
@handlerAction="handlerEJAction"
/>
<ExjumperButton
@btnClick="beforeJumpToExam"
v-if="project.cmeType == 2 && hasBindCard"
v-if="hasBindCard"
:btnText="project.currentProgress > 1 ? '参加考试' : '学完全部课程,可参加考试'"
:type="project.currentProgress > 1 ? 'primary' : 'disabled'"
></ExjumperButton>
<div v-if="project.cmeType == 2 && !isWeb" style="padding-top: 30px"></div>
<div v-if="!isWeb" style="padding-top: 30px"></div>
<BindCardButton
v-if="project.cmeType == 2 && !hasBindCard && !isWeb"
v-if="!hasBindCard && !isWeb"
:cardInfo="cardInfo"
@changeClick="changeClick"
@gotoBuy="confirm"
......@@ -141,7 +108,6 @@
@cancle="cancleChangeCard"
@confirm="changeCardAction">
</ChangeCard>
<!-- <CardPopup :cardInfo="cardInfo" :isShow="isShowPopup" @clickOverlay="clickOverlay" @cancle="jumpToCardList()" @confirm="confirm"></CardPopup> -->
<Loading v-show="showLoading" />
<div>
<span ref="copyLinkBtn"
......@@ -159,19 +125,15 @@ import CommonDescription from "@/components/common/common-description";
import CommonSpliteLine from "@/components/common/common-splite-line";
import CellListDetail from "@/components/business/cell-list-detail";
// import NoPermContent from "@/components/business/no-perm-content";
// import CommonBannerVideo from "@/components/common/common-banner-video";
import CommonTcPlayer from "@/components/common/common-tcplayer";
import Loading from "@/components/common/common-loading";
import CmeStep from "@/components/cme/cme-step";
import BasicInfo from "@/components/cme/basic-info";
import LearnKnow from "@/components/cme/learn-know";
import ItemIntro from "@/components/cme/item-intro";
import ItemLeader from "@/components/cme/item-leader";
import TeacterIntro from "@/components/cme/teacter-intro";
import CommonDialog from "@/components/cme/common-dialog";
import ExjumperDialog from "@/components/cme/exjumper-dialog";
import ExjumperButton from "@/components/cme/exjumper-button";
import NoMoreContent from "@/components/business/no-more-content";
import CommonAdertImg from "@/components/common/common-advert-img";
......@@ -180,7 +142,6 @@ import { getWebPageUrl, gotoPage } from "@/utils/index";
import { mapGetters, mapActions } from "vuex";
import vueFilters from "@/utils/filter";
import { Toast } from "vant";
// import CardPopup from "@/components/cme/card-popup";
import BindCardButton from "@/components/cme/bind-card-button";
import ChangeCard from "@/components/cme/change-card";
let cataOffsetTop = 0;
......@@ -196,13 +157,6 @@ export default {
leaderText: "",
pageTitle: "",
isShowShare: true,
premissionFlag: false,
isSingle: false,
dialogContent: "", // 弹框内容
confirmBtnText: "", // 弹框按钮
cancleBtnText: "",
isShowDialog: false,
isShowEJDialog: false,
tabFlag: true, // 显示目录还是简介
fixedFlag: false, // 目录和简介是否固定
project: {
......@@ -227,17 +181,11 @@ export default {
inScope: 0, // 是否在范围内判断
projectCredit: "", // 学分
certificateId: "0",
cmeType: 1, // 1: 自营项目; 2: 中华医学会二类
examBtnUrl: "", // 考试按钮跳转连接
firstIntoExam: false, // true弹框,是否首次进入考试,用于首次跳转弹框提示,只跟项目和人员有关
jumpToContents: false, // 是否跳转到目录
cardStatus: 0,
cardKey: '',
// cmeType=2时不显示进度,
// projectNo为空时不显示项目编号,
// projectLeader为空时不显示项目负责人,
// inScope=0时考试按钮不显示,
// currentProgress>1时考试按钮显示并可用
},
hasBindCard: false, // 是否绑定过学习卡或激活过 没有绑定,则显示绑定按钮
limitTimes: 60,
......@@ -247,8 +195,6 @@ export default {
isBlack: false,
showLoading: false,
projectId: "1",
//componentId: 1,
//moduleId: 1,
contentList: [],
//moduleName: "",
bannerType: 1, // 1 图片 2视频
......@@ -277,13 +223,13 @@ export default {
btnText: "学完全部课程,可参加考试", // 参加考试(currentProgress = 1); 或者学完全部课程,可参加考试
provinceId: "",
organizationId: "",
isShowPopup: false,
cardInfo: {
id: 0
},
advertInfoList: [],
showChangeCard: false, //是否展示激活弹框,
changeCardErrorMsg: ""
changeCardErrorMsg: "",
isInfresh: false,
};
},
components: {
......@@ -293,7 +239,6 @@ export default {
CellListDetail,
Loading,
CommonTcPlayer,
CmeStep,
BasicInfo,
LearnKnow,
ItemIntro,
......@@ -301,8 +246,6 @@ export default {
TeacterIntro,
CommonDialog,
ExjumperButton,
ExjumperDialog,
// CardPopup,
CommonAdertImg,
NoMoreContent,
BindCardButton,
......@@ -341,14 +284,10 @@ export default {
_this.getProjectParticularsV2();
}
window.__refresh = function() {
_this.isInfresh = true;
_this.getUserInfo();
};
// 打开页面埋点
this.$sendBuriedData({
// action: "打开页面",
component_tag: `211#0#${this.projectId}#0`
});
window.__getPositionData = function(param) {
console.log(param);
// _this.showLoading = false;
......@@ -378,7 +317,7 @@ export default {
let _this = this;
let param = {
cardKey: cardKey,
cardType: 2,
cardType: 3,
portalProjectId: this.projectId,
setEntry: true
};
......@@ -424,65 +363,22 @@ export default {
});
},
// 点击弹层
clickOverlay() {
console.log("clickOverlay");
// this.isShowPopup = false;
},
// 点击“参与考试”
beforeJumpToExam() {
this.$sendBuriedData({
component_tag: `882#8824`
});
// this.$sendBuriedData({
// component_tag: `882#8824`
// });
// 如果是首次,则弹出弹框
if (this.project.firstIntoExam) {
this.isShowEJDialog = true;
} else {
// this.isBuy(2);
this.jumpToCardList();
}
},
// 第一次跳转弹框,点击时调用相应接口
handlerEJAction() {
this.$sendBuriedData({
component_tag: `883#8831`
});
this.isShowEJDialog = false;
this.jumpToCardList();
// this.isBuy(2);
this.firstIntoExamAction();
},
// 判断用户是否购买过I类学习卡
// isBuy(cardType) {
// this.showLoading = true;
// // alert(this.showLoading)
// let param = {
// cardType: cardType,
// setEntry: true,
// }
// this.GET("trade/storage/card/isBuy", param).then(res => {
// if (res.code == "000000") {
// // 如果购买过,则直接跳转到中华医学会页面
// if(res.data) {
// this.jumpToCardList();
// } else {
// this.preJumper();
// }
// }
// });
// },
// 跳转II类学习详情页面(中华医学会项目详情页面)
// 跳转II类学习详情页面(跳转的页面由后面配置)
jumpToCardList() {
this.$sendBuriedData({
component_tag: `885#8851`
});
// this.$sendBuriedData({
// component_tag: `885#8851`
// });
this.showLoading = false;
// this.isShowPopup = false;
// 判断版本号,如果小于3.4.0,则只做提示
let appVersion = this.userInfo.appVersion;
let appVersionNum = appVersion.split(".").join("");
......@@ -551,14 +447,13 @@ export default {
getCardInfoByProvinceId(provinceId) {
let param = {
area: provinceId + "",
cardType: 2,
cardType: 3,
pageNum: 1,
pageSize: 1
};
this.POST("trade/goods/cardList", param).then(res => {
if (res.code == "000000") {
this.showLoading = false;
// this.isShowPopup = true;
this.cardInfo = (res.data && res.data[0]) || { id: 0 };
}
});
......@@ -581,16 +476,15 @@ export default {
Toast("请您下载新版本App");
return;
}
this.$sendBuriedData({
component_tag: `885#8852`
});
// this.$sendBuriedData({
// component_tag: `885#8852`
// });
// this.isShowPopup = false;
// let pageUrl = this.project.examBtnUrl;
// 直接传入项目ID(projectId)
let projectId = this.project.projectId;
let pageUrl = getWebPageUrl(
`/cme/#/coop?id=${projectId}&cmeProjectId=${projectId}`
`/profexam/#/index?id=${projectId}&profexamProjectId=${projectId}`
);
let paramList = [
{
......@@ -619,13 +513,13 @@ export default {
jsonString: paramList
});
},
// 跳转到原生的购买页面
confirmOld() {
this.$sendBuriedData({
component_tag: `885#8852`
});
// this.$sendBuriedData({
// component_tag: `885#8852`
// });
// this.isShowPopup = false;
let pageUrl = this.project.examBtnUrl;
let paramList = [
{
......@@ -687,76 +581,13 @@ export default {
this.GET("campaign/admin/task/checkToken", param).then(res => {
if (res.code !== "000000") {
//未登录 跳转登录页
console.log("跳登录");
rocNative.gotoLogin();
} else {
// if (!_this.premissionFlag) {
// _this.premissionFlag = true;
// _this.permission(); // 提示是否有机构和在申请范围内
// }
}
});
},
//(判断是否加入机构,是否为认证用户,是否在申请范围内)
permission() {
let _this = this;
let param = {
id: _this.projectId,
creditId: _this.project.creditId,
token: _this.userInfo.userToken || this.token,
setEntry: true
};
_this.NEW_POST("cme/credit/rangeCheck", param).then(res => {
if (
_this.project.cmeType != 2 &&
(res.code == "219004" || res.code == "219012")
) {
// 未加入机构 219004 不在申请范围 219012
this.dialogContent = `该项目仅对${_this.project.scope}的用户开放`;
this.cancleBtnText = "我知道了";
this.isShowDialog = true;
this.isSingle = true;
} else {
this.isShowDialog = false;
}
});
},
// 立即申请学分
applicationCredit() {
let _this = this;
let param = {
id: _this.projectId,
creditId: _this.project.creditId,
token: _this.userInfo.userToken || this.token,
setEntry: true
};
_this.NEW_POST("cme/credit/applyCheck", param).then(res => {
if (res.code == "000000") {
gotoPage(
_this,
`cme/#/credit-edit?creditId=${_this.project.creditId}`
);
} else if (res.code == "219004" || res.code == "219005") {
// 未加入机构 219004 未身份认证 219005 不在申请范围 219012
let params = {
__funcName: "__checkPermissions",
permCode: "009014"
};
rocNative.checkPermissions(params);
}
// else if (res.code == "219012") {
// this.dialogContent = res.message;
// this.cancleBtnText = "我知道了";
// this.isShowDialog = true;
// this.isSingle = true;
// }
else {
this.dialogContent = res.message;
this.cancleBtnText = "我知道了";
this.isShowDialog = true;
this.isSingle = true;
console.log("跳登录", _this.isInfresh);
if(_this.isInfresh) {
rocNative.goBack();
} else {
rocNative.gotoLogin();
}
_this.isInfresh = false;
}
});
},
......@@ -767,14 +598,8 @@ export default {
this.showChangeCard = true;
},
// 弹框按钮事件
handlerAction(data) {
this.isShowDialog = false;
},
scrollFun() {
//如果是第一次的弹框,则直接退出
if(this.isShowEJDialog) return;
let scrollTop =
document.body.scrollTop || document.documentElement.scrollTop;
let h = intorOffsetTop - 135;
......@@ -825,9 +650,9 @@ export default {
window.scrollTo(0, h);
this.isBlack = true;
this.bgColor = "#fff";
this.$sendBuriedData({
component_tag: `211#211007#${this.projectId}`
});
// this.$sendBuriedData({
// component_tag: `211#211007#${this.projectId}`
// });
},
// 锚点到目录
......@@ -847,9 +672,9 @@ export default {
window.scrollTo(0, h);
this.isBlack = true;
this.bgColor = "#fff";
this.$sendBuriedData({
component_tag: `211#211008#${this.projectId}`
});
// this.$sendBuriedData({
// component_tag: `211#211008#${this.projectId}`
// });
},
// 获取项目详情
......@@ -900,11 +725,6 @@ export default {
res.data.projectComponentDTOS
);
if (!_this.isWeb && !_this.premissionFlag) {
_this.premissionFlag = true;
_this.permission(); // 提示是否有机构和在申请范围内
}
// TODO Add by Anndy Yang
if (_this.project.currentProgress == 2) {
_this.$nextTick(() => {
......@@ -1010,10 +830,10 @@ export default {
_this.actionList = actionList;
_this.detailNum = detailNum;
console.log("list转为:", list, actionList, detailNum);
// list[0].portalModuleDTOS[3].contentList[0].certificateFlag = 2;
// list[0].portalModuleDTOS[3].contentList[1].certificateFlag = 2;
return list;
},
// 这里?
getHight(data) {
let len = vueFilters.strLength(data.name);
let certificate = data.certificateFlag;
......
<template>
<!-- 组件详情页面:模块列表及其下面的元件列表 -->
<div class="page-container-parent">
<CommonNavbar
:bgColor="bgColor"
v-show="isShowNavbar"
:isBlack="isBlack"
:title="navTitle"
:isFixNavbar="isFixNavbar"
:burialPoint="pointStyle"
borderStyle="0px solid #fff"
:backMethod="from"
></CommonNavbar>
<div class="page-content list-container">
<!-- <img
v-if="bannerType == 1"
class="banner-img"
src="https://files.yunqueyi.com/image/jpeg/common/20190214153449966.jpg"
>-->
<!-- <div v-if="bannerType == 1" class="page-content-img-container"> -->
<div v-if="bannerType == 1" class="page-content-img-container">
<img class="banner-img" :src="attachmentUrl">
<img v-show="pStatus == 1" class="banner-img-1" src="../images/status-join.png">
<img v-show="pStatus == 5" class="banner-img-5" src="../images/status-keep-on.png">
<img v-show="pStatus == 10" class="banner-img-10" src="../images/status-end.png">
</div>
<!-- <CommonBannerVideo v-if="bannerType == 1" :videoOptions="videoOptions"></CommonBannerVideo> -->
<CommonTcPlayer v-if="bannerType == 2" style="flex" :options="videoOptions"></CommonTcPlayer>
<CommonDescription :descTitle="projectName" :value="projectIntro"></CommonDescription>
<CommonSpliteLine></CommonSpliteLine>
<div v-if="visibleFlag == 1" class="project-num">{{ childrenList.length }} 个项目</div>
<CoopListItem v-if="visibleFlag == 1" :paramData="childrenList" :coopType="1" :tabTo="3" :isShow="isShow"></CoopListItem>
<NoPermContent v-if="visibleFlag == 2"></NoPermContent>
</div>
<Loading v-show="showLoading"/>
</div>
</template>
<script>
import CommonNavbar from "@/components/common/common-navbar";
import CommonDescription from "@/components/common/common-description";
import CommonSpliteLine from "@/components/common/common-splite-line";
import CommonTitle from "@/components/common/common-title";
import CommonBannerVideo from "@/components/common/common-banner-video";
import CommonTcPlayer from "@/components/common/common-tcplayer";
import CoopListItem from "@/components/business/coop-list-item";
import NoPermContent from "@/components/business/no-perm-content";
import Loading from "@/components/common/common-loading";
import { mapGetters, mapActions } from "vuex";
import vueFilters from '@/utils/filter'
export default {
data() {
return {
from: "inner",
isBlack: false,
showLoading: false,
contentList: [],
bannerType: 1,
videoOptions: {
mp4: "",
// mp4: "https://pica-pro.oss-cn-shanghai.aliyuncs.com/2019/03/05/movie.mp4",
// "mp4": "http://1258717429.vod2.myqcloud.com/24a74910vodcq1258717429/7c37c18f5285890786204547811/9BFIyaoXYAcA.mp4",
// "m3u8": "http://2157.liveplay.myqcloud.com/2157_358535a.m3u8",
// "flv": "http://2157.liveplay.myqcloud.com/live/2157_358535a.flv", //增加了一个flv的播放地址,用于PC平台的播放 请替换成实际可用的播放地址
autoplay: false, //iOS下safari浏览器,以及大部分移动端浏览器是不开放视频自动播放这个能力的
coverpic: require("../images/video-cover.png"),
width: "415", //视频的显示宽度,请尽量使用视频分辨率宽度
height: "210" //视频的显示高度,请尽量使用视频分辨率高度
},
// projectStatus: 1, //1没有获得证书 2是获得全部证书
pStatus: 0, // 项目状态 1是参加中 5是进行中 10是已结束
projectIntro: "",
projectName: "",
attachmentUrl: require("../images/banner-default.png"),
bgColor: "none",
navTitle: "",
compTitle: "组件名称",
isShowNavbar: true,
isShow: true,
isFixNavbar: true,
pointStyle: "activity",
descTitle: "规定从何处开始选取。如果是负数",
description:
"必需。规定从何处开始选取。如果是负数,那么它规定从数组尾部开始算起的位置那么它规定从数组尾部开始算起的位置那么它规定从数组尾部开始算起的位置那么它规定从数组尾部开始算起的位置。也就是说那么它规定从数组尾部开始算起的位置。也就是说那么它规定从数组尾部开始算起的位置。也就是说那么它规定从数组尾部开始算起的位置。也就是说那么它规定从数组尾部开始算起的位置。" +
" 也就是说那么它规定从数组尾部开始算起的位置。也就是说,必需。规定从何处开始选取。如果是负数,那么它规定从数组尾部开始算起的位置。也就是说,必需。规定从何处开始选取。如果是负数,那么它规定从数组尾部开始算起的位置。也就是说,必需。规定从何处开始选取。如果是负数,那么它规定从数组尾部开始算起的位置。也就是说,必需。规定从何处开始选取。如果是负数,那么它规定从数组尾部开始算起的位置。也就是说,必需。规定从何处开始选取。如果是负数,那么它规定从数组尾部开始算起的位置。也就是说,-1 指最后一个元素,-2 指倒数第二个元素,以此类推第二个元素。",
childrenList: [],
visibleFlag: 0,
entryId: 0,
};
},
components: {
CommonNavbar,
CommonDescription,
CommonSpliteLine,
CommonTitle,
CommonBannerVideo,
Loading,
CommonTcPlayer,
CoopListItem,
NoPermContent,
},
computed: {
...mapGetters(["userInfo"])
},
created() {
let _this = this;
this.from = this.$route.query.from || this.from || "native";
this.entryId = this.$route.query.entryId;
window.__getUserInfo4Comp = function(param) {
_this.token = param.userToken;
_this.setUserInfo(param);
_this.checkToken();
_this.getChildrenProject(_this.entryId);
};
window.__refresh = function() {
_this.getChildrenProject(_this.entryId);
};
_this.getUserInfo();
},
mounted() {
window.addEventListener("scroll", this.scrollFun);
},
beforeDestroyed() {
window.removeEventListener("scroll", this.scrollFun);
},
methods: {
...mapActions(["setUserInfo"]),
//获取用户信息
getUserInfo() {
rocNative.getUserInfo({
__funcName: "__getUserInfo4Comp"
});
if (window.__isWeb && process.env.BUILD_ENV == "development") {
let param = {
userToken: 'ED9F3381362641858B2B1F90C92A8050',
};
__getUserInfo4Comp(param);
}
},
checkToken() {
let _this = this;
let param = {
token: _this.userInfo.userToken,
setEntry: true,
};
this.GET("campaign/admin/task/checkToken", param).then(res => {
if(res.code !== '000000') {
//未登录 跳转登录页
console.log('跳登录');
rocNative.gotoLogin();
}
});
},
getChildrenProject(entryId) {
let _this = this;
let param = {
entryId: entryId,
token: _this.userInfo.userToken,
setEntry: true
};
this.GET("portal/portalApp/getEntryInfo", param).then(res => {
if (res.code == "000000") {
_this.visibleFlag = res.data.learnableFlag;
if (res.data.attachmentType == 2) {
_this.videoOptions.mp4 = res.data.attachmentUrl;
} else {
_this.attachmentUrl = res.data.attachmentUrl;
}
_this.bannerType = res.data.attachmentType;
// 先设置视频URL再显示视频组件 ------------ END
_this.projectIntro = res.data.entryIntro;
_this.projectName = res.data.entryName;
_this.pStatus = res.data.status;
_this.childrenList = res.data.projectList;
}
});
},
scrollFun() {
let scrollTop =
document.body.scrollTop || document.documentElement.scrollTop;
if (scrollTop > 20) {
this.isBlack = true;
this.bgColor = "#fff";
} else {
this.isBlack = false;
this.bgColor = "none";
}
}
}
};
</script>
<style lang="scss" >
@import "../style/mixin";
.page-container-parent {
.nav-top .nav-title {
height: px2rem(0px);
padding: px2rem(18px);
}
.banner-img {
display: inherit;
width: px2rem(375px);
height: px2rem(210px);
&-1 {
position: absolute;
left: 0;
top: px2rem(180px);
width: px2rem(76px);
height: px2rem(30px);
}
&-5 {
position: absolute;
left: 0;
top: px2rem(180px);
width: px2rem(76px);
height: px2rem(30px);
}
&-10 {
position: absolute;
left: 0;
top: px2rem(180px);
width: px2rem(148px);
height: px2rem(30px);
}
}
.list-container {
// margin-bottom: px2rem(40px);
}
.project-num {
position: relative;
height: px2rem(18px);
margin: px2rem(20px) 0 px2rem(15px) px2rem(15px);
font-weight: 500;
font-size: px2rem(18px);
line-height: px2rem(18px);
}
}
</style>
\ No newline at end of file
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册