instrumentModel.vue 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191
  1. <template>
  2. <div class="instrumentModel">
  3. <h2 class="titles" v-if="instrumentResultList.length > 0">
  4. <img :src="trainSmallBg" />
  5. <span>乐器</span>
  6. </h2>
  7. <div class="section" v-if="instrumentResultList.length > 0">
  8. <div v-for="(i, index) in instrumentResultList" :key="index">
  9. <el-row class="title-row">
  10. <el-col
  11. :span="i[0]['kitType'] == 'LEASE' || isShowSalePrice ? 14 : 19"
  12. >
  13. <template v-if="i[0]['kitType'] == 'GROUP'">
  14. 团购乐器
  15. </template>
  16. <template v-if="i[0]['kitType'] == 'LEASE'">
  17. 乐器租赁
  18. </template>
  19. <template v-if="i[0]['kitType'] == 'FREE'">
  20. 免费乐器
  21. </template>
  22. <template v-if="i[0]['kitType'] == 'owned'">
  23. 自备乐器
  24. </template>
  25. </el-col>
  26. <el-col :span="5" style="text-align: right;">
  27. <template
  28. v-if="['GROUP', 'LEASE', 'FREE'].includes(i[0]['kitType'])"
  29. >原价</template
  30. >
  31. <!-- <template v-if="i[0]['kitType'] == 'LEASE'">原价</template> -->
  32. </el-col>
  33. <el-col
  34. :span="5"
  35. style="text-align: right;"
  36. v-if="
  37. ['GROUP', 'FREE'].includes(i[0]['kitType']) && isShowSalePrice
  38. "
  39. >
  40. 售价
  41. </el-col>
  42. <el-col
  43. :span="5"
  44. style="text-align: right;"
  45. v-if="i[0]['kitType'] == 'LEASE'"
  46. >租赁押金
  47. </el-col>
  48. </el-row>
  49. <div v-for="(con, index) in i" :key="index">
  50. <div @click="instrumentF(con)">
  51. <el-row class="option-row">
  52. <el-col
  53. :span="con.kitType == 'LEASE' || isShowSalePrice ? 14 : 19"
  54. >
  55. <i
  56. class="check_default"
  57. :class="[con.isStatus ? 'check_active' : '']"
  58. ></i>
  59. <div>
  60. {{ con.name }}
  61. </div>
  62. </el-col>
  63. <el-col :span="5">
  64. <del
  65. style="color: #808080; font-size: 12px;"
  66. v-if="con.kitType != 'owned'"
  67. >¥{{ con.marketPrice | moneyFormat }}</del
  68. >
  69. </el-col>
  70. <el-col
  71. :span="5"
  72. v-if="
  73. ['FREE', 'GROUP'].includes(con.kitType) && isShowSalePrice
  74. "
  75. >
  76. <span style="color: #1A1A1A" v-if="con.kitType == 'FREE'"
  77. >¥{{ 0 | moneyFormat }}</span
  78. >
  79. <!-- 乐器现价 = 乐器现价 + 分部分润金额 -->
  80. <span style="color: #1A1A1A" v-if="con.kitType == 'GROUP'"
  81. >¥{{
  82. (courseViewType == 2 && organId == 55 && !toolsPackages ? Number(
  83. (con.discountPrice - con.coupon + con.organShareProfit).toFixed(2)
  84. ) : Number(
  85. (con.price - con.coupon + con.organShareProfit).toFixed(2)
  86. ))
  87. | moneyFormat
  88. }}</span
  89. >
  90. </el-col>
  91. <el-col :span="5" v-if="con.kitType == 'LEASE'">
  92. <span style="color: #1A1A1A"
  93. >¥{{
  94. Number((con.depositFee - con.coupon).toFixed(2))
  95. | moneyFormat
  96. }}</span
  97. >
  98. </el-col>
  99. </el-row>
  100. <el-row style="padding-left: 26px; margin-bottom: 5px;">
  101. <el-col :span="24">
  102. <div style="display: flex;align-items: center;">
  103. <div
  104. v-if="con.goodsList"
  105. style="font-size: 12px; color: #808080"
  106. >
  107. {{ con.goodsList[0].specification }}
  108. </div>
  109. <el-tag
  110. effect="plain"
  111. size="mini"
  112. style="margin-left: 10px; color: #ff4644;border-color: #ff4644;"
  113. @click.stop="onLookRule"
  114. v-if="
  115. con.groupRemissionCourseFee == 1 && con.kitType == 'GROUP'
  116. "
  117. >课程减免</el-tag
  118. >
  119. </div>
  120. </el-col>
  121. </el-row>
  122. <!-- <el-row
  123. style="padding: 8px 0 8px 24px; border-top: 1px solid #F0F0F0;"
  124. v-if="con.childGoodsNames && con.kitType == 'GROUP'"
  125. >
  126. <el-col :span="24" style="font-size: 14px; color: #1A1A1A"
  127. >赠送辅件</el-col
  128. >
  129. <el-col>
  130. <span style="font-size: 12px; color: #808080;">{{
  131. con.childGoodsNames
  132. }}</span>
  133. </el-col>
  134. </el-row> -->
  135. </div>
  136. </div>
  137. </div>
  138. </div>
  139. </div>
  140. </template>
  141. <script>
  142. export default {
  143. name: "instrumentModel",
  144. props: {
  145. courseViewType: [Number, String],
  146. instrumentResultList: Array,
  147. buyMaintenance: Boolean,
  148. trainSmallBg: String,
  149. toolsPackage: Array,
  150. organId: [Number, String, null],
  151. isShowSalePrice: Boolean
  152. },
  153. methods: {
  154. // onLeBao() {
  155. // this.$emit('onLeBao')
  156. // },
  157. instrumentF(item) {
  158. this.$emit("instrumentF", item, "INSTRUMENT");
  159. },
  160. onQuestions(item) {
  161. this.$emit("onQuestions", item);
  162. }
  163. },
  164. computed: {
  165. toolsPackages() {
  166. let status = false
  167. this.toolsPackage.forEach(item => {
  168. if(item.isStatus) {
  169. status = true
  170. }
  171. })
  172. return status
  173. },
  174. }
  175. };
  176. </script>
  177. <style lang="less" scoped>
  178. @import url("./signUpPayment.less");
  179. .icon_courseFee {
  180. margin-left: 9px;
  181. display: inline-block;
  182. width: 17px;
  183. height: 15px;
  184. background: url("../../../assets/images/musicGroup/icon_courseFee.png");
  185. background-size: 100%;
  186. }
  187. </style>