1 |
- (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-acaabf60"],{"14f7":function(e,t,l){"use strict";var a=l("9a2a"),s=l.n(a);s.a},1749:function(e,t,l){},"2a78":function(e,t,l){"use strict";var a=l("1749"),s=l.n(a);s.a},"558b":function(e,t,l){"use strict";l.r(t);var a=function(){var e=this,t=e.$createElement,l=e._self._c||t;return l("div",{staticClass:"class-template"},[l("div",{staticClass:"template-set"},[1==e.templateType?l("div",{staticClass:"step"},[l("module-title",{attrs:{titleNum:1,titleText:"学生层次划分规则"}}),l("div",{staticClass:"top-select"},[l("div",{staticClass:"drop-down-menu"},[l("span",{staticClass:"c-name"},[e._v(" 学生层次: ")]),l("Select-option",{attrs:{selectType:"1",value:e.selectOption.studentLevel,options:e.selectOption.studentLevelData},on:{"update:value":function(t){return e.$set(e.selectOption,"studentLevel",t)},selectChange:e.changeSelect}})],1),l("div",{staticClass:"drop-down-menu"},[l("span",{staticClass:"c-name"},[e._v(" 划分依据: ")]),l("SelectOption",{attrs:{selectType:"2",value:e.selectOption.rankBase,options:e.selectOption.rankBaseData},on:{"update:value":function(t){return e.$set(e.selectOption,"rankBase",t)},selectChange:e.changeSelect}})],1),l("div",{staticClass:"drop-down-menu"},[l("span",{staticClass:"c-name"},[e._v(" 统计方式: ")]),l("SelectOption",{attrs:{selectType:"3",value:e.selectOption.statistical,options:e.selectOption.statisticData},on:{"update:value":function(t){return e.$set(e.selectOption,"statistical",t)},selectChange:e.changeSelect}})],1)]),l("div",{directives:[{name:"show",rawName:"v-show",value:1!==e.selectOption.studentLevel,expression:"selectOption.studentLevel !== 1"}],staticClass:"step-block division-rules"},[l("el-table",{staticStyle:{width:"100%"},attrs:{border:"",data:e.levelRuleList,"header-cell-style":{background:"#f2f2f2",color:"#606266"}}},[l("el-table-column",{attrs:{prop:"level",label:"学生层次",width:"200"}}),l("el-table-column",{attrs:{label:"划分规则"},scopedSlots:e._u([{key:"default",fn:function(t){return[l("div",{directives:[{name:"show",rawName:"v-show",value:"score"===e.selectOption.rankBase,expression:"selectOption.rankBase === 'score'"}],staticClass:"divide"},[l("span",{staticClass:"c-name"},[e._v("得分率")]),l("el-input",{attrs:{size:"mini",onkeyup:"value=value.replace(/[^\\d]/g,'')",disabled:t.$index==e.levelRuleList.length-1},model:{value:t.row.valueStart.score,callback:function(l){e.$set(t.row.valueStart,"score",e._n(l))},expression:"scope.row.valueStart.score"}}),l("span",[e._v("%")]),l("span",{staticClass:"to"},[e._v("~")]),l("el-input",{attrs:{size:"mini",onkeyup:"value=value.replace(/[^\\d]/g,'')",disabled:0==t.$index},model:{value:t.row.valueEnd.score,callback:function(l){e.$set(t.row.valueEnd,"score",e._n(l))},expression:"scope.row.valueEnd.score"}}),l("span",[e._v("%")])],1),l("div",{directives:[{name:"show",rawName:"v-show",value:"grade"===e.selectOption.rankBase,expression:"selectOption.rankBase === 'grade'"}],staticClass:"divide"},[l("span",{staticClass:"c-name"},[e._v("班级排名")]),l("el-input",{attrs:{size:"mini",onkeyup:"value=value.replace(/[^\\d]/g,'')"},model:{value:t.row.valueStart.grade,callback:function(l){e.$set(t.row.valueStart,"grade",e._n(l))},expression:"scope.row.valueStart.grade"}}),l("span",{staticClass:"to"},[e._v("~")]),l("el-input",{attrs:{size:"mini",onkeyup:"value=value.replace(/[^\\d]/g,'')"},model:{value:t.row.valueEnd.grade,callback:function(l){e.$set(t.row.valueEnd,"grade",e._n(l))},expression:"scope.row.valueEnd.grade"}}),l("span",[e._v("名")])],1)]}}],null,!1,3069432705)})],1)],1)],1):e._e(),l("div",{staticClass:"step"},[l("module-title",{attrs:{titleNum:1==e.templateType?2:1,titleText:"错题推送规则"}}),l("div",{staticClass:"step-block wrong-push"},[l("el-table",{staticStyle:{width:"100%"},attrs:{border:"",data:e.wrongRuleList,"header-cell-style":{background:"#f2f2f2",color:"#606266"}}},[1==e.templateType?l("el-table-column",{attrs:{prop:"level",label:"学生层次",width:"200"}}):e._e(),l("el-table-column",{attrs:{prop:"rule",label:"错题推送(可设置过滤条件,减少学生的错题推送)"},scopedSlots:e._u([{key:"default",fn:function(t){return[l("div",{staticClass:"push-tip"},[l("div",{staticClass:"push-tip-text"},[e._v(" "+e._s(e.textArr[t.$index])+" ")]),l("el-button",{attrs:{type:"text"},on:{click:function(l){return e.pushSet(t.$index,t.row)}}},[e._v("设置")])],1)]}}])})],1),l("set-module",{attrs:{isShow:e.moduleShow,oldData:e.oldModuleData,moduleData:e.moduleData},on:{save:e.handleSave,close:e.handleClose}})],1)],1),l("div",{staticClass:"step"},[l("module-title",{attrs:{titleNum:1==e.templateType?3:2,titleText:"题型方法推送规则"}}),l("div",{staticClass:"step-block type-method"},[l("el-table",{staticStyle:{width:"100%"},attrs:{border:"",data:e.methodRuleList,"header-cell-style":{background:"#f2f2f2",color:"#606266"}}},[1==this.templateType?l("el-table-column",{attrs:{prop:"level",label:"学生层次",width:"200"}}):e._e(),l("el-table-column",{attrs:{label:"题型方法最大推送数量"},scopedSlots:e._u([{key:"default",fn:function(t){return[l("div",{staticClass:"push-select"},[l("SelectOption",{attrs:{value:t.row.methodPushDetail.maxPushNum,options:e.maxPushNum,index:t.$index},on:{"update:value":function(l){return e.$set(t.row.methodPushDetail,"maxPushNum",l)},selectChange:e.pushSelect}})],1)]}}])}),l("el-table-column",{attrs:{label:"每个题型方法推送变式训练题数量"},scopedSlots:e._u([{key:"default",fn:function(t){return[l("div",{staticClass:"push-select"},[l("SelectOption",{attrs:{value:t.row.methodPushDetail.trainPushNum,options:e.trainPushNum,index:t.$index},on:{"update:value":function(l){return e.$set(t.row.methodPushDetail,"trainPushNum",l)},selectChange:e.pushSelect}})],1)]}}])}),l("el-table-column",{attrs:{label:"方法训练题推送难度"},scopedSlots:e._u([{key:"default",fn:function(t){return[l("div",{staticClass:"push-select"},[l("SelectOption",{attrs:{value:t.row.methodPushDetail.trainPushLevel,options:e.trainPushLevel,index:t.$index},on:{"update:value":function(l){return e.$set(t.row.methodPushDetail,"trainPushLevel",l)},selectChange:e.pushSelect}})],1)]}}])})],1)],1)],1),l("div",{staticClass:"step"},[l("module-title",{attrs:{titleNum:1==e.templateType?4:3,titleText:"方法宝排版"}}),l("div",{staticClass:"step-block type-set"},[l("el-table",{staticStyle:{width:"100%"},attrs:{border:"",data:e.typesetList,"header-cell-style":{background:"#f2f2f2",color:"#606266"}}},[l("el-table-column",{attrs:{prop:"title",label:"一级栏目"}}),l("el-table-column",{attrs:{label:"二级栏目"},scopedSlots:e._u([{key:"default",fn:function(t){return e._l(t.row.cellItem,(function(t,a){return l("div",{key:a,staticClass:"show-text"},[e._v(" "+e._s(t.text)+" ")])}))}}])}),l("el-table-column",{attrs:{label:"设置"},scopedSlots:e._u([{key:"default",fn:function(t){return e._l(t.row.cellItem,(function(t,a){return l("div",{key:a,staticClass:"switch-block"},[l("el-switch",{attrs:{"active-color":"#16ae68","inactive-color":"#ddd"},on:{change:function(t){return e.switchStatus()}},model:{value:e.typesetValue[t.name],callback:function(l){e.$set(e.typesetValue,t.name,l)},expression:"typesetValue[item.name]"}})],1)}))}}])})],1)],1)],1),l("div",{staticClass:"save-btn"},[l("el-button",{attrs:{id:"saveSetting"},on:{click:e.SaveSetting}},[e._v(" 保存设置 ")])],1)])])},s=[],n=(l("4160"),l("d81d"),l("159b"),function(){var e=this,t=e.$createElement,l=e._self._c||t;return l("div",{staticClass:"module-title"},[l("i",[e._v(e._s(e.titleNum))]),l("span",[e._v(e._s(e.titleText))])])}),i=[],u=(l("a9e3"),{name:"ModuleTitle",props:{titleNum:Number,titleText:String}}),o=u,r=(l("14f7"),l("2877")),c=Object(r["a"])(o,n,i,!1,null,"90682b1a",null),d=c.exports,p=function(){var e=this,t=e.$createElement,l=e._self._c||t;return l("el-select",{attrs:{size:"mini"},on:{change:e.selectChange},model:{value:e.newValue,callback:function(t){e.newValue=t},expression:"newValue"}},e._l(e.options,(function(e){return l("el-option",{key:e.value,attrs:{label:e.label,value:e.value}})})),1)},v=[],h={name:"SelectOption",props:{value:{type:[String,Number]},selectType:{type:String},options:{type:Array,default:function(){return[]}},index:{type:Number}},data:function(){return{}},computed:{newValue:{set:function(e){this.$emit("update:value",e)},get:function(){return this.value}}},methods:{selectChange:function(e){this.$emit("selectChange",e,this.selectType,this.index)}}},m=h,f=Object(r["a"])(m,p,v,!1,null,null,null),b=f.exports,g=function(){var e=this,t=e.$createElement,l=e._self._c||t;return e.isShow?l("div",{staticClass:"setup-module"},[l("div",{staticClass:"setup-block"},[l("div",{staticClass:"title"},[l("span",[e._v("错题推送规则设置")]),l("i",{staticClass:"close-icon",on:{click:e.sendClose}},[e._v("X")])]),l("div",{staticClass:"content"},e._l(e.moduleData,(function(t,a,s){return l("div",{key:s,staticClass:"item"},[l("span",[e._v(e._s(e.list[s].name))]),"select"==e.list[s].value||"fillInBlank"==e.list[s].value?l("el-radio-group",{model:{value:e.moduleData[e.list[s].value][0],callback:function(t){e.$set(e.moduleData[e.list[s].value],0,t)},expression:"moduleData[list[index].value][0]"}},e._l(e.firstOptions,(function(t,a){return l("el-radio",{key:a,attrs:{label:t.key}},[e._v(e._s(t.value))])})),1):e._e(),"answer"==e.list[s].value||"chooseAnswer"==e.list[s].value?l("el-radio-group",{model:{value:e.moduleData[e.list[s].value][0],callback:function(t){e.$set(e.moduleData[e.list[s].value],0,t)},expression:"moduleData[list[index].value][0]"}},e._l(e.secondOptions,(function(t,a){return l("el-radio",{key:a,attrs:{label:t.key}},[e._v(e._s(t.value))])})),1):e._e(),"difficulty"==e.list[s].value?l("el-checkbox-group",{model:{value:e.moduleData.difficulty,callback:function(t){e.$set(e.moduleData,"difficulty",t)},expression:"moduleData.difficulty"}},e._l(e.checkOption,(function(t,a){return l("el-checkbox",{key:a,attrs:{label:t.key}},[e._v(e._s(t.value))])})),1):e._e()],1)})),0),l("div",{staticClass:"submit"},[l("el-button",{attrs:{id:"saveSetting"},on:{click:e.sendModule}},[e._v(" 保存 ")])],1)])]):e._e()},w=[],y={name:"SetModule",props:{isShow:Boolean,moduleData:Object,oldData:Object},data:function(){return{firstOptions:[{key:"pushLose",value:"扣了分就推"},{key:"pushHalf",value:"扣一半以上分才推"},{key:"pushZero",value:"只推得0分的"},{key:"pushNone",value:"不推"}],secondOptions:[{key:"pushLose",value:"扣了分就推"},{key:"pushThree",value:"扣3分以上才推"},{key:"pushHalf",value:"扣一半以上分才推"},{key:"pushNone",value:"不推"}],checkOption:[{key:1,value:"推基础题"},{key:2,value:"推中档题"},{key:3,value:"推培优题"}]}},computed:{list:function(){return[{name:"选择题",value:"select"},{name:"填空题",value:"fillInBlank"},{name:"解答题",value:"answer"},{name:"其他题型",value:"chooseAnswer"},{name:"错题难度",value:"difficulty"}]}},methods:{sendModule:function(){this.$emit("save",this.moduleData)},sendClose:function(){this.$emit("close",this.oldData)}}},S=y,k=(l("2a78"),Object(r["a"])(S,g,w,!1,null,"216d3aea",null)),D=k.exports,L=l("6593"),x=l("7660"),C={name:"SetTemplate",components:{ModuleTitle:d,SelectOption:b,SetModule:D},filters:{},props:{},data:function(){return{templateId:this.$route.query.id,templateType:this.$route.query.target_type,selectOption:{studentLevel:3,rankBase:"score",statistical:"currentAchieve",studentLevelData:[{value:1,label:"不分层"},{value:2,label:"分为AB两层"},{value:3,label:"分为ABC三层"},{value:4,label:"分为ABCD四层"},{value:5,label:"分为ABCDE五层"},{value:6,label:"分为ABCDEF六层"}],rankBaseData:[{value:"score",label:"按得分率"},{value:"grade",label:"按班级排名"}],statisticData:[{value:"currentAchieve",label:"本次考试成绩"},{value:"latelyThreeAchieve",label:"最近3场考试平均成绩"},{value:"latelyFiveAchieve",label:"最近5场考试平均成绩"}]},levelRuleList:[],wrongRuleList:[],textValue:{pushNone:"不推",pushLose:"扣了分就推",pushZero:"只推得0分",pushThree:"扣3分以上才推",pushHalf:"扣一半以上分才推",0:"",1:"推基础题",2:"推中档题",3:"推培优题"},textArr:[],wrongRuleValue:{select:["pushLose"],fillInBlank:["pushLose"],answer:["pushLose"],chooseAnswer:["pushLose"],difficulty:[1,2,3]},moduleData:{},oldModuleData:{},moduleShow:!1,methodRuleList:[],methodRuleValue:{maxPushNum:1,trainPushNum:1,trainPushLevel:1},maxPushNum:[{value:1,label:"1个"},{value:2,label:"2个"},{value:3,label:"3个"},{value:4,label:"4个"},{value:5,label:"5个"},{value:6,label:"6个"},{value:7,label:"7个"},{value:8,label:"8个"}],trainPushNum:[{value:1,label:"1配1"},{value:2,label:"1配2"}],trainPushLevel:[{value:1,label:"难度从高到低"},{value:2,label:"难度从中到高"},{value:3,label:"难度从中到低"},{value:4,label:"难度从低到高"}],typesetList:[{title:"第一部分 学情分析",cellItem:[{text:"显示【得分明细】",name:"hasScoreDetail"},{text:"显示【题型得分】",name:"questionTypeScore"},{text:"显示【二维码】",name:"qrCode"},{text:"显示【小贴士】",name:"hasTips"},{text:"显示【方法分析】",name:"methodAnalysis"},{text:"显示【诊断解读】",name:"diagnosticInterpretation"}]},{title:"第二部分 共性问题",cellItem:[{text:"显示【共性问题】整个模块",name:"commonProblemsAll"},{text:"显示【试卷题文】和【你的答案】",name:"commonPaperTitleAnswer"}]},{title:"第三部分 错题整理",cellItem:[{text:"显示【错题整理】整个模块",name:"wrongArrangementOfWrongQuestionsAll"},{text:"显示 【试卷题文】和【你的答案】",name:"wrongPaperTitleAnswer"},{text:"显示【自我订正】",name:"wrongHasCorrection"}]},{title:"第四部分 方法训练",cellItem:[{text:"显示【方法训练】",name:"methodTrainingAll"}]}],typesetValue:{hasScoreDetail:!0,questionTypeScore:!0,qrCode:!0,hasTips:!0,methodAnalysis:!0,diagnosticInterpretation:!0,commonProblemsAll:!0,commonPaperTitleAnswer:!0,wrongArrangementOfWrongQuestionsAll:!0,wrongPaperTitleAnswer:!0,wrongHasCorrection:!0,methodTrainingAll:!0,mergeDownload:!0}}},computed:{},watch:{wrongRuleList:{deep:!0,handler:function(e){var t=this;e&&e.forEach((function(e,l){var a="",s="",n="",i="",u="",o="",r="";for(var c in e.errorPushDetail)"select"==c?e.errorPushDetail[c].forEach((function(e){a="选择题:".concat(t.textValue[e],";")})):"fillInBlank"==c?e.errorPushDetail[c].forEach((function(e){s="填空题:".concat(t.textValue[e],";")})):"answer"==c?e.errorPushDetail[c].forEach((function(e){i="解答题:".concat(t.textValue[e],";")})):"chooseAnswer"==c?e.errorPushDetail[c].forEach((function(e){n="选做题:".concat(t.textValue[e],";")})):"difficulty"==c&&(0!=e.errorPushDetail[c].length&&(o="错题难度:"),e.errorPushDetail[c].forEach((function(e){u+="".concat(t.textValue[e],",")})));r=a+s+i+n+o+u,r=r.substr(0,r.length-1),t.$set(t.textArr,l,r)}))}}},created:function(){this.getTemplateData(),1==this.templateType&&this.typesetList.push({title:"第五部分 答案部分",cellItem:[{text:"题目答案合并下载",name:"mergeDownload"}]})},mounted:function(){},methods:{getTemplateData:function(){var e=this,t={id:this.templateId},l=Object(x["c"])(t);Object(L["d"])(l).then((function(t){var l=JSON.parse(t.data.config_text);e.selectOption.studentLevel=l.studentLevelDivide.studentLevel,e.selectOption.rankBase=l.studentLevelDivide.rankBase,e.selectOption.statistical=l.studentLevelDivide.statisticsMethods,e.levelRuleList=l.studentLevelDivide.levelDetails.map((function(e){return{level:e.level,valueEnd:e.valueEnd,valueStart:e.valueStart}})),e.wrongRuleList=l.studentLevelDivide.levelDetails.map((function(e){return{level:e.level,errorPushDetail:e.errorPushDetail}})),e.methodRuleList=l.studentLevelDivide.levelDetails.map((function(e){return{level:e.level,methodPushDetail:e.methodPushDetail}})),e.typesetValue=l.errorTypeSetting}))},changeSelect:function(e,t){switch(t){case"1":this.selectOption.studentLevel=e,this.levelRuleList=this.addLevelList(e).levelRuleList,this.wrongRuleList=this.addLevelList(e).wrongRuleList,this.methodRuleList=this.addLevelList(e).methodRuleList;break;case"2":this.selectOption.rankBase=e;break;case"3":this.selectOption.statisticsMethods=e;break}},addLevelList:function(e){for(var t={levelRuleList:[],wrongRuleList:[],methodRuleList:[]},l=0;l<e;l++){var a={};a.level=String.fromCharCode(65+l),a.valueStart={score:0,grade:0},a.valueEnd={score:0,grade:0};var s={};s.level=String.fromCharCode(65+l),s.errorPushDetail=JSON.parse(JSON.stringify(this.wrongRuleValue));var n={};n.level=String.fromCharCode(65+l),n.methodPushDetail=JSON.parse(JSON.stringify(this.methodRuleValue)),t.levelRuleList.push(a),t.levelRuleList[0].valueEnd.score=100,t.wrongRuleList.push(s),t.methodRuleList.push(n)}return t},pushSet:function(e,t){this.moduleShow=!0,this.setIndex=e,this.moduleData=t.errorPushDetail,this.oldModuleData=JSON.parse(JSON.stringify(t.errorPushDetail))},handleSave:function(e){this.moduleShow=!this.moduleShow,this.$set(this.wrongRuleList[this.setIndex],"errorPushDetail",e)},handleClose:function(e){this.moduleShow=!this.moduleShow,this.$set(this.wrongRuleList[this.setIndex],"errorPushDetail",e)},pushSelect:function(e,t,l){},switchStatus:function(){},SaveSetting:function(){var e=this,t=[],l=null;if(1==this.templateType){for(var a=0;a<this.selectOption.studentLevel;a++){var s={};s.level=this.levelRuleList[a].level,s.valueEnd=this.levelRuleList[a].valueEnd,s.valueStart=this.levelRuleList[a].valueStart,s.errorPushDetail=this.wrongRuleList[a].errorPushDetail,s.methodPushDetail=this.methodRuleList[a].methodPushDetail,t.push(s)}l={studentLevelDivide:{studentLevel:this.selectOption.studentLevel,rankBase:this.selectOption.rankBase,statisticsMethods:this.selectOption.statistical,levelDetails:t}},l.errorTypeSetting=this.typesetValue}else{for(var n=0;n<this.wrongRuleList.length;n++){var i={};i.errorPushDetail=this.wrongRuleList[n].errorPushDetail,i.methodPushDetail=this.methodRuleList[n].methodPushDetail,t.push(i)}l={studentLevelDivide:{levelDetails:t}},l.errorTypeSetting=this.typesetValue}var u={config:JSON.stringify(l),id:this.templateId},o=Object(x["c"])(u);Object(L["l"])(o).then((function(t){1===t.status?e.$alert("操作成功!","信息",{confirmButtonText:"确定",callback:function(){e.$router.push("TemplateCenter")}}):e.$message.error(t.msg)}))}}},_=C,O=(l("6338"),Object(r["a"])(_,a,s,!1,null,"fdf14c52",null));t["default"]=O.exports},6338:function(e,t,l){"use strict";var a=l("7b5c"),s=l.n(a);s.a},6593:function(e,t,l){"use strict";l.d(t,"e",(function(){return s})),l.d(t,"b",(function(){return n})),l.d(t,"o",(function(){return i})),l.d(t,"m",(function(){return u})),l.d(t,"n",(function(){return o})),l.d(t,"d",(function(){return r})),l.d(t,"l",(function(){return c})),l.d(t,"a",(function(){return d})),l.d(t,"f",(function(){return p})),l.d(t,"h",(function(){return v})),l.d(t,"j",(function(){return h})),l.d(t,"g",(function(){return m})),l.d(t,"i",(function(){return f})),l.d(t,"c",(function(){return b})),l.d(t,"k",(function(){return g}));var a=l("c1fb");function s(e){return a["a"].post("/productMethod/getTemplateByType",e)}var n=function(e){return a["a"].post("/productMethod/copyTemplate",e)},i=function(e){return a["a"].post("/productMethod/reNameTemplate",e)},u=function(e){return a["a"].post("/productMethod/beforeDelTemplate",e)},o=function(e){return a["a"].post("/productMethod/delTemplate",e)},r=function(e){return a["a"].post("/productMethod/ajaxGetTemplateById",e)},c=function(e){return a["a"].post("/productMethod/saveTemplate",e)};function d(e){return a["a"].post("/productMethod/getClassByGrade",e)}function p(e){return a["a"].post("/productMethod/productClassSet",e)}function v(e){return a["a"].post("/productMethod/resetClassSet",e)}var h=function(e){return a["a"].post("/productMethod/saveClassSet",e)};function m(e){return a["a"].post("/productMethod/productStudentSet",e)}function f(e){return a["a"].post("/productMethod/resetStudentSet",e)}var b=function(e){return a["a"].post("/studentinfo/getStudent",e)},g=function(e){return a["a"].post("/productMethod/saveStudentSet",e)}},"7b5c":function(e,t,l){},"9a2a":function(e,t,l){},d81d:function(e,t,l){"use strict";var a=l("23e7"),s=l("b727").map,n=l("1dde"),i=l("ae40"),u=n("map"),o=i("map");a({target:"Array",proto:!0,forced:!u||!o},{map:function(e){return s(this,e,arguments.length>1?arguments[1]:void 0)}})}}]);
|