酒店桌布为微信小程序
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.

108 lines
1.9 KiB

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. // 水洗店换货发货
  35. sendLogistics(from, fn){
  36. if (this.$utils.verificationAll(this.form, {
  37. logisticsName : '请输入物流名称',
  38. logisticsCode : '请输入物流单号',
  39. })) {
  40. return
  41. }
  42. this.form.id = this.orderId
  43. this.$api('sendLogistics', this.form, res => {
  44. if (res.code == 200) {
  45. this.$emit('getData')
  46. }
  47. })
  48. },
  49. }
  50. }
  51. </script>
  52. <style scoped lang="scss">
  53. .form{
  54. padding: 20rpx 0;
  55. height: 40vh;
  56. .shopName {
  57. display: flex;
  58. align-items: center;
  59. background-color: #FFF;
  60. margin: 10rpx 0 0 0;
  61. padding: 10rpx 20rpx;
  62. >view:nth-of-type(1) {
  63. width: 30%;
  64. // font-weight: 700;
  65. }
  66. >view:nth-of-type(2) {
  67. width: 70%;
  68. // padding: 0 20rpx 0 0;
  69. border-radius: 10rpx;
  70. overflow: hidden;
  71. input {
  72. background-color: #f5f5f5;
  73. // color: #a4a4a4;
  74. font-size: 28rpx;
  75. padding: 8rpx 8rpx 8rpx 15rpx;
  76. }
  77. }
  78. }
  79. }
  80. .btn {
  81. display: flex;
  82. justify-content: center;
  83. width: 100%;
  84. .a {
  85. display: flex;
  86. justify-content: center;
  87. align-items: center;
  88. width: 90%;
  89. height: 100rpx;
  90. color: #FFF;
  91. background-color: $uni-color;
  92. border: 1px solid red;
  93. border-radius: 100rpx;
  94. font-size: 30rpx;
  95. }
  96. }
  97. </style>