Browse Source

Merge branch 'develop3.0' of http://106.12.23.251:10080/TEAMMODEL/TEAMModelOS into develop3.0

liqk 4 years ago
parent
commit
0f16805950

+ 4 - 4
TEAMModelOS.SDK/Module/OpenXmlTool/WmlToHtmlConverter.cs

@@ -562,11 +562,11 @@ namespace OpenXmlPowerTools
 
                 return ProcessOMath(element);
             }
-            //if (element.Name == W._object)
-            //{
+            if (element.Name == M.oMathPara)
+            {
 
-            //    return ProcessOMath(element);
-            //}
+                return element.Elements().Select(e => ConvertToHtmlTransform(wordDoc, settings, e, false, currentMarginLeft));
+            }
 
             // Ignore element.
             return null;

+ 22 - 4
TEAMModelOS/ClientApp/src/components/learnactivity/ClassList.less

@@ -11,15 +11,33 @@
     display: flex;
 
     .class-list {
-        width: 20%;
+        width: calc(100% - 10px);
         height: 100%;
     }
 
     .class-info {
-        width: 80%;
+        /*width: 80%;*/
         min-height: 98%;
-        padding-left: 10px;
-        border-left: 1px solid @borderColor;
+        /*padding-left: 10px;*/
+        /*border-left: 1px solid @borderColor;*/
+    }
+
+    .subject-item {
+        display: inline-block;
+        margin-right: 15px;
+        color: @second-textColor;
+        cursor: pointer;
+        line-height: 40px;
+        min-width: 50px;
+        font-size: 15px;
+        text-align: center;
+        margin-left: 15px;
+    }
+
+    .subject-item-active {
+        color: @primary-textColor;
+        border-bottom: 2px solid white;
+        font-weight: 500;
     }
 
     .chart-show {

+ 35 - 26
TEAMModelOS/ClientApp/src/components/learnactivity/ClassList.vue

@@ -1,32 +1,39 @@
 <template>
     <div class="content">
         <div class="class-list">
+            <!--<div class="activity-target-header">
+        <span>测试科目</span>
+    </div>-->
             <div class="activity-target-header">
-                <span>测试科目</span>
-            </div>
-            <div @click="selectActivity(index)" v-for="(item,index) in paper" :key="index":class="index == currentActivityIndex ? 'activity-target-item block-bg block-bg-active':'block-bg activity-target-item'">
-                <p class="target-name">
+                <span>测试科目:</span>
+                <span v-if="paper.length > 0" v-for="(item,index) in paper" :class="index == currentActivityIndex ? 'subject-item subject-item-active':'subject-item'" @click="selectActivity(index)">
+                    {{jsFn.getPeriod($store.state.schoolBaseInfo.schoolBaseInfo, item.periodCode).periodName}}
+                    <span style="margin:0px 2px;">·</span>
                     {{jsFn.getSubjectName(jsFn.getPeriod($store.state.schoolBaseInfo.schoolBaseInfo, item.periodCode), item.subjectCode)}}
-                    <span class="activity-status">进行中</span>
-                </p>
-                <p style="margin-top:6px;">
-                    <span class="info-label"><Icon type="md-flag" style="margin-right:5px;" size="16" />测试类型:</span>
-                    <span class="info-value">{{typeList[item.level].label}}</span>
-                </p>
-                <p style="margin-top:6px;" >
-                    <span class="info-label"><Icon type="md-time" style="margin-right:5px;" size="16" />开始时间:</span>
-                    <span class="info-value">{{ $tools.formatTime(item.createTime *1000 , 'yyyy-MM-dd')}}</span>
-                </p>
-                <!--<p style="margin-top:6px;" v-else>
-                    <span class="info-label"><Icon type="md-time" style="margin-right:5px;" size="16" />结束时间:</span>
-                    <span class="info-value">{{item.endTime}}</span>
-                </p>-->
+                </span>
             </div>
-        </div>
+            <!--<div @click="selectActivity(index)" v-for="(item,index) in paper" :key="index":class="index == currentActivityIndex ? 'activity-target-item block-bg block-bg-active':'block-bg activity-target-item'">-->
+            <!--<p class="target-name">
+        {{jsFn.getSubjectName(jsFn.getPeriod($store.state.schoolBaseInfo.schoolBaseInfo, item.periodCode), item.subjectCode)}}
+        <span class="activity-status">进行中</span>
+    </p>
+    <p style="margin-top:6px;">
+        <span class="info-label"><Icon type="md-flag" style="margin-right:5px;" size="16" />测试类型:</span>
+        <span class="info-value">{{typeList[item.level].label}}</span>
+    </p>
+    <p style="margin-top:6px;" >
+        <span class="info-label"><Icon type="md-time" style="margin-right:5px;" size="16" />开始时间:</span>
+        <span class="info-value">{{ $tools.formatTime(item.createTime *1000 , 'yyyy-MM-dd')}}</span>
+    </p>-->
+            <!--<p style="margin-top:6px;" v-else>
+        <span class="info-label"><Icon type="md-time" style="margin-right:5px;" size="16" />结束时间:</span>
+        <span class="info-value">{{item.endTime}}</span>
+    </p>-->
+            <!--</div>-->
             <div class="class-info">
                 <div class="learn-progress-main dark-iview-table" v-if="currentActivityIndex == 0">
                     <vuescroll>
-                        <p style="color:#EEEEEE;padding-left:15px;font-size:16px;margin-top:15px;">测验成绩分析</p>
+                        <p style="color:#EEEEEE;font-size:16px;margin-top:5px;">测验成绩分析</p>
                         <div class="class-filter dark-iview-select">
                             <span class="filter-label">测验班级:</span>
                             <Select filterable style="display: inline-block;width: 150px;" @on-change="getClass" size="small">
@@ -35,7 +42,7 @@
                             <span style="float:right" @click="getTestData"><Icon :type="testStatus ? 'md-list-box':'md-stats'" style="margin-right:5px;" />{{testStatus ? '成绩列表':'成绩分析'}}</span>
                         </div>
                         <div class="chart-show">
-                            <div  v-if="!testStatus" class="chart" style="margin:auto">
+                            <div v-if="!testStatus" class="chart" style="margin:auto">
                                 <Grade v-if="studentList.length !== 0" :studentData="studentList"></Grade>
                             </div>
                             <div v-if="testStatus" class="chart">
@@ -50,13 +57,15 @@
                         </div>
                     </vuescroll>
                 </div>
-                    <div class="dark-iview-table" v-if="currentActivityIndex != 0">
-                        <p style="color:#EEEEEE;padding-left:15px;font-size:16px;margin-top:15px;">测验成绩评分</p>
-                        <div style="margin-top:5px;margin-left:5px;">
-                            <grade-list :paperInfo="paperData"></grade-list>
-                        </div>
+                <div class="dark-iview-table" v-if="currentActivityIndex != 0">
+                    <p style="color:#EEEEEE;font-size:16px;margin-top:5px;">测验成绩评分</p>
+                    <div style="margin-top:5px;">
+                        <grade-list :paperInfo="paperData"></grade-list>
                     </div>
+                </div>
             </div>
+        </div>
+
     </div>
 </template>
 <script>

+ 4 - 3
TEAMModelOS/ClientApp/src/components/learnactivity/GradeList.less

@@ -5,8 +5,8 @@
 @primary-fontSize: 14px;
 @second-fontSize: 16px;
 .body {
-    width: 95%;
-    margin: auto;
+    margin-right:10px;
+    /*margin: auto;*/
 /*    border: 1px solid @borderColor;*/
 }
 
@@ -35,6 +35,7 @@
         height:96%;
     }
     .student-show {
+        width:95%;
         height: 40px;
         padding-top:10px;
         border-bottom: 1px solid @borderColor;
@@ -64,7 +65,7 @@
     display: flex;
     width: 100%;
     margin: auto;
-    height:755px;
+    height:720px;
     border: 1px solid @borderColor;
 }
 

