addCourse.vue 146 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794479547964797479847994800480148024803480448054806480748084809481048114812481348144815481648174818481948204821482248234824482548264827482848294830483148324833483448354836483748384839484048414842484348444845484648474848484948504851485248534854485548564857485848594860486148624863486448654866486748684869487048714872487348744875487648774878487948804881488248834884488548864887488848894890489148924893489448954896489748984899490049014902490349044905490649074908490949104911
  1. <template>
  2. <div class="pb_content">
  3. <div class="pb_content_body" style="position: relative">
  4. <div class="right">
  5. <div
  6. style="
  7. display: flex;
  8. flex-direction: row;
  9. justify-content: flex-start;
  10. align-items: center;
  11. width: 100%;
  12. background: #fff;
  13. border-radius: 10px;
  14. "
  15. >
  16. <div
  17. style="
  18. display: flex;
  19. flex-direction: row;
  20. justify-content: flex-start;
  21. align-items: center;
  22. border-radius: 80px;
  23. box-shadow: 0px 1px 2px 3px #f2f2f2;
  24. margin: 30px 20px 20px 45px;
  25. min-width: 420px;
  26. "
  27. >
  28. <h3 class="info_title" v-if="steps == 1">课程内容填写</h3>
  29. <h3 class="info_title" v-if="steps == 2">请选择课程框架</h3>
  30. <h3 class="info_title" v-if="steps == 3">课程内容填写</h3>
  31. <h3 class="info_title" v-if="steps == 4">上传课程</h3>
  32. <el-breadcrumb
  33. separator-class="el-icon-arrow-right"
  34. style="margin-top: 15px"
  35. >
  36. <el-breadcrumb-item
  37. :to="{ path: '/course?userid=' + userid + '&oid=' + oid }"
  38. >课程管理</el-breadcrumb-item
  39. >
  40. <el-breadcrumb-item>添加课程</el-breadcrumb-item>
  41. </el-breadcrumb>
  42. </div>
  43. <div
  44. v-if="steps == 1 || steps == 2 || steps == 3"
  45. style="
  46. font-size: 25px;
  47. color: #dedede;
  48. font-weight: bold;
  49. margin-left: auto;
  50. margin-right: 2%;
  51. "
  52. >
  53. {{
  54. steps == 1
  55. ? "第一步"
  56. : steps == 2
  57. ? "第二步"
  58. : steps == 3
  59. ? "第三步"
  60. : ""
  61. }}
  62. </div>
  63. </div>
  64. <div style="display: flex; margin-top: 20px">
  65. <div class="stepBg" :class="steps == 3 ? 'isHeight' : ''">
  66. <div v-if="steps == 1" class="first" @click="navSteps(1)">
  67. <div>
  68. <img src="../../assets/icon/first.png" alt />
  69. </div>
  70. <div>填写基本信息</div>
  71. </div>
  72. <div v-else class="firstNo" @click="navSteps(1)">
  73. <div>
  74. <img src="../../assets/icon/firstNo.png" alt />
  75. </div>
  76. <div>填写基本信息</div>
  77. </div>
  78. <div v-show="cid == ''" class="secondNo">
  79. <div
  80. v-if="steps == 2"
  81. class="newSteps second"
  82. @click="navSteps(2)"
  83. >
  84. <div style="margin: 5px 10px 0 0; width: 2rem">
  85. <img src="../../assets/icon/second.png" alt />
  86. </div>
  87. <div>选择课程框架</div>
  88. </div>
  89. <div v-else class="newSteps secondNo" @click="navSteps(2)">
  90. <div>
  91. <img src="../../assets/icon/secondNo.png" alt />
  92. </div>
  93. <div>选择课程框架</div>
  94. </div>
  95. </div>
  96. <div v-if="steps == 3" class="third" @click="navSteps(3)">
  97. <div>
  98. <img src="../../assets/icon/third.png" alt />
  99. </div>
  100. <div>上传课程内容</div>
  101. </div>
  102. <div v-else class="thirdNo" @click="navSteps(3)">
  103. <div>
  104. <img src="../../assets/icon/thirdNo.png" alt />
  105. </div>
  106. <div>上传课程内容</div>
  107. </div>
  108. <div v-if="steps == 4" class="four">
  109. <div>
  110. <img src="../../assets/icon/four.png" alt />
  111. </div>
  112. <div>上传完成</div>
  113. </div>
  114. <div v-else class="fourNo">
  115. <div>
  116. <img src="../../assets/icon/fourNo.png" alt />
  117. </div>
  118. <div>上传完成</div>
  119. </div>
  120. </div>
  121. <div
  122. style="
  123. width: calc(100% - 17% - 25px);
  124. background: #fff;
  125. border-radius: 10px;
  126. min-height: 550px;
  127. min-width: 800px;
  128. "
  129. v-if="this.steps == 1"
  130. >
  131. <div class="whiteBg">
  132. <div class="right_title">课程基本信息</div>
  133. <div class="basic_box">
  134. <div class="big_box">
  135. <div class="left_first">
  136. <div>
  137. <div>
  138. <div class="bInfo_title" style="margin-bottom: 15px">
  139. <span style="color: red">*</span>课程名称
  140. </div>
  141. <div style="display: flex">
  142. <img
  143. src="../../assets/icon/projectName.png"
  144. alt
  145. style="margin-right: 8px"
  146. />
  147. <input
  148. type="text"
  149. placeholder="请输入课程名称"
  150. class="binfo_input"
  151. v-model="courseName"
  152. />
  153. </div>
  154. </div>
  155. <div class="both">
  156. <div class="choose">
  157. <div
  158. class="all_choose"
  159. v-for="(item, index) in CourseType[0]"
  160. :key="index"
  161. >
  162. <span>{{ item.name }}</span>
  163. <el-checkbox-group v-model="courseTypeId">
  164. <el-checkbox
  165. v-for="item1 in CourseTypeJson[item.id]"
  166. :key="item1.id"
  167. :label="item1.id"
  168. >{{ item1.name }}</el-checkbox
  169. >
  170. </el-checkbox-group>
  171. </div>
  172. </div>
  173. </div>
  174. </div>
  175. </div>
  176. </div>
  177. </div>
  178. </div>
  179. <div class="whiteBg" style="border-radius: 0">
  180. <div class="right_first">
  181. <div class="right_title">上传封面与成员</div>
  182. <div
  183. style="
  184. padding: 0 0 50px 0;
  185. display: flex;
  186. align-items: baseline;
  187. justify-content: flex-start;
  188. "
  189. >
  190. <div style="margin: 45px 0px 0px 80px">
  191. <div class="bInfo_title" style="margin-top: 0 !important">
  192. 课程封面
  193. </div>
  194. <el-upload
  195. :class="{ disUoloadSty: noneBtnImg }"
  196. class="upCss"
  197. action="#"
  198. list-type="picture"
  199. v-loading="uploadLoading1"
  200. :http-request="beforeUpload1"
  201. ref="upload1"
  202. :on-preview="handlePictureCardPreview"
  203. :on-remove="handle_remove1"
  204. :show-file-list="true"
  205. :file-list="cover"
  206. accept="image/*"
  207. :limit="1"
  208. :on-exceed="onExceed"
  209. >
  210. <i class="el-icon-plus"></i>
  211. </el-upload>
  212. </div>
  213. <div
  214. style="
  215. display: flex;
  216. flex-flow: row nowrap;
  217. flex-direction: row;
  218. align-items: baseline; ;
  219. "
  220. >
  221. <!-- <div style="margin: 0 80px">
  222. <div class="bInfo_title">
  223. 选择课程成员
  224. </div>
  225. <div
  226. class="addPeople"
  227. @click="addPP"
  228. v-if="this.checkboxList.length == 0"
  229. >添加成员</div>
  230. <div class="addPeople" @click="addPP" v-else>已添加,点击查看</div>
  231. </div>-->
  232. <div style="flex: 0.5 1 0%; margin: 30px 80px 0">
  233. <div class="bInfo_title">协同编辑</div>
  234. <div
  235. class="addPeople"
  236. @click="isNoFinsh"
  237. style="background: #6b92c9"
  238. >
  239. 添加协同成员
  240. </div>
  241. </div>
  242. </div>
  243. </div>
  244. </div>
  245. </div>
  246. <div class="whiteBg" style="border-radius: 0; margin-top: 15px">
  247. <div class="right_title">课程简要描述</div>
  248. <div style="width: 55%; padding: 10px 0 10px 80px">
  249. <!-- <div class="bInfo_title">
  250. <span style="color: red">*</span>简要描述
  251. </div>-->
  252. <div>
  253. <textarea
  254. rows="8"
  255. class="binfo_input"
  256. cols
  257. v-model="courseText"
  258. ></textarea>
  259. </div>
  260. </div>
  261. <el-switch
  262. v-model="isTeacherSee"
  263. active-text="允许给其他老师查看"
  264. style="margin: 30px 0px 10px 110px; padding-bottom: 30px"
  265. ></el-switch>
  266. </div>
  267. </div>
  268. <div
  269. style="
  270. width: calc(100% - 17% - 25px);
  271. background: #fff;
  272. border-radius: 10px;
  273. min-height: 550px;
  274. min-width: 800px;
  275. "
  276. v-if="this.steps == 2"
  277. >
  278. <div class="basic_box" style="margin: 20px 30px 0 !important">
  279. <div
  280. style="
  281. color: #b8b8b8;
  282. background: #fff;
  283. width: 26%;
  284. height: 40px;
  285. border-radius: 15px;
  286. padding-left: 20px;
  287. line-height: 40px;
  288. font-size: 17px;
  289. box-shadow: 0px 1px 2px 2px #e0e0e0;
  290. "
  291. >
  292. 请选择合适的课程模板
  293. </div>
  294. <div class="wordbox">
  295. <div
  296. class="wordTeacher"
  297. v-for="(aa, indexF) in templateArray"
  298. :key="indexF"
  299. @click="checkTemplate(aa)"
  300. >
  301. <div class="wordPic">
  302. <img src="../../assets/icon/wordMub.png" alt />
  303. </div>
  304. <div
  305. style="
  306. margin-top: 10px;
  307. line-height: 19px;
  308. overflow: hidden;
  309. text-overflow: ellipsis;
  310. white-space: nowrap;
  311. padding: 0 20px;
  312. "
  313. >
  314. {{ aa.title }}
  315. </div>
  316. <!-- <div class="checkword">
  317. <img
  318. src="../../assets/icon/checked.png"
  319. alt
  320. v-if="clearArray.indexOf(aa.id) == 0"
  321. />
  322. <img src="../../assets/icon/check.png" alt v-else />
  323. </div>-->
  324. </div>
  325. <div class="wordTeacher" @click="checkTemplate2()">
  326. <div class="wordPic">
  327. <img src="../../assets/icon/wordMub.png" alt />
  328. </div>
  329. <div
  330. style="
  331. margin-top: 10px;
  332. line-height: 19px;
  333. overflow: hidden;
  334. text-overflow: ellipsis;
  335. white-space: nowrap;
  336. padding: 0 20px;
  337. "
  338. >
  339. 新建课程
  340. </div>
  341. <!-- <div class="checkword">
  342. <img src="../../assets/icon/check.png" alt />
  343. </div>-->
  344. </div>
  345. <div class="wordTeacher" @click="checkTemplate1()">
  346. <div class="wordPic">
  347. <img src="../../assets/icon/wordMub.png" alt />
  348. </div>
  349. <div
  350. style="
  351. margin-top: 10px;
  352. line-height: 19px;
  353. overflow: hidden;
  354. text-overflow: ellipsis;
  355. white-space: nowrap;
  356. padding: 0 20px;
  357. "
  358. >
  359. 我的课程
  360. </div>
  361. <!-- <div class="checkword">
  362. <img
  363. src="../../assets/icon/checked.png"
  364. alt
  365. v-if="
  366. clearArray.length == 0
  367. "
  368. />
  369. <img src="../../assets/icon/check.png" alt v-else />
  370. </div>-->
  371. </div>
  372. </div>
  373. </div>
  374. </div>
  375. <div
  376. style="
  377. width: calc(100% - 17% - 25px);
  378. background: #fff;
  379. border-radius: 10px;
  380. min-height: 550px;
  381. min-width: 800px;
  382. "
  383. v-if="this.steps == 3"
  384. >
  385. <div class="basic_box" style="margin: 0px 0 0 30px">
  386. <div
  387. style="display: flex; flex-direction: row; align-items: center"
  388. >
  389. <div class="cru_selectBox">
  390. <div
  391. v-for="(item, index) in unitJson"
  392. :key="index"
  393. class="cru_select"
  394. :class="unitIndex == index ? 'cru_selected' : ''"
  395. @click="unitSet(index)"
  396. >
  397. 第{{ index + 1 }}阶段
  398. </div>
  399. <img
  400. src="../../assets/line.png"
  401. class="cru_line"
  402. :style="{
  403. left: offsetLetfPx + 'px',
  404. }"
  405. />
  406. </div>
  407. <div class="addStageImg" @click="addunit()">
  408. <img src="../../assets/icon/add.png" alt />
  409. </div>
  410. </div>
  411. <div
  412. style="margin: 0 0 40px 0"
  413. v-for="(item, index) in unitJson[unitIndex].chapterInfo"
  414. :key="index"
  415. >
  416. <div>
  417. <div class="chapter_contentbox">
  418. <div>第{{ unitIndex + 1 }}阶段</div>
  419. <div>
  420. <input
  421. type="text"
  422. placeholder="阶段标题"
  423. class="binfo_input"
  424. v-model="unitJson[unitIndex].dyName"
  425. />
  426. </div>
  427. <div
  428. v-if="unitJson.length > 1"
  429. @click="deleteUnit(unitIndex)"
  430. ></div>
  431. </div>
  432. </div>
  433. <div style="margin: 50px 0 10px 0; font-size: 24px">
  434. 添加任务
  435. </div>
  436. <div
  437. class="taskBorder"
  438. v-for="(itemTask, itemTaskIndex) in item.taskJson"
  439. :key="itemTaskIndex"
  440. >
  441. <div>
  442. <div>
  443. <!-- <div
  444. style="
  445. font-weight: unset;
  446. font-size: 1.3rem;
  447. width: 110px;
  448. color: #b7b7b7;
  449. "
  450. >
  451. 任务 {{ itemTaskIndex + 1 }}
  452. </div>-->
  453. <div
  454. class="chapter_contentbox"
  455. style="
  456. flex-direction: row;
  457. justify-content: flex-start;
  458. align-items: center;
  459. "
  460. >
  461. <div
  462. style="
  463. font-weight: unset;
  464. font-size: 1.5em;
  465. font-weight: 700;
  466. width: 110px;
  467. "
  468. >
  469. 任务名称
  470. </div>
  471. <div>
  472. <input
  473. type="text"
  474. placeholder="输入任务名称"
  475. class="binfo_input"
  476. style="height: 50px; border-radius: 4px"
  477. v-model="
  478. unitJson[unitIndex].chapterInfo[0].taskJson[
  479. itemTaskIndex
  480. ].task
  481. "
  482. />
  483. </div>
  484. <div
  485. class="remove"
  486. v-if="item.taskJson.length > 1"
  487. @click="deleteTask(itemTaskIndex)"
  488. style="position: absolute; right: 55px"
  489. ></div>
  490. </div>
  491. <!-- <div style="margin: 30px 0 10px; font-size: 16px">任务描述</div> -->
  492. <div
  493. style="
  494. display: flex;
  495. margin: 0 0 20px 0;
  496. flex-direction: row;
  497. justify-content: flex-start;
  498. align-items: center;
  499. width: 70.5% !important;
  500. padding-top: 30px;
  501. "
  502. >
  503. <div
  504. style="
  505. font-size: 1.5em;
  506. font-weight: bold;
  507. margin-top: 15px;
  508. width: 110px;
  509. min-width: 110px;
  510. "
  511. >
  512. 任务描述
  513. </div>
  514. <div class="line"></div>
  515. </div>
  516. <div>
  517. <textarea
  518. rows="6"
  519. class="binfo_input"
  520. placeholder="请输入任务描述"
  521. cols
  522. style="width: 70.5% !important; height: 120px"
  523. v-model="
  524. unitJson[unitIndex].chapterInfo[0].taskJson[
  525. itemTaskIndex
  526. ].taskDetail
  527. "
  528. ></textarea>
  529. </div>
  530. </div>
  531. </div>
  532. <div
  533. class="basic_box"
  534. style="
  535. margin: 0;
  536. min-height: 0;
  537. width: 66% !important;
  538. paddint-top: 10px !important;
  539. "
  540. >
  541. <div
  542. style="
  543. display: flex;
  544. margin: 0 0 20px 0;
  545. flex-direction: row;
  546. justify-content: flex-start;
  547. align-items: center;
  548. "
  549. >
  550. <div
  551. style="
  552. font-size: 1.5em;
  553. font-weight: bold;
  554. margin-top: 15px;
  555. width: 110px;
  556. min-width: 110px;
  557. "
  558. >
  559. 学习内容
  560. </div>
  561. <div class="line"></div>
  562. </div>
  563. <div>
  564. <div
  565. class="add_chapters_box"
  566. v-if="
  567. itemTask.chapterData &&
  568. itemTask.chapterData.length == 0
  569. "
  570. style="height: 185px"
  571. ></div>
  572. <div
  573. v-else
  574. class="add_chapters_box"
  575. style="display: flex; flex-direction: column"
  576. >
  577. <div
  578. class="chapter_upload"
  579. v-for="(item1, index1) in itemTask.chapterData"
  580. :key="item1.id"
  581. @click="
  582. getChapterData(
  583. $event,
  584. unitIndex,
  585. index,
  586. index1,
  587. item1.type
  588. )
  589. "
  590. >
  591. <div
  592. class="chapter_upload_t"
  593. style="width: 100%"
  594. ></div>
  595. <div
  596. class="chapter_upload_o"
  597. style="
  598. position: relative;
  599. display: flex;
  600. align-items: center;
  601. "
  602. >
  603. <div
  604. class="chapter_upload_l"
  605. style="padding: 1px 0 0 10px"
  606. >
  607. <div
  608. v-if="item1.type == 2"
  609. class="chapter_upload_l_i1"
  610. ></div>
  611. <div
  612. v-if="
  613. item1.type == 3 ||
  614. item1.type == 6 ||
  615. item1.type == 7
  616. "
  617. class="chapter_upload_l_i5"
  618. style="margin-right: 4px"
  619. ></div>
  620. <div
  621. v-if="item1.type == 8"
  622. class="chapter_upload_l_i8"
  623. style="margin-right: 4px"
  624. ></div>
  625. </div>
  626. <div
  627. class="chapter_upload_ic"
  628. style="
  629. cursor: pointer;
  630. position: absolute;
  631. width: 45px;
  632. right: 0;
  633. top: 0;
  634. "
  635. >
  636. <div class="chapter_upload_ic_l"></div>
  637. <div
  638. class="chapter_upload_ic_r"
  639. style="position: absolute"
  640. @click.stop="
  641. deleteChapterData(
  642. $event,
  643. unitIndex,
  644. index,
  645. index1,
  646. itemTaskIndex
  647. )
  648. "
  649. >
  650. <div></div>
  651. </div>
  652. </div>
  653. <div class="chapter_upload_n">
  654. <input
  655. v-if="
  656. item1.type == 2 ||
  657. item1.type == 3 ||
  658. item1.type == 7
  659. "
  660. :placeholder="item1.name"
  661. @change="
  662. updataVideoT(
  663. $event,
  664. unitIndex,
  665. chapterIndex,
  666. index1
  667. )
  668. "
  669. style="
  670. border: none;
  671. outline: none;
  672. width: 55%;
  673. minwidth: 215px;
  674. z-index: 99;
  675. font-size: 14px;
  676. "
  677. />
  678. <input
  679. :placeholder="item1.name"
  680. v-if="item1.type == 6"
  681. style="
  682. border: none;
  683. outline: none;
  684. width: 55%;
  685. minwidth: 215px;
  686. "
  687. readonly="true"
  688. @click="selectAttText(itemTaskIndex, index1)"
  689. />
  690. <input
  691. :placeholder="item1.name"
  692. v-if="item1.type == 8"
  693. style="
  694. border: none;
  695. outline: none;
  696. width: 55%;
  697. minwidth: 215px;
  698. "
  699. readonly="true"
  700. @click="selectLine(itemTaskIndex, index1)"
  701. />
  702. <div
  703. class="chapter_upload_ud"
  704. style="z-index: 99"
  705. >
  706. <div
  707. class="chapter_upload_up"
  708. @click="
  709. upCd($event, unitIndex, index, index1)
  710. "
  711. ></div>
  712. <div
  713. class="chapter_upload_down"
  714. @click="
  715. downCd($event, unitIndex, index, index1)
  716. "
  717. ></div>
  718. </div>
  719. </div>
  720. </div>
  721. </div>
  722. </div>
  723. </div>
  724. <div class="add_info_box">
  725. <button class="info_btn" @click="addImg($event)">
  726. 教学视频添加
  727. <input
  728. type="file"
  729. accept="video/mp4, video/quicktime, video/x-msvideo"
  730. style="display: none"
  731. v-if="inputShow"
  732. @change="
  733. beforeUpload2($event, unitIndex, 2, itemTaskIndex)
  734. "
  735. />
  736. </button>
  737. <button class="info_btn" @click="addImg($event)">
  738. 教学附件添加
  739. <input
  740. type="file"
  741. accept="application/pdf, .ppt, .pptx, .xlsx, .xls, application/msword, application/vnd.openxmlformats-officedocument.wordprocessingml.document"
  742. style="display: none"
  743. v-if="inputShow"
  744. @change="
  745. beforeUpload2($event, unitIndex, 3, itemTaskIndex)
  746. "
  747. />
  748. </button>
  749. <button
  750. class="info_btn"
  751. @click="addAttText(itemTaskIndex)"
  752. >
  753. 添加图文
  754. </button>
  755. <!-- <button class="info_btn" @click="addChaptersTools(itemTaskIndex)">添加工具</button> -->
  756. <button class="info_btn" @click="openLine(itemTaskIndex)">
  757. 添加链接
  758. </button>
  759. </div>
  760. </div>
  761. <div
  762. style="
  763. flex-direction: row;
  764. justify-content: flex-start;
  765. align-items: center;
  766. padding: 0 0 0 30px;
  767. paddint-top: 10px !important;
  768. "
  769. >
  770. <div
  771. style="
  772. display: flex;
  773. flex-direction: row;
  774. align-items: center;
  775. margin-bottom: 20px;
  776. "
  777. >
  778. <div
  779. style="
  780. font-size: 1.5em;
  781. font-weight: bold;
  782. margin-top: 15px;
  783. "
  784. >
  785. 练习内容
  786. </div>
  787. <div class="line" style="width: 90%"></div>
  788. </div>
  789. </div>
  790. <div class="toolChoose" style="padding: 0 0 0 30px">
  791. <div class="tools">
  792. <div
  793. class="leftTools"
  794. style="
  795. width: 95%;
  796. padding: 0 0 15px 0;
  797. border-bottom: 1px solid #efefef;
  798. margin-bottom: 15px;
  799. "
  800. v-for="(itemTool, toolIndex) in itemTask.toolChoose"
  801. :key="toolIndex"
  802. >
  803. <div>
  804. <input
  805. type="text"
  806. placeholder="添加工具描述"
  807. class="binfo_input"
  808. style="margin: 20px 0; width: 71.5% !important"
  809. v-model="itemTool.toolDetail"
  810. />
  811. </div>
  812. <div
  813. style="
  814. display: flex;
  815. flex-direction: row;
  816. align-items: baseline;
  817. flex-wrap: nowrap;
  818. justify-content: flex-start;
  819. position: relative;
  820. "
  821. >
  822. <div style="margin-right: 20px">
  823. 工具 {{ toolIndex + 1 }} :
  824. </div>
  825. <div class="chooseWho">
  826. <div
  827. :class="
  828. itemTool.toolType == 0 ? 'isChooseActive' : ''
  829. "
  830. @click="itemTool.toolType = 0"
  831. >
  832. 展示类
  833. </div>
  834. <div
  835. :class="
  836. itemTool.toolType == 1 ? 'isChooseActive' : ''
  837. "
  838. @click="itemTool.toolType = 1"
  839. >
  840. 思维类
  841. </div>
  842. <div
  843. :class="
  844. itemTool.toolType == 2 ? 'isChooseActive' : ''
  845. "
  846. @click="itemTool.toolType = 2"
  847. >
  848. 评价类
  849. </div>
  850. </div>
  851. <div
  852. class="remove"
  853. @click="deleteTool(itemTaskIndex, toolIndex)"
  854. v-if="itemTask.toolChoose.length > 1"
  855. style="position: absolute; right: 55px"
  856. ></div>
  857. </div>
  858. <div style="min-height: 163px">
  859. <div class="toolSort" v-if="itemTool.toolType == 0">
  860. <!-- <div class="tool">
  861. <div
  862. class="whiteBIcon"
  863. @click="addTools(8, itemTaskIndex, toolIndex)"
  864. >
  865. <img src="../../assets/icon/secondToolList/library.png" alt />
  866. <div style="margin: 5px 0">素材库</div>
  867. </div>
  868. <div class="check" @click="addTools(8, itemTaskIndex, toolIndex)">
  869. <img
  870. src="../../assets/icon/checkNo.png"
  871. alt
  872. v-if="itemTool.tool.indexOf(8) == -1"
  873. />
  874. <img src="../../assets/icon/checkedIs.png" alt v-else />
  875. </div>
  876. </div> -->
  877. <div class="tool">
  878. <div
  879. class="whiteBIcon"
  880. @click="addTools(17, itemTaskIndex, toolIndex)"
  881. >
  882. <img
  883. src="../../assets/icon/secondToolList/library.png"
  884. alt
  885. />
  886. <div style="margin: 5px 0">学习资料</div>
  887. </div>
  888. <div
  889. class="check"
  890. @click="addTools(17, itemTaskIndex, toolIndex)"
  891. >
  892. <img
  893. src="../../assets/icon/checkNo.png"
  894. alt
  895. v-if="itemTool.tool.indexOf(17) == -1"
  896. />
  897. <img
  898. src="../../assets/icon/checkedIs.png"
  899. alt
  900. v-else
  901. />
  902. </div>
  903. </div>
  904. <div class="tool">
  905. <div
  906. class="whiteBIcon"
  907. @click="addTools(10, itemTaskIndex, toolIndex)"
  908. >
  909. <img
  910. src="../../assets/icon/thirdToolList/time.png"
  911. alt
  912. />
  913. <div style="margin: 5px 0">倒计时</div>
  914. </div>
  915. <div
  916. class="check"
  917. @click="addTools(10, itemTaskIndex, toolIndex)"
  918. >
  919. <img
  920. src="../../assets/icon/checkNo.png"
  921. alt
  922. v-if="itemTool.tool.indexOf(10) == -1"
  923. />
  924. <img
  925. src="../../assets/icon/checkedIs.png"
  926. alt
  927. v-else
  928. />
  929. </div>
  930. </div>
  931. <div class="tool">
  932. <div
  933. class="whiteBIcon"
  934. @click="addTools(18, itemTaskIndex, toolIndex)"
  935. >
  936. <img
  937. src="../../assets/icon/thirdToolList/trainPlatform.png"
  938. alt
  939. />
  940. <div style="margin: 5px 0">训练服务器</div>
  941. </div>
  942. <div
  943. class="check"
  944. @click="addTools(18, itemTaskIndex, toolIndex)"
  945. >
  946. <img
  947. src="../../assets/icon/checkNo.png"
  948. alt
  949. v-if="itemTool.tool.indexOf(18) == -1"
  950. />
  951. <img
  952. src="../../assets/icon/checkedIs.png"
  953. alt
  954. v-else
  955. />
  956. </div>
  957. </div>
  958. </div>
  959. <div class="toolSort" v-if="itemTool.toolType == 1">
  960. <div class="tool">
  961. <div
  962. class="whiteBIcon"
  963. @click="addTools(7, itemTaskIndex, toolIndex)"
  964. >
  965. <img
  966. src="../../assets/icon/secondToolList/mindNetwork.png"
  967. alt
  968. />
  969. <div style="margin: 5px 0">思维网格</div>
  970. </div>
  971. <div
  972. class="check"
  973. @click="addTools(7, itemTaskIndex, toolIndex)"
  974. >
  975. <img
  976. src="../../assets/icon/checkNo.png"
  977. alt
  978. v-if="itemTool.tool.indexOf(7) == -1"
  979. />
  980. <img
  981. src="../../assets/icon/checkedIs.png"
  982. alt
  983. v-else
  984. />
  985. </div>
  986. </div>
  987. <div class="tool">
  988. <div
  989. class="whiteBIcon"
  990. @click="addTools(1, itemTaskIndex, toolIndex)"
  991. >
  992. <img
  993. src="../../assets/icon/secondToolList/whiteBoard.png"
  994. alt
  995. />
  996. <div style="margin: 5px 0">电子白板</div>
  997. </div>
  998. <div
  999. class="check"
  1000. @click="addTools(1, itemTaskIndex, toolIndex)"
  1001. >
  1002. <img
  1003. src="../../assets/icon/checkNo.png"
  1004. alt
  1005. v-if="itemTool.tool.indexOf(1) == -1"
  1006. />
  1007. <img
  1008. src="../../assets/icon/checkedIs.png"
  1009. alt
  1010. v-else
  1011. />
  1012. </div>
  1013. </div>
  1014. <div class="tool">
  1015. <div
  1016. class="whiteBIcon"
  1017. @click="addTools(2, itemTaskIndex, toolIndex)"
  1018. >
  1019. <img
  1020. src="../../assets/icon/secondToolList/note.png"
  1021. alt
  1022. />
  1023. <div style="margin: 5px 0">便签</div>
  1024. </div>
  1025. <div
  1026. class="check"
  1027. @click="addTools(2, itemTaskIndex, toolIndex)"
  1028. >
  1029. <img
  1030. src="../../assets/icon/checkNo.png"
  1031. alt
  1032. v-if="itemTool.tool.indexOf(2) == -1"
  1033. />
  1034. <img
  1035. src="../../assets/icon/checkedIs.png"
  1036. alt
  1037. v-else
  1038. />
  1039. </div>
  1040. </div>
  1041. <div class="tool">
  1042. <div
  1043. class="whiteBIcon"
  1044. @click="addTools(6, itemTaskIndex, toolIndex)"
  1045. >
  1046. <img
  1047. src="../../assets/icon/secondToolList/doc.png"
  1048. alt
  1049. />
  1050. <div style="margin: 5px 0">协同文档</div>
  1051. </div>
  1052. <div
  1053. class="check"
  1054. @click="addTools(6, itemTaskIndex, toolIndex)"
  1055. >
  1056. <img
  1057. src="../../assets/icon/checkNo.png"
  1058. alt
  1059. v-if="itemTool.tool.indexOf(6) == -1"
  1060. />
  1061. <img
  1062. src="../../assets/icon/checkedIs.png"
  1063. alt
  1064. v-else
  1065. />
  1066. </div>
  1067. </div>
  1068. <div class="tool">
  1069. <div
  1070. class="whiteBIcon"
  1071. @click="addTools(3, itemTaskIndex, toolIndex)"
  1072. >
  1073. <img
  1074. src="../../assets/icon/secondToolList/mindMapping.png"
  1075. alt
  1076. />
  1077. <div style="margin: 5px 0">思维导图</div>
  1078. </div>
  1079. <div
  1080. class="check"
  1081. @click="addTools(3, itemTaskIndex, toolIndex)"
  1082. >
  1083. <img
  1084. src="../../assets/icon/checkNo.png"
  1085. alt
  1086. v-if="itemTool.tool.indexOf(3) == -1"
  1087. />
  1088. <img
  1089. src="../../assets/icon/checkedIs.png"
  1090. alt
  1091. v-else
  1092. />
  1093. </div>
  1094. </div>
  1095. <div class="tool">
  1096. <div
  1097. class="whiteBIcon"
  1098. @click="openTools(itemTaskIndex, 15, toolIndex)"
  1099. >
  1100. <img
  1101. src="../../assets/icon/thirdToolList/answer.png"
  1102. alt
  1103. />
  1104. <div style="margin: 5px 0">问答工具</div>
  1105. </div>
  1106. <div
  1107. class="check"
  1108. @click="addTools(15, itemTaskIndex, toolIndex)"
  1109. >
  1110. <img
  1111. src="../../assets/icon/checkNo.png"
  1112. alt
  1113. v-if="itemTool.tool.indexOf(15) == -1"
  1114. />
  1115. <img
  1116. src="../../assets/icon/checkedIs.png"
  1117. alt
  1118. v-else
  1119. />
  1120. </div>
  1121. </div>
  1122. </div>
  1123. <div class="toolSort" v-if="itemTool.toolType == 2">
  1124. <div class="tool">
  1125. <div
  1126. class="whiteBIcon"
  1127. @click="addTools(5, itemTaskIndex, toolIndex)"
  1128. >
  1129. <img
  1130. src="../../assets/icon/thirdToolList/score.png"
  1131. alt
  1132. />
  1133. <div style="margin: 5px 0">量规评分</div>
  1134. </div>
  1135. <div
  1136. class="check"
  1137. @click="addTools(5, itemTaskIndex, toolIndex)"
  1138. >
  1139. <img
  1140. src="../../assets/icon/checkNo.png"
  1141. alt
  1142. v-if="itemTool.tool.indexOf(5) == -1"
  1143. />
  1144. <img
  1145. src="../../assets/icon/checkedIs.png"
  1146. alt
  1147. v-else
  1148. />
  1149. </div>
  1150. </div>
  1151. <div class="tool">
  1152. <div
  1153. class="whiteBIcon"
  1154. @click="openTools(itemTaskIndex, 4, toolIndex)"
  1155. >
  1156. <img
  1157. src="../../assets/icon/thirdToolList/ask.png"
  1158. alt
  1159. />
  1160. <div style="margin: 5px 0">问卷调查</div>
  1161. </div>
  1162. <div
  1163. class="check"
  1164. @click="addTools(4, itemTaskIndex, toolIndex)"
  1165. >
  1166. <img
  1167. src="../../assets/icon/checkNo.png"
  1168. alt
  1169. v-if="itemTool.tool.indexOf(4) == -1"
  1170. />
  1171. <img
  1172. src="../../assets/icon/checkedIs.png"
  1173. alt
  1174. v-else
  1175. />
  1176. </div>
  1177. </div>
  1178. <!-- <div class="tool">
  1179. <div
  1180. class="whiteBIcon"
  1181. @click="addTools(16, itemTaskIndex, toolIndex)"
  1182. >
  1183. <img src="../../assets/icon/thirdToolList/work.png" alt />
  1184. <div style="margin: 5px 0">作业提交</div>
  1185. </div>
  1186. <div class="check" @click="addTools(16, itemTaskIndex, toolIndex)">
  1187. <img
  1188. src="../../assets/icon/checkNo.png"
  1189. alt
  1190. v-if="itemTool.tool.indexOf(16) == -1"
  1191. />
  1192. <img src="../../assets/icon/checkedIs.png" alt v-else />
  1193. </div>
  1194. </div> -->
  1195. </div>
  1196. </div>
  1197. </div>
  1198. <div
  1199. class="addToolFun"
  1200. @click="addToolFun(itemTaskIndex)"
  1201. >
  1202. <div class="addToolImg">
  1203. <img src="../../assets/icon/add.png" alt />
  1204. </div>
  1205. <div>添加工具</div>
  1206. </div>
  1207. </div>
  1208. </div>
  1209. <div class="elist_css">
  1210. <div class="elist_title">
  1211. <!-- <span>评价分类</span> -->
  1212. <div
  1213. style="
  1214. display: flex;
  1215. flex-direction: row;
  1216. align-items: center;
  1217. margin-bottom: 20px;
  1218. "
  1219. >
  1220. <div
  1221. style="
  1222. font-size: 1.5em;
  1223. font-weight: bold;
  1224. margin-top: 15px;
  1225. "
  1226. >
  1227. 评价设置
  1228. </div>
  1229. <div class="line" style="width: 90%"></div>
  1230. </div>
  1231. </div>
  1232. <div
  1233. v-if="itemTask.eList && itemTask.eList.length"
  1234. class="elist_input"
  1235. >
  1236. <div
  1237. v-for="(eItem, eIndex) in itemTask.eList"
  1238. :key="eIndex"
  1239. class="elist_input_box"
  1240. >
  1241. <span>评价名称:</span>
  1242. <input
  1243. type="input"
  1244. v-model="itemTask.eList[eIndex].value"
  1245. placeholder="填写评价名称"
  1246. />
  1247. <span>评星等级:</span>
  1248. <el-rate
  1249. v-model="itemTask.eList[eIndex].score"
  1250. @change="setEListStar()"
  1251. disabled
  1252. ></el-rate>
  1253. <div
  1254. class="remove"
  1255. @click="deletEList(unitIndex, itemTaskIndex, eIndex)"
  1256. ></div>
  1257. <div class="elist_inptu_text">
  1258. <span>评价描述:</span>
  1259. <input
  1260. type="input"
  1261. v-model="itemTask.eList[eIndex].detail"
  1262. placeholder="填写评价描述"
  1263. />
  1264. </div>
  1265. </div>
  1266. </div>
  1267. <div
  1268. class="addToolFun"
  1269. @click="addEList(unitIndex, itemTaskIndex)"
  1270. >
  1271. <div class="addToolImg">
  1272. <img src="../../assets/icon/add.png" alt />
  1273. </div>
  1274. <div>添加</div>
  1275. </div>
  1276. <!-- <el-button
  1277. class="elist_btn"
  1278. type="primary"
  1279. @click="addEList(unitIndex,itemTaskIndex)"
  1280. >添加</el-button>-->
  1281. </div>
  1282. <!-- <el-switch
  1283. v-model="
  1284. unitJson[unitIndex].chapterInfo[0].taskJson[taskCount]
  1285. .isShowTools
  1286. "
  1287. active-text="是否开启评价"
  1288. style="margin: 30px 0px 10px 0; padding-bottom: 30px"
  1289. ></el-switch>-->
  1290. <div class="funBlock" style="padding: 0">
  1291. <div class="fold">
  1292. <div @click="fold(itemTaskIndex, $event, 1)">折叠</div>
  1293. <div class="arrow">
  1294. <img src="../../assets/icon/fold.png" alt />
  1295. </div>
  1296. </div>
  1297. <div class="fold">
  1298. <div @click="fold(itemTaskIndex, $event, 0)">展开</div>
  1299. <div class="arrow">
  1300. <img src="../../assets/icon/expand.png" alt />
  1301. </div>
  1302. </div>
  1303. </div>
  1304. </div>
  1305. <div class="addTaskBorder" @click="addTaskBorder">
  1306. <div>
  1307. <img src="../../assets/icon/addHw.png" alt />
  1308. <span>添加任务</span>
  1309. </div>
  1310. </div>
  1311. </div>
  1312. </div>
  1313. </div>
  1314. <div
  1315. style="
  1316. width: calc(100% - 17% - 25px);
  1317. background: #fff;
  1318. border-radius: 10px;
  1319. min-height: 550px;
  1320. min-width: 800px;
  1321. "
  1322. v-if="this.steps == 4"
  1323. >
  1324. <div class="basic_box_success">
  1325. <div class="right_img">
  1326. <img src="../../assets/icon/right.png" alt />
  1327. </div>
  1328. <div style="font-weight: bold">成功</div>
  1329. <div>您的课程编号</div>
  1330. <div class="number">{{ number }}</div>
  1331. <div class="success_button">
  1332. <div class="look_course" @click="isNoFinsh">
  1333. 邀请老师协同编辑
  1334. </div>
  1335. <div class="attend_others" @click="goCourse">预览课程</div>
  1336. </div>
  1337. </div>
  1338. </div>
  1339. </div>
  1340. <!-- <div class="line"></div> -->
  1341. <div class="info_btnBox">
  1342. <button
  1343. class="info_btn"
  1344. v-if="steps == 1"
  1345. @click="goTo('/course?userid=' + userid + '&oid=' + oid)"
  1346. >
  1347. 返回课程
  1348. </button>
  1349. <button
  1350. class="info_btn"
  1351. v-if="steps > 1 && steps != 5"
  1352. @click="lastSteps"
  1353. >
  1354. {{ steps == 4 ? "返回首页" : "上一步" }}
  1355. </button>
  1356. <button class="info_btn" v-if="steps < 5" @click="nextSteps">
  1357. {{ steps == 3 ? "确认上传" : "下一步" }}
  1358. </button>
  1359. </div>
  1360. </div>
  1361. </div>
  1362. <el-dialog
  1363. title="提示"
  1364. :visible.sync="dialogVisible"
  1365. :append-to-body="true"
  1366. width="25%"
  1367. :before-close="handleClose"
  1368. class="dialog_diy2 customWidth"
  1369. >
  1370. <div>请复制该链接邀请协同编辑</div>
  1371. <div>http://www.boomyon.com/index-zhang.com</div>
  1372. <span slot="footer" class="dialog-footer">
  1373. <el-button type="primary">复制链接分享</el-button>
  1374. <el-button @click="dialogVisible = false">取消</el-button>
  1375. </span>
  1376. </el-dialog>
  1377. <el-dialog
  1378. :title="updateBoolean2 ? '查看文档' : '添加文档'"
  1379. :visible.sync="dialogVisible1"
  1380. :append-to-body="true"
  1381. width="25%"
  1382. :before-close="handleClose"
  1383. class="dialog_diy2 customWidth"
  1384. >
  1385. <el-form>
  1386. <el-form-item label="文档标题">
  1387. <el-input
  1388. v-model="tTitle"
  1389. auto-complete="off"
  1390. placeholder="请输入文档标题名..."
  1391. ></el-input>
  1392. </el-form-item>
  1393. <div>文档简介</div>
  1394. <editor-bar v-model="tdetail" @change="change"></editor-bar>
  1395. </el-form>
  1396. <span slot="footer" class="dialog-footer">
  1397. <el-button @click="dialogVisible1 = false">取 消</el-button>
  1398. <el-button type="primary" @click="addWord" v-if="!updateBoolean2"
  1399. >添加</el-button
  1400. >
  1401. <el-button type="primary" @click="upWord" v-else>修 改</el-button>
  1402. </span>
  1403. </el-dialog>
  1404. <el-dialog
  1405. title="添加文档"
  1406. :visible.sync="dialogVisible2"
  1407. :append-to-body="true"
  1408. width="500px"
  1409. :before-close="handleClose"
  1410. class="dialog_diy"
  1411. >
  1412. <el-form>
  1413. <el-form-item label="文档标题">
  1414. <el-input
  1415. v-model="templateC.title"
  1416. auto-complete="off"
  1417. placeholder="请输入文档标题名..."
  1418. ></el-input>
  1419. </el-form-item>
  1420. <div>文档内容</div>
  1421. <editor-bar v-model="cTemplate" @change="change"></editor-bar>
  1422. </el-form>
  1423. <span slot="footer" class="dialog-footer">
  1424. <el-button @click="clearChoose">取 消</el-button>
  1425. <el-button type="primary" @click="wordNext()">确定</el-button>
  1426. </span>
  1427. </el-dialog>
  1428. <el-dialog
  1429. title="添加富文本"
  1430. :visible.sync="dialogVisible6"
  1431. :append-to-body="true"
  1432. width="500px"
  1433. :before-close="handleClose"
  1434. class="dialog_diy"
  1435. >
  1436. <el-form>
  1437. <el-form-item label="文本标题">
  1438. <el-input
  1439. v-model="AttText.title"
  1440. auto-complete="off"
  1441. placeholder="请输入文本标题..."
  1442. ></el-input>
  1443. </el-form-item>
  1444. <div>富文本内容</div>
  1445. <editor-bar v-model="AttText.text" @change="change"></editor-bar>
  1446. </el-form>
  1447. <span slot="footer" class="dialog-footer">
  1448. <el-button @click="clearAttText">取 消</el-button>
  1449. <el-button type="primary" @click="isAddOrUpdateAttText">确定</el-button>
  1450. </span>
  1451. </el-dialog>
  1452. <el-dialog
  1453. title="添加链接"
  1454. :visible.sync="dialogVisible7"
  1455. :append-to-body="true"
  1456. width="500px"
  1457. :before-close="handleClose"
  1458. class="dialog_diy lineCss"
  1459. >
  1460. <el-form>
  1461. <el-form-item label="链接" :label-width="formLabelWidth">
  1462. <span>
  1463. <el-input
  1464. placeholder="请输入链接"
  1465. clearable
  1466. v-model="line"
  1467. class="add_input"
  1468. ></el-input>
  1469. </span>
  1470. </el-form-item>
  1471. </el-form>
  1472. <span slot="footer" class="dialog-footer">
  1473. <el-button @click="clearLine">取 消</el-button>
  1474. <el-button type="primary" @click="isAddOrUpdateLine">确定</el-button>
  1475. </span>
  1476. </el-dialog>
  1477. <el-dialog
  1478. title="添加课程成员"
  1479. :visible.sync="dialogVisible3"
  1480. :append-to-body="true"
  1481. width="25%"
  1482. height="80%"
  1483. :before-close="handleClose"
  1484. class="addNewPP customWidth"
  1485. >
  1486. <div class="people">
  1487. <div class="people_top">
  1488. <div class="people_nav">选择成员</div>
  1489. <div class="people_top_right">
  1490. <div class="people_search">
  1491. <el-input
  1492. placeholder="搜索成员"
  1493. v-model="searchPeople"
  1494. ></el-input>
  1495. <div class="search_img" @click="searchStudent">
  1496. <img src="../../assets/icon/search.png" alt />
  1497. </div>
  1498. </div>
  1499. </div>
  1500. </div>
  1501. <el-checkbox-group v-model="checkboxList" class="people_name">
  1502. <el-checkbox
  1503. v-for="item in studentJuri"
  1504. :key="item.userid"
  1505. :label="item.userid"
  1506. >{{ item.name ? item.name : "暂无学生可选" }}</el-checkbox
  1507. >
  1508. </el-checkbox-group>
  1509. </div>
  1510. <span slot="footer" class="dialog-footer">
  1511. <el-button @click="dialogVisible3 = false">取 消</el-button>
  1512. <el-button type="primary" @click="isAddPP">确定</el-button>
  1513. </span>
  1514. </el-dialog>
  1515. <el-dialog
  1516. title="创建问卷调查"
  1517. :visible.sync="dialogVisible5"
  1518. :append-to-body="true"
  1519. width="800px"
  1520. :before-close="handleClose"
  1521. class="dialog_diy"
  1522. >
  1523. <!-- v-for="(item, index) in unitJson[unitIndex].chapterInfo[0].taskJson[taskCount].toolChoose"
  1524. :key="index"-->
  1525. <div>
  1526. <div
  1527. class="a_add_title"
  1528. style="
  1529. display: flex;
  1530. flex-direction: row;
  1531. align-items: center;
  1532. justify-content: center;
  1533. "
  1534. >
  1535. <div style="margin-right: 20px; font-size: 20px">问卷标题:</div>
  1536. <el-input
  1537. v-model="askJson.askTitle"
  1538. placeholder="请输入问卷标题"
  1539. style="width: 400px"
  1540. ></el-input>
  1541. </div>
  1542. <div class="a_addBox">
  1543. <div style="font-size: 16px; color: #c7c7c7">请输入问卷内容</div>
  1544. <div
  1545. class="a_add_box"
  1546. v-for="(item1, index1) in askJson.askCount"
  1547. :key="index1"
  1548. >
  1549. <div class="a_add_head">
  1550. <div>
  1551. {{ index1 + 1 + "、" }}
  1552. <el-input
  1553. class="a_add_head_input"
  1554. v-model="askJson.askJson[index1].askstitle"
  1555. placeholder="请输入问卷题目..."
  1556. ></el-input>
  1557. </div>
  1558. <div class="a_add_head_div">
  1559. <el-button type="primary" size="small" @click="addAskList()"
  1560. >添加</el-button
  1561. >
  1562. <el-button
  1563. type="primary"
  1564. size="small"
  1565. @click="deleteAskList()"
  1566. v-if="index1 != 0"
  1567. >删除</el-button
  1568. >
  1569. </div>
  1570. </div>
  1571. <div class="a_add_body">
  1572. <div class="a_add_input">
  1573. <el-input
  1574. v-for="(item2, checkIndex) in askJson.askJson[index1].askItem"
  1575. :key="checkIndex"
  1576. v-model="askJson.askJson[index1].checkList[checkIndex]"
  1577. placeholder="请输入选项..."
  1578. style="width: 150px; margin: 10px 10px 0 0"
  1579. ></el-input>
  1580. </div>
  1581. <div class="a_add_body_div">
  1582. <el-button
  1583. style="margin: 10px 0px 0 0"
  1584. type="primary"
  1585. size="small"
  1586. @click="addcheckList(askJson.askJson[index1])"
  1587. v-if="askJson.askJson[index1].askItem < 4"
  1588. >添加</el-button
  1589. >
  1590. <el-button
  1591. type="primary"
  1592. size="small"
  1593. style="margin: 10px 0 0 0"
  1594. @click="deletecheckList(askJson.askJson[index1])"
  1595. v-if="askJson.askJson[index1].askItem != 1"
  1596. >删除</el-button
  1597. >
  1598. </div>
  1599. </div>
  1600. </div>
  1601. </div>
  1602. </div>
  1603. <span slot="footer" class="dialog-footer">
  1604. <el-button @click="dialogVisible5 = false">取 消</el-button>
  1605. <el-button type="primary" @click="addAsk">确 定</el-button>
  1606. </span>
  1607. </el-dialog>
  1608. <el-dialog
  1609. title="添加工具"
  1610. :visible.sync="dialogVisible4"
  1611. :append-to-body="true"
  1612. width="600px"
  1613. :before-close="handleClose"
  1614. class="dialog_diy addToolsDia"
  1615. >
  1616. <div class="toolChoose" style="padding: 0 0 0 30px">
  1617. <div class="tools">
  1618. <div
  1619. class="leftTools"
  1620. style="
  1621. width: 95%;
  1622. padding: 0 0 15px 0;
  1623. border-bottom: 1px solid #efefef;
  1624. margin-bottom: 15px;
  1625. "
  1626. v-for="(itemTools, itemToolsIndex) in chapTools"
  1627. :key="itemToolsIndex"
  1628. >
  1629. <div
  1630. style="
  1631. display: flex;
  1632. flex-direction: row;
  1633. align-items: baseline;
  1634. flex-wrap: nowrap;
  1635. justify-content: flex-start;
  1636. position: relative;
  1637. "
  1638. >
  1639. <div class="chooseWho">
  1640. <div
  1641. :class="chapToolsType == 0 ? 'isChooseActive' : ''"
  1642. @click="chapToolsType = 0"
  1643. >
  1644. 展示类
  1645. </div>
  1646. <div
  1647. :class="chapToolsType == 1 ? 'isChooseActive' : ''"
  1648. @click="chapToolsType = 1"
  1649. >
  1650. 思维类
  1651. </div>
  1652. <div
  1653. :class="chapToolsType == 2 ? 'isChooseActive' : ''"
  1654. @click="chapToolsType = 2"
  1655. >
  1656. 评价类
  1657. </div>
  1658. </div>
  1659. <!-- <div
  1660. class="remove"
  1661. @click="deleteTool(itemTaskIndex, toolIndex)"
  1662. v-if="itemTask.toolChoose.length > 1"
  1663. style="position: absolute; right: 55px"
  1664. ></div>-->
  1665. </div>
  1666. <div style="min-height: 163px">
  1667. <div class="toolSort" v-if="chapToolsType == 0">
  1668. <div class="tool">
  1669. <div class="whiteBIcon" @click="chapAddTools(8)">
  1670. <img
  1671. src="../../assets/icon/secondToolList/library.png"
  1672. alt
  1673. />
  1674. <div style="margin: 5px 0">素材库</div>
  1675. </div>
  1676. <div class="check" @click="chapAddTools(8)">
  1677. <img
  1678. src="../../assets/icon/checkNo.png"
  1679. alt
  1680. v-if="itemTools.tools.indexOf(8) == -1"
  1681. />
  1682. <img src="../../assets/icon/checkedIs.png" alt v-else />
  1683. </div>
  1684. </div>
  1685. </div>
  1686. <div class="toolSort" v-if="chapToolsType == 1">
  1687. <div class="tool">
  1688. <div class="whiteBIcon" @click="chapAddTools(7)">
  1689. <img
  1690. src="../../assets/icon/secondToolList/mindNetwork.png"
  1691. alt
  1692. />
  1693. <div style="margin: 5px 0">思维网格</div>
  1694. </div>
  1695. <div class="check" @click="chapAddTools(7)">
  1696. <img
  1697. src="../../assets/icon/checkNo.png"
  1698. alt
  1699. v-if="itemTools.tools.indexOf(7) == -1"
  1700. />
  1701. <img src="../../assets/icon/checkedIs.png" alt v-else />
  1702. </div>
  1703. </div>
  1704. <div class="tool">
  1705. <div class="whiteBIcon" @click="chapAddTools(1)">
  1706. <img
  1707. src="../../assets/icon/secondToolList/whiteBoard.png"
  1708. alt
  1709. />
  1710. <div style="margin: 5px 0">电子白板</div>
  1711. </div>
  1712. <div class="check" @click="chapAddTools(1)">
  1713. <img
  1714. src="../../assets/icon/checkNo.png"
  1715. alt
  1716. v-if="itemTools.tools.indexOf(1) == -1"
  1717. />
  1718. <img src="../../assets/icon/checkedIs.png" alt v-else />
  1719. </div>
  1720. </div>
  1721. <div class="tool">
  1722. <div class="whiteBIcon" @click="chapAddTools(2)">
  1723. <img src="../../assets/icon/secondToolList/note.png" alt />
  1724. <div style="margin: 5px 0">便签</div>
  1725. </div>
  1726. <div class="check" @click="chapAddTools(2)">
  1727. <img
  1728. src="../../assets/icon/checkNo.png"
  1729. alt
  1730. v-if="itemTools.tools.indexOf(2) == -1"
  1731. />
  1732. <img src="../../assets/icon/checkedIs.png" alt v-else />
  1733. </div>
  1734. </div>
  1735. <div class="tool">
  1736. <div class="whiteBIcon" @click="chapAddTools(6)">
  1737. <img src="../../assets/icon/secondToolList/doc.png" alt />
  1738. <div style="margin: 5px 0">协同文档</div>
  1739. </div>
  1740. <div class="check" @click="chapAddTools(6)">
  1741. <img
  1742. src="../../assets/icon/checkNo.png"
  1743. alt
  1744. v-if="itemTools.tools.indexOf(6) == -1"
  1745. />
  1746. <img src="../../assets/icon/checkedIs.png" alt v-else />
  1747. </div>
  1748. </div>
  1749. <div class="tool">
  1750. <div class="whiteBIcon" @click="chapAddTools(3)">
  1751. <img
  1752. src="../../assets/icon/secondToolList/mindMapping.png"
  1753. alt
  1754. />
  1755. <div style="margin: 5px 0">思维导图</div>
  1756. </div>
  1757. <div class="check" @click="chapAddTools(3)">
  1758. <img
  1759. src="../../assets/icon/checkNo.png"
  1760. alt
  1761. v-if="itemTools.tools.indexOf(3) == -1"
  1762. />
  1763. <img src="../../assets/icon/checkedIs.png" alt v-else />
  1764. </div>
  1765. </div>
  1766. </div>
  1767. <div class="toolSort" v-if="chapToolsType == 2">
  1768. <div class="tool">
  1769. <div class="whiteBIcon" @click="chapAddTools(5)">
  1770. <img src="../../assets/icon/thirdToolList/score.png" alt />
  1771. <div style="margin: 5px 0">量规评分</div>
  1772. </div>
  1773. <div class="check" @click="chapAddTools(5)">
  1774. <img
  1775. src="../../assets/icon/checkNo.png"
  1776. alt
  1777. v-if="itemTools.tools.indexOf(5) == -1"
  1778. />
  1779. <img src="../../assets/icon/checkedIs.png" alt v-else />
  1780. </div>
  1781. </div>
  1782. <div class="tool">
  1783. <div
  1784. class="whiteBIcon"
  1785. @click="openTools(chapCount, 4, null)"
  1786. >
  1787. <img src="../../assets/icon/thirdToolList/ask.png" alt />
  1788. <div style="margin: 5px 0">问卷调查</div>
  1789. </div>
  1790. <div class="check" @click="chapAddTools(4)">
  1791. <img
  1792. src="../../assets/icon/checkNo.png"
  1793. alt
  1794. v-if="itemTools.tools.indexOf(4) == -1"
  1795. />
  1796. <img src="../../assets/icon/checkedIs.png" alt v-else />
  1797. </div>
  1798. </div>
  1799. </div>
  1800. </div>
  1801. <div>
  1802. <input
  1803. type="text"
  1804. placeholder="添加工具描述"
  1805. class="binfo_input"
  1806. style="margin: 20px 0; width: 71.5% !important"
  1807. v-model="itemTools.toolDetail"
  1808. />
  1809. </div>
  1810. </div>
  1811. <!-- <div class="addToolFun" @click="addToolFun(itemTaskIndex)">
  1812. <div class="addToolImg">
  1813. <img src="../../assets/icon/add.png" alt />
  1814. </div>
  1815. <div>添加工具</div>
  1816. </div>-->
  1817. </div>
  1818. </div>
  1819. <span slot="footer" class="dialog-footer">
  1820. <el-button @click="dialogVisible4 = false">取 消</el-button>
  1821. <el-button type="primary" @click="addChaptersDataTools">确定</el-button>
  1822. </span>
  1823. </el-dialog>
  1824. <el-dialog
  1825. title="添加问答"
  1826. :visible.sync="dialogVisible8"
  1827. :append-to-body="true"
  1828. width="500px"
  1829. :before-close="handleClose"
  1830. class="dialog_diy"
  1831. >
  1832. <!-- v-for="(item, index) in unitJson[unitIndex].chapterInfo[0].taskJson[taskCount].toolChoose"
  1833. :key="index"-->
  1834. <div>
  1835. <div
  1836. class="a_add_title"
  1837. style="
  1838. display: flex;
  1839. flex-direction: column;
  1840. align-items: flex-start;
  1841. justify-content: center;
  1842. "
  1843. >
  1844. <div style="margin-bottom: 20px; font-size: 20px">问题:</div>
  1845. <el-input
  1846. v-model="answerQ"
  1847. placeholder="请输入您要问的问题"
  1848. ></el-input>
  1849. </div>
  1850. </div>
  1851. <span slot="footer" class="dialog-footer">
  1852. <el-button @click="dialogVisible8 = false">取 消</el-button>
  1853. <el-button type="primary" @click="addAnswer">确 定</el-button>
  1854. </span>
  1855. </el-dialog>
  1856. </div>
  1857. </template>
  1858. <script>
  1859. import "../../common/aws-sdk-2.235.1.min.js";
  1860. import $ from "jquery";
  1861. import EditorBar from "../../components/tools/wangEnduit";
  1862. export default {
  1863. components: { EditorBar },
  1864. data() {
  1865. return {
  1866. checkAll: false,
  1867. checkedCities: [],
  1868. isIndeterminate: true,
  1869. steps: 1,
  1870. nbOrder: 0,
  1871. courseId: "",
  1872. chapToolsType: 0,
  1873. chapTools: [
  1874. {
  1875. tools: [],
  1876. toolDetail: "",
  1877. },
  1878. ],
  1879. line: "",
  1880. lineCount: 0,
  1881. lineType: 0,
  1882. chapCount: 0,
  1883. courseName: "",
  1884. isTeacherSee: false,
  1885. courseText: "",
  1886. formLabelWidth: "100px",
  1887. uploadLoading1: false,
  1888. noneBtnImg: false,
  1889. updateBoolean2: false,
  1890. unitIndex: 0,
  1891. taskCount: 0,
  1892. dialogVisible: false,
  1893. dialogVisible1: false,
  1894. dialogVisible2: false,
  1895. dialogVisible3: false,
  1896. dialogVisible4: false,
  1897. dialogVisible5: false,
  1898. dialogVisible6: false,
  1899. dialogVisible7: false,
  1900. dialogVisible8: false,
  1901. publicTool: 0,
  1902. searchPeople: "",
  1903. userid: this.$route.query.userid,
  1904. oid: this.$route.query.oid,
  1905. cid: this.$route.query.cid != undefined ? this.$route.query.cid : "",
  1906. cover: [], //课程封面
  1907. myWord: [],
  1908. askJson: {
  1909. askCount: 1,
  1910. askTitle: "",
  1911. askJson: [{ askstitle: "", askItem: 1, checkList: [] }],
  1912. },
  1913. unitJson: [
  1914. {
  1915. dyName: "", //单元标题
  1916. // dyText: "",
  1917. // startTime: "", //开始时间
  1918. // endTime: "", //结束时间
  1919. // isTalk: false, //是否开启评价
  1920. chapterInfo: [
  1921. {
  1922. isread: false,
  1923. chapterid: this.guid(),
  1924. title: "",
  1925. courseName: "",
  1926. taskJson: [
  1927. {
  1928. task: "",
  1929. taskDetail: "",
  1930. chapterData: [],
  1931. toolText: "",
  1932. toolChoose: [
  1933. {
  1934. tool: [],
  1935. toolDetail: "",
  1936. toolType: 0,
  1937. askCount: 1,
  1938. askTitle: "",
  1939. askJson: [{ askstitle: "", askItem: 1, checkList: [] }],
  1940. },
  1941. ],
  1942. isShowTools: false,
  1943. askCount: 1,
  1944. isFold: 0,
  1945. askTitle: "",
  1946. askJson: [{ askstitle: "", askItem: 1, checkList: [] }],
  1947. checkJson: [{ checkCount: [], checkPerent: [] }],
  1948. homeworkList: [],
  1949. },
  1950. ],
  1951. itemCount: 1,
  1952. // question: "",
  1953. fileList1: [],
  1954. video: [],
  1955. testData: [],
  1956. pData: [],
  1957. templateArray: [],
  1958. },
  1959. ],
  1960. },
  1961. ],
  1962. studentJuri: [],
  1963. checkboxList: [],
  1964. number: "",
  1965. tTitle: "",
  1966. tdetail: "",
  1967. templateC: {},
  1968. AttText: {},
  1969. AttTextType: 0,
  1970. AttTextIndex: 0,
  1971. cTemplate: "",
  1972. CourseType: [],
  1973. CourseTypeJson: {},
  1974. courseTypeId: [],
  1975. courseTypeSon: [],
  1976. clearArray: [],
  1977. loading: false,
  1978. toolType: 0,
  1979. inputShow: true,
  1980. toolIndex: 0,
  1981. cidType: 0,
  1982. answerQ: "",
  1983. };
  1984. },
  1985. computed: {
  1986. offsetLetfPx: function () {
  1987. //addnum可以直接在模板语法里面用,相当于data内的值
  1988. return (
  1989. $(".cru_select")[this.unitIndex] &&
  1990. $(".cru_select")[this.unitIndex].offsetLeft
  1991. );
  1992. },
  1993. },
  1994. methods: {
  1995. handleCheckAllChange(val) {
  1996. this.checkedCities = val ? cityOptions : [];
  1997. this.isIndeterminate = false;
  1998. },
  1999. handleCheckedCitiesChange(value) {
  2000. let checkedCount = value.length;
  2001. this.checkAll = checkedCount === this.cities.length;
  2002. this.isIndeterminate =
  2003. checkedCount > 0 && checkedCount < this.cities.length;
  2004. },
  2005. addHw(e) {
  2006. var el = e.currentTarget;
  2007. el.getElementsByTagName("input")[0].click();
  2008. },
  2009. change(val) {
  2010. console.log(val);
  2011. },
  2012. handleClose(done) {
  2013. done();
  2014. },
  2015. imgChange1(file, fileList, type, itemTaskIndex) {
  2016. if (type == 1) {
  2017. var _tmp = this.cover;
  2018. } else if (
  2019. type == 2 ||
  2020. type == 3 ||
  2021. type == 6 ||
  2022. type == 7 ||
  2023. type == 8
  2024. ) {
  2025. var _tmp =
  2026. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
  2027. .chapterData;
  2028. } else if (type == 4) {
  2029. var _tmp = this.unitJson[this.unitIndex].chapterInfo[0].fileList1;
  2030. } else {
  2031. var _tmp =
  2032. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
  2033. .homeworkList;
  2034. }
  2035. this.noneBtnImg = _tmp.length >= 1;
  2036. },
  2037. goTo(path) {
  2038. this.$router.push(path);
  2039. },
  2040. guid() {
  2041. var _num,
  2042. i,
  2043. _guid = "";
  2044. for (i = 0; i < 32; i++) {
  2045. _guid += Math.floor(Math.random() * 16).toString(16); //随机0 - 16 的数字 转变为16进制的字符串
  2046. _num = Math.floor((i - 7) / 4); //计算 (i-7)除4
  2047. if (_num > -1 && _num < 4 && i == 7 + 4 * _num) {
  2048. //会使guid中间加 "-" 形式为xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
  2049. _guid += "-";
  2050. }
  2051. }
  2052. return _guid;
  2053. },
  2054. lastSteps() {
  2055. if (this.steps == 4) {
  2056. // window.location.href =
  2057. // "./course.vue?userid=" + this.userid + "&oid=" + this.oid;
  2058. this.goTo("/course?userid=" + this.userid + "&oid=" + this.oid);
  2059. } else {
  2060. if (this.cidType == 0) {
  2061. this.steps--;
  2062. } else {
  2063. if (this.steps == 3) {
  2064. this.steps = 1;
  2065. }
  2066. }
  2067. }
  2068. },
  2069. navSteps(s) {
  2070. if (this.cidType == 0) {
  2071. if (s == 1) {
  2072. this.steps = 1;
  2073. }
  2074. if (s == 2) {
  2075. this.steps = 2;
  2076. }
  2077. if (s == 3) {
  2078. this.cTemplate = this.templateC.content;
  2079. this.dialogVisible2 = false;
  2080. this.steps = 3;
  2081. }
  2082. } else {
  2083. if (s == 1) {
  2084. this.steps = 1;
  2085. }
  2086. if (s == 3) {
  2087. this.cTemplate = this.templateC.content;
  2088. this.dialogVisible2 = false;
  2089. this.steps = 3;
  2090. }
  2091. }
  2092. },
  2093. nextSteps() {
  2094. if (this.cidType == 1) {
  2095. if (this.steps == 1) {
  2096. if (this.courseName != "") {
  2097. // || this.courseText != ""
  2098. this.steps = 3;
  2099. } else {
  2100. this.$message.error("请将信息填写完整");
  2101. return;
  2102. }
  2103. } else if (this.steps == 3) {
  2104. if (this.cid == "" || this.cid == undefined) {
  2105. if (this.courseName == "") {
  2106. // || this.courseText == ""
  2107. this.$message.error("请将信息填写完整");
  2108. return;
  2109. } else {
  2110. this.addWork();
  2111. this.steps++;
  2112. }
  2113. } else {
  2114. if (this.courseName == "") {
  2115. // || this.courseText == "" || this.cover.length == 0
  2116. this.$message.error("请将信息填写完整");
  2117. return;
  2118. } else {
  2119. this.updateWork();
  2120. this.steps++;
  2121. }
  2122. }
  2123. }
  2124. } else {
  2125. if (this.steps == 1) {
  2126. if (this.courseName != "") {
  2127. //|| this.courseText != ""
  2128. this.steps++;
  2129. } else {
  2130. this.$message.error("请将信息填写完整");
  2131. return;
  2132. }
  2133. } else if (this.steps == 2) {
  2134. if (this.templateC.id != "" || this.templateC.id != undefined) {
  2135. // this.$message.error("请选择文档");
  2136. // return;
  2137. this.cTemplate = this.templateC.content;
  2138. }
  2139. // this.cTemplate = this.templateC.content;
  2140. this.dialogVisible2 = false;
  2141. this.steps++;
  2142. } else if (this.steps == 3) {
  2143. if (this.cid == "" || this.cid == undefined) {
  2144. if (this.courseName == "") {
  2145. //|| this.courseText == ""
  2146. this.$message.error("请将信息填写完整");
  2147. return;
  2148. } else {
  2149. this.addWork();
  2150. this.steps++;
  2151. }
  2152. } else {
  2153. if (this.courseName == "") {
  2154. // || this.courseText == ""
  2155. this.$message.error("请将信息填写完整");
  2156. return;
  2157. } else {
  2158. this.updateWork();
  2159. this.steps++;
  2160. }
  2161. }
  2162. }
  2163. }
  2164. },
  2165. unitSet(i) {
  2166. this.unitIndex = i;
  2167. },
  2168. time() {
  2169. if (!this.now) {
  2170. this.now = new Date().getTime();
  2171. return true;
  2172. } else {
  2173. let time = new Date().getTime();
  2174. if (time - this.now > 3000) {
  2175. this.now = time;
  2176. return true;
  2177. } else {
  2178. return false;
  2179. }
  2180. }
  2181. },
  2182. deleteUnit(i) {
  2183. var _this = this;
  2184. if (_this.time()) {
  2185. _this
  2186. .$confirm("确定删除此单元吗?", "提示", {
  2187. confirmButtonText: "确定",
  2188. cancelButtonText: "取消",
  2189. type: "warning",
  2190. })
  2191. .then(() => {
  2192. _this.unitJson.splice(i, 1);
  2193. // var a = 0;
  2194. // if (_this.unitIndex > 0) {
  2195. // a = _this.unitIndex - 1;
  2196. // }
  2197. this.unitIndex = this.unitIndex - 1;
  2198. _this.$message.success("删除成功");
  2199. })
  2200. .catch(() => {
  2201. return;
  2202. });
  2203. }
  2204. },
  2205. deleteTool(itemTaskIndex, i) {
  2206. var _this = this;
  2207. if (_this.time()) {
  2208. _this
  2209. .$confirm("确定删除此工具吗?", "提示", {
  2210. confirmButtonText: "确定",
  2211. cancelButtonText: "取消",
  2212. type: "warning",
  2213. })
  2214. .then(() => {
  2215. _this.unitJson[_this.unitIndex].chapterInfo[0].taskJson[
  2216. itemTaskIndex
  2217. ].toolChoose.splice(i, 1);
  2218. _this.$message.success("删除成功");
  2219. })
  2220. .catch(() => {
  2221. return;
  2222. });
  2223. }
  2224. },
  2225. deleteTask(i) {
  2226. var _this = this;
  2227. if (_this.time()) {
  2228. _this
  2229. .$confirm("确定删除此任务吗?", "提示", {
  2230. confirmButtonText: "确定",
  2231. cancelButtonText: "取消",
  2232. type: "warning",
  2233. })
  2234. .then(() => {
  2235. _this.unitJson[_this.unitIndex].chapterInfo[0].taskJson.splice(
  2236. i,
  2237. 1
  2238. );
  2239. _this.$message.success("删除成功");
  2240. // _this.unitJson[_this.unitIndex].chapterInfo[0].taskJson[
  2241. // itemTaskIndex
  2242. // ].toolChoose.splice(i, 1);
  2243. // _this.$message.success("删除成功");
  2244. })
  2245. .catch(() => {
  2246. return;
  2247. });
  2248. }
  2249. },
  2250. handlePictureCardPreview(file) {
  2251. this.dialogImageUrl = file.url;
  2252. },
  2253. clean(i, c) {
  2254. this.unitJson[this.unitIndex].chapterInfo[i].fileList1.splice(c, 1);
  2255. },
  2256. handle_remove1(file, fileList, type) {
  2257. var _tmp = this.cover;
  2258. for (var i = 0, len = _tmp.length; i < len; i++) {
  2259. if (_tmp[i].uid == file.uid) {
  2260. _tmp.splice(i, 1);
  2261. break;
  2262. }
  2263. this.cover = _tmp;
  2264. }
  2265. this.noneBtnImg = _tmp.length >= 1;
  2266. },
  2267. addImg(e) {
  2268. var el = e.currentTarget;
  2269. el.getElementsByTagName("input")[0].click();
  2270. },
  2271. addChaptersTools(i) {
  2272. this.chapTools = [
  2273. {
  2274. tools: [],
  2275. toolDetail: "",
  2276. },
  2277. ];
  2278. this.chapCount = i;
  2279. this.dialogVisible4 = true;
  2280. },
  2281. isNoFinsh() {
  2282. this.$message.warning("功能正在开发中");
  2283. },
  2284. addAttText(i) {
  2285. this.AttText = {
  2286. title: "",
  2287. text: "",
  2288. };
  2289. this.taskCount = i;
  2290. this.AttTextType = 0;
  2291. this.$forceUpdate();
  2292. this.dialogVisible6 = true;
  2293. },
  2294. openLine(i) {
  2295. this.line = "";
  2296. this.lineCount = i;
  2297. this.lineType = 0;
  2298. this.$forceUpdate();
  2299. this.dialogVisible7 = true;
  2300. },
  2301. beforeUpload1(event, type) {
  2302. const loading = this.openLoading();
  2303. var file = event.file;
  2304. var credentials = {
  2305. accessKeyId: "AKIATLPEDU37QV5CHLMH",
  2306. secretAccessKey: "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",
  2307. }; //秘钥形式的登录上传
  2308. window.AWS.config.update(credentials);
  2309. window.AWS.config.region = "cn-northwest-1"; //设置区域
  2310. var bucket = new window.AWS.S3({ params: { Bucket: "ccrb" } }); //选择桶
  2311. var _this = this;
  2312. if (file) {
  2313. var params = {
  2314. Key:
  2315. file.name.split(".")[0] +
  2316. new Date().getTime() +
  2317. "." +
  2318. file.name.split(".")[1],
  2319. ContentType: file.type,
  2320. Body: file,
  2321. "Access-Control-Allow-Credentials": "*",
  2322. ACL: "public-read",
  2323. }; //key可以设置为桶的相抵路径,Body为文件, ACL最好要设置
  2324. var options = {
  2325. partSize: 2048 * 1024 * 1024,
  2326. queueSize: 2,
  2327. leavePartsOnError: true,
  2328. };
  2329. bucket
  2330. .upload(params, options)
  2331. .on("httpUploadProgress", function (evt) {
  2332. //这里可以写进度条
  2333. // console.log("Uploaded : " + parseInt((evt.loaded * 80) / evt.total) + '%');
  2334. })
  2335. .send(function (err, data) {
  2336. loading.close();
  2337. if (err) {
  2338. var a = _this.$refs.upload1.uploadFiles;
  2339. a.splice(a.length - 1, a.length);
  2340. _this.$message.error("上传失败");
  2341. } else {
  2342. _this.cover.push({
  2343. name: file.name,
  2344. url: data.Location,
  2345. uid: file.uid,
  2346. });
  2347. _this.imgChange1(null, null, 1, null);
  2348. console.log(data.Location);
  2349. }
  2350. });
  2351. }
  2352. },
  2353. beforeUpload(data) {
  2354. this.$refs.upload1.uploadFiles;
  2355. this.uploadLoading1 = true;
  2356. var file = data.file;
  2357. var credentials = {
  2358. accessKeyId: "AKIATLPEDU37QV5CHLMH",
  2359. secretAccessKey: "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",
  2360. }; //秘钥形式的登录上传
  2361. window.AWS.config.update(credentials);
  2362. window.AWS.config.region = "cn-northwest-1"; //设置区域
  2363. var bucket = new window.AWS.S3({ params: { Bucket: "ccrb" } }); //选择桶
  2364. var _this = this;
  2365. if (file) {
  2366. var params = {
  2367. Key:
  2368. file.name.split(".")[0] +
  2369. new Date().getTime() +
  2370. "." +
  2371. file.name.split(".")[1],
  2372. ContentType: file.type,
  2373. Body: file,
  2374. "Access-Control-Allow-Credentials": "*",
  2375. ACL: "public-read",
  2376. }; //key可以设置为桶的相抵路径,Body为文件, ACL最好要设置
  2377. var options = {
  2378. partSize: 2048 * 1024 * 1024,
  2379. queueSize: 2,
  2380. leavePartsOnError: true,
  2381. };
  2382. bucket
  2383. .upload(params, options)
  2384. .on("httpUploadProgress", function (evt) {
  2385. //这里可以写进度条
  2386. // console.log("Uploaded : " + parseInt((evt.loaded * 80) / evt.total) + '%');
  2387. })
  2388. .send(function (err, data) {
  2389. _this.uploadLoading1 = false;
  2390. if (err) {
  2391. var a = _this.$refs.upload1.uploadFiles;
  2392. a.splice(a.length - 1, a.length);
  2393. _this.$message.error("上传失败");
  2394. } else {
  2395. //上传成功处理
  2396. _this.unitJson[_this.unitIndex].chapterInfo[0].fileList1.push({
  2397. name: file.name,
  2398. url: data.Location,
  2399. uid: file.uid,
  2400. });
  2401. _this.imgChange();
  2402. console.log(data.Location);
  2403. }
  2404. });
  2405. }
  2406. },
  2407. onExceed() {
  2408. this.$message.error("课程封面仅支持上传一张,请删除后再进行上传");
  2409. },
  2410. beforeUpload2(event, unitIndex, type, itemTaskIndex) {
  2411. const loading = this.openLoading();
  2412. var file = event.target.files[0];
  2413. this.inputShow = false;
  2414. var credentials = {
  2415. accessKeyId: "AKIATLPEDU37QV5CHLMH",
  2416. secretAccessKey: "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",
  2417. }; //秘钥形式的登录上传
  2418. window.AWS.config.update(credentials);
  2419. window.AWS.config.region = "cn-northwest-1"; //设置区域
  2420. var bucket = new window.AWS.S3({ params: { Bucket: "ccrb" } }); //选择桶
  2421. var _this = this;
  2422. if (file) {
  2423. var params = {
  2424. Key:
  2425. file.name.split(".")[0] +
  2426. new Date().getTime() +
  2427. "." +
  2428. file.name.split(".")[1],
  2429. ContentType: file.type,
  2430. Body: file,
  2431. "Access-Control-Allow-Credentials": "*",
  2432. ACL: "public-read",
  2433. }; //key可以设置为桶的相抵路径,Body为文件, ACL最好要设置
  2434. var options = {
  2435. partSize: 2048 * 1024 * 1024,
  2436. queueSize: 2,
  2437. leavePartsOnError: true,
  2438. };
  2439. bucket
  2440. .upload(params, options)
  2441. .on("httpUploadProgress", function (evt) {
  2442. //这里可以写进度条
  2443. // console.log("Uploaded : " + parseInt((evt.loaded * 80) / evt.total) + '%');
  2444. })
  2445. .send(function (err, data) {
  2446. loading.close();
  2447. _this.inputShow = true;
  2448. if (err) {
  2449. var a = _this.$refs.upload1.uploadFiles;
  2450. a.splice(a.length - 1, a.length);
  2451. _this.$message.error("上传失败");
  2452. } else {
  2453. if (type == 2 || type == 3) {
  2454. _this.unitJson[unitIndex].chapterInfo[0].taskJson[
  2455. itemTaskIndex
  2456. ].chapterData.push({
  2457. name: file.name,
  2458. url: data.Location,
  2459. uid: file.uid,
  2460. type: type,
  2461. });
  2462. _this.imgChange1(null, null, type, itemTaskIndex);
  2463. } else if (type == 4) {
  2464. _this.unitJson[_this.unitIndex].chapterInfo[0].taskJson[
  2465. itemTaskIndex
  2466. ].fileList1.push({
  2467. name: file.name,
  2468. url: data.Location,
  2469. uid: file.uid,
  2470. });
  2471. _this.imgChange1(null, null, type, itemTaskIndex);
  2472. } else if (type == 5) {
  2473. _this.unitJson[_this.unitIndex].chapterInfo[0].taskJson[
  2474. itemTaskIndex
  2475. ].homeworkList.push({
  2476. name: file.name,
  2477. url: data.Location,
  2478. uid: file.uid,
  2479. });
  2480. _this.imgChange1(null, null, type, itemTaskIndex);
  2481. }
  2482. console.log(data.Location);
  2483. }
  2484. });
  2485. }
  2486. },
  2487. addunit() {
  2488. this.unitJson.push({
  2489. dyName: "", //单元标题
  2490. // dyText: "",
  2491. // startTime: "", //开始时间
  2492. // endTime: "", //结束时间
  2493. // isTalk: false, //是否开启评价
  2494. chapterInfo: [
  2495. {
  2496. isread: false,
  2497. chapterid: this.guid(),
  2498. title: "",
  2499. courseName: "",
  2500. taskJson: [
  2501. {
  2502. task: "",
  2503. taskDetail: "",
  2504. chapterData: [],
  2505. toolText: "",
  2506. toolChoose: [
  2507. {
  2508. tool: [],
  2509. toolDetail: "",
  2510. toolType: 0,
  2511. askCount: 1,
  2512. askTitle: "",
  2513. askJson: [{ askstitle: "", askItem: 1, checkList: [] }],
  2514. },
  2515. ],
  2516. isShowTools: false,
  2517. askCount: 1,
  2518. isFold: 0,
  2519. askTitle: "",
  2520. askJson: [{ askstitle: "", askItem: 1, checkList: [] }],
  2521. checkJson: [{ checkCount: [], checkPerent: [] }],
  2522. homeworkList: [],
  2523. },
  2524. ],
  2525. itemCount: 1,
  2526. // question: "",
  2527. fileList1: [],
  2528. video: [],
  2529. testData: [],
  2530. pData: [],
  2531. templateArray: [],
  2532. },
  2533. ],
  2534. });
  2535. setTimeout(() => {
  2536. this.unitIndex = this.unitJson.length - 1;
  2537. this.unitSet(this.unitIndex);
  2538. }, 0);
  2539. },
  2540. addToolFun(itemTaskIndex) {
  2541. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
  2542. itemTaskIndex
  2543. ].toolChoose.push({
  2544. tool: [],
  2545. toolDetail: "",
  2546. toolType: 0,
  2547. askCount: 1,
  2548. askTitle: "",
  2549. askJson: [{ askstitle: "", askItem: 1, checkList: [] }],
  2550. });
  2551. },
  2552. addTaskBorder() {
  2553. this.unitJson[this.unitIndex].chapterInfo[0].taskJson.push({
  2554. task: "",
  2555. taskDetail: "",
  2556. chapterData: [],
  2557. toolText: "",
  2558. toolChoose: [
  2559. {
  2560. tool: [],
  2561. toolDetail: "",
  2562. toolType: 0,
  2563. askCount: 1,
  2564. askTitle: "",
  2565. askJson: [{ askstitle: "", askItem: 1, checkList: [] }],
  2566. },
  2567. ],
  2568. isShowTools: false,
  2569. askCount: 1,
  2570. isFold: 0,
  2571. askTitle: "",
  2572. askJson: [{ askstitle: "", askItem: 1, checkList: [] }],
  2573. checkJson: [{ checkCount: [], checkPerent: [] }],
  2574. homeworkList: [],
  2575. });
  2576. },
  2577. add(e, i) {
  2578. var el = e.currentTarget;
  2579. el.getElementsByTagName("input")[0].click();
  2580. },
  2581. fold(i, e, type) {
  2582. var a = e.path[3];
  2583. var b = e.path[2];
  2584. if (type == 1) {
  2585. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[i].isFold = 1;
  2586. a.className += " smallTaskBorder";
  2587. b.className += " funBlockTop";
  2588. } else {
  2589. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[i].isFold = 0;
  2590. a.className = "taskBorder";
  2591. b.className = "funBlock";
  2592. }
  2593. console.log(e);
  2594. },
  2595. deleteHomeworkBox(unitIndex, index, i) {
  2596. this.unitJson[unitIndex].chapterInfo[index].taskJson[
  2597. this.taskCount
  2598. ].homeworkList.splice(i, 1);
  2599. },
  2600. getStudent() {
  2601. // let params = {
  2602. // cn: this.searchPeople,
  2603. // oid: this.oid,
  2604. // uid: this.userid,
  2605. // };
  2606. // this.ajax
  2607. // .get(this.$store.state.api + "selectProjectStudent", params)
  2608. // .then((res) => {
  2609. // this.studentJuri = res.data[0];
  2610. // })
  2611. // .catch((err) => {});
  2612. let params = {
  2613. oid: this.oid,
  2614. cu: "",
  2615. cn: this.searchPeople,
  2616. };
  2617. this.ajax
  2618. .get(this.$store.state.api + "selectStudentAdd", params)
  2619. .then((res) => {
  2620. this.studentJuri = res.data[0];
  2621. })
  2622. .catch((err) => {
  2623. this.isLoading = false;
  2624. console.error(err);
  2625. });
  2626. },
  2627. searchStudent() {
  2628. this.getStudent();
  2629. },
  2630. getChapterData(e, i, j, ic, type) {
  2631. e.stopPropagation();
  2632. this.updataC = true;
  2633. this.icc = ic;
  2634. if ((type == 2 || type == 3) && e.target.tagName !== "INPUT") {
  2635. console.log("还不能下载图片喔");
  2636. }
  2637. },
  2638. deleteChapterData(e, i, j, ic, taskI) {
  2639. // window.U.UF.EV.stopBubble();
  2640. e.stopPropagation();
  2641. this.unitJson[i].chapterInfo[j].taskJson[taskI].chapterData.splice(ic, 1);
  2642. },
  2643. updataVideoT(e, i, j, ic) {
  2644. e.stopPropagation();
  2645. this.unitJson[i].chapterInfo[j].taskJson[this.taskCount].chapterData[
  2646. ic
  2647. ].name = e.target.value;
  2648. },
  2649. upCd(e, i, j, ic) {
  2650. e.stopPropagation();
  2651. if (ic == 0) {
  2652. return;
  2653. }
  2654. var a =
  2655. this.unitJson[i].chapterInfo[j].taskJson[this.taskCount].chapterData[
  2656. ic - 1
  2657. ];
  2658. this.unitJson[i].chapterInfo[j].taskJson[this.taskCount].chapterData[
  2659. ic - 1
  2660. ] =
  2661. this.unitJson[i].chapterInfo[j].taskJson[this.taskCount].chapterData[
  2662. ic
  2663. ];
  2664. this.unitJson[i].chapterInfo[j].taskJson[this.taskCount].chapterData[ic] =
  2665. a;
  2666. },
  2667. downCd(e, i, j, ic) {
  2668. e.stopPropagation();
  2669. if (ic == this.unitJson[i].chapterInfo[j].chapterData.length - 1) {
  2670. return;
  2671. }
  2672. var a =
  2673. this.unitJson[i].chapterInfo[j].taskJson[this.taskCount].chapterData[
  2674. ic + 1
  2675. ];
  2676. this.unitJson[i].chapterInfo[j].taskJson[this.taskCount].chapterData[
  2677. ic + 1
  2678. ] =
  2679. this.unitJson[i].chapterInfo[j].taskJson[this.taskCount].chapterData[
  2680. ic
  2681. ];
  2682. this.unitJson[i].chapterInfo[j].taskJson[this.taskCount].chapterData[ic] =
  2683. a;
  2684. },
  2685. addWork() {
  2686. for (var i = 0; i < this.unitJson.length; i++) {
  2687. for (
  2688. var j = 0;
  2689. j < this.unitJson[i].chapterInfo[0].taskJson.length;
  2690. j++
  2691. ) {
  2692. if (this.unitJson[i].chapterInfo[0].taskJson[j].eList) {
  2693. this.unitJson[i].chapterInfo[0].taskJson[j].eList = this.unitJson[
  2694. i
  2695. ].chapterInfo[0].taskJson[j].eList.filter((ele) => {
  2696. return ele.value != "";
  2697. });
  2698. }
  2699. }
  2700. }
  2701. let params = [
  2702. {
  2703. uid: this.userid,
  2704. title: this.courseName,
  2705. brief: this.courseText.replace(/%/g, "%25"),
  2706. cover:
  2707. this.cover.length > 0
  2708. ? JSON.stringify(this.cover)
  2709. : JSON.stringify([
  2710. {
  2711. name: "noBanner.jpg",
  2712. url: "https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/noBanner1656409780264.jpg",
  2713. uid: 1656409780264,
  2714. status: "success",
  2715. },
  2716. ]),
  2717. astudent:
  2718. this.checkboxList.length > 0
  2719. ? JSON.stringify(this.checkboxList)
  2720. : "",
  2721. see: this.isTeacherSee == true ? 0 : 1,
  2722. chapters: JSON.stringify(this.unitJson),
  2723. template: this.cTemplate,
  2724. courseType: JSON.stringify(this.courseTypeId),
  2725. },
  2726. ];
  2727. this.ajax
  2728. // .post(this.$store.state.api + "addWork", params)
  2729. .post(this.$store.state.api + "addWorkNew", params)
  2730. .then((res) => {
  2731. this.$message({
  2732. message: "新增成功",
  2733. type: "success",
  2734. });
  2735. this.number = res.data.ordernumber;
  2736. this.courseId = res.data.courseId;
  2737. this.islogin = true;
  2738. })
  2739. .catch((err) => {
  2740. this.$message.error("新增失败");
  2741. console.error(err);
  2742. });
  2743. },
  2744. goCourse() {
  2745. window.parent.postMessage({ cid: this.courseId, type: "1" }, "*");
  2746. },
  2747. updateWork() {
  2748. for (var i = 0; i < this.unitJson.length; i++) {
  2749. for (
  2750. var j = 0;
  2751. j < this.unitJson[i].chapterInfo[0].taskJson.length;
  2752. j++
  2753. ) {
  2754. if (this.unitJson[i].chapterInfo[0].taskJson[j].eList) {
  2755. this.unitJson[i].chapterInfo[0].taskJson[j].eList = this.unitJson[
  2756. i
  2757. ].chapterInfo[0].taskJson[j].eList.filter((ele) => {
  2758. return ele.value != "";
  2759. });
  2760. }
  2761. }
  2762. }
  2763. let params = [
  2764. {
  2765. cid: this.cid,
  2766. title: this.courseName,
  2767. brief: this.courseText.replace(/%/g, "%25"),
  2768. cover: this.cover.length > 0 ? JSON.stringify(this.cover) : "",
  2769. astudent:
  2770. this.checkboxList.length > 0
  2771. ? JSON.stringify(this.checkboxList)
  2772. : "",
  2773. see: this.isTeacherSee == true ? 0 : 1,
  2774. chapters: JSON.stringify(this.unitJson),
  2775. template: this.myWord,
  2776. uid: this.userid,
  2777. courseType: JSON.stringify(this.courseTypeId),
  2778. },
  2779. ];
  2780. this.ajax
  2781. .post(this.$store.state.api + "updateWorkNew", params)
  2782. .then((res) => {
  2783. this.$message({
  2784. message: "修改成功",
  2785. type: "success",
  2786. });
  2787. this.number = this.nbOrder;
  2788. this.courseId = this.cid;
  2789. })
  2790. .catch((err) => {
  2791. this.$message.error("修改失败");
  2792. console.error(err);
  2793. });
  2794. },
  2795. guid() {
  2796. var _num,
  2797. i,
  2798. _guid = "";
  2799. for (i = 0; i < 32; i++) {
  2800. _guid += Math.floor(Math.random() * 16).toString(16); //随机0 - 16 的数字 转变为16进制的字符串
  2801. _num = Math.floor((i - 7) / 4); //计算 (i-7)除4
  2802. if (_num > -1 && _num < 4 && i == 7 + 4 * _num) {
  2803. //会使guid中间加 "-" 形式为xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
  2804. _guid += "-";
  2805. }
  2806. }
  2807. return _guid;
  2808. },
  2809. insertWord() {
  2810. this.dialogVisible1 = true;
  2811. this.updateBoolean2 = false;
  2812. this.tTitle = "";
  2813. this.tdetail = "";
  2814. },
  2815. addWord() {
  2816. this.unitJson[this.unitIndex].chapterInfo[0].fileList1.push({
  2817. name: this.tTitle,
  2818. content: this.tdetail,
  2819. uid: this.guid(),
  2820. });
  2821. this.dialogVisible1 = false;
  2822. },
  2823. upWord() {},
  2824. selectWord(uid, i, c) {
  2825. this.dialogVisible1 = true;
  2826. this.updateBoolean2 = true;
  2827. if (
  2828. uid == this.unitJson[this.unitIndex].chapterInfo[i].fileList1[c].uid
  2829. ) {
  2830. this.tTitle =
  2831. this.unitJson[this.unitIndex].chapterInfo[i].fileList1[c].name;
  2832. this.tdetail =
  2833. this.unitJson[this.unitIndex].chapterInfo[i].fileList1[c].content;
  2834. }
  2835. },
  2836. isAddPP() {
  2837. if (this.checkboxList.length > 0) {
  2838. this.$message({
  2839. message: "添加成功",
  2840. type: "success",
  2841. });
  2842. this.dialogVisible3 = false;
  2843. } else {
  2844. this.$message({
  2845. message: "请添加课程成员",
  2846. type: "error",
  2847. });
  2848. }
  2849. },
  2850. getTemplate() {
  2851. this.ajax
  2852. .get(this.$store.state.api + "getCourseTemplateT", "")
  2853. .then((res) => {
  2854. this.templateArray = res.data[0];
  2855. })
  2856. .catch((err) => {});
  2857. },
  2858. clearChoose() {
  2859. this.clearArray.splice(this.templateC.id, 1);
  2860. this.dialogVisible2 = false;
  2861. },
  2862. clearAttText() {
  2863. this.AttText = {
  2864. title: "",
  2865. text: "",
  2866. };
  2867. this.dialogVisible6 = false;
  2868. },
  2869. clearLine() {
  2870. this.line = "";
  2871. this.dialogVisible7 = false;
  2872. },
  2873. checkTemplate(res) {
  2874. let _this = this;
  2875. _this
  2876. .$confirm("确定选择此模板吗?", "提示", {
  2877. confirmButtonText: "确定",
  2878. cancelButtonText: "取消",
  2879. type: "warning",
  2880. })
  2881. .then(() => {
  2882. _this.unitJson = JSON.parse(res.chapters);
  2883. _this.steps++;
  2884. })
  2885. .catch(() => {
  2886. return;
  2887. });
  2888. // this.clearArray.push(res.id);
  2889. // this.templateC = res;
  2890. // this.cTemplate = res.content;
  2891. // this.dialogVisible2 = true;
  2892. },
  2893. checkTemplate1(w) {
  2894. this.steps++;
  2895. // this.clearArray.splice(0, this.clearArray.length);
  2896. // this.templateC.title = "我的文档";
  2897. // this.cTemplate = w != "undefined" ? w : "";
  2898. // this.dialogVisible2 = true;
  2899. },
  2900. checkTemplate2() {
  2901. let _this = this;
  2902. _this
  2903. .$confirm("确定选择空模板吗?", "提示", {
  2904. confirmButtonText: "确定",
  2905. cancelButtonText: "取消",
  2906. type: "warning",
  2907. })
  2908. .then(() => {
  2909. _this.unitJson = [
  2910. {
  2911. dyName: "", //单元标题
  2912. // dyText: "",
  2913. // startTime: "", //开始时间
  2914. // endTime: "", //结束时间
  2915. // isTalk: false, //是否开启评价
  2916. chapterInfo: [
  2917. {
  2918. isread: false,
  2919. chapterid: this.guid(),
  2920. title: "",
  2921. courseName: "",
  2922. taskJson: [
  2923. {
  2924. task: "",
  2925. taskDetail: "",
  2926. chapterData: [],
  2927. toolText: "",
  2928. toolChoose: [
  2929. {
  2930. tool: [],
  2931. toolDetail: "",
  2932. toolType: 0,
  2933. askCount: 1,
  2934. askTitle: "",
  2935. askJson: [
  2936. { askstitle: "", askItem: 1, checkList: [] },
  2937. ],
  2938. },
  2939. ],
  2940. isShowTools: false,
  2941. askCount: 1,
  2942. isFold: 0,
  2943. askTitle: "",
  2944. askJson: [{ askstitle: "", askItem: 1, checkList: [] }],
  2945. checkJson: [{ checkCount: [], checkPerent: [] }],
  2946. homeworkList: [],
  2947. },
  2948. ],
  2949. itemCount: 1,
  2950. // question: "",
  2951. fileList1: [],
  2952. video: [],
  2953. testData: [],
  2954. pData: [],
  2955. templateArray: [],
  2956. },
  2957. ],
  2958. },
  2959. ];
  2960. this.steps++;
  2961. })
  2962. .catch(() => {
  2963. return;
  2964. });
  2965. },
  2966. wordNext() {
  2967. // this.cTemplate = this.templateC.content;
  2968. // this.steps++;
  2969. this.dialogVisible2 = false;
  2970. },
  2971. isAddOrUpdateAttText() {
  2972. if (this.AttTextType == 0) {
  2973. this.addAttTextMessage();
  2974. } else {
  2975. this.updateAttText();
  2976. }
  2977. },
  2978. isAddOrUpdateLine() {
  2979. if (this.lineType == 0) {
  2980. this.addLine();
  2981. } else {
  2982. this.updateLine();
  2983. }
  2984. },
  2985. addAttTextMessage() {
  2986. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
  2987. this.taskCount
  2988. ].chapterData.push({
  2989. name: this.AttText.title,
  2990. url: this.AttText.text,
  2991. type: 6,
  2992. });
  2993. this.imgChange1(null, null, 6, this.taskCount);
  2994. this.dialogVisible6 = false;
  2995. },
  2996. selectAttText(itemTaskIndex, i) {
  2997. this.AttText.title =
  2998. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
  2999. itemTaskIndex
  3000. ].chapterData[i].name;
  3001. this.AttText.text =
  3002. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
  3003. itemTaskIndex
  3004. ].chapterData[i].url;
  3005. this.taskCount = itemTaskIndex;
  3006. this.AttTextIndex = i;
  3007. this.AttTextType = 1;
  3008. this.dialogVisible6 = true;
  3009. },
  3010. updateAttText() {
  3011. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
  3012. this.taskCount
  3013. ].chapterData[this.AttTextIndex].name = this.AttText.title;
  3014. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
  3015. this.taskCount
  3016. ].chapterData[this.AttTextIndex].url = this.AttText.text;
  3017. this.dialogVisible6 = false;
  3018. },
  3019. addLine() {
  3020. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
  3021. this.lineCount
  3022. ].chapterData.push({
  3023. name: "链接",
  3024. url: this.line,
  3025. type: 8,
  3026. });
  3027. this.imgChange1(null, null, 8, this.lineCount);
  3028. this.dialogVisible7 = false;
  3029. },
  3030. selectLine(itemTaskIndex, i) {
  3031. this.line =
  3032. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
  3033. itemTaskIndex
  3034. ].chapterData[i].url;
  3035. this.taskCount = itemTaskIndex;
  3036. this.lineCount = i;
  3037. this.lineType = 1;
  3038. this.dialogVisible7 = true;
  3039. },
  3040. updateLine() {
  3041. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
  3042. this.taskCount
  3043. ].chapterData[this.lineCount].url = this.line;
  3044. this.dialogVisible7 = false;
  3045. },
  3046. addPP() {
  3047. this.dialogVisible3 = true;
  3048. },
  3049. goTo(path) {
  3050. this.$router.push(path);
  3051. },
  3052. openTools(itemTaskIndex, i, toolIndex) {
  3053. // if (i == 1) {
  3054. // window.parent.postMessage({ tools: "1" }, "*");
  3055. // } else if (i == 2) {
  3056. // window.parent.postMessage({ tools: "2" }, "*");
  3057. // } else if (i == 3) {
  3058. // window.parent.postMessage({ tools: "3" }, "*");
  3059. // } else if (i == 4) {
  3060. // window.parent.postMessage({ tools: "4" }, "*");
  3061. // }
  3062. // // else if(i == 5){
  3063. // // window.parent.postMessage({ tools: "5" }, "*");
  3064. // // }
  3065. // else {
  3066. // window.parent.postMessage({ tools: "6" }, "*");
  3067. // }
  3068. this.toolIndex = toolIndex;
  3069. this.taskCount = itemTaskIndex;
  3070. if (i == 4) {
  3071. if (toolIndex == null) {
  3072. var a =
  3073. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
  3074. .chapterData;
  3075. for (var i = 0; i < a.length; i++) {
  3076. if (a[i].url == 4 && a[i].askJson.askTitle != "") {
  3077. this.askJson =
  3078. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
  3079. itemTaskIndex
  3080. ].chapterData[i].askJson;
  3081. }
  3082. }
  3083. // this.askJson =
  3084. // this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
  3085. // itemTaskIndex
  3086. // ].chapterData;
  3087. } else {
  3088. this.askJson = JSON.parse(
  3089. JSON.stringify(
  3090. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
  3091. itemTaskIndex
  3092. ].toolChoose[toolIndex]
  3093. )
  3094. );
  3095. }
  3096. this.dialogVisible5 = true;
  3097. } else if (i == 15) {
  3098. this.answerQ = this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
  3099. itemTaskIndex
  3100. ].toolChoose[toolIndex].answerQ
  3101. ? JSON.parse(
  3102. JSON.stringify(
  3103. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
  3104. itemTaskIndex
  3105. ].toolChoose[toolIndex].answerQ
  3106. )
  3107. )
  3108. : "";
  3109. this.dialogVisible8 = true;
  3110. }
  3111. },
  3112. chapAddTools(i) {
  3113. if (this.chapTools[0].tools.length == 0) {
  3114. this.chapTools[0].tools.push(i);
  3115. } else {
  3116. if (this.chapTools[0].tools.indexOf(i) != -1) {
  3117. this.chapTools[0].tools.splice(this.chapTools[0].tools.indexOf(i), 1);
  3118. } else {
  3119. this.chapTools[0].tools.push(i);
  3120. }
  3121. // if (this.chapTools.tools != null && this.chapTools.tools != i) {
  3122. // this.$message({
  3123. // message: "每个工具只能添加一个",
  3124. // type: "error",
  3125. // });
  3126. // } else {
  3127. // this.chapTools.tools = null;
  3128. // }
  3129. }
  3130. this.$forceUpdate();
  3131. },
  3132. addChaptersDataTools() {
  3133. if (this.chapTools[0].tools.indexOf(4) != -1) {
  3134. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
  3135. this.chapCount
  3136. ].chapterData.push({
  3137. name: this.chapTools[0].toolDetail,
  3138. url: this.chapTools[0].tools,
  3139. type: 7,
  3140. askJson: this.askJson,
  3141. });
  3142. } else {
  3143. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
  3144. this.chapCount
  3145. ].chapterData.push({
  3146. name: this.chapTools[0].toolDetail,
  3147. url: this.chapTools[0].tools,
  3148. type: 7,
  3149. });
  3150. }
  3151. this.imgChange1(null, null, 7, this.chapCount);
  3152. this.dialogVisible4 = false;
  3153. },
  3154. addTools(i, itemTaskIndex, toolIndex) {
  3155. if (
  3156. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
  3157. .toolChoose[toolIndex].tool.length == 0
  3158. ) {
  3159. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
  3160. itemTaskIndex
  3161. ].toolChoose[toolIndex].tool.push(i);
  3162. } else {
  3163. if (
  3164. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
  3165. itemTaskIndex
  3166. ].toolChoose[toolIndex].tool.indexOf(i) != -1
  3167. ) {
  3168. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
  3169. itemTaskIndex
  3170. ].toolChoose[toolIndex].tool.splice(
  3171. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
  3172. itemTaskIndex
  3173. ].toolChoose[toolIndex].tool.indexOf(i),
  3174. 1
  3175. );
  3176. } else {
  3177. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
  3178. itemTaskIndex
  3179. ].toolChoose[toolIndex].tool.push(i);
  3180. }
  3181. console.log(
  3182. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
  3183. .toolChoose[toolIndex].tool
  3184. );
  3185. // if (
  3186. // this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
  3187. // .toolChoose[toolIndex].tool != null &&
  3188. // this.unitJson[this.unitIndex].chapterInfo[0].taskJson[itemTaskIndex]
  3189. // .toolChoose[toolIndex].tool != i
  3190. // ) {
  3191. // this.$message({
  3192. // message: "每个工具只能添加一个",
  3193. // type: "error",
  3194. // });
  3195. // } else {
  3196. // this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
  3197. // itemTaskIndex
  3198. // ].toolChoose[toolIndex].tool = null;
  3199. // }
  3200. }
  3201. this.$forceUpdate();
  3202. },
  3203. // cleanAsk(p) {
  3204. // if (this.unitJson[this.unitIndex].chapterInfo[0].askCount == 1) {
  3205. // this.unitJson[this.unitIndex].chapterInfo[0].toolChoose.splice(
  3206. // this.unitJson[this.unitIndex].chapterInfo[0].toolChoose.indexOf(p),
  3207. // 1
  3208. // );
  3209. // this.unitJson[this.unitIndex].chapterInfo[0].askTitle = "";
  3210. // this.unitJson[this.unitIndex].chapterInfo[0].askJson = [];
  3211. // this.unitJson[this.unitIndex].chapterInfo[0].askJson.push({
  3212. // askstitle: "",
  3213. // askItem: 1,
  3214. // checkList: [],
  3215. // });
  3216. // this.dialogVisible5 = false;
  3217. // } else {
  3218. // this.dialogVisible5 = false;
  3219. // }
  3220. // },
  3221. addAskList() {
  3222. // this.askJson.checkJson.push({
  3223. // checkCount: [],
  3224. // checkPerent: [],
  3225. // });
  3226. this.askJson.askJson.push({
  3227. askstitle: "",
  3228. askItem: 1,
  3229. checkList: [],
  3230. });
  3231. this.askJson.askCount++;
  3232. },
  3233. deleteAskList() {
  3234. this.askJson.askJson.splice(-1);
  3235. this.askJson.askCount--;
  3236. },
  3237. addcheckList(json) {
  3238. json.checkList.length++;
  3239. json.askItem++;
  3240. },
  3241. deletecheckList(json) {
  3242. json.checkList.length--;
  3243. json.askItem--;
  3244. },
  3245. addAsk() {
  3246. // this.unitJson[this.unitIndex].chapterInfo[0].taskJson[this.taskCount]
  3247. if (this.askJson.askTitle === "") {
  3248. this.$message.error("问卷调查标题不能为空!");
  3249. return;
  3250. }
  3251. var aj = this.askJson.askJson;
  3252. var b = 1;
  3253. for (var i = 0; i < aj.length; i++) {
  3254. if (aj[i].askstitle === "") {
  3255. var a = 1;
  3256. for (let index = 0; index < aj[i].askItem; index++) {
  3257. const element = aj[i].checkList[index]
  3258. ? aj[i].checkList[index]
  3259. : "";
  3260. if (element != "") {
  3261. b++;
  3262. this.$message.error("填写了问卷调查选项,问卷调查题目不能为空!");
  3263. return;
  3264. } else {
  3265. a++;
  3266. }
  3267. }
  3268. if (b == 1) {
  3269. this.$message.error("至少填写一个问题");
  3270. return;
  3271. }
  3272. // if (a > 1) {
  3273. // aj.splice(i, 1);
  3274. // }
  3275. } else if (aj[i].askstitle != "") {
  3276. for (let index = 0; index < aj[i].askItem; index++) {
  3277. const element = aj[i].checkList[index]
  3278. ? aj[i].checkList[index]
  3279. : "";
  3280. var index = 0;
  3281. for (var z = 0; z < aj[i].checkList.length; z++) {
  3282. var checkC = aj[i].checkList[z] ? aj[i].checkList[z] : "";
  3283. if (checkC != "") {
  3284. index++;
  3285. } else {
  3286. this.$message.error("问卷调查选项不能为空!");
  3287. return;
  3288. }
  3289. }
  3290. b++;
  3291. if (index < 2) {
  3292. this.$message.error(
  3293. "填写了问卷调查的题目,问卷调查选项至少要有两项!"
  3294. );
  3295. return;
  3296. }
  3297. // if (element == "") {
  3298. // this.$message.error(
  3299. // "填写了问卷调查的题目,问卷调查选项不能为空!"
  3300. // );
  3301. // return;
  3302. // }
  3303. }
  3304. }
  3305. }
  3306. this.askJson.askJson = this.askJson.askJson.filter((el) => {
  3307. var elc = el.checkList.filter((element) => {
  3308. return element != "";
  3309. });
  3310. return el.askstitle != "" && elc.length != 0;
  3311. });
  3312. if (!this.dialogVisible4) {
  3313. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
  3314. this.taskCount
  3315. ].toolChoose[this.toolIndex] = this.askJson;
  3316. }
  3317. this.dialogVisible5 = false;
  3318. },
  3319. addAnswer() {
  3320. if (this.answerQ == "") {
  3321. this.$message.error("请输入您想要问的问题");
  3322. return;
  3323. }
  3324. this.unitJson[this.unitIndex].chapterInfo[0].taskJson[
  3325. this.taskCount
  3326. ].toolChoose[this.toolIndex].answerQ = this.answerQ;
  3327. this.dialogVisible8 = false;
  3328. },
  3329. selectCourseDetail() {
  3330. if (this.cid == "" || this.cid == undefined) {
  3331. console.log("这是新增课程");
  3332. } else {
  3333. this.cidType = 1;
  3334. let params = {
  3335. cid: this.cid,
  3336. };
  3337. this.ajax
  3338. .get(this.$store.state.api + "select_course_detail", params)
  3339. .then((res) => {
  3340. this.loading = true;
  3341. this.unitJson = JSON.parse(res.data[0][0].chapters);
  3342. // this.unitJson[0].chapterInfo = JSON.parse(res.data[0][0].chapters);
  3343. for (var j in this.unitJson) {
  3344. for (var i in this.unitJson[j].chapterInfo) {
  3345. this.unitJson[j].chapterInfo[i].taskJson[
  3346. this.taskCount
  3347. ].toolChoose = this.unitJson[j].chapterInfo[i].taskJson[
  3348. this.taskCount
  3349. ].toolChoose
  3350. ? this.unitJson[j].chapterInfo[i].taskJson[this.taskCount]
  3351. .toolChoose
  3352. : [];
  3353. }
  3354. }
  3355. // this.unitJson[0].dyText = "";
  3356. this.courseName = res.data[0][0].title;
  3357. this.courseText = res.data[0][0].brief;
  3358. this.cover = JSON.parse(res.data[0][0].cover);
  3359. this.noneBtnImg = this.cover.length >= 1;
  3360. this.checkboxList =
  3361. res.data[0][0].course_student.length > 0
  3362. ? JSON.parse(res.data[0][0].course_student)
  3363. : [];
  3364. this.isTeacherSee =
  3365. res.data[0][0].is_teacher_look == 0 ? true : false;
  3366. this.myWord = res.data[0][0].template;
  3367. this.templateC.id = "123";
  3368. this.nbOrder = res.data[0][0].ordernumber;
  3369. // this.CourseType[0] = res.data[1];
  3370. // this.selectType();
  3371. for (var i = 0; i < res.data[1].length; i++) {
  3372. // this.courseTypeId[this.CourseType[0][i].typePid] =
  3373. // this.CourseType[0][i].typeid;
  3374. this.courseTypeId.push(res.data[1][i].typeid);
  3375. }
  3376. console.log(this.courseTypeId);
  3377. this.$forceUpdate();
  3378. })
  3379. .catch((err) => {
  3380. console.error(err);
  3381. });
  3382. }
  3383. },
  3384. getTypeName() {
  3385. console.log(this.courseTypeId);
  3386. this.$forceUpdate();
  3387. },
  3388. selectType() {
  3389. this.ajax
  3390. .get(this.$store.state.api + "selectType")
  3391. .then((res) => {
  3392. this.CourseType = res.data;
  3393. for (var i = 0; i < res.data[0].length; i++) {
  3394. if (!this.cid) {
  3395. this.courseTypeId[res.data[0][i].id] = "";
  3396. }
  3397. for (var j = 0; j < res.data[1].length; j++) {
  3398. if (res.data[0][i].id == res.data[1][j].pid) {
  3399. if (!this.CourseTypeJson[res.data[0][i].id]) {
  3400. this.CourseTypeJson[res.data[0][i].id] = [];
  3401. }
  3402. this.CourseTypeJson[res.data[0][i].id].push(res.data[1][j]);
  3403. }
  3404. }
  3405. }
  3406. })
  3407. .catch((err) => {
  3408. console.error(err);
  3409. });
  3410. },
  3411. /*添加评价 */
  3412. addEList(index, tIndex) {
  3413. this.unitJson[index].chapterInfo[0].taskJson[tIndex].eList
  3414. ? this.unitJson[index].chapterInfo[0].taskJson[tIndex].eList.push({
  3415. value: "",
  3416. detail: "",
  3417. score: 5,
  3418. })
  3419. : (this.unitJson[index].chapterInfo[0].taskJson[tIndex].eList = [
  3420. { value: "", detail: "", score: 5 },
  3421. ]);
  3422. this.$forceUpdate();
  3423. },
  3424. deletEList(index, tIndex, eIndex) {
  3425. this.unitJson[index].chapterInfo[0].taskJson[tIndex].eList.splice(
  3426. eIndex,
  3427. 1
  3428. );
  3429. this.$forceUpdate();
  3430. },
  3431. setEListStar() {
  3432. this.$forceUpdate();
  3433. },
  3434. },
  3435. created() {
  3436. this.getStudent();
  3437. this.getTemplate();
  3438. this.selectType();
  3439. this.loading = false;
  3440. setTimeout(() => {
  3441. this.selectCourseDetail();
  3442. }, 500);
  3443. },
  3444. };
  3445. </script>
  3446. <style scoped>
  3447. .dialog_diy >>> .el-dialog__header {
  3448. background: #3d67bc !important;
  3449. padding: 15px 20px;
  3450. }
  3451. .dialog_diy >>> .el-dialog__title {
  3452. color: #fff;
  3453. }
  3454. .dialog_diy >>> .el-dialog__headerbtn {
  3455. top: 19px;
  3456. }
  3457. .dialog_diy >>> .el-dialog__headerbtn .el-dialog__close {
  3458. color: #fff;
  3459. }
  3460. .dialog_diy >>> .el-dialog__headerbtn .el-dialog__close:hover {
  3461. color: #fff;
  3462. }
  3463. .dialog_diy >>> .el-dialog__body,
  3464. .dialog_diy >>> .el-dialog__footer {
  3465. background: #fafafa;
  3466. }
  3467. .left {
  3468. border-right: 1px solid rgb(60, 94, 143);
  3469. display: flex;
  3470. flex-direction: column;
  3471. align-items: center;
  3472. min-height: 600px;
  3473. width: 385px;
  3474. height: 80%;
  3475. }
  3476. .tips {
  3477. color: rgb(128, 128, 128);
  3478. font-size: 12px;
  3479. width: 270px;
  3480. margin: 40px;
  3481. }
  3482. .pb_content {
  3483. /* background: #fff; */
  3484. /* height: 100%; */
  3485. height: auto !important;
  3486. margin: 20px 20px 20px 20px;
  3487. }
  3488. .pb_content_body {
  3489. width: 100% !important;
  3490. height: 100%;
  3491. }
  3492. .info_solid {
  3493. width: 270px;
  3494. height: 30px;
  3495. border-left: 1px solid #bdbdbd;
  3496. margin: 10px 0px 10px 30px;
  3497. }
  3498. .info_steps {
  3499. width: 270px;
  3500. font-size: 0.875rem;
  3501. display: flex;
  3502. align-items: center;
  3503. }
  3504. .info_steps span:nth-child(1) {
  3505. width: 30px;
  3506. height: 30px;
  3507. background: rgba(0, 0, 0, 0.38);
  3508. display: block;
  3509. color: #fff;
  3510. border-radius: 40px;
  3511. text-align: center;
  3512. line-height: 30px;
  3513. }
  3514. .steps_active {
  3515. background: #3d67bc !important;
  3516. }
  3517. .info_steps span:nth-child(2) {
  3518. margin-left: 5px;
  3519. }
  3520. .right {
  3521. height: 100%;
  3522. width: 100%;
  3523. }
  3524. .basic_box {
  3525. width: 90%;
  3526. margin: 0 auto;
  3527. position: relative;
  3528. }
  3529. .basic_box_success {
  3530. width: 80%;
  3531. min-height: 455px;
  3532. margin: 50px auto;
  3533. position: relative;
  3534. text-align: center;
  3535. border-bottom: 1px solid #bfbfbf;
  3536. }
  3537. .info_title {
  3538. font-size: 1.5em;
  3539. margin: 20px 30px 20px 30px;
  3540. }
  3541. .bInfo_title {
  3542. font-size: 20px;
  3543. text-align: left;
  3544. margin-top: 20px;
  3545. margin-bottom: 10px;
  3546. font-weight: 700;
  3547. }
  3548. .small_title {
  3549. font-size: 14px;
  3550. line-height: 40px;
  3551. }
  3552. .binfo_input {
  3553. font: inherit;
  3554. color: currentColor;
  3555. width: 100%;
  3556. margin: 0;
  3557. padding: 15px 14px;
  3558. display: block;
  3559. min-width: 0;
  3560. outline: none;
  3561. box-sizing: content-box;
  3562. background: none;
  3563. -webkit-tap-highlight-color: transparent;
  3564. border: 1px solid rgba(0, 0, 0, 0.23);
  3565. border-radius: 4px;
  3566. box-sizing: border-box;
  3567. resize: none;
  3568. }
  3569. .binfo_input:focus-visible {
  3570. border: 1px solid rgba(61, 103, 188);
  3571. }
  3572. .chapter_beizhu {
  3573. font-size: 12px;
  3574. font-weight: bold;
  3575. float: right;
  3576. color: rgb(128, 128, 128);
  3577. margin-top: 5px;
  3578. }
  3579. .chapter_uploadBox1 {
  3580. text-align: left;
  3581. background-color: rgb(242, 242, 242);
  3582. width: 100%;
  3583. height: 67px;
  3584. padding: 0px 15px;
  3585. border-radius: 8px;
  3586. overflow: hidden;
  3587. font-size: 16px;
  3588. box-sizing: border-box;
  3589. position: relative;
  3590. }
  3591. .chapter_add {
  3592. width: 100%;
  3593. height: 32px;
  3594. margin-top: 15px;
  3595. cursor: pointer;
  3596. }
  3597. .chapter_add_l {
  3598. margin-left: 5px;
  3599. width: 30px;
  3600. height: 30px;
  3601. float: left;
  3602. border: 1px solid #aaa;
  3603. color: #aaa;
  3604. border-radius: 50%;
  3605. font-size: 25px;
  3606. text-align: center;
  3607. }
  3608. .chapter_add_r {
  3609. font-size: 18px;
  3610. height: 40px;
  3611. line-height: 30px;
  3612. text-indent: 10px;
  3613. color: #aaa;
  3614. }
  3615. .chapter_add_r span {
  3616. font-size: 12px;
  3617. color: rgb(204, 204, 204);
  3618. }
  3619. .chapter_add_input {
  3620. display: none;
  3621. }
  3622. .line {
  3623. width: 85%;
  3624. margin: 0 auto;
  3625. border-top: 1px solid #e5e5e5;
  3626. margin-top: 20px;
  3627. }
  3628. .info_btnBox {
  3629. width: 100%;
  3630. display: flex;
  3631. justify-content: space-evenly;
  3632. margin: 20px 0 25px 0;
  3633. padding-bottom: 20px;
  3634. }
  3635. .info_btn,
  3636. .teacherWord {
  3637. color: #fff;
  3638. background-color: #6a8ed5;
  3639. padding: 8px 24px;
  3640. font-size: 0.9375rem;
  3641. box-shadow: 0px 1px 3px 0px rgb(0 0 0 / 20%), 0px 2px 2px 0px rgb(0 0 0 / 14%),
  3642. 0px 3px 1px -2px rgb(0 0 0 / 12%);
  3643. min-width: 64px;
  3644. font-weight: 500;
  3645. border-radius: 4px;
  3646. box-sizing: border-box;
  3647. border: none;
  3648. cursor: pointer;
  3649. }
  3650. .teacherWord {
  3651. width: 105px !important;
  3652. text-align: center !important;
  3653. line-height: 36px !important;
  3654. padding: 0 !important;
  3655. font-size: 14px !important;
  3656. margin: 10px 0 !important;
  3657. }
  3658. .wordTeacher {
  3659. display: flex;
  3660. flex-direction: column;
  3661. width: 20%;
  3662. text-align: center;
  3663. font-size: 14px;
  3664. margin: 30px 30px 0 10px;
  3665. background: #fff;
  3666. position: relative;
  3667. border-radius: 5px;
  3668. padding: 25px 0px;
  3669. }
  3670. .wordPic {
  3671. margin: 0 auto;
  3672. width: 60px;
  3673. height: 60px;
  3674. cursor: pointer;
  3675. }
  3676. .deleteWord {
  3677. width: 22px;
  3678. height: 22px;
  3679. position: absolute;
  3680. right: 20px;
  3681. top: -10px;
  3682. cursor: pointer;
  3683. }
  3684. .wordPic > img,
  3685. .deleteWord > img,
  3686. .addToolImg > img {
  3687. width: 100%;
  3688. height: 100%;
  3689. }
  3690. .info_btn:hover {
  3691. background-color: #4f7cd5 !important;
  3692. }
  3693. .cru_selectBox {
  3694. display: flex;
  3695. margin: 24px 0 10px;
  3696. flex-wrap: nowrap;
  3697. white-space: nowrap;
  3698. overflow: auto;
  3699. position: relative;
  3700. height: 47px;
  3701. }
  3702. .cru_selectBox::-webkit-scrollbar {
  3703. /*滚动条整体样式*/
  3704. width: 6px;
  3705. /*高宽分别对应横竖滚动条的尺寸*/
  3706. height: 6px;
  3707. }
  3708. /*定义滚动条轨道 内阴影+圆角*/
  3709. .cru_selectBox::-webkit-scrollbar-track {
  3710. border-radius: 10px;
  3711. background-color: #eee;
  3712. }
  3713. /*定义滑块 内阴影+圆角*/
  3714. .cru_selectBox::-webkit-scrollbar-thumb {
  3715. border-radius: 10px;
  3716. -webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.3);
  3717. background-color: rgba(0, 0, 0, 0.1);
  3718. }
  3719. .cru_line {
  3720. position: absolute;
  3721. bottom: 0px;
  3722. transition: all 0.5s;
  3723. left: 0px;
  3724. width: 125px;
  3725. margin-left: -25px;
  3726. }
  3727. .cru_select {
  3728. font-size: 21px;
  3729. margin-right: 37px;
  3730. margin-left: 5px;
  3731. cursor: pointer;
  3732. color: #a6a6a6;
  3733. }
  3734. .cru_selected {
  3735. color: #0b7fc2 !important;
  3736. }
  3737. .chapter_contentbox {
  3738. display: flex;
  3739. align-items: center;
  3740. margin-top: 15px;
  3741. }
  3742. .chapter_contentbox div:nth-child(1) {
  3743. width: 150px;
  3744. margin: 0px;
  3745. font-size: 2em;
  3746. color: black;
  3747. display: block;
  3748. white-space: nowrap;
  3749. overflow: hidden;
  3750. text-overflow: ellipsis;
  3751. font-weight: 600;
  3752. }
  3753. .chapter_contentbox div:nth-child(2) {
  3754. width: 380px;
  3755. }
  3756. .chapter_contentbox div:nth-child(3),
  3757. .remove {
  3758. background-image: url(../../assets/remove.png);
  3759. cursor: pointer;
  3760. opacity: 0.5;
  3761. width: 40px;
  3762. height: 50px;
  3763. background-repeat: no-repeat;
  3764. background-position: 5px 10px;
  3765. }
  3766. .binfo_input {
  3767. font: inherit;
  3768. color: currentColor;
  3769. width: 100%;
  3770. margin: 0;
  3771. padding: 15px 14px;
  3772. display: block;
  3773. min-width: 0;
  3774. outline: none;
  3775. box-sizing: content-box;
  3776. background: none;
  3777. border: 1px solid rgba(0, 0, 0, 0.23);
  3778. border-radius: 4px;
  3779. box-sizing: border-box;
  3780. background: #fff;
  3781. }
  3782. .binfo_input:focus-visible {
  3783. border: 1px solid rgba(61, 103, 188);
  3784. }
  3785. .time {
  3786. display: flex;
  3787. margin: 35px 0 80px 0;
  3788. }
  3789. .chapter_btnbox {
  3790. width: 160px;
  3791. border-radius: 5px;
  3792. border: 2px dashed gray;
  3793. display: flex;
  3794. padding: 8px 50px;
  3795. align-items: center;
  3796. justify-content: center;
  3797. margin: 30px auto 0;
  3798. cursor: pointer;
  3799. }
  3800. .icon_add {
  3801. position: relative;
  3802. width: 24px;
  3803. padding-top: 20px;
  3804. border-radius: 100%;
  3805. border-width: 2px;
  3806. border-style: solid;
  3807. border-color: gray;
  3808. }
  3809. .icon_add i:nth-child(1) {
  3810. position: absolute;
  3811. left: 50%;
  3812. top: 50%;
  3813. height: 60%;
  3814. transform: translate(-50%, -50%);
  3815. border-width: 1px;
  3816. border-style: solid;
  3817. border-color: inherit;
  3818. }
  3819. .icon_add i:nth-child(2) {
  3820. position: absolute;
  3821. top: 50%;
  3822. left: 50%;
  3823. width: 60%;
  3824. transform: translate(-50%, -50%);
  3825. border-width: 1px;
  3826. border-style: solid;
  3827. border-color: inherit;
  3828. }
  3829. .chapter_btn_w {
  3830. font-size: 0.9375rem;
  3831. font-weight: bold;
  3832. color: gray;
  3833. margin-left: 20px;
  3834. }
  3835. .disUoloadSty >>> .el-icon-plus {
  3836. display: none !important; /* 上传按钮隐藏 */
  3837. }
  3838. .imgLeft {
  3839. margin: 15px 0;
  3840. }
  3841. .add_info_box {
  3842. margin: 20px 0;
  3843. }
  3844. .add_info_box button {
  3845. margin: 0 10px 10px 0;
  3846. }
  3847. .add_chapters_box {
  3848. text-align: left;
  3849. background-color: rgb(232 234 237);
  3850. width: 100%;
  3851. padding: 0px 15px;
  3852. border-radius: 15px;
  3853. font-size: 16px;
  3854. box-sizing: border-box;
  3855. position: relative;
  3856. padding: 0 10px 5px 10px;
  3857. height: 185px;
  3858. overflow-y: auto;
  3859. overflow-x: hidden;
  3860. }
  3861. .homework_box {
  3862. display: flex;
  3863. align-items: flex-start;
  3864. flex-wrap: wrap;
  3865. margin: 15px 0 0 0;
  3866. flex-direction: column;
  3867. align-content: flex-start;
  3868. }
  3869. .course_homework {
  3870. display: flex;
  3871. justify-content: center;
  3872. flex-direction: row;
  3873. align-items: center;
  3874. margin: 0 10px 0 0;
  3875. }
  3876. .course_homework >>> .el-input__inner {
  3877. width: 140px;
  3878. margin-left: 15px;
  3879. }
  3880. .chapter_upload_move {
  3881. position: relative;
  3882. background-color: #fff;
  3883. position: absolute;
  3884. width: 100%;
  3885. top: 0px;
  3886. left: 0px;
  3887. border: 1px solid #eee;
  3888. border-radius: 5px;
  3889. transition: width 2s;
  3890. -moz-transition: width 2s;
  3891. -webkit-transition: width 2s;
  3892. -o-transition: width 2s;
  3893. }
  3894. .chapter_upload_l_i {
  3895. background-image: url("../../assets/icon.png");
  3896. background-position: 3px -165px;
  3897. width: 30px;
  3898. height: 30px;
  3899. margin: 10px auto 0 auto;
  3900. }
  3901. .left_first {
  3902. display: flex;
  3903. flex-direction: column;
  3904. flex-wrap: nowrap;
  3905. width: 65%;
  3906. }
  3907. .right_first {
  3908. width: 100%;
  3909. height: 100%;
  3910. margin-top: 15px;
  3911. }
  3912. .right_title {
  3913. height: 30px;
  3914. padding: 20px 0 10px 30px;
  3915. border-bottom: 1px solid #f2f2f2;
  3916. font-size: 1.5em;
  3917. font-weight: bold;
  3918. }
  3919. .people {
  3920. border: 1px solid rgb(229 229 229);
  3921. height: 495px;
  3922. border-radius: 5px;
  3923. width: 100%;
  3924. overflow: auto;
  3925. }
  3926. .people_top {
  3927. display: flex;
  3928. width: 100%;
  3929. justify-content: space-between;
  3930. align-items: center;
  3931. }
  3932. .people_nav,
  3933. .people_top_right {
  3934. padding: 20px 0 0 20px;
  3935. }
  3936. .people_search {
  3937. display: flex;
  3938. position: relative;
  3939. }
  3940. .people_search >>> .el-input__inner {
  3941. height: 25px;
  3942. width: 95%;
  3943. }
  3944. .search_img {
  3945. width: 20px;
  3946. height: 20px;
  3947. position: absolute;
  3948. right: 15px;
  3949. top: 3px;
  3950. }
  3951. .search_img > img {
  3952. width: 100%;
  3953. height: 100%;
  3954. }
  3955. .people_name {
  3956. display: flex;
  3957. justify-content: flex-start;
  3958. padding: 20px 0 0 25px;
  3959. flex-direction: column;
  3960. flex-wrap: wrap;
  3961. }
  3962. .people_name >>> .el-checkbox {
  3963. width: 100%;
  3964. display: flex;
  3965. align-items: center;
  3966. margin-bottom: 10px;
  3967. }
  3968. .people_name >>> .el-checkbox__label {
  3969. text-overflow: ellipsis;
  3970. overflow: hidden;
  3971. width: 100%;
  3972. }
  3973. .right_img {
  3974. width: 150px;
  3975. height: 150px;
  3976. margin: 0 auto;
  3977. }
  3978. .right_img > img {
  3979. width: 100%;
  3980. height: 100%;
  3981. }
  3982. .number {
  3983. margin-top: 20px;
  3984. color: #4aa6ff;
  3985. text-decoration: underline;
  3986. }
  3987. .success_button {
  3988. display: flex;
  3989. text-align: center;
  3990. margin: 5% 0 auto;
  3991. flex-direction: row;
  3992. justify-content: center;
  3993. }
  3994. .look_course {
  3995. margin-right: 40px;
  3996. background: #3d67bc;
  3997. width: 200px;
  3998. height: 35px;
  3999. line-height: 35px;
  4000. color: #fff;
  4001. text-align: center;
  4002. font-size: 14px;
  4003. border-radius: 5px;
  4004. cursor: pointer;
  4005. }
  4006. .attend_others {
  4007. width: 250px;
  4008. background: #4fb13c;
  4009. height: 35px;
  4010. line-height: 35px;
  4011. color: #fff;
  4012. text-align: center;
  4013. font-size: 14px;
  4014. border-radius: 5px;
  4015. cursor: pointer;
  4016. }
  4017. .dialog_diy2 >>> .el-dialog__body {
  4018. text-align: center;
  4019. }
  4020. .write_togother {
  4021. position: absolute;
  4022. right: 45px;
  4023. display: flex;
  4024. top: 5%;
  4025. }
  4026. .write_people {
  4027. font-size: 14px;
  4028. line-height: 50px;
  4029. padding-right: 10px;
  4030. }
  4031. .end_write {
  4032. background: #3d67bc;
  4033. color: #fff;
  4034. width: 100px;
  4035. height: 35px;
  4036. line-height: 35px;
  4037. text-align: center;
  4038. font-size: 14px;
  4039. border-radius: 5px;
  4040. cursor: pointer;
  4041. }
  4042. .chapter_upload {
  4043. height: 50px;
  4044. margin-top: 12px;
  4045. position: relative;
  4046. display: flex;
  4047. align-items: center;
  4048. width: 100%;
  4049. min-height: 50px;
  4050. }
  4051. .chapter_upload_t {
  4052. background-color: #fff;
  4053. position: absolute;
  4054. height: 100%;
  4055. top: 0px;
  4056. left: 0px;
  4057. border-radius: 40px;
  4058. box-sizing: border-box;
  4059. box-shadow: 0 0 3px 3px #dfdfdf;
  4060. }
  4061. .chapter_upload_o {
  4062. width: 100%;
  4063. height: 100%;
  4064. position: relative;
  4065. z-index: 1;
  4066. }
  4067. .chapter_upload_l {
  4068. /* width: 50px;
  4069. height: 50px;
  4070. border-right: 1px solid #eee;
  4071. float: left; */
  4072. }
  4073. .chapter_upload_ic {
  4074. height: 30px;
  4075. float: right;
  4076. }
  4077. .chapter_upload_ic_l {
  4078. width: 50px;
  4079. height: 50px;
  4080. float: left;
  4081. }
  4082. .chapter_upload_ic_l div {
  4083. width: 30px;
  4084. height: 35px;
  4085. background: url("../../assets/icon/icon.png");
  4086. }
  4087. .chapter_upload_ic_r {
  4088. width: 50px;
  4089. height: 50px;
  4090. float: left;
  4091. margin-left: 0px;
  4092. display: flex;
  4093. align-items: center;
  4094. }
  4095. .chapter_upload_ic_r div {
  4096. width: 25px;
  4097. height: 25px;
  4098. background-image: url("../../assets/delete.png");
  4099. background-size: 100% 100%;
  4100. }
  4101. .chapter_upload_n {
  4102. display: flex;
  4103. text-indent: 10px;
  4104. text-decoration: none;
  4105. text-overflow: ellipsis;
  4106. white-space: nowrap;
  4107. overflow: hidden;
  4108. width: 55%;
  4109. margin-left: 20px;
  4110. cursor: pointer;
  4111. }
  4112. .chapter_upload_l_i1 {
  4113. background-image: url("../../assets/icon/video.png");
  4114. width: 28px;
  4115. height: 28px;
  4116. /* margin: 10px auto 0 auto; */
  4117. background-size: 100% 100%;
  4118. }
  4119. .chapter_upload_l_i5 {
  4120. background-image: url("../../assets/icon/word.png");
  4121. width: 24px;
  4122. height: 24px;
  4123. /* margin: 10px auto 0 auto; */
  4124. background-size: 100% 100%;
  4125. }
  4126. .chapter_upload_l_i8 {
  4127. background-image: url("../../assets/icon/line.png");
  4128. width: 24px;
  4129. height: 24px;
  4130. /* margin: 10px auto 0 auto; */
  4131. background-size: 100% 100%;
  4132. }
  4133. .chapter_upload_ud {
  4134. display: flex;
  4135. flex-direction: column;
  4136. margin-left: 5px;
  4137. justify-content: center;
  4138. }
  4139. .chapter_upload_up {
  4140. background-image: url("../../assets/icon/up.png");
  4141. width: 17px;
  4142. height: 15px;
  4143. background-size: 100% 100%;
  4144. cursor: pointer;
  4145. }
  4146. .chapter_upload_down {
  4147. background-image: url("../../assets/icon/down.png");
  4148. width: 17px;
  4149. height: 15px;
  4150. margin: 2px auto 0 auto;
  4151. background-size: 100% 100%;
  4152. cursor: pointer;
  4153. }
  4154. .addWordStyle {
  4155. display: flex;
  4156. flex-direction: row;
  4157. justify-content: flex-start;
  4158. overflow-x: auto;
  4159. white-space: nowrap;
  4160. flex-wrap: wrap;
  4161. }
  4162. /* table 样式 */
  4163. .cont >>> table {
  4164. border-top: 1px solid #ccc;
  4165. border-left: 1px solid #ccc;
  4166. }
  4167. .cont >>> table td,
  4168. .cont >>> table th {
  4169. border-bottom: 1px solid #ccc;
  4170. border-right: 1px solid #ccc;
  4171. padding: 3px 5px;
  4172. }
  4173. .cont >>> table th {
  4174. border-bottom: 2px solid #ccc;
  4175. text-align: center;
  4176. }
  4177. /* blockquote 样式 */
  4178. .cont >>> blockquote {
  4179. display: block;
  4180. border-left: 8px solid #d0e5f2;
  4181. padding: 5px 10px;
  4182. margin: 10px 0;
  4183. line-height: 1.4;
  4184. font-size: 100%;
  4185. background-color: #f1f1f1;
  4186. }
  4187. /* code 样式 */
  4188. .cont >>> code {
  4189. display: inline-block;
  4190. *display: inline;
  4191. *zoom: 1;
  4192. background-color: #f1f1f1;
  4193. border-radius: 3px;
  4194. padding: 3px 5px;
  4195. margin: 0 3px;
  4196. }
  4197. .cont >>> pre code {
  4198. display: block;
  4199. }
  4200. /* ul ol 样式 */
  4201. .cont >>> ul,
  4202. ol {
  4203. margin: 10px 0 10px 20px;
  4204. }
  4205. .wordbox {
  4206. display: flex;
  4207. flex-wrap: wrap;
  4208. cursor: pointer;
  4209. width: 100%;
  4210. }
  4211. .checkword {
  4212. width: 22px;
  4213. height: 22px;
  4214. margin: 10px auto 0;
  4215. cursor: pointer;
  4216. }
  4217. .checkword img {
  4218. width: 100%;
  4219. }
  4220. .stepBg {
  4221. margin: 0 25px 0 0;
  4222. width: 17%;
  4223. min-width: 230px;
  4224. border-radius: 10px;
  4225. display: flex;
  4226. flex-direction: column;
  4227. justify-content: flex-start;
  4228. align-items: center;
  4229. flex-wrap: nowrap;
  4230. background: #fff;
  4231. max-height: 700px;
  4232. }
  4233. .stepBg > div {
  4234. height: 80px;
  4235. width: 85%;
  4236. cursor: pointer;
  4237. margin: 10px 0;
  4238. border-radius: 10px;
  4239. }
  4240. .first,
  4241. .second,
  4242. .third,
  4243. .four {
  4244. background: #4a83d0;
  4245. height: 90px;
  4246. color: #fff;
  4247. display: flex;
  4248. flex-direction: row;
  4249. align-items: center;
  4250. justify-content: center;
  4251. }
  4252. .first > div:nth-child(1),
  4253. .second > div:nth-child(1),
  4254. .third > div:nth-child(1),
  4255. .four > div:nth-child(1) {
  4256. margin: 5px 10px 0 0;
  4257. width: 2rem;
  4258. }
  4259. .firstNo,
  4260. .secondNo,
  4261. .thirdNo,
  4262. .fourNo {
  4263. background: #e7e7e7;
  4264. color: #adadad;
  4265. display: flex;
  4266. flex-direction: row;
  4267. align-items: center;
  4268. justify-content: center;
  4269. }
  4270. .firstNo > div:nth-child(1),
  4271. .secondNo > div:nth-child(1),
  4272. .thirdNo > div:nth-child(1),
  4273. .fourNo > div:nth-child(1) {
  4274. margin: 5px 10px 0 0;
  4275. width: 2rem;
  4276. }
  4277. .uploadWidth >>> .el-upload {
  4278. width: 60px;
  4279. height: 60px;
  4280. position: relative;
  4281. }
  4282. .addPeople {
  4283. background: #fa6060;
  4284. width: 135px;
  4285. height: 40px;
  4286. color: #fff;
  4287. border-radius: 5px;
  4288. text-align: center;
  4289. line-height: 40px;
  4290. font-size: 15px;
  4291. cursor: pointer;
  4292. }
  4293. .kcImg {
  4294. width: 60px;
  4295. margin-left: 10px;
  4296. }
  4297. .zyImg {
  4298. width: 55px;
  4299. margin: 0 10px;
  4300. }
  4301. .deleteZy {
  4302. width: 20px;
  4303. position: absolute;
  4304. top: 5px;
  4305. right: 5px;
  4306. cursor: pointer;
  4307. }
  4308. .kcImg > img,
  4309. .zyImg > img,
  4310. .deleteZy > img {
  4311. width: 100%;
  4312. height: 100%;
  4313. }
  4314. .zyBox {
  4315. display: flex;
  4316. flex-direction: row;
  4317. align-items: center;
  4318. background: #67d37d;
  4319. color: #fff;
  4320. width: 210px;
  4321. margin: 20px 20px 0 0;
  4322. border-radius: 10px;
  4323. height: 70px;
  4324. position: relative;
  4325. }
  4326. .upCss {
  4327. display: flex;
  4328. flex-direction: row;
  4329. justify-content: flex-start;
  4330. }
  4331. /* .upCss >>> .el-upload {
  4332. margin-right: 30px;
  4333. } */
  4334. .upCss >>> .el-icon-plus {
  4335. position: none !important;
  4336. width: 200px;
  4337. height: 100px;
  4338. display: flex;
  4339. flex-wrap: nowrap;
  4340. flex-direction: column;
  4341. align-items: center;
  4342. justify-content: center;
  4343. border: 1px dashed #ccc;
  4344. min-width: 78px;
  4345. min-height: 100px;
  4346. z-index: 999;
  4347. }
  4348. .addStageImg {
  4349. min-width: 25px;
  4350. min-height: 25px;
  4351. width: 25px;
  4352. height: 25px;
  4353. cursor: pointer;
  4354. }
  4355. .addHW {
  4356. width: 28px;
  4357. height: 28px;
  4358. cursor: pointer;
  4359. }
  4360. .addStageImg > img,
  4361. .addHW > img {
  4362. width: 100%;
  4363. height: 100%;
  4364. }
  4365. .addNewPP >>> .el-dialog__body {
  4366. padding: 5px 20px;
  4367. }
  4368. .isHeight {
  4369. height: 680px;
  4370. }
  4371. .toolChoose {
  4372. display: flex;
  4373. width: 100%;
  4374. flex-direction: row;
  4375. flex-wrap: wrap;
  4376. }
  4377. .tool {
  4378. display: flex;
  4379. flex-direction: column;
  4380. flex-wrap: nowrap;
  4381. width: fit-content;
  4382. margin: 10px 0 10px 0;
  4383. align-items: center;
  4384. }
  4385. .tool + .tool {
  4386. margin-right: 45px;
  4387. }
  4388. .whiteBIcon {
  4389. width: 80px;
  4390. cursor: pointer;
  4391. display: flex;
  4392. flex-direction: column;
  4393. flex-wrap: nowrap;
  4394. align-items: center;
  4395. }
  4396. .whiteBIcon > img,
  4397. .check > img,
  4398. .toolIcon > img,
  4399. .arrow > img {
  4400. width: 100%;
  4401. height: 100%;
  4402. }
  4403. .check {
  4404. width: 20px;
  4405. height: 20px;
  4406. cursor: pointer;
  4407. margin: 10px 0;
  4408. }
  4409. .customWidth >>> .el-dialog {
  4410. min-width: 500px !important;
  4411. }
  4412. .a_addBox {
  4413. margin: 10px 0;
  4414. background: #fff;
  4415. padding: 15px;
  4416. max-height: 400px;
  4417. overflow: auto;
  4418. }
  4419. .a_add_box {
  4420. border-bottom: 2px solid #eee;
  4421. padding-bottom: 10px;
  4422. }
  4423. .a_add_head {
  4424. display: flex;
  4425. align-items: center;
  4426. justify-content: space-between;
  4427. margin: 10px 0;
  4428. font-size: 18px;
  4429. }
  4430. .a_add_head .a_add_head_input {
  4431. width: 300px;
  4432. }
  4433. .a_add_head .a_add_head_div {
  4434. display: flex;
  4435. align-items: center;
  4436. justify-content: space-between;
  4437. }
  4438. .a_add_body {
  4439. display: flex;
  4440. align-items: center;
  4441. }
  4442. .a_add_input {
  4443. display: flex;
  4444. align-items: center;
  4445. flex-wrap: wrap;
  4446. /* flex-direction: column; */
  4447. /* width: 100%; */
  4448. }
  4449. .width100 {
  4450. width: 100%;
  4451. }
  4452. .a_add_input .a_add_persent {
  4453. /* display: flex; */
  4454. /* flex-direction: column; */
  4455. width: 100%;
  4456. }
  4457. .a_add_persent_div {
  4458. width: 100%;
  4459. display: flex;
  4460. align-items: center;
  4461. }
  4462. .a_add_persent_div span {
  4463. margin: 5px 0;
  4464. }
  4465. .a_add_persent_div span:nth-child(1) {
  4466. width: 30%;
  4467. }
  4468. .a_add_persent_div span:nth-child(2) {
  4469. width: 7%;
  4470. }
  4471. .a_add_persent_div span:nth-child(3) {
  4472. width: 40%;
  4473. }
  4474. .a_add_persent_title {
  4475. /* margin-bottom: 10px; */
  4476. }
  4477. .a_add_body_div {
  4478. display: flex;
  4479. align-items: center;
  4480. justify-content: center;
  4481. flex-direction: column;
  4482. }
  4483. .all_choose {
  4484. display: flex;
  4485. flex-direction: row;
  4486. align-items: flex-start;
  4487. }
  4488. .all_choose > span {
  4489. width: 80px;
  4490. display: block;
  4491. letter-spacing: 14px;
  4492. }
  4493. .all_choose >>> .el-checkbox-group {
  4494. display: flex;
  4495. flex-direction: row;
  4496. width: 820px;
  4497. flex-wrap: wrap;
  4498. align-content: center;
  4499. justify-content: flex-start;
  4500. align-items: center;
  4501. }
  4502. .all_choose > .el-checkbox-group >>> .el-checkbox {
  4503. margin-bottom: 10px;
  4504. display: flex;
  4505. flex-direction: row;
  4506. align-items: center;
  4507. }
  4508. .all_choose > .el-checkbox-group > .el-checkbox >>> .el-checkbox__label {
  4509. min-width: 80px;
  4510. overflow: hidden;
  4511. width: 80px;
  4512. text-overflow: ellipsis;
  4513. white-space: nowrap;
  4514. }
  4515. .all_choose > .el-checkbox-group > .el-checkbox >>> .el-checkbox__label:hover {
  4516. width: auto;
  4517. }
  4518. .choose > div:nth-child(3) > span {
  4519. letter-spacing: 0 !important;
  4520. }
  4521. .choose {
  4522. display: flex;
  4523. flex-direction: column;
  4524. flex-wrap: nowrap;
  4525. height: 100%;
  4526. justify-content: space-evenly;
  4527. align-items: flex-start;
  4528. }
  4529. .both {
  4530. display: flex;
  4531. flex-direction: row;
  4532. flex-wrap: wrap;
  4533. width: 100%;
  4534. height: 350px;
  4535. align-items: center;
  4536. justify-content: flex-start;
  4537. }
  4538. .notice >>> .el-dialog {
  4539. width: 500px !important;
  4540. text-align: center;
  4541. }
  4542. .notice >>> .el-button {
  4543. margin-top: 20px;
  4544. }
  4545. .whiteBg {
  4546. background: #fff;
  4547. border-radius: 10px;
  4548. min-width: 800px;
  4549. }
  4550. .chooseWho {
  4551. display: flex;
  4552. width: 250px;
  4553. flex-direction: row;
  4554. flex-wrap: nowrap;
  4555. justify-content: space-between;
  4556. padding-bottom: 10px;
  4557. }
  4558. .chooseWho > div {
  4559. cursor: pointer;
  4560. padding-bottom: 10px;
  4561. }
  4562. .isChooseActive {
  4563. color: #3e88f4;
  4564. border-bottom: 2px solid #2f80f3;
  4565. }
  4566. .toolSort {
  4567. display: flex;
  4568. flex-direction: row;
  4569. flex-wrap: wrap;
  4570. justify-content: flex-start;
  4571. align-items: flex-start;
  4572. min-width: 685px;
  4573. }
  4574. .toolSort > div {
  4575. margin-right: 45px;
  4576. }
  4577. .tools {
  4578. width: 100%;
  4579. display: flex;
  4580. flex-direction: column;
  4581. flex-wrap: nowrap;
  4582. align-items: flex-start;
  4583. }
  4584. .leftTools,
  4585. .rightTools {
  4586. width: 50%;
  4587. }
  4588. .rightTools {
  4589. display: flex;
  4590. flex-direction: row;
  4591. flex-wrap: nowrap;
  4592. justify-content: space-around;
  4593. }
  4594. .firstToolList {
  4595. display: flex;
  4596. flex-direction: column;
  4597. flex-wrap: nowrap;
  4598. align-items: center;
  4599. }
  4600. .iconList {
  4601. display: flex;
  4602. flex-direction: row;
  4603. flex-wrap: wrap;
  4604. justify-content: flex-start;
  4605. align-items: center;
  4606. margin: 20px 0 5px 0;
  4607. width: 240px;
  4608. min-width: 240px;
  4609. }
  4610. .iconTool {
  4611. display: flex;
  4612. flex-direction: column;
  4613. flex-wrap: nowrap;
  4614. align-items: center;
  4615. justify-content: flex-start;
  4616. margin: 15px 10px;
  4617. }
  4618. .toolIcon {
  4619. width: 50px;
  4620. }
  4621. .taskBorder {
  4622. border: 1px solid #e1e1e1;
  4623. border-radius: 10px;
  4624. margin-top: 20px;
  4625. min-height: 1160px;
  4626. position: relative;
  4627. background: #fbfbfb;
  4628. /* transition: all .5s; */
  4629. }
  4630. .smallTaskBorder {
  4631. height: 170px;
  4632. min-height: 170px !important;
  4633. overflow: hidden;
  4634. }
  4635. .taskBorder > div {
  4636. padding: 30px 0 10px 30px;
  4637. }
  4638. .addTaskBorder {
  4639. border: 2px solid #e1e1e1;
  4640. border-radius: 10px;
  4641. margin-top: 25px;
  4642. cursor: pointer;
  4643. }
  4644. .addTaskBorder > div {
  4645. /* width: 100px; */
  4646. margin: 0 auto;
  4647. display: flex;
  4648. align-items: center;
  4649. justify-content: center;
  4650. }
  4651. .addTaskBorder > div > img {
  4652. width: 100px;
  4653. }
  4654. .addTaskBorder > div > span {
  4655. font-size: 23px;
  4656. color: #dbdbdb;
  4657. }
  4658. .funBlock {
  4659. display: flex;
  4660. padding: 15px 0;
  4661. flex-direction: row;
  4662. justify-content: flex-end;
  4663. align-items: center;
  4664. position: absolute;
  4665. right: 15px;
  4666. bottom: 35px;
  4667. }
  4668. .funBlockTop {
  4669. /* top: 35px; */
  4670. }
  4671. .fold {
  4672. display: flex;
  4673. margin: 0 10px;
  4674. flex-direction: row;
  4675. align-items: center;
  4676. cursor: pointer;
  4677. }
  4678. .arrow {
  4679. width: 15px;
  4680. height: 15px;
  4681. margin-left: 10px;
  4682. }
  4683. .addToolFun {
  4684. display: flex;
  4685. width: 150px;
  4686. flex-direction: row;
  4687. align-items: center;
  4688. justify-content: center;
  4689. border: 1px dashed;
  4690. border-radius: 5px;
  4691. height: 50px;
  4692. margin: 35px auto 0;
  4693. cursor: pointer;
  4694. }
  4695. .addToolImg {
  4696. width: 30px;
  4697. height: 30px;
  4698. margin-right: 20px;
  4699. }
  4700. .addToolsDia >>> .el-dialog__body {
  4701. padding: 20px;
  4702. }
  4703. .addToolsDia >>> .el-dialog__body > .toolChoose {
  4704. padding: 0;
  4705. }
  4706. .addToolsDia >>> .el-dialog__body > .toolChoose > .leftTools {
  4707. padding: 0;
  4708. border-bottom: none;
  4709. margin-bottom: 0;
  4710. }
  4711. .addToolsDia >>> .el-dialog__body > .toolChoose > .leftTools > .chooseWho {
  4712. width: 100%;
  4713. }
  4714. .lineCss >>> .el-form-item__label {
  4715. width: auto !important;
  4716. }
  4717. .lineCss >>> .el-form-item__content {
  4718. margin-left: 50px !important;
  4719. }
  4720. .newSteps {
  4721. display: flex;
  4722. width: 100% !important;
  4723. height: 80px;
  4724. cursor: pointer;
  4725. margin: 10px 0;
  4726. border-radius: 10px;
  4727. flex-direction: row;
  4728. align-content: center;
  4729. justify-content: center;
  4730. align-items: center;
  4731. margin: 0 !important;
  4732. }
  4733. /* 评价样式 */
  4734. .elist_css {
  4735. margin-bottom: 60px;
  4736. }
  4737. .elist_title {
  4738. margin-bottom: 10px;
  4739. }
  4740. .elist_input {
  4741. }
  4742. .elist_input_box {
  4743. display: flex;
  4744. align-items: center;
  4745. flex-wrap: wrap;
  4746. }
  4747. .elist_input_box + .elist_input_box {
  4748. margin-top: 30px;
  4749. }
  4750. .elist_input .elist_input_box input {
  4751. font: inherit;
  4752. color: currentColor;
  4753. width: 200px;
  4754. padding: 8px 14px;
  4755. display: block;
  4756. min-width: 0;
  4757. outline: none;
  4758. border: 1px solid rgba(0, 0, 0, 0.23);
  4759. border-radius: 4px;
  4760. box-sizing: border-box;
  4761. background: #fff;
  4762. margin: 0 20px 0 0;
  4763. }
  4764. .elist_input .elist_input_box span {
  4765. height: 36px;
  4766. line-height: 36px;
  4767. color: rgb(82, 82, 82);
  4768. }
  4769. .elist_input .elist_input_box .remove {
  4770. height: 20px;
  4771. width: 20px;
  4772. background-size: 100% 100%;
  4773. background-position: unset;
  4774. margin-left: 5px;
  4775. }
  4776. .elist_input_box >>> .el-rate {
  4777. display: flex;
  4778. height: 36px;
  4779. align-items: center;
  4780. }
  4781. .elist_input_box .elist_inptu_text {
  4782. width: 100%;
  4783. display: flex;
  4784. align-items: center;
  4785. margin-top: 10px;
  4786. }
  4787. .elist_input_box .elist_inptu_text input {
  4788. width: 500px;
  4789. }
  4790. .elist_input_box >>> .el-rate__icon {
  4791. font-size: 24px;
  4792. }
  4793. .elist_btn {
  4794. margin-top: 10px;
  4795. }
  4796. </style>