node.vue 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264
  1. <template>
  2. <view class="center">
  3. <scroll-view class="box" scroll-y="true" >
  4. <view class="bg">
  5. <image src="../../static/img/rengou.png" mode=""></image>
  6. </view>
  7. <view class="rengou">
  8. 1、每份投资{{list.buy_price*1}}U,有效直推3人<br>
  9. 2、49份组成一个社区节点<br>
  10. 3、总节点合伙人1024名,每期49人,分21期招募
  11. </view>
  12. <view class="quanyi">
  13. 1、赠送1T FiL矿机1080天标准产币收益,技术服务费30% <br>
  14. 2、赠送LALA积分通证10万枚,每天1%释放。LALA上交易所前每天1%上涨,总100天<br>
  15. 3、享受LALA门票50%合伙人加权分红(扣除销毁后的门票,门票销毁按照市场情况动态调整,系数在10~50%之间)。<br>
  16. 4、享受项目总50%的股权加权分红(包括门票、手续费等)。<br>
  17. 5、享受LALA社区会员A2级别权益。<br>
  18. 6、赠送LALA NFT创世勋章一枚。
  19. </view>
  20. <view class="rule">
  21. 1、LALA NFT平台节点合伙人共分21期,即21个主节点。<br>
  22. 2、LALA节点每期认购满额后,自然开启第2期节点认购。直至21个节点认购满结束。<br>
  23. 3、个人可以一次多份参与认购,也可参与多个节点认购,每份节点认购享受的权益相同。<br>
  24. </view>
  25. <view class="jiedian">
  26. <view class="mun">
  27. {{mun}}
  28. </view>
  29. <view class="font">
  30. 认购份数
  31. </view>
  32. <view class="jdt">
  33. <u-line-progress :show-percent="false" inactive-color="#BBBBBB" active-color="#29F3FD" :percent="zuiduo"></u-line-progress>
  34. </view>
  35. <view class="yue-num">
  36. 仅剩{{ shen }}份,总共{{ all }}份
  37. </view>
  38. </view>
  39. <view class="btn" @click="buy()">
  40. 立即认购
  41. </view>
  42. </scroll-view>
  43. <u-popup v-model="show1" mode="center" width="548rpx" border-radius="14">
  44. <view class="psw-wrapper">
  45. <view class="psw-title">请输入支付密码</view>
  46. <input type="password" v-model="password" class="psw-ipt" />
  47. <view class="psw-btn">
  48. <text @click="cancel">取消</text>
  49. <text class="psw-qd" @click="pswQd">确定</text>
  50. </view>
  51. </view>
  52. </u-popup>
  53. </view>
  54. </template>
  55. <script>
  56. import { getPoint,buyPoint } from '@/api/set.js'
  57. export default {
  58. data() {
  59. return {
  60. mun: 1,
  61. zuiduo:0,//剩余份数占总数的百分比
  62. shen:0,//还剩几份
  63. all:0,//总量
  64. id:'',
  65. list:'',
  66. show1: false, //支付密码
  67. password: '',
  68. }
  69. },
  70. onLoad() {
  71. this.loadData()
  72. },
  73. methods: {
  74. async loadData() {
  75. getPoint().then(({data}) => {
  76. console.log(data)
  77. this.list = data[0]
  78. this.shen = data[0].stock * 1
  79. this.zuiduo = (data[0].stock * 1 / data[0].all_stock) * 100
  80. // this.zuiduo = this.zuiduo.toFixed(2)
  81. this.all = data[0].all_stock*1
  82. this.id = data[0].id
  83. })
  84. },
  85. buy(){
  86. this.show1 = true
  87. },
  88. cancel() {
  89. this.password = '';
  90. this.show1 = false;
  91. },
  92. pswQd() {
  93. const obj = this
  94. buyPoint(
  95. {
  96. trade_psw: this.password,
  97. num: this.mun
  98. },
  99. this.id
  100. )
  101. .then(e => {
  102. this.password = '';
  103. this.show1 = false;
  104. this.$api.msg("购买节点成功");
  105. })
  106. .catch(e => {
  107. this.password = '';
  108. this.show1 = false;
  109. console.log(e);
  110. });
  111. },
  112. }
  113. }
  114. </script>
  115. <style lang="scss">
  116. page {
  117. height: 100%;
  118. }
  119. .center {
  120. height: 0;
  121. min-height: 100%;
  122. }
  123. .box {
  124. position: relative;
  125. width: 100%;
  126. height: 100%;
  127. .bg {
  128. position: absolute;
  129. top: 0;
  130. right: 0;
  131. left: 0;
  132. width: 100%;
  133. height: 3456rpx;
  134. image {
  135. width: 100%;
  136. height: 3456rpx;
  137. }
  138. }
  139. .rengou {
  140. position: relative;
  141. z-index: 10;
  142. padding-top: 1120rpx;
  143. margin: 0 auto;
  144. width: 460rpx;
  145. font-size: 24rpx;
  146. line-height: 36rpx;
  147. font-family: PingFang SC;
  148. font-weight: bold;
  149. color: #FFFFFF;
  150. height: 1260rpx;
  151. }
  152. .quanyi {
  153. position: relative;
  154. z-index: 10;
  155. // padding-top: 254rpx;
  156. // margin: 0 auto;
  157. margin: 240rpx auto 0;
  158. width: 460rpx;
  159. font-size: 24rpx;
  160. line-height: 36rpx;
  161. font-family: PingFang SC;
  162. font-weight: bold;
  163. color: #FFFFFF;
  164. height: 420rpx;
  165. }
  166. .rule {
  167. position: relative;
  168. z-index: 10;
  169. // padding-top: 264rpx;
  170. // margin: 0 auto;
  171. margin: 264rpx auto 0;
  172. width: 460rpx;
  173. font-size: 24rpx;
  174. line-height: 36rpx;
  175. font-family: PingFang SC;
  176. font-weight: bold;
  177. color: #FFFFFF;
  178. height: 252rpx;
  179. }
  180. .jiedian {
  181. text-align: center;
  182. position: relative;
  183. z-index: 10;
  184. // padding-top: 280rpx;
  185. // margin: 0 auto;
  186. margin: 300rpx auto 0;
  187. width: 460rpx;
  188. color: #FFFFFF;
  189. height: 206rpx;
  190. line-height: 1;
  191. .mun {
  192. font-size: 50rpx;
  193. font-family: PingFang SC;
  194. font-weight: bold;
  195. }
  196. .font {
  197. margin-top: 10rpx;
  198. }
  199. .jdt {
  200. // padding: 20rpx;
  201. margin: 20rpx auto 0;
  202. width: 300rpx;
  203. height: auto;
  204. }
  205. .yue-num {
  206. font-size: 20rpx;
  207. color: #29F3FD;
  208. margin-top: 20rpx;
  209. }
  210. }
  211. .btn {
  212. position: relative;
  213. margin: 120rpx auto 0;
  214. z-index: 10;
  215. width: 514rpx;
  216. height: 80rpx;
  217. background: #29F3FD;
  218. border-radius: 40px;
  219. text-align: center;
  220. line-height: 80rpx;
  221. font-size: 32rpx;
  222. font-family: PingFang SC;
  223. font-weight: bold;
  224. color: #051D38;
  225. }
  226. }
  227. .line {
  228. display: inline-block;
  229. padding-left: 20rpx;
  230. }
  231. .psw-wrapper {
  232. width: 548rpx;
  233. height: 344rpx;
  234. background-color: #ffffff;
  235. .psw-title {
  236. width: 100%;
  237. font-size: 35rpx;
  238. padding: 43rpx 0 49rpx;
  239. text-align: center;
  240. font-weight: 800;
  241. }
  242. .psw-ipt {
  243. display: block;
  244. background-color: #dce3ed;
  245. height: 90rpx;
  246. width: 464rpx;
  247. padding-left: 30rpx;
  248. margin: 0 auto;
  249. font-size: 80rpx;
  250. }
  251. .psw-btn text {
  252. display: inline-block;
  253. text-align: center;
  254. width: 50%;
  255. padding-top: 29rpx;
  256. font-size: 35rpx;
  257. }
  258. .psw-qd {
  259. color: #45969b;
  260. }
  261. }
  262. </style>