Storeclassification.vue 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124
  1. <template>
  2. <view class="titlenav">
  3. <titlenav :flag="true"></titlenav>
  4. <view class="top">
  5. <view class="title">添加分类</view>
  6. </view>
  7. <view class="content">
  8. <view class="add">
  9. <view class="name">分类一</view>
  10. <view class="inpt"><input type="number" value="" placeholder="请输入" v-model="form.name" /></view>
  11. <image class="imgBox" src="https://ticket-exchange.oss-cn-hangzhou.aliyuncs.com/image/2021-09-29-12-21-44BiuCgnNh.png" mode=""></image>
  12. </view>
  13. <view class="add">
  14. <view class="name">分类二</view>
  15. <view class="inpt"><input type="number" value="" placeholder="请输入" v-model="form.name1" /></view>
  16. <image class="imgBox" src="https://ticket-exchange.oss-cn-hangzhou.aliyuncs.com/image/2021-09-29-12-21-44BiuCgnNh.png" mode=""></image>
  17. </view>
  18. <view class="add">
  19. <view class="name">分类三</view>
  20. <view class="inpt"><input type="number" value="" placeholder="请输入" v-model="form.name2" /></view>
  21. <image class="imgBox" src="https://ticket-exchange.oss-cn-hangzhou.aliyuncs.com/image/2021-09-29-12-21-44BiuCgnNh.png" mode=""></image>
  22. </view>
  23. </view>
  24. <view class="btn">
  25. <u-button block class="btn2" @click="submit">添加分类</u-button>
  26. <u-button block type="primary" @click="submit2">保存修改</u-button>
  27. </view>
  28. </view>
  29. </template>
  30. <script>
  31. import { mapState } from 'vuex';
  32. import Titlenav from '../components/Titlenav.vue';
  33. export default {
  34. components: { Titlenav },
  35. data() {
  36. return {
  37. form: {}
  38. };
  39. },
  40. computed: {
  41. ...mapState(['systemInfo'])
  42. },
  43. methods: {}
  44. };
  45. </script>
  46. <style lang="scss" scoped>
  47. .titlenav {
  48. background: #214bbe;
  49. .top {
  50. height: 50px;
  51. .title {
  52. font-size: 22px;
  53. font-weight: bold;
  54. color: #ffffff;
  55. line-height: 26px;
  56. padding: 10px 0 20px 20px;
  57. }
  58. }
  59. .content {
  60. background: #ffffff;
  61. border-radius: 16px 16px 0px 0px;
  62. padding: 1px 20px;
  63. }
  64. /deep/ .uni-input-placeholder {
  65. font-size: 16px;
  66. text-align: center;
  67. line-height: 24px;
  68. }
  69. /deep/ .uni-input-input{
  70. text-align: center;
  71. }
  72. /deep/ .u-btn {
  73. width: 162px;
  74. height: 48px;
  75. font-size: 16px;
  76. font-weight: 400;
  77. color: #ffffff;
  78. border-radius: 4px;
  79. }
  80. .add{
  81. padding: 11px 0;
  82. display: flex;
  83. align-items: center;
  84. justify-content: space-between;
  85. .inpt {
  86. background: #f5f7fa;
  87. width: 70%;
  88. height: 48px;
  89. border-radius: 8px;
  90. padding: 11px 12px;
  91. }
  92. .name {
  93. font-size: 14px;
  94. font-weight: bold;
  95. color: #aaabad;
  96. line-height: 24px;
  97. width: 42px;
  98. }
  99. .imgBox {
  100. width: 24px;
  101. height: 24px;
  102. }
  103. }
  104. .btn {
  105. display: flex;
  106. align-items: center;
  107. position: fixed;
  108. justify-content: space-between;
  109. left: 0;
  110. right: 0;
  111. bottom: 0;
  112. z-index: 100;
  113. padding: 6px 20px;
  114. padding-bottom: 34px;
  115. padding-bottom: calc(34px + constant(safe-area-inset-bottom)); // 兼容 IOS<11.2
  116. padding-bottom: calc(34px + env(safe-area-inset-bottom)); // 兼容 IOS>=11.2
  117. background-color: #ffffff;
  118. .btn2 {
  119. color: #214bbe;
  120. }
  121. }
  122. }
  123. </style>