myInfo.vue 24 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003
  1. <template>
  2. <view class="content">
  3. <u-loading-page loading-mode='spinner' image="/static/imgs/logo.png" iconSize='60' :loading='loading'></u-loading-page>
  4. <view v-show='!loading'>
  5. <view class="card-list content1">
  6. <view class="row" v-for="(item,index) in cardList" :key="index">
  7. <view class="title-name">
  8. {{item.cardBusiness}}
  9. </view>
  10. <view class="card-list-item"
  11. :style="item.currentBackground?'background:url('+item.currentBackground+');background-size:100% 100%':''">
  12. <view class="card-content style1" v-if="item.cuttentTemplate==1">
  13. <view class="left">
  14. <u--image :showLoading="true" :src="item.headSculpture?item.headSculpture:'/static/imgs/card/defaulthead.png'" width="66px" height="66px"
  15. shape="circle"></u--image>
  16. </view>
  17. <view class="right">
  18. <view class="row1">
  19. <text class="name">{{item.name}}</text>
  20. <text class="post">{{item.post}}</text>
  21. </view>
  22. <view class="row2">
  23. {{item.companyName}}
  24. </view>
  25. <view class="row3 flex">
  26. <u--image :showLoading="true" src="/static/imgs/card/address1.png" width="13px"
  27. height="16px"></u--image> <view class='icon-text'>{{ item.province }}{{ item.city }}{{ item.area }}</view>
  28. </view>
  29. <view class="row4 flex">
  30. <u--image :showLoading="true" src="/static/imgs/card/phone1.png" width="12px"
  31. height="13px"></u--image><view class='icon-text'>{{ item.phone }}</view>
  32. </view>
  33. <view class="row4 flex">
  34. <u--image :showLoading="true" src="/static/imgs/card/remark1.png" width="10px"
  35. height="12px"></u--image><view class='icon-text'>{{item.remark?item.remark:'--'}}</view>
  36. </view>
  37. <!-- <view class="">
  38. 备注
  39. </view> -->
  40. </view>
  41. </view>
  42. <view class="card-content style1 flex-between" v-if="item.cuttentTemplate==2">
  43. <view class="right">
  44. <view class="row1">
  45. <text class="name">{{item.name}}</text>
  46. <text class="post">{{item.post}}</text>
  47. </view>
  48. <view class="row2">
  49. {{item.companyName}}
  50. </view>
  51. <view class="row3 flex">
  52. <u--image :showLoading="true" src="/static/imgs/card/address3.png" width="13px"
  53. height="16px"></u--image><view class='icon-text'>{{ item.province }}{{ item.city }}{{ item.area }}</view>
  54. </view>
  55. <view class="row4 flex">
  56. <u--image :showLoading="true" src="/static/imgs/card/phone3.png" width="12px"
  57. height="13px"></u--image><view class='icon-text'>{{ item.phone }}</view>
  58. </view>
  59. <view class="row4 flex">
  60. <u--image :showLoading="true" src="/static/imgs/card/remark3.png" width="10px"
  61. height="12px"></u--image><view class='icon-text'>{{item.remark?item.remark:'--'}}</view>
  62. </view>
  63. <!-- <view class="">
  64. 备注
  65. </view> -->
  66. </view>
  67. <view class="left">
  68. <u--image :showLoading="true" :src="item.headSculpture" width="66px" height="66px"
  69. shape="circle" v-if="item.headSculpture"></u--image>
  70. <u--image :showLoading="true" src="/static/imgs/card/defaulthead.png" width="66px"
  71. height="66px" shape="circle" v-else></u--image>
  72. </view>
  73. </view>
  74. <view class="card-content style2" v-if="item.cuttentTemplate==3">
  75. <view class="top">
  76. <u--image :showLoading="true" :src="item.headSculpture" width="66px" height="66px"
  77. shape="circle" v-if="item.headSculpture"></u--image>
  78. <u--image :showLoading="true" src="/static/imgs/card/defaulthead.png" width="66px"
  79. height="66px" shape="circle" v-else></u--image>
  80. </view>
  81. <view class="bottom flex">
  82. <view class="left">
  83. <view class="row1">
  84. <text class="name">{{item.name}}</text>
  85. <text class="post">{{item.post}}</text>
  86. </view>
  87. <view class="row2">
  88. {{item.companyName}}
  89. </view>
  90. </view>
  91. <view class="right">
  92. <view class="row3 flex">
  93. <u--image :showLoading="true" src="/static/imgs/card/address1.png" width="13px"
  94. height="16px"></u--image><view class='icon-text'>{{ item.province }}{{ item.city }}{{ item.area }}</view>
  95. </view>
  96. <view class="row4 flex">
  97. <u--image :showLoading="true" src="/static/imgs/card/phone1.png" width="12px"
  98. height="13px"></u--image><view class='icon-text'>{{ item.phone }}</view>
  99. </view>
  100. <view class="row4 flex">
  101. <u--image :showLoading="true" src="/static/imgs/card/remark1.png" width="10px"
  102. height="12px"></u--image><view class='icon-text'>{{item.remark?item.remark:'--'}}</view>
  103. </view>
  104. </view>
  105. </view>
  106. </view>
  107. <view class="card-content style2" v-if="item.cuttentTemplate==4">
  108. <view class="top">
  109. <view class="row1">
  110. <text class="name">{{item.name}}</text>
  111. <text class="post">{{item.post}}</text>
  112. </view>
  113. <view class="row2">
  114. {{item.companyName}}
  115. </view>
  116. </view>
  117. <view class="bottom flex">
  118. <view class="left">
  119. <u--image :showLoading="true" :src="item.headSculpture" width="66px" height="66px"
  120. shape="circle" v-if="item.headSculpture"></u--image>
  121. <u--image :showLoading="true" src="/static/imgs/card/defaulthead.png" width="66px"
  122. height="66px" shape="circle" v-else></u--image>
  123. </view>
  124. <view class="right">
  125. <view class="row3 flex">
  126. <u--image :showLoading="true" src="/static/imgs/card/address2.png" width="13px"
  127. height="16px"></u--image><view class='icon-text'>{{ item.province }}{{ item.city }}{{ item.area }}</view>
  128. </view>
  129. <view class="row4 flex">
  130. <u--image :showLoading="true" src="/static/imgs/card/phone2.png" width="12px"
  131. height="13px"></u--image><view class='icon-text'>{{ item.phone }}</view>
  132. </view>
  133. <view class="row4 flex">
  134. <u--image :showLoading="true" src="/static/imgs/card/remark2.png" width="10px"
  135. height="12px"></u--image><view class='icon-text'>{{item.remark?item.remark:'--'}}</view>
  136. </view>
  137. </view>
  138. </view>
  139. </view>
  140. <view class="car-bottom flex">
  141. <view class="left">
  142. <image src="../../static/imgs/card/home.png" mode="widthFix" style="width: 32rpx;height: auto;"
  143. @click="toHome(item)"></image>
  144. <image src="../../static/imgs/card/share.png" mode="widthFix" style="width: 35rpx;height: auto;"
  145. @click="share(item)"></image>
  146. <image src="../../static/imgs/card/ewm.png" mode="widthFix" style="width: 32rpx;height: auto;"
  147. @click="showCode(item)"></image>
  148. </view>
  149. <view class="right">
  150. <text class="text" @click="topMarking(item)">置顶</text>
  151. <text class="text" @click="del(item.id)">删除</text>
  152. <text class="text" @click="toEditCard(item)">编辑</text>
  153. </view>
  154. <!-- <u-button text="置顶" @click="topMarking(item)" throttle-time='1000'></u-button> -->
  155. <!-- <button @click="$u.debounce(topMarking, 500)">置顶</button> -->
  156. <!-- <button @click="$u.debounce(topMarking(item), 500)">置顶</button> -->
  157. <!-- <u-button text="删除" @click="del(item.id)" throttle-time='1000'></u-button> -->
  158. <!-- <button @click="toEditCard(item)">编辑</button> -->
  159. </view>
  160. </view>
  161. </view>
  162. </view>
  163. <view class="upload flex flex-all-center" @click="addCard">
  164. <view class="solids flex flex-all-center">
  165. <image src="../../static/imgs/card/add.png" mode="widthFix" style="width: 148rpx;height: auto;"></image>
  166. <text class='text'>添加新名片</text>
  167. </view>
  168. </view>
  169. </view>
  170. <u-toast ref="uToast"></u-toast>
  171. <u-popup :round='10' :show="isShowDel" @close="isShowDel=false" mode="center">
  172. <view class="del-style">
  173. <text class="title">删除名片自动退出关联得圈子,确定删除?</text>
  174. <view class="">
  175. <view @click='radiovalue=1' class="flex align-item-center radio-wrap">
  176. <image style='width:13px;height:13px;margin-right:10rpx;' :src="radiovalue==1?'../../static/imgs/mySet/checked.png':'../../static/imgs/mySet/not-checked.png'" mode=""></image>
  177. <view class="">仅从自己名片列表删除</view>
  178. </view>
  179. <view @click='radiovalue=2' class="flex align-item-center radio-wrap">
  180. <image style='width:13px;height:13px;margin-right:10rpx;' :src="radiovalue==2?'../../static/imgs/mySet/checked.png':'../../static/imgs/mySet/not-checked.png'" mode=""></image>
  181. <view class="">从所有拥有此名片用户列表删除</view>
  182. </view>
  183. </view>
  184. <view class="flex footer">
  185. <view class="cancel" @click="isShowDel=false">
  186. 取消
  187. </view>
  188. <view class="confirm" @click="delCard">
  189. 删除
  190. </view>
  191. </view>
  192. </view>
  193. </u-popup>
  194. <u-popup :show="isShowCode" @close="isShowCode=false" mode="center" :round='10'>
  195. <image style='margin:10px;height: auto;' :src="selectCode" mode="widthFix"></image>
  196. </u-popup>
  197. <u-popup :show="popupshow" :closeOnClickOverlay='true' :overlayOpacity='0.4' @close='handleHiddenShare'
  198. :round="10" mode="bottom">
  199. <view>
  200. <view class="share-content">
  201. <view class="block" @click="toUrl()">
  202. <button class="moment">
  203. <view class="iconfont icon-pengyouquan"></view>
  204. <view>分享朋友圈</view>
  205. </button>
  206. </view>
  207. <view class="block">
  208. <button class="shareBtn" type="default" data-name="shareBtn" open-type="share">
  209. <view class="iconfont icon-weixin"></view>
  210. <view>分享微信好友</view>
  211. </button>
  212. </view>
  213. </view>
  214. </view>
  215. </u-popup>
  216. <!-- 生成图片 -->
  217. <poster :data="canvasData" background-color="#FFF" :width='750' :height='420' @on-success="posterSuccess"
  218. ref="poster" @on-error="posterError"></poster>
  219. <point-share @close='showShare=false' :show='showShare'></point-share>
  220. </view>
  221. </template>
  222. <script>
  223. import Poster from '../../components/zhangyuhao-poster/Poster.vue';
  224. import PointShare from '../../components/point-share/index.vue';
  225. var that;
  226. export default {
  227. components: {
  228. Poster,
  229. PointShare
  230. },
  231. data() {
  232. return {
  233. isShowCode: false,
  234. selectCode: '',
  235. id: '',
  236. showShare:false,
  237. popupshow:false,
  238. radiovalue: 1,
  239. loading:true,
  240. isShowDel: false,
  241. cardList: [],
  242. canvasData:{},
  243. clicknum:0,
  244. poster:''
  245. };
  246. },
  247. onLoad() {
  248. that = this
  249. this.userInfo = uni.getStorageSync("userInfo")
  250. },
  251. onShow() {
  252. this.init()
  253. },
  254. onShareAppMessage(res) {
  255. console.log(res, this.popupshow)
  256. let that = this;
  257. //生成名片图片
  258. let imageUrl = this.poster
  259. console.log("imageUrl", imageUrl)
  260. if (res.from === 'button') {
  261. let path = `/pages/cardHolder/scanCodeAddCard?id=${that.currectData.id}`
  262. return {
  263. title: this.popupshow ? `${that.currectData.name}分享的名片~` : '电子名片',
  264. path: path,
  265. imageUrl: this.popupshow ? imageUrl : '',
  266. };
  267. }
  268. if (res.from === 'menu') {
  269. return {
  270. title: '我的名片',
  271. path: '/pages/tabBarPro/index/index',
  272. imageUrl: this.popupshow ? imageUrl : ''
  273. };
  274. }
  275. },
  276. methods: {
  277. toUrl(){
  278. this.popupshow=false
  279. this.showShare=true
  280. },
  281. handleHiddenShare() {
  282. this.popupshow = false
  283. },
  284. posterError(err) {
  285. console.log(err)
  286. uni.hideLoading()
  287. },
  288. posterSuccess(url) {
  289. console.log("hahahah", url)
  290. // 生成成功,会把临时路径在这里返回
  291. this.poster = url;
  292. uni.hideLoading()
  293. this.popupshow = true
  294. console.log(url)
  295. },
  296. showCode(val) {
  297. this.selectCode = val.qrCodeMyself
  298. this.isShowCode = true
  299. },
  300. share(item) {
  301. uni.showLoading({
  302. title: '加载中',
  303. mask: true
  304. })
  305. this.currectData = item
  306. var data = [{
  307. type: 'image',
  308. path: this.currectData.currentBackground,
  309. use: 'bg',
  310. x: -10,
  311. y: 0,
  312. width: 530,
  313. height: 325
  314. },
  315. {
  316. type: 'image',
  317. path: this.currectData.headSculpture?this.currectData.headSculpture:'../../static/imgs/card/defaulthead.png',
  318. shape: 'circle',
  319. use: 'head',
  320. imageType:this.currectData.headSculpture?'wl':'bd',
  321. x: 30,
  322. y: 30,
  323. width: 100,
  324. height: 100
  325. },
  326. {
  327. type: 'text',
  328. text: this.currectData.name,
  329. use: 'name',
  330. x: 150,
  331. y: 50,
  332. size: 24,
  333. color: '#000'
  334. },
  335. {
  336. type: 'text',
  337. text: this.currectData.post,
  338. use: 'post',
  339. x: 240,
  340. y: 55,
  341. size: 18,
  342. color: '#666666'
  343. },
  344. {
  345. type: 'text',
  346. text: this.currectData.companyName,
  347. use: 'companyName',
  348. x: 150,
  349. y: 95,
  350. size: 18,
  351. color: '#000'
  352. },
  353. {
  354. type: 'image',
  355. path: '../../static/imgs/card/address1.png',
  356. use: 'address-icon',
  357. x: 145,
  358. y: 130,
  359. width: 15,
  360. height: 20
  361. },
  362. {
  363. type: 'textarea',
  364. text: this.currectData.province + this.currectData.city + this.currectData.area + this
  365. .currectData.detailedAddress,
  366. lineSpace: 1,
  367. width: 320,
  368. use: 'address',
  369. x: 175,
  370. y: 135,
  371. size: 14,
  372. color: '#000'
  373. },
  374. {
  375. type: 'image',
  376. path: '../../static/imgs/card/phone1.png',
  377. use: 'phone-icon',
  378. x: 145,
  379. y: 163,
  380. width: 16,
  381. height: 16
  382. },
  383. {
  384. type: 'text',
  385. text: this.currectData.phone,
  386. use: 'phone',
  387. x: 175,
  388. y: 167,
  389. size: 14,
  390. color: '#000'
  391. },
  392. {
  393. type: 'image',
  394. path: '../../static/imgs/card/remark1.png',
  395. use: 'remark-icon',
  396. x: 145,
  397. y: 197,
  398. width: 13,
  399. height: 16
  400. },
  401. {
  402. type: 'textarea',
  403. text: this.currectData.remark ? this.currectData.remark : '单击添加备注',
  404. use: 'remark',
  405. lineSpace: 2,
  406. width: 200,
  407. x: 175,
  408. y: 200,
  409. size: 13,
  410. color: '#000'
  411. },
  412. {
  413. type: 'image',
  414. path: '../../static/imgs/card/bgc1.png',
  415. use: 'bg1',
  416. x: 3,
  417. y: 243,
  418. width: 240,
  419. height: 67
  420. },
  421. {
  422. type: 'image',
  423. path: '../../static/imgs/card/bgc2.png',
  424. use: 'bg2',
  425. x: 225,
  426. y: 243,
  427. width: 278,
  428. height: 67
  429. },
  430. {
  431. type: 'image',
  432. path: '../../static/imgs/card/home.png',
  433. use: 'home',
  434. x: 30,
  435. y: 260,
  436. width: 33,
  437. height: 33
  438. },
  439. {
  440. type: 'image',
  441. path: '../../static/imgs/card/share.png',
  442. use: 'share',
  443. x: 90,
  444. y: 263,
  445. width: 33,
  446. height: 28
  447. },
  448. {
  449. type: 'image',
  450. path: '../../static/imgs/card/ewm.png',
  451. use: 'code',
  452. x: 150,
  453. y: 263,
  454. width: 32,
  455. height: 32
  456. },
  457. {
  458. type: 'text',
  459. text: '置顶',
  460. use: 'top',
  461. x: 280,
  462. y: 265,
  463. size: 24,
  464. color: '#fff'
  465. },
  466. {
  467. type: 'text',
  468. text: '删除',
  469. use: 'del',
  470. x: 350,
  471. y: 265,
  472. size: 24,
  473. color: '#fff'
  474. },
  475. {
  476. type: 'text',
  477. text: '编辑',
  478. use: 'edit',
  479. x: 420,
  480. y: 265,
  481. size: 24,
  482. color: '#fff'
  483. },
  484. ]
  485. console.log(this.currectData.cuttentTemplate, 111111)
  486. for (var i = 0; i < data.length; i++) {
  487. switch (this.currectData.cuttentTemplate) {
  488. case '2':
  489. if (data[i].use === 'name' ||
  490. data[i].use === 'companyName' ||
  491. data[i].use === 'address-icon' ||
  492. data[i].use === 'phone-icon' ||
  493. data[i].use === 'remark-icon') {
  494. data[i].x = 30
  495. }
  496. if (data[i].use === 'address-icon') {
  497. data[i].path = '../../static/imgs/card/address3.png'
  498. }
  499. if (data[i].use === 'phone-icon') {
  500. data[i].path = '../../static/imgs/card/phone3.png'
  501. }
  502. if (data[i].use === 'remark-icon') {
  503. data[i].path = '../../static/imgs/card/remark3.png'
  504. }
  505. if (data[i].use === 'post') {
  506. data[i].x = 100
  507. }
  508. if (data[i].use === 'address' ||
  509. data[i].use === 'phone' ||
  510. data[i].use === 'remark') {
  511. data[i].x = 60
  512. }
  513. if (data[i].use == 'head') {
  514. data[i].x = 370
  515. }
  516. break;
  517. case '3':
  518. if (data[i].use === 'name') {
  519. data[i].x = 30
  520. data[i].y = 150
  521. }
  522. if (data[i].use === 'companyName') {
  523. data[i].x = 30
  524. data[i].y = 180
  525. }
  526. if (data[i].use === 'post') {
  527. data[i].x = 100
  528. data[i].y = 153
  529. }
  530. if (data[i].use === 'address-icon' ||
  531. data[i].use === 'phone-icon' ||
  532. data[i].use === 'remark-icon') {
  533. data[i].x = 170
  534. }
  535. if (data[i].use === 'address-icon') {
  536. data[i].y = 150
  537. }
  538. if (data[i].use === 'address') {
  539. data[i].y = 155;
  540. data[i].width = 300
  541. }
  542. if (data[i].use === 'phone-icon') {
  543. data[i].y = 180
  544. }
  545. if (data[i].use === 'phone') {
  546. data[i].y = 183
  547. }
  548. if (data[i].use === 'remark-icon') {
  549. data[i].y = 210
  550. }
  551. if (data[i].use === 'remark') {
  552. data[i].y = 212
  553. }
  554. if (data[i].use === 'address' ||
  555. data[i].use === 'phone' ||
  556. data[i].use === 'remark') {
  557. data[i].x = 190
  558. }
  559. break;
  560. case '4':
  561. if (data[i].use === 'name' ||
  562. data[i].use === 'companyName') {
  563. data[i].x = 30
  564. }
  565. if (data[i].use === 'companyName') {
  566. data[i].y = 90
  567. }
  568. if (data[i].use === 'post') {
  569. data[i].x = 100
  570. }
  571. if (data[i].use == 'head') {
  572. data[i].x = 25
  573. data[i].y = 120
  574. }
  575. if (data[i].use === 'address-icon') {
  576. data[i].path = '../../static/imgs/card/address2.png'
  577. }
  578. if (data[i].use === 'phone-icon') {
  579. data[i].path = '../../static/imgs/card/phone2.png'
  580. }
  581. if (data[i].use === 'remark-icon') {
  582. data[i].path = '../../static/imgs/card/remark2.png'
  583. }
  584. if (data[i].use === 'address-icon' ||
  585. data[i].use === 'phone-icon' ||
  586. data[i].use === 'remark-icon') {
  587. data[i].x = 170
  588. }
  589. if (data[i].use === 'address') {
  590. data[i].width = 300
  591. }
  592. if (data[i].use === 'address' ||
  593. data[i].use === 'phone' ||
  594. data[i].use === 'remark') {
  595. data[i].x = 190
  596. }
  597. break;
  598. default:
  599. }
  600. }
  601. this.canvasData = {
  602. clicknum: this.clicknum++,
  603. list: data,
  604. page:'myInfo'
  605. }
  606. console.log(1111111)
  607. },
  608. toHome(item) {
  609. uni.navigateTo({
  610. url: "/pages/mySet/myHome?id=" + item.personalHomeId
  611. })
  612. },
  613. radioChange(n) {
  614. console.log('radioChange', n);
  615. },
  616. init() {
  617. var that = this
  618. this.$request.baseRequest('admin.unimall.cardManagementInfo', 'list', {
  619. commonId: this.userInfo.id
  620. }, failres => {
  621. this.$refs.uToast.show({
  622. type: 'error',
  623. message: failres.errmsg,
  624. })
  625. uni.hideLoading()
  626. }).then(res => {
  627. this.cardList = res.data.items
  628. setTimeout(()=>{
  629. that.loading=false
  630. },1500)
  631. })
  632. },
  633. toEditCard(val) {
  634. uni.navigateTo({
  635. url: "/pages/mySet/editCard?itemVal=" + JSON.stringify(val)
  636. })
  637. },
  638. delCard() {
  639. let _data = {}
  640. if (this.radiovalue == 1) {
  641. _data = {
  642. id: this.id
  643. }
  644. } else {
  645. _data = {
  646. id: this.id,
  647. deleteCondition: 1
  648. }
  649. }
  650. that.$request.baseRequest('admin.unimall.cardManagementInfo', 'delete', _data, failres => {
  651. this.$refs.uToast.show({
  652. type: 'error',
  653. message: failres.errmsg,
  654. })
  655. uni.hideLoading()
  656. }).then(res => {
  657. this.isShowDel = false
  658. this.$refs.uToast.show({
  659. type: 'success',
  660. message: '删除成功!',
  661. })
  662. this.init()
  663. })
  664. },
  665. del(val) {
  666. this.id = val
  667. this.isShowDel = true
  668. },
  669. addCard() {
  670. uni.navigateTo({
  671. url: "/pages/mySet/newCard"
  672. })
  673. },
  674. topMarking(val) {
  675. that.$request.baseRequest('admin.unimall.cardManagementInfo', 'top', {
  676. cardManagementInfo: JSON.stringify({
  677. id: val.id
  678. })
  679. }, failres => {
  680. this.$refs.uToast.show({
  681. type: 'error',
  682. message: failres.errmsg,
  683. })
  684. uni.hideLoading()
  685. }).then(res => {
  686. this.$refs.uToast.show({
  687. type: 'success',
  688. message: '置顶成功!',
  689. })
  690. this.init()
  691. })
  692. }
  693. }
  694. }
  695. </script>
  696. <style lang="scss" scoped>
  697. .content {
  698. padding-bottom: 40rpx;
  699. }
  700. .card-content {
  701. width: 100%;
  702. }
  703. .content1 {
  704. .icon-text{
  705. margin-left:10rpx;
  706. }
  707. .style1 {
  708. display: flex;
  709. padding: 20rpx 30rpx;
  710. width: 85%;
  711. margin-bottom: 70rpx;
  712. .left {
  713. width: 132rpx;
  714. height: 132rpx;
  715. border-radius: 50%;
  716. }
  717. .right {
  718. margin-left: 40rpx;
  719. .row1 {
  720. .name {
  721. font-size: 38rpx;
  722. font-weight: bold;
  723. color: #040000;
  724. margin-right: 20rpx;
  725. }
  726. .post {
  727. font-size: 26rpx;
  728. font-weight: 500;
  729. color: #666666;
  730. }
  731. }
  732. .row2 {
  733. margin-top: 20rpx;
  734. font-size: 24rpx;
  735. font-weight: bold;
  736. color: #323333;
  737. }
  738. .row3,.row4 {
  739. margin-top: 30rpx;
  740. font-size: 24rpx;
  741. font-weight: 500;
  742. color: #323333;
  743. }
  744. }
  745. }
  746. .style2 {
  747. padding: 30rpx;
  748. margin-bottom: 70rpx;
  749. .top {
  750. .row1 {
  751. .name {
  752. font-size: 38rpx;
  753. font-weight: bold;
  754. color: #040000;
  755. margin-right: 20rpx;
  756. }
  757. .post {
  758. font-size: 26rpx;
  759. font-weight: 500;
  760. color: #666666;
  761. }
  762. }
  763. .row2 {
  764. margin-top: 20rpx;
  765. font-size: 24rpx;
  766. font-weight: bold;
  767. color: #323333;
  768. }
  769. }
  770. .bottom {
  771. margin-top: 20rpx;
  772. .left {
  773. margin-right: 40rpx;
  774. .row1 {
  775. .name {
  776. font-size: 38rpx;
  777. font-weight: bold;
  778. color: #040000;
  779. margin-right: 20rpx;
  780. }
  781. .post {
  782. font-size: 26rpx;
  783. font-weight: 500;
  784. color: #666666;
  785. }
  786. }
  787. .row2 {
  788. margin-top: 20rpx;
  789. font-size: 24rpx;
  790. font-weight: bold;
  791. color: #323333;
  792. }
  793. }
  794. .right {
  795. .row1,
  796. .row2 {
  797. font-size: 24rpx;
  798. font-weight: 500;
  799. color: #323333;
  800. }
  801. .row2 {
  802. margin-top: 20rpx;
  803. }
  804. .row3,.row4 {
  805. margin-top: 30rpx;
  806. font-size: 24rpx;
  807. font-weight: 500;
  808. color: #323333;
  809. }
  810. }
  811. }
  812. }
  813. }
  814. .card-list {
  815. padding: 0 20rpx;
  816. .title-name {
  817. font-weight: bold;
  818. color: #19191A;
  819. margin: 20rpx 0;
  820. }
  821. }
  822. .card-list-item {
  823. width: calc(100% + 40rpx);
  824. left: -20rpx;
  825. position: relative;
  826. border-radius: 30rpx;
  827. padding: 40rpx;
  828. box-sizing: border-box;
  829. .car-bottom {
  830. position: absolute;
  831. bottom: 22rpx;
  832. left: 20rpx;
  833. width: calc(100% - 40rpx);
  834. .left {
  835. position: absolute;
  836. padding: 20rpx 0;
  837. width: 310rpx;
  838. box-sizing: border-box;
  839. display: flex;
  840. justify-content: space-evenly;
  841. background: url("../../static/imgs/card/bgc1.png") no-repeat center;
  842. background-size: 100% 100%;
  843. }
  844. .right {
  845. font-size: 26rpx;
  846. padding: 20rpx 0;
  847. position: relative;
  848. right: -278rpx;
  849. width: calc(100vw - 320rpx);
  850. box-sizing: border-box;
  851. display: flex;
  852. justify-content: space-evenly;
  853. background: url("../../static/imgs/card/bgc2.png") no-repeat center;
  854. background-size: 100% 100%;
  855. .text {
  856. color: #fff;
  857. }
  858. }
  859. }
  860. .left {
  861. width: 30%;
  862. .top {
  863. margin-bottom: 20rpx;
  864. }
  865. .img {
  866. width: 80%;
  867. }
  868. .bottom {}
  869. }
  870. .right {
  871. .row1 {
  872. .line {
  873. width: 1px;
  874. height: 20px;
  875. margin: 0 20rpx;
  876. background: black;
  877. }
  878. }
  879. }
  880. }
  881. .upload {
  882. background-color: #fff;
  883. margin: 20rpx;
  884. border-radius: 20rpx;
  885. padding: 76rpx;
  886. .solids {
  887. flex-direction: column;
  888. .text {
  889. margin-top: 20rpx;
  890. font-size: 26rpx;
  891. font-weight: 500;
  892. color: #666666;
  893. }
  894. }
  895. }
  896. .share-content {
  897. display: flex;
  898. padding: 20rpx;
  899. justify-content: center;
  900. font-size: 24rpx;
  901. button {
  902. background: transparent;
  903. line-height: 1.5;
  904. }
  905. button:after {
  906. border: none;
  907. }
  908. }
  909. .icon-pengyouquan,.icon-weixin{
  910. font-size:50px;
  911. color:#33CC00;
  912. }
  913. .del-style{
  914. padding:40rpx 40rpx 160rpx 40rpx;
  915. font-size:32rpx;
  916. position:relative;
  917. .title{
  918. color:#1A1A1A;
  919. font-size:32rpx;
  920. font-weight: bold;
  921. }
  922. .radio-wrap{
  923. padding:23rpx;
  924. border-radius:10rpx;
  925. background:#F5F5F5;
  926. margin:20rpx 0;
  927. }
  928. .cancel,.confirm{
  929. width: 50%;
  930. text-align: center;
  931. padding: 35rpx 0;
  932. border-top: 1px solid #ccc;
  933. font-size:36rpx;
  934. }
  935. .footer{
  936. position: absolute;
  937. bottom: 0px;
  938. width: 100%;
  939. left: 0;
  940. }
  941. .cancel{
  942. border-right: 1px solid #ccc;
  943. }
  944. .confirm{
  945. color:#4977FC;
  946. }
  947. }
  948. </style>