lianjieDesc.vue 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173
  1. <template>
  2. <view class="content">
  3. <form >
  4. <view class="body user-insert-line">服务器IP:{{equipmentApply.managerId}}</view>
  5. <view class="body user-insert-line">设备编号:{{equipmentApply.clientId}}</view>
  6. <view class="body user-insert-line">归属者:{{equipmentApply.adminUserName}}</view>
  7. <view class="body user-insert-line">归属商家级别:{{equipmentApply.adminLevel}}</view>
  8. <!-- //提交按钮 -->
  9. <view class="tr">
  10. <button type="primary" formType="submit" @click="agree(equipmentApply.id)"
  11. class="button">
  12. <p class="p1">通过</p>
  13. </button>
  14. <button type="warn" formType="submit" @click="unagree(equipmentApply.id)" class="button">
  15. <p class="p1">拒绝</p>
  16. </button>
  17. </view>
  18. </form>
  19. </view>
  20. </template>
  21. <script>
  22. export default {
  23. data(){
  24. return{
  25. equipmentApply:{},
  26. }
  27. },
  28. onLoad: function(option) {
  29. const equipmentApply = JSON.parse(decodeURIComponent(option.equipmentApply));
  30. //idCardNo
  31. this.equipmentApply = equipmentApply;
  32. },
  33. onShow() {
  34. },
  35. methods: {
  36. agree(id){
  37. var that = this;
  38. uni.showModal({
  39. title: '提示',
  40. content: '是否通过?',
  41. success: function(res) {
  42. if (res.confirm) {
  43. var token = uni.getStorageSync("token");
  44. uni.request({
  45. url: that.serverurl + '/TEquipmentApply/agree',
  46. header: {
  47. 'token': token
  48. },
  49. data:{
  50. "id":id
  51. },
  52. method: "POST",
  53. success: (res) => {
  54. uni.showToast({
  55. title: res.data.message,
  56. duration: 2000
  57. });
  58. },
  59. });
  60. } else if (res.cancel) {}
  61. }
  62. });
  63. },
  64. unagree(id){
  65. var that = this;
  66. uni.showModal({
  67. title: '提示',
  68. content: '是否拒绝?',
  69. success: function(res) {
  70. if (res.confirm) {
  71. var token = uni.getStorageSync("token");
  72. var eid = id;
  73. uni.request({
  74. url: that.serverurl + '/TEquipmentApply/unagree',
  75. data:{
  76. "id":eid
  77. },
  78. header: {
  79. 'token': token
  80. },
  81. method: "POST",
  82. success: (res) => {
  83. uni.showToast({
  84. title: res.data.message,
  85. duration: 2000
  86. });
  87. },
  88. });
  89. } else if (res.cancel) {}
  90. }
  91. });
  92. },
  93. }
  94. }
  95. </script>
  96. <style>
  97. .content{
  98. padding-top:20upx;
  99. margin-left:20upx;
  100. }
  101. .body {
  102. background-color: #FFFFFF;
  103. padding: 10upx 20upx 10upx 20upx;
  104. display: flex;
  105. flex-direction: row;
  106. justify-content: flex-start;
  107. }
  108. .input {
  109. /* padding: 10upx 20upx 10upx 0upx; */
  110. padding-left: 20upx;
  111. padding-top: 10upx;
  112. background-color: #FFFFFF;
  113. width: 500upx;
  114. height: 50upx;
  115. box-shadow: 0upx 0upx 20upx #D3D3D3;
  116. border-radius: 5upx;
  117. }
  118. /* .button {
  119. margin: 0 auto;
  120. display: inline-block;
  121. }
  122. button[type=primary] {
  123. background-color: #007aff;
  124. color: #fff;
  125. display: inline-block;
  126. } */
  127. .btn-area{
  128. padding-top:60upx;
  129. margin: 0 auto;
  130. width: 50%;
  131. }
  132. .user-insert-line {
  133. width: 600upx;
  134. height: 23px;
  135. border-bottom:solid black 1px;
  136. margin: 0 auto;
  137. }
  138. .user-insert{
  139. width: 400upx;
  140. margin: 0 auto;
  141. }
  142. .tr {
  143. padding-top: 15upx;
  144. display: flex;
  145. flex-direction: row;
  146. justify-content: flex-start;
  147. font-size: 48upx;
  148. font-family: "PingFang-SC-Bold";
  149. position: fixed;
  150. bottom: 100upx;
  151. width: 95%;
  152. }
  153. .button {
  154. margin: auto;
  155. width: 50%;
  156. height: 100upx;
  157. }
  158. .p1 {
  159. font-size: 48upx;
  160. }
  161. view{
  162. font-size: 30rpx;
  163. }
  164. </style>