Browse Source

添加answer-boy的样式判断和增加最小宽度

namejr 4 years ago
parent
commit
5c42c58f26
2 changed files with 9 additions and 3 deletions
  1. 1 1
      EBook.Web/Common/tasklib_book.css
  2. 8 2
      EBook.Web/Common/tasklib_book.js

+ 1 - 1
EBook.Web/Common/tasklib_book.css

@@ -84,5 +84,5 @@ p .answer-body:first-child{
     overflow-y:hidden !important;
 }
 .container-table td{
-    min-width:90px;
+    min-width:135px;
 }

+ 8 - 2
EBook.Web/Common/tasklib_book.js

@@ -1019,7 +1019,6 @@ function backupAllAnswer(answerJson, statusType) {
                     recordAudioClick(this, answerList[index].Id, answerList[index].AudioUrl);
                 });
             }
-
             //可作答状态,作答还原
             if (statusType == 0) {
                 //已作答过,还原作答,增加作答后的UI节点
@@ -1055,7 +1054,6 @@ function backupAllAnswer(answerJson, statusType) {
             }
             //已评阅,查看评阅详情
             if (statusType == 2) {
-                $(item).attr("answer-showanswer", "1");  // 修改显示格式
                 //添加音频控制
                 if ((answerList[index].Type == 3 || answerList[index].Type == 4) && answerList[index].AudioUrl != "") {
                     //独立绑定事件
@@ -1084,6 +1082,14 @@ function backupAllAnswer(answerJson, statusType) {
                     $(item).children(".answer-text").addClass("good-answer");
                 }
             }
+            // 添加answer-boy的样式判断
+            var DStatusFlag = $(item).find(".answer-point-range").css("display") != "none";
+            if (DStatusFlag) {
+                $(item).attr("answer-showanswer", "0");  // 修改显示格式
+            }
+            else {
+                $(item).attr("answer-showanswer", "1");  // 修改显示格式
+            }
         });
         //打勾题的还原
         $.each($(".checkbox"), function (num, item) {