+ 21 - 6
TEAMModelOS/ClientApp/src/components/learnactivity/RecordChart.vue

@@ -15,7 +15,7 @@
     export default {
         data() {
             return {
-
+                timer:''
             }
         },
         methods: {
@@ -135,8 +135,6 @@
                     }]
                 }
                 myChart.setOption(option)
-                console.log(window)
-
             },
             setPie() {
                 let color = ['#FF8700', '#ffc300', '#00e473', '#009DFF', '#0034ff'];
@@ -543,9 +541,26 @@
             }
         },
         mounted() {
-            this.setTable()
-            this.setPie()
-            this.setChart()
+            setTimeout(() => {
+                this.setTable()
+                this.setPie()
+                this.setChart()
+            }, 200)
+
+            // 监听窗口echart自适应浏览器变化大小
+            window.addEventListener('resize', () => {
+                    this.table.resize()
+                    this.pie.resize()
+                    this.chart.resize()
+                console.log('16541654416516')
+            })
+           
+            //window.addEventListener('resize', () => {
+            //    this.$echarts.init(document.getElementById('table')).resize()
+            //    this.$echarts.init(document.getElementById('pie')).resize()
+            //    this.$echarts.init(document.getElementById('chart')).resize()
+            //    console.log('11111111111111111')
+            //})
         }
     }
 </script>

