酒店桌布为微信小程序
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

112 lines
2.0 KiB

4 months ago
3 months ago
4 months ago
3 months ago
4 months ago
  1. <template>
  2. <uv-popup ref="popup" :round="30">
  3. <view class="form">
  4. <view class="shopName">
  5. <view>物流名称</view>
  6. <view>
  7. <input v-model="form.logisticsName" placeholder="请输入物流名称" clearable></input>
  8. </view>
  9. </view>
  10. <view class="shopName">
  11. <view>物流单号</view>
  12. <view>
  13. <input v-model="form.logisticsCode" placeholder="请输入物流单号" clearable></input>
  14. </view>
  15. </view>
  16. </view>
  17. <view class="btn" @click="sendLogistics">
  18. <button class="a">发货</button>
  19. </view>
  20. </uv-popup>
  21. </template>
  22. <script>
  23. export default {
  24. data() {
  25. return {
  26. form : {}
  27. }
  28. },
  29. props : ['orderId'],
  30. methods: {
  31. open(){
  32. this.$refs.popup.open('bottom')
  33. },
  34. close(){
  35. this.$refs.popup.close()
  36. },
  37. // 水洗店换货发货
  38. sendLogistics(from, fn){
  39. if (this.$utils.verificationAll(this.form, {
  40. logisticsName : '请输入物流名称',
  41. logisticsCode : '请输入物流单号',
  42. })) {
  43. return
  44. }
  45. this.form.id = this.orderId
  46. this.$api('sendLogistics', this.form, res => {
  47. if (res.code == 200) {
  48. this.$emit('getData')
  49. this.$refs.popup.close()
  50. }
  51. })
  52. },
  53. }
  54. }
  55. </script>
  56. <style scoped lang="scss">
  57. .form{
  58. padding: 20rpx 0;
  59. height: 40vh;
  60. .shopName {
  61. display: flex;
  62. align-items: center;
  63. background-color: #FFF;
  64. margin: 10rpx 0 0 0;
  65. padding: 10rpx 20rpx;
  66. >view:nth-of-type(1) {
  67. width: 30%;
  68. // font-weight: 700;
  69. }
  70. >view:nth-of-type(2) {
  71. width: 70%;
  72. // padding: 0 20rpx 0 0;
  73. border-radius: 10rpx;
  74. overflow: hidden;
  75. input {
  76. background-color: #f5f5f5;
  77. // color: #a4a4a4;
  78. font-size: 28rpx;
  79. padding: 8rpx 8rpx 8rpx 15rpx;
  80. }
  81. }
  82. }
  83. }
  84. .btn {
  85. display: flex;
  86. justify-content: center;
  87. width: 100%;
  88. .a {
  89. display: flex;
  90. justify-content: center;
  91. align-items: center;
  92. width: 90%;
  93. height: 100rpx;
  94. color: #FFF;
  95. background-color: $uni-color;
  96. border: 1px solid red;
  97. border-radius: 100rpx;
  98. font-size: 30rpx;
  99. }
  100. }
  101. </style>