lj-taskmx-popup.vue 3.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133
  1. <template>
  2. <div style="width: 100%;">
  3. <div style="display: flex;padding: 10px 0;">
  4. <div style="margin:0 auto;font-size:16px;font-weight:bold;color:#666;padding:0 0 5px 0">{{title}}</div>
  5. <div style="position: absolute;right: 20px;color: #ccc;font-size: 15px;line-height:26px;"
  6. @click="handleClickClose">
  7. <svg class="icon" aria-hidden="true">
  8. <use xlink:href="#icon-close"></use>
  9. </svg>
  10. </div>
  11. </div>
  12. <div style="padding-bottom: 5px;">
  13. <mu-row>
  14. <template v-for="item in objectList">
  15. <mu-col :span="item.tilspan ? item.tilspan : '3'" class="lj-text text-title">{{item.title}}:
  16. </mu-col>
  17. <mu-col :span="item.valspan ? item.valspan : '9'" class="lj-text">{{item.value}}<span
  18. v-if="item.append">{{item.append}}</span></mu-col>
  19. </template>
  20. </mu-row>
  21. </div>
  22. <div class="lj-divider" style="height: 5px;"></div>
  23. <div>
  24. <mu-tabs :value.sync="activeTab" inverse color="orange" indicator-color="orange" center
  25. style="width:60%;margin: 0 auto;background-color: #ffffff;" @change="changeTabs" ref="headerDom">
  26. <mu-tab style="font-size:15px;font-weight: bold;">数量</mu-tab>
  27. <mu-tab style="font-size:15px;font-weight: bold;" v-if="!has121Power">价格</mu-tab>
  28. <mu-tab style="font-size:15px;font-weight: bold;" v-if="showFj">附件</mu-tab>
  29. </mu-tabs>
  30. <div v-show="activeTab === 0">
  31. <div class="lj-cell" style="font-size: 15px;font-weight:bold;color:#666">
  32. <div style="padding: 10px 0 0 0;" v-for="item in neededList">
  33. <div>
  34. <span>{{item.mainlable}}</span>
  35. <span style="position: absolute;right:30px;color:#888">{{item.mainvalue}}</span>
  36. </div>
  37. <div style="font-size:14px;color:#999;margin-left:30px;font-weight:400">
  38. <div style="display:flex;" v-for="mx in item.tableList">
  39. <span>{{mx.lable}}</span>
  40. <span style="position: absolute;right:30px;">{{mx.value}}</span>
  41. </div>
  42. </div>
  43. <div class="lj-divider" style="margin-top:10px"></div>
  44. </div>
  45. </div>
  46. </div>
  47. <div v-show="activeTab === 1">
  48. <mu-row align-items="center"
  49. style="text-align: center;font-size:13px;margin-top:10px;border-bottom: 1px solid #eee;padding:0 0 10px 0;color:#666;">
  50. <mu-col span="4">供应商</mu-col>
  51. <mu-col span="4">最新报价</mu-col>
  52. <mu-col span="4">报价时间</mu-col>
  53. <!-- <mu-col span="3">累计采购量</mu-col> -->
  54. </mu-row>
  55. <mu-row align-items="center"
  56. style="text-align: center;border-bottom: 1px solid #eee;font-size:12px;"
  57. v-for="item in priceList">
  58. <mu-col span="4">{{item.sptname}}</mu-col>
  59. <mu-col span="4">{{item.fpice | moneyFilter}}/{{item.unit}}</mu-col>
  60. <mu-col span="4">{{item.moddate | dateFilter}}</mu-col>
  61. <!-- <mu-col span="3">{{item.qty}}{{item.unit}}</mu-col> -->
  62. </mu-row>
  63. </div>
  64. <div v-show="activeTab === 2" v-if="showFj">
  65. <slot name="filelist"></slot>
  66. </div>
  67. </div>
  68. </div>
  69. </template>
  70. <script>
  71. export default {
  72. name: 'LjTaskmxPopup',
  73. props: {
  74. objectList: {
  75. type: Array,
  76. default: function () {
  77. return []
  78. }
  79. },
  80. neededList: {
  81. type: Array,
  82. default: function () {
  83. return []
  84. }
  85. },
  86. priceList: {
  87. type: Array,
  88. default: function () {
  89. return []
  90. }
  91. },
  92. showFj: {
  93. type: Boolean,
  94. default: false
  95. }
  96. },
  97. data() {
  98. return {
  99. title: '明细相关信息',
  100. activeTab: 0,
  101. }
  102. },
  103. created() {
  104. },
  105. methods: {
  106. handleClickClose() {
  107. this.$emit('click-close')
  108. },
  109. changeTabs() {
  110. }
  111. },
  112. computed: {
  113. has121Power() {
  114. let userinfo = $lj.getStorage("userInfo");
  115. return userinfo.empid > 0 && $lj.checkPower(121);
  116. }
  117. }
  118. }
  119. </script>
  120. <style scoped>
  121. .lj-text {
  122. font-size: 14px;
  123. }
  124. .text-title {
  125. text-align: right;
  126. }
  127. </style>