drawerdetail.vue 4.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259
  1. <template>
  2. <view class="content">
  3. <view class="acountbox">
  4. <text class="atitle">出票人</text>
  5. <view class="inacount">
  6. <text class="acoutitle">出票人</text>
  7. <input type="text" v-model="form.name" class="checkword" placeholder="请输入出票人的姓名"
  8. placeholder-style="font-size:30rpx;color:#BEBDBB" />
  9. </view>
  10. <view class="inacount">
  11. <text class="acoutitle">账户</text>
  12. <input type="text" v-model="form.bankAccount" class="checkword" placeholder="请输入账户"
  13. placeholder-style="font-size:30rpx;color:#BEBDBB" />
  14. </view>
  15. <view class="inacount">
  16. <text class="acoutitle">开户行名称</text>
  17. <input type="text" v-model="form.bankName" class="checkword" placeholder="请输入开户行名称"
  18. placeholder-style="font-size:30rpx;color:#BEBDBB" />
  19. </view>
  20. </view>
  21. <view class="logininbtn" @click="MakeSure">
  22. <text>确认修改</text>
  23. </view>
  24. </view>
  25. </template>
  26. <script>
  27. let that
  28. export default {
  29. data() {
  30. return {
  31. form: {
  32. name: '',
  33. bankAccount: '',
  34. bankName: ''
  35. },
  36. }
  37. },
  38. onLoad(o) {
  39. that = this
  40. if (o.id) {
  41. this.id = o.id
  42. }
  43. this.init()
  44. },
  45. methods: {
  46. init() {
  47. uni.$u.http.get(`/api/Drawer/${this.id}`, {
  48. custom: {
  49. auth: true
  50. }
  51. }).then((res) => {
  52. this.form = res
  53. }).catch((err) => {
  54. console.log(err)
  55. })
  56. },
  57. MakeSure() {
  58. let form=this.form
  59. form.id=this.id
  60. if (form.name.length == 0) {
  61. that.$toast("请输入出票人的姓名")
  62. return
  63. }
  64. if (form.bankAccount.length == 0) {
  65. that.$toast("请输入出票人的账户")
  66. return
  67. }
  68. if (form.bankName.length == 0) {
  69. that.$toast("请输入开户行名称")
  70. return
  71. }
  72. uni.showModal({
  73. title: '提示',
  74. content: '是否确认修改?',
  75. success: function(res) {
  76. if (res.confirm) {
  77. uni.showLoading()
  78. uni.$u.http.post('/api/Drawer/update', form, {
  79. custom: {
  80. auth: true
  81. }
  82. }).then((res) => {
  83. uni.hideLoading()
  84. that.$toast("修改成功")
  85. }).catch((err) => {
  86. uni.hideLoading()
  87. that.$toast(err.msg)
  88. })
  89. }
  90. }
  91. });
  92. }
  93. }
  94. }
  95. </script>
  96. <style lang="scss" scoped>
  97. /* uni.scss */
  98. @import 'uview-ui/theme.scss';
  99. .content {
  100. display: flex;
  101. flex-direction: column;
  102. align-items: center;
  103. justify-content: center;
  104. }
  105. .atitle {
  106. display: block;
  107. padding-top: 102rpx;
  108. // padding-left: 30rpx;
  109. font-size: 60rpx;
  110. font-weight: 600;
  111. }
  112. .loginbg {
  113. background-image: url("https://t39.9026.com/web/uploads/thumbs/mall10000/20220629/e01b927c95ee1f05364f5e456f281388.png");
  114. height: 559rpx;
  115. width: 750rpx;
  116. background-size: 100% 100%;
  117. // display: flex;
  118. // align-items: center;
  119. // justify-content: center;
  120. }
  121. .logo {
  122. margin: 0 auto;
  123. height: 200rpx;
  124. width: 200rpx;
  125. margin-left: auto;
  126. margin-right: auto;
  127. margin-bottom: 50rpx;
  128. }
  129. .text-area {
  130. display: flex;
  131. justify-content: center;
  132. }
  133. .title {
  134. font-size: 36rpx;
  135. color: #8f8f94;
  136. }
  137. .logobox {
  138. margin: 0 auto;
  139. margin-top: 212rpx;
  140. width: 269rpx;
  141. height: 191rpx;
  142. // background-color: #F1F1F1;
  143. image {
  144. width: 100%;
  145. height: 100%;
  146. }
  147. }
  148. .checkbox {}
  149. .business {
  150. width: 305rpx;
  151. height: 90rpx;
  152. display: flex;
  153. align-items: center;
  154. justify-content: center;
  155. text-align: center;
  156. // background-color: #D8AB5A;
  157. border-raotherdius: 20rpx;
  158. color: #FFFFFF;
  159. margin-top: 57rpx;
  160. }
  161. .bnesper {
  162. background-size: 100%;
  163. background-image: url("@/static/img/loginbtn4.png");
  164. padding-top: 10rpx;
  165. color: #FFF1D8;
  166. line-height: 90rpx;
  167. }
  168. .applyper {
  169. background-image: url("@/static/img/loginbt1.png");
  170. background-size: 100%;
  171. padding-top: 10rpx;
  172. color: #FFF1D8;
  173. }
  174. .actapp {
  175. background-image: url("@/static/img/loginbtn3.png");
  176. background-size: 100%;
  177. color: #D05C39;
  178. }
  179. .actbnes {
  180. background-image: url("@/static/img/loginbt2.png");
  181. background-size: 100%;
  182. color: #D05C39;
  183. }
  184. .acountbox {
  185. .inacount {
  186. display: flex;
  187. padding: 35rpx 20rpx;
  188. box-sizing: border-box;
  189. width: 690rpx;
  190. margin-top: 40rpx;
  191. background-color: #F6F6F6;
  192. border-radius: 20rpx;
  193. font-size: 30rpx;
  194. color: #1F242A;
  195. input {
  196. width: 360rpx;
  197. color: #68625B;
  198. }
  199. }
  200. .acoutitle {
  201. font-weight: 600;
  202. }
  203. .checkword {
  204. padding-left: 20rpx;
  205. color: #1F242A;
  206. font-size: 30rpx;
  207. }
  208. }
  209. .otherbt {
  210. width: 606rpx;
  211. display: flex;
  212. justify-content: space-between;
  213. font-size: 24rpx;
  214. padding-top: 30rpx;
  215. }
  216. .regbt {
  217. color: $uni-all-theme;
  218. }
  219. .logininbtn {
  220. margin-top: 80rpx;
  221. width:690rpx;
  222. border-radius:20rpx;
  223. background: linear-gradient(to right, #FFE1AD,#D8AB5A);
  224. box-shadow: 0 10rpx 20rpx 1rpx rgba(179, 116, 5, 0.2);
  225. height: 100rpx;
  226. text-align: center;
  227. color: #fff;
  228. line-height: 100rpx;
  229. }
  230. </style>