addStaff.vue 6.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271
  1. <template>
  2. <view>
  3. <!-- 公共组件-每个页面必须引入 -->
  4. <public-module></public-module>
  5. <service-widget @btnClick="btn_click"></service-widget>
  6. <view class="headers dis a-c j-start " :style="headerStyle">
  7. <u-icon name="arrow-left" size="40" @tap="back"></u-icon>
  8. <text style="margin: auto;">会员分享</text>
  9. </view>
  10. <view class="Personnel dis a-c j-s">
  11. <view class="addMe">
  12. <image src="../../../static/image/addStaff/f1.png" mode="" @click="getStaffList(1)"></image>
  13. </view>
  14. <view class="addMe">
  15. <image src="../../../static/image/addStaff/f2.png" mode="" @click="getStaffList(2)"></image>
  16. </view>
  17. <view class="addMe">
  18. <image src="../../../static/image/addStaff/f3.png" mode="" @click="getStaffList(3)"></image>
  19. </view>
  20. </view>
  21. <view class="" style="padding: 16px;">
  22. <view class="promotion " v-if="sources==1">
  23. <view style="width: 100%;border-bottom: 1px solid #f2f2f2;">
  24. <u-tabs :list="list1" :is-scroll="false" :current="current" @change="change"></u-tabs>
  25. </view>
  26. <view class="dis a-c j-c f-c mt-5" v-if="current==0">
  27. <image :src="recommendImg" mode="widthFix" lazy-load style="width: 110px;"></image>
  28. <text class="mt-1" style="color: rgba(51, 51, 51, 0.8);">面对面推荐</text>
  29. <text style="color: rgba(51, 51, 51, 0.8);">更安全更方便的加入方式</text>
  30. <view class="invitation dis j-c a-c">
  31. <image src="../../../static/image/addStaff/f4.png" mode=""></image>
  32. <text @click="invitation">邀请函</text>
  33. </view>
  34. </view>
  35. <view class="dis a-c j-c f-c mt-5" v-if="current==1">
  36. <image :src="DownloadImg" mode="widthFix" lazy-load style="width: 110px;"></image>
  37. <text class="mt-1" style="color: rgba(51, 51, 51, 0.8);">微信扫描二维码</text>
  38. <text style="color: rgba(51, 51, 51, 0.8);">即可下载App</text>
  39. <!-- <view class="invitation dis j-c a-c">
  40. <image src="../../../static/image/addStaff/f4.png" mode=""></image>
  41. <text @click="invitation">邀请函</text>
  42. </view> -->
  43. </view>
  44. </view>
  45. <view class="promotion " v-if="sources==2">
  46. <view style="width: 100%;border-bottom: 1px solid #f2f2f2;">
  47. <u-tabs :list="list" :is-scroll="false" :current="current1" @change="change1"></u-tabs>
  48. </view>
  49. <view class="dis a-c j-c f-c mt-5" v-if="current1==0">
  50. <image :src="orderissuerImg" mode="widthFix" lazy-load style="width: 110px;"></image>
  51. <text class="mt-1" style="color: rgba(51, 51, 51, 0.8);">面对面推荐</text>
  52. <text style="color: rgba(51, 51, 51, 0.8);">更安全更方便的加入方式</text>
  53. </view>
  54. <view class="dis a-c j-c f-c mt-5" v-if="current1==1">
  55. <image :src="DownloadImg" mode="widthFix" lazy-load style="width: 110px;"></image>
  56. <text class="mt-1" style="color: rgba(51, 51, 51, 0.8);">微信扫描二维码</text>
  57. <text style="color: rgba(51, 51, 51, 0.8);">即可下载App</text>
  58. </view>
  59. </view>
  60. </view>
  61. </view>
  62. </template>
  63. <script>
  64. import myListItem from "@/components/modules/my/my-list-item.vue";
  65. import {
  66. mapState
  67. } from "vuex"
  68. import QR from "@/common/wxqrcode.js"
  69. export default {
  70. components: {
  71. myListItem
  72. },
  73. data() {
  74. return {
  75. recommendImg: "",
  76. DownloadImg: "",
  77. orderissuerImg: '',
  78. list: [{
  79. name: '面对面推荐'
  80. }, {
  81. name: '扫码下载'
  82. }],
  83. current: 0,
  84. list1: [{
  85. name: '出单员扫码注册'
  86. }, {
  87. name: '扫码下载'
  88. }, ],
  89. current1: 0,
  90. headerStyle: {
  91. backgroundColor: '',
  92. backgroundImage: '',
  93. backgroundSize: '',
  94. backgroundPosition: '',
  95. boxShadow: ''
  96. // 其他样式属性...
  97. },
  98. }
  99. },
  100. onLoad() {
  101. this.recommendCode();
  102. this.codeDownload();
  103. this.orderissuer();
  104. this.$http.get('/sysMenuRecord/add?type=1&menuType=4')
  105. },
  106. computed: {
  107. ...mapState(['userInfo', 'sources']),
  108. },
  109. methods: {
  110. btn_click() {
  111. uni.navigateTo({
  112. url: '/pages/chat/chat'
  113. })
  114. },
  115. //页面返回按钮
  116. back() {
  117. uni.navigateBack({
  118. delta: 1, // 返回的页面数,如果是1表示返回上一页
  119. success: function() {}
  120. });
  121. },
  122. invitation() {
  123. this.navigate({
  124. url: '/pages/tools/poster/poster',
  125. }, "navigateTo", true)
  126. },
  127. recommendCode() {
  128. let id = this.userInfo.sysUser.id;
  129. this.recommendImg = QR.createQrCodeImg(this.$base.h5BaseUrl + "/#/pages/register/register?id=" + id, {
  130. size: parseInt(200) //二维码大小
  131. })
  132. },
  133. async codeDownload() {
  134. let id = this.userInfo.sysUser.id;
  135. let pageRequest = {
  136. pageNum: 1,
  137. pageSize: 50,
  138. columnFilters: {
  139. apptype: {
  140. name: "apptype",
  141. value: "apk",
  142. },
  143. appid: {
  144. name: "appid",
  145. value: "__UNI__D4FE29A",
  146. }
  147. }
  148. };
  149. let getquote = await this.$http.post('/sysVersion/findPage', pageRequest);
  150. let url = getquote.data.content[0].path;
  151. this.DownloadImg = QR.createQrCodeImg(url, {
  152. size: parseInt(200) //二维码大小
  153. })
  154. },
  155. orderissuer() {
  156. let id = this.userInfo.sysUser.id;
  157. this.orderissuerImg = QR.createQrCodeImg(this.$base.h5BaseUrl + "/#/pages/register/orderissuer?id=" + id, {
  158. size: parseInt(200) //二维码大小
  159. })
  160. },
  161. change(index) {
  162. this.current = index;
  163. },
  164. change1(index) {
  165. this.current1 = index;
  166. },
  167. getStaffList(staffType) {
  168. // 0未认证 1已认证 2全部
  169. this.navigate({
  170. url: '/pages/tools/addStaff/authentication' + staffType,
  171. }, "navigateTo", true);
  172. }
  173. }
  174. }
  175. </script>
  176. <style lang="scss" scoped>
  177. page {
  178. background-color: #F8FAFE;
  179. }
  180. .promotion {
  181. width: 100%;
  182. height: auto;
  183. background: #FFFFFF;
  184. box-shadow: 0px 4px 10px 0px #DAE3F4;
  185. border-radius: 6px;
  186. padding: 0 16px 16px;
  187. .invitation {
  188. width: 160px;
  189. height: 24px;
  190. background: rgba(255, 224, 178, 0.5);
  191. box-shadow: 2px 0px 1px 0px rgba(255, 255, 255, 0.6);
  192. border-radius: 12px;
  193. border: 1px solid #FFDCA7;
  194. color: #FB892B;
  195. margin-top: 10px;
  196. image {
  197. width: 16px;
  198. height: 16px;
  199. margin-right: 5px;
  200. }
  201. }
  202. }
  203. .Personnel {
  204. height: auto;
  205. width: 100%;
  206. background: #fff;
  207. background-image: url("/static/image/my/banner.png");
  208. background-size: 100% 100%;
  209. padding: 110px 24px 10px;
  210. .addMe {
  211. width: 70px;
  212. height: 70px;
  213. image {
  214. width: 100%;
  215. height: 100%;
  216. }
  217. }
  218. }
  219. .headers {
  220. position: fixed;
  221. top: 0;
  222. left: 0;
  223. height: auto;
  224. width: 100%;
  225. z-index: 999999;
  226. padding: 16px;
  227. padding-top: 50px;
  228. text {
  229. font-size: 18px;
  230. font-weight: bold;
  231. color: #000;
  232. }
  233. }
  234. .addStaffManage {
  235. height: 220upx;
  236. margin: 0 40upx;
  237. }
  238. .addStaffManage>view>view.icon {
  239. width: 110upx;
  240. height: 110upx;
  241. color: #FFFFFF;
  242. border-radius: 100%;
  243. margin-bottom: 10upx;
  244. font-size: 60upx;
  245. }
  246. .addStaffManage>view:nth-of-type(1)>view.icon {
  247. background-color: #78CBFF;
  248. }
  249. .addStaffManage>view:nth-of-type(2)>view.icon {
  250. background-color: #78FF7E;
  251. }
  252. .addStaffManage>view:nth-of-type(3)>view.icon {
  253. background-color: #FF9D4A;
  254. }
  255. </style>