+ 12 - 8
TEAMModelOS/ClientApp/src/view/learnactivity/ManageEvaluation.less

@@ -1,7 +1,7 @@
-@main-bgColor: rgb(40,40,40); //Ö÷±³¾°ÑÕÉ«
+@main-bgColor: rgb(40,40,40); //主背景颜色
 @borderColor: #424242;
-@primary-textColor: #fff; //Îı¾Ö÷ÑÕÉ«
-@second-textColor: #a5a5a5; //Îı¾¸±¼¶ÑÕÉ«
+@primary-textColor: #fff; //文本主颜色
+@second-textColor: #a5a5a5; //文本副级颜色
 @primary-fontSize: 14px;
 @second-fontSize: 16px;
 @status-pending: #0FB68B;
@@ -13,7 +13,7 @@
     flex-direction: row;
 
     .evaluation-list-wrap {
-        width: 350px;
+        width: 45%;
         height: 100%;
         border-right: 1px solid @borderColor;
         padding-left: 15px;
@@ -62,10 +62,13 @@
 
             .evaluation-type {
                 color: @second-textColor;
-                margin-top: 10px
+                margin-top: 10px;
             }
-        }
 
+            .evaluation-type span{
+                margin-right:10px;
+            }
+        }
     }
 }
 
@@ -129,7 +132,7 @@
         }
 
         .evaluation-test-paper {
-            width: ~"calc(100% - 350px)";
+            width: ~"calc(100% - 10px)";
             height: 100%;
             padding-left: 15px;
 
@@ -183,6 +186,7 @@
     font-size: 18px;
     &:hover{
         color:aqua;
+        /*display:flex;*/
     }
 }
 
@@ -214,6 +218,6 @@
     background: @status-pending;
     color: #fff;
     display: inline-block;
-    margin-left: 20px;
+    margin-left: 5px;
     border-radius: 5px;
 }

+ 37 - 98
TEAMModelOS/ClientApp/src/view/learnactivity/ManageEvaluation.vue

@@ -5,18 +5,30 @@
             <div class="evaluation-list-title">
                 <span>评测列表</span>
                 <Icon type="md-add" class="to-create-icon" size="20" @click="goToCreate" title="新建" />
-                <Icon type="md-trash" :class="evaluationList.length == 0 ? 'custom-label-disabeld to-create-icon':'to-create-icon'" title="删除" @click="deleteEvaluation" />
-                <Icon type="md-create" :class="evaluationList.length == 0 ? 'custom-label-disabeld to-create-icon':'to-create-icon'" @click="editEvaluation" title="编辑" />
+                <!--<Icon type="md-trash" :class="evaluationList.length == 0 ? 'custom-label-disabeld to-create-icon':'to-create-icon'" title="删除" @click="deleteEvaluation" />
+                <Icon type="md-create" :class="evaluationList.length == 0 ? 'custom-label-disabeld to-create-icon':'to-create-icon'" @click="editEvaluation" title="编辑" />-->
             </div>
             <div class="evaluation-list-main">
                 <vuescroll>
                     <div :class="index == avtiveEvaluationIndex ? 'evaluation-item block-bg-active block-bg':'evaluation-item block-bg'" v-for="(item,index) in evaluationList" @click="selectEvaluation(index)">
