(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["subjectEdit"],{"064b":function(t,e,n){},3284:function(t,e,n){"use strict";n.d(e,"b",(function(){return o})),n.d(e,"a",(function(){return r})),n.d(e,"z",(function(){return a})),n.d(e,"i",(function(){return u})),n.d(e,"p",(function(){return c})),n.d(e,"S",(function(){return s})),n.d(e,"o",(function(){return d})),n.d(e,"q",(function(){return f})),n.d(e,"E",(function(){return l})),n.d(e,"F",(function(){return p})),n.d(e,"G",(function(){return m})),n.d(e,"A",(function(){return v})),n.d(e,"D",(function(){return h})),n.d(e,"C",(function(){return g})),n.d(e,"B",(function(){return y})),n.d(e,"N",(function(){return b})),n.d(e,"K",(function(){return w})),n.d(e,"O",(function(){return N})),n.d(e,"M",(function(){return S})),n.d(e,"L",(function(){return F})),n.d(e,"w",(function(){return T})),n.d(e,"y",(function(){return I})),n.d(e,"f",(function(){return _})),n.d(e,"c",(function(){return k})),n.d(e,"h",(function(){return x})),n.d(e,"e",(function(){return A})),n.d(e,"d",(function(){return E})),n.d(e,"n",(function(){return C})),n.d(e,"m",(function(){return M})),n.d(e,"Q",(function(){return L})),n.d(e,"k",(function(){return U})),n.d(e,"T",(function(){return O})),n.d(e,"P",(function(){return V})),n.d(e,"H",(function(){return D})),n.d(e,"j",(function(){return P})),n.d(e,"R",(function(){return R})),n.d(e,"l",(function(){return $})),n.d(e,"I",(function(){return q})),n.d(e,"t",(function(){return Q})),n.d(e,"g",(function(){return j})),n.d(e,"x",(function(){return G})),n.d(e,"v",(function(){return z})),n.d(e,"s",(function(){return J})),n.d(e,"r",(function(){return H})),n.d(e,"J",(function(){return X})),n.d(e,"u",(function(){return Y}));var i=n("284b"),o=function(t){return i["a"].post("/adminv2/miniprogram/videoList",t)},r=function(t){return i["a"].post("/adminv2/miniprogram/addVideoForProgram",t)},a=function(t){return i["a"].post("/adminv2/applet/banner/list",t)},u=function(t){return i["a"].post("/adminv2/applet/banner/add",t)},c=function(t){return i["a"].post("/adminv2/applet/banner/detail",t)},s=function(t){return i["a"].post("/adminv2/applet/banner/update",t)},d=function(t){return i["a"].post("/adminv2/applet/banner/delete",t)},f=function(t){return i["a"].post("/adminv2/applet/banner/enableFlag",t)},l=function(t){return i["a"].post("/adminv2/applet/privateAd/add",t)},p=function(t){return i["a"].post("/adminv2/applet/privateAd/detail",t)},m=function(t){return i["a"].post("/adminv2/applet/privateAd/update",t)},v=function(t){return i["a"].post("/adminv2/applet/liveDesc/add",t)},h=function(t){return i["a"].post("/adminv2/applet/liveDesc/update",t)},g=function(t){return i["a"].post("/adminv2/applet/liveDesc/list",t)},y=function(t){return i["a"].post("/adminv2/applet/liveDesc/delete",t)},b=function(t){return i["a"].post("/adminv2/applet/sharePoster/list",t)},w=function(t){return i["a"].post("/adminv2/applet/sharePoster/add",t)},N=function(t){return i["a"].post("/adminv2/applet/sharePoster/update",t)},S=function(t){return i["a"].post("/adminv2/applet/sharePoster/enableFlag",t)},F=function(t){return i["a"].post("/adminv2/applet/sharePoster/delete",t)},T=function(t){return i["a"].post("/adminv2/applet/liveDesc/getShowSwitch",t)},I=function(t){return i["a"].post("/adminv2/applet/liveDesc/isShowSwitch",t)},_=function(t){return i["a"].post("/adminv2/applet/active/list",t)},k=function(t){return i["a"].post("/adminv2/applet/active/add",t)},x=function(t){return i["a"].post("/adminv2/applet/active/update",t)},A=function(t){return i["a"].post("/adminv2/applet/active/enableFlag",t)},E=function(t){return i["a"].post("/adminv2/applet/active/delete",t)},C=function(t){return i["a"].post("/adminv2/activities/shuihu/commentList",t)},M=function(t){return i["a"].post("/adminv2/activities/shuihu/commentEnableFlag",t)},L=function(t){return i["a"].post("/adminv2/activities/shuihu/topicList",t)},U=function(t){return i["a"].post("/adminv2/activities/shuihu/addTopic",t)},O=function(t){return i["a"].post("/adminv2/activities/shuihu/updateTopic",t)},V=function(t){return i["a"].post("/adminv2/activities/shuihu/topicEnableFlag",t)},D=function(t){return i["a"].post("/adminv2/activities/shuihu/qaList",t)},P=function(t){return i["a"].post("/adminv2/activities/shuihu/addQa",t)},R=function(t){return i["a"].post("/adminv2/activities/shuihu/updateQa",t)},$=function(t){return i["a"].post("/adminv2/activities/shuihu/answerList",t)},q=function(t){return i["a"].post("/adminv2/activities/shuihu/saveAnswer",t)},Q=function(t){return i["a"].post("/adminv2/activities/shuihu/getAnswerInfo",t)},j=function(t){return i["a"].post("/adminv2/activities/shuihu/activeQr",t)},G=function(t){return i["a"].post("/adminv2/activities/shuihu/isShowSwitch",t)},z=function(t){return i["a"].post("/adminv2/activities/shuihu/getShowSwitch",t)},J=function(t){return i["a"].post("/adminv2/activities/shuihu/getActiveQr",t)},H=function(t){return i["a"].post("/adminv2/activities/shuihu/gameList",t)},X=function(t){return i["a"].post("/adminv2/activities/shuihu/saveGame",t)},Y=function(t){return i["a"].post("/adminv2/activities/shuihu/getGameInfo",t)}},"44e7":function(t,e,n){var i=n("861d"),o=n("c6b6"),r=n("b622"),a=r("match");t.exports=function(t){var e;return i(t)&&(void 0!==(e=t[a])?!!e:"RegExp"==o(t))}},5899:function(t,e){t.exports="\t\n\v\f\r                 \u2028\u2029\ufeff"},"58a8":function(t,e,n){var i=n("1d80"),o=n("5899"),r="["+o+"]",a=RegExp("^"+r+r+"*"),u=RegExp(r+r+"*$"),c=function(t){return function(e){var n=String(i(e));return 1&t&&(n=n.replace(a,"")),2&t&&(n=n.replace(u,"")),n}};t.exports={start:c(1),end:c(2),trim:c(3)}},"6fee":function(t,e,n){"use strict";n("064b")},7156:function(t,e,n){var i=n("861d"),o=n("d2bb");t.exports=function(t,e,n){var r,a;return o&&"function"==typeof(r=e.constructor)&&r!==n&&i(a=r.prototype)&&a!==n.prototype&&o(t,a),t}},a9e3:function(t,e,n){"use strict";var i=n("83ab"),o=n("da84"),r=n("94ca"),a=n("6eeb"),u=n("5135"),c=n("c6b6"),s=n("7156"),d=n("c04e"),f=n("d039"),l=n("7c73"),p=n("241c").f,m=n("06cf").f,v=n("9bf2").f,h=n("58a8").trim,g="Number",y=o[g],b=y.prototype,w=c(l(b))==g,N=function(t){var e,n,i,o,r,a,u,c,s=d(t,!1);if("string"==typeof s&&s.length>2)if(s=h(s),e=s.charCodeAt(0),43===e||45===e){if(n=s.charCodeAt(2),88===n||120===n)return NaN}else if(48===e){switch(s.charCodeAt(1)){case 66:case 98:i=2,o=49;break;case 79:case 111:i=8,o=55;break;default:return+s}for(r=s.slice(2),a=r.length,u=0;uo)return NaN;return parseInt(r,i)}return+s};if(r(g,!y(" 0o1")||!y("0b1")||y("+0x1"))){for(var S,F=function(t){var e=arguments.length<1?0:t,n=this;return n instanceof F&&(w?f((function(){b.valueOf.call(n)})):c(n)!=g)?s(new y(N(e)),n,F):N(e)},T=i?p(y):"MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,EPSILON,isFinite,isInteger,isNaN,isSafeInteger,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,parseFloat,parseInt,isInteger,fromString,range".split(","),I=0;T.length>I;I++)u(y,S=T[I])&&!u(F,S)&&v(F,S,m(y,S));F.prototype=b,b.constructor=F,a(o,g,F)}},b0dd:function(t,e,n){"use strict";n.r(e);var i=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"positionT0L0"},[n("div",{staticClass:"top"},[n("a-form",{attrs:{layout:"inline"}},[n("a-form-item",[n("a-button",{staticClass:"margin_right20",attrs:{icon:"plus",type:"primary"},on:{click:function(e){return t.addClick("1")}}},[t._v("添加对话")])],1)],1)],1),n("a-table",{attrs:{columns:t.columns,"data-source":t.tableData,pagination:!1,"row-key":function(t){return t.id},loading:t.tableLoading},scopedSlots:t._u([{key:"direction",fn:function(e,i){return n("span",{},[n("span",[t._v(t._s(1===i.direction?"番茄妈妈":"申老师"))])])}},{key:"contentType",fn:function(e,i){return n("span",{},[1===i.contentType?n("span",[t._v("文字")]):2===i.contentType?n("span",[t._v("音频")]):n("span",[t._v("视频")])])}},{key:"operation",fn:function(e,i){return n("span",{},[n("a",{staticClass:"margin_right10",attrs:{type:"primary"},on:{click:function(e){return t.editClick(i)}}},[t._v("编辑")])])}}])}),n("a-modal",{attrs:{title:t.titleSize},on:{ok:t.handleOk,cancel:t.handleCancel},model:{value:t.visibleShow,callback:function(e){t.visibleShow=e},expression:"visibleShow"}},[t.visibleShow?n("a-form-model",{ref:"ruleForm",attrs:{model:t.form,rules:t.rules}},[n("a-form-model-item",{ref:"direction",attrs:{label:"人物",prop:"direction"}},[n("a-radio-group",{model:{value:t.form.direction,callback:function(e){t.$set(t.form,"direction",e)},expression:"form.direction"}},[n("a-radio",{attrs:{value:1}},[t._v("番茄妈妈")]),n("a-radio",{attrs:{value:2}},[t._v("申老师")])],1)],1),n("a-form-model-item",{ref:"contentType",attrs:{label:"类型",prop:"contentType"}},[n("a-radio-group",{on:{change:t.contentTypeChange},model:{value:t.form.contentType,callback:function(e){t.$set(t.form,"contentType",e)},expression:"form.contentType"}},[n("a-radio",{attrs:{value:1}},[t._v("文字")]),n("a-radio",{attrs:{value:2}},[t._v("音频")]),n("a-radio",{attrs:{value:3}},[t._v("视频")])],1)],1),1===t.form.contentType?n("a-form-model-item",{key:"1",ref:"content",attrs:{label:"内容",prop:"content"}},[n("a-textarea",{attrs:{placeholder:"请输入文字","allow-clear":""},model:{value:t.form.content,callback:function(e){t.$set(t.form,"content",e)},expression:"form.content"}})],1):t._e(),2===t.form.contentType?n("a-form-model-item",{key:"2",ref:"audio",attrs:{label:"音频",prop:"audio"}},[n("QiniuVideoAudio",{attrs:{oldFileName:t.form.audio,type:1,id:"videoUpdate"},on:{videoFn:t.audioFn,changeOldFileName:t.audioName}}),n("div",{staticStyle:{"font-weight":"600","line-height":"20px"}},[t._v("支持mp3 建议文件不超过500M")]),n("span",{directives:[{name:"show",rawName:"v-show",value:t.oldFileNameMp3Show,expression:"oldFileNameMp3Show"}],staticStyle:{color:"#f5222d"}},[t._v("请上传音频")])],1):t._e(),3===t.form.contentType?n("a-form-model-item",{key:"3",ref:"video",attrs:{label:"视频",prop:"video"}},[n("QiniuVideoAudio",{attrs:{oldFileName:t.form.video,type:2,id:"videoUpdate"},on:{videoFn:t.videoFn,changeOldFileName:t.videoName}}),n("div",{staticStyle:{"font-weight":"600","line-height":"20px"}},[t._v("支持mp4 建议文件不超过500M")]),n("span",{directives:[{name:"show",rawName:"v-show",value:t.oldFileNameMp4Show,expression:"oldFileNameMp4Show"}],staticStyle:{color:"#f5222d"}},[t._v("请上传视频")])],1):t._e(),n("a-form-model-item",{ref:"sort",attrs:{label:"排序",prop:"sort"}},[n("a-input-number",{staticStyle:{width:"100%"},attrs:{placeholder:"请输入排序"},model:{value:t.form.sort,callback:function(e){t.$set(t.form,"sort",e)},expression:"form.sort"}})],1)],1):t._e()],1),n("router-view")],1)},o=[],r=n("3284"),a=n("5497"),u={components:{QiniuVideoAudio:a["a"]},created:function(){this.topicId=this.$route.params.id,this.getInitFn()},data:function(){return{topicId:"",visibleShow:!1,tableLoading:!1,oldFileNameMp3Show:!1,oldFileNameMp4Show:!1,titleSize:"",columns:[{title:"人物",dataIndex:"direction",key:"direction",scopedSlots:{customRender:"direction"}},{title:"内容",dataIndex:"content",key:"content"},{title:"内容类型",dataIndex:"contentType",key:"contentType",scopedSlots:{customRender:"contentType"}},{title:"排序",dataIndex:"sort",key:"sort"},{title:"操作",width:"100px",dataIndex:"operation",key:"operation",scopedSlots:{customRender:"operation"}}],tableData:[],form:{id:"",direction:1,contentType:1,sort:"",content:"",fileUrl:"",oldFileVideoName:"",audio:"",video:""},rules:{direction:[{required:!0,message:"请选择人物",trigger:"change"}],contentType:[{required:!0,message:"选择类型",trigger:"change"}],sort:[{required:!0,message:"请输入排序",trigger:"blur"}],content:[{required:!0,message:"请输入内容",trigger:"blur"}],audio:[{required:!0,message:""}],video:[{required:!0,message:""}]}}},methods:{contentTypeChange:function(){this.form.fileUrl="",this.form.content="",this.form.video="",this.form.audio="",this.form.oldFileVideoName="",this.form.oldFileAudioName=""},videoFn:function(t){this.form.fileUrl=t.fileUrl,this.form.video=t.oldFileName},videoName:function(t){this.form.oldFileVideoName=t},audioFn:function(t){this.form.fileUrl=t.fileUrl,this.form.audio=t.oldFileName},audioName:function(t){this.form.oldFileAudioName=t},addClick:function(){this.visibleShow=!0,this.titleSize="新增对话"},editClick:function(t){this.form.id=t.id,this.form.direction=t.direction,this.form.content=t.content,this.form.fileUrl=t.content,this.form.contentType=t.contentType,this.form.sort=t.sort,2==this.form.contentType?this.form.audio=t.content:3==this.form.contentType&&(this.form.video=t.content),this.titleSize="编辑对话",this.visibleShow=!0},getInitFn:function(){var t=this;Object(r["H"])({topicId:1*this.topicId}).then((function(e){e.code;var n=e.data;t.tableLoading=!1,t.tableData=n}))},handleOk:function(){var t=this;2!==t.form.contentType||t.form.audio?(t.oldFileNameMp3Show=!1,3!==t.form.contentType||t.form.video?(t.oldFileNameMp4Show=!1,t.$refs.ruleForm.validate((function(e){e&&(t.form.id?Object(r["R"])({id:t.form.id,direction:t.form.direction,contentType:t.form.contentType,content:1==t.form.contentType?t.form.content:2==t.form.contentType||3==t.form.contentType?t.form.fileUrl:t.form.content,sort:t.form.sort,topicId:1*t.topicId}).then((function(e){var n=e.code,i=e.data;200==n?(t.getInitFn(),t.isNull(),t.visibleShow=!1):t.$message.success(i.msg)})):Object(r["j"])({direction:t.form.direction,contentType:t.form.contentType,content:1==t.form.contentType?t.form.content:2==t.form.contentType||3==t.form.contentType?t.form.fileUrl:t.form.content,sort:t.form.sort,topicId:1*t.topicId}).then((function(e){var n=e.code,i=e.data;200==n?(t.getInitFn(),t.isNull(),t.visibleShow=!1):t.$message.success(i.msg)})))}))):t.oldFileNameMp4Show=!0):t.oldFileNameMp3Show=!0},handleCancel:function(){this.isNull()},isNull:function(){this.form.id="",this.form.direction=1,this.form.content="",this.form.contentType=1,this.form.sort="",this.form.video="",this.form.audio="",this.form.fileUrl="",this.form.oldFileVideoName=""},targetFn:function(){return document.querySelector("#third_Party_order")}}},c=u,s=(n("6fee"),n("2877")),d=Object(s["a"])(c,i,o,!1,null,"2f553ffa",null);e["default"]=d.exports}}]); //# sourceMappingURL=subjectEdit.d0185452.js.map