list.vue 30 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794
  1. <template>
  2. <view>
  3. <!-- 第一种样式 人员管理-->
  4. <block v-if="datainfo.length>0">
  5. <block v-if="type=='mycar'">
  6. <view class="carlist pr" v-for="(ite,idx) in datainfo" :key="idx" @click="getDetail(ite.carId)"
  7. :data-idx="idx"
  8. @touchstart="drawStart" @touchmove="drawMove" @touchend="drawEnd" :style="'right:'+ite.right+'px'"
  9. >
  10. <view class="delleft" style="padding: 0 24rpx;">
  11. <view class="carltop flexc">
  12. <view class="flex1">
  13. <view class="tit mb6 flexc" :class="ite.vehicleEnergy=='新能源'?'co16':'co01'">{{ite.plateNumber}}
  14. <text class="cir"></text>
  15. <text v-if="ite.vehicleColour">{{ite.vehicleColour}}</text>
  16. </view>
  17. <view class="txt flexc">
  18. {{ite.vehicleBrand}}
  19. <view class="txtbtn flexcc" v-if="ite.vehicleEnergy=='新能源'">{{ite.vehicleEnergy}}</view>
  20. <!-- <view class="txtbtn flexcc" v-if="ite.vehicleType==2">新能源</view> -->
  21. </view>
  22. </view>
  23. <image :src="carb" class="carb" v-if="ite.vehicleEnergy=='新能源'"></image>
  24. <image :src="cara" class="cara" v-else></image>
  25. </view>
  26. <view class="carlf">
  27. <view class="clflist">发动机号码 :{{ite.engineNumber}}</view>
  28. <view class="clflist">车辆识别代号:{{ite.identificationNumber}}</view>
  29. <view class="flexc">
  30. <view class="clflist w50">注册日期:{{ite.registrationDate}}</view>
  31. <view class="clflist w50">发证日期:{{ite.issueDate}}</view>
  32. </view>
  33. </view>
  34. </view>
  35. <view class="spdel" v-if="ite.right>0&&checkPermi(['wuYe:car:remove'])" @click.stop="getDelFn(ite.carId)">删除</view>
  36. </view>
  37. </block>
  38. <!-- 地址 -->
  39. <block v-if="type=='address'">
  40. <view class="adrlist flexc" :class="ite.isdefault?'act':''" v-for="(ite,idx) in datainfo" :key="idx">
  41. <view class="adrl flex1">
  42. <view class="tit mb5">安徽省 合肥市 蜀山区 高新技术产业开发区</view>
  43. <view class="txt mb5">幸福大街88号幸福小区12#1304</view>
  44. <view class="txts flexc">袁玥 <text class="ml8">18305687768</text>
  45. <text class="ml8 btns" v-if="ite.isdefault">默认</text>
  46. <text class="ml8 btns" v-if="ite.isuser">最近使用</text>
  47. </view>
  48. </view>
  49. <view class="adrr flexcc">
  50. <image :src="edit"></image>
  51. </view>
  52. </view>
  53. </block>
  54. <!-- 快递 -->
  55. <block v-if="type=='delivery'">
  56. <view class="kdlists flex" v-for="(ite,idx) in datainfo" :key="idx" @click="getDetail">
  57. <image :src="noiconpimg" class="kdll"></image>
  58. <view class="kdlr over flex1">
  59. <view class="over tit">已发货</view>
  60. <view class="over tits">包裹正在等待揽收</view>
  61. <view class="over txt">淘宝 | 白色晚礼服平时可穿毕业洋装小白裙…</view>
  62. </view>
  63. </view>
  64. </block>
  65. <!-- 步骤条 -->
  66. <block v-if="type=='kdstep'">
  67. <view class="hfstep">
  68. <view class="hfslist flex">
  69. <view class="limg flexccc">
  70. <image :src="cira" class="imga"></image>
  71. </view>
  72. <view class="flex1">
  73. <view class="hfstit co01">运输中 11-25 12:24</view>
  74. <view class="hfstxt co27">【合肥市】快件已到达 合肥蜀山新产业园</view>
  75. </view>
  76. </view>
  77. <view class="hfslist flex">
  78. <view class="limg flexccc">
  79. <image :src="cirb" class="imgb"></image>
  80. </view>
  81. <view class="flex1">
  82. <view class="hfstit">11-25 07:23</view>
  83. <view class="hfstxt">【合肥市】快件已发往 合肥蜀山新产业园</view>
  84. </view>
  85. </view>
  86. <view class="hfslist flex">
  87. <view class="limg flexccc">
  88. <image :src="cirb" class="imgb"></image>
  89. </view>
  90. <view class="flex1">
  91. <view class="hfstit">11-25 07:20</view>
  92. <view class="hfstxt">【合肥市】快件已到达 合肥转运中心</view>
  93. </view>
  94. </view>
  95. </view>
  96. </block>
  97. <!-- 房屋管理 -->
  98. <block v-if="type=='comehouse'">
  99. <view class="carlist houselist" v-for="(ite,idx) in datainfo" :key="idx" @click="getDetail(ite.houseId)">
  100. <view class="ctop flexc">
  101. <image :src="house" class="imgs" v-if="ite.houseStatus==1"></image>
  102. <image :src="housea" class="imgs" v-if="ite.houseStatus==4"></image>
  103. <image :src="houseb" class="imgs" v-if="ite.houseStatus==2"></image>
  104. <image :src="housec" class="imgs" v-if="ite.houseStatus==3"></image>
  105. <view class="tit">{{ite.communityName}}{{ite.detailedAddress}}</view>
  106. <!-- view class="btn btnbga">预约</view>
  107. <view class="btn btnbgb">已来访</view>
  108. <view class="btn btnbgc">待来访</view> -->
  109. <image :src="hedit" class="hedit"></image>
  110. <view class="flex1"></view>
  111. <view class="txt ca" v-if="ite.houseStatus==1">自住</view>
  112. <view class="txt cb" v-if="ite.houseStatus==4">出租</view>
  113. <view class="txt cc" v-if="ite.houseStatus==2">空闲</view>
  114. <view class="txt co6" v-if="ite.houseStatus==3">代售</view>
  115. </view>
  116. <view class="clists">
  117. <view class="clist"><view class="tit">房屋坐落</view>{{ite.location}}</view>
  118. <view class="flexc">
  119. <view class="clist w50"><view class="tit">房屋所属</view>{{ite.ownerName}}</view>
  120. <view class="clist w50"><view class="tit">建筑面积</view>{{ite.area}}m²</view>
  121. </view>
  122. <view class="flexc">
  123. <view class="clist w50"><view class="tit">有无车位</view>{{ite.hasParkingSpace=='Y'?'有':'无'}}</view>
  124. </view>
  125. <image :src="sha" class="shimg"></image>
  126. <!-- <image :src="shb" class="shimg"></image> -->
  127. </view>
  128. </view>
  129. </block>
  130. <!-- 居住人员 -->
  131. <block v-if="type=='authen'">
  132. <view class="carlist houselist" v-for="(ite,idx) in datainfo" :key="idx" @click="getDetail(ite.residentId)">
  133. <view class="ctop flexc">
  134. <!-- <image :src="house" class="imgs" v-if="ite.houseStatus==1"></image>
  135. <image :src="housea" class="imgs" v-if="ite.houseStatus==4"></image>
  136. <image :src="houseb" class="imgs" v-if="ite.houseStatus==2"></image>
  137. <image :src="housec" class="imgs" v-if="ite.houseStatus==3"></image> -->
  138. <view class="tit">{{kaType(ite.tenantId,voList)}}</view>
  139. <!-- view class="btn btnbga">预约</view>
  140. <view class="btn btnbgb">已来访</view>
  141. <view class="btn btnbgc">待来访</view> -->
  142. <image :src="hedit" class="hedit"></image>
  143. <image :src="hdel" class="hdel" v-if="ite.examine!=2&&checkPermi(['wuYe:residentInfo:remove'])" @click.stop="getDelFn(ite)"></image>
  144. <view class="flex1"></view>
  145. <view class="txt ca" >{{kaType(ite.residentType,rylxList)}}</view>
  146. <!-- <view class="txt cb" v-if="ite.houseStatus==4">出租</view>
  147. <view class="txt cc" v-if="ite.houseStatus==2">空闲</view>
  148. <view class="txt co6" v-if="ite.houseStatus==3">代售</view> -->
  149. </view>
  150. <view class="clists">
  151. <view class="clist"><view class="tit">姓名</view>{{ite.residentName}}</view>
  152. <view class="clist"><view class="tit">联系方式</view>{{ite.residentPhone}}</view>
  153. <block v-if="ite.residentType!=3">
  154. <image :src="sha" class="shimg" v-if="ite.examine==1"></image>
  155. <image :src="shb" class="shimg" v-if="ite.examine==3"></image>
  156. </block>
  157. </view>
  158. </view>
  159. </block>
  160. <!-- 人员管理 -->
  161. <block v-if="type=='people'">
  162. <view class="carlist peolist" v-for="(ite,idx) in datainfo" :key="idx">
  163. <view class="ctop flexc">
  164. <image :src="house" class="imgs" v-if="ite.houseStatus==1"></image>
  165. <image :src="housea" class="imgs" v-if="ite.houseStatus==4"></image>
  166. <image :src="houseb" class="imgs" v-if="ite.houseStatus==2"></image>
  167. <image :src="housec" class="imgs" v-if="ite.houseStatus==3"></image>
  168. <!-- <view class="tit">{{ite.detailedAddress}}</view> -->
  169. <view class="tit">{{ite.communityName}}</view>
  170. <view class="flex1"></view>
  171. <view class="txt ca" v-if="ite.houseStatus==1">自住</view>
  172. <view class="txt cb" v-if="ite.houseStatus==4">出租</view>
  173. <view class="txt cc" v-if="ite.houseStatus==2">空闲</view>
  174. <view class="txt co6" v-if="ite.houseStatus==3">代售</view>
  175. </view>
  176. <view class="plists">
  177. <block v-for="(aite,aidx) in ite.residentInfoList">
  178. <!-- v-if="aidx==0" -->
  179. <view class="flexc pr mb12" :key="`peo${aidx}`" @click="getDetail(aite.residentId)"
  180. :data-idx="idx" :data-aidx="aidx" data-type="peo"
  181. @touchstart="drawStart" @touchmove="drawMove" @touchend="drawEnd" :style="'right:'+aite.right+'px'"
  182. >
  183. <view class="plist flexc">
  184. <image :src="man" class="head" v-if="aite.residentGender==1"></image>
  185. <image :src="woman" class="head" v-else></image>
  186. <view class="flex1">
  187. <view class="ptit">{{aite.residentName}}
  188. <view class="btn btnc ml10" v-if="aite.isHouseholder=='Y'">户主</view>
  189. </view>
  190. <view class="ptxt">身份证号 | {{aite.residentIdCard}}</view>
  191. <view class="flexc">
  192. <view class="ptxt">性别 | {{aite.residentGender==1?'男':'女'}}</view>
  193. <view class="ptxt">年龄 | {{getAgeFromID(aite.residentIdCard)}}岁</view>
  194. </view>
  195. <view class="flexc" v-if="aite.residentAppearance">
  196. <view class="ptxt">人员面貌 | {{kaType(aite.residentAppearance,rymmList)}}</view>
  197. </view>
  198. </view>
  199. </view>
  200. <view class="spdel" v-if="aite.right>0&&checkPermi(['wuYe:residentInfo:remove'])" @click.stop="getDelFn(aite.residentId)">删除</view>
  201. </view>
  202. <!-- <view class="flexc pr mb12" :key="`peo${aidx}`" v-if="aidx>0&&ite.zhanflag" @click="getDetail(aite.residentId)"
  203. :data-idx="idx"
  204. :data-aidx="aidx" data-type="peo"
  205. @touchstart="drawStart" @touchmove="drawMove" @touchend="drawEnd" :style="'right:'+aite.right+'px'"
  206. >
  207. <view class="plist flexc">
  208. <image :src="man" class="head" v-if="aite.residentGender==1"></image>
  209. <image :src="woman" class="head" v-else></image>
  210. <view class="flex1">
  211. <view class="ptit">{{aite.residentName}}
  212. <view class="btn btnc ml10" v-if="aite.isHouseholder=='Y'">户主</view>
  213. </view>
  214. <view class="ptxt">身份证号 | {{aite.residentIdCard}}</view>
  215. <view class="flexc">
  216. <view class="ptxt">性别 | {{aite.residentGender==1?'男':'女'}}</view>
  217. <view class="ptxt">年龄 | {{getAgeFromID(aite.residentIdCard)}}岁</view>
  218. </view>
  219. <view class="flexc" v-if="aite.residentAppearance">
  220. <view class="ptxt">人员面貌 | {{kaType(aite.residentAppearance,rymmList)}}</view>
  221. </view>
  222. </view>
  223. </view>
  224. <view class="spdel" v-if="aite.right>0&&checkPermi(['wuYe:residentInfo:remove'])" @click.stop="getDelFn(aite.residentId)">删除</view>
  225. </view> -->
  226. </block>
  227. <!-- <image :src="upimg" v-if="ite.residentInfoList.length>1" :class="ite.zhanflag?'act':''" class="upimg" @click="getZhan(idx)"></image> -->
  228. </view>
  229. </view>
  230. </block>
  231. <!-- 我的互动 -->
  232. <block v-if="type=='myhd'">
  233. <view class="mb12 pr" v-for="(ite,idx) in datainfo" :key="idx">
  234. <view class="hdlist pd12 flex">
  235. <image :src="man" class="mhead flex0"></image>
  236. <view class="flex1 overh">
  237. <view class="flexc mb6">
  238. <view class="name flex1 over">{{ite.nickName}}</view>
  239. <view class="tit flex0 ml10">
  240. <block v-if="ite.targetType==1">评论了你的文章</block>
  241. <block v-if="ite.targetType==2">点赞了你的文章</block>
  242. <block v-if="ite.targetType==3">收藏了你的文章</block>
  243. <block v-if="ite.targetType==4">回复了你的评论</block>
  244. <block v-if="ite.targetType==5">点赞了你的评论</block>
  245. </view>
  246. <view class="time flex0 ml10">{{ite.createTime}}</view>
  247. </view>
  248. <view class="flexc overh mb4">
  249. <view class="line bga"></view>
  250. <view class="txt over flex1">{{ite.targetTitle}}</view>
  251. <image :src="rimg" class="rimg ml10"></image>
  252. </view>
  253. </view>
  254. </view>
  255. </view>
  256. </block>
  257. <block v-if="type=='plsh'">
  258. <view class="mb12 pr" v-for="(ite,idx) in datainfo" :key="idx"
  259. :data-idx="idx"
  260. @touchstart="drawStart" @touchmove="drawMove" @touchend="drawEnd" :style="'right:'+ite.right+'px'"
  261. >
  262. <view class="hdlist ">
  263. <view class="pd12 flex">
  264. <image :src="ite.avatar&&ite.avatar.avatar.indexOf('/static/img/profile')==-1?baseUrl+ite.avatar:man" class="mhead flex0"></image>
  265. <view class="flex1 overh">
  266. <view class="flexc mb6">
  267. <view class="name flex1 over">{{ite.nickName}}</view>
  268. <view class="time flex0 ml10">02-26</view>
  269. </view>
  270. <view class="txt mb8">{{ite.commentContent}}</view>
  271. <view class="flexc overh mb2">
  272. <view class="line bgd"></view>
  273. <view class="txta over flex1">{{ite.communityTitle}}</view>
  274. <image :src="rimg" class="rimg ml10"></image>
  275. </view>
  276. </view>
  277. </view>
  278. <view class="shbtns flexc pd12" >
  279. <view class="btn bga" @click="getSh('4',ite)">不予展示</view>
  280. <view class="flex1"></view>
  281. <view class="btn bgb" @click="getSh('3',ite)">不通过</view>
  282. <view class="btn bgc" @click="getSh('2',ite)">通过</view>
  283. </view>
  284. </view>
  285. <view class="spdel" v-if="ite.right>0&&checkPermi(['wuYe:residentInfo:remove'])" @click.stop="getDelFn(ite.residentId)">删除</view>
  286. </view>
  287. </block>
  288. <!-- 我的点赞,收藏,评论 :data-idx="idx"
  289. @touchstart="drawStart" @touchmove="drawMove" @touchend="drawEnd" :style="'right:'+ite.right+'px'"-->
  290. <block v-if="type=='wdhd'">
  291. <view class="mb12 pr" v-for="(ite,idx) in datainfo" :key="idx" @click="getDetail(ite)">
  292. <view class="hdlist ">
  293. <view class="pd12 flex">
  294. <image :src="ite.avatar&&ite.avatar.indexOf('/static/img/profile')==-1?baseUrl+ite.avatar:man" class="mhead flex0"></image>
  295. <view class="flex1 overh">
  296. <view class="flexc mb6">
  297. <view class="name flex1 over">{{ite.nickName}}</view>
  298. <view class="time flex0 ml10">{{ite.createTime}}</view>
  299. </view>
  300. <view class="txt mb8">{{ite.commentContent}}</view>
  301. <view class="flexc overh mb2">
  302. <view class="line bgd"></view>
  303. <view class="txta over flex1" v-if="tabval=='mypl'">{{ite.communityTitle}}</view>
  304. <view class="txta over flex1" v-else>{{ite.targetTitle}}</view>
  305. <image :src="rimg" class="rimg ml10"></image>
  306. </view>
  307. </view>
  308. </view>
  309. </view>
  310. <!-- <view class="spdel" v-if="ite.right>0&&checkPermi(['wuYe:residentInfo:remove'])" @click.stop="getDelFn(ite.residentId)">删除</view> -->
  311. </view>
  312. </block>
  313. <!-- 车辆违规 -->
  314. <block v-if="type=='carpark'">
  315. <view class="carlist pr" v-for="(ite,idx) in datainfo" :key="ite.illegalParkingId" @click="getDetail(ite.illegalParkingId)"
  316. :data-idx="idx"
  317. @touchstart="drawStart" @touchmove="drawMove" @touchend="drawEnd" :style="checkPermi(['wuYe:illegalParking:remove'])?'right:'+ite.right+'px':''"
  318. >
  319. <view class="delleft">
  320. <view class="ctop flexc">
  321. <image :src="caraa" class="imgs" v-if="ite.carType==1"></image>
  322. <image :src="carbb" class="imgs" v-if="ite.carType==2"></image>
  323. <view class="tit">{{ite.plateNumber}}</view>
  324. <view class="num coff" v-if="ite.isBlack=='Y'">(已登黑名单)</view>
  325. <view class="flex1"></view>
  326. <block v-if="ite.carType">
  327. <view class="txt " :class="ite.carType==1?'ca':'cb'">{{kaType(ite.carType,carType)}}</view>
  328. </block>
  329. <!-- <view class="txt cb" v-if="ite.type==2">外来车辆</view> -->
  330. </view>
  331. <view class="clists">
  332. <block v-if="ite.carType==1">
  333. <view class="clist"><view class="tit">关联房号</view>{{ite.visitPortal}}</view>
  334. <view class="clist"><view class="tit">手机号码</view>{{ite.mobileNumber}}</view>
  335. </block>
  336. <view class="clist"><view class="tit">登记时间</view>{{ite.createTime}}</view>
  337. <view class="clist"><view class="tit">违停拍照</view>
  338. <view class="imgas" v-if="ite.illegalPhoto">
  339. <image :src="baseUrl+aite" v-for="(aite,aidx) in kaPhoto(ite.illegalPhoto)" :key="aidx" @click.stop="getPreview(aidx,ite.illegalPhoto)"></image>
  340. </view>
  341. </view>
  342. </view>
  343. </view>
  344. <view class="spdel" v-if="ite.right>0&&checkPermi(['wuYe:illegalParking:remove'])" @click.stop="getDelFn(ite.illegalParkingId)">删除</view>
  345. </view>
  346. </block>
  347. <view class="shax" v-if="wtdt">{{wtdt}}</view>
  348. </block>
  349. <!-- 无数据 -->
  350. <view class="nodata" v-else>
  351. <image :src="noiconpimg"></image>
  352. <view>
  353. 暂无数据
  354. </view>
  355. </view>
  356. </view>
  357. </template>
  358. <script>
  359. import {selectDictValue} from "@/utils/common.js"
  360. import { checkPermi, checkRole } from "@/utils/permission"; // 权限判断函数
  361. import config from '@/config'
  362. export default{
  363. props:{
  364. datainfo: {
  365. type: Array,
  366. default () {
  367. return []
  368. }
  369. },
  370. wtdt:{
  371. type:String,
  372. default () {
  373. return ''
  374. }
  375. },
  376. type:{
  377. type:String,
  378. default () {
  379. return 0
  380. }
  381. },
  382. clcxList:{
  383. type: Array,
  384. default () {
  385. return []
  386. }
  387. },
  388. rymmList:{
  389. type: Array,
  390. default () {
  391. return []
  392. }
  393. },
  394. carType:{
  395. type: Array,
  396. default () {
  397. return []
  398. }
  399. },
  400. rylxList:{
  401. type: Array,
  402. default () {
  403. return []
  404. }
  405. },
  406. voList:{
  407. type: Array,
  408. default () {
  409. return []
  410. }
  411. },
  412. tabval:{
  413. type:String,
  414. default () {
  415. return ''
  416. }
  417. }
  418. },
  419. data(){
  420. return{
  421. house:require("@/health/static/house.png"),
  422. housea:require("@/health/static/housea.png"),
  423. houseb:require("@/health/static/houseb.png"),
  424. housec:require("@/health/static/housec.png"),
  425. noiconpimg:require("@/static/images/nodata.png"),
  426. upimg:require("@/mine/static/house/up.png"),
  427. cara:require("@/mine/static/house/cara.png"),
  428. carb:require("@/mine/static/house/carb.png"),
  429. caraa:require("@/mine/static/house/caraa.png"),
  430. carbb:require("@/mine/static/house/carbb.png"),
  431. hedit:require("@/mine/static/house/hedit.png"),
  432. hdel:require("@/mine/static/house/del.png"),
  433. sha:require("@/mine/static/house/sha.png"),
  434. shb:require("@/mine/static/house/shb.png"),
  435. edit:require("@/mine/static/edit.png"),
  436. cira:require('@/news/static/complaint/cira.png'),
  437. cirb:require('@/news/static/complaint/cirb.png'),
  438. man:require("@/health/static/man.png"),
  439. woman:require("@/health/static/woman.png"),
  440. rimg:require("@/static/images/rimga.png"),
  441. baseUrl:config.baseUrl,
  442. delBtnWidth:66,//左滑默认宽度
  443. }
  444. },
  445. mounted() {
  446. },
  447. methods:{
  448. checkPermi, checkRole,
  449. kaType(data, list) {
  450. return selectDictValue(list, data);
  451. },
  452. kaPhoto(data){
  453. return data.split(',');
  454. },
  455. getDetail(e){
  456. this.$emit('getDetail',e)
  457. },
  458. getDelFn(e){
  459. var that=this;
  460. uni.showModal({
  461. title: '确认删除',
  462. content: "是否确认删除",
  463. cancelText: '取消',
  464. confirmText: '确认',
  465. success: function(res) {
  466. if (res.confirm) {
  467. that.$emit('getDelFn',e)
  468. } else if (res.cancel) {
  469. }
  470. }
  471. });
  472. },
  473. getSh(type,ite){
  474. var that=this;
  475. var str="";
  476. if(type=='2'){
  477. str="通过"
  478. }else if(type=='3'){
  479. str="不通过"
  480. }else if(type=='4'){
  481. str="下架"
  482. }
  483. uni.showModal({
  484. title: '确认'+str,
  485. content: "是否确认"+str,
  486. cancelText: '取消',
  487. confirmText: '确认',
  488. success: function(res) {
  489. if (res.confirm) {
  490. var obj={
  491. status:type,
  492. contentId:ite.contentId,
  493. commentId:ite.commentId,
  494. }
  495. that.$emit('getSh',obj)
  496. } else if (res.cancel) {
  497. }
  498. }
  499. });
  500. },
  501. getZhan(idx){
  502. // var obj=JSON.parse(JSON.stringify(this.datainfo))[idx]
  503. // obj.zhanflag=!obj.zhanflag;
  504. // this.datainfo.splice(idx,1,obj);
  505. this.datainfo[idx].zhanflag=!this.datainfo[idx].zhanflag
  506. },
  507. getDelFn(id){
  508. var that=this;
  509. uni.showModal({
  510. title: '确认删除',
  511. content: "是否确认删除",
  512. cancelText: '取消',
  513. confirmText: '确认',
  514. success: function(res) {
  515. if (res.confirm) {
  516. that.$emit('getDelFn',id)
  517. } else if (res.cancel) {
  518. }
  519. }
  520. });
  521. },
  522. getAgeFromID(idNumber) {
  523. if(idNumber){
  524. const birthDateStr = idNumber.substring(6, 14);
  525. const birthYear = parseInt(birthDateStr.substring(0, 4));
  526. const birthMonth = parseInt(birthDateStr.substring(4, 6));
  527. const birthDay = parseInt(birthDateStr.substring(6, 8));
  528. const today = new Date();
  529. const currentYear = today.getFullYear();
  530. const currentMonth = today.getMonth() + 1;
  531. const currentDay = today.getDate();
  532. let age = currentYear - birthYear;
  533. if (currentMonth < birthMonth || (currentMonth === birthMonth && currentDay < birthDay)) {
  534. age--;
  535. }
  536. return age;
  537. }
  538. },
  539. getPreview(idx,arr) {
  540. var newArr=[];
  541. var list=arr.split(',')
  542. list.forEach(ite=>{
  543. var ds=this.baseUrl+ite
  544. newArr.push(ds)
  545. })
  546. uni.previewImage({
  547. urls: newArr,
  548. current:idx,
  549. success: function(data) {},
  550. fail: function(err) {}
  551. });
  552. },
  553. //开始触摸滑动
  554. drawStart(e) {
  555. // console.log("开始触发");
  556. var touch = e.touches[0];
  557. this.startX = touch.clientX;
  558. },
  559. //触摸滑动
  560. drawMove(e) {
  561. var idx=e.currentTarget.dataset.idx
  562. var aidx=e.currentTarget.dataset.aidx
  563. var type=e.currentTarget.dataset.type;
  564. for (var index in this.datainfo) {
  565. if(type&&type=='peo'){
  566. for(var i in this.datainfo[idx].residentInfoList){
  567. this.$set(this.datainfo[idx].residentInfoList[i],'right',0);
  568. }
  569. }else{
  570. this.$set(this.datainfo[index],'right',0);
  571. }
  572. }
  573. var touch = e.touches[0];
  574. var item = this.datainfo[idx];
  575. var disX = this.startX - touch.clientX;
  576. if (disX >= 20) {
  577. if (disX > this.delBtnWidth) {
  578. disX = this.delBtnWidth;
  579. }
  580. if(type&&type=='peo'){
  581. this.$set(this.datainfo[idx].residentInfoList[aidx],'right',disX);
  582. }else{
  583. this.$set(this.datainfo[idx],'right',disX);
  584. }
  585. // this.csListArrl[idx].right=disX
  586. } else {
  587. // this.csListArrl[idx].right=0
  588. this.$set(this.datainfo[idx],'right',0);
  589. }
  590. },
  591. //触摸滑动结束
  592. drawEnd(e) {
  593. // console.log("滑动结束");
  594. var idx=e.currentTarget.dataset.idx
  595. var item = this.datainfo[idx];
  596. if (item.right >= this.delBtnWidth / 2) {
  597. // this.datainfo[idx].right=this.delBtnWidth
  598. // this.$set(this.datainfo[idx],'right',this.delBtnWidth);
  599. } else {
  600. this.datainfo[idx].right=0
  601. }
  602. },
  603. }
  604. }
  605. </script>
  606. <style lang="scss" scoped>
  607. .flex{display: flex;}
  608. .flexc{display: flex;align-items: center;}
  609. .mb10{margin-bottom: 20rpx;}
  610. .carlist{background: #FFFFFF;border-radius: 20rpx;margin-bottom: 24rpx;
  611. .carltop{min-height: 154rpx;border-bottom: 2rpx solid #E5E5E5;
  612. .cir{width: 8rpx;height: 8rpx;border-radius: 50%;margin: 0 8rpx;display: inline-block;}
  613. .co16{
  614. .cir{background: #16BE7F;}
  615. }
  616. .co01{
  617. .cir{background: #0156FE;}
  618. }
  619. .tit{font-weight: bold;font-size: 32rpx;}
  620. .txt{font-weight: 500;font-size: 26rpx;color: #272727;}
  621. .txtbtn{min-width: 82rpx;
  622. height: 32rpx;font-weight: 500;font-size: 20rpx;color: #45CB99;
  623. border-radius: 16rpx;border: 1px solid #45CB99;margin-left: 12rpx;}
  624. .cara{flex: 0 0 auto;width: 232rpx;height: 74rpx;margin-right: 40rpx;}
  625. .carb{flex: 0 0 auto;width: 278rpx;height: 130rpx;}
  626. }
  627. .carlf{padding:26rpx 0 10rpx;
  628. .clflist{font-weight: 500;font-size: 26rpx;color: #666666;margin-bottom: 16rpx;}
  629. }
  630. }
  631. .carlist{background: #FFFFFF;border-radius: 20rpx;margin-bottom: 24rpx;
  632. .ctop{border-bottom: 2rpx solid #E5E5E5;padding:26rpx 24rpx;
  633. .imgs{width: 40rpx;height: 42rpx;margin-right: 30rpx;}
  634. .tit{font-size: 32rpx;color: #272727;font-weight: bold;margin-right: 14rpx;}
  635. .txt{font-weight: 500;font-size: 26rpx;
  636. &.ca{color: #3565ED;}
  637. &.cb{color: #FE5A0E;}
  638. &.cc{color: #28C529;}
  639. }
  640. .txta{font-weight: 500;font-size: 24rpx;color: #AAAAAA;}
  641. .num{font-size: 24rpx;color: #AAAAAA;}
  642. }
  643. .btn{height: 34rpx;border-radius: 18rpx;display: flex;align-items: center;justify-content: center;padding: 0 10rpx;font-size: 22rpx;margin-right: 24rpx;
  644. &.btna{border: 2rpx solid #06C770;color: #06C770;}
  645. &.btnb{border: 2rpx solid #3565ED;color: #3565ED;}
  646. &.btnc{border: 2rpx solid #FE5A0E;color: #FE5A0E;}
  647. &.btnbga{border: 1px solid #0156FE;color: #3565ED;background: #DFEAFF;height: 36rpx;}
  648. &.btnbgb{border: 1px solid #C1C1C1;color: #666666;background: #F1F1F1;height: 36rpx;}
  649. &.btnbgc{border: 1px solid #FE5A0E;color:#FE5A0E;background:#FFEEE6;height: 36rpx;}
  650. }
  651. .clists{padding: 24rpx 24rpx 8rpx;
  652. .clist{font-weight: 500;margin-bottom: 16rpx;
  653. font-size: 26rpx;color: #272727;display: flex;line-height: 34rpx;
  654. .tit{font-size: 26rpx;color: #AAAAAA;flex: 0 0 auto;margin-right: 16rpx;min-width: 108rpx;text-align-last: justify;}
  655. .imgas{display: flex;align-items: center;flex-wrap: wrap;
  656. image{width: 142rpx;height: 142rpx;margin-right: 30rpx;margin-top: 8rpx;}
  657. }
  658. }
  659. .w50{
  660. .clist{width: 50%;}
  661. }
  662. }
  663. }
  664. // 收货地址
  665. .adrlist{border-bottom: 2rpx solid #E5E5E5;padding: 34rpx 0 34rpx 8rpx;
  666. .tit{font-weight: 500;font-size: 22rpx;color: #666666;}
  667. .txt{font-size: 28rpx;color: #272727;font-weight: bold;}
  668. .txts{font-weight: 500;font-size: 26rpx;color: #272727;}
  669. .btns{font-weight: 500;font-size: 22rpx;color: #0256FD;padding: 2rpx 14rpx;display:inline-block;background: #C9DBFF;
  670. border-radius: 10rpx;}
  671. .adrr{width: 40rpx;height: 40rpx;flex: 0 0 auto;margin-left: 12rpx;
  672. image{width: 22rpx;height: 22rpx;}
  673. }
  674. &.act{
  675. .tit{color: #0256FD;}
  676. .txt{color: #0256FD;}
  677. .txts{color: #0256FD;}
  678. }
  679. }
  680. // 快递
  681. .kdlists{padding: 24rpx 26rpx;background-color: #FFFFFF;border-radius: 20rpx;margin-bottom: 24rpx;
  682. .kdll{width: 140rpx;height: 140rpx;border-radius: 10rpx;margin-right: 32rpx;flex: 0 0 auto;}
  683. .kdlr{
  684. .tit{font-size: 30rpx;color: #272727;font-weight: bold;margin-bottom: 18rpx;margin-top: 4rpx;}
  685. .tits{font-size: 24rpx;color: #272727;font-weight: 500;margin-bottom: 14rpx;}
  686. .txt{font-weight: 500;font-size: 24rpx;color: #AAAAAA;}
  687. }
  688. }
  689. // 快递步骤条
  690. .hfstep{padding: 0 32rpx 44rpx 32rpx;
  691. .hfslist{padding-bottom: 44rpx;position: relative;
  692. &::before{content: '';position: absolute;left: 14rpx;top:14rpx;height: 100%;width: 2rpx;background: #E6E6E6;}
  693. .limg{width: 30rpx;height: 30rpx;margin-right: 22rpx;flex: 0 0 auto;margin-top:3rpx;
  694. .imga{width: 30rpx;height: 30rpx;}
  695. .imgb{width: 18rpx;height: 18rpx;}
  696. }
  697. .hfstit{font-weight: bold;font-size: 26rpx;color: #666666;line-height: 36rpx;margin-bottom: 24rpx;}
  698. .hfstxt{font-weight: 500;font-size: 26rpx;color: #666666;line-height: 36rpx;padding-left: 8rpx;}
  699. }
  700. }
  701. .carlist{background: #FFFFFF;border-radius: 20rpx;margin-bottom: 24rpx;
  702. .ctop{border-bottom: 2rpx solid #E5E5E5;padding:26rpx 24rpx;
  703. .imgs{width: 40rpx;height: 42rpx;margin-right: 30rpx;}
  704. .tit{font-size: 32rpx;color: #272727;font-weight: bold;margin-right: 14rpx;}
  705. .txt{font-weight: 500;font-size: 26rpx;
  706. &.ca{color: #3565ED;}
  707. &.cb{color: #FE5A0E;}
  708. &.cc{color: #28C529;}
  709. }
  710. .txta{font-weight: 500;font-size: 24rpx;color: #AAAAAA;}
  711. .num{font-size: 24rpx;color: #AAAAAA;}
  712. }
  713. .btn{height: 34rpx;border-radius: 18rpx;display: flex;align-items: center;justify-content: center;padding: 0 10rpx;font-size: 22rpx;margin-right: 24rpx;
  714. &.btna{border: 2rpx solid #06C770;color: #06C770;}
  715. &.btnb{border: 2rpx solid #3565ED;color: #3565ED;}
  716. &.btnc{border: 2rpx solid #FE5A0E;color: #FE5A0E;}
  717. &.btnbga{border: 1px solid #0156FE;color: #3565ED;background: #DFEAFF;height: 36rpx;}
  718. &.btnbgb{border: 1px solid #C1C1C1;color: #666666;background: #F1F1F1;height: 36rpx;}
  719. &.btnbgc{border: 1px solid #FE5A0E;color:#FE5A0E;background:#FFEEE6;height: 36rpx;}
  720. }
  721. }
  722. // 人员
  723. .peolist{
  724. .ctop{padding: 24rpx 24rpx 22rpx;}
  725. .imgs{margin-right: 16rpx !important;}
  726. .tit{font-size: 28rpx !important;}
  727. .plists{padding: 30rpx 24rpx 6rpx;
  728. .plist{background: linear-gradient(-90deg, #F2F5FF 0%, #FBFDFF 100%);border-radius: 20rpx;border: 2rpx solid #E6E6E6;padding: 18rpx 26rpx 4rpx;width: 100%;z-index: 1;
  729. .head{width: 96rpx;height: 98rpx;margin-right: 32rpx;flex: 0 0 auto;}
  730. .ptit{font-weight: bold;font-size: 30rpx;color: #272727;display: flex;align-items: center;margin-bottom: 14rpx;}
  731. .ptxt{font-weight: 500;font-size: 26rpx;color: #666666;line-height: 36rpx;margin-bottom: 14rpx;min-width: 176rpx;}
  732. }
  733. }
  734. .upimg{width: 26rpx;height: 22rpx;display: block;transform: rotate(180deg);transition: all 0.3s;margin: 0 auto 18rpx;
  735. &.act{transform: rotate(0deg);}
  736. }
  737. }
  738. // 房屋管理
  739. .houselist{position: relative;
  740. .clists{padding-bottom: 2rpx !important;}
  741. .clist{margin-bottom: 22rpx !important;}
  742. .hedit{width: 22rpx;height: 22rpx;flex: 0 0 auto;margin-left:16rpx;}
  743. .hdel{width: 26rpx;height: 26rpx;flex: 0 0 auto;margin-left:16rpx;}
  744. .shimg{width: 117rpx;height: 78rpx;position: absolute;right: 26rpx;bottom: 20rpx;}
  745. // .btns{justify-content: flex-end;
  746. // view{min-width: 156rpx;font-weight: 500;font-size: 26rpx;margin-right: 24rpx;border-radius: 20rpx;padding: 6rpx 8rpx;box-sizing: border-box;text-align: center;margin-bottom: 26rpx;
  747. // &.bga{border: 2rpx solid #FE5A0E;background: #FFF8F5;color: #FE5A0E;}
  748. // &.bgb{border: 2rpx solid #0256FD;background: #F1F5FC;color: #0256FD;}
  749. // &.bgc{border: 2rpx solid #06C770;background: #EEF8F4;color: #06C770;}
  750. // }
  751. // }
  752. }
  753. // 互动
  754. .pd12{padding: 24rpx;}
  755. .hdlist{background: #FFFFFF;border-radius: 20rpx;position: relative;z-index: 1;
  756. .mhead{width: 56rpx;height: 56rpx;margin-right: 20rpx;border-radius: 50%}
  757. .name{font-size: 28rpx;font-weight: bold;color: #272727;height: 56rpx;line-height: 56rpx;}
  758. .tit{font-weight: 500;font-size: 22rpx;color: #666666;}
  759. .time{font-weight: 500;font-size: 22rpx;color: #666666;}
  760. .line{width: 6rpx;height: 28rpx;border-radius: 4rpx;margin-right: 12rpx;
  761. &.bga{background: #FACA7D;}
  762. &.bgb{background: #86AFFF;}
  763. &.bgc{background: #93E9C2;}
  764. &.bgd{background: #DADADA;}
  765. }
  766. .txt{font-weight: 500;font-size: 26rpx;color: #272727;line-height: 36rpx;}
  767. .txta{font-weight: 500;font-size: 26rpx;color: #666666;}
  768. .rimg{width: 12rpx;height: 22rpx;}
  769. .shbtns{border-top: 2rpx solid #DADADA;
  770. .btn{border-radius: 20rpx;min-width: 110rpx;box-sizing: border-box;padding: 0 16rpx;
  771. height: 52rpx;display: flex;align-items: center;justify-content: center;flex:0 0 auto;margin-left: 20rpx;
  772. &.bga{border: 2rpx solid #06C770;background: #DAEFE6;color: #06C770;margin-left: 0;}
  773. &.bgb{border: 2rpx solid #FF6969;;background: #FFE7E7;color: #FF6969;}
  774. &.bgc{background: #0256FD;color: #FFFFFF;}
  775. }
  776. }
  777. }
  778. // 无数据
  779. .nodata{display: flex;flex-direction: column;align-items: center;
  780. image{width: 440rpx;height: 440rpx;}
  781. view{font-size: 30rpx;color: #666666;font-weight: bold;}
  782. }
  783. </style>