+                        <Icon type="md-trash" :class="evaluationList.length == 0 ? 'custom-label-disabeld to-create-icon':'to-create-icon'" title="删除" @click="deleteEvaluation" />
+                        <Icon type="md-create" :class="evaluationList.length == 0 ? 'custom-label-disabeld to-create-icon':'to-create-icon'" @click="editEvaluation" title="编辑" />
                         <p class="evaluation-name">{{item.name}}</p>
                         <p class="evaluation-type">
-                            <Icon type="ios-cube" color="#a5a5a5" style="margin-right:10px;" size="16" />
-                            <span>评测类型:{{getTypeLabel(item.type)}}</span>
+                            <Icon type="md-time" color="#a5a5a5" style="margin-right:5px;" size="16" />
+                            <span>施测时间:{{dateFormat(item.startTime)}}</span>
                             <span class="evaluation-status-tag" :style="{ background: (item.state === 100 ? '#0BADD4' : item.state === 200 ? '#0fb68b' : '#949594')}">{{ item.state === 100 ? '待发布' : item.state === 200 ? '进行中' : '已结束' }}</span>
                         </p>
+                        <div style="display:inline-flex">
+                            <p class="evaluation-type">
+                                <Icon type="ios-cube" color="#a5a5a5" style="margin-right:5px;" size="16" />
+                                <span>评测类型:{{getTypeLabel(item.type)}}</span>
+                            </p>
+                            <p class="evaluation-type">
+                                <Icon type="ios-cube" color="#a5a5a5" style="margin-right:5px;" size="16" />
+                                <span>施测对象:{{getTypeLabel(item.type)}}</span>
+                            </p>
+                        </div>
                     </div>
                     <EmptyData v-if="evaluationList.length == 0" style="margin-top:120px;"></EmptyData>
                 </vuescroll>
@@ -31,7 +43,7 @@
             </div>
             <!--评测基础信息-->
             <div :class="currentBraIndex == 0 ? 'animated fadeIn evaluation-base-info':'evaluation-base-info animated fadeOutRight'" v-show="currentBraIndex == 0">
-                <div class="evalustion-base-attr dark-iview-input dark-iview-select">
+                <!--<div class="evalustion-base-attr dark-iview-input dark-iview-select">
                     <div class="evalustion-base-attr-header">
                         基础信息
                     </div>
@@ -59,7 +71,7 @@
                         </FormItem>
                     </Form>
                     <EmptyData v-else style="margin-top:80px;"></EmptyData>
-                </div>
+                </div>-->
                 <!-- 试卷详细信息 -->
                 <div class="evaluation-test-paper">
                     <div class="evaluation-test-paper-header">
@@ -102,7 +114,7 @@
                @on-ok="confirmDeleteEvaluation">
             <p style="font-size:16px;" v-if="evaluationList.length > 0">确认删除 {{evaluationList[avtiveEvaluationIndex].name}}?</p>
         </Modal>
-        <Modal v-model="publishStatus"
+        <!--<Modal v-model="publishStatus"
                title="发布评测"
                class-name="dark-iview-modal dark-iview-form"
                @on-ok="confirmPublishEvaluation">
@@ -126,7 +138,7 @@
                     <DatePicker type="date" format="yyyy/MM/dd HH:mm" split-panels placeholder="请选择发布时间" style="width:100%" @on-change="getDate"></DatePicker>
                 </FormItem>
             </Form>
-        </Modal>
+        </Modal>-->
     </div>
 </template>
 <script>
@@ -217,13 +229,7 @@
                         label:'定时发布'
                     }
                 ],
