|
12345678910111213141516171819202122232425262728293031323334 |
- $(function() {
- // outerHeight(true) 高度为 height+margin+padding+border
- var parameter = $(".section_2_html_root").data("page-params");
- console.log("section_2:parameter", parameter);
-
- var sectionsHtmlArr = [
- "section_2_class_all",
- "section_2_class_single",
- "section_2_level",
- "section_2_part",
- "section_2_lin_rank",
- "section_2_lin_score",
- "section_2_excellent"
- ];
- $(".score_analysis_root").html(sectionsHtmlArr.map(function (htmlName) {
- return "<div class='" + htmlName + "_html_root'></div>";
- }).join(""));
- sectionsHtmlArr.forEach(function(htmlName) {
- if (htmlName === "preface") {
- $("." + htmlName + "_html_root").data("page-params", JSON.stringify({
- htmlName: htmlName,
- subjectname: "语文",
- num: 12
- }));
- } else if (htmlName === "section_1") {
- $("." + htmlName + "_html_root").data("page-params", JSON.stringify({
- htmlName: htmlName,
- subjectname: "数学",
- num: 33
- }));
- }
- $("." + htmlName + "_html_root").load("./sections/scoreAnalysis/" + htmlName + ".html");
- });
- });
|