StaffList.vue 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716
  1. <template>
  2. <div class="seek">
  3. <div class="com-mobile-header mobile-center-header">
  4. <a @click="goLastPage"><i class="iconfont icon-fanhui"></i></a>
  5. <p>员工管理</p>
  6. <p class="en-name"><img :src="`/images/mobile/center/${user.data.enterprise.uu ? 'en' : 'self'}.png`" alt="">{{currentEnName}}</p>
  7. </div>
  8. <!--列表-->
  9. <div class="mobile-fix-content mobile-centerfix-content" id="mobile-staff-center">
  10. <!--列表-->
  11. <div v-if="activeTab == 0">
  12. <div class="staff-head">
  13. <span class="inline-block" :class="{'active': switchType === 'info'}" @click="setSwitchType('info')">员工信息</span>
  14. <span v-show="isAdmin" class="inline-block" :class="{'active': switchType === 'Audit'}" @click="setSwitchType('Audit')">审核绑定</span>
  15. </div>
  16. <div class="staff-record" v-if="switchType === 'info'">
  17. <div class="search-content clearfix">
  18. <div class="search">
  19. <input type="text" placeholder="人员姓名、电话号码、邮箱或UU" v-model="staffSearch" class="staff-search" @keyup.13="staffRecord()">
  20. <span @click="staffRecord()"><i class="iconfont icon-sousuo"></i></span>
  21. </div>
  22. <div class="search-filter">
  23. <div class="select-wrap" @click="showRoleEvent($event)"><strong v-text="role"></strong><i class="iconfont icon-arrow-down"></i></div>
  24. <ul class="select-list" v-if="showRole">
  25. <li @click="rolesEvent()">全部角色</li>
  26. <li v-for="item in rolesList" v-text="item.desc" @click="rolesEvent(item)">全部角色</li>
  27. </ul>
  28. </div>
  29. </div>
  30. <div class="list-content" v-if="staffDataList && staffDataList.length">
  31. <div class="bg" v-for="item in staffDataList">
  32. <div class="staff-list">
  33. <div class="list-item"><span>UU账号:</span><span v-text="item.userUU">100000721</span></div>
  34. <div class="list-item"><span>姓名:</span><span v-text="item.userName">张洪别</span></div>
  35. <div class="list-item"><span>性别:</span><span v-text="item.userSex === 'F' ? '女' : item.userSex === 'M' ? '男' : '-'">男</span></div>
  36. <div class="list-item"><span>手机号:</span><span v-text="item.userTel">12345678901</span></div>
  37. <div class="list-item"><span>邮箱:</span><span v-text="item.userEmail">12345678901</span></div>
  38. <div class="list-item"><span>角色:</span><span class="role" v-for="role in item.roles" v-text="role.desc ? role.desc.slice(0,2) : ''" v-bind:class="'bg' + role.color">普通</span></div>
  39. </div>
  40. <div class="list-footer">
  41. <div @click="goEdit(item)" class="edit handle" v-bind:class="{'no-allow': (item.userUU === userInfo.userUU)}"><i class="iconfont icon-edit"></i><span>编辑</span></div>
  42. <div @click="openDelete(item)" class="delete handle" v-bind:class="{'no-allow': (item.userUU === userInfo.userUU)}"><i class="iconfont icon-lajitong"></i><span>删除</span></div>
  43. </div>
  44. </div>
  45. </div>
  46. <empty-status :type="'collect'" :showLink="true" :text="'抱歉,没有相关信息'" v-else></empty-status>
  47. <pull-up :fixId="'mobile-staff-center'" :isValid="isValid" :searchMore="fetching" :allPage="allPage" :page="page" @pullUpAction="onPullUpAction"></pull-up>
  48. <nuxt-link class="staff-add" :to="'/mobile/user/staff/add'"><i class="iconfont icon-add"></i>新增用户</nuxt-link>
  49. </div>
  50. <div class="staff-record" v-if="switchType === 'Audit'">
  51. <div class="search-content">
  52. <input type="text" placeholder="人员姓名、电话号码、邮箱或UU" v-model="auditSearch" @keyup.13="auditRecord()">
  53. <span @click="auditRecord()"><i class="iconfont icon-sousuo"></i></span>
  54. </div>
  55. <div class="list-content" v-if="AuditList && AuditList.length">
  56. <div class="bg" v-for="item in AuditList">
  57. <div class="staff-list">
  58. <div class="list-item"><span>用户名:</span><span v-text="item.user.vipName"></span></div>
  59. <div class="list-item"><span>UU账号:</span><span v-text="item.user.userUU">100000721</span></div>
  60. <div class="list-item"><span>手机号:</span><span v-text="item.user.mobile">12345678901</span></div>
  61. <div class="list-item"><span>邮箱:</span><span v-text="item.user.email">12345678901</span></div>
  62. </div>
  63. <div class="list-footer">
  64. <div class="edit handle" @click="agreeEvent(item, '1')"><i class="iconfont icon-check-circle"></i><span>同意</span></div>
  65. <div class="handle delete" @click="agreeEvent(item, '0')"><i class="iconfont icon-close-circle"></i><span>拒绝</span></div>
  66. </div>
  67. </div>
  68. </div>
  69. <empty-status :type="'collect'" :showLink="true" :text="'抱歉,没有相关信息'" v-else></empty-status>
  70. <pull-up :fixId="'mobile-staff-center'" :searchMore="fetch" :allPage="allPageAudit" :page="page" @pullUpAction="onPullUpAudit"></pull-up>
  71. </div>
  72. </div>
  73. <!--编辑角色-->
  74. <div v-if="activeTab == 1">
  75. <div v-for="(role, index) in rolesList">
  76. <div class="staff-role">
  77. <div class="staff-header"><span :class="'active_0' + role.color"><b></b>{{role.desc}}</span></div>
  78. <div class="staff-content">
  79. <label class="radio-label clearfix" >
  80. <input type="checkbox" :id="role.id" :checked="role.checked" @change="checkRole(role, index)"/>
  81. <label :for="role.id" v-bind:class="{'margin0': role.color === '4' || role.color === '2'}"></label>
  82. <p class="staff-des">{{role.duty}}</p>
  83. </label>
  84. </div>
  85. </div>
  86. </div>
  87. <div class="staff-footer" v-if="rolesList || rolesList.length > 0">
  88. <div class="cancel handle" @click="cancelBind">取消</div>
  89. <div class="agree handle" @click="sureEdit">确定</div>
  90. </div>
  91. </div>
  92. <pull-up :fixId="'mobile-staff-center'" :isValid="isValid" :searchMore="fetching" :allPage="allPage" :page="page" @pullUpAction="onPullUpAction"></pull-up>
  93. <remind-box :title="remindText" :timeoutCount="timeoutCount"></remind-box>
  94. </div>
  95. <!--删除员工-->
  96. <div class="deleteKuang" v-if="showDelete">
  97. <div class="kuangContent">
  98. <div class="title">温馨提示</div>
  99. <div class="titleinfo">确定删除该用户吗?</div>
  100. <div class="K_btn">
  101. <div class="cancelBtn" @click="showDelete = false">取消</div>
  102. <div class="answerBtn" @click="sureDelete()">确定</div>
  103. </div>
  104. </div>
  105. </div>
  106. <remind-box :title="remindText" :timeoutCount="timeoutCount"></remind-box>
  107. </div>
  108. </template>
  109. <script>
  110. import { RemindBox, PullUp, EmptyStatus } from '~components/mobile/common'
  111. import { BaseFilter } from '~components/mobile/base'
  112. export default {
  113. layout: 'mobile',
  114. data () {
  115. return {
  116. remindText: '',
  117. timeoutCount: 0,
  118. page: 1,
  119. count: 10,
  120. staffSearch: '',
  121. staffDataList: [],
  122. auditSearch: '',
  123. AuditList: [],
  124. isChange: false,
  125. hasChange: false,
  126. switchType: 'info',
  127. showDelete: false,
  128. currentObject: '',
  129. activeTab: 0,
  130. checked: false,
  131. rolesList: [],
  132. currentStaff: [],
  133. isValid: true,
  134. role: '全部角色',
  135. showRole: false
  136. }
  137. },
  138. components: {
  139. RemindBox,
  140. PullUp,
  141. EmptyStatus,
  142. BaseFilter
  143. },
  144. mounted () {
  145. // 获取角色
  146. this.$nextTick(() => {
  147. this.getRoles()
  148. })
  149. let _this = this
  150. _this.$nextTick(function () {
  151. window.addEventListener('scroll', function () {
  152. _this.scroll()
  153. }, false)
  154. document.body.onclick = () => {
  155. this.showRole = false
  156. }
  157. })
  158. },
  159. watch: {
  160. 'staffData': {
  161. handler: function (val) {
  162. if (this.isChange) {
  163. this.staffDataList = val.content
  164. this.isChange = false
  165. } else {
  166. this.staffDataList = [...this.staffDataList, ...val.content]
  167. }
  168. },
  169. immediate: true
  170. },
  171. 'auditBind': {
  172. handler: function (val) {
  173. if (this.hasChange) {
  174. this.AuditList = val.content
  175. this.hasChange = false
  176. } else {
  177. this.AuditList = [...this.AuditList, ...val.content]
  178. }
  179. }
  180. }
  181. },
  182. mounted () {
  183. // 获取角色
  184. this.$nextTick(() => {
  185. this.getRoles()
  186. })
  187. },
  188. computed: {
  189. staffData () {
  190. return this.$store.state.staff.infoList.info.data
  191. },
  192. fetching () {
  193. return this.staffData.fetching
  194. },
  195. allPage () {
  196. return Math.floor(this.staffData.totalElements / this.staffData.size) + Math.floor(this.staffData.totalElements % this.staffData.size > 0 ? 1 : 0)
  197. },
  198. auditBind () {
  199. return this.$store.state.staff.infoList.audit.data || {content:[]}
  200. },
  201. fetch () {
  202. return this.$store.state.staff.infoList.audit.fetching
  203. },
  204. allPageAudit () {
  205. return Math.floor(this.auditBind.totalElements / this.auditBind.size) + Math.floor(this.auditBind.totalElements % this.auditBind.size > 0 ? 1 : 0)
  206. },
  207. userInfo () {
  208. return this.$store.state.option.user.data
  209. }
  210. },
  211. methods: {
  212. onRemind: function (str) {
  213. this.remindText = str
  214. this.timeoutCount++
  215. },
  216. setSwitchType (type) {
  217. this.switchType = type
  218. this.page = 1
  219. if ( type === 'info') {
  220. this.staffRecord()
  221. } else {
  222. this.auditRecord()
  223. }
  224. },
  225. staffList () {
  226. this.$store.dispatch('staff/loadStaffList', {count: this.count, page: this.page, enuu: this.userInfo.enterprise.uu})
  227. },
  228. onPullUpAction: function () {
  229. this.page++
  230. this.staffList()
  231. this.isValid = true
  232. },
  233. // 员工搜索
  234. staffRecord () {
  235. this.role = '全部角色'
  236. this.showRole = false
  237. this.$store.dispatch('staff/loadStaffList', {count: this.count, page: this.page, enuu: this.user.data.enterprise.uu, keyword: this.staffSearch})
  238. },
  239. // 删除员工
  240. openDelete (item) {
  241. this.currentObject = item
  242. this.showDelete = true
  243. },
  244. // 确认删除
  245. sureDelete () {
  246. this.$http.delete('/basic/user/' + this.currentObject.userUU)
  247. .then(response => {
  248. // console.log(response)
  249. this.showDelete = false
  250. this.onRemind('用户' + this.currentObject.userUU + '删除成功')
  251. this.page = 1
  252. this.isChange = true
  253. this.staffList()
  254. }).catch(data => {
  255. this.showDelete = false
  256. this.onRemind(data.response.data)
  257. })
  258. },
  259. // 打开选择
  260. showRoleEvent (e) {
  261. if (e) {
  262. e.stopPropagation()
  263. }
  264. this.showRole = !this.showRole
  265. },
  266. // 选择性搜索
  267. rolesEvent (type) {
  268. this.showRole = !this.showRole
  269. this.page = 1
  270. if (type) {
  271. this.role = type.desc
  272. let params = {
  273. count: this.count,
  274. page: this.page,
  275. enuu: this.user.data.enterprise.uu,
  276. keyword: this.staffSearch,
  277. roleId: type.id
  278. }
  279. this.$store.commit('infoList/REQUEST_INFO_LIST')
  280. this.$http.get('/basic/user/enterprise/keywordinfo', {params})
  281. .then(response => {
  282. this.$store.commit('staff/infoList/GET_INFO_LIST_SUCCESS', response.data ? response.data : {})
  283. }, err => {
  284. this.$store.commit('staff/infoList/GET_INFO_LIST_FAILURE', err)
  285. })
  286. } else {
  287. this.role = '全部角色'
  288. this.staffRecord()
  289. }
  290. },
  291. // 获取角色
  292. getRoles () {
  293. this.isValid = false
  294. this.$http.get('/account/role')
  295. .then(response => {
  296. if (response.data) {
  297. this.rolesList = response.data
  298. }
  299. })
  300. },
  301. // 当前选中对象
  302. goEdit (item) {
  303. let currentData = item
  304. this.currentStaff = this.baseUtils.deepCopy(currentData)
  305. this.activeTab = 1
  306. for (let i = 0; i < this.currentStaff.roles.length; i++) {
  307. for (let j = 0; j < this.rolesList.length; j++) {
  308. //判断已绑定角色
  309. if (this.currentStaff.roles[i].id === this.rolesList[j].id) {
  310. this.rolesList[j].checked = true
  311. }
  312. }
  313. }
  314. },
  315. // 选择角色
  316. checkRole (role) {
  317. role.checked = !role.checked
  318. },
  319. // 取消编辑
  320. cancelBind () {
  321. this.activeTab = 0
  322. },
  323. // 确定编辑
  324. sureEdit () {
  325. this.currentStaff.roles = []
  326. for (var i = 0 ; i< this.rolesList.length; i++) {
  327. if (this.rolesList[i].checked) {
  328. this.currentStaff.roles.push(this.rolesList[i])
  329. }
  330. }
  331. this.$http.put(`/basic/user/updaterole`, this.currentStaff)
  332. .then(() => {
  333. this.onRemind('角色编辑成功')
  334. this.activeTab = 0
  335. this.page = 1
  336. this.isChange = true
  337. this.staffList()
  338. })
  339. },
  340. // 申请绑定搜索
  341. auditRecord () {
  342. this.$store.dispatch('staff/loadBindAudit', {count: this.count, page: this.page, speaceUU: this.user.data.enterprise.uu, status: 311, keyword: this.auditSearch})
  343. },
  344. // 绑定下拉
  345. onPullUpAudit () {
  346. this.page++
  347. this.auditRecord()
  348. },
  349. // 申请绑定操作事件 (同意和拒绝)
  350. agreeEvent (type, flag) {
  351. this.$http.get(`/basic/enterprise/auditApply?id=${type.id}&status=${Number(flag)}&userUU=${type.userUU}`)
  352. this.auditSearch = null
  353. this.page = 1
  354. this.auditRecord()
  355. }
  356. }
  357. }
  358. </script>
  359. <style lang="scss">
  360. $base-color: #3f84f6;
  361. #mobile-staff-center {
  362. padding-bottom: .5rem;
  363. margin: 0 auto;
  364. .staff-head {
  365. height: .82rem;
  366. line-height: .82rem;
  367. text-align: center;
  368. background: #fff;
  369. span {
  370. font-size: .29rem;
  371. &:first-child {
  372. margin-right: 2.6rem;
  373. }
  374. &.active {
  375. color: $base-color;
  376. border-bottom: 1px solid $base-color;
  377. }
  378. }
  379. }
  380. .staff-record {
  381. .search-content {
  382. padding: .25rem 0;
  383. text-align: center;
  384. input {
  385. width: 6.9rem;
  386. border: 1px solid #376ff3;
  387. }
  388. .staff-search {
  389. width: 5.31rem;
  390. }
  391. .search {
  392. float: left;
  393. }
  394. .search-filter {
  395. float: left;
  396. margin-left: .35rem;
  397. position: relative;
  398. .select-wrap {
  399. width: 1.45rem;
  400. height: .58rem;
  401. line-height: .58rem;
  402. background-color: #ffffff;
  403. border-radius: .06rem;
  404. border: solid 1px #b4b4b4;
  405. strong{
  406. font-weight: normal;
  407. }
  408. i{
  409. float:right;
  410. display:inline-block;
  411. font-size: .1rem;
  412. font-weight: bold;
  413. color: $base-color;
  414. }
  415. }
  416. ul.select-list{
  417. width: 1.45rem;
  418. position: absolute;
  419. left: 0rem;
  420. top: .59rem;
  421. border: solid 1px #b4b4b4;
  422. border-top: none;
  423. -webkit-box-shadow: 0 1px 5px 0 #aaa;
  424. box-shadow: 0 1px 5px 0 #aaa;
  425. border-radius: .04rem;
  426. li{
  427. background: #fff;
  428. text-align: left;
  429. padding: 0 .13rem;
  430. font-size: .28rem;
  431. height: .53rem;
  432. line-height: .53rem;
  433. }
  434. }
  435. }
  436. }
  437. .list-content{
  438. margin: 0 auto;
  439. padding: 0 .20rem;
  440. margin-bottom:1.2rem;
  441. div.bg{
  442. padding: .32rem .24rem 0 .24rem;
  443. margin-bottom: .25rem;
  444. width: 7.1rem;
  445. background: #fff;
  446. border-radius: .05rem;
  447. &:last-child {
  448. margin-bottom: 1.5rem;
  449. }
  450. }
  451. .staff-list {
  452. width: 100%;
  453. .list-item {
  454. margin-bottom: .14rem;
  455. &:last-child{
  456. padding-bottom: 0;
  457. }
  458. span {
  459. display: inline-block;
  460. font-size: .28rem;
  461. &:first-child {
  462. width: 1.3rem;
  463. text-align: right;
  464. color: #3f84f6;
  465. }
  466. &:last-child {
  467. color: #666;
  468. }
  469. }
  470. span.role{
  471. display: inline-block;
  472. margin-right: .1rem;
  473. padding: 0 .05rem;
  474. height: .25rem;
  475. line-height: .25rem;
  476. text-align: center;
  477. font-size: .24rem;
  478. color: #fff;
  479. border-radius: .04rem;
  480. }
  481. span.role.bg1{
  482. background-color: #89aefa;
  483. }
  484. span.role.bg2{
  485. background-color: #01d9ce;
  486. }
  487. span.role.bg3{
  488. background-color: #01d9ce;
  489. }
  490. span.role.bg4{
  491. background-color: #ff6769;
  492. }
  493. span.role.bg5{
  494. background-color: #ff8050;
  495. }
  496. }
  497. }
  498. .list-footer {
  499. width: 100%;
  500. height: .8rem;
  501. line-height: .8rem;
  502. background: #fff;
  503. border-top: 1px solid #d9d9d9;
  504. div.handle{
  505. float: left;
  506. width: 50%;
  507. margin: 0 auto;
  508. text-align: center;
  509. span{
  510. font-size: .26rem;
  511. color: #333;
  512. }
  513. i.iconfont {
  514. margin-right: .06rem;
  515. font-size: .36rem;
  516. color: #333;
  517. }
  518. }
  519. div.edit{
  520. border-right: 1px solid #d9d9d9;
  521. }
  522. div.no-allow {
  523. color: #606168;
  524. cursor: not-allowed;
  525. }
  526. }
  527. }
  528. .staff-add {
  529. display: inline-block;
  530. position: fixed;
  531. bottom: 1.2rem;
  532. left: 50%;
  533. margin-left: -3.29rem;
  534. width: 6.59rem;
  535. height: .77rem;
  536. line-height: .77rem;
  537. text-align: center;
  538. font-size: .32rem;
  539. color: #fff;
  540. background-color: #3f84f6;
  541. border-radius: 0.08rem;
  542. i{
  543. margin-right: .1rem;
  544. font-size: .32rem;
  545. color: #fff;
  546. }
  547. }
  548. }
  549. /*编辑角色*/
  550. .staff-role{
  551. margin: .2rem auto 0;
  552. padding: 0 .24rem;
  553. width: 7.1rem;
  554. height: 1.72rem;
  555. background-color: #fff;
  556. border-radius: .05rem;
  557. .staff-header {
  558. height: .5rem;
  559. line-height: .5rem;
  560. text-align: left;
  561. border-bottom: 1px solid #d9d9d9;
  562. span {
  563. font-size: .28rem;
  564. color: #333;
  565. b{
  566. display: inline-block;
  567. margin-right: .05rem;
  568. width: .05rem;
  569. height: .18rem;
  570. background-color: #3f84f6;
  571. }
  572. }
  573. span.active_02 b{
  574. background-color: #8aaefc;
  575. }
  576. span.active_03 b{
  577. background-color: #09d7cd;
  578. }
  579. span.active_04 b{
  580. background-color: #ff676a;
  581. }
  582. span.active_05 b{
  583. background-color: #fc9b68;
  584. }
  585. }
  586. .staff-content {
  587. padding-top: .25rem;
  588. .radio-label {
  589. background-size: contain;
  590. vertical-align: middle;
  591. input{
  592. float: left;
  593. display: none;
  594. margin: .18rem .1rem 0 0;
  595. width: .36rem;
  596. height: .36rem;
  597. border: solid 2px #999999;
  598. }
  599. label {
  600. float: left;
  601. margin: .18rem .1rem 0 0;
  602. width: .36rem;
  603. height: .36rem;
  604. border-radius: 50%;
  605. background: url(/images/mobile/center/user/car-noChecked.png) no-repeat;
  606. background-size: contain;
  607. vertical-align: middle;
  608. }
  609. label.margin0 {
  610. margin: 0.05rem .1rem 0 0;
  611. }
  612. input:checked + label {
  613. background-image: url(/images/mobile/center/user/car-checked.png);
  614. }
  615. input.checked + label {
  616. background-image: url(/images/mobile/center/user/car-checked.png);
  617. }
  618. }
  619. .staff-des{
  620. float: left;
  621. width: 6rem;
  622. line-height: .42rem;
  623. font-weight: normal;
  624. font-size: .28rem;
  625. color: #666666;
  626. }
  627. }
  628. }
  629. .staff-footer{
  630. overflow: hidden;
  631. margin-top: .6rem;
  632. div.handle{
  633. float: left;
  634. width: 3.24rem;
  635. height: .77rem;
  636. line-height: .77rem;
  637. font-size: .32rem;
  638. color: #fff;
  639. text-align: center;
  640. border-radius: .08rem;
  641. &:first-child{
  642. margin: 0 .28rem 0 .35rem;
  643. background-color: #acaaab;
  644. }
  645. &:last-child{
  646. background-color: #3f84f6;
  647. }
  648. }
  649. }
  650. }
  651. /*删除弹框*/
  652. .deleteKuang {
  653. position: fixed;
  654. background: rgba(0,0,0,0.5);
  655. top: 0;
  656. left: 0;
  657. right: 0;
  658. bottom: 0;
  659. z-index: 9999;
  660. .kuangContent {
  661. border-radius: 5px;
  662. background: #fff;
  663. width: 5rem;
  664. position: absolute;
  665. left: 50%;
  666. top: 50%;
  667. transform: translate3d(-50%, -50%, 0);
  668. overflow: hidden;
  669. .titleinfo {
  670. font-size: .3rem;
  671. color: #666;
  672. text-align: center;
  673. margin-top: 0.5rem;
  674. margin-bottom: 0.1rem;
  675. }
  676. .title {
  677. background: #5078cb;
  678. height: .7rem;
  679. line-height: .7rem;
  680. font-size: .3rem;
  681. color: #fff;
  682. text-align: center;
  683. }
  684. .info {
  685. color: #f00;
  686. text-align: center;
  687. }
  688. .K_btn {
  689. margin-top: 0.4rem;
  690. line-height: 0.7rem;
  691. height: 0.7rem;
  692. &::after{
  693. clear: both;
  694. display: block;
  695. content: ' ';
  696. visibility: hidden;
  697. zoom: 1;
  698. }
  699. div {
  700. float: left;
  701. width: 50%;
  702. font-size: 0.3rem;
  703. text-align: center;
  704. &.cancelBtn {
  705. background: #b4b5b9;
  706. color: #333;
  707. }
  708. &.answerBtn {
  709. background: #5078cb;
  710. color: #fff;
  711. }
  712. }
  713. }
  714. }
  715. }
  716. </style>