-                //studentLsit: [
-                //    {
-                //        id: HSBN001,
-                //        name: '测试一',
-
-                //    },
-                //]
+                startTime:''
             }
         },
         methods: {
@@ -495,9 +501,17 @@
                 let date = new Date(timestamp)
                 return date
             },
+            dateFormat(timestamp) {
+            var date = new Date(timestamp)
+            var Y = date.getFullYear() + '-'
+            var M = (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1) + '-'
+            var D = date.getDate() + ' '
+            return Y + M + D ;
+            },
             getMyDate(start, end) {
                 this.myDate.length = 0
                 this.myDate = [this.formatDate(start), this.formatDate(end)]
+                this.startTime = this.dateFormat( start)
             },
             selectEvaluation(index) {
                 this.currentBraIndex = 0
@@ -505,13 +519,13 @@
                 this.getMyDate(this.evaluationList[this.avtiveEvaluationIndex].startTime, this.evaluationList[this.avtiveEvaluationIndex].endTime)
                 this.findExamPaper()
             },
-            timestampToTime(timestamp) {
-                var date = new Date(timestamp);//时间戳为10位需*1000,时间戳为13位的话不需乘1000
-                var Y = date.getFullYear() + '-';
-                var M = (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1) + '-';
-                var D = date.getDate()
-                return Y + M + D;
-            },
+            //timestampToTime(timestamp) {
+            //    var date = new Date(timestamp);//时间戳为10位需*1000,时间戳为13位的话不需乘1000
+            //    var Y = date.getFullYear() + '-';
+            //    var M = (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1) + '-';
+            //    var D = date.getDate()
+            //    return Y + M + D;
+            //},
             findEvaluation() {
                 let requestData = {
                     code: this.$store.state.userInfo.TEAMModelId
@@ -520,6 +534,7 @@
                     res => {
                         if (res.error == null) {
                             this.evaluationList = res.result.data
+                            console.log(this.evaluationList)
                             if (this.evaluationList.length > 0) {
                                 this.selectEvaluation(0)
                             }
@@ -559,82 +574,6 @@
                     }
                 )
             },
-            //checkCount(count) {
-            //    switch (count) {
-            //        case 0:
-            //            return '一、'
-            //            break
-            //        case 1:
-            //            return '二、'
-            //            break
-            //        case 2:
-            //            return '三、'
-            //            break
-            //        case 3:
-            //            return '四、'
-            //            break
-            //        case 4:
-            //            return '五、'
-            //            break
-            //        case 5:
-            //            return '六、'
-            //            break
-            //        default:
-            //            return ''
-            //            break
-            //    }
-            //},
-            //getOrder(type) {
-            //    let count = 0
-            //    switch (type) {
-            //        case 'Single':
-            //            return '一、'
-            //            break
-            //        case 'Multiple':
-            //            if (this.groupQuestion.Single != undefined) {
-            //                return '二、'
-            //            } else {
-            //                return '一、'
-            //            }
-            //            break
-            //        case 'Complete':
-            //            for (let key in this.groupQuestion) {
-            //                if (key == 'Single' || key == 'Multiple') {
-            //                    count++
-            //                }
-            //            }
-            //            return this.checkCount(count)
-            //            break
-            //        case 'Judge':
-
-            //            for (let key in this.groupQuestion) {
-            //                if (key == 'Single' || key == 'Complete' || key == 'Multiple') {
-            //                    count++
-            //                }
-            //            }
-            //            return this.checkCount(count)
-            //            break
-            //        case 'Subjective':
-            //            for (let key in this.groupQuestion) {
-            //                if (key == 'Single' || key == 'Complete' || key == 'Multiple' || key == 'Judge') {
-            //                    count++
-            //                }
-            //            }
-            //            return this.checkCount(count)
-            //            break
-            //        case 'Compose':
-            //            for (let key in this.groupQuestion) {
-            //                if (key == 'Single' || key == 'Complete' || key == 'Multiple' || key == 'Judge' || key == 'Subjective') {
-            //                    count++
-            //                }
-            //            }
-            //            return this.checkCount(count)
-            //            break
-            //        default:
-            //            return ''
-            //            break
-            //    }
-            //}
         },
         mounted() {
             setTimeout(() => {

+ 36 - 35
TEAMModelOS/ClientApp/src/view/learnactivity/ManageRecord.vue

@@ -27,7 +27,6 @@
                                 <span>二年二班</span>
                             </MenuItem>
                         </Menu>
-
                     </Sider>
                 </Layout>
             </div>
@@ -36,40 +35,34 @@
             <div class="top-box">
                 <record-chart></record-chart>
             </div>
-                <div class="buttom-box">
-                    <Tabs>
-                        <TabPane v-for="(item,index) in dataInfo" :key="index" :label="item.type">
-                            <div class="list">
-                                <vuescroll :ops="scrollPanel">
-                                    <ul v-for=" (data,indexs) in item.data" :key="indexs">
-                                        <li>
-                                            <div class="box">
-                                                <span>{{data.name}}</span><br />
-                                                <hr />
-                                                <div class="box-info">
-                                                    <h3>参与班级:</h3>
-                                                    <div class="class-name">
-                                                        <p v-for="(info,num) in data.class" :key="num">{{info.value}}</p>
-                                                    </div>
-                                                    <h3>活动开始时间:</h3><p>{{data.time}}</p>
-                                                    <h3>活动结束时间:</h3><p>{{data.endTime}}</p>
+            <div class=" ">
+                <Tabs>
+                    <TabPane v-for="(item,index) in dataInfo" :key="index" :label="item.type">
+                        <div class="list">
+                            <vuescroll :ops="scrollPanel">
+                                <ul v-for=" (data,indexs) in item.data" :key="indexs">
+                                    <li>
+                                        <div class="box">
+                                            <span>{{data.name}}</span><br />
+                                            <hr />
+                                            <div class="box-info">
+                                                <h3>参与班级:</h3>
+                                                <div class="class-name">
+                                                    <p v-for="(info,num) in data.class" :key="num">{{info.value}}</p>
                                                 </div>
-                                                <Button style="float:right;margin-right:30px;margin-top:-15px" type="primary">查看详情</Button>
+                                                 <h3>活动开始时间:</h3><p>{{data.time}}</p>
+                                                <!--<h3>--><!--活动结束时间:--><!--</h3><p>{{data.endTime}}</p>-->
                                             </div>
-                                        </li>
-                                    </ul>
-                                </vuescroll>
-                            </div>
-                        </TabPane>
-                        <!--<TabPane label="自主学习" name="tab2" context-menu>自主学习</TabPane>
-                <TabPane label="作业活动" name="tab3" context-menu>作业活动</TabPane>
-                <TabPane label="投票活动" name="tab4" context-menu>投票活动</TabPane>
-                <TabPane label="问卷调查" name="tab5" context-menu>问卷调查</TabPane>-->
-                    </Tabs>
-
-                </div>
+                                            <Button style="float:right;margin-right:30px;margin-top:-15px" type="primary">查看详情</Button>
+                                        </div>
+                                    </li>
+                                </ul>
+                            </vuescroll>
+                        </div>
+                    </TabPane>
+                </Tabs>
+            </div>
         </div>
-        </Layout>
     </div>
 </template>
 <script>
@@ -133,10 +126,18 @@
         },
         mounted() {
             this.getData()
+            window.addEventListener('resize', () => {
+                //clearTimeout(this.timer)  //清零
+                //this.timer = setTimeout(() => {
+                //    //this.table.resize()
+                //    //this.pie.resize()
+                //    //this.chart.resize()
+                //}, 500)
+                console.log('16541654416516')
+            })
         },
         computed: {
             menuitemClasses: function () {
-    
                 return [
                     'menu-item',
                     this.isCollapsed ? 'collapsed-menu' : ''
@@ -217,11 +218,11 @@
         background: rgb(40,40,40);
     }
     .list {
-        /*width: calc(100% - 20px);*/
+        width: calc(100% - 70px);
         margin-left: 15px;
         margin-right: 20px;
         overflow: hidden;
-        height: 35%;
+        height: 40%;
     }
         .list li {
             list-style: none;