Explorar o código

上传答题点修改

namejr %!s(int64=4) %!d(string=hai) anos
pai
achega
a6ca3a14b4
Modificáronse 2 ficheiros con 20 adicións e 13 borrados
  1. 12 5
      EBook.Web/Common/tasklib_book.css
  2. 8 8
      EBook.Web/Common/tasklib_book.js

+ 12 - 5
EBook.Web/Common/tasklib_book.css

@@ -1,12 +1,11 @@
 body {text-align:left;}
 p{word-break: break-word;word-wrap: break-word;clear:both;line-height: 22px;}
 /*作答区域外层*/
-.answer-body {border-radius: 5px;display:inline-block;margin-bottom:-1px;margin-top:8px;margin-bottom: 5px;line-height: 30px;}
+.answer-body {border-radius: 5px;display:inline-block;margin-bottom:-1px;margin-top:8px;margin-bottom: 5px;}
 .answer-body[answer-showanswer='1']{display:inline;}
 .answer-body[data-astatus='0'] {
-    height: 22px;
-    border: 1px solid #6ab7ff;
     margin-bottom: 0px;
+    margin-top: 0px;
 }
 .boxQue .answer-body{
     line-height: 20px;
@@ -29,15 +28,23 @@ p .answer-body:first-child{
 .answer-audio-range span { float:left;margin-left:4px; margin-right:5px;color:#6ab7ff;line-height:19px;font-size:15px;}
 
 /*答题点区域*/
-.answer-point-range { border-radius: 5px;height:22px;display:inline-block;}
+.answer-point-range {display:inline-block;}
 .answer-point-range img {float:left;margin-left:3px;margin-top:3px;width:16px;height:16px;}
 .answer-point-range span { float:left;margin-left:3px; margin-right:7px;color:#6ab7ff;line-height:22px;font-size:16px;}
+.answer-point-range-div{display: block;border: 1px solid #6ab7ff;height: 22px;border-radius: 5px;position: relative;left: 0px;top: 5px;}
+.select-answer[data-astatus='0'] .answer-point-range-div{
+    border: none !important;
+    background:#eaf6ff !important;
+}
+.underlinePart{
+    margin-bottom:10px;
+}
 /*作答内容*/
 .answer-text { margin-left:5px; margin-right:8px;color:#6ab7ff;font-size:16px;word-break:break-word;word-wrap:break-word;display:inline-block;text-indent:0;display:none;border-bottom: 1px solid #979797;margin-bottom:5px;padding-bottom:1px;}
 /*评阅及点击相关样式*/
 .no-answer { color:#ff6600;text-decoration:none;border-bottom: 1px solid #979797;}
 .answer-body .no-answer { display:inline !important;}
-.select-answer{
+.select-answer[data-astatus='1'],.select-answer[data-astatus='2'],.select-answer[data-astatus='3']{
     border: none !important;
     background:#eaf6ff !important;
 }

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

@@ -1398,7 +1398,7 @@ function handleAnswerRange() {
                 break;
             }
         }
-        $(item).prop("outerHTML", "<div class='answer-body' answer-id='" + answerid + "' parent-anid='" + parentId + "' answer-anstext='" + answerText + "' answer-isky='" + isky + "' answer-showanswer='0' data-astatus='0' data-errstatus='0' onclick='ClickRecFunc(" + parentId + ")'><div class='answer-audio-range'><img class='nextpic' src='" + PicInfo.recordPlayImgUrl + "'/><span class='answer-audio-text'>作答音频</span></div><div class='answer-point-range'><img class='nextpic' src='" + PicInfo.answerPointImgUrl + "'/><span class='answer-point-text'>答题点</span></div><buttom class='answer-text'></buttom></div>");
+        $(item).prop("outerHTML", "<div class='answer-body' answer-id='" + answerid + "' parent-anid='" + parentId + "' answer-anstext='" + answerText + "' answer-isky='" + isky + "' answer-showanswer='0' data-astatus='0' data-errstatus='0' onclick='ClickRecFunc(" + parentId + ")'><div class='answer-audio-range'><img class='nextpic' src='" + PicInfo.recordPlayImgUrl + "'/><span class='answer-audio-text'>作答音频</span></div><div class='answer-point-range'><div class='answer-point-range-div'><img class='nextpic' src='" + PicInfo.answerPointImgUrl + "'/><span class='answer-point-text'>答题点</span></div></div><buttom class='answer-text'></buttom></div>");
         //删除钥匙节点
         var prev = $("img[answer-id='" + answerid + "']");
         if (prev.length > 0) {
@@ -1461,7 +1461,7 @@ function reviewAnswer(answerJson) {
         if ((answerObj.Type == 3 || answerObj.Type == 4) && answerObj.AudioUrl != "") {
             $(selectElement).children(".answer-point-range").hide();
             $(selectElement).children(".answer-audio-range").css("display", "inline-block");
-            $(selectElement).children(".answer-audio-range").children("span").text("作答音频(" + answerObj.AudioLength + "s)");
+            $(selectElement).children(".answer-audio-range").eq(0).children("span").text("作答音频(" + answerObj.AudioLength + "s)");
             //填充作答内容
             $(selectElement).attr("answer-text", answerObj.Text);
             if (answerObj.Text != "") {
@@ -1573,10 +1573,10 @@ function getAllAnswer() {
         }
         //mytext = mytext == "" ? "&nbsp;&nbsp;&nbsp;" : mytext;
         if (!isanswer) {
-            $(item).prop("outerHTML", "<div class='answer-body' answer-id='" + answerid + "' parent-anid='" + parentid + "' answer-anstext='" + answerText + "' answer-isky='2' data-astatus='1' data-errstatus='0' onclick='ClickRecFunc(" + parentid + ")'><div class='answer-audio-range'><img class='nextpic' src='" + PicInfo.recordPlayImgUrl + "'/><span class='answer-audio-text'>作答音频</span></div><div class='answer-point-range' style='display:none;'><img class='nextpic' src='" + PicInfo.answerPointImgUrl + "'/><span class='answer-point-text'>答题点</span></div><buttom class='answer-text no-answer' style='display:inline-block;'>" + mytext + "</buttom></div>");
+            $(item).prop("outerHTML", "<div class='answer-body' answer-id='" + answerid + "' parent-anid='" + parentid + "' answer-anstext='" + answerText + "' answer-isky='2' data-astatus='1' data-errstatus='0' onclick='ClickRecFunc(" + parentid + ")'><div class='answer-audio-range'><img class='nextpic' src='" + PicInfo.recordPlayImgUrl + "'/><span class='answer-audio-text'>作答音频</span></div><div class='answer-point-range' style='display:none;'><div class='answer-point-range-div'><img class='nextpic' src='" +PicInfo.answerPointImgUrl + "'/><span class='answer-point-text'>答题点</span></div></div><buttom class='answer-text no-answer' style='display:inline-block;'>" +mytext + "</buttom></div>");
         }
         else {
-            $(item).prop("outerHTML", "<div class='answer-body' answer-id='" + answerid + "' parent-anid='" + parentid + "' answer-anstext='" + answerText + "' answer-isky='2' data-astatus='1' data-errstatus='0' onclick='ClickRecFunc(" + parentid + ")'><div class='answer-audio-range'><img class='nextpic' src='" +PicInfo.recordPlayImgUrl + "'/><span class='answer-audio-text'>作答音频</span></div><div class='answer-point-range' style='display:none;'><img class='nextpic' src='" + PicInfo.answerPointImgUrl + "'/><span class='answer-point-text'>答题点</span></div><buttom class='answer-text' style='display:inline-block;'>" +mytext + "</buttom></div>");
+            $(item).prop("outerHTML", "<div class='answer-body' answer-id='" + answerid + "' parent-anid='" + parentid + "' answer-anstext='" + answerText + "' answer-isky='2' data-astatus='1' data-errstatus='0' onclick='ClickRecFunc(" +parentid + ")'><div class='answer-audio-range'><img class='nextpic' src='" + PicInfo.recordPlayImgUrl + "'/><span class='answer-audio-text'>作答音频</span></div><div class='answer-point-range' style='display:none;'><div class='answer-point-range-div'><img class='nextpic' src='" +PicInfo.answerPointImgUrl + "'/><span class='answer-point-text'>答题点</span></div></div><buttom class='answer-text' style='display:inline-block;'>" + mytext + "</buttom></div>");
         }
         if (mytext == "未作答") {
             $(".answer-body[answer-id='" + answerid + "']").attr("data-errstatus", "1");
@@ -1793,10 +1793,10 @@ function backupAllAnswer(answerJson, statusType) {
                 }
                 //mytext = mytext == "" ? "&nbsp;&nbsp;&nbsp;" : mytext;
                 if (!isanswer) {
-                    $(item).prop("outerHTML", "<div class='answer-body' answer-id='" +answerid + "' parent-anid='" + parentid + "' answer-anstext='" + answerText + "' answer-isky='2' answer-text='" + mytext + "' data-astatus='" +statusType + "' data-errstatus='0' onclick='ClickRecFunc(" +parentid + ")'><div class='answer-audio-range'><img class='nextpic' src='" +PicInfo.recordPlayImgUrl + "'/><span class='answer-audio-text'>作答音频</span></div><div class='answer-point-range' style='display:none;'><img class='nextpic' src='" +PicInfo.answerPointImgUrl + "'/><span class='answer-point-text'>答题点</span></div><buttom class='answer-text no-answer' style='display:inline-block;'>" +mytext + "</buttom></div>");
+                    $(item).prop("outerHTML", "<div class='answer-body' answer-id='" + answerid + "' parent-anid='" + parentid + "' answer-anstext='" + answerText + "' answer-isky='2' answer-text='" + mytext + "' data-astatus='" + statusType + "' data-errstatus='0' onclick='ClickRecFunc(" + parentid + ")'><div class='answer-audio-range'><img class='nextpic' src='" + PicInfo.recordPlayImgUrl + "'/><span class='answer-audio-text'>作答音频</span></div><div class='answer-point-range' style='display:none;'><div class='answer-point-range-div'><img class='nextpic' src='" + PicInfo.answerPointImgUrl + "'/><span class='answer-point-text'>答题点</span></div></div><buttom class='answer-text no-answer' style='display:inline-block;'>" + mytext + "</buttom></div>");
                 }
                 else {
-                    $(item).prop("outerHTML", "<div class='answer-body' answer-id='" + answerid + "' parent-anid='" + parentid + "' answer-anstext='" + answerText + "' answer-isky='2' answer-text='" +mytext + "' data-astatus='" +statusType + "' data-errstatus='0' onclick='ClickRecFunc(" + parentid + ")'><div class='answer-audio-range'><img class='nextpic' src='" +PicInfo.recordPlayImgUrl + "'/><span class='answer-audio-text'>作答音频</span></div><div class='answer-point-range' style='display:none;'><img class='nextpic' src='" +PicInfo.answerPointImgUrl + "'/><span class='answer-point-text'>答题点</span></div><buttom class='answer-text' style='display:inline-block;'>" +mytext + "</buttom></div>");
+                    $(item).prop("outerHTML", "<div class='answer-body' answer-id='" + answerid + "' parent-anid='" + parentid + "' answer-anstext='" + answerText + "' answer-isky='2' answer-text='" + mytext + "' data-astatus='" + statusType + "' data-errstatus='0' onclick='ClickRecFunc(" + parentid + ")'><div class='answer-audio-range'><img class='nextpic' src='" + PicInfo.recordPlayImgUrl + "'/><span class='answer-audio-text'>作答音频</span></div><div class='answer-point-range' style='display:none;'><div class='answer-point-range-div'><img class='nextpic' src='" +PicInfo.answerPointImgUrl + "'/><span class='answer-point-text'>答题点</span></div></div><buttom class='answer-text' style='display:inline-block;'>" +mytext + "</buttom></div>");
                 }
                 if (mytext == "未作答") {
                     $(".answer-body[answer-id='" + answerid + "']").attr("data-errstatus", "1");
@@ -2030,10 +2030,10 @@ function backupAllReview(answerJson) {
             }
             //mytext = mytext == "" ? "&nbsp;&nbsp;&nbsp;" : mytext;
             if (!isanswer) {
-                $(item).prop("outerHTML", "<div class='answer-body' answer-id='" + answerid + "' parent-anid='" + parentid + "' answer-anstext='" + answerText + "' answer-isky='2' answer-text='" + mytext + "' data-astatus='2' data-errstatus='0' onclick='ClickRecFunc(" + parentid + ")'><div class='answer-audio-range'><img class='nextpic' src='" +PicInfo.recordPlayImgUrl + "'/><span class='answer-audio-text'>作答音频</span></div><div class='answer-point-range' style='display:none;'><img class='nextpic' src='" +PicInfo.answerPointImgUrl + "'/><span class='answer-point-text'>答题点</span></div><buttom class='answer-text' style='display:inline-block;'>" +mytext + "</buttom></div>");
+                $(item).prop("outerHTML", "<div class='answer-body' answer-id='" + answerid + "' parent-anid='" + parentid + "' answer-anstext='" + answerText + "' answer-isky='2' answer-text='" + mytext + "' data-astatus='2' data-errstatus='0' onclick='ClickRecFunc(" + parentid + ")'><div class='answer-audio-range'><img class='nextpic' src='" + PicInfo.recordPlayImgUrl + "'/><span class='answer-audio-text'>作答音频</span></div><div class='answer-point-range' style='display:none;'><div class='answer-point-range-div'><img class='nextpic' src='" + PicInfo.answerPointImgUrl + "'/><span class='answer-point-text'>答题点</span></div></div><buttom class='answer-text' style='display:inline-block;'>" + mytext + "</buttom></div>");
             }
             else {
-                $(item).prop("outerHTML", "<div class='answer-body' answer-id='" + answerid + "' parent-anid='" +parentid + "' answer-anstext='" +answerText + "' answer-isky='2' answer-text='" +mytext + "' data-astatus='2' data-errstatus='0' onclick='ClickRecFunc(" +parentid + ")'><div class='answer-audio-range'><img class='nextpic' src='" +PicInfo.recordPlayImgUrl + "'/><span class='answer-audio-text'>作答音频</span></div><div class='answer-point-range' style='display:none;'><img class='nextpic' src='" +PicInfo.answerPointImgUrl + "'/><span class='answer-point-text'>答题点</span></div><buttom class='answer-text no-answer' style='display:inline-block;'>" +mytext + "</buttom></div>");
+                $(item).prop("outerHTML", "<div class='answer-body' answer-id='" + answerid + "' parent-anid='" + parentid + "' answer-anstext='" + answerText + "' answer-isky='2' answer-text='" + mytext + "' data-astatus='2' data-errstatus='0' onclick='ClickRecFunc(" + parentid + ")'><div class='answer-audio-range'><img class='nextpic' src='" + PicInfo.recordPlayImgUrl + "'/><span class='answer-audio-text'>作答音频</span></div><div class='answer-point-range' style='display:none;'><div class='answer-point-range-div'><img class='nextpic' src='" + PicInfo.answerPointImgUrl + "'/><span class='answer-point-text'>答题点</span></div></div><buttom class='answer-text no-answer' style='display:inline-block;'>" + mytext + "</buttom></div>");
             }
             if (mytext == "未作答") {
                 $(".answer-body[answer-id='" + answerid + "']").attr("data-errstatus", "1");