transactionDetail.vue 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. <template>
  2. <view class="content">
  3. <web-view :src="url+type" @message='back1' ref="webH5"></web-view>
  4. <!-- #ifdef H5 -->
  5. <view class="btns">
  6. <view @click="back('/pages/transaction/bbjy?type=' + type + '&current=1')" class="btn btn-green">买入</view>
  7. <view @click="back('/pages/transaction/bbjy?type=' + type + '&current=2')" class="btn btn-red" >卖出</view>
  8. </view>
  9. <!-- #endif -->
  10. </view>
  11. </template>
  12. <script>
  13. var wv
  14. export default {
  15. data() {
  16. return {
  17. url: '/hybrid/html/local.html?type=',
  18. type: ''
  19. };
  20. },
  21. onLoad(res) {
  22. this.type = res.type
  23. console.log(this.type,'this,type+++++++++++++')
  24. },
  25. onShow() {},
  26. methods: {
  27. back(url){
  28. console.log('触发');
  29. uni.navigateTo({
  30. url
  31. })
  32. },
  33. back1(url){
  34. console.log('触发1');
  35. },
  36. }
  37. };
  38. </script>
  39. <style lang="scss">
  40. page,
  41. .content {
  42. min-height: 100%;
  43. height: auto;
  44. }
  45. .btns{
  46. position: fixed;
  47. z-index: 1000;
  48. left: 0;
  49. right: 0;
  50. bottom: 0;
  51. display: flex;
  52. flex-direction: row;
  53. align-items: center;
  54. justify-content: center;
  55. padding: 10px;
  56. box-sizing: border-box;
  57. background-color: #131623;
  58. .btn{
  59. flex: 1;
  60. height: 40px;
  61. border-radius: 4px;
  62. line-height: 40px;
  63. text-align: center;
  64. color: #fff;
  65. font-size: 16px;
  66. }
  67. .btn-green{
  68. margin-right: 20px;
  69. background-color: #38ad70;
  70. }
  71. .btn-red{
  72. background-color: #fe5c57;
  73. }
  74. }
  75. </style>