autoParts.vue 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110
  1. <template>
  2. <view>
  3. <view style="position: fixed;top: 0;background-color: #E75F37;">
  4. <view style="width: 90%;margin: 0 auto;padding: 20rpx 0;display: flex;">
  5. <u--text color="#fff" :lines="1"
  6. :text="`${params.brand} ${params.seriesName} ${params.engine} ${params.modelYear} ${params.modelName}`">
  7. </u--text>
  8. <u-icon name="home" color="#fff" size="48rpx" @click="reLaunch"></u-icon>
  9. </view>
  10. </view>
  11. <view style="margin-top: 110rpx;">
  12. <u--form labelPosition="left" :labelStyle="{color: '#E75F37'}" :model="form" ref="form" labelWidth="150rpx"
  13. style="margin-top: 10rpx;padding-bottom: 130rpx;">
  14. <view style="width: calc(96%);margin: 0 auto;background-color: #fff;border-radius: 20rpx;">
  15. <u-cell-group :border="false">
  16. <u-cell :border="false" center title="轮胎规格" arrow-direction="down">
  17. <view slot="icon" style="width: 10rpx;height: 35rpx;background-color: #E75F37;"></view>
  18. </u-cell>
  19. </u-cell-group>
  20. <view style="padding: 0 25rpx;">
  21. <u-form-item label="前轮胎" prop="cname" borderBottom @click="SearchJump(form.frontTireSpecification)">
  22. <u-input v-model="form.frontTireSpecification" inputAlign="right" border="none"
  23. disabledColor="#ffffff" disabled/>
  24. </u-form-item>
  25. <u-form-item label="后轮胎" prop="attn" borderBottom @click="SearchJump(form.rearTireSpecification)" >
  26. <u-input v-model="form.rearTireSpecification" inputAlign="right" border="none"
  27. disabledColor="#ffffff" disabled/>
  28. </u-form-item>
  29. </view>
  30. </view>
  31. </u--form>
  32. </view>
  33. </view>
  34. </template>
  35. <script>
  36. import {
  37. detail,goodsdescGetCnameInt
  38. } from '@/api/views/vehicle/brand.js'
  39. export default {
  40. data() {
  41. return {
  42. displacementList: [],
  43. annualStyle: false,
  44. params: {},
  45. form:{}
  46. }
  47. },
  48. onLoad(params) {
  49. this.params = {
  50. ...params
  51. }
  52. detail({id:this.params.id}).then(res=>{
  53. this.form = res.data
  54. })
  55. },
  56. methods: {
  57. // 搜索跳转
  58. SearchJump(cname) {
  59. goodsdescGetCnameInt({cname}).then(res=>{
  60. uni.setStorageSync('cname', res.data);
  61. uni.reLaunch({
  62. url: '/pages/tabBar/classification',
  63. })
  64. })
  65. },
  66. reLaunch(){
  67. uni.switchTab({
  68. url: '/pages/tabBar/home'
  69. })
  70. }
  71. }
  72. }
  73. </script>
  74. <style lang="scss">
  75. .box-c,
  76. .child {
  77. display: flex;
  78. flex: 1;
  79. }
  80. .list {
  81. &__item {
  82. @include flex;
  83. padding: 6px 12px;
  84. align-items: center;
  85. justify-content: space-between;
  86. &__user-name {
  87. font-size: 32rpx;
  88. color: $u-main-color;
  89. }
  90. &__user-tel {
  91. font-size: 32rpx;
  92. margin-right: 20rpx;
  93. color: $u-main-color;
  94. }
  95. }
  96. &__footer {
  97. color: $u-tips-color;
  98. font-size: 14px;
  99. text-align: center;
  100. margin: 15px 0;
  101. }
  102. }
  103. </style>