card.vue 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146
  1. <template>
  2. <view class="">
  3. <view @click="goDetail(item)" class="data" v-for="(item, index) in list" :key="index">
  4. <view class="top">
  5. <view class="left">
  6. <view class="title ">
  7. <text class="text-bold">员工姓名:</text>
  8. <text>{{item.realName}}</text>
  9. </view>
  10. </view>
  11. <view class="right">
  12. <text class="" v-if="item.auditStatus==1">已通过</text>
  13. <text style="color: #ea7500;" v-if="item.auditStatus==0">待审核</text>
  14. <text style="color: #da0000;" v-if="item.auditStatus==2">未通过</text>
  15. </view>
  16. </view>
  17. <view class="item">
  18. <view class="left">
  19. <view style="padding: 20rpx 30rpx 0;">
  20. <view v-if="item.face" class="">
  21. <image @click.stop="$util.preview(item.face)" style="width: 140rpx;height: 140rpx;" :src="item.face" mode=""></image>
  22. </view>
  23. <view class="content">
  24. <text class="padding-right-10">所属企业:</text>
  25. <text >{{item.enterpriseName}}</text>
  26. </view>
  27. <view class="content">
  28. <text class="padding-right-10">联系方式:</text>
  29. <text>{{item.phone}}</text>
  30. <image @click.stop="call(item.phone)" class="call" src="/static/index/call.png" ></image>
  31. </view>
  32. <view class="content">
  33. <text class="padding-right-10">备注:</text>
  34. <text style="line-height: 50rpx;">{{item.remarks}}</text>
  35. </view>
  36. </view>
  37. </view>
  38. </view>
  39. <view class="bottom" >
  40. <!-- 待审核,显示取消工单 -->
  41. <view @click.stop="pass(item)" v-if="item.auditStatus==0" style="font-size: 22rpx;" class="cu-btn sm round base-bg-color margin-right-20" >
  42. 审核通过
  43. </view>
  44. <view @click.stop="fail(item)" v-if="item.auditStatus==0" style="font-size: 22rpx;" class="cu-btn sm round bg-red " >
  45. 审核不通过
  46. </view>
  47. </view>
  48. </view>
  49. </view>
  50. </template>
  51. <script>
  52. export default {
  53. name: 'card',
  54. props:{
  55. list:{
  56. type:Array,
  57. default:()=>{
  58. []
  59. }
  60. }
  61. },
  62. data() {
  63. return {
  64. };
  65. },
  66. onLoad() {
  67. },
  68. methods:{
  69. call(phone){
  70. uni.makePhoneCall({
  71. phoneNumber:phone
  72. })
  73. },
  74. goDetail(item){
  75. uni.navigateTo({
  76. url:"/pages/index/staffAudit/detail?id="+item.id
  77. })
  78. },
  79. pass(item){
  80. this.$emit('pass',item)
  81. },
  82. fail(item){
  83. this.$emit('fail',item)
  84. }
  85. }
  86. };
  87. </script>
  88. <style lang="scss">
  89. .bg-blue{
  90. background-color: #59a5f0;
  91. color: #FFFFFF;
  92. }
  93. .data {
  94. width: 710rpx;
  95. background-color: #ffffff;
  96. margin: 20rpx auto;
  97. border-radius: 6rpx;
  98. box-sizing: border-box;
  99. padding: 20rpx;
  100. font-size: 28rpx;
  101. .top {
  102. display: flex;
  103. justify-content: space-between;
  104. padding-bottom: 20rpx;
  105. border-bottom: 1rpx dashed #EEEEEE;
  106. .left {
  107. display: flex;
  108. align-items: center;
  109. .title {
  110. margin: 0 10rpx;
  111. font-size: 30rpx;
  112. }
  113. }
  114. .right{
  115. margin-right: 10rpx;
  116. }
  117. }
  118. .item {
  119. margin: 5rpx 0 20rpx 0;
  120. .content {
  121. // border-bottom: 1rpx dashed #DDDDDD;
  122. padding: 20rpx 0 ;
  123. .call{
  124. width: 36rpx;
  125. height: 36rpx;
  126. margin-left: 40rpx;
  127. margin-top: 10rpx;
  128. }
  129. }
  130. }
  131. .bottom {
  132. display: flex;
  133. margin-top: 30rpx;
  134. justify-content: flex-end;
  135. align-items: center;
  136. }
  137. }
  138. </style>