adminIndex.vue 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113
  1. <template>
  2. <view class="mainBox">
  3. <uni-nav-bar fixed="true" statusBar="true" left-icon="back" background-color="#157A2C" color="#fff" title="公海客户" @clickLeft="back">
  4. </uni-nav-bar>
  5. <u-list @scrolltolower="scrolltolower">
  6. <contactList :btnList="btnList" ref="contactListRef"></contactList>
  7. </u-list>
  8. <view class="add" @click="add">
  9. <u-icon name="plus" color="#fff"></u-icon>
  10. </view>
  11. </view>
  12. </template>
  13. <script>
  14. import contactList from './contactList.vue'
  15. export default {
  16. components: {
  17. contactList
  18. },
  19. data() {
  20. return {
  21. treeList: [],
  22. btnList: [{
  23. name: '修改',
  24. apiName: '',
  25. btnType: 'primary',
  26. type: '1',
  27. pageUrl: '/pages/saleManage/contact/add',
  28. judge: [{
  29. key: 'assignStatus',
  30. value: [0]
  31. }],
  32. },{
  33. name: '详情',
  34. apiName: '',
  35. btnType: 'primary',
  36. type: '1',
  37. pageUrl: '/pages/saleManage/contact/components/drawer'
  38. },{
  39. name: '释放',
  40. apiName: 'setFree',
  41. btnType: 'warning ',
  42. type: '2',
  43. pageUrl: '',
  44. judge: [{
  45. key: 'assignStatus',
  46. value: [1]
  47. }],
  48. }, {
  49. name: '指派',
  50. apiName: 'assignModelShow',
  51. btnType: 'warning ',
  52. type: '2',
  53. pageUrl: '',
  54. judge: [{
  55. key: 'assignStatus',
  56. value: [0]
  57. }],
  58. }, {
  59. name: '删除',
  60. apiName: 'del',
  61. btnType: 'error',
  62. type: '2',
  63. pageUrl: '',
  64. judge: [{
  65. key: 'assignStatus',
  66. value: [0]
  67. }],
  68. }]
  69. }
  70. },
  71. async onLoad() {
  72. this.$nextTick(() => {
  73. this.$refs.contactListRef.getList({
  74. type: 1
  75. })
  76. })
  77. },
  78. methods: {
  79. add() {
  80. uni.navigateTo({
  81. url: '/pages/saleManage/contact/add'
  82. })
  83. },
  84. scrolltolower() {
  85. this.$refs.contactListRef.getList({
  86. type: 1
  87. })
  88. },
  89. }
  90. }
  91. </script>
  92. <style lang="scss" scoped>
  93. .add {
  94. width: 96rpx;
  95. height: 96rpx;
  96. border-radius: 48rpx;
  97. background: #3c9cff;
  98. position: fixed;
  99. bottom: 100rpx;
  100. right: 24rpx;
  101. display: flex;
  102. align-items: center;
  103. justify-content: center;
  104. }
  105. </style>