salesContract.vue 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175
  1. <template>
  2. <view>
  3. <view style='background:#fff;padding:15px 10px;border-radius:0 0 10px 10px;'>
  4. <u-search bgColor='#F5F6F9' @change='keyWordChange' :show-action="false" placeholder="请输入合同编号或客户名称" v-model="searchKeyWord"></u-search>
  5. </view>
  6. <view class='content'>
  7. <view class='content-item' v-for='item in contractList'>
  8. <view style='padding:10px 0;' class="flex justify-between">
  9. <view class="title">合同编号</view>
  10. <view>{{item.contractNo}}</view>
  11. </view>
  12. <view style='padding:10px 0;' class="flex justify-between">
  13. <view class="title">客户</view>
  14. <view>{{item.buyer}}</view>
  15. </view>
  16. <view style='padding:10px 0;' class="flex justify-between">
  17. <view class="title">合同重量(吨)</view>
  18. <view>{{item.weight}}</view>
  19. </view>
  20. <view style='padding:10px 0;' class="flex justify-between">
  21. <view class="title">合同单价(元)</view>
  22. <view>{{item.unitContractPrice}}</view>
  23. </view>
  24. <view style='padding:10px 0;' class="flex justify-between">
  25. <view class="title">合同总价(元)</view>
  26. <view>{{item.totalContractPrice}}</view>
  27. </view>
  28. <view style='padding:10px 0;' class="flex justify-between">
  29. <view class="title">已付款(元)</view>
  30. <view>{{item.mildewGrain}}</view>
  31. </view>
  32. <view style='padding:10px 0;' class="flex justify-between">
  33. <view class="title">已开发票 (元)</view>
  34. <view>{{item.goodsNames}}</view>
  35. </view>
  36. </view>
  37. </view>
  38. </view>
  39. </template>
  40. <script>
  41. export default {
  42. data() {
  43. return {
  44. chartlist: [],
  45. carCount1: '',
  46. carCount2: '',
  47. carCount3: '',
  48. inventoryCost: '',
  49. inventoryValue: '',
  50. ZChart: {},
  51. // url:"https://datav.aliyuncs.com/share/235518097ffd673bc1eb05011b9a02b6",
  52. url: '',
  53. flag: true,
  54. chartData: {},
  55. ringoptions: {},
  56. contractType:1,
  57. contractList:[],
  58. currentPage:1,
  59. pageSize:10,
  60. searchKeyWord:''
  61. }
  62. },
  63. onLoad: function(option) {
  64. uni.showLoading({
  65. title: "加载中",
  66. mask: true
  67. })
  68. this.init()
  69. },
  70. onReachBottom() {
  71. let _self = this
  72. uni.showLoading({
  73. title: "加载中",
  74. mask: true
  75. })
  76. setTimeout(function() {
  77. _self.currentPage++;
  78. _self.init();
  79. }, 2000);
  80. },
  81. onPullDownRefresh() {
  82. let _self = this
  83. setTimeout(function() {
  84. uni.stopPullDownRefresh();//停止当前页面下拉刷新
  85. _self.currentPage=0;
  86. _self.init();
  87. }, 1000);
  88. },
  89. methods: {
  90. keyWordChange(e){
  91. this.searchKeyWord=e
  92. uni.showLoading({
  93. title: "加载中",
  94. mask: true
  95. })
  96. this.init()
  97. },
  98. init() {
  99. this.$api.doRequest('get', '/contractManagementInfo/selectInfo',
  100. {compId:uni.getStorageSync('pcUserInfo').compId,
  101. contractType: this.contractType,goodsType:1,currentPage: this.currentPage,pageSize: this.pageSize,searchKeyWord:this.searchKeyWord}).then(res => {
  102. uni.hideLoading()
  103. if(res.data.data.records.length==0){
  104. uni.showToast({title:'没有更多数据了',icon:"none"});
  105. }
  106. if(this.currentPage!=0){
  107. this.contractList=this.contractList.concat(res.data.data.records)
  108. }else{
  109. this.contractList=res.data.data.records
  110. }
  111. })
  112. },
  113. getdata(e) {
  114. console.log(e)
  115. }
  116. }
  117. }
  118. </script>
  119. <style scoped lang="scss">
  120. .content{
  121. background:#F5F6FA;
  122. }
  123. .content-item{
  124. background:#fff;
  125. margin:10px;
  126. padding:10px;
  127. border-radius:6px;
  128. font-size:14px;
  129. .title {
  130. color:#9698A2;
  131. font-size:26rpx;
  132. }
  133. }
  134. charts-box {
  135. // background: black;
  136. position: relative;
  137. // top: 70vh;
  138. }
  139. .content2 .row,
  140. .content4 .row {
  141. display: flex;
  142. justify-content: space-around;
  143. background: #24262d;
  144. padding: 40rpx 20rpx;
  145. .item-top,
  146. .item-bottom {
  147. color: #d5d5d5;
  148. }
  149. .item-bottom {
  150. display: flex;
  151. align-items: center;
  152. }
  153. }
  154. .bottom-tip {
  155. position: absolute;
  156. z-index: 11;
  157. color: #8c8c8d;
  158. right: 10px;
  159. bottom: 10px;
  160. }
  161. .title-margin {
  162. bottom: 120rpx;
  163. }
  164. </style>