stock.wxml 6.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120
  1. <wxs module="filters" src="../../utils/toFixed.wxs" />
  2. <view wx:if="{{type==1}}">
  3. <view wx:if='{{id}}' class="detail">
  4. <view class="stock_name">{{info.name}}
  5. <text>{{info.code}}</text>
  6. </view>
  7. <block wx:if='{{info.last_nb_comments}}'>
  8. <image mode="withFix" src="{{info.last_nb_comments.img}}"></image>
  9. <view class="desc">{{info.last_nb_comments.content}}</view>
  10. <view class="nr">@牛人点评 {{filters.getDate(info.last_nb_comments.ctime)}}</view>
  11. </block>
  12. <view class="tab">
  13. <view bindtap="tab" data-id='1' class="{{cur==1?'act':''}}">今日持仓<text></text></view>
  14. <!-- <view bindtap="tab" data-id='0' class="{{cur==0?'act':''}}">我要解读<text></text></view>
  15. <view bindtap="tab" data-id='2' class="{{cur==2?'act':''}}">牛人点评<text></text></view> -->
  16. </view>
  17. <view bindtap="blur" style="background: #fff;padding: 20rpx 0rpx 0rpx 20rpx;">
  18. <view class="content" wx:if='{{cur==0}}'>
  19. <view class="_list" wx:for="{{comment_list}}">
  20. <navigator url="../homepage/homepage?user_id={{item.user_id}}"><image src="{{item.user_avatar}}" ></image></navigator>
  21. <view class="msg">
  22. <navigator url="../homepage/homepage?user_id={{item.user_id}}" class="_name">{{item.user_name}}</navigator>
  23. <view class="_content">{{item.content}}</view>
  24. <view class="answer" wx:if="{{item.children.length>0}}">
  25. <view wx:for="{{item.children}}" wx:for-item='i'>
  26. <text>{{i.user_name}}:</text>
  27. {{i.content}}</view>
  28. </view>
  29. <view class="addr">
  30. <text>{{item.ctime}}</text><text>来自{{item.location}}</text>
  31. <image wx:if="{{item.user_id==user_id}}" class="del" data-id='{{item.id}}' data-name='{{item.user_name}}' catchtap="delmsg" mode="widthFix" src="../../images/delete.png"></image>
  32. <image data-id='{{item.id}}' data-name='{{item.user_name}}' catchtap="answer" mode="widthFix" src="../../images/msg.png"></image>
  33. </view>
  34. </view>
  35. </view>
  36. </view>
  37. <scroll-view wx:if='{{cur==1}}' bindscrolltolower='next1' scroll-y='{{true}}' style="height:calc(100vh - 90rpx);">
  38. <navigator hover-class="none" class="player" wx:for='{{list}}' bind:tap="pushToday" data-match_id="{{item.match_id}}" data-record_id="{{item.id}}" data-user_id = "{{item.user_id}}">
  39. <view class="name">{{item.username}} <text>{{item.badge}}</text>
  40. </view>
  41. <view class="info">
  42. 资产:<view><label style="font-weight: 600;">{{item.today_fund}}w</label>(今日收益 <text class="{{item.today_income[0]=='-' ?'down':'up'}}">{{item.today_income}}</text><text style="color:#F5F5F5;"> | </text>总收益<text class="{{item.total_income[0]=='-' ?'down':'up'}}">{{item.total_income}}</text>)</view>
  43. </view>
  44. <view class="info" wx:if="{{role != 0}}">
  45. 持仓:
  46. <view wx:if='{{item.is_markt}}'>开超市</view>
  47. <view wx:elif='{{item.today_stock.length>0}}'>
  48. <block wx:for="{{item.today_stock}}" wx:for-item='i'> {{i.name}}({{i.fund}}w) </block>
  49. </view>
  50. <view wx:else>空仓</view>
  51. </view>
  52. </navigator>
  53. <block wx:if='{{total1 >= 20}}'>
  54. <view class='loading' wx:if='{{list.length < total1}}'>加载更多...</view>
  55. </block>
  56. </scroll-view>
  57. <view wx:if='{{cur==2}}'>
  58. <view wx:for="{{nbComments}}" style="margin-bottom: 20rpx;">
  59. <image style="width: 100%;" mode="withFix" src="{{item.img}}"></image>
  60. <view class="desc">{{item.content}}</view>
  61. <view class="nr">{{filters.getDate(item.ctime)}}</view>
  62. </view>
  63. </view>
  64. </view>
  65. <!-- <view class="post">
  66. <input value="{{comment}}" confirm-type='send' bindconfirm='sendmsg' placeholder-style="color:#999" maxlength="500" bindinput="inputchange1" focus='{{focus}}' type="text" placeholder="{{text}}"/>
  67. </view> -->
  68. </view>
  69. <view wx:else class="hot_list">
  70. <view class="top_bg">
  71. <image mode="widthFix" src="../../xiao/titlehot@2x.png"></image>
  72. <view class="top_title">顽主杯热榜
  73. <image bindtap="toSearch" class="search-img" mode="widthFix" src="../../xiao/search@2x.png"></image>
  74. <picker mode="date" value="{{stock_date}}" bindchange="bindDateChange">
  75. <view class="date-picker">
  76. {{stock_date}}
  77. <image style="width: 16rpx;" mode="widthFix" src="../../xiao/choosedown@2x.png"></image>
  78. </view>
  79. </picker>
  80. </view>
  81. </view>
  82. <scroll-view scroll-y='{{true}}' bindscrolltolower='next' style="background: #fff;padding:0 30rpx;">
  83. <navigator hover-class="none" class="list" url="../stock/stock?id={{item.id}}&&stock_date={{stock_date}}&type=1" wx:for='{{list}}'>
  84. <image wx:if="{{index<3}}" class="number" mode="widthFix" src="../../xiao/{{index+1}}.png"></image>
  85. <text wx:else class="number">{{index+1}}</text>
  86. <view class="stock-name">
  87. {{item.stock_name}} <text class="cc">{{filters.toFix2(item.total_fund)}}w</text>
  88. <text class="code">{{item.stock_code}} {{item.stock_desc}}</text>
  89. </view>
  90. <view class="num"> <text>{{item.count}}</text> 人持仓
  91. <image class="more-image" mode="widthFix" src="../../images/right_icon.png"></image>
  92. </view>
  93. </navigator>
  94. <block wx:if='{{total >= 20}}'>
  95. <view class='loading' wx:if='{{list.length < total}}'>上拉加载更多...</view>
  96. </block>
  97. </scroll-view>
  98. </view>
  99. </view>
  100. <view wx:else>
  101. <view style="background: #fff;padding: 20rpx;">
  102. <view class="search">
  103. <image mode="heightFix" src="../../images/ss1.png"></image>
  104. <input bindconfirm="inputChange" confirm-type='search' placeholder-style="color:#999;" placeholder="输入股票名称"></input>
  105. </view>
  106. </view>
  107. <scroll-view scroll-y='{{true}}' bindscrolltolower='next' style="background: #fff;padding:0 30rpx;">
  108. <navigator hover-class="none" class="list" url="../stock/stock?id={{item.id}}&stock_date={{stock_date}}&type=1" wx:for='{{searchList}}'>
  109. <image wx:if="{{index<3}}" class="number" mode="widthFix" src="../../xiao/{{index+1}}.png"></image>
  110. <text wx:else class="number">{{index+1}}</text>
  111. <view class="stock-name">
  112. {{item.stock_name}}
  113. <text>持仓金额:{{filters.toFix2(item.total_fund)}}w</text>
  114. </view>
  115. <view class="num"> <text>{{item.count}}</text> 人持仓</view>
  116. </navigator>
  117. </scroll-view>
  118. </view>