appoint.vue 46 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687
  1. <template>
  2. <div class="context">
  3. <!-- panel-->
  4. <div class="">
  5. <div class="panel">
  6. <h5>预约管理</h5>
  7. </div>
  8. <div class="timeList">
  9. <ul>
  10. <li :class="[{'active': i == choiceDate}]" v-for="(day,i) in weeks" @click="choiceTime(i)">
  11. <em>{{ day.name }}</em><span>{{ day.data }}</span>
  12. </li>
  13. </ul>
  14. </div>
  15. <el-tabs v-model="activeName" type="card">
  16. <el-tab-pane label="会员预约列表" name="second">
  17. <div class="panel-body">
  18. <div class="panel_control">
  19. <el-row :gutter="1">
  20. <el-col :span="4">
  21. <em>会员名:</em>
  22. <el-input v-model="panel.name" placeholder="请输入会员名"></el-input>
  23. </el-col>
  24. <el-col :span="4">
  25. <em>手机号:</em>
  26. <el-input v-model="panel.phone" placeholder="请输入手机号" type="number"></el-input>
  27. </el-col>
  28. <el-col :span="4">
  29. <em>预约课程:</em>
  30. <el-select v-model="panel.classId">
  31. <el-option
  32. v-for="item in panel.classOptions"
  33. :key="item.value"
  34. :label="item.label"
  35. :value="item.value">
  36. </el-option>
  37. </el-select>
  38. </el-col>
  39. <el-col :span="2">
  40. <el-button size="" type="primary" @click="query" plain :disabled="serachBtnStatus">
  41. 查询
  42. </el-button>
  43. </el-col>
  44. <el-col :span="8" style="float:right">
  45. <el-button class="pull-right vipAddBtn" type="warning" @click="addMember(1)" style="margin-left: 10px">本店预约</el-button>
  46. <el-button class="pull-right acrossAddBtn" type="success" @click="addMember(2)">跨店预约</el-button>
  47. </el-col>
  48. </el-row>
  49. </div>
  50. </div>
  51. <br>
  52. <div class="table">
  53. <el-table
  54. :data="tableData2"
  55. border
  56. is-horizontal-resize
  57. :default-sort="{prop: 'date', order: 'descending'}"
  58. element-loading-background="rgba(0, 0, 0, 0.8)"
  59. class=""
  60. @selection-change="handleSelectionChange" @current-change="clickChange"
  61. >
  62. >
  63. <el-table-column label="选择" width="55" fixed>
  64. <template slot-scope="scope">
  65. <el-radio v-model="tableRadio" :label="scope.row"><i></i></el-radio>
  66. </template>
  67. </el-table-column>
  68. <el-table-column label="序号" type="index" width="50" align="center" fixed>
  69. <template scope="scope">
  70. <span>{{ (start) + scope.$index + 1 }}</span>
  71. </template>
  72. </el-table-column>
  73. <el-table-column
  74. prop="UserName"
  75. label="会员名"
  76. fixed
  77. >
  78. </el-table-column>
  79. <el-table-column
  80. prop="Phone"
  81. label="手机号"
  82. width="160"
  83. sortable
  84. fixed
  85. >
  86. </el-table-column>
  87. <el-table-column
  88. prop="ClassName"
  89. label="预约课程"
  90. width="120"
  91. sortable
  92. >
  93. <template slot-scope="scope">
  94. <span class="lessons" :style="{ background:scope.row.ClassColor }">{{ scope.row.ClassName }}</span>
  95. </template>
  96. </el-table-column>
  97. <el-table-column
  98. prop="BeginTime"
  99. label="上课时间"
  100. :formatter="filterFmtDate"
  101. width="160"
  102. sortable
  103. >
  104. </el-table-column>
  105. <el-table-column
  106. prop="Base.CreatedAt"
  107. label="会员预约时间"
  108. width="160"
  109. :formatter="filterFmtDate"
  110. sortable
  111. >
  112. </el-table-column>
  113. <el-table-column
  114. prop="ConsumeHour"
  115. label="消耗课时"
  116. sortable
  117. >
  118. </el-table-column>
  119. <el-table-column
  120. prop="RemainHour"
  121. label="剩余课时"
  122. sortable
  123. >
  124. </el-table-column>
  125. <el-table-column
  126. prop="Status"
  127. label="预约状态"
  128. sortable
  129. >
  130. <template slot-scope="scope">
  131. <span v-if="scope.row.Status == 1" style="color: chartreuse">已预约</span>
  132. <span v-if="scope.row.Status == 2" style="color: #ccc">已取消</span>
  133. <span v-if="scope.row.Status == 3" style="color: red">预约未到</span>
  134. <span v-if="scope.row.Status == 4" style="color: #015B9E">已完成</span>
  135. </template>
  136. </el-table-column>
  137. <el-table-column
  138. prop="Status"
  139. label="操作"
  140. >
  141. <template slot-scope="scope">
  142. <el-button type="danger" size="mini" round
  143. @click="BtnOrderCancelByManager(scope.row)">取消预约
  144. </el-button>
  145. </template>
  146. </el-table-column>
  147. </el-table>
  148. <br>
  149. <el-pagination
  150. background
  151. :total="pageination.total"
  152. :page-size="pageination.pageItem"
  153. @current-change="pageChange"
  154. ></el-pagination>
  155. </div>
  156. </el-tab-pane>
  157. <el-tab-pane label="课程预约列表" name="first">
  158. <div class="table">
  159. <el-table
  160. :data="tableData"
  161. border
  162. is-horizontal-resize
  163. :default-sort="{prop: 'date', order: 'descending'}"
  164. element-loading-background="rgba(0, 0, 0, 0.8)"
  165. class=""
  166. @selection-change="handleSelectionChange" @current-change="clickChange"
  167. >
  168. <el-table-column label="序号" type="index" width="50" align="center">
  169. <template scope="scope">
  170. <span>{{ (start) + scope.$index + 1 }}</span>
  171. </template>
  172. </el-table-column>
  173. <el-table-column
  174. prop="BeginTime"
  175. label="上课时间"
  176. width="160"
  177. :formatter="filterFmtDate"
  178. >
  179. </el-table-column>
  180. <el-table-column
  181. prop="ClassName"
  182. label="课程"
  183. width="110"
  184. sortable
  185. >
  186. <template slot-scope="scope">
  187. <span class="lessons" :style="{ background:scope.row.ClassColor }">{{ scope.row.ClassName }}</span>
  188. </template>
  189. </el-table-column>
  190. <el-table-column
  191. prop="Recovered"
  192. label="预约比例"
  193. width="210px"
  194. sortable
  195. >
  196. <template slot-scope="scope">
  197. <el-progress
  198. :percentage="parseInt((scope.row.OrderCount/scope.row.OrderToplimit * 100))"
  199. :format="format"
  200. ></el-progress>
  201. </template>
  202. </el-table-column>
  203. <el-table-column
  204. prop="OrderToplimit"
  205. label="预约名额"
  206. >
  207. </el-table-column>
  208. <el-table-column
  209. prop="OrderCount"
  210. label="预约人数"
  211. >
  212. </el-table-column>
  213. <el-table-column
  214. prop="ConsumeHour"
  215. label="消耗课时"
  216. >
  217. </el-table-column>
  218. <el-table-column
  219. prop="WxOrder"
  220. label="微信可约"
  221. >
  222. <template slot-scope="scope">
  223. <!-- 0:不可预约 1:可预约-->
  224. <el-switch
  225. v-model="scope.row.WxOrder"
  226. :active-value="1"
  227. :inactive-value="0"
  228. active-color="#409EFF"
  229. inactive-color="#D9D9D9"
  230. @change=changeWechat($event,scope.row)
  231. >
  232. </el-switch>
  233. </template>
  234. </el-table-column>
  235. <el-table-column
  236. prop="StdId"
  237. label="操作"
  238. width=70px
  239. >
  240. <template slot-scope="scope">
  241. <el-button type="text" @click="seeDetail(scope.row)">详情</el-button>
  242. </template>
  243. </el-table-column>
  244. </el-table>
  245. <br>
  246. <el-pagination
  247. background
  248. :total="pageination.total"
  249. :page-size="pageination.pageItem"
  250. @current-change="pageChange"
  251. ></el-pagination>
  252. </div>
  253. </el-tab-pane>
  254. </el-tabs>
  255. </div>
  256. <el-dialog :title="dialogTitle" :visible.sync="dialogMemberVisible" width="650px">
  257. <div class="dialogContent">
  258. <div class="">
  259. <el-form ref="form" :model="form" label-width="160px">
  260. <el-form-item label="当前日期" :required="true">
  261. <el-input v-model="form.displayDay" placeholder="placeholder" :disabled="true"
  262. style="width: 220px"></el-input>
  263. </el-form-item>
  264. <el-form-item label="课程" :required="true">
  265. <el-select v-model="form.stdId" filterable placeholder="请选择"
  266. @change="vipSelect(form.stdId)">
  267. <el-option
  268. v-for="item in form.stdList"
  269. :key="item.value"
  270. :label="item.label"
  271. :value="item.value">
  272. </el-option>
  273. </el-select>
  274. </el-form-item>
  275. <!-- 课程联动查询userlist by classid-->
  276. <el-form-item label="本店会员" :required="true" v-if="form.addType == 1 ">
  277. <el-select v-model="form.userId" filterable placeholder="请选择"
  278. @change="reMainSelect(form.userId)">
  279. <el-option
  280. v-for="item in form.userList"
  281. :key="item.value"
  282. :label="item.label"
  283. :value="item.value">
  284. </el-option>
  285. </el-select>
  286. </el-form-item>
  287. <el-form-item label="跨店会员" :required="true" v-if="form.addType == 2 ">
  288. <el-select v-model="form.userId" filterable placeholder="请选择"
  289. @change="reMainSelect(form.userId)">
  290. <el-option
  291. v-for="item in form.userList"
  292. :key="item.value"
  293. :label="item.label"
  294. :value="item.value">
  295. </el-option>
  296. </el-select>
  297. </el-form-item>
  298. <el-form-item label="消耗课时">
  299. <el-input v-model="form.ConsumeHour" placeholder="placeholder" :disabled="true"
  300. style="width: 220px"></el-input>
  301. </el-form-item>
  302. <el-form-item label="会员剩余课时">
  303. <el-input v-model="form.remain" placeholder="placeholder" :disabled="true"
  304. style="width: 220px"></el-input>
  305. </el-form-item>
  306. </el-form>
  307. </div>
  308. </div>
  309. <div class="dialogFooter">
  310. <el-button type="primary" size="small" @click="ConfirmOrderAddByManager"
  311. :disabeld="BtnConfirmOrderAddByManager">确定
  312. </el-button>
  313. <el-button size="small" @click="dialogMemberVisible = false">取消</el-button>
  314. </div>
  315. </el-dialog>
  316. <el-dialog title="预约会员" :visible.sync="dialogTableVisible" width="650px">
  317. <el-table :data="gridData">
  318. <el-table-column property="UserName" label="姓名" width="200"></el-table-column>
  319. <el-table-column property="Phone" label="手机"></el-table-column>
  320. </el-table>
  321. </el-dialog>
  322. </div>
  323. </template>
  324. <script>
  325. import Global from '../Global.js'
  326. import {
  327. TodayClassOrderQuery,
  328. VipUserListQuery,
  329. TodayVipOrderQuery,
  330. ClassOrderQuery,
  331. OrderAddByManager,
  332. ClassListByOrderDate,
  333. VipUserOrderQuery,
  334. OrderCancelByManager,
  335. STTDetailWxOrderEdit,
  336. testTable,
  337. testSelect,
  338. WaitingBeginClassList,
  339. ShopWxStatusEdit,
  340. ClassListQuery,
  341. ClassSimpleQuery,
  342. AcrossUserSimpleQuery,
  343. VipUserSimpleQuery
  344. } from "../api/getApiRes";
  345. let qs = require('qs');
  346. export default {
  347. data() {
  348. return {
  349. BtnConfirmOrderAddByManager: false,
  350. serachBtnStatus: false,
  351. activeName: 'second',
  352. choiceDate: 0,//默认为今天
  353. tableView: true,//其他dialog
  354. dialogVisible: false,//其他dialog
  355. dialogTableVisible: false,//其他dialog
  356. dialogMemberVisible: false,//新增教练dialog
  357. dialogLesson: false,//课时调整
  358. dialogGift: false,//赠送课时调整
  359. dialogExpTime: false,//有效期调整
  360. dialogLessonTable: false,//教练课程
  361. dialogTitle: '增加预约',
  362. current: getNowDate(),
  363. dialogValue: [],
  364. weeks: [],
  365. gridData: [],
  366. start: 0,
  367. draw: 1,
  368. // panel 配置项目
  369. panel: {
  370. name: '',
  371. phone: '',
  372. classId: '0',
  373. usercode: '',
  374. username: '',
  375. compname: '',
  376. keyword: '',
  377. USERCODE: '',
  378. endType: '',
  379. taskstatus: 99,
  380. draw: 1,
  381. start: 0,
  382. recordsTotal: 0,
  383. recordsTotal2: 0,
  384. tableData: [],
  385. allTableData: [],
  386. allTableData2: [],
  387. limit: '10',
  388. multipleSort: false,
  389. loading: false,
  390. fileList: [],
  391. multipleSelection: [],
  392. detectedmac: '',
  393. options: [
  394. {value: 99, label: '全部'},
  395. {value: 1, label: '进行中'},
  396. {value: 2, label: '已完成'},
  397. ],
  398. endTypeOptions: [
  399. {value: 99, label: '全部'},
  400. {value: 30, label: '近一个月'},
  401. {value: 7, label: '近一周'},
  402. {value: 1, label: '当日'},
  403. ],
  404. // time1: globalBt(),
  405. },
  406. multipleSelection: [],
  407. pageination: {
  408. pageItem: 100,
  409. pageoptions: pageOptions(),
  410. total: 100,
  411. pageIndex: 1,
  412. },
  413. form: {
  414. name: '',
  415. displayDay: '',
  416. userCode: '',
  417. shopId: '',
  418. stdId: 0,
  419. userId: 0,
  420. memberType: 1,
  421. lesson: 1,
  422. gift: 1,
  423. btnType: 0,//0新建,1编辑编辑
  424. memo: '',
  425. expTime: '',
  426. dialogdata: [],//穿梭待选
  427. dialogValue: [],//穿梭已选
  428. userList: [],//穿梭已选
  429. stdList: [],//穿梭已选
  430. remain: 0,
  431. ConsumeHour: 0,
  432. addType: 0
  433. },
  434. memberTypes: [
  435. {value: 1, label: '年教练'},
  436. {value: 2, label: '充值教练'},
  437. ],
  438. tableData: [],
  439. tableData2: [],
  440. tableRadio: [],
  441. }
  442. },
  443. mounted() {
  444. if (this.$route.query.page == 'second') {
  445. this.panel.name = this.$route.query.name;
  446. this.activeName = 'second'
  447. } else {
  448. this.activeName = 'second'
  449. }
  450. this.ClassSelect();
  451. this.panelSelect();
  452. // this.getCurrWeekDays();
  453. this.getFurtherDays();
  454. },
  455. methods: {
  456. clickChange(item) {
  457. this.tableRadio = item
  458. },
  459. // .课程表详情微信可预约状态修改
  460. changeWechat(e, appoint) {
  461. let that = this;
  462. let statusText = appoint.WxOrder == 0 ? "关闭" : "开启";
  463. this.$confirm('是否' + statusText + '课程预约?', '微信预约操作', {
  464. confirmButtonText: '确定',
  465. cancelButtonText: '取消',
  466. type: 'warning'
  467. }).then(() => {
  468. let param = {
  469. token: localStorage.token,
  470. stdId: appoint.StdId,
  471. wxOrder: e,
  472. };
  473. let postdata = qs.stringify(param);
  474. STTDetailWxOrderEdit(postdata).then(res => {
  475. let json = res;
  476. if (json.Code == 0) {
  477. that.$message({
  478. showClose: true,
  479. message: '预约已' + statusText + '!',
  480. type: 'success'
  481. });
  482. // table 重载
  483. that.getTableQuery();
  484. } else {
  485. // 状态返回
  486. appoint.WxOrder = e == 0 ? 1 : 0;
  487. that.$message.error(json.Memo + ' 错误码:' + json.Code);
  488. }
  489. })
  490. }).catch(() => {
  491. this.appoint = "0";
  492. this.$message({
  493. type: 'info',
  494. message: '已取消当前操作'
  495. });
  496. });
  497. },
  498. panelSelect() {
  499. let that = this;
  500. let param = {
  501. token: localStorage.token,
  502. };
  503. let postdata = qs.stringify(param);
  504. ClassSimpleQuery(postdata).then(res => {
  505. // ClassListQuery(postdata).then(res => {
  506. let json = res;
  507. if (json.Code == 0) {
  508. if (json.Rs == null) return false;
  509. that.panel.classOptions = turnClassResToOption(json.Rs);
  510. that.panel.classOptions.unshift({value: '0', label: '全部'})
  511. } else {
  512. that.$message.error(json.Memo + ' 错误码:' + json.Code);
  513. }
  514. })
  515. },
  516. vipSelect(stdId) {
  517. let that = this;
  518. // 筛选相同的stdid的classId
  519. that.form.stdList.map(function (item) {
  520. if (item.value == stdId) {
  521. that.form.ConsumeHour = item.ConsumeHour;
  522. let param = {
  523. token: localStorage.token,
  524. // classId: item.classId
  525. };
  526. let postdata = qs.stringify(param);
  527. // VipUserListQuery
  528. // 本店会员添加时
  529. if (that.form.addType == 1) {
  530. VipUserSimpleQuery(postdata).then(res => {
  531. let json = res;
  532. if (json.Code == 0) {
  533. that.form.userId = '';
  534. that.form.userList = turnResToOptionBySimViper(json.Rs);
  535. } else {
  536. that.$message.error(json.Memo + ' 错误码:' + json.Code);
  537. }
  538. })
  539. }
  540. // 跨店会员添加时
  541. if (that.form.addType == 2) {
  542. AcrossUserSimpleQuery(postdata).then(res => {
  543. let json = res;
  544. if (json.Code == 0) {
  545. that.form.userId = '';
  546. that.form.userList = turnResToOptionBySimViper(json.Rs);
  547. } else {
  548. that.$message.error(json.Memo + ' 错误码:' + json.Code);
  549. }
  550. })
  551. }
  552. }
  553. })
  554. },
  555. reMainSelect(userId) {
  556. let that = this;
  557. this.form.userList.filter((v) => {
  558. if (v.key == userId) {
  559. that.form.remain = v.RemainHour;
  560. }
  561. })
  562. },
  563. ClassSelect() {
  564. let that = this;
  565. let param = {
  566. token: localStorage.token,
  567. start: 1,//
  568. tableMax: 9999,//
  569. };
  570. let postdata = qs.stringify(param);
  571. WaitingBeginClassList(postdata).then(res => {
  572. let json = res;
  573. if (json.Code == 0) {
  574. that.form.stdList = turnStdToOption(json.Rs);
  575. } else {
  576. that.$message.error(json.Memo + ' 错误码:' + json.Code);
  577. }
  578. })
  579. },
  580. ConfirmOrderAddByManager() {
  581. let that = this;
  582. that.BtnConfirmOrderAddByManager = true;
  583. let param = {
  584. token: localStorage.token,
  585. stdId: this.form.stdId,
  586. userId: this.form.userId,
  587. };
  588. let postdata = qs.stringify(param);
  589. OrderAddByManager(postdata).then(res => {
  590. let json = res;
  591. that.BtnConfirmOrderAddByManager = false;
  592. if (json.Code == 0) {
  593. that.$message({
  594. showClose: true,
  595. message: '预约添加成功!',
  596. type: 'success'
  597. });
  598. this.getTableQuery2();
  599. that.dialogMemberVisible = false;
  600. } else {
  601. that.$message.error(json.Memo + ' 错误码:' + json.Code);
  602. }
  603. })
  604. },
  605. // 选择日期
  606. choiceTime(i) {
  607. this.choiceDate = parseInt(i);
  608. // 读取当前页
  609. if (this.activeName == 'first') {
  610. this.getTableQuery();
  611. } else {
  612. // second
  613. this.getTableQuery2();
  614. }
  615. },
  616. seeDetail(row) {
  617. let that = this;
  618. let dayIndex = parseInt(this.choiceDate);
  619. let param = {
  620. token: localStorage.token,
  621. classId: row.ClassId,
  622. orderDate: this.weeks[dayIndex].orderDate,
  623. stdId: row.StdId,
  624. };
  625. let postdata = qs.stringify(param);
  626. VipUserOrderQuery(postdata).then(res => {
  627. let json = res;
  628. if (json.Code == 0) {
  629. this.dialogTableVisible = true;
  630. this.gridData = json.Rs;
  631. console.log(123);
  632. } else {
  633. that.$message.error(json.Memo + ' 错误码:' + json.Code);
  634. }
  635. })
  636. },
  637. format(percentage) {
  638. return percentage === 100 ? '已满' : `${percentage}%`;
  639. },
  640. // 编辑
  641. BtnOrderCancelByManager(row) {
  642. let that = this;
  643. this.$confirm('是否取消用户 ' + row.UserName + ' 的预约?', '取消预约', {
  644. confirmButtonText: '确定',
  645. cancelButtonText: '取消',
  646. type: 'warning'
  647. }).then(() => {
  648. let param = {
  649. token: localStorage.token,
  650. orderId: row.OrderId,
  651. };
  652. let postdata = qs.stringify(param);
  653. OrderCancelByManager(postdata).then(res => {
  654. let json = res;
  655. if (json.Code == 0) {
  656. that.$message({
  657. showClose: true,
  658. message: row.UserName + '取消预约成功!',
  659. type: 'success'
  660. });
  661. // table 重载
  662. that.getTableQuery2();
  663. } else {
  664. that.$message.error(json.Memo + ' 错误码:' + json.Code);
  665. }
  666. })
  667. }).catch(() => {
  668. this.$message({
  669. type: 'info',
  670. message: '已取消操作'
  671. });
  672. });
  673. },
  674. // 禁用
  675. pauseRow(row) {
  676. let that = this;
  677. this.$confirm('是否禁用用户' + row.name + '?', '禁用操作', {
  678. confirmButtonText: '确定',
  679. cancelButtonText: '取消',
  680. type: 'warning'
  681. }).then(() => {
  682. let param = {
  683. token: localStorage.token,
  684. Id: row.Id,
  685. status: 0,
  686. };
  687. let postdata = qs.stringify(param);
  688. testTable(postdata).then(res => {
  689. let json = res;
  690. if (json.Code == 0) {
  691. that.$message({
  692. showClose: true,
  693. message: row.name + '禁用成功!',
  694. type: 'success'
  695. });
  696. // table 重载
  697. that.getTableQuery();
  698. } else {
  699. that.$message.error(json.Memo + ' 错误码:' + json.Code);
  700. }
  701. })
  702. }).catch(() => {
  703. this.$message({
  704. type: 'info',
  705. message: '已取消禁用'
  706. });
  707. });
  708. },
  709. // 启用
  710. runRow(row) {
  711. let that = this;
  712. this.$confirm('是否启用用户' + row.name + '?', '启用操作', {
  713. confirmButtonText: '确定',
  714. cancelButtonText: '取消',
  715. type: 'warning'
  716. }).then(() => {
  717. let param = {
  718. token: localStorage.token,
  719. Id: row.Id,
  720. status: 1,
  721. };
  722. let postdata = qs.stringify(param);
  723. testTable(postdata).then(res => {
  724. let json = res;
  725. if (json.Code == 0) {
  726. that.$message({
  727. showClose: true,
  728. message: row.name + '启用成功!',
  729. type: 'success'
  730. });
  731. // table 重载
  732. that.getTableQuery();
  733. } else {
  734. that.$message.error(json.Memo + ' 错误码:' + json.Code);
  735. }
  736. })
  737. }).catch(() => {
  738. this.$message({
  739. type: 'info',
  740. message: '已取消启用'
  741. });
  742. });
  743. },
  744. // 关闭所有
  745. allDialogClose() {
  746. this.dialogVisible = false;
  747. this.dialogGift = false;
  748. this.dialogLesson = false;
  749. this.dialogExpTime = false;
  750. this.dialogLessonTable = false;
  751. },
  752. // 用户禁用 todo
  753. // 用户启用 todo
  754. // 有效期调整
  755. ExpTimeChange() {
  756. // 仅针对年费用户,使用日期格式
  757. this.allDialogClose();
  758. if (!this.multipleSelection.length) {
  759. this.$message({
  760. showClose: true,
  761. message: '错了哦,需要先选中至少一条记录',
  762. type: 'error'
  763. });
  764. return false
  765. }
  766. if (this.multipleSelection.length != 1) {
  767. this.$message({
  768. showClose: true,
  769. message: '错了哦,只能选中一条记录',
  770. type: 'error'
  771. });
  772. return false
  773. }
  774. let row = this.tableRadio;
  775. if (parseInt(row.vipType) == 2) {
  776. this.$message({
  777. showClose: true,
  778. message: '错了哦,充值教练不能调整有效期',
  779. type: 'error'
  780. });
  781. return false
  782. }
  783. this.form.expTime = row.expTime;
  784. this.form.rowName = row.name;
  785. this.dialogVisible = true;
  786. this.dialogExpTime = true;
  787. },
  788. // 课时调整
  789. lessonChange() {
  790. this.allDialogClose();
  791. if (!this.multipleSelection.length) {
  792. this.$message({
  793. showClose: true,
  794. message: '错了哦,需要先选中至少一条记录',
  795. type: 'error'
  796. });
  797. return false
  798. }
  799. if (this.multipleSelection.length != 1) {
  800. this.$message({
  801. showClose: true,
  802. message: '错了哦,只能选中一条记录',
  803. type: 'error'
  804. });
  805. return false
  806. }
  807. let row = this.tableRadio;
  808. this.form.lesson = row.Recovered;
  809. this.form.rowName = row.name;
  810. this.dialogVisible = true;
  811. this.dialogLesson = true;
  812. },
  813. // 赠送调整
  814. giftChange() {
  815. this.allDialogClose();
  816. if (!this.multipleSelection.length) {
  817. this.$message({
  818. showClose: true,
  819. message: '错了哦,需要先选中至少一条记录',
  820. type: 'error'
  821. });
  822. return false
  823. }
  824. if (this.multipleSelection.length != 1) {
  825. this.$message({
  826. showClose: true,
  827. message: '错了哦,只能选中一条记录',
  828. type: 'error'
  829. });
  830. return false
  831. }
  832. let row = this.tableRadio;
  833. this.form.gift = row.Recovered;
  834. this.form.rowName = row.name;
  835. this.dialogVisible = true;
  836. this.dialogGift = true;
  837. },
  838. // 增删教练课程
  839. lessonStudenChange() {
  840. this.allDialogClose();
  841. if (!this.multipleSelection.length) {
  842. this.$message({
  843. showClose: true,
  844. message: '错了哦,需要先选中至少一条记录',
  845. type: 'error'
  846. });
  847. return false
  848. }
  849. if (this.multipleSelection.length != 1) {
  850. this.$message({
  851. showClose: true,
  852. message: '错了哦,只能选中一条记录',
  853. type: 'error'
  854. });
  855. return false
  856. }
  857. let row = this.tableRadio;
  858. this.form.gift = row.Recovered;
  859. this.form.rowName = row.name;
  860. this.dialogVisible = true;
  861. this.dialogLessonTable = true;
  862. },
  863. // 确认提交新增教练
  864. confirmMember() {
  865. let that = this;
  866. // checkNum
  867. if (!that.form.userCode) {
  868. this.$message.error('错了哦,手机号不能为空');
  869. return false
  870. }
  871. if (!globalCheckPhone(that.form.userCode)) {
  872. this.$message.error('错了哦,手机号格式不正确');
  873. return false
  874. }
  875. if (!that.form.name) {
  876. this.$message.error('错了哦,教练名不能为空');
  877. return false
  878. }
  879. if (that.form.name.length > 8) {
  880. this.$message.error('错了哦,教练名字数超过8个字');
  881. return false
  882. }
  883. if (that.form.memo) {
  884. if (that.form.memo.length > 200) {
  885. this.$message.error('错了哦,备注字数超过200个字');
  886. return false
  887. }
  888. }
  889. let param = {
  890. token: localStorage.token,
  891. userCode: that.form.userCode,
  892. name: that.form.name,
  893. memberType: that.form.memberType,
  894. lesson: that.form.lesson,
  895. gift: that.form.gift,
  896. memo: that.form.memo,
  897. dialogValue: that.form.dialogValue,
  898. };
  899. let postdata = qs.stringify(param);
  900. testSelect(postdata).then(res => {
  901. let json = res;
  902. if (json.Code == 0) {
  903. // 关闭弹窗
  904. that.dialogMemberVisible = false;
  905. // 重载列表
  906. that.getTableQuery();
  907. that.$message({
  908. showClose: true,
  909. message: '教练添加成功!',
  910. type: 'success'
  911. });
  912. } else {
  913. that.$message.error(json.Memo + ' 错误码:' + json.Code);
  914. }
  915. })
  916. },
  917. confirmEditMember() {
  918. let that = this;
  919. // checkNum
  920. if (!that.form.userCode) {
  921. this.$message.error('错了哦,手机号不能为空');
  922. return false
  923. }
  924. console.log(that.form.userCode);
  925. if (!globalCheckPhone(that.form.userCode)) {
  926. this.$message.error('错了哦,手机号格式不正确');
  927. return false
  928. }
  929. if (!that.form.name) {
  930. this.$message.error('错了哦,教练名不能为空');
  931. return false
  932. }
  933. if (that.form.name.length > 8) {
  934. this.$message.error('错了哦,教练名字数超过8个字');
  935. return false
  936. }
  937. if (that.form.memo) {
  938. if (that.form.memo.length > 200) {
  939. this.$message.error('错了哦,备注字数超过200个字');
  940. return false
  941. }
  942. }
  943. let param = {
  944. token: localStorage.token,
  945. userCode: that.form.userCode,
  946. name: that.form.name,
  947. memberType: that.form.memberType,
  948. lesson: that.form.lesson,
  949. gift: that.form.gift,
  950. memo: that.form.memo,
  951. dialogValue: that.form.dialogValue,
  952. };
  953. let postdata = qs.stringify(param);
  954. testSelect(postdata).then(res => {
  955. let json = res;
  956. if (json.Code == 0) {
  957. // 关闭弹窗
  958. that.dialogMemberVisible = false;
  959. // 重载列表
  960. that.getTableQuery();
  961. that.$message({
  962. showClose: true,
  963. message: '教练信息编辑成功!',
  964. type: 'success'
  965. });
  966. } else {
  967. that.$message.error(json.Memo + ' 错误码:' + json.Code);
  968. }
  969. })
  970. },
  971. // 确认提交课时
  972. confirmLesson() {
  973. let that = this;
  974. // checkNum
  975. let param = {
  976. token: localStorage.token,
  977. userCode: that.form.userCode,
  978. lesson: that.form.lesson,
  979. };
  980. let postdata = qs.stringify(param);
  981. testSelect(postdata).then(res => {
  982. let json = res;
  983. if (json.Code == 0) {
  984. // 关闭弹窗
  985. that.dialogVisible = false;
  986. // 重载列表
  987. that.getTableQuery();
  988. that.$message({
  989. showClose: true,
  990. message: '课时调整成功!',
  991. type: 'success'
  992. });
  993. } else {
  994. that.$message.error(json.Memo + ' 错误码:' + json.Code);
  995. }
  996. })
  997. },
  998. // 确认提交赠送
  999. confirmGift() {
  1000. let that = this;
  1001. // checkNum
  1002. let param = {
  1003. token: localStorage.token,
  1004. userCode: that.form.userCode,
  1005. gift: that.form.gift,
  1006. };
  1007. let postdata = qs.stringify(param);
  1008. testSelect(postdata).then(res => {
  1009. let json = res;
  1010. if (json.Code == 0) {
  1011. // 关闭弹窗
  1012. that.dialogVisible = false;
  1013. // 重载列表
  1014. that.getTableQuery();
  1015. that.$message({
  1016. showClose: true,
  1017. message: '赠送课时调整成功!',
  1018. type: 'success'
  1019. });
  1020. } else {
  1021. that.$message.error(json.Memo + ' 错误码:' + json.Code);
  1022. }
  1023. })
  1024. },
  1025. // 确认提交有效期
  1026. confirmExpTime() {
  1027. let that = this;
  1028. // checkNum
  1029. let param = {
  1030. token: localStorage.token,
  1031. userCode: that.form.userCode,
  1032. expTime: that.form.expTime,
  1033. };
  1034. let postdata = qs.stringify(param);
  1035. testSelect(postdata).then(res => {
  1036. let json = res;
  1037. if (json.Code == 0) {
  1038. // 关闭弹窗
  1039. that.dialogVisible = false;
  1040. // 重载列表
  1041. that.getTableQuery();
  1042. that.$message({
  1043. showClose: true,
  1044. message: '赠送课时调整成功!',
  1045. type: 'success'
  1046. });
  1047. } else {
  1048. that.$message.error(json.Memo + ' 错误码:' + json.Code);
  1049. }
  1050. })
  1051. },
  1052. // 确认提交教练课程
  1053. confirmLessonTable() {
  1054. let that = this;
  1055. // checkNum
  1056. let param = {
  1057. token: localStorage.token,
  1058. userCode: that.form.userCode,
  1059. dialogValue: that.form.dialogValue,
  1060. };
  1061. let postdata = qs.stringify(param);
  1062. testSelect(postdata).then(res => {
  1063. let json = res;
  1064. if (json.Code == 0) {
  1065. // 关闭弹窗
  1066. that.dialogVisible = false;
  1067. // 重载列表
  1068. that.getTableQuery();
  1069. that.$message({
  1070. showClose: true,
  1071. message: '教练课程调整成功!',
  1072. type: 'success'
  1073. });
  1074. } else {
  1075. that.$message.error(json.Memo + ' 错误码:' + json.Code);
  1076. }
  1077. })
  1078. },
  1079. // 新增预约
  1080. addMember(type) {
  1081. this.clearForm();
  1082. // 加载当前可选课程
  1083. this.getClassListByOrderDate();
  1084. this.dialogMemberVisible = true;
  1085. this.form.displayDay = this.weeks[this.choiceDate].data + ' ' + this.weeks[this.choiceDate].name;
  1086. this.btnType = 0;
  1087. this.form.ConsumeHour = 0;
  1088. this.form.addType = type
  1089. this.dialogTitle = '新增预约';
  1090. },
  1091. // 加载当前可选课程
  1092. getClassListByOrderDate() {
  1093. let that = this;
  1094. let dayIndex = parseInt(this.choiceDate);
  1095. let param = {
  1096. token: localStorage.token,
  1097. orderDate: this.weeks[dayIndex].orderDate,
  1098. };
  1099. let postdata = qs.stringify(param);
  1100. ClassListByOrderDate(postdata).then(res => {
  1101. let json = res;
  1102. if (json.Code == 0) {
  1103. that.form.stdList = turnStdToOption(json.Rs);
  1104. } else {
  1105. that.$message.error(json.Memo + ' 错误码:' + json.Code);
  1106. }
  1107. })
  1108. },
  1109. // 删除
  1110. delList() {
  1111. let that = this;
  1112. // checkNum
  1113. if (!this.multipleSelection.length) {
  1114. that.$message({
  1115. showClose: true,
  1116. message: '错了哦,需要先选中至少一条记录',
  1117. type: 'error'
  1118. });
  1119. return false
  1120. }
  1121. if (this.multipleSelection.length != 1) {
  1122. that.$message({
  1123. showClose: true,
  1124. message: '错了哦,只能选中一条记录',
  1125. type: 'error'
  1126. });
  1127. return false
  1128. }
  1129. let detectorid = that.tableRadio.Id;
  1130. let param = {
  1131. token: localStorage.token,
  1132. detectorid: detectorid,
  1133. status: 9,//0禁用1启用9删除
  1134. };
  1135. let postdata = qs.stringify(param);
  1136. this.$confirm('此操作将永久删除该教练, 是否继续?', '提示', {
  1137. confirmButtonText: '确定',
  1138. cancelButtonText: '取消',
  1139. type: 'warning'
  1140. }).then(() => {
  1141. testSelect(postdata).then(res => {
  1142. let json = res;
  1143. if (json.Code == 0) {
  1144. that.$message({
  1145. showClose: true,
  1146. message: '选中的教练已删除!',
  1147. type: 'success'
  1148. });
  1149. // 重载列表
  1150. that.getTableQuery();
  1151. } else {
  1152. that.$message.error(json.Memo + ' 错误码:' + json.Code);
  1153. }
  1154. });
  1155. }).catch(() => {
  1156. this.$message({
  1157. type: 'info',
  1158. message: '已取消删除'
  1159. });
  1160. });
  1161. },
  1162. handleSelectionChange(val) {
  1163. this.multipleSelection = val;
  1164. },
  1165. // 查询按钮
  1166. query() {
  1167. let that = this;
  1168. that.serachBtnStatus = true;
  1169. let totalTime = 2
  1170. let clock = window.setInterval(() => {
  1171. totalTime--
  1172. if (totalTime < 0) {
  1173. totalTime = 2;
  1174. that.serachBtnStatus = false;
  1175. }
  1176. }, 1000)
  1177. this.getTableQuery2();
  1178. this.$message.success('查询完毕');
  1179. },
  1180. clearForm() {
  1181. // clear
  1182. this.form.stdId = '';
  1183. this.form.userId = '';
  1184. this.form.name = '';
  1185. this.form.userCode = '';
  1186. this.form.shopId = '';
  1187. this.form.userList = [];
  1188. },
  1189. // 页面数据查询
  1190. getTableQuery() {
  1191. let that = this;
  1192. that.loading = true;
  1193. let dayIndex = parseInt(this.choiceDate);
  1194. let param = {
  1195. token: localStorage.token,
  1196. orderDate: this.weeks[dayIndex].orderDate,
  1197. };
  1198. let postdata = qs.stringify(param);
  1199. ClassOrderQuery(postdata).then(res => {
  1200. let json = res;
  1201. if (json.Code == 0) {
  1202. that.loading = false;
  1203. if (json.Rs) {
  1204. that.allTableData = [];
  1205. that.allTableData = json.Rs;
  1206. that.recordsTotal = json.Rs.length;
  1207. } else {
  1208. that.allTableData = [];
  1209. that.recordsTotal = 0;
  1210. }
  1211. // 设置分页数据
  1212. that.setPaginations();
  1213. } else {
  1214. that.$message.error(json.Memo + ' 错误码:' + json.Code);
  1215. }
  1216. })
  1217. },
  1218. getTableQuery2() {
  1219. let that = this;
  1220. that.loading = true;
  1221. let dayIndex = parseInt(this.choiceDate);
  1222. let param = {
  1223. token: localStorage.token,
  1224. classId: this.panel.classId,//
  1225. stdId: 0,//
  1226. name: this.panel.name,//
  1227. phone: this.panel.phone,//
  1228. orderDate: this.weeks[dayIndex].orderDate,
  1229. };
  1230. let postdata = qs.stringify(param);
  1231. VipUserOrderQuery(postdata).then(res => {
  1232. let json = res;
  1233. if (json.Code == 0) {
  1234. that.loading = false;
  1235. if (json.Rs) {
  1236. that.allTableData2 = json.Rs;
  1237. that.recordsTotal2 = json.Rs.length;
  1238. } else {
  1239. that.allTableData2 = [];
  1240. that.recordsTotal2 = 0;
  1241. }
  1242. // 设置分页数据
  1243. that.setPaginations2();
  1244. } else {
  1245. that.$message.error(json.Memo + ' 错误码:' + json.Code);
  1246. }
  1247. })
  1248. },
  1249. // 设置分页数据
  1250. setPaginations() {
  1251. // 分页属性
  1252. let that = this;
  1253. that.pageination.total = that.recordsTotal;
  1254. // 默认分页
  1255. that.tableData = that.allTableData.filter((item, index) => {
  1256. return index < that.pageination.pageItem;
  1257. });
  1258. },
  1259. // 设置分页数据
  1260. setPaginations2() {
  1261. // 分页属性
  1262. let that = this;
  1263. that.pageination.total = that.recordsTotal2;
  1264. // 默认分页
  1265. that.tableData2 = that.allTableData2.filter((item, index) => {
  1266. return index < that.pageination.pageItem;
  1267. });
  1268. },
  1269. // 每页显示数量
  1270. handleSizeChange() {
  1271. let that = this;
  1272. that.tableData = that.allTableData.filter((item, index) => {
  1273. return index < that.pageination.pageItem;
  1274. });
  1275. that.draw = that.pageination.pageItem;
  1276. that.getTableQuery();
  1277. },
  1278. // 翻页
  1279. pageChange(pageIndex) {
  1280. let that = this;
  1281. // 获取当前页
  1282. let index = that.pageination.pageItem * (pageIndex - 1);
  1283. // 数据总数
  1284. let nums = that.pageination.pageItem * pageIndex;
  1285. // 容器
  1286. let tables = [];
  1287. for (var i = index; i < nums; i++) {
  1288. if (that.allTableData[i]) {
  1289. tables.push(that.allTableData[i])
  1290. }
  1291. this.tableData = tables;
  1292. }
  1293. that.start = index * that.draw;
  1294. // that.getTableQuery();
  1295. },
  1296. // 自动排序
  1297. sortChange(params) {
  1298. console.log(params)
  1299. },
  1300. // 过滤时间
  1301. filterFmtDate(value, row, column) {
  1302. let that = this;
  1303. return nonTfmtDate(column, 11);
  1304. },
  1305. // 过滤金额
  1306. filterMoney(value, row, column) {
  1307. let that = this;
  1308. return parseFloat(column).toFixed(2);
  1309. },
  1310. // 本周
  1311. getCurrWeekDays() {
  1312. let now = new Date();
  1313. let nowTime = now.getTime();
  1314. let day = now.getDay();
  1315. let oneDayTime = 24 * 60 * 60 * 1000;
  1316. let days = '';
  1317. let item = [];
  1318. let month = 0;
  1319. for (let i = 0; i < 7; i++) {
  1320. days = new Date(nowTime + (i - day) * oneDayTime);//显示周日
  1321. month = days.getMonth() + 1;
  1322. item = {
  1323. name: this.numberToWeek(days.getDay()),
  1324. data: month + '月' + days.getDate() + '日',
  1325. orderDate: new Date().getFullYear() + '-' + month + '-' + days.getDate()
  1326. }
  1327. this.weeks.push(item)
  1328. }
  1329. },
  1330. // 获取未来7天的
  1331. getFurtherDays() {
  1332. let now = new Date();
  1333. let nowTime = now.getTime();
  1334. let oneDayTime = 24 * 60 * 60 * 1000;
  1335. let days = '';
  1336. let item = [];
  1337. let month = 0;
  1338. let day = 0;
  1339. for (let i = 0; i < 7; i++) {
  1340. days = new Date(nowTime + (i) * oneDayTime);//显示周日
  1341. month = days.getMonth() + 1;
  1342. day = days.getDate();
  1343. month = month < 10 ? '0' + month : month;
  1344. day = day < 10 ? '0' + day : day;
  1345. item = {
  1346. name: this.numberToWeek(days.getDay()),
  1347. data: days.getMonth() + 1 + '月' + days.getDate() + '日',
  1348. orderDate: days.getFullYear() + '-' + month + '-' + day
  1349. }
  1350. this.weeks.push(item)
  1351. }
  1352. this.getTableQuery();
  1353. this.getTableQuery2();
  1354. },
  1355. numberToWeek(val) {
  1356. switch (parseInt(val)) {
  1357. case 1:
  1358. return '星期一';
  1359. break;
  1360. case 2:
  1361. return '星期二';
  1362. break;
  1363. case 3:
  1364. return '星期三';
  1365. break;
  1366. case 4:
  1367. return '星期四';
  1368. break;
  1369. case 5:
  1370. return '星期五';
  1371. break;
  1372. case 6:
  1373. return '星期六';
  1374. break;
  1375. case 0:
  1376. return '星期天';
  1377. break;
  1378. }
  1379. }
  1380. },
  1381. watch: {
  1382. $route(to) {
  1383. if (to.name == 'appoint') {
  1384. this.panelSelect();
  1385. if (this.$route.query.page == 'second') {
  1386. this.activeName = 'second';
  1387. this.panel.name = this.$route.query.name;
  1388. // second
  1389. this.getTableQuery2();
  1390. }
  1391. }
  1392. },
  1393. activeName(val) {
  1394. // 重置一次选择
  1395. this.tableRadio = [];
  1396. if (val == 'first') {
  1397. this.getTableQuery();
  1398. } else {
  1399. // second
  1400. this.getTableQuery2();
  1401. this.panelSelect();
  1402. }
  1403. },
  1404. }
  1405. }
  1406. </script>
  1407. <style scoped>
  1408. @import "../assets/css/panel.css";
  1409. .context {
  1410. /* height: 770px; */
  1411. overflow-y: scroll;
  1412. display: block;
  1413. margin: 0 auto;
  1414. background-color: #fff !important;
  1415. padding: 30px;
  1416. }
  1417. .panel-body {
  1418. padding: 20px;
  1419. background: #F0F2F5;
  1420. }
  1421. .change {
  1422. width: 100%;
  1423. overflow: hidden;
  1424. display: block;
  1425. margin: 0 auto;
  1426. padding-top: 10px;
  1427. padding-bottom: 10px;
  1428. }
  1429. .change button {
  1430. float: left;
  1431. }
  1432. .change button.pull-right {
  1433. float: right;
  1434. }
  1435. .dialogTitle {
  1436. width: 100%;
  1437. overflow: hidden;
  1438. display: block;
  1439. margin: 0 auto;
  1440. color: #000000;
  1441. font-size: 18px;
  1442. text-align: center;
  1443. }
  1444. .dialogTitle em {
  1445. float: none;
  1446. font-style: normal;
  1447. color: #3799FF;
  1448. margin: 0;
  1449. }
  1450. /deep/ .el-transfer-panel__item .el-checkbox__input {
  1451. left: 40px;
  1452. }
  1453. .dialogFooter {
  1454. width: 90%;
  1455. overflow: hidden;
  1456. display: block;
  1457. margin: 0 auto;
  1458. margin-top: 10px;
  1459. }
  1460. .dialogFooter button {
  1461. float: right;
  1462. margin-left: 10px;
  1463. }
  1464. .dialogContent {
  1465. width: 100%;
  1466. overflow: hidden;
  1467. display: block;
  1468. margin: 0 auto;
  1469. }
  1470. .dialogContent .pull-left {
  1471. width: 30%;
  1472. float: left;
  1473. }
  1474. .dialogContent .pull-right {
  1475. width: 70%;
  1476. float: right;
  1477. }
  1478. .current {
  1479. width: 158px;
  1480. height: 23px;
  1481. /*float: left;*/
  1482. border-radius: 250px;
  1483. text-align: center;
  1484. background: #F0F2F5;
  1485. color: #545454;
  1486. font-size: 14px;
  1487. padding: 3px 10px;
  1488. margin-left: 20px;
  1489. }
  1490. .timeList {
  1491. width: 800px;
  1492. overflow: hidden;
  1493. float: right;
  1494. position: relative;
  1495. z-index: 100;
  1496. cursor: pointer;
  1497. }
  1498. .timeList ul {
  1499. width: 100%;
  1500. overflow: hidden;
  1501. display: block;
  1502. margin: 0 auto;
  1503. list-style: none;
  1504. }
  1505. .timeList li {
  1506. width: 100px;
  1507. overflow: hidden;
  1508. list-style: none;
  1509. float: left;
  1510. margin-right: 6px;
  1511. border: 1px solid #ccc;
  1512. border-bottom: 0;
  1513. text-align: center;
  1514. height: 40px;
  1515. background: #fff;
  1516. z-index: 222;
  1517. }
  1518. em {
  1519. font-style: normal;
  1520. }
  1521. .timeList em {
  1522. width: 100%;
  1523. overflow: hidden;
  1524. display: block;
  1525. margin: 0 auto;
  1526. font-size: 14px;
  1527. text-align: center;
  1528. }
  1529. .timeList span {
  1530. width: 100%;
  1531. overflow: hidden;
  1532. display: block;
  1533. margin: 0 auto;
  1534. font-size: 12px;
  1535. text-align: center;
  1536. }
  1537. .timeList li.active {
  1538. border: 1px solid #3799FF;
  1539. border-bottom: 0;
  1540. }
  1541. .timeList li.active em {
  1542. color: #3799FF;
  1543. }
  1544. .timeList li.active span {
  1545. color: #3799FF;
  1546. }
  1547. .panel_control /deep/ .el-input {
  1548. max-width: 140px;
  1549. float: left;
  1550. }
  1551. .panel-body em {
  1552. float: left;
  1553. line-height: 40px;
  1554. margin-right: 10px;
  1555. }
  1556. .gary {
  1557. border: 1px solid #ccc;
  1558. border-bottom: 0;
  1559. color: #ccc;
  1560. }
  1561. .pull-right {
  1562. float: right;
  1563. }
  1564. .lessons {
  1565. padding: 1px 7px;
  1566. border-radius: 250px;
  1567. float: left;
  1568. color: #000;
  1569. }
  1570. /deep/ .el-progress__text {
  1571. position: relative;
  1572. top: 1px;
  1573. float: right;
  1574. line-height: 14px;
  1575. height: 16px;
  1576. }
  1577. /deep/ .el-progress-bar {
  1578. width: 190px;
  1579. float: left;
  1580. overflow: hidden;
  1581. margin-top: 5px;
  1582. }
  1583. .timeList li.active {
  1584. color: #fff;
  1585. background: #409EFF;
  1586. }
  1587. .timeList li.active span, .timeList li.active em {
  1588. color: #fff;
  1589. }
  1590. .acrossAddBtn {
  1591. margin-right: 10px;
  1592. }
  1593. /*ipad only*/
  1594. @media only screen and (max-width: 1366px) {
  1595. .panel-body em {
  1596. font-size: 12px;
  1597. }
  1598. .timeList {
  1599. width: 510px;
  1600. }
  1601. .timeList li {
  1602. width: 60px;
  1603. font-size: 12px;
  1604. }
  1605. .timeList em {
  1606. font-size: 12px;
  1607. }
  1608. .timeList span {
  1609. font-size: 12px;
  1610. }
  1611. .panel_control /deep/ .el-input {
  1612. width: 130px;
  1613. }
  1614. /deep/ .el-button--warning {
  1615. margin-bottom: 5px;
  1616. }
  1617. .acrossAddBtn {
  1618. margin-right: 0;
  1619. }
  1620. }
  1621. </style>