popup.vue 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485
  1. <template>
  2. <view>
  3. <!-- 弹窗 -->
  4. <view class="bgbox" @click="getClose" v-if="type"></view>
  5. </view>
  6. </template>
  7. <script>
  8. import config from '@/config'
  9. const baseUrl = config.baseUrl
  10. import { getToken } from '@/utils/auth'
  11. import {uploadmore} from '@/utils/common.js'
  12. export default{
  13. components:{},
  14. props:{
  15. type: {
  16. type: String,
  17. default () {
  18. return ''
  19. }
  20. },
  21. finshtype:{
  22. type: [String,Number],
  23. default () {
  24. return ''
  25. }
  26. }
  27. },
  28. data(){
  29. return{
  30. baseUrl:config.baseUrl,
  31. closeimg:require("@/static/images/close.png"),
  32. downimg:require("@/health/static/health/down.png"),
  33. hicoa:require("@/health/static/health/hicoa.png"),
  34. }
  35. },
  36. mounted() {
  37. this.baseUrl=baseUrl
  38. },
  39. watch:{
  40. type(val){
  41. // this.filelist=[];
  42. // this.shtext='';
  43. // this.isty='2';
  44. // this.phofile=[];
  45. }
  46. },
  47. methods:{
  48. bindDateChange(){
  49. var val=e.detail.value;
  50. },
  51. getClose(){
  52. this.$emit('getClose')
  53. },
  54. getSure(){
  55. this.$emit('getSure')
  56. },
  57. getChose(val){
  58. this.peoval=val
  59. },
  60. getPreviewImage(arr,idx){
  61. var newArr=[];
  62. arr.forEach(ite=>{
  63. var ds=this.baseUrl+ite
  64. newArr.push(ds)
  65. })
  66. uni.previewImage({
  67. urls: newArr,
  68. current:idx,
  69. success: function(data) {
  70. },
  71. fail: function(err) {
  72. }
  73. });
  74. },
  75. }
  76. }
  77. </script>
  78. <style lang="scss" scoped>
  79. .closeimg{width: 32rpx;height: 32rpx;position: absolute;bottom: -72rpx;left: 50%;margin-left: -16rpx;}
  80. </style>