lsc il y a 5 mois
Parent
commit
9f13b4bdf6
1 fichiers modifiés avec 19 ajouts et 5 suppressions
  1. 19 5
      src/components/pages/aiAddCourse/addCourse.vue

+ 19 - 5
src/components/pages/aiAddCourse/addCourse.vue

@@ -3501,7 +3501,7 @@
                           background: #fff;
                           border-radius: 5px;
                           margin-top: 15px;
-                        " :style="{paddingBottom:pjTemplateArray.indexOf(templateid) == -1?'':'75px'}">
+                        " :style="{paddingBottom: panTaskElist() == 0?'75px':''}">
                         <div v-if="
                           unitJson[unitIndex].easy == 6 ||
                           !unitJson[unitIndex].easy
@@ -4871,7 +4871,7 @@
                               :aiJson="aiJson"
                               @setEvaList="setEvaList"
                               @addCourseBehavior="addCourseBehavior"
-                              v-if="pjTemplateArray.indexOf(templateid) != -1 && pjIndex.indexOf(itemTool.tool[0]) != -1"
+                              v-if="panTaskElist() == 0 && pjIndex.indexOf(itemTool.tool[0]) != -1"
                               :ref="'evalist'+itemTaskIndex+toolIndex"></evaList>
                             </div>
                             <button class="c_pub_button_add pub_btn_tool_img" @click="addToolFun(itemTaskIndex), addCourseBehavior('courseBehavior', `点击学历案-任务${itemTaskIndex + 1}-工具描述-添加按钮`)" style="
@@ -4883,7 +4883,7 @@
                             </button>
                           </div>
                         </div>
-                        <div class="elist_css" v-if="pjTemplateArray.indexOf(templateid) != -1 && panElist(itemTask) > 0">
+                        <div class="elist_css" v-if="panElist(itemTask) > 0">
                           <div class="elist_title">
                             <div style=" display: flex; flex-direction: row; align-items: center; margin: 20px 0; ">
                               <div class="lineTitle clineTitle" style="width: auto">任务评价体系</div>
@@ -4893,7 +4893,7 @@
                             </div>
                           </div>
                         </div>
-                        <div class="elist_css" v-if="!(unitJson[unitJson.length - 1].easy == 4) && pjTemplateArray.indexOf(templateid) == -1"
+                        <div class="elist_css" v-if="panTaskElist() > 0"
                           v-loading="(taskDetailLoading4.indexOf('task-' + itemTaskIndex) !== -1) || (taskGLoading[itemTaskIndex] && taskGLoading[itemTaskIndex][2])" element-loading-text="小可正在努力生成中,请稍等...">
                           <div class="elist_title">
                             <div style="
@@ -7605,6 +7605,20 @@ export default {
         return count;
       };
     },
+    panTaskElist(){
+      return function () {
+        let count = 0;
+        for(var i = 0; i < this.unitJson.length; i++){
+          let _task = this.unitJson[i].chapterInfo[0].taskJson
+          for(var j = 0; j < _task.length; j++){
+            if(_task[j].eList && _task[j].eList.length){
+              count++
+            }
+          }
+        }
+        return count;
+      };
+    },
     dataCheckPan(){
       return function (fileid) {
         for(let i = 0; i < this.infoData.length; i++){
@@ -19675,7 +19689,7 @@ ${this.courseText && this.aiCallBack[0] == 2 ? '注意,优化原有的<参考
             _this.$nextTick(()=>{
               setTimeout(() => {
                 for (var j = 0; j < _task.toolChoose.length; j++) {
-                  if(_this.pjTemplateArray.indexOf(_this.templateid) !=-1 && _this.pjIndex.indexOf(_this.unitJson[0].chapterInfo[0].taskJson[index].toolChoose[j].tool[0]) != -1){
+                  if(_this.panTaskElist() == 0 && _this.pjIndex.indexOf(_this.unitJson[0].chapterInfo[0].taskJson[index].toolChoose[j].tool[0]) != -1){
                     _this.$refs['evalist'+index+j][0].openAiDialog('elist');
                   }
                 }