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

部分bug修复。。。

上级 e8ed87f8
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
</ul> </ul>
<ul class="list"> <ul class="list">
<li v-for="(item, index) in dataList" :key="index"> <li v-for="(item, index) in dataList" :key="index">
<span>{{item.courseName}}</span> <span>{{item.courseName | shortName}}</span>
<span>{{item.courseTime}}分钟</span> <span>{{item.courseTime}}分钟</span>
<span>{{item.averageTime}}分钟</span> <span>{{item.averageTime}}分钟</span>
</li> </li>
...@@ -28,6 +28,19 @@ export default { ...@@ -28,6 +28,19 @@ export default {
default: () => [] default: () => []
} }
}, },
filters: {
shortName: function (value, length = 8, append = '...') {
if (value && value.length > length) {
return value.substring(0, length) + append
} else {
return value
}
},
},
methods: {
},
}; };
</script> </script>
<style scoped lang="scss"> <style scoped lang="scss">
......
...@@ -5,7 +5,7 @@ ...@@ -5,7 +5,7 @@
<li> <li>
<p> <p>
课程总时长 课程总时长
<span>(所有课程数 2门)</span> <span>(所有课程数 {{totalSize}}门)</span>
</p> </p>
<ProcessBar :maxValue="maxDuration" :value="maxDuration"></ProcessBar> <ProcessBar :maxValue="maxDuration" :value="maxDuration"></ProcessBar>
</li> </li>
...@@ -18,13 +18,13 @@ ...@@ -18,13 +18,13 @@
<li> <li>
<p> <p>
课程总时长 课程总时长
<span>(所有课程数 2门)</span> <span>(所有课程数 {{totalSize}}门)</span>
</p> </p>
<ProcessBar :maxValue="avgDuration" :value="maxDuration"></ProcessBar> <ProcessBar :maxValue="avgDuration" :value="avgDuration"></ProcessBar>
</li> </li>
<li> <li>
<p>平均学习时长</p> <p>平均学习时长</p>
<ProcessBar barColor="#FFB01A" :maxValue="avgDuration" :value="avgDuration"></ProcessBar> <ProcessBar barColor="#FFB01A" :maxValue="avgDuration" :value="maxDuration"></ProcessBar>
</li> </li>
</ul> </ul>
</div> </div>
...@@ -33,6 +33,10 @@ ...@@ -33,6 +33,10 @@
import ProcessBar from "@/components/common/pica-process"; import ProcessBar from "@/components/common/pica-process";
export default { export default {
props: { props: {
totalSize: {
type: Number | String,
default: 0
},
maxDuration: { maxDuration: {
type: Number | String, type: Number | String,
default: 100 default: 100
......
...@@ -35,10 +35,11 @@ export default { ...@@ -35,10 +35,11 @@ export default {
}, },
computed: { computed: {
...mapGetters({ ...mapGetters({
orgList: 'orgList' orgList: 'orgList',
areaDegree: 'areaDegree'
}), }),
isNotVisible() { isNotVisible() {
return this.orgList.length == 0 return this.orgList.length == 0 || this.areaDegree == 0 || this.areaDegree == 1 || this.areaDegree == 2
} }
}, },
// watch: { // watch: {
......
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
{{ {{
value.provinceName value.provinceName
? value.provinceName ? value.provinceName
: '请选择' : '请选择1'
}} }}
</li> </li>
<li <li
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
:class="{ active: isShowCity }" :class="{ active: isShowCity }"
class="item" class="item"
@click="tabAddressClick(2)" @click="tabAddressClick(2)"
>{{ value.cityName ? value.cityName : '请选择' }}</li> >{{ value.cityName ? value.cityName : '请选择2' }}</li>
<li <li
v-show="value.cityName && rank>2 && isShowCounty" v-show="value.cityName && rank>2 && isShowCounty"
:class="{ active: isShowCounty }" :class="{ active: isShowCounty }"
...@@ -31,7 +31,7 @@ ...@@ -31,7 +31,7 @@
@click="tabAddressClick(3)" @click="tabAddressClick(3)"
> >
{{ {{
value.countyName ? value.countyName : '请选择' value.countyName ? value.countyName : '请选择3'
}} }}
</li> </li>
<li <li
...@@ -39,7 +39,7 @@ ...@@ -39,7 +39,7 @@
:class="{ active: isShowTown }" :class="{ active: isShowTown }"
class="item" class="item"
@click="tabAddressClick(4)" @click="tabAddressClick(4)"
>{{ value.townName ? value.townName : '请选择' }}</li> >{{ value.townName ? value.townName : '请选择4' }}</li>
</ul> </ul>
<div class="address-content" @touchmove.stop> <div class="address-content" @touchmove.stop>
<ul v-show="isShowProvince" id="province"> <ul v-show="isShowProvince" id="province">
...@@ -158,6 +158,14 @@ export default { ...@@ -158,6 +158,14 @@ export default {
// localStorage.setItem('baseUrl',this.baseUrl); // localStorage.setItem('baseUrl',this.baseUrl);
// this.projectId = (this.$route.query && this.$route.query.projectId) || 374; // this.projectId = (this.$route.query && this.$route.query.projectId) || 374;
// this.getProvinceData(this.queryParams); // this.getProvinceData(this.queryParams);
if(process.client) {
if(this.$route && this.$route.query) {
let cQuery = this.$route.query
let hospitalIdList = cQuery.hospitalIdList || ''
this.queryParams.projectId = cQuery.projectId || '';
}
}
}, },
computed: { computed: {
...mapGetters({ ...mapGetters({
...@@ -272,6 +280,7 @@ export default { ...@@ -272,6 +280,7 @@ export default {
// }, // },
//选择省份的操作 //选择省份的操作
provinceSelect(item, idx) { provinceSelect(item, idx) {
console.log('provinceSelect', item, this.rank);
this.value.regionId = item.id this.value.regionId = item.id
this.value.provinceId = item.id; this.value.provinceId = item.id;
this.queryParams.regionId = item.id; this.queryParams.regionId = item.id;
...@@ -294,7 +303,7 @@ export default { ...@@ -294,7 +303,7 @@ export default {
// 调用机构接口 // 调用机构接口
this.setAreaDegree(item.degree) this.setAreaDegree(item.degree)
this.getHospitalsByRegionId(this.queryParams); this.getHospitalsByRegionId(this.queryParams);
return; // return;
} }
//控制省市县乡数据展示与隐藏 //控制省市县乡数据展示与隐藏
this.isShowProvince = false; this.isShowProvince = false;
...@@ -313,6 +322,7 @@ export default { ...@@ -313,6 +322,7 @@ export default {
}, },
//选择市的操作 //选择市的操作
citySelect(item, idx) { citySelect(item, idx) {
console.log('citySelect', item, this.rank);
this.value.regionId = item.id this.value.regionId = item.id
this.value.cityId = item.id; this.value.cityId = item.id;
this.queryParams.regionId = item.id; this.queryParams.regionId = item.id;
...@@ -348,6 +358,7 @@ export default { ...@@ -348,6 +358,7 @@ export default {
}, },
//选择区/县的操作 //选择区/县的操作
countySelect(item, idx) { countySelect(item, idx) {
console.log('countySelect', item, this.rank);
this.value.regionId = item.id this.value.regionId = item.id
this.value.countyId = item.id; this.value.countyId = item.id;
this.queryParams.regionId = item.id; this.queryParams.regionId = item.id;
...@@ -365,7 +376,7 @@ export default { ...@@ -365,7 +376,7 @@ export default {
// 调用机构接口 // 调用机构接口
this.setAreaDegree(item.degree) this.setAreaDegree(item.degree)
this.getHospitalsByRegionId(this.queryParams); this.getHospitalsByRegionId(this.queryParams);
return; // return;
} }
//控制省市县乡数据展示与隐藏 //控制省市县乡数据展示与隐藏
this.isShowProvince = false; this.isShowProvince = false;
...@@ -381,6 +392,7 @@ export default { ...@@ -381,6 +392,7 @@ export default {
}, },
//选择乡镇的操作 //选择乡镇的操作
townSelect(item, idx) { townSelect(item, idx) {
console.log('townSelect', item, this.rank);
this.value.regionId = item.id this.value.regionId = item.id
this.value.townId = item.id; this.value.townId = item.id;
this.queryParams.regionId = item.id; this.queryParams.regionId = item.id;
...@@ -393,7 +405,7 @@ export default { ...@@ -393,7 +405,7 @@ export default {
// 调用机构接口 // 调用机构接口
this.setAreaDegree(item.degree) this.setAreaDegree(item.degree)
this.getHospitalsByRegionId(this.queryParams); this.getHospitalsByRegionId(this.queryParams);
return; // return;
} }
// 当前选中的样式 // 当前选中的样式
this.areaList.townList.map(a => (a.selected = false)); this.areaList.townList.map(a => (a.selected = false));
......
...@@ -13,7 +13,7 @@ export default { ...@@ -13,7 +13,7 @@ export default {
}, },
value: { value: {
type: Number | String, type: Number | String,
default: 100 default: 0
}, },
valueDescWidth: { valueDescWidth: {
type: Number | String, type: Number | String,
...@@ -37,13 +37,18 @@ export default { ...@@ -37,13 +37,18 @@ export default {
mounted() { mounted() {
// let maxWidth = window.clien // let maxWidth = window.clien
// scrollWidth offsetWidth // scrollWidth offsetWidth
let clientWidth = window.outerWidth || document.body.clientWidth || document.documentElement.clientWidth this.$nextTick(() => {
let maxWidth = clientWidth - this.valueDescWidth let clientWidth = window.outerWidth || document.body.clientWidth || document.documentElement.clientWidth;
let ratio = 1 let maxWidth = clientWidth - this.valueDescWidth;
if(this.value && this.value < this.maxValue) { let ratio = 1;
ratio = this.value / this.maxValue if(this.value && this.value < this.maxValue) {
} ratio = this.value / this.maxValue;
this.maxPocessWidth = Math.round(ratio * maxWidth) + 'px' }
if(!this.value) {
ratio = 0.01;
}
this.maxPocessWidth = Math.round(ratio * maxWidth) + 'px'
})
}, },
methods: {} methods: {}
}; };
......
...@@ -90,12 +90,14 @@ export default { ...@@ -90,12 +90,14 @@ export default {
}); });
}, },
selectSortItem(type) { selectSortItem(type) {
alert(type)
console.log(this.allData)
if(type == 1) { if(type == 1) {
this.dataList = this.allData.examScoreList || []; this.dataList = this.allData.examScoreList || [];
} else if(type === 2) { } else if(type === 2) {
this.dataList = this.allData.examFiveScoreList || []; this.dataList = this.allData.fiveExamScoreList || [];
} else if(type === 3) { } else if(type === 3) {
this.dataList = this.allData.examTenScoreList || []; this.dataList = this.allData.tenExamScoreList || [];
} }
this.title = `共${this.dataList.length}条数据`; this.title = `共${this.dataList.length}条数据`;
} }
......
...@@ -55,7 +55,7 @@ ...@@ -55,7 +55,7 @@
<!-- 课程分析 --> <!-- 课程分析 -->
<article v-show="(cIndex === 2) && (projectInfo.existCourse == 1)" style="padding-top: 8px;"> <article v-show="(cIndex === 2) && (projectInfo.existCourse == 1)" style="padding-top: 8px;">
<CourseTimesStat :maxDuration="courseInfo.pCourseTotalTime" :avgDuration="courseInfo.pCourseAvg"></CourseTimesStat> <CourseTimesStat :totalSize="courseInfo.totalSize" :maxDuration="courseInfo.pCourseTotalTime" :avgDuration="courseInfo.pCourseAvg"></CourseTimesStat>
<CommonSplitLine></CommonSplitLine> <CommonSplitLine></CommonSplitLine>
<CommonTitle title="课程列表"></CommonTitle> <CommonTitle title="课程列表"></CommonTitle>
<CourseTimesList :dataList="courseInfo.pCourseList"></CourseTimesList> <CourseTimesList :dataList="courseInfo.pCourseList"></CourseTimesList>
...@@ -217,7 +217,7 @@ export default { ...@@ -217,7 +217,7 @@ export default {
allData: {}, allData: {},
projectId: "", projectId: "",
token: token:
"4F17C83E6D44456CB873B489BDC1380A" || "A0E52265D31B4D2380C7CFC9E1ACCDCE" ||
"A7F0A8A4BB5C4EC4B78E71261B753C9C" || "A7F0A8A4BB5C4EC4B78E71261B753C9C" ||
"4281940A6A0C49F69F06BBC9E83DA90D" || "4281940A6A0C49F69F06BBC9E83DA90D" ||
"A62E9F92365547A29724F21F29BED4F6" || "A62E9F92365547A29724F21F29BED4F6" ||
...@@ -314,6 +314,9 @@ export default { ...@@ -314,6 +314,9 @@ export default {
(this.$router && this.$route.query && this.$route.query.projectId) || (this.$router && this.$route.query && this.$route.query.projectId) ||
374; 374;
this.queryGDParams.projectId = this.projectId; this.queryGDParams.projectId = this.projectId;
this.CNTParams.projectId = this.projectId;
this.examSingleParams.projectId = this.projectId;
this.queryParams.projectId = this.projectId;
if (this.$rocNative.isWeb) { if (this.$rocNative.isWeb) {
this.setUserToken(this.token); this.setUserToken(this.token);
cookies.set("token", this.token); cookies.set("token", this.token);
...@@ -535,7 +538,7 @@ export default { ...@@ -535,7 +538,7 @@ export default {
// if(this.isShowArea) { // if(this.isShowArea) {
// this.isShowArea = false; // this.isShowArea = false;
// } // }
if(this.orgDegree !== 3 && this.orgDegree !== 4) { if(this.areaDegree !== 3 && this.areaDegree !== 4) {
this.$toast('选择区/县后才可选择机构'); this.$toast('选择区/县后才可选择机构');
return; return;
} }
...@@ -565,14 +568,14 @@ export default { ...@@ -565,14 +568,14 @@ export default {
analysisEduClick(index) { analysisEduClick(index) {
this.analysisEduData = this.analysisData.eduList[ this.analysisEduData = this.analysisData.eduList[
index ? "join" : "finish" index ? "finish" : "join"
]; ];
this.$forceUpdate(); this.$forceUpdate();
}, },
analysisTitleClick(index) { analysisTitleClick(index) {
this.analysisTitleData = this.analysisData.titleList[ this.analysisTitleData = this.analysisData.titleList[
index ? "join" : "finish" index ? "finish" : "join"
]; ];
this.$forceUpdate(); this.$forceUpdate();
}, },
......
const { NUXT_ENV_APP } = process.env; const { NUXT_ENV_APP } = process.env;
export const BASE_URL = { export const BASE_URL = {
dev: 'https://dev-sc.yunqueyi.com', // dev: 'https://dev-sc.yunqueyi.com',
dev: 'https://uat-sc.yunqueyi.com',
test: 'https://test1-sc.yunqueyi.com', test: 'https://test1-sc.yunqueyi.com',
uat: 'https://uat-sc.yunqueyi.com', uat: 'https://uat-sc.yunqueyi.com',
prod: 'https://sc.yunqueyi.com' prod: 'https://sc.yunqueyi.com'
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册