vipActiveList.vue 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749
  1. <template >
  2. <div class="m-container">
  3. <h2>
  4. <div class="squrt"></div>vip活动方案
  5. </h2>
  6. <div class="m-core">
  7. <div class="newBand"
  8. @click='gotoNewActive'>新建</div>
  9. <el-form :inline="true"
  10. class="searchForm"
  11. v-model="searchForm">
  12. <el-form-item prop='organId'>
  13. <el-select class='multiple'
  14. style="width:180px!important"
  15. v-model="searchForm.organId"
  16. clearable
  17. placeholder="请选择分部">
  18. <el-option v-for="(item,index) in organList"
  19. :key="index"
  20. :label="item.name"
  21. :value="item.id"></el-option>
  22. </el-select>
  23. </el-form-item>
  24. <el-form-item>
  25. <el-button @click="search"
  26. type="danger">搜索</el-button>
  27. </el-form-item>
  28. </el-form>
  29. <div class="tableWrap">
  30. <el-table :data='tableList'
  31. :header-cell-style="{background:'#EDEEF0',color:'#444'}">
  32. <el-table-column align='center'
  33. prop="id"
  34. label="活动编号">
  35. </el-table-column>
  36. <el-table-column align='center'
  37. prop="name"
  38. label="活动名称">
  39. </el-table-column>
  40. <el-table-column align='center'
  41. prop="vipGroupCategoryNames"
  42. label="适用课程形式">
  43. </el-table-column>
  44. <el-table-column align='center'
  45. prop="type"
  46. :formatter="fommatterType"
  47. label="活动类型">
  48. </el-table-column>
  49. <el-table-column align='center'
  50. label="适用课时类型"
  51. :formatter="fommatterCourseType">
  52. </el-table-column>
  53. <el-table-column align='center'
  54. label="结算标准">
  55. <template slot-scope="scope">
  56. <div>
  57. <p>{{ scope.row.salarySettlementJson | onlinePip }}</p>
  58. <p>{{ scope.row.salarySettlementJson | unonlinePip }}</p>
  59. </div>
  60. </template>
  61. </el-table-column>
  62. <el-table-column align='center'
  63. label="结算说明">
  64. <template slot-scope="scope">
  65. <div>
  66. <p>{{ scope.row.salarySettlementJson | onlineDesc }}</p>
  67. <p>{{ scope.row.salarySettlementJson | unonlineDesc }}</p>
  68. </div>
  69. </template>
  70. </el-table-column>
  71. <el-table-column align='center'
  72. label="启用状态"
  73. prop='enable'
  74. :formatter="fommatterEnable">
  75. </el-table-column>
  76. <el-table-column align='center'
  77. width="130px"
  78. label="活动持续时间">
  79. <template slot-scope="scope">
  80. <div>
  81. <p>{{ scope.row.startTime | formatTimer }}</p>
  82. <p>{{ scope.row.endTime | formatTimer }}</p>
  83. </div>
  84. </template>
  85. </el-table-column>
  86. <el-table-column align='center'
  87. width="130px"
  88. label="课程安排时间">
  89. <template slot-scope="scope">
  90. <div>
  91. <p>{{ scope.row.coursesStartTime | formatTimer }}</p>
  92. <p>{{ scope.row.coursesEndTime | formatTimer }}</p>
  93. </div>
  94. </template>
  95. </el-table-column>
  96. <el-table-column align='center'
  97. label="操作">
  98. <template slot-scope="scope">
  99. <div>
  100. <el-button type='text'
  101. @click="reset(scope.row)">修改</el-button>
  102. <!-- <el-button type='text'
  103. @click="remove(scope.row)">删除</el-button> -->
  104. <el-popover placement="top"
  105. width="160"
  106. :ref="scope.$index">
  107. <p>确定删除?</p>
  108. <div style="text-align: right; margin: 0">
  109. <el-button size="mini"
  110. type="text"
  111. @click="scope._self.$refs[scope.$index].doClose()">取消</el-button>
  112. <el-button type="primary"
  113. size="mini"
  114. @click="remove(scope)">确定</el-button>
  115. </div>
  116. <el-button type="text"
  117. slot="reference">删除</el-button>
  118. </el-popover>
  119. </div>
  120. </template>
  121. </el-table-column>
  122. </el-table>
  123. <!-- 分页器 -->
  124. <pagination :total="rules.total"
  125. :page.sync="rules.page"
  126. :limit.sync="rules.limit"
  127. :page-sizes="rules.page_size"
  128. @pagination="getList" />
  129. </div>
  130. </div>
  131. <el-dialog title='提示'
  132. width="60%"
  133. :visible.sync="dialogVisible">
  134. <div>
  135. <el-form :label-position="labelPosition"
  136. :model="resetForm"
  137. ref='vipform'
  138. :rules='resetFormRules'
  139. class="vipform">
  140. <el-form-item label="活动名称"
  141. prop="name">
  142. <el-input style="width:400px"
  143. v-model="resetForm.name"></el-input>
  144. </el-form-item>
  145. <el-form-item label="适用分部"
  146. prop="organ">
  147. <el-select v-model="resetForm.organ"
  148. multiple
  149. clearable>
  150. <el-option v-for='(item,index) in organList'
  151. :key="index"
  152. :label="item.name"
  153. :value="item.id"></el-option>
  154. </el-select>
  155. <el-button @click="onCheckAllBranch">适用所有分部</el-button>
  156. </el-form-item>
  157. <el-form-item label="活动描述"
  158. prop="desc">
  159. <el-input type="textarea"
  160. v-model="resetForm.desc"
  161. style="width:400px"
  162. :rows="5"
  163. placeholder="请输入活动说明"></el-input>
  164. </el-form-item>
  165. <el-form-item label="活动时间"
  166. prop="activeTime">
  167. <el-date-picker v-model="resetForm.activeTime"
  168. type="datetimerange"
  169. range-separator="至"
  170. value-format="yyyy-MM-dd HH:mm:ss"
  171. start-placeholder="开始日期"
  172. end-placeholder="结束日期">
  173. </el-date-picker>
  174. </el-form-item>
  175. <el-form-item label="课程时间"
  176. prop="courseTime">
  177. <el-date-picker v-model="resetForm.courseTime"
  178. type="datetimerange"
  179. range-separator="至"
  180. value-format="yyyy-MM-dd HH:mm:ss"
  181. start-placeholder="开始日期"
  182. end-placeholder="结束日期">
  183. </el-date-picker>
  184. </el-form-item>
  185. <el-form-item label="课程形式"
  186. prop="stauts">
  187. <el-select v-model="resetForm.stauts"
  188. multiple>
  189. <el-option v-for="(item,index) in courseStatusList"
  190. :key='index'
  191. :value="item.id"
  192. :label="item.name"></el-option>
  193. </el-select>
  194. </el-form-item>
  195. </el-form>
  196. <div class="activeRange">
  197. <div class="left">
  198. <p>活动适用范围&结算标准:</p>
  199. </div>
  200. <div class="right">
  201. <div class="chioseWrap">
  202. <el-checkbox label="线上课"
  203. v-model="online"></el-checkbox>
  204. <el-select v-model="onlineSalary">
  205. <el-option label="老师默认课酬"
  206. value="TEACHER_DEFAULT"></el-option>
  207. <el-option label="课程单价比例折扣"
  208. value="RATIO_DISCOUNT"></el-option>
  209. <el-option label="固定课酬"
  210. value="FIXED_SALARY"></el-option>
  211. </el-select>
  212. <el-input placeholder="请输入"
  213. style="width:100px"
  214. type="number"
  215. v-if='onlineSalary!= "TEACHER_DEFAULT"'
  216. v-model="onlineprice"></el-input>
  217. </div>
  218. <div class="chioseWrap">
  219. <el-checkbox label="线下课"
  220. v-model="unonline"></el-checkbox>
  221. <el-select v-model="unonlineSalary">
  222. <el-option label="老师默认课酬"
  223. value="TEACHER_DEFAULT"></el-option>
  224. <el-option label="课程单价比例折扣"
  225. value="RATIO_DISCOUNT"></el-option>
  226. <el-option label="固定课酬"
  227. value="FIXED_SALARY"></el-option>
  228. </el-select>
  229. <el-input placeholder="请输入"
  230. style="width:100px"
  231. v-if='unonlineSalary!= "TEACHER_DEFAULT"'
  232. type="number"
  233. v-model="unonlineprice"></el-input>
  234. </div>
  235. <div class="chioseWrap">
  236. <el-checkbox v-model="salaryReadonlyFlag"
  237. label="可自定义收费、结算标准"></el-checkbox>
  238. </div>
  239. </div>
  240. </div>
  241. <div class="activeType">
  242. <div class="left">
  243. <p style='width:60px;'>活动类型</p>
  244. </div>
  245. <div class="right">
  246. <div>
  247. <div class="head"
  248. :class="activeType=='BASE_ACTIVITY'?'active':''"
  249. @click="activeType='BASE_ACTIVITY'">基础活动</div>
  250. <p class="title"
  251. v-if="activeType=='BASE_ACTIVITY'">课程原价</p>
  252. </div>
  253. <div>
  254. <div class="head"
  255. :class="activeType=='DISCOUNT'?'active':''"
  256. @click="activeType='DISCOUNT'">折扣</div>
  257. <el-input v-if="activeType=='DISCOUNT'"
  258. v-model="attribute1"
  259. placeholder="请输入折扣数值"></el-input>
  260. </div>
  261. <div>
  262. <div class="head"
  263. :class="activeType=='GIVE_CLASS'?'active':''"
  264. @click="activeType='GIVE_CLASS'">赠送课时</div>
  265. <el-input placeholder="多少节开始赠"
  266. v-if="activeType=='GIVE_CLASS'"
  267. v-model="attribute1"
  268. style='margin-right:10px;'></el-input> <span v-if="activeType=='GIVE_CLASS'">赠</span>
  269. <el-input v-if="activeType=='GIVE_CLASS'"
  270. placeholder="请输入赠送课时数"
  271. v-model="attribute2"
  272. style='margin:0 10px;'></el-input>
  273. <el-checkbox v-if="activeType=='GIVE_CLASS'"
  274. v-model="giveClassPaySalaryFlag"
  275. label="赠送课时结算课酬"></el-checkbox>
  276. </div>
  277. </div>
  278. </div>
  279. </div>
  280. <span slot="footer"
  281. class="dialog-footer">
  282. <el-button @click="dialogVisible = false">取 消</el-button>
  283. <el-button type="primary"
  284. @click="resetRow">确 定</el-button>
  285. </span>
  286. </el-dialog>
  287. </div>
  288. </template>
  289. <script>
  290. import pagination from '@/components/Pagination/index'
  291. import { vipGroupActivity, vipGroupCategory, addVipActive, resetVipActive, removeVipActive } from "@/api/vipSeting"
  292. import { getEmployeeOrgan } from '@/api/buildTeam'
  293. export default {
  294. components: { pagination },
  295. data () {
  296. return {
  297. labelPosition: 'right',
  298. tableList: [],
  299. rules: {
  300. // 分页规则
  301. limit: 10, // 限制显示条数
  302. page: 1, // 当前页
  303. total: 0, // 总条数
  304. page_size: [10, 20, 40, 50] // 选择限制显示条数
  305. },
  306. searchForm: { organId: null },
  307. organList: [],
  308. dialogVisible: false,
  309. resetForm: {
  310. name: '',
  311. desc: '',
  312. activeTime: [],
  313. courseTime: [],
  314. stauts: [],
  315. organ: []
  316. }, // 修改信息
  317. resetFormRules: {
  318. name: [{ required: true, message: '请输入活动名称', trigger: 'blur' },
  319. { min: 1, max: 25, message: '长度在 1 到 25 个字符', trigger: 'blur' }],
  320. desc: [{ required: false, message: '请输入文字描述', trigger: 'blur' },
  321. { min: 1, max: 200, message: '长度在 1 到 200 个字符', trigger: 'blur' }],
  322. activeTime: [{ required: false, message: '请选择活动时间', trigger: 'blur' }],
  323. courseTime: [{ required: false, message: '请选择课程时间', trigger: 'blur' }],
  324. organ: [{ required: true, message: '请选择分部', trigger: 'blur' }]
  325. },
  326. courseStatusList: [],
  327. activeType: '',
  328. online: true,
  329. unonline: true,
  330. onlineSalary: 'TEACHER_DEFAULT',
  331. unonlineSalary: 'TEACHER_DEFAULT',
  332. onlineprice: '',
  333. unonlineprice: '',
  334. salaryReadonlyFlag: true,
  335. attribute1: '',
  336. attribute2: '',
  337. attribute3: '',
  338. giveClassPaySalaryFlag: false,
  339. activeId: ''
  340. }
  341. },
  342. created () {
  343. if (this.$route.query.searchForm) {
  344. this.$route.query.searchForm instanceof Object ? this.searchForm = this.$route.query.searchForm : this.searchForm = JSON.parse(this.$route.query.searchForm);
  345. }
  346. if (this.$route.query.rules) {
  347. this.$route.query.rules instanceof Object ? this.rules = this.$route.query.rules : this.rules = JSON.parse(this.$route.query.rules);
  348. }
  349. },
  350. mounted () {
  351. getEmployeeOrgan().then(res => {
  352. if (res.code == 200) {
  353. this.organList = res.data;
  354. }
  355. })
  356. this.getList();
  357. // 首先获取课程形式
  358. // 获取分部id
  359. // let organId = this.$store.getters.organ;
  360. // console.log(organId)
  361. vipGroupCategory().then(res => {
  362. // console.log(res);
  363. if (res.code == 200) {
  364. this.courseStatusList = res.data;
  365. }
  366. })
  367. },
  368. filters: {
  369. onlinePip (val) {
  370. let obj = JSON.parse(val)
  371. // debugger;
  372. if (obj && obj.onlineSalarySettlement && obj.onlineSalarySettlement.salarySettlementType) {
  373. switch (obj.onlineSalarySettlement.salarySettlementType) {
  374. case 'RATIO_DISCOUNT': {
  375. return '线上:比例结算'
  376. break
  377. }
  378. case 'TEACHER_DEFAULT': {
  379. return '线上:老师默认'
  380. break
  381. }
  382. case 'FIXED_SALARY': {
  383. return '线上:固定课酬'
  384. break
  385. }
  386. }
  387. }
  388. },
  389. unonlinePip (val) {
  390. let obj = JSON.parse(val)
  391. if (obj && obj.offlineSalarySettlement && obj.offlineSalarySettlement.salarySettlementType) {
  392. switch (obj.offlineSalarySettlement.salarySettlementType) {
  393. case 'RATIO_DISCOUNT': {
  394. return '线下:比例结算'
  395. break
  396. }
  397. case 'TEACHER_DEFAULT': {
  398. return '线下:老师默认'
  399. break
  400. }
  401. case 'FIXED_SALARY': {
  402. return '线下:固定课酬'
  403. break
  404. }
  405. }
  406. }
  407. },
  408. onlineDesc (val) {
  409. let obj = JSON.parse(val)
  410. // debugger;
  411. if (obj && obj.onlineSalarySettlement && obj.onlineSalarySettlement.salarySettlementType) {
  412. switch (obj.onlineSalarySettlement.salarySettlementType) {
  413. case 'RATIO_DISCOUNT': {
  414. return `线上:${obj.onlineSalarySettlement.settlementValue}%`
  415. break
  416. }
  417. case 'TEACHER_DEFAULT': {
  418. return '线上:默认'
  419. break
  420. }
  421. case 'FIXED_SALARY': {
  422. return `线上:${obj.onlineSalarySettlement.settlementValue}/次`
  423. break
  424. }
  425. }
  426. }
  427. },
  428. unonlineDesc (val) {
  429. let obj = JSON.parse(val)
  430. if (obj && obj.offlineSalarySettlement && obj.offlineSalarySettlement.salarySettlementType) {
  431. switch (obj.offlineSalarySettlement.salarySettlementType) {
  432. case 'RATIO_DISCOUNT': {
  433. return '线下:' + obj.offlineSalarySettlement.settlementValue + '%'
  434. break
  435. }
  436. case 'TEACHER_DEFAULT': {
  437. return '线下:默认'
  438. break
  439. }
  440. case 'FIXED_SALARY': {
  441. return '线下:' + obj.offlineSalarySettlement.settlementValue + '/次'
  442. break
  443. }
  444. }
  445. }
  446. }
  447. },
  448. methods: {
  449. onCheckAllBranch () {
  450. // 适用所有分部
  451. this.resetForm.organ = []
  452. this.organList.forEach(item => {
  453. this.resetForm.organ.push(item.id)
  454. })
  455. },
  456. search () {
  457. this.rules.page = 1;
  458. this.getList();
  459. },
  460. getList () {
  461. vipGroupActivity({
  462. organId: this.searchForm.organId,
  463. rows: this.rules.limit,
  464. page: this.rules.page }).then(res => {
  465. if (res.code == 200) {
  466. this.tableList = res.data.rows
  467. this.rules.total = res.data.total
  468. }
  469. })
  470. },
  471. // 格式化活动类型
  472. fommatterType (row, column) {
  473. switch (row.type) {
  474. case 'BASE_ACTIVITY': {
  475. return '基础';
  476. break;
  477. }
  478. case 'DISCOUNT': {
  479. return '折扣';
  480. break;
  481. }
  482. case 'GIVE_CLASS': {
  483. if (row.giveClassPaySalaryFlag) {
  484. return '买赠(赠课结算)';
  485. } else {
  486. return '买赠(不结算)';
  487. }
  488. break;
  489. }
  490. }
  491. },
  492. // 格式化课时类型
  493. fommatterCourseType (row) {
  494. let date = JSON.parse(row.salarySettlementJson);
  495. let str = '';
  496. if (date && date.onlineSalarySettlement) {
  497. str += '线上 '
  498. }
  499. if (date && date.offlineSalarySettlement) {
  500. str += '线下'
  501. }
  502. return str
  503. },
  504. // 格式化启用状态
  505. fommatterEnable (row) {
  506. switch (row.enable) {
  507. case 0: {
  508. return '关闭'
  509. break
  510. }
  511. case 1: {
  512. return '开启'
  513. break
  514. }
  515. }
  516. },
  517. // 点击列表修改同步状态
  518. reset (row) {
  519. this.activeId = row.id;
  520. this.dialogVisible = true;
  521. this.resetForm.name = row.name;
  522. this.resetForm.desc = row.description;
  523. if (row.organId) {
  524. this.resetForm.organ = row.organId.split(',').map(res => {
  525. return parseInt(res);
  526. });
  527. }
  528. if (row.vipGroupCategoryIdList) {
  529. this.resetForm.stauts = row.vipGroupCategoryIdList.split(',').map(res => {
  530. return parseInt(res);
  531. });
  532. }
  533. // 同步活动时间
  534. if (row.startTime && row.endTime) {
  535. this.resetForm.activeTime = [row.startTime, row.endTime];
  536. }
  537. if (row.coursesStartTime && row.coursesEndTime) {
  538. this.resetForm.courseTime = [row.coursesStartTime, row.coursesEndTime];
  539. }
  540. // 同步适用范围
  541. let obj = JSON.parse(row.salarySettlementJson);
  542. // 同步线上课状态
  543. obj.onlineSalarySettlement ? this.online = true : this.online = false;
  544. if (obj.onlineSalarySettlement) {
  545. this.onlineSalary = obj.salarySettlementType;
  546. if (obj.onlineSalarySettlement.settlementValue) {
  547. this.onlineprice = obj.onlineSalarySettlement.settlementValue;
  548. }
  549. if (obj.onlineSalarySettlement.salarySettlementType)
  550. this.onlineSalary = obj.onlineSalarySettlement.salarySettlementType;
  551. }
  552. // 同步线下课状态
  553. obj.offlineSalarySettlement ? this.unonline = true : this.unonline = false;
  554. if (obj.offlineSalarySettlement) {
  555. this.unonlineSalary = obj.offlineSalarySettlement;
  556. if (obj.offlineSalarySettlement.settlementValue) {
  557. this.unonlineprice = obj.offlineSalarySettlement.settlementValue;
  558. }
  559. if (obj.offlineSalarySettlement.salarySettlementType)
  560. this.unonlineSalary = obj.offlineSalarySettlement.salarySettlementType;
  561. }
  562. //
  563. this.salaryReadonlyFlag = !!parseInt(row.salaryReadonlyFlag);
  564. this.activeType = row.type;
  565. this.attribute1 = row.attribute1;
  566. this.attribute2 = row.attribute2;
  567. this.giveClassPaySalaryFlag = row.giveClassPaySalaryFlag == 1 ? true : false;
  568. },
  569. // 点击确认按钮发送修改请求
  570. resetRow () {
  571. this.$refs['vipform'].validate((valid) => {
  572. if (valid) {
  573. // 验证通过
  574. let id = this.activeId;
  575. let coursesStartTime = this.resetForm.courseTime[0];
  576. let coursesEndTime = this.resetForm.courseTime[1];
  577. let startTime = this.resetForm.activeTime[0];
  578. let endTime = this.resetForm.activeTime[1];
  579. let organId = this.resetForm.organ.join(',');
  580. let type = this.activeType;
  581. let vipGroupCategoryIdList = this.resetForm.stauts.join(',')
  582. let onlineSalarySettlement;
  583. let offlineSalarySettlement;
  584. if (this.online) {
  585. // 勾选线上
  586. onlineSalarySettlement = {
  587. salarySettlementType: this.onlineSalary,
  588. settlementValue: this.onlineprice
  589. }
  590. } else {
  591. onlineSalarySettlement = null;
  592. }
  593. if (this.unonline) {
  594. // 勾选线下
  595. offlineSalarySettlement = {
  596. salarySettlementType: this.unonlineSalary,
  597. settlementValue: this.unonlineprice
  598. }
  599. } else {
  600. offlineSalarySettlement = null
  601. }
  602. let salaryReadonlyFlag = this.salaryReadonlyFlag * 1;
  603. let giveClassPaySalaryFlag = this.giveClassPaySalaryFlag * 1;
  604. let vipGroupSalarySettlement = {
  605. onlineSalarySettlement,
  606. offlineSalarySettlement
  607. }
  608. // 发请求创建活动
  609. resetVipActive({
  610. id,
  611. coursesStartTime,
  612. coursesEndTime,
  613. startTime,
  614. endTime,
  615. name: this.resetForm.name,
  616. description: this.resetForm.desc,
  617. organId,
  618. type,
  619. vipGroupCategoryIdList,
  620. vipGroupSalarySettlement,
  621. salaryReadonlyFlag,
  622. giveClassPaySalaryFlag,
  623. attribute1: this.attribute1,
  624. attribute2: this.attribute2,
  625. attribute3: this.attribute3
  626. }).then(res => {
  627. if (res.code == 200) {
  628. this.$message.success('恭喜你,活动修改成功')
  629. this.dialogVisible = false;
  630. this.getList();
  631. }
  632. })
  633. } else {
  634. this.$message.error('请填写必要参数')
  635. }
  636. })
  637. },
  638. remove (scope) {
  639. let id = scope.row.id;
  640. removeVipActive({ id }).then(res => {
  641. if (res.code == 200) {
  642. this.$message.success('恭喜您删除成功')
  643. this.getList();
  644. }
  645. scope._self.$refs[scope.$index].doClose()
  646. })
  647. },
  648. gotoNewActive () {
  649. // 带参数 searchForm: { organId: null } 搜索条件
  650. let rules = JSON.stringify(this.rules)
  651. let searchForm = JSON.stringify(this.searchForm)
  652. this.$router.push({ path: '/vipClassSet/vipNewActive?type=create', query: { rules, searchForm } })
  653. }
  654. },
  655. }
  656. </script>
  657. <style lang="scss" scoped>
  658. .activeType {
  659. .right {
  660. .el-input {
  661. width: 150px !important;
  662. }
  663. }
  664. }
  665. .activeRange {
  666. display: flex;
  667. flex-direction: row;
  668. justify-content: flex-start;
  669. .left {
  670. height: 72px;
  671. line-height: 72px;
  672. }
  673. .right {
  674. .chioseWrap {
  675. display: flex;
  676. flex-direction: row;
  677. justify-content: flex-start;
  678. height: 72px;
  679. line-height: 72px;
  680. align-items: center;
  681. .el-checkbox {
  682. margin-right: 20px;
  683. }
  684. .el-select {
  685. margin-right: 20px;
  686. }
  687. }
  688. }
  689. }
  690. .activeType {
  691. display: flex;
  692. flex-direction: row;
  693. justify-content: flex-start;
  694. .left {
  695. margin-right: 20px;
  696. p {
  697. height: 40px;
  698. line-height: 40px;
  699. }
  700. }
  701. .right {
  702. > div {
  703. display: flex;
  704. flex-direction: row;
  705. justify-content: flex-start;
  706. height: 40px;
  707. line-height: 40px;
  708. margin-bottom: 20px;
  709. .head {
  710. width: 120px;
  711. height: 40px;
  712. line-height: 40px;
  713. border: 1px solid #ccc;
  714. text-align: center;
  715. border-radius: 5px;
  716. cursor: pointer;
  717. margin-right: 10px;
  718. }
  719. > .head.active {
  720. background-color: #13817a;
  721. color: #fff;
  722. border: none;
  723. }
  724. .title {
  725. line-height: 40px;
  726. height: 40px;
  727. }
  728. }
  729. }
  730. }
  731. .vipform {
  732. .el-select {
  733. width: 400px !important;
  734. .el-input__inner {
  735. width: 400px;
  736. }
  737. }
  738. }
  739. </style>