123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236 |
- <template>
- <div id="classHoursReview">
- <div class="dis_fs">
- <ul class="ul_ls">
- <li>学员编码:{{ userData.studentCode }}</li>
- <li>学员姓名:{{ userData.realName }}</li>
- <li>学员身份证号码:{{ userData.idCard }}</li>
- <li>绑定手机号码:{{ userData.telPhone }}</li>
- </ul>
- <div class="photoSty1">
- <el-image
- style="width: 100%; height: 100%"
- :src="$methodsTools.splitImgHost(recent_photos)"
- :preview-src-list="[$methodsTools.splitImgHost(recent_photos)]"
- >
- </el-image>
- <div class="pos_bottom">一寸头像图</div>
- </div>
- <div class="photoSty2">
- <el-image
- style="width: 100%; height: 100%"
- :src="$methodsTools.splitImgHost(idcard_face_photo)"
- :preview-src-list="[$methodsTools.splitImgHost(idcard_face_photo)]"
- >
- </el-image>
- <div class="pos_bottom">身份证正面照片</div>
- </div>
- <div class="photoSty2" style="margin-right: 0px">
- <el-image
- style="width: 100%; height: 100%"
- :src="$methodsTools.splitImgHost(idcard_national_photo)"
- :preview-src-list="[
- $methodsTools.splitImgHost(idcard_national_photo),
- ]"
- >
- </el-image>
- <div class="pos_bottom">身份证背面照片</div>
- </div>
- </div>
- <div class="dis_fls">
- <div class="s_sd">
- <div class="dis_colu">
- <div class="jdNumSty" style="margin-bottom: 4px">
- 视频学习进度:{{ userData.stuAllNum }}/{{ userData.secAllNum }}
- {{
- userData.stuAllNum == 0 && userData.secAllNum == 0
- ? "0"
- : ((userData.stuAllNum / userData.secAllNum) * 100).toFixed(2)
- }}% 通过:{{ userData.pass }}节
- <span style="color: #f56c6c">作弊:{{ userData.cheat }}节</span>
- <span style="color: #409eff"> 待审:{{ userData.pending }}节</span>
- </div>
- <div class="jdNumSty">
- 做题学习进度:{{ userData.recordNum }}/{{ userData.examNum }}
- {{
- userData.recordNum == 0 && userData.examNum == 0
- ? "0"
- : ((userData.recordNum / userData.examNum) * 100).toFixed(2)
- }}% 通过:{{ userData.examPass }}节
- <span style="color: #f56c6c">作弊:{{ userData.examCheat }}节</span>
- <span style="color: #409eff">
- 待审:{{ userData.examPending }}节</span
- >
- </div>
- </div>
- <div class="shbtns">
- 学时审批状态:{{
- userData.allStatus === 1
- ? "未通过"
- : userData.allStatus === 0
- ? "待审核"
- : userData.allStatus === -1
- ? "不可审核"
- : userData.allStatus === 2
- ? "通过审核"
- : "未知状态,请联系管理员"
- }}
- </div>
- </div>
- <div class="s_sd">
- <div
- class="btnStys"
- @click="getChangeStatus(1)"
- v-if="userData.allStatus === 0 || userData.allStatus === 1"
- >
- 待审核全部通过
- </div>
- <div
- class="btnStys"
- @click="getChangeStatus(2)"
- v-if="userData.allStatus === 0 || userData.allStatus === 1"
- >
- 待审核全部作弊
- </div>
- </div>
- </div>
- <template v-for="(asrt, insrt) in 3">
- <el-table
- border
- v-loading="loading"
- :key="insrt"
- :data="
- listData[
- insrt === 0
- ? 'tableData1'
- : insrt === 1
- ? 'tableData2'
- : insrt === 2
- ? 'tableData3'
- : ''
- ]
- "
- style="width: 100%"
- :default-expand-all="false"
- :header-cell-style="
- insrt === 0
- ? {
- 'background-color': 'skyblue',
- padding: '8px',
- color: '#333',
- }
- : insrt === 1
- ? {
- 'background-color': 'rgb(255,255,204)',
- padding: '8px',
- color: '#333',
- }
- : insrt === 2
- ? {
- 'background-color': '#eee',
- padding: '8px',
- color: '#333',
- }
- : ''
- "
- >
- <!-- 插槽开始--------------------------------------------------------- -->
- <el-table-column
- :label="
- insrt === 0
- ? '模块'
- : insrt === 1
- ? '章'
- : insrt === 2
- ? '节/卷'
- : ''
- "
- type="expand"
- width="70px"
- >
- <template slot-scope="scope">
- <!-- type为3时使用该插槽START -->
- <div
- v-if="scope.row.type === 3 || scope.row.type === 4"
- class="dis_flexs"
- >
- <ul
- style="flex: 1"
- v-if="
- scope.row.userStudyRecordPhotoList &&
- scope.row.userStudyRecordPhotoList.length
- "
- >
- <li
- v-for="(its, inds) in scope.row.userStudyRecordPhotoList"
- :key="inds"
- class="liImgs"
- >
- <el-image
- style="width: 100%; height: 100%"
- :src="$methodsTools.splitImgHost(its.photo)"
- :preview-src-list="[$methodsTools.splitImgHost(its.photo)]"
- >
- </el-image>
- <div class="abos">
- {{ $methodsTools.onlyForma(its.createTime) }}
- </div>
- </li>
- <div style="clear: both"></div>
- </ul>
- <p v-else style="text-align: center; width: 100%">暂无拍照数据</p>
- <div
- class="styFlex"
- v-if="
- (userData.allStatus === 0 || userData.allStatus === 1) &&
- scope.row.periodStatus === 1
- "
- >
- <el-button
- :disabled="scope.row.status === 1"
- class="btnstyles"
- size="mini"
- @click="changeStatus(scope.row, 1, scope.$index)"
- >通过</el-button
- >
- <el-button
- :disabled="scope.row.status === 0"
- class="btnstyles"
- size="mini"
- @click="
- scope.row.status === 2 || scope.row.status === 3
- ? changeStatus(scope.row, 2, scope.$index)
- : ''
- "
- >作弊</el-button
- >
- </div>
- <!-- <div
- class="styFlex"
- v-if="
- (scope.row.allStatus === 0 || scope.row.allStatus === 1) &&
- scope.row.periodStatus === 1 &&
- scope.row.status === 0
- "
- >
- <el-button
- class="btnstyles"
- size="mini"
- @click="changeStatus(scope.row, 1, scope.$index)"
- >通过</el-button
- >
- </div> -->
- </div>
- <!-- type为3时使用该插槽END -->
- <!-- 章表格START -->
- <el-table
- v-else
- border
- :data="
- scope.row.type === 1
- ? scope.row.classPeriods
- : scope.row.type === 2
- ? scope.row.classPeriodSectionList
- : ''
- "
- style="width: 100%"
- :default-expand-all="false"
- :header-cell-style="
- scope.row.type === 1
- ? {
- 'background-color': 'rgb(255,255,204)',
- padding: '8px',
- color: '#333',
- }
- : scope.row.type === 2
- ? {
- 'background-color': '#eee',
- padding: '8px',
- color: '#333',
- }
- : ''
- "
- >
- <!-- 章插槽START -->
- <el-table-column
- type="expand"
- :label="
- scope.row.type === 1
- ? '章'
- : scope.row.type === 2
- ? '节/卷'
- : ''
- "
- :width="
- scope.row.type === 1
- ? '70px'
- : scope.row.type === 2
- ? '80px'
- : ''
- "
- >
- <template slot-scope="scope2">
- <!-- 节插槽START -->
- <div
- v-if="scope2.row.type === 3 || scope2.row.type === 4"
- class="dis_flexs"
- >
- <ul
- style="flex: 1"
- v-if="
- scope2.row.userStudyRecordPhotoList &&
- scope2.row.userStudyRecordPhotoList.length
- "
- >
- <li
- v-for="(its, inds) in scope2.row
- .userStudyRecordPhotoList"
- :key="inds"
- class="liImgs"
- >
- <el-image
- style="width: 100%; height: 100%"
- :src="$methodsTools.splitImgHost(its.photo)"
- :preview-src-list="[
- $methodsTools.splitImgHost(its.photo),
- ]"
- >
- </el-image>
- <div class="abos">
- {{ $methodsTools.onlyForma(its.createTime) }}
- </div>
- </li>
- <div style="clear: both"></div>
- </ul>
- <p v-else style="text-align: center; width: 100%">
- 暂无拍照数据
- </p>
- <div
- class="styFlex"
- v-if="
- (userData.allStatus === 0 ||
- userData.allStatus === 1) &&
- scope2.row.periodStatus === 1
- "
- >
- <el-button
- :disabled="scope2.row.status === 1"
- class="btnstyles"
- size="mini"
- @click="
- changeStatusCharpter(
- scope2.row,
- 1,
- scope.$index,
- scope2.$index
- )
- "
- >通过</el-button
- >
- <el-button
- :disabled="scope2.row.status === 0"
- class="btnstyles"
- size="mini"
- @click="
- scope2.row.status === 2 || scope2.row.status === 3
- ? changeStatusCharpter(
- scope2.row,
- 2,
- scope.$index,
- scope2.$index
- )
- : ''
- "
- >作弊</el-button
- >
- </div>
- <!-- <div
- class="styFlex"
- v-if="
- (scope2.row.allStatus === 0 ||
- scope2.row.allStatus === 1) &&
- scope2.row.periodStatus === 1 &&
- scope2.row.status === 0
- "
- >
- <el-button
- class="btnstyles"
- size="mini"
- @click="
- changeStatusCharpter(
- scope2.row,
- 1,
- scope.$index,
- scope2.$index
- )
- "
- >通过</el-button
- >
- </div> -->
- </div>
- <!-- 节插槽END -->
- <!-- 节表格START -->
- <el-table
- v-else
- border
- :data="
- scope2.row.type === 2
- ? scope2.row.classPeriodSectionList
- : ''
- "
- style="width: 100%"
- :default-expand-all="false"
- :header-cell-style="
- scope2.row.type === 2
- ? {
- 'background-color': '#eee',
- padding: '8px',
- color: '#333',
- }
- : ''
- "
- >
- <!-- 节插槽START -->
- <el-table-column
- type="expand"
- :label="scope2.row.type === 2 ? '节/卷' : ''"
- width="80px"
- >
- <template slot-scope="scope3">
- <div
- v-if="scope3.row.type === 3 || scope3.row.type === 4"
- class="dis_flexs"
- >
- <ul
- style="flex: 1"
- v-if="
- scope3.row.userStudyRecordPhotoList &&
- scope3.row.userStudyRecordPhotoList.length
- "
- >
- <li
- v-for="(its, inds) in scope3.row
- .userStudyRecordPhotoList"
- :key="inds"
- class="liImgs"
- >
- <el-image
- style="width: 100%; height: 100%"
- :src="$methodsTools.splitImgHost(its.photo)"
- :preview-src-list="[
- $methodsTools.splitImgHost(its.photo),
- ]"
- >
- </el-image>
- <div class="abos">
- {{ $methodsTools.onlyForma(its.createTime) }}
- </div>
- </li>
- <div style="clear: both"></div>
- </ul>
- <p v-else style="text-align: center; width: 100%">
- 暂无拍照数据
- </p>
- <div
- class="styFlex"
- v-if="
- (userData.allStatus === 0 ||
- userData.allStatus === 1) &&
- scope3.row.periodStatus === 1
- "
- >
- <el-button
- :disabled="scope3.row.status === 1"
- class="btnstyles"
- size="mini"
- @click="
- changeStatusModule(
- scope3.row,
- 1,
- scope.$index,
- scope2.$index,
- scope3.$index
- )
- "
- >通过</el-button
- >
- <el-button
- :disabled="scope3.row.status === 0"
- class="btnstyles"
- size="mini"
- @click="
- scope3.row.status === 2 ||
- scope3.row.status === 3
- ? changeStatusModule(
- scope3.row,
- 2,
- scope.$index,
- scope2.$index,
- scope3.$index
- )
- : ''
- "
- >作弊</el-button
- >
- </div>
- <!-- <div
- class="styFlex"
- v-if="
- (scope3.row.allStatus === 0 ||
- scope3.row.allStatus === 1) &&
- scope3.row.periodStatus === 1 &&
- scope3.row.status === 0
- "
- >
- <el-button
- class="btnstyles"
- size="mini"
- @click="
- changeStatusModule(
- scope3.row,
- 1,
- scope.$index,
- scope2.$index,
- scope3.$index
- )
- "
- >通过</el-button
- >
- </div> -->
- </div>
- </template>
- </el-table-column>
- <!-- 节插槽END -->
- <template
- v-for="(item, index) in scope2.row.type === 2
- ? tableSet3
- : ''"
- >
- <el-table-column
- :width="item.width"
- :key="index"
- :label="item.label"
- align="center"
- >
- <template slot-scope="scope3">
- <span v-if="item.scope === 'select'">
- <span v-for="(k, ds) in item.options" :key="ds">
- {{
- k.value == scope3.row[item.prop] ? k.label : ""
- }}
- </span>
- </span>
- <div v-else-if="item.scope === 'activeNum'">
- <el-select
- v-model="scope3.row[item.prop]"
- placeholder="请选择"
- @change="
- getNewListMores(
- scope.$index,
- scope2.$index,
- scope3.$index,
- $event,
- scope3.row
- )
- "
- >
- <el-option
- v-for="(items, indexs) in scope3.row['numList']"
- :key="indexs"
- :label="'第' + items + '次审核记录'"
- :value="items"
- >
- </el-option>
- </el-select>
- </div>
- <span v-else-if="item.scope === 'typeOptions'">
- <span v-for="(is, ds) in item.options" :key="ds">
- <span v-if="is.value === scope3.row[item.prop]">{{
- is.label
- }}</span>
- </span>
- </span>
- <span v-else-if="item.scope === 'aTime'">
- {{ $methodsTools.onlyForma(scope3.row[item.prop]) }}
- </span>
- <div v-else-if="item.scope === 'aTimeSE'">
- <span
- v-if="
- scope3.row['type'] === 3 &&
- scope3.row['durationTime'] &&
- scope3.row['studyStartTime'] &&
- scope3.row['studyEndTime']
- "
- :style="comput(scope3.row)"
- >
- {{
- $methodsTools.onlyForma(scope3.row[item.prop])
- }}
- </span>
- <span v-else>
- {{
- $methodsTools.onlyForma(scope3.row[item.prop])
- }}
- </span>
- </div>
- <span v-else> {{ scope3.row[item.prop] }} </span>
- </template>
- </el-table-column>
- </template>
- </el-table>
- <!-- 节表格END -->
- </template>
- </el-table-column>
- <!-- 章插槽END -->
- <template
- v-for="(item, index) in scope.row.type === 1
- ? tableSet2
- : scope.row.type === 2
- ? tableSet3
- : ''"
- >
- <el-table-column
- :width="item.width"
- :key="index"
- :label="item.label"
- align="center"
- >
- <template slot-scope="scope2">
- <span v-if="item.scope === 'select'">
- <span v-for="(k, ds) in item.options" :key="ds">
- {{ k.value == scope2.row[item.prop] ? k.label : "" }}
- </span>
- </span>
- <div v-else-if="item.scope === 'activeNum'">
- <el-select
- v-model="scope2.row[item.prop]"
- placeholder="请选择"
- @change="
- getNewListchapt(
- scope.$index,
- scope2.$index,
- $event,
- scope2.row
- )
- "
- >
- <el-option
- v-for="(items, indexs) in scope2.row['numList']"
- :key="indexs"
- :label="'第' + items + '次审核记录'"
- :value="items"
- >
- </el-option>
- </el-select>
- </div>
- <span v-else-if="item.scope === 'typeOptions'">
- <span v-for="(is, ds) in item.options" :key="ds">
- <span v-if="is.value === scope2.row[item.prop]">{{
- is.label
- }}</span>
- </span>
- </span>
- <span v-else-if="item.scope === 'aTime'">
- {{ $methodsTools.onlyForma(scope2.row[item.prop]) }}
- </span>
- <div v-else-if="item.scope === 'aTimeSE'">
- <span
- v-if="
- scope2.row['type'] === 3 &&
- scope2.row['durationTime'] &&
- scope2.row['studyStartTime'] &&
- scope2.row['studyEndTime']
- "
- :style="comput(scope2.row)"
- >
- {{ $methodsTools.onlyForma(scope2.row[item.prop]) }}
- </span>
- <span v-else>
- {{ $methodsTools.onlyForma(scope2.row[item.prop]) }}
- </span>
- </div>
- <span v-else> {{ scope2.row[item.prop] }} </span>
- </template>
- </el-table-column>
- </template>
- </el-table>
- <!-- 章表格END -->
- </template>
- </el-table-column>
- <!-- 插槽结束--------------------------------------------------------- -->
- <template
- v-for="(item, index) in insrt === 0
- ? tableSet1
- : insrt === 1
- ? tableSet2
- : insrt === 2
- ? tableSet3
- : ''"
- >
- <el-table-column
- :width="item.width"
- :key="index"
- :label="item.label"
- align="center"
- >
- <template slot-scope="scope">
- <span v-if="item.scope === 'select'">
- <span v-for="(k, ds) in item.options" :key="ds">
- {{ k.value == scope.row[item.prop] ? k.label : "" }}
- </span>
- </span>
- <div v-else-if="item.scope === 'activeNum'">
- <el-select
- v-model="scope.row[item.prop]"
- placeholder="请选择"
- @change="getNewList(scope.$index, $event, scope.row)"
- >
- <el-option
- v-for="(items, indexs) in scope.row['numList']"
- :key="indexs"
- :label="'第' + items + '次审核记录'"
- :value="items"
- >
- </el-option>
- </el-select>
- </div>
- <span v-else-if="item.scope === 'typeOptions'">
- <span v-for="(is, ds) in item.options" :key="ds">
- <span v-if="is.value === scope.row[item.prop]">{{
- is.label
- }}</span>
- </span>
- </span>
- <span v-else-if="item.scope === 'aTime'">
- {{ $methodsTools.onlyForma(scope.row[item.prop]) }}
- </span>
- <div v-else-if="item.scope === 'aTimeSE'">
- <span
- v-if="
- scope.row['type'] === 3 &&
- scope.row['durationTime'] &&
- scope.row['studyStartTime'] &&
- scope.row['studyEndTime']
- "
- :style="comput(scope.row)"
- >
- {{ $methodsTools.onlyForma(scope.row[item.prop]) }}
- </span>
- <span v-else>
- {{ $methodsTools.onlyForma(scope.row[item.prop]) }}
- </span>
- </div>
- <span v-else>
- {{ scope.row[item.prop] }}{{ item.ch ? item.ch : "" }}
- </span>
- </template>
- </el-table-column>
- </template>
- </el-table>
- </template>
- </div>
- </template>
- <script>
- export default {
- data() {
- return {
- size: "medium",
- active: "",
- loading: false,
- studentCode: "",
- realName: "",
- idCard: "",
- telPhone: "",
- recent_photos: "",
- idcard_face_photo: "",
- idcard_national_photo: "",
- arr: ["tableData1", "tableData2", "tableData3"],
- listData: {
- tableData1: [],
- tableData2: [],
- tableData3: [],
- },
- userData: {},
- tableData: [],
- tableSet1: [
- {
- label: "姓名",
- prop: "realName",
- },
- {
- label: "模块标题",
- prop: "typeName",
- },
- {
- label: "学时",
- prop: "classHours",
- },
- ],
- tableSet2: [
- {
- label: "姓名",
- prop: "realName",
- },
- {
- label: "章标题",
- prop: "typeName",
- },
- {
- label: "学时",
- prop: "classHours",
- },
- {
- label: "开始学习时间",
- prop: "studyStartTime",
- scope: "aTime",
- },
- {
- label: "结束学习时间",
- prop: "studyEndTime",
- scope: "aTime",
- },
- {
- label: "测试成绩",
- prop: "performance",
- },
- ],
- tableSet3: [
- {
- label: "选择",
- prop: "numIndex",
- scope: "activeNum",
- width: "180px",
- },
- {
- label: "姓名",
- prop: "realName",
- },
- {
- label: "标题",
- prop: "typeName",
- },
- {
- label: "类型",
- prop: "type",
- scope: "typeOptions",
- options: [
- {
- label: "节",
- value: 3,
- },
- {
- label: "试卷",
- value: 4,
- },
- ],
- },
- {
- label: "节时长",
- prop: "durationTime",
- width: "180px",
- },
- {
- label: "开始时间",
- prop: "studyStartTime",
- scope: "aTimeSE",
- },
- {
- label: "结束时间",
- prop: "studyEndTime",
- scope: "aTimeSE",
- },
- {
- label: "审核状态",
- prop: "status",
- scope: "select",
- options: [
- {
- label: "待审核",
- value: 2,
- },
- {
- label: "通过",
- value: 1,
- },
- {
- label: "作弊",
- value: 0,
- },
- ],
- },
- {
- label: "审核人",
- prop: "auditUserName",
- },
- {
- label: "审核时间",
- prop: "auditTime",
- scope: "aTime",
- },
- ],
- tableDataChild: {},
- tableSetChild: [],
- };
- },
- mounted() {
- this.getUserInfo();
- this.search();
- },
- methods: {
- comput(item) {
- var ast = (item.studyEndTime - item.studyStartTime) / 60;
- console.log(ast, item.durationTime, 555);
- if (ast < item.durationTime) {
- return "color:red;";
- } else {
- return "";
- }
- },
- /**
- * 通过 作弊 periodId
- */
- changeStatus(item, int, index) {
- var data = {
- id: item.periodStatusId,
- };
- if (int === 1) {
- data.status = 1;
- }
- if (int === 2) {
- data.status = 0;
- }
- this.$api.editGradeUsereditPeriode(data).then((res) => {
- this.$message.success("修改成功");
- this.getNewList(index, item.numIndex, item);
- });
- },
- changeStatusCharpter(item, int, index1, index2) {
- var data = {
- id: item.periodStatusId,
- };
- if (int === 1) {
- data.status = 1;
- }
- if (int === 2) {
- data.status = 0;
- }
- this.$api.editGradeUsereditPeriode(data).then((res) => {
- this.$message.success("修改成功");
- this.getNewListchapt(index1, index2, item.numIndex, item);
- });
- },
- changeStatusModule(item, int, index1, index2, index3) {
- var data = {
- id: item.periodStatusId,
- };
- if (int === 1) {
- data.status = 1;
- }
- if (int === 2) {
- data.status = 0;
- }
- this.$api.editGradeUsereditPeriode(data).then((res) => {
- this.$message.success("修改成功");
- this.getNewListMores(index1, index2, index3, item.numIndex, item);
- });
- },
- //批量审批
- getChangeStatus(int) {
- var data = {
- gradeId: Number(this.$route.query.id),
- userId: Number(this.$route.query.userId),
- goodsId: Number(this.$route.query.goodsId),
- };
- if (int === 1) {
- data.status = 1;
- }
- if (int === 2) {
- data.status = 0;
- }
- this.$api.editGradeUsereditPeriodeAll(data).then((res) => {
- if (int === 1) {
- this.$message.success("状态全部通过修改成功");
- }
- if (int === 2) {
- this.$message.success("状态全部作弊修改成功");
- }
- this.getUserInfo();
- this.search();
- });
- },
- //节
- getNewList(index, int, item) {
- let data = {
- courseId: item.courseId,
- moduleId: item.moduleId,
- chapterId: item.chapterId,
- numIndex: int,
- userId: this.$route.query.userId,
- goodsId: this.$route.query.goodsId,
- gradeId: this.$route.query.id,
- };
- if (item.type === 3) {
- data.sectionId = item.id;
- }
- if (item.type === 4) {
- data.examId = item.id;
- }
- this.$api.inquireGradegradelistPeriodAuditStatus(data).then((res) => {
- this.$set(this.listData.tableData3, index, res.data);
- this.getUserInfo();
- });
- },
- //章 节
- getNewListchapt(a, b, int, item) {
- let data = {
- courseId: item.courseId,
- moduleId: item.moduleId,
- chapterId: item.chapterId,
- numIndex: int,
- userId: this.$route.query.userId,
- goodsId: this.$route.query.goodsId,
- gradeId: this.$route.query.id,
- };
- if (item.type === 3) {
- data.sectionId = item.id;
- }
- if (item.type === 4) {
- data.examId = item.id;
- }
- this.$api.inquireGradegradelistPeriodAuditStatus(data).then((res) => {
- this.$set(
- this.listData.tableData2[a].classPeriodSectionList,
- b,
- res.data
- );
- this.getUserInfo();
- });
- },
- //模块 章 节
- getNewListMores(a, b, c, int, item) {
- let data = {
- courseId: item.courseId,
- moduleId: item.moduleId,
- chapterId: item.chapterId,
- numIndex: int,
- userId: this.$route.query.userId,
- goodsId: this.$route.query.goodsId,
- gradeId: this.$route.query.id,
- };
- if (item.type === 3) {
- data.sectionId = item.id;
- }
- if (item.type === 4) {
- data.examId = item.id;
- }
- this.$api.inquireGradegradelistPeriodAuditStatus(data).then((res) => {
- this.$set(
- this.listData.tableData1[a].classPeriods[b].classPeriodSectionList,
- c,
- res.data
- );
- this.getUserInfo();
- });
- },
- //获取用户信息
- getUserInfo() {
- this.$api
- .inquireGradegradelistUserlistPeriod({
- gradeId: this.$route.query.id,
- userId: this.$route.query.userId,
- goodsId: this.$route.query.goodsId,
- })
- .then((res) => {
- if (res.rows[0].keyValue) {
- var data = JSON.parse(res.rows[0].keyValue);
- this.recent_photos = data.recent_photos.value;
- this.idcard_face_photo = data.idcard_face_photo.value;
- this.idcard_national_photo = data.idcard_national_photo.value;
- this.realName = data.name.value;
- this.idCard = data.idcard.value;
- this.telPhone = data.telphone.value;
- }
- this.userData = res.rows[0];
- console.log(this.userData,123)
- });
- },
- search() {
- let data = {
- gradeId: this.$route.query.id,
- userId: this.$route.query.userId,
- goodsId: this.$route.query.goodsId,
- };
- this.loading = true;
- this.$api
- .inquireGradegradelistPeriodAudit(data)
- .then((res) => {
- let tab1 = [];
- let tab2 = [];
- let tab3 = [];
- for (let i = 0; i < res.rows.length; i++) {
- if (res.rows[i].type === 1) {
- tab1.push(res.rows[i]);
- }
- if (res.rows[i].type === 2) {
- tab2.push(res.rows[i]);
- }
- if (res.rows[i].type === 3) {
- tab3.push(res.rows[i]);
- }
- }
- this.listData.tableData1 = tab1;
- this.listData.tableData2 = tab2;
- this.listData.tableData3 = tab3;
- })
- .finally(() => {
- this.loading = false;
- });
- },
- },
- };
- </script>
- <style lang="less" scoped>
- .styFlex {
- width: 80px;
- text-align: center;
- }
- .btnstyles {
- margin-left: 0px;
- margin-bottom: 10px;
- }
- .dis_flexs {
- display: flex;
- align-items: center;
- }
- .dis_fs {
- display: flex;
- align-items: center;
- height: 211px;
- background-color: #eee;
- padding: 0px 30px;
- overflow: auto;
- .ul_ls {
- margin-right: 30px;
- align-self: flex-start;
- li {
- font-size: 14px;
- white-space: nowrap;
- margin-bottom: 14px;
- }
- }
- &::-webkit-scrollbar {
- width: 14px;
- height: 14px;
- }
- &::-webkit-scrollbar-track,
- &::-webkit-scrollbar-thumb {
- border-radius: 999px;
- border: 5px solid transparent;
- }
- &::-webkit-scrollbar-track {
- box-shadow: 1px 1px 5px rgba(0, 0, 0, 0.2) inset;
- }
- &::-webkit-scrollbar-thumb {
- min-height: 20px;
- background-clip: content-box;
- box-shadow: 0 0 0 5px rgba(0, 0, 0, 0.2) inset;
- }
- &::-webkit-scrollbar-corner {
- background: transparent;
- }
- }
- .photoSty1 {
- flex-shrink: 0;
- width: 150px;
- height: 160px;
- background-color: #fff;
- margin-right: 60px;
- position: relative;
- }
- .photoSty2 {
- position: relative;
- flex-shrink: 0;
- width: 230px;
- height: 160px;
- margin-right: 60px;
- background-color: #fff;
- }
- .pos_bottom {
- position: absolute;
- height: 20px;
- bottom: 0px;
- left: 0px;
- right: 0px;
- background-color: rgba(0, 0, 0, 0.8);
- text-align: center;
- line-height: 20px;
- font-size: 14px;
- color: #fff;
- }
- .dis_fls {
- margin: 16px 0px;
- display: flex;
- align-items: center;
- justify-content: space-between;
- flex-wrap: wrap;
- .s_sd {
- display: flex;
- align-items: center;
- flex-shrink: 0;
- margin-bottom: 10px;
- .dis_colu {
- height: 55px;
- margin-right: 14px;
- display: flex;
- flex-direction: column;
- justify-content: space-around;
- font-size: 14px;
- }
- }
- }
- .jdNumSty {
- border: 1px solid #000;
- border-radius: 6px;
- padding: 6px;
- }
- .shbtns {
- padding: 0px 10px;
- height: 55px;
- line-height: 55px;
- background-color: #eee;
- border-radius: 6px;
- }
- .btnStys {
- border: 1px solid #666;
- padding: 0px 8px;
- border-radius: 4px;
- font-size: 15px;
- margin-right: 8px;
- cursor: pointer;
- }
- .liImgs {
- float: left;
- width: 250px;
- height: 250px;
- margin-right: 20px;
- margin-bottom: 20px;
- position: relative;
- .abos {
- position: absolute;
- bottom: 0px;
- width: 100%;
- height: 44px;
- line-height: 44px;
- font-size: 16px;
- color: #000;
- text-align: center;
- background-color: rgba(90, 90, 90, 0.7);
- }
- }
- </style>
|