index.vue 94 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632
  1. <template>
  2. <div class="bgcolor">
  3. <div class="navBarTOP">
  4. <!-- 顶部条-->
  5. <van-nav-bar class="navBar" title="计划外">
  6. <template #right>
  7. <span @click="searchFn">筛选<van-icon name="arrow-down" /></span>
  8. </template>
  9. </van-nav-bar>
  10. <div class="searchDiv">
  11. <van-search
  12. v-model="storeName"
  13. left-icon="search"
  14. show-action
  15. placeholder="搜索名称/编号/地址"
  16. @clear="clearFn">
  17. <template #action>
  18. <div @click="onSearchm">搜索</div>
  19. </template>
  20. </van-search>
  21. </div>
  22. <van-tabs class="myTab" type="card" v-model="tabVal" color="#0057ba" @change="tabChange">
  23. <van-tab title="销售部" name="0" :disabled="disabled"></van-tab>
  24. <van-tab title="我的" name="1" :disabled="disabled"></van-tab>
  25. </van-tabs>
  26. </div>
  27. <!-- 主体内容-->
  28. <div class="container" style="margin-top: 144px">
  29. <van-list
  30. class="myList"
  31. v-model="loading"
  32. :finished="finished"
  33. finished-text="--已经到底了--"
  34. @load="onLoad">
  35. <div class="cellcontent" v-for="(item, index) in list" :key="index">
  36. <van-cell>
  37. <div class="card">
  38. <div class="title titlero btn" :data-clipboard-text="item.storeCode">
  39. {{ item.storeName }}(<span style="color: #0057ba">{{ item.storeCode }}</span
  40. >)<van-icon
  41. :name="paste"
  42. color="#ee0a24"
  43. size="20"
  44. style="top: 6px; margin-left: 4px" />
  45. </div>
  46. <div class="info" style="position: relative">
  47. 联系人:{{ item.contactName }}
  48. <div style="position: absolute; bottom: 0px; right: 0px">
  49. <el-popover
  50. popper-class="zpover zpover6"
  51. placement="bottom-start"
  52. trigger="click">
  53. <div>
  54. <p>
  55. 本店{{ timeData }}下单SKU数:<a
  56. @click="linkList(item)"
  57. style="text-decoration: underline"
  58. >点击查看详情</a
  59. >
  60. </p>
  61. </div>
  62. <div
  63. class="visitStoreIco"
  64. v-if="item.storeLabels.zysslNums"
  65. style="background-color: #fff; position: relative"
  66. slot="reference">
  67. <p
  68. style="
  69. width: 100%;
  70. position: absolute;
  71. z-index: 1;
  72. top: 0.2px;
  73. width: 22px;
  74. margin: 0;
  75. margin-left: 3.6px;
  76. text-align: center;
  77. font-size: 12px;
  78. ">
  79. {{ item.storeLabels.zysslNums }}
  80. </p>
  81. <van-icon :name="ord" size="26" />
  82. </div>
  83. </el-popover>
  84. <el-popover
  85. popper-class="zpover zpover5"
  86. placement="bottom"
  87. width="200"
  88. trigger="click">
  89. <div v-if="item.storeLabels">
  90. <p>已参加:</p>
  91. <p v-for="tt in (item.storeLabels.targetOne + '').split(';')">
  92. {{ tt }}
  93. </p>
  94. </div>
  95. <div
  96. class="visitStoreIco"
  97. v-if="item.storeLabels.targetOne"
  98. style="background-color: #fff"
  99. slot="reference">
  100. <van-icon :name="targetOne" size="26" />
  101. </div>
  102. </el-popover>
  103. <el-popover
  104. popper-class="zpover"
  105. placement="bottom"
  106. width="200"
  107. trigger="click"
  108. content="金牌店调色机5天未联网">
  109. <div
  110. v-if="item.storeLabels.ccmOffline"
  111. class="visitStoreIco"
  112. style="background-color: #fff"
  113. slot="reference">
  114. <van-icon :name="Network" size="26" />
  115. </div>
  116. </el-popover>
  117. <el-popover
  118. popper-class="zpover"
  119. placement="bottom"
  120. width="200"
  121. trigger="click"
  122. content="同城店近60天未下单">
  123. <div
  124. v-if="item.storeLabels.fxNoOrder"
  125. class="visitStoreIco"
  126. style="background-color: #fff"
  127. slot="reference">
  128. <van-icon :name="order60" size="26" />
  129. </div>
  130. </el-popover>
  131. <el-popover
  132. popper-class="zpover"
  133. placement="bottom"
  134. width="200"
  135. trigger="click"
  136. content="金牌店近30天未下单">
  137. <div
  138. v-if="item.storeLabels.noOrder"
  139. class="visitStoreIco"
  140. style="background-color: #fff"
  141. slot="reference">
  142. <van-icon :name="order" size="26" />
  143. </div>
  144. </el-popover>
  145. <el-popover
  146. popper-class="zpover"
  147. placement="bottom"
  148. width="200"
  149. trigger="click"
  150. content="本店本月进过专业时时丽">
  151. <div
  152. class="visitStoreIco"
  153. v-if="item.storeLabels.zyssl"
  154. style="background-color: #ed5c68"
  155. slot="reference">
  156. </div>
  157. </el-popover>
  158. <el-popover
  159. popper-class="zpover zpover1"
  160. placement="bottom"
  161. width="200"
  162. trigger="click"
  163. content="本店本月进过超好贴">
  164. <div
  165. v-if="item.storeLabels.chtczj"
  166. class="visitStoreIco"
  167. style="background-color: #0057ba"
  168. slot="reference">
  169. </div>
  170. </el-popover>
  171. <el-popover
  172. placement="bottom"
  173. popper-class="zpover zpover1 zpover1sb"
  174. :disabled="!item.userVisitTimesMap"
  175. trigger="click">
  176. <div
  177. v-if="item.storeLabels.visitTimes && item.storeLabels.visitTimes > 0"
  178. class="visitStoreIco"
  179. slot="reference"
  180. style="background-color: #fff; position: relative">
  181. <p
  182. style="
  183. width: 100%;
  184. position: absolute;
  185. z-index: 10;
  186. top: -2px;
  187. margin: 0;
  188. text-align: center;
  189. font-size: 12px;
  190. ">
  191. {{ item.storeLabels.visitTimes }}
  192. </p>
  193. <van-icon :name="ordernum" size="26" />
  194. </div>
  195. <el-table :data="item.userVisitTimesMap" border max-height="180px">
  196. <el-table-column label="业务员" prop="userName" />
  197. <el-table-column label="拜访次数" prop="visitTimes" width="110px" />
  198. </el-table>
  199. </el-popover>
  200. </div>
  201. </div>
  202. <div class="info">
  203. 类型:{{ item.storeCategory }}&nbsp;
  204. <el-popover popper-class="zpover zpover6" placement="bottom-start" trigger="click">
  205. <div>
  206. <p>
  207. 本店经营品项指导:
  208. <a @click="linkimg(item)" style="text-decoration: underline">点击查看</a>
  209. </p>
  210. </div>
  211. <van-icon name="question-o" size="18" slot="reference" />
  212. </el-popover>
  213. </div>
  214. <div class="info" v-if="item.telephone" @click="buryingPointFn(item)">
  215. 联系电话:<a
  216. style="color: #0057ba; font-weight: bold; text-decoration: underline"
  217. :href="'tel:' + item.telephone"
  218. >{{ item.telephone }}<van-icon name="phone"
  219. /></a>
  220. </div>
  221. <div class="info">
  222. 地址:{{ item.addressLine }}
  223. <img
  224. v-if="item.storeLonExist"
  225. style="width: 36px"
  226. :src="sbpmdh"
  227. @click="linkapp(item)" />
  228. </div>
  229. <div class="info" v-if="typeShow">经销商:{{ item.chainName }}</div>
  230. <!-- storeLonExist 门店是否存在经纬度 字段false=不显示导航和距离,true=显示 -->
  231. <div class="info" v-if="item.storeLonExist">
  232. 距离:{{ Micrometer(item.distance) }}m
  233. </div>
  234. </div>
  235. <div
  236. class="statstext"
  237. v-if="item.stateString == '未拜访'"
  238. style="background-color: #ed5c68">
  239. 未拜访
  240. </div>
  241. <div
  242. class="statstext"
  243. v-if="item.stateString == '拜访中'"
  244. style="background-color: white">
  245. <van-icon :name="times" color="#ee0a24" size="32" />
  246. </div>
  247. <div class="statstext" v-if="item.stateString == '已拜访'">已拜访</div>
  248. <div class="btnbox">
  249. <van-row>
  250. <van-col
  251. span="5"
  252. v-if="item.stateString != '已拜访' && customerVisits"
  253. @click="storeVisit(item)">
  254. <img :src="call" style="margin: 0 auto; height: 18px; display: block" />
  255. <p style="text-align: center; margin: 0; font-size: 12px">进入拜访</p>
  256. </van-col>
  257. <van-col
  258. span="5"
  259. v-if="item.storeCategory == '公装经销商'"
  260. @click="projectOutVisit(item)">
  261. <img :src="xmgj" style="margin: 0 auto; height: 18px; display: block" />
  262. <p style="text-align: center; margin: 0; font-size: 12px">项目跟进</p>
  263. </van-col>
  264. <van-col
  265. span="5"
  266. v-if="
  267. item.stateString != '已拜访' &&
  268. item.storeCategory != '公装经销商' &&
  269. customerVisits
  270. "
  271. @click="abnormalVisit(item)">
  272. <img :src="yichang" style="margin: 0 auto; height: 18px; display: block" />
  273. <p style="text-align: center; margin: 0; margin-top: 1px; font-size: 12px">
  274. 异常拜访
  275. </p>
  276. </van-col>
  277. <van-col span="4" v-if="item.showOrderButton" @click="orderFn(item)">
  278. <img :src="xiadan" style="margin: 0 auto; height: 18px; display: block" />
  279. <p style="text-align: center; margin: 0; margin-top: 1px; font-size: 12px">
  280. 去下单
  281. </p>
  282. </van-col>
  283. <van-col span="5" v-if="item.stateString == '已拜访'" @click="Visit(item)">
  284. <img :src="bfxx" style="margin: 0 auto; height: 18px; display: block" />
  285. <p style="text-align: center; margin: 0; margin-top: 1px; font-size: 12px">
  286. 拜访信息
  287. </p>
  288. </van-col>
  289. <van-col span="5" @click="visitFn(item)">
  290. <img :src="kehuxinxi" style="margin: 0 auto; width: 18px; display: block" />
  291. <p style="text-align: center; margin: 0; margin-top: 1px; font-size: 12px">
  292. 客户信息
  293. </p>
  294. </van-col>
  295. <van-col span="5" v-if="tabVal == 1" @click="storeJoinVisit(item)">
  296. <img :src="jiarujihua" style="margin: 0 auto; height: 18px; display: block" />
  297. <p style="text-align: center; margin: 0; font-size: 12px">加入计划内</p>
  298. </van-col>
  299. </van-row>
  300. </div>
  301. </van-cell>
  302. <div class="lineGrey"></div>
  303. </div>
  304. <van-empty v-if="list.length == 0" />
  305. </van-list>
  306. <br />
  307. <br />
  308. <br />
  309. <br />
  310. <br />
  311. </div>
  312. <van-popup v-model="showPicker" position="bottom" class="textsize">
  313. <van-row
  314. style="
  315. position: fixed;
  316. top: 0;
  317. width: 100%;
  318. z-index: 998;
  319. background-color: #fff;
  320. border-bottom: 1px solid #ccc;
  321. ">
  322. <van-col span="3" style="text-align: center; margin: 14px 0" @click="showPicker = false">
  323. <van-icon name="cross" size="20" color="#909399" />
  324. </van-col>
  325. <van-col span="13"> </van-col>
  326. <van-col span="4" style="text-align: center; line-height: 36px" @click="onConfirm">
  327. <div style="color: #0057ba">
  328. <van-button type="info" size="small" color="#0057ba">筛选</van-button>
  329. </div></van-col
  330. >
  331. <van-col span="4" style="text-align: center; line-height: 36px" @click="onsets">
  332. <van-button type="default" size="small" style="height: 28px">重置</van-button>
  333. </van-col>
  334. </van-row>
  335. <div style="height: 48px; width: 100%"></div>
  336. <div class="searchcheck">
  337. <p class="searchchecktitle">&nbsp;经销商</p>
  338. <van-row>
  339. <van-col span="24">
  340. <div @click="moreTypeShowFn">
  341. <van-field
  342. style="
  343. margin-top: -6px;
  344. border-radius: 6px;
  345. border: 1px solid #ccc;
  346. overflow: hidden;
  347. "
  348. readonly
  349. v-model="chainName"
  350. label=""
  351. placeholder="请选择经销商" />
  352. </div>
  353. </van-col>
  354. </van-row>
  355. <p class="searchchecktitle" @click="otherbqShow = !otherbqShow">
  356. &nbsp;门店标签<van-icon name="arrow-down" style="float: right" />
  357. </p>
  358. <van-checkbox-group v-model="storeLabelTypes" direction="horizontal">
  359. <div v-if="otherbqShow" style="width: 100%">
  360. <div class="checkbox" v-for="(item, index) in StoreLabels" :key="index">
  361. <van-checkbox :name="item.dictValue">{{ item.dictLabel }}</van-checkbox>
  362. </div>
  363. <div style="height: 2px; background-color: #f5f5f5; width: 100%; clear: both"></div>
  364. </div>
  365. </van-checkbox-group>
  366. <van-checkbox-group v-model="result" direction="horizontal">
  367. <p class="searchchecktitle" @click="otherkkdShow = !otherkkdShow">
  368. &nbsp;可控店<van-icon name="arrow-down" style="float: right" />
  369. </p>
  370. <div v-if="otherkkdShow">
  371. <div v-for="(item, index) in storeTypeLists" :key="index" class="checkbox1">
  372. <div v-if="item.groupType == 'kkd'" class="child">
  373. <van-checkbox :name="item.dictValue">{{ item.dictLabel }}</van-checkbox>
  374. </div>
  375. </div>
  376. </div>
  377. <div style="height: 2px; background-color: #f5f5f5; width: 100%; clear: both"></div>
  378. <p class="searchchecktitle" @click="otherfxdShow = !otherfxdShow">
  379. &nbsp;分销店<van-icon name="arrow-down" style="float: right" />
  380. </p>
  381. <div v-if="otherfxdShow" style="margin: 0 14px; width: 100%">
  382. <div style="height: 2px; background-color: #f5f5f5; width: 100%; clear: both"></div>
  383. <p class="searchchecktitle1" @click="otherfxdShow1 = !otherfxdShow1">
  384. 金牌店<van-icon name="arrow-down" style="float: right" />
  385. </p>
  386. <div v-if="otherfxdShow1">
  387. <div v-for="(item1, index1) in storeTypeLists" :key="200 + index1" class="checkbox1">
  388. <div v-if="item1.groupType == 'fxd' && item1.remark == 'jp'" class="child">
  389. <van-checkbox :name="item1.dictValue">{{ item1.dictLabel }}</van-checkbox>
  390. </div>
  391. </div>
  392. <div style="height: 2px; background-color: #f5f5f5; width: 100%; clear: both"></div>
  393. </div>
  394. <p class="searchchecktitle1" @click="otherfxdShow2 = !otherfxdShow2">
  395. 同城分销店<van-icon name="arrow-down" style="float: right" />
  396. </p>
  397. <div v-if="otherfxdShow2">
  398. <div
  399. v-for="(itemlj, indexlj) in storeTypeLists"
  400. :key="400 + indexlj"
  401. class="checkbox1">
  402. <div v-if="itemlj.groupType == 'fxd' && itemlj.remark == 'tcfx'" class="child">
  403. <van-checkbox :name="itemlj.dictValue">{{ itemlj.dictLabel }}</van-checkbox>
  404. </div>
  405. </div>
  406. <div style="clear: both"></div>
  407. </div>
  408. </div>
  409. <div style="height: 2px; background-color: #f5f5f5; width: 100%; clear: both"></div>
  410. <p class="searchchecktitle" @click="otherShow = !otherShow">
  411. &nbsp;其他 <van-icon name="arrow-down" style="float: right" />
  412. </p>
  413. <div v-if="otherShow">
  414. <div v-for="(item2, index2) in storeTypeLists" :key="100 + index2" class="checkbox1">
  415. <div v-if="item2.groupType == 'other'" class="child">
  416. <van-checkbox :name="item2.dictValue">{{ item2.dictLabel }}</van-checkbox>
  417. </div>
  418. </div>
  419. </div>
  420. </van-checkbox-group>
  421. </div>
  422. </van-popup>
  423. <van-popup v-model="moreTypeShow" position="bottom" style="height: 80%">
  424. <van-row style="background-color: #f5f5f5">
  425. <van-col span="20">
  426. <van-field
  427. left-icon="search"
  428. style="margin-top: 2px; border-radius: 6px; overflow: hidden"
  429. v-model="CustomerName"
  430. label=""
  431. placeholder="请输入关键词"
  432. clearable />
  433. </van-col>
  434. <van-col span="4" style="text-align: center; line-height: 48px" @click="getCustomer">
  435. <div style="background-color: #0057ba; color: #fff">搜索</div></van-col
  436. >
  437. </van-row>
  438. <van-picker
  439. show-toolbar
  440. :columns="chainsData"
  441. value-key="chainName"
  442. @confirm="onConfirmChainsList"
  443. @cancel="moreTypeShow = false"
  444. visible-item-count="10" />
  445. </van-popup>
  446. <tab-bar tabBarActive="outsidelist"></tab-bar>
  447. <div class="positionContent" @click="rangeStoreFn()" v-if="mapShows">
  448. <van-icon class="img" :name="mpimg" size="50" />
  449. </div>
  450. </div>
  451. </template>
  452. <script>
  453. import tabBar from '@/components/tabBar';
  454. import {
  455. getUserOutPlaList,
  456. getUserOrgStoreList,
  457. stopVisit,
  458. checkVisit,
  459. addVisitsPosition,
  460. mobileReposition,
  461. getStoreyslTypeList,
  462. getStoreTypeListlp,
  463. joinInPlan,
  464. getStoreLabels,
  465. getCustomerList,
  466. buryingPoint,
  467. ProductItemImge,
  468. } from '@/api/index';
  469. import times from '@/assets/Icon/times.png';
  470. import order60 from '@/assets/order60.png';
  471. import targetOne from '@/assets/targetOne.png';
  472. import Network from '@/assets/Network.png';
  473. import ord from '@/assets/ord.png';
  474. import timeico from '@/assets/Icon/datatims.png';
  475. import location from '@/assets/location.png';
  476. import paste from '@/assets/paste.png';
  477. import visitTimes from '@/assets/visitTimes.png';
  478. import mpimg from '@/assets/mpimg.png';
  479. import axios from 'axios';
  480. import mapmarker from '@/components/mapMarkerDouble';
  481. import order from '@/assets/order.png';
  482. import ordernum from '@/assets/ordernum.png';
  483. import sbpmdh from '@/assets/sbpmdh.png';
  484. import request from '@/utils/request';
  485. import call from '@/assets/call.png';
  486. import jiarujihua from '@/assets/jiarujihua.png';
  487. import kehuxinxi from '@/assets/kehuxinxi-2.png';
  488. import xiadan from '@/assets/xiadan.png';
  489. import yichang from '@/assets/yichang.png';
  490. import bfxx from '@/assets/bfxx.png';
  491. import xmgj from '@/assets/xmgj.png';
  492. import { getOrderUrlByStoreId } from '@/api/inventory';
  493. import { checkStoreAddressByStoreCode } from '@/api/visitstore';
  494. import { getPosition, getMapPoi, getkeywordPoi, getTicketFun } from '@/utils/TXApiFun';
  495. export default {
  496. name: 'outsidelist',
  497. components: { tabBar, mapmarker },
  498. data() {
  499. return {
  500. yichang: yichang,
  501. xmgj: xmgj,
  502. bfxx: bfxx,
  503. xiadan: xiadan,
  504. kehuxinxi: kehuxinxi,
  505. jiarujihua: jiarujihua,
  506. call: call,
  507. times: times,
  508. searchShows: false,
  509. paste: paste,
  510. visitTimess: visitTimes,
  511. sbpmdh: sbpmdh,
  512. ordernum: ordernum,
  513. typeShow: false,
  514. mpimg: mpimg,
  515. order: order,
  516. ord: ord,
  517. mapShow: false,
  518. otherShow: false,
  519. Network: Network,
  520. order60: order60,
  521. targetOne: targetOne,
  522. chainName: '',
  523. chainCode: '',
  524. mapShows: false,
  525. activeNames: '1',
  526. showPopover: false,
  527. moreTypeShow: false,
  528. showPopoverVNUM: [],
  529. showPopoverC: [],
  530. showPopoverZ: [],
  531. zyssl: [],
  532. chtczj: [],
  533. noVisit: [],
  534. noOrder: [],
  535. fxNoOrder: [],
  536. storeLabelTypes: [],
  537. // showPopover:false,
  538. location: location,
  539. timeico: timeico,
  540. disabled: false,
  541. timer: null,
  542. flag: true,
  543. show: false,
  544. tabVal: '1',
  545. list: [],
  546. cont: 0,
  547. loading: false,
  548. showPicker: false,
  549. finished: false,
  550. otherbqShow: true,
  551. otherkkdShow: true,
  552. otherfxdShow: true,
  553. otherfxdShow2: true,
  554. otherfxdShow1: true,
  555. typeName: '搜索',
  556. visitEndId: '',
  557. pageSize: 12,
  558. pageNum: 1,
  559. listActive: null,
  560. query: '',
  561. storeName: '',
  562. genDate: '',
  563. storeType: '',
  564. endShow: false,
  565. storeCategory: '',
  566. fromValue: {},
  567. storeTypeList: [],
  568. storeTypeLists: [],
  569. chainsData: [],
  570. serachstype: '',
  571. addShow1: false,
  572. storeCategoryList: '',
  573. result: [],
  574. StoreLabels: [],
  575. CustomerName: '',
  576. lat: '',
  577. lon: '',
  578. timeData: '',
  579. customerVisits: true,
  580. };
  581. },
  582. watch: {
  583. $route(to, from) {
  584. this.storeName = localStorage.getItem('outvstoreName');
  585. this.chainName = localStorage.getItem('outvchainName');
  586. if (localStorage.getItem('lat') != null) {
  587. this.lat = localStorage.getItem('lat');
  588. this.lon = localStorage.getItem('lon');
  589. } else {
  590. this.lat = '';
  591. this.lon = '';
  592. }
  593. if (localStorage.getItem('outvstoreLabelTypes') != null) {
  594. this.storeLabelTypes = localStorage.getItem('outvstoreLabelTypes').split(',');
  595. } else {
  596. this.storeLabelTypes = [];
  597. }
  598. if (localStorage.getItem('outvstoreCategoryList') != null) {
  599. this.result = localStorage.getItem('outvstoreCategoryList').split(',');
  600. this.storeLabelTypes = [];
  601. this.storeCategoryList = this.result.join(',');
  602. } else {
  603. this.result = [];
  604. this.storeCategoryList = this.result.join(',');
  605. }
  606. this.chainCode = localStorage.getItem('outvchainCode');
  607. this.storeName = localStorage.getItem('outvstoreName');
  608. if (
  609. (from.path == '/My/index' && to.path == '/outsidelist/index') ||
  610. (from.path == '/home' && to.path == '/outsidelist/index') ||
  611. (from.path == '/deviceWithin/index' && to.path == '/outsidelist/index') ||
  612. (from.path == '/storemanagement/index' && to.path == '/outsidelist/index')
  613. ) {
  614. this.tabVal = '1';
  615. } else {
  616. if (localStorage.getItem('tabVal') != null) {
  617. this.tabVal = localStorage.getItem('tabVal');
  618. }
  619. }
  620. if (
  621. (from.path == '/storeDetail' && to.path == '/outsidelist/index') ||
  622. (from.path == '/storeGroup' && to.path == '/outsidelist/index') ||
  623. (from.path == '/suishenbangOutstoreVisit' && to.path == '/outsidelist/index') ||
  624. (from.path == '/outabnormalVisit' && to.path == '/outsidelist/index') ||
  625. (from.path == '/home' && to.path == '/outsidelist/index') ||
  626. (from.path == '/deviceWithin/index' && to.path == '/outsidelist/index') ||
  627. (from.path == '/storemanagement/index' && to.path == '/outsidelist/index') ||
  628. (from.path == '/My/index' && to.path == '/outsidelist/index')
  629. ) {
  630. this.onSearch();
  631. }
  632. var postType = localStorage.getItem('postType');
  633. if (postType == 'GZ') {
  634. this.addShow1 = false;
  635. this.otherShow = true;
  636. } else {
  637. this.addShow1 = true;
  638. this.otherShow = false;
  639. }
  640. if (localStorage.getItem('postType') == 'JZ' || localStorage.getItem('postType') == 'GZ') {
  641. this.mapShows = false;
  642. } else {
  643. this.mapShows = true;
  644. }
  645. this.getMonth();
  646. },
  647. },
  648. created() {
  649. this.storeName = localStorage.getItem('outvstoreName');
  650. this.chainName = localStorage.getItem('outvchainName');
  651. if (localStorage.getItem('outvstoreLabelTypes') != null) {
  652. this.storeLabelTypes = localStorage.getItem('outvstoreLabelTypes').split(',');
  653. } else {
  654. this.storeLabelTypes = [];
  655. }
  656. if (localStorage.getItem('outvstoreCategoryList') != null) {
  657. this.result = localStorage.getItem('outvstoreCategoryList').split(',');
  658. this.storeCategoryList = this.result.join(',');
  659. } else {
  660. this.result = [];
  661. this.storeCategoryList = this.result.join(',');
  662. }
  663. this.chainCode = localStorage.getItem('outvchainCode');
  664. this.storeName = localStorage.getItem('outvstoreName');
  665. if (localStorage.getItem('tabVal') == null || this.$route.query.info != 'y') {
  666. if (this.$route.query.info != undefined) {
  667. if (this.$route.query.info.indexOf('y') != -1) {
  668. this.tabVal = localStorage.getItem('tabVal');
  669. } else {
  670. this.tabVal = '1';
  671. }
  672. } else {
  673. this.tabVal = '1';
  674. }
  675. } else {
  676. this.tabVal = localStorage.getItem('tabVal');
  677. }
  678. if (localStorage.getItem('postType') == 'JZ' || localStorage.getItem('postType') == 'GZ') {
  679. this.mapShows = false;
  680. } else {
  681. this.mapShows = true;
  682. }
  683. this.query = this.$route.query;
  684. localStorage.removeItem('visitId');
  685. this.getStoreTypeList();
  686. this.getStoreLabels();
  687. var postType = localStorage.getItem('postType');
  688. if (postType == 'GZ') {
  689. this.addShow1 = false;
  690. this.otherShow = true;
  691. } else {
  692. this.addShow1 = true;
  693. this.otherShow = false;
  694. }
  695. this.getMonth();
  696. },
  697. methods: {
  698. clearFn() {
  699. this.storeName = '';
  700. localStorage.setItem('outvstoreName', '');
  701. },
  702. linkapp(val) {
  703. var poind = this.gcj02BD(val.lat, val.lon);
  704. let url = window.location.href;
  705. let that = this;
  706. let wx = this.wx;
  707. let qiyeData;
  708. const instance = axios.create();
  709. instance.defaults.headers.common['userId'] = localStorage.getItem('loginName');
  710. instance
  711. .get(process.env.VUE_APP_BASE_API + 'mobile/wx/ticket', {
  712. params: {
  713. url: url,
  714. agent: 1,
  715. },
  716. })
  717. .then((response) => {
  718. if (response.status == 200) {
  719. qiyeData = response.data.data;
  720. // wx.config({
  721. // beta: true, // 必须这么写,否则wx.invoke调用形式的jsapi会有问题
  722. // debug: false, // 开启调试模式,调用的所有api的返回值会在客户端alert出来,若要查看传入的参数,可以在pc端打开,参数信息会通过log打出,仅在pc端时才会打印。
  723. // appId: qiyeData.appId, // 必填,企业微信的corpID
  724. // timestamp: qiyeData.timestamp, // 必填,生成签名的时间戳
  725. // nonceStr: qiyeData.nonceStr, // 必填,生成签名的随机串
  726. // signature: qiyeData.signature, // 必填,签名,见 附录-JS-SDK使用权限签名算法
  727. // jsApiList: ["ready", "invoke"]
  728. // });
  729. // wx.ready(function() {
  730. // wx.checkJsApi({
  731. // jsApiList: ["agentConfig", "launchMiniprogram"], // 需要检测的JS接口列表
  732. // success: function(res) {}})})
  733. wx.agentConfig({
  734. corpid: qiyeData.appId, // 必填,企业微信的corpid,必须与当前登录的企业一致
  735. agentid: qiyeData.agentId, // 必填,企业微信的应用id (e.g. 1000247)
  736. timestamp: qiyeData.timestamp, // 必填,生成签名的时间戳
  737. nonceStr: qiyeData.nonceStr, // 必填,生成签名的随机串
  738. signature: qiyeData.signature, // 必填,签名,见附录-JS-SDK使用权限签名算法
  739. jsApiList: ['launchMiniprogram'], //必填,传入需要使用的接口名称
  740. success: function (res) {
  741. wx.invoke(
  742. 'launchMiniprogram',
  743. {
  744. appid: 'wx238bbb5f6d958414',
  745. path:
  746. 'pages/relayStation/relayStation?latitude=' +
  747. poind.lat +
  748. '&longitude=' +
  749. poind.lon +
  750. '&name=' +
  751. val.addressLine,
  752. },
  753. function (res) {
  754. if (res.err_msg == 'launchMiniprogram:ok') {
  755. } else {
  756. }
  757. }
  758. );
  759. },
  760. fail: function (res) {
  761. if (res.errMsg.indexOf('function not exist') > -1) {
  762. alert('版本过低请升级');
  763. }
  764. },
  765. });
  766. }
  767. });
  768. },
  769. orderFn(val) {
  770. getOrderUrlByStoreId({
  771. storeId: val.storeId,
  772. from: 'outPlan',
  773. }).then((res) => {
  774. if (res.code == 200 && res.data) {
  775. window.location.href = res.data;
  776. } else {
  777. this.Toast({
  778. message: res.msg,
  779. duration: 5000,
  780. });
  781. }
  782. });
  783. },
  784. linkList(val) {
  785. this.$router.push({
  786. path: '/pItem',
  787. query: { id: val.storeCode, detilId: 'a' },
  788. });
  789. },
  790. linkimg(val) {
  791. ProductItemImge({ storeId: val.storeId }).then((response) => {
  792. if (response.code == 200) {
  793. if (response.data != undefined) {
  794. window.open(response.data);
  795. } else {
  796. this.$toast(response.msg);
  797. }
  798. } else {
  799. this.$toast(res.msg);
  800. }
  801. });
  802. },
  803. getMonth() {
  804. // 获取当前日期
  805. var currentDate = new Date();
  806. // 获取当前月份
  807. var currentMonth = currentDate.getMonth();
  808. // 获取当前年份
  809. // var currentYear = currentDate.getFullYear();
  810. var previousMonthDate1 = new Date();
  811. if (currentDate.getDate() == 1) {
  812. previousMonthDate1.setMonth(currentMonth - 1);
  813. } else {
  814. }
  815. var previousMonth1 = previousMonthDate1.getMonth();
  816. var previousYear1 = previousMonthDate1.getFullYear();
  817. // 计算前三个月的年份和月份
  818. var previousMonthDate = new Date();
  819. if (currentDate.getDate() == 1) {
  820. previousMonthDate.setMonth(currentMonth - 3);
  821. } else {
  822. previousMonthDate.setMonth(currentMonth - 2);
  823. }
  824. 1;
  825. var previousMonth = previousMonthDate.getMonth();
  826. var previousYear = previousMonthDate.getFullYear();
  827. //前三个月
  828. if (previousYear1 == previousYear) {
  829. var formattedPreviousMonth1 = previousYear1 + '-' + (previousMonth1 + 1);
  830. // 格式化年份和月份
  831. var formattedPreviousMonth = previousYear + '-' + (previousMonth + 1);
  832. this.timeData =
  833. formattedPreviousMonth.split('-')[1] + '-' + formattedPreviousMonth1.split('-')[1] + '月';
  834. } else {
  835. var formattedPreviousMonth1 = previousYear1 + '年' + (previousMonth1 + 1) + '月';
  836. // .toString().padStart(2, '0');
  837. // 格式化年份和月份
  838. var formattedPreviousMonth = previousYear + '年' + (previousMonth + 1) + '月';
  839. this.timeData = formattedPreviousMonth + '-' + formattedPreviousMonth1;
  840. }
  841. },
  842. moreTypeShowFn() {
  843. this.moreTypeShow = true;
  844. // this.CustomerName=""
  845. // this.chainsData=[]
  846. this.getCustomer();
  847. },
  848. buryingPoint(val) {
  849. buryingPoint(val);
  850. },
  851. getCustomer() {
  852. var name = '';
  853. if (this.tabVal != 1) {
  854. name = 'org';
  855. } else {
  856. name = 'my';
  857. }
  858. getCustomerList({ name: this.CustomerName, from: name }).then((request) => {
  859. this.chainsData = request.data;
  860. this.chainsData.push({});
  861. this.chainsData.pop();
  862. });
  863. },
  864. onConfirmChainsList(value) {
  865. if (value.chainName != undefined) {
  866. this.chainName = value.chainName;
  867. this.chainCode = value.chainCode;
  868. }
  869. this.showPickerChainsList = false;
  870. this.moreTypeShow = false;
  871. },
  872. getStoreLabels() {
  873. getStoreLabels().then((res) => {
  874. this.StoreLabels = res.data;
  875. });
  876. },
  877. searchType(val) {
  878. this.storeTypeLists = [];
  879. if (val != '') {
  880. let filterArr = this.storeTypeList.filter((item) => {
  881. return item.dictLabel.toLowerCase().includes(val.toLowerCase());
  882. });
  883. this.storeTypeLists = filterArr;
  884. } else {
  885. this.storeTypeLists = this.storeTypeList;
  886. }
  887. },
  888. onConfirm(value) {
  889. this.storeCategoryList = this.result.join(',');
  890. // this.typeName=value.dictLabel
  891. this.showPicker = false;
  892. this.onSearchm();
  893. },
  894. moreTypeShowclearableFn() {
  895. this.chainName = '';
  896. this.chainCode = '';
  897. this.chainsData = [];
  898. },
  899. onsets() {
  900. this.result = [];
  901. this.zyssl = [];
  902. this.chtczj = [];
  903. this.noVisit = [];
  904. this.noOrder = [];
  905. this.fxNoOrder = [];
  906. this.storeLabelTypes = [];
  907. this.storeCategoryList = this.result.join(',');
  908. this.chainName = '';
  909. this.chainCode = '';
  910. // this.typeName=value.dictLabel
  911. this.onSearch();
  912. },
  913. getStoreTypeList() {
  914. getStoreTypeListlp({}).then((res) => {
  915. this.storeTypeLists = res.data;
  916. this.storeTypeList = res.data;
  917. });
  918. },
  919. buryingPointFn(val) {
  920. this.buryingPoint({
  921. systemModel: '计划外',
  922. buryingPointType: 1,
  923. buryingPointValue: val.telephone,
  924. buryingPointName: '点击电话',
  925. buryingPointPosition: val.storeName + '(' + val.storeCode + ')',
  926. });
  927. },
  928. // 范围
  929. rangeStoreFn() {
  930. localStorage.setItem('tabVal', this.tabVal);
  931. getPosition()
  932. .then((res) => {
  933. let { TXisBD } = res;
  934. this.lat = TXisBD.lat;
  935. this.lon = TXisBD.lon;
  936. let name = this.tabVal != 1 ? '销售部' : '我的';
  937. this.buryingPoint({
  938. systemModel: '计划外',
  939. buryingPointType: 3,
  940. buryingPointValue: name,
  941. buryingPointName: '计划外',
  942. buryingPointPosition: '进入地图',
  943. });
  944. this.$router.push({
  945. path: '/rangeStore',
  946. query: {
  947. lat: '',
  948. lon: '',
  949. tabVal: this.tabVal,
  950. },
  951. });
  952. })
  953. .catch((error) => {
  954. this.$dialog.alert({
  955. message: error,
  956. });
  957. });
  958. // let loading1 = this.$toast.loading({
  959. // duration: 0,
  960. // message: '加载中...',
  961. // forbidClick: true,
  962. // });
  963. // let url = window.location.href;
  964. // let wx = this.wx;
  965. // var that = this;
  966. // let qiyeData;
  967. // const instance = axios.create();
  968. // instance.defaults.headers.common['userId'] = localStorage.getItem('loginName');
  969. // instance
  970. // .get(process.env.VUE_APP_BASE_API + 'mobile/wx/ticket', {
  971. // params: {
  972. // url: url,
  973. // },
  974. // })
  975. // .then((response) => {
  976. // if (response.status == 200) {
  977. // this.cont = 5;
  978. // var flat = true;
  979. // var times = setInterval(() => {
  980. // this.cont--;
  981. // if (this.cont == '0') {
  982. // if (flat) {
  983. // loading1.clear();
  984. // clearInterval(times);
  985. // that.$dialog.alert({
  986. // message: '定位失败,请开启企微定位权限',
  987. // });
  988. // } else {
  989. // clearInterval(times);
  990. // }
  991. // }
  992. // }, 1000);
  993. // qiyeData = response.data.data;
  994. // wx.config({
  995. // beta: true, // 必须这么写,否则wx.invoke调用形式的jsapi会有问题
  996. // debug: false, // 开启调试模式,调用的所有api的返回值会在客户端alert出来,若要查看传入的参数,可以在pc端打开,参数信息会通过log打出,仅在pc端时才会打印。
  997. // appId: qiyeData.appId, // 必填,企业微信的corpID
  998. // timestamp: qiyeData.timestamp, // 必填,生成签名的时间戳
  999. // nonceStr: qiyeData.nonceStr, // 必填,生成签名的随机串
  1000. // signature: qiyeData.signature, // 必填,签名,见 附录-JS-SDK使用权限签名算法
  1001. // jsApiList: ['ready', 'getLocation'], // 必填,需要使用的JS接口列表,凡是要调用的接口都需要传进来
  1002. // });
  1003. // wx.ready(function () {
  1004. // wx.getLocation({
  1005. // type: 'gcj02',
  1006. // success: function (res) {
  1007. // flat = false;
  1008. // loading1.clear();
  1009. // var name = '我的';
  1010. // if (that.tabVal != 1) {
  1011. // name = '销售部';
  1012. // }
  1013. // that.buryingPoint({
  1014. // systemModel: '计划外',
  1015. // buryingPointType: 3,
  1016. // buryingPointValue: name,
  1017. // buryingPointName: '计划外',
  1018. // buryingPointPosition: '进入地图',
  1019. // });
  1020. // that.$router.push({
  1021. // path: '/rangeStore',
  1022. // query: {
  1023. // lat: '',
  1024. // lon: '',
  1025. // tabVal: that.tabVal,
  1026. // },
  1027. // });
  1028. // },
  1029. // fail: function () {
  1030. // loading1.clear();
  1031. // that.$dialog.alert({
  1032. // message: 'GPS未开启',
  1033. // });
  1034. // },
  1035. // });
  1036. // });
  1037. // wx.error(function (res) {
  1038. // loading1.clear();
  1039. // that.$dialog.alert({
  1040. // message: '定位失败,请开启企微定位权限',
  1041. // });
  1042. // });
  1043. // }
  1044. // });
  1045. },
  1046. //取消搜索
  1047. cancelSearch() {
  1048. this.$refs.item.toggle();
  1049. },
  1050. storeJoinVisit(val) {
  1051. joinInPlan({ storeId: val.storeId }).then((res) => {
  1052. if (res.code == 200) {
  1053. this.onSearch();
  1054. } else {
  1055. this.$dialog.alert({
  1056. title: '系统提示',
  1057. message: res.msg,
  1058. });
  1059. }
  1060. });
  1061. },
  1062. searchFn() {
  1063. this.showPicker = true;
  1064. this.CustomerName = '';
  1065. },
  1066. moreSearch() {
  1067. this.onSearch();
  1068. this.$refs.item.toggle();
  1069. },
  1070. getUserOrgStoreList() {
  1071. this.storeType = localStorage.getItem('storeType');
  1072. this.endShow = false;
  1073. if (this.refreshing) {
  1074. this.list = [];
  1075. this.refreshing = false;
  1076. }
  1077. var that = this;
  1078. this.disabled = true;
  1079. let loading2 = this.$toast.loading({
  1080. duration: 0,
  1081. message: '加载中...',
  1082. forbidClick: true,
  1083. });
  1084. getUserOrgStoreList({
  1085. lat: that.lat,
  1086. lon: that.lon,
  1087. chainCode: this.chainCode,
  1088. storeLabelTypes: this.storeLabelTypes.join(','),
  1089. pageNum: this.pageNum,
  1090. storeCategoryList: this.storeCategoryList,
  1091. pageSize: this.pageSize,
  1092. storeName: this.storeName.trim(),
  1093. genDate: this.genDate,
  1094. }).then((res) => {
  1095. this.disabled = false;
  1096. if (res.code == 200) {
  1097. loading2.clear();
  1098. this.loading = false;
  1099. if (this.pageNum == '1') {
  1100. this.list = [];
  1101. }
  1102. this.list = this.list.concat(res.rows);
  1103. if (this.list.length >= res.total) {
  1104. this.finished = true;
  1105. } else {
  1106. this.finished = false;
  1107. }
  1108. this.pageNum = this.pageNum + 1;
  1109. this.list.forEach((item) => {
  1110. if (item.stateString.indexOf('拜访中') != -1) {
  1111. this.endShow = true;
  1112. this.visitEndId = item.visitId;
  1113. return;
  1114. }
  1115. });
  1116. res.rows.forEach((item) => {
  1117. this.showPopoverVNUM.push({ showPopover: false });
  1118. this.showPopoverC.push({ showPopover: false });
  1119. this.showPopoverZ.push({ showPopover: false });
  1120. });
  1121. } else {
  1122. this.$toast(res.msg);
  1123. }
  1124. });
  1125. },
  1126. positionFn(val) {
  1127. const isDevice = localStorage.getItem('isDevice');
  1128. getPosition(isDevice)
  1129. .then((res) => {
  1130. let { TXisBD } = res;
  1131. this.lat = TXisBD.lat;
  1132. this.lon = TXisBD.lon;
  1133. if (val == 1) {
  1134. if (this.tabVal == 1) {
  1135. this.getUserOutPlaListFun();
  1136. } else {
  1137. this.getUserOrgStoreList();
  1138. }
  1139. } else {
  1140. this.getUserOutPlaListFun();
  1141. }
  1142. })
  1143. .catch((error) => {
  1144. this.$dialog.alert({
  1145. message: error,
  1146. });
  1147. });
  1148. // // 本地开发 test 环境时 时跳过获取定位功能
  1149. // if (process.env.NODE_ENV === 'test') {
  1150. // this.lat = 34.62188103091605;
  1151. // this.lon = 112.45364302095416;
  1152. // localStorage.setItem('lat', this.lat);
  1153. // localStorage.setItem('lon', this.lon);
  1154. // if (this.tabVal == 1) {
  1155. // this.getUserOutPlaListFun();
  1156. // } else {
  1157. // this.getUserOrgStoreList();
  1158. // }
  1159. // return;
  1160. // }
  1161. // var that = this;
  1162. // let url = window.location.href;
  1163. // let wx = this.wx;
  1164. // let loadingmap = this.$toast.loading({
  1165. // duration: 0,
  1166. // message: '定位中...',
  1167. // forbidClick: true,
  1168. // });
  1169. // let qiyeData;
  1170. // const instance = axios.create();
  1171. // instance.defaults.headers.common['userId'] = localStorage.getItem('loginName');
  1172. // instance
  1173. // .get(process.env.VUE_APP_BASE_API + 'mobile/wx/ticket', {
  1174. // params: {
  1175. // url: url,
  1176. // },
  1177. // })
  1178. // .then((response) => {
  1179. // console.log('url=' + url);
  1180. // loadingmap.clear();
  1181. // if (response.status == 200) {
  1182. // this.cont = 5;
  1183. // var flat = true;
  1184. // var times = setInterval(() => {
  1185. // this.cont--;
  1186. // if (this.cont == '0') {
  1187. // if (flat) {
  1188. // clearInterval(times);
  1189. // if (val == 1) {
  1190. // that.$dialog.alert({
  1191. // message: '定位失败,请开启企微定位权限',
  1192. // });
  1193. // }
  1194. // loadingmap.clear();
  1195. // } else {
  1196. // clearInterval(times);
  1197. // }
  1198. // }
  1199. // }, 1000);
  1200. // qiyeData = response.data.data;
  1201. // wx.config({
  1202. // beta: true, // 必须这么写,否则wx.invoke调用形式的jsapi会有问题
  1203. // debug: false, // 开启调试模式,调用的所有api的返回值会在客户端alert出来,若要查看传入的参数,可以在pc端打开,参数信息会通过log打出,仅在pc端时才会打印。
  1204. // appId: qiyeData.appId, // 必填,企业微信的corpID
  1205. // timestamp: qiyeData.timestamp, // 必填,生成签名的时间戳
  1206. // nonceStr: qiyeData.nonceStr, // 必填,生成签名的随机串
  1207. // signature: qiyeData.signature, // 必填,签名,见 附录-JS-SDK使用权限签名算法
  1208. // jsApiList: ['ready', 'getLocation'], // 必填,需要使用的JS接口列表,凡是要调用的接口都需要传进来
  1209. // });
  1210. // wx.ready(function () {
  1211. // wx.getLocation({
  1212. // type: 'gcj02',
  1213. // success: function (res) {
  1214. // flat = false;
  1215. // loadingmap.clear();
  1216. // console.log('处理前');
  1217. // console.log(res.latitude, res.longitude);
  1218. // var location = that.CJ02BD(res.latitude, res.longitude);
  1219. // console.log('处理后');
  1220. // console.log(location);
  1221. // that.lat = location.lat;
  1222. // that.lon = location.lon;
  1223. // localStorage.setItem('lat', location.lat);
  1224. // localStorage.setItem('lon', location.lon);
  1225. // if (val == 1) {
  1226. // if (that.tabVal == 1) {
  1227. // that.getUserOutPlaListFun();
  1228. // } else {
  1229. // that.getUserOrgStoreList();
  1230. // }
  1231. // } else {
  1232. // that.getUserOutPlaListFun();
  1233. // }
  1234. // },
  1235. // fail: function () {
  1236. // loadingmap.clear();
  1237. // if (val == 1) {
  1238. // that.$dialog.alert({
  1239. // message: 'GPS未开启',
  1240. // });
  1241. // }
  1242. // },
  1243. // });
  1244. // });
  1245. // wx.error(function (res) {
  1246. // loadingmap.clear();
  1247. // if (val == 1) {
  1248. // that.$dialog.alert({
  1249. // message: '定位失败,请开启企微定位权限',
  1250. // });
  1251. // }
  1252. // });
  1253. // }
  1254. // });
  1255. },
  1256. getUserOutPlaListFun() {
  1257. this.storeType = localStorage.getItem('storeType');
  1258. var that = this;
  1259. this.disabled = true;
  1260. let loading3 = this.$toast.loading({
  1261. duration: 0,
  1262. message: '加载中...',
  1263. forbidClick: true,
  1264. });
  1265. this.endShow = false;
  1266. if (this.refreshing) {
  1267. this.list = [];
  1268. this.refreshing = false;
  1269. }
  1270. getUserOutPlaList({
  1271. lat: that.lat,
  1272. lon: that.lon,
  1273. chainCode: this.chainCode,
  1274. storeLabelTypes: this.storeLabelTypes.join(','),
  1275. pageNum: this.pageNum,
  1276. storeCategoryList: this.storeCategoryList,
  1277. pageSize: this.pageSize,
  1278. storeName: this.storeName.trim(),
  1279. genDate: this.genDate,
  1280. }).then((res) => {
  1281. this.disabled = false;
  1282. if (res.code == 200) {
  1283. loading3.clear();
  1284. this.loading = false;
  1285. this.list = this.list.concat(res.rows);
  1286. if (this.list.length >= res.total) {
  1287. this.finished = true;
  1288. } else {
  1289. this.finished = false;
  1290. }
  1291. this.pageNum = this.pageNum + 1;
  1292. this.list.forEach((item) => {
  1293. if (item.stateString.indexOf('拜访中') != -1) {
  1294. this.endShow = true;
  1295. this.visitEndId = item.visitId;
  1296. return;
  1297. }
  1298. });
  1299. res.rows.forEach(() => {
  1300. this.showPopoverVNUM.push({ showPopover: false });
  1301. this.showPopoverC.push({ showPopover: false });
  1302. this.showPopoverZ.push({ showPopover: false });
  1303. });
  1304. } else {
  1305. this.$toast(res.msg);
  1306. }
  1307. });
  1308. },
  1309. // 获取当前定位数据
  1310. getLocationFun() {
  1311. return new Promise((resolve, reject) => {
  1312. let url = window.location.href;
  1313. // let url = "https://ssbsfatest.nipponpaint.com.cn/mobile"
  1314. let wx = this.wx;
  1315. let qiyeData;
  1316. const instance = axios.create();
  1317. instance.defaults.headers.common['userId'] = localStorage.getItem('loginName');
  1318. instance
  1319. .get(process.env.VUE_APP_BASE_API + 'mobile/wx/ticket', {
  1320. params: {
  1321. url: url,
  1322. },
  1323. })
  1324. .then((response) => {
  1325. if (response.status == 200) {
  1326. this.cont = 5;
  1327. var flat = true;
  1328. var times = setInterval(() => {
  1329. this.cont--;
  1330. if (this.cont == '0') {
  1331. if (flat) {
  1332. clearInterval(times);
  1333. this.$dialog
  1334. .alert({
  1335. message: '定位失败,请开启企微定位权限',
  1336. })
  1337. .then(() => {});
  1338. } else {
  1339. clearInterval(times);
  1340. }
  1341. }
  1342. }, 1000);
  1343. qiyeData = response.data.data;
  1344. wx.config({
  1345. beta: true, // 必须这么写,否则wx.invoke调用形式的jsapi会有问题
  1346. debug: false, // 开启调试模式,调用的所有api的返回值会在客户端alert出来,若要查看传入的参数,可以在pc端打开,参数信息会通过log打出,仅在pc端时才会打印。
  1347. appId: qiyeData.appId, // 必填,企业微信的corpID
  1348. timestamp: qiyeData.timestamp, // 必填,生成签名的时间戳
  1349. nonceStr: qiyeData.nonceStr, // 必填,生成签名的随机串
  1350. signature: qiyeData.signature, // 必填,签名,见 附录-JS-SDK使用权限签名算法
  1351. jsApiList: ['ready', 'getLocation'], // 必填,需要使用的JS接口列表,凡是要调用的接口都需要传进来
  1352. });
  1353. wx.ready(() => {
  1354. wx.getLocation({
  1355. type: 'gcj02',
  1356. success: (res) => {
  1357. flat = false;
  1358. var location = this.CJ02BD(res.latitude, res.longitude);
  1359. resolve({ location, res });
  1360. },
  1361. fail: () => {
  1362. this.$dialog.alert({
  1363. message: 'GPS未开启',
  1364. });
  1365. reject('GPS未开启');
  1366. },
  1367. });
  1368. });
  1369. wx.error(() => {
  1370. this.$dialog
  1371. .alert({
  1372. message: '定位失败,请开启企微定位权限',
  1373. })
  1374. .then(() => {});
  1375. reject('定位失败,请开启企微定位权限');
  1376. });
  1377. }
  1378. });
  1379. });
  1380. },
  1381. storeVisit(val) {
  1382. localStorage.setItem('tabVal', this.tabVal);
  1383. localStorage.removeItem('visitId');
  1384. checkVisit({ storeId: val.storeId }).then((res) => {
  1385. if (this.tabVal == 1) {
  1386. this.buryingPoint({
  1387. systemModel: '计划外',
  1388. buryingPointType: 1,
  1389. buryingPointValue: val.storeName + '(' + val.storeCode + ')',
  1390. buryingPointName: '进店拜访',
  1391. buryingPointPosition: '我的',
  1392. });
  1393. } else {
  1394. this.buryingPoint({
  1395. systemModel: '计划外',
  1396. buryingPointType: 1,
  1397. buryingPointValue: val.storeName + '(' + val.storeCode + ')',
  1398. buryingPointName: '进店拜访',
  1399. buryingPointPosition: '销售部',
  1400. });
  1401. }
  1402. if (res.code == 200 || val.stateString.indexOf('拜访中') != -1) {
  1403. if (localStorage.getItem('loginType') == 'cs') {
  1404. var lat = '';
  1405. var lon = '';
  1406. if (val.lat == '' || val.lat == null) {
  1407. lat = '31.2517820000';
  1408. lon = '120.5593090000';
  1409. } else {
  1410. lat = val.lat;
  1411. lon = val.lon;
  1412. }
  1413. this.$router.push({
  1414. path: '/suishenbangOutstoreVisit',
  1415. query: {
  1416. storeId: val.storeId,
  1417. rdId: val.rdId,
  1418. lat: lat,
  1419. lon: lon,
  1420. visitId: val.visitId,
  1421. pageType: 'out',
  1422. addressLine: val.addressLine,
  1423. storeCategory: val.storeCategory,
  1424. storeName: val.storeName,
  1425. hisTime: val.hisTime,
  1426. contactName: val.contactName,
  1427. storeCode: val.storeCode,
  1428. tabVal: this.tabVal,
  1429. visitModel: '1',
  1430. latNew: '31.2517820000',
  1431. lonNew: '120.5593090000',
  1432. PointSum: 0,
  1433. marklat: lat,
  1434. marklon: lon,
  1435. },
  1436. });
  1437. localStorage.setItem('startTime', new Date());
  1438. localStorage.setItem('ORGName', val.deptName);
  1439. localStorage.setItem('chainNameR', val.storeName);
  1440. } else {
  1441. if (this.flag) {
  1442. this.flag = false;
  1443. this.timer = null;
  1444. let that = this;
  1445. this.timer = setTimeout(() => {
  1446. this.flag = true;
  1447. }, 2000);
  1448. if (val.stateString.indexOf('拜访中') != -1 && val.visitSource == 1) {
  1449. localStorage.setItem('startTime', new Date());
  1450. localStorage.setItem('ORGName', val.deptName);
  1451. localStorage.setItem('chainNameR', val.storeName);
  1452. that.$router.push({
  1453. path: '/suishenbangOutstoreVisit',
  1454. query: {
  1455. storeId: val.storeId,
  1456. rdId: val.rdId,
  1457. lat: val.lat,
  1458. lon: val.lon,
  1459. visitId: val.visitId,
  1460. pageType: 'out',
  1461. addressLine: val.addressLine,
  1462. storeCategory: val.storeCategory,
  1463. storeName: val.storeName,
  1464. hisTime: val.hisTime,
  1465. contactName: val.contactName,
  1466. storeCode: val.storeCode,
  1467. tabVal: that.tabVal,
  1468. visitModel: '1',
  1469. latNew: val.lat,
  1470. lonNew: val.lon,
  1471. PointSum: '0',
  1472. marklat: val.lat,
  1473. marklon: val.lon,
  1474. },
  1475. });
  1476. } else {
  1477. getPosition()
  1478. .then((res) => {
  1479. let { TXisBD, resData } = res;
  1480. this.lat = TXisBD.lat;
  1481. this.lon = TXisBD.lon;
  1482. localStorage.setItem('lat', this.lat);
  1483. localStorage.setItem('lon', this.lon);
  1484. // var location = this.CJ02BD(res.latitude, res.longitude);
  1485. this.checkStoreAddressByStoreCodeFun(val, TXisBD, resData);
  1486. })
  1487. .catch((error) => {
  1488. this.$dialog.alert({
  1489. message: error,
  1490. });
  1491. });
  1492. // // 本地开发 test 环境时 跳过获取定位功能
  1493. // if (process.env.NODE_ENV === 'test') {
  1494. // let res = {
  1495. // latitude: 34.615684509277344,
  1496. // longitude: 112.4474105834961,
  1497. // };
  1498. // this.lat = res.latitude;
  1499. // this.lon = res.longitude;
  1500. // localStorage.setItem('lat', this.lat);
  1501. // localStorage.setItem('lon', this.lon);
  1502. // var location = this.CJ02BD(res.latitude, res.longitude);
  1503. // this.checkStoreAddressByStoreCodeFun(val, location, res);
  1504. // } else {
  1505. // let loading1 = this.$toast.loading({
  1506. // duration: 0,
  1507. // message: '加载中...',
  1508. // forbidClick: true,
  1509. // });
  1510. // this.getLocationFun()
  1511. // .then((resData) => {
  1512. // loading1.clear();
  1513. // let { location, res } = resData;
  1514. // this.checkStoreAddressByStoreCodeFun(val, location, res);
  1515. // })
  1516. // .catch((err) => {
  1517. // console.log(err);
  1518. // loading1.clear();
  1519. // });
  1520. // }
  1521. }
  1522. }
  1523. }
  1524. } else {
  1525. this.$dialog.alert({
  1526. message: res.msg,
  1527. });
  1528. }
  1529. });
  1530. },
  1531. checkStoreAddressByStoreCodeFun(val, location, res) {
  1532. checkStoreAddressByStoreCode({
  1533. storeCode: val.storeCode,
  1534. lon: location.lon,
  1535. lat: location.lat,
  1536. }).then((response) => {
  1537. // loading1.clear();
  1538. if (val.lat == '' || val.lat == null) {
  1539. this.lat = location.lat;
  1540. this.lon = location.lon;
  1541. } else {
  1542. this.lat = val.lat;
  1543. this.lon = val.lon;
  1544. }
  1545. // let PointSum = this.twoPointSum(this.lat, this.lon, location.lat, location.lon).toFixed(2);
  1546. let PointSumval = this.twoPointSum(
  1547. location.lat,
  1548. location.lon,
  1549. location.lat,
  1550. location.lon
  1551. ).toFixed(2);
  1552. // GZ:工装店铺 直接进入拜访
  1553. if (localStorage.getItem('postType') == 'GZ') {
  1554. localStorage.setItem('startTime', new Date());
  1555. localStorage.setItem('ORGName', val.deptName);
  1556. localStorage.setItem('chainNameR', val.storeName);
  1557. this.toSuishenbangOutstoreVisit(res, val, location, PointSumval);
  1558. return;
  1559. }
  1560. // 门店校验 地址不通过
  1561. if (response.code != 200) {
  1562. // updateAddress : ,1:同城AB+金牌,去修改地址;2:非金牌店铺,非同城店铺偏差过大不允许拜访,可以重置定位;0非金牌店铺,非同城店铺 位置信息不存在 可以继续拜访
  1563. if (response.data.updateAddress == 0) {
  1564. // 非金牌店铺,非同城店铺 位置信息不存在 可以继续拜访
  1565. this.$dialog
  1566. .confirm({
  1567. confirmButtonText: '确定拜访',
  1568. cancelButtonText: '取消拜访',
  1569. title: '系统提示',
  1570. message:
  1571. '该客户没有经纬度,此次拜访会保存定位点作为客户经纬度,下次拜访时判断是否偏差过大。',
  1572. closeOnClickOverlay: true,
  1573. })
  1574. .then(() => {
  1575. this.toSuishenbangOutstoreVisit(res, val, location, PointSumval);
  1576. });
  1577. } else if (response.data.updateAddress == 1) {
  1578. // 同城AB+金牌,去修改地址
  1579. // addressUpdateTimesOver: true=已经达到最大次数,不让修改; false=没有达到可以修改
  1580. if (!response.data.addressUpdateTimesOver) {
  1581. this.$dialog
  1582. .confirm({
  1583. title: '系统提示',
  1584. message: response.msg + '请立即修改后再拜访',
  1585. messageAlign: 'left',
  1586. confirmButtonText: '立即修改',
  1587. cancelButtonText: '取消',
  1588. })
  1589. .then(() => {
  1590. this.$router.push({
  1591. path: '/storeDetail',
  1592. query: {
  1593. id: val.storeId,
  1594. type: 'address',
  1595. storeAddressId: val.storeAddressId,
  1596. },
  1597. });
  1598. });
  1599. } else {
  1600. this.$dialog.confirm({
  1601. title: '系统提示',
  1602. message: '已经达到最大修改次数',
  1603. messageAlign: 'left',
  1604. confirmButtonText: '确定',
  1605. });
  1606. }
  1607. } else if (response.data.updateAddress == 2) {
  1608. // 1.非金牌店铺,非同城店铺 位置偏差过大 重置经纬度
  1609. this.resetCoord(res, val, location, PointSumval);
  1610. return;
  1611. }
  1612. } else {
  1613. // 门店编码校验门店地址通过 进入拜访
  1614. this.toSuishenbangOutstoreVisit(res, val, location, PointSumval);
  1615. }
  1616. });
  1617. },
  1618. // 重置经纬度
  1619. resetCoord(res, val, location, PointSumval) {
  1620. this.$dialog
  1621. .confirm({
  1622. confirmButtonText: '初始化定位',
  1623. cancelButtonText: '取消拜访',
  1624. title: '系统提示',
  1625. message: '偏差过大,不允许拜访。可修改本店定位.',
  1626. closeOnClickOverlay: true,
  1627. })
  1628. .then(() => {
  1629. mobileReposition({
  1630. storeId: val.storeId,
  1631. lat: location.lat,
  1632. lon: location.lon,
  1633. }).then((res) => {
  1634. if (res.code == 200) {
  1635. this.$dialog
  1636. .alert({
  1637. title: '系统提示',
  1638. message: '本信息定位已更新成功!',
  1639. })
  1640. .then(() => {
  1641. this.toSuishenbangOutstoreVisit(res, val, location, PointSumval);
  1642. });
  1643. localStorage.setItem('startTime', new Date());
  1644. localStorage.setItem('ORGName', val.deptName);
  1645. localStorage.setItem('chainNameR', val.storeName);
  1646. } else {
  1647. this.$toast(res.msg);
  1648. }
  1649. });
  1650. });
  1651. },
  1652. // 进入拜访 router.push
  1653. toSuishenbangOutstoreVisit(res, val, location, PointSumval) {
  1654. addVisitsPosition({
  1655. storeId: val.storeId,
  1656. visitsId: '',
  1657. lon: res.longitude,
  1658. lat: res.latitude,
  1659. sourceLon: location.lon,
  1660. sourceLat: location.lat,
  1661. positionDesc: '',
  1662. accuracy: res.accuracy,
  1663. });
  1664. this.$router.push({
  1665. path: '/suishenbangOutstoreVisit',
  1666. query: {
  1667. storeId: val.storeId,
  1668. rdId: val.rdId,
  1669. lat: location.lat,
  1670. lon: location.lon,
  1671. visitId: val.visitId,
  1672. pageType: 'out',
  1673. addressLine: val.addressLine,
  1674. storeCategory: val.storeCategory,
  1675. storeName: val.storeName,
  1676. hisTime: val.hisTime,
  1677. contactName: val.contactName,
  1678. storeCode: val.storeCode,
  1679. tabVal: this.tabVal,
  1680. visitModel: '1',
  1681. latNew: location.lat,
  1682. lonNew: location.lon,
  1683. PointSum: PointSumval,
  1684. marklat: res.latitude,
  1685. marklon: res.longitude,
  1686. },
  1687. });
  1688. },
  1689. projectOutVisit(val) {
  1690. localStorage.setItem('tabVal', this.tabVal);
  1691. localStorage.removeItem('visitId');
  1692. // checkVisit({storeId:val.storeId}).then(res=>{
  1693. // if(res.code==200||val.stateString.indexOf("拜访中")!=-1){
  1694. if (localStorage.getItem('loginType') == 'cs') {
  1695. var lat = '';
  1696. var lon = '';
  1697. if (val.lat == '' || val.lat == null) {
  1698. lat = '31.2517820000';
  1699. lon = '120.5593090000';
  1700. } else {
  1701. lat = val.lat;
  1702. lon = val.lon;
  1703. }
  1704. this.$router.push({
  1705. path: '/storeGroup',
  1706. query: {
  1707. storeId: val.storeId,
  1708. rdId: val.rdId,
  1709. lat: lat,
  1710. lon: lon,
  1711. visitId: val.visitId,
  1712. pageType: 'out',
  1713. addressLine: val.addressLine,
  1714. storeCategory: val.storeCategory,
  1715. storeName: val.storeName,
  1716. hisTime: val.hisTime,
  1717. contactName: val.contactName,
  1718. storeCode: val.storeCode,
  1719. tabVal: this.tabVal,
  1720. visitModel: '1',
  1721. latNew: '31.2517820000',
  1722. lonNew: '120.5593090000',
  1723. PointSum: 0,
  1724. marklat: lat,
  1725. marklon: lon,
  1726. },
  1727. });
  1728. localStorage.setItem('startTime', new Date());
  1729. localStorage.setItem('ORGName', val.deptName);
  1730. localStorage.setItem('chainNameR', val.storeName);
  1731. } else {
  1732. if (this.flag) {
  1733. this.flag = false;
  1734. this.timer = null;
  1735. let that = this;
  1736. this.timer = setTimeout(() => {
  1737. this.flag = true;
  1738. }, 2000);
  1739. if (val.stateString.indexOf('拜访中') != -1 && val.visitSource == 1) {
  1740. localStorage.setItem('startTime', new Date());
  1741. localStorage.setItem('ORGName', val.deptName);
  1742. localStorage.setItem('chainNameR', val.storeName);
  1743. that.$router.push({
  1744. path: '/storeGroup',
  1745. query: {
  1746. storeId: val.storeId,
  1747. rdId: val.rdId,
  1748. lat: val.lat,
  1749. lon: val.lon,
  1750. visitId: val.visitId,
  1751. pageType: 'out',
  1752. addressLine: val.addressLine,
  1753. storeCategory: val.storeCategory,
  1754. storeName: val.storeName,
  1755. hisTime: val.hisTime,
  1756. contactName: val.contactName,
  1757. storeCode: val.storeCode,
  1758. tabVal: that.tabVal,
  1759. visitModel: '1',
  1760. latNew: val.lat,
  1761. lonNew: val.lon,
  1762. PointSum: '0',
  1763. marklat: val.lat,
  1764. marklon: val.lon,
  1765. },
  1766. });
  1767. } else {
  1768. let loading1 = this.$toast.loading({
  1769. duration: 0,
  1770. message: '加载中...',
  1771. forbidClick: true,
  1772. });
  1773. let url = window.location.href;
  1774. let wx = this.wx;
  1775. let qiyeData;
  1776. const instance = axios.create();
  1777. instance.defaults.headers.common['userId'] = localStorage.getItem('loginName');
  1778. instance
  1779. .get(process.env.VUE_APP_BASE_API + 'mobile/wx/ticket', {
  1780. params: {
  1781. url: url,
  1782. },
  1783. })
  1784. .then((response) => {
  1785. if (response.status == 200) {
  1786. this.cont = 3;
  1787. var flat = true;
  1788. var times = setInterval(() => {
  1789. this.cont--;
  1790. if (this.cont == '0') {
  1791. if (flat) {
  1792. loading1.clear();
  1793. clearInterval(times);
  1794. that.$dialog
  1795. .alert({
  1796. message: '定位失败,请开启企微定位权限',
  1797. })
  1798. .then(() => {});
  1799. } else {
  1800. clearInterval(times);
  1801. }
  1802. }
  1803. }, 1000);
  1804. qiyeData = response.data.data;
  1805. wx.config({
  1806. beta: true, // 必须这么写,否则wx.invoke调用形式的jsapi会有问题
  1807. debug: false, // 开启调试模式,调用的所有api的返回值会在客户端alert出来,若要查看传入的参数,可以在pc端打开,参数信息会通过log打出,仅在pc端时才会打印。
  1808. appId: qiyeData.appId, // 必填,企业微信的corpID
  1809. timestamp: qiyeData.timestamp, // 必填,生成签名的时间戳
  1810. nonceStr: qiyeData.nonceStr, // 必填,生成签名的随机串
  1811. signature: qiyeData.signature, // 必填,签名,见 附录-JS-SDK使用权限签名算法
  1812. jsApiList: ['ready', 'getLocation'], // 必填,需要使用的JS接口列表,凡是要调用的接口都需要传进来
  1813. });
  1814. wx.ready(function () {
  1815. wx.getLocation({
  1816. type: 'gcj02',
  1817. success: function (res) {
  1818. flat = false;
  1819. loading1.clear();
  1820. var location = that.CJ02BD(res.latitude, res.longitude);
  1821. if (val.lat == '' || val.lat == null) {
  1822. that.lat = location.lat;
  1823. that.lon = location.lon;
  1824. } else {
  1825. that.lat = val.lat;
  1826. that.lon = val.lon;
  1827. }
  1828. let PointSum = that
  1829. .twoPointSum(that.lat, that.lon, location.lat, location.lon)
  1830. .toFixed(2);
  1831. if (val.lat == '' || val.lat == null) {
  1832. if (localStorage.getItem('postType') != 'GZ') {
  1833. that.$dialog
  1834. .confirm({
  1835. confirmButtonText: '确定拜访',
  1836. cancelButtonText: '取消拜访',
  1837. title: '系统提示',
  1838. message:
  1839. '该信息没有经纬度,此次拜访会保存定位点作为信息经纬度,下次拜访时判断是否偏差过大。',
  1840. closeOnClickOverlay: true,
  1841. })
  1842. .then(() => {
  1843. that.$router.push({
  1844. path: '/storeGroup',
  1845. query: {
  1846. storeId: val.storeId,
  1847. rdId: val.rdId,
  1848. lat: that.lat,
  1849. lon: that.lon,
  1850. visitId: val.visitId,
  1851. pageType: 'out',
  1852. addressLine: val.addressLine,
  1853. storeCategory: val.storeCategory,
  1854. storeName: val.storeName,
  1855. contactName: val.contactName,
  1856. hisTime: val.hisTime,
  1857. storeCode: val.storeCode,
  1858. tabVal: that.tabVal,
  1859. visitModel: '1',
  1860. latNew: location.lat,
  1861. lonNew: location.lon,
  1862. PointSum: PointSum,
  1863. marklat: res.latitude,
  1864. marklon: res.longitude,
  1865. },
  1866. });
  1867. });
  1868. } else {
  1869. that.$router.push({
  1870. path: '/storeGroup',
  1871. query: {
  1872. storeId: val.storeId,
  1873. rdId: val.rdId,
  1874. lat: that.lat,
  1875. lon: that.lon,
  1876. visitId: val.visitId,
  1877. pageType: 'out',
  1878. addressLine: val.addressLine,
  1879. storeCategory: val.storeCategory,
  1880. storeName: val.storeName,
  1881. contactName: val.contactName,
  1882. hisTime: val.hisTime,
  1883. storeCode: val.storeCode,
  1884. tabVal: that.tabVal,
  1885. visitModel: '1',
  1886. latNew: location.lat,
  1887. lonNew: location.lon,
  1888. PointSum: PointSum,
  1889. marklat: res.latitude,
  1890. marklon: res.longitude,
  1891. },
  1892. });
  1893. }
  1894. } else {
  1895. that.$router.push({
  1896. path: '/storeGroup',
  1897. query: {
  1898. storeId: val.storeId,
  1899. rdId: val.rdId,
  1900. lat: that.lat,
  1901. lon: that.lon,
  1902. visitId: val.visitId,
  1903. pageType: 'out',
  1904. addressLine: val.addressLine,
  1905. storeCategory: val.storeCategory,
  1906. storeName: val.storeName,
  1907. contactName: val.contactName,
  1908. hisTime: val.hisTime,
  1909. storeCode: val.storeCode,
  1910. tabVal: that.tabVal,
  1911. visitModel: '1',
  1912. latNew: location.lat,
  1913. lonNew: location.lon,
  1914. PointSum: PointSum,
  1915. marklat: res.latitude,
  1916. marklon: res.longitude,
  1917. },
  1918. });
  1919. }
  1920. localStorage.setItem('startTime', new Date());
  1921. localStorage.setItem('ORGName', val.deptName);
  1922. localStorage.setItem('chainNameR', val.storeName);
  1923. addVisitsPosition({
  1924. storeId: val.storeId,
  1925. visitsId: '',
  1926. lon: res.longitude,
  1927. lat: res.latitude,
  1928. sourceLon: location.lon,
  1929. sourceLat: location.lat,
  1930. positionDesc: '',
  1931. accuracy: res.accuracy,
  1932. });
  1933. },
  1934. fail: function () {
  1935. loading1.clear();
  1936. that.$dialog.alert({
  1937. message: 'GPS未开启',
  1938. });
  1939. },
  1940. });
  1941. });
  1942. wx.error(function (res) {
  1943. loading1.clear();
  1944. that.$dialog
  1945. .alert({
  1946. message: '定位失败,请开启企微定位权限',
  1947. })
  1948. .then(() => {});
  1949. });
  1950. }
  1951. });
  1952. }
  1953. }
  1954. }
  1955. // }
  1956. // })
  1957. },
  1958. abnormalVisit(val) {
  1959. localStorage.removeItem('visitId');
  1960. localStorage.setItem('tabVal', this.tabVal);
  1961. checkVisit({ storeId: val.storeId }).then((res) => {
  1962. if (res.code == 200 || val.stateString.indexOf('拜访中') != -1) {
  1963. if (localStorage.getItem('loginType') == 'cs') {
  1964. var lat = '';
  1965. var lon = '';
  1966. if (val.lat == '' || val.lat == null) {
  1967. lat = '31.2517820000';
  1968. lon = '120.5593090000';
  1969. } else {
  1970. lat = val.lat;
  1971. lon = val.lon;
  1972. }
  1973. this.$router.push({
  1974. path: '/outabnormalVisit',
  1975. query: {
  1976. storeId: val.storeId,
  1977. rdId: val.rdId,
  1978. lat: lat,
  1979. lon: lon,
  1980. visitId: val.visitId,
  1981. pageType: 'out',
  1982. addressLine: val.addressLine,
  1983. storeCategory: val.storeCategory,
  1984. storeName: val.storeName,
  1985. hisTime: val.hisTime,
  1986. contactName: val.contactName,
  1987. storeCode: val.storeCode,
  1988. tabVal: this.tabVal,
  1989. visitModel: '3',
  1990. latNew: '31.2517820000',
  1991. lonNew: '120.5593090000',
  1992. PointSum: 0,
  1993. marklat: lat,
  1994. marklon: lon,
  1995. },
  1996. });
  1997. localStorage.setItem('startTime', new Date());
  1998. localStorage.setItem('ORGName', val.deptName);
  1999. localStorage.setItem('chainNameR', val.storeName);
  2000. } else {
  2001. if (this.flag) {
  2002. this.flag = false;
  2003. this.timer = null;
  2004. this.timer = setTimeout(() => {
  2005. this.flag = true;
  2006. }, 2000);
  2007. let loading1 = this.$toast.loading({
  2008. duration: 0,
  2009. message: '加载中...',
  2010. forbidClick: true,
  2011. });
  2012. let url = window.location.href;
  2013. let that = this;
  2014. let wx = this.wx;
  2015. let qiyeData;
  2016. const instance = axios.create();
  2017. instance.defaults.headers.common['userId'] = localStorage.getItem('loginName');
  2018. instance
  2019. .get(process.env.VUE_APP_BASE_API + 'mobile/wx/ticket', {
  2020. params: {
  2021. url: url,
  2022. },
  2023. })
  2024. .then((response) => {
  2025. if (response.status == 200) {
  2026. this.cont = 3;
  2027. var flat = true;
  2028. var times = setInterval(() => {
  2029. this.cont--;
  2030. if (this.cont == '0') {
  2031. if (flat) {
  2032. loading1.clear();
  2033. clearInterval(times);
  2034. that.$dialog
  2035. .alert({
  2036. message: '定位失败,请开启企微定位权限',
  2037. })
  2038. .then(() => {
  2039. this.$router.go(-1);
  2040. });
  2041. } else {
  2042. clearInterval(times);
  2043. }
  2044. }
  2045. }, 1000);
  2046. qiyeData = response.data.data;
  2047. wx.config({
  2048. beta: true, // 必须这么写,否则wx.invoke调用形式的jsapi会有问题
  2049. debug: false, // 开启调试模式,调用的所有api的返回值会在客户端alert出来,若要查看传入的参数,可以在pc端打开,参数信息会通过log打出,仅在pc端时才会打印。
  2050. appId: qiyeData.appId, // 必填,企业微信的corpID
  2051. timestamp: qiyeData.timestamp, // 必填,生成签名的时间戳
  2052. nonceStr: qiyeData.nonceStr, // 必填,生成签名的随机串
  2053. signature: qiyeData.signature, // 必填,签名,见 附录-JS-SDK使用权限签名算法
  2054. jsApiList: ['ready', 'getLocation'], // 必填,需要使用的JS接口列表,凡是要调用的接口都需要传进来
  2055. });
  2056. wx.ready(function () {
  2057. wx.getLocation({
  2058. type: 'gcj02',
  2059. success: function (res) {
  2060. flat = false;
  2061. loading1.clear();
  2062. var location = that.CJ02BD(res.latitude, res.longitude);
  2063. if (val.lat == '' || val.lat == null) {
  2064. that.lat = location.lat;
  2065. that.lon = location.lon;
  2066. } else {
  2067. that.lat = val.lat;
  2068. that.lon = val.lon;
  2069. }
  2070. let PointSum = that
  2071. .twoPointSum(that.lat, that.lon, location.lat, location.lon)
  2072. .toFixed(2);
  2073. if (PointSum > 500 && localStorage.getItem('postType') != 'GZ') {
  2074. that.$dialog
  2075. .confirm({
  2076. confirmButtonText: '确定',
  2077. cancelButtonText: '取消',
  2078. title: '系统提示',
  2079. message: '定位距离偏差大',
  2080. closeOnClickOverlay: true,
  2081. })
  2082. .then(() => {
  2083. that.$router.push({
  2084. path: '/outabnormalVisit',
  2085. query: {
  2086. storeId: val.storeId,
  2087. rdId: val.rdId,
  2088. lat: that.lat,
  2089. lon: that.lon,
  2090. visitId: val.visitId,
  2091. pageType: 'out',
  2092. visitModel: '5',
  2093. storeCode: val.storeCode,
  2094. tabVal: that.tabVal,
  2095. latNew: location.lat,
  2096. lonNew: location.lon,
  2097. PointSum: PointSum,
  2098. marklat: res.latitude,
  2099. marklon: res.longitude,
  2100. },
  2101. });
  2102. localStorage.setItem('startTime', new Date());
  2103. localStorage.setItem('ORGName', val.deptName);
  2104. localStorage.setItem('chainNameR', val.storeName);
  2105. })
  2106. .catch(() => {
  2107. // that.abnormalVisit(val)
  2108. });
  2109. } else {
  2110. that.$router.push({
  2111. path: '/outabnormalVisit',
  2112. query: {
  2113. storeId: val.storeId,
  2114. rdId: val.rdId,
  2115. lat: that.lat,
  2116. lon: that.lon,
  2117. visitId: val.visitId,
  2118. pageType: 'out',
  2119. visitModel: '3',
  2120. storeCode: val.storeCode,
  2121. tabVal: that.tabVal,
  2122. latNew: location.lat,
  2123. lonNew: location.lon,
  2124. PointSum: PointSum,
  2125. marklat: res.latitude,
  2126. marklon: res.longitude,
  2127. },
  2128. });
  2129. localStorage.setItem('startTime', new Date());
  2130. localStorage.setItem('ORGName', val.deptName);
  2131. localStorage.setItem('chainNameR', val.storeName);
  2132. }
  2133. addVisitsPosition({
  2134. storeId: val.storeId,
  2135. visitsId: '',
  2136. lon: res.longitude,
  2137. lat: res.latitude,
  2138. sourceLon: location.lon,
  2139. sourceLat: location.lat,
  2140. positionDesc: '',
  2141. accuracy: res.accuracy,
  2142. });
  2143. },
  2144. fail: function () {
  2145. loading1.clear();
  2146. that.$dialog
  2147. .alert({
  2148. message: 'GPS未开启',
  2149. })
  2150. .then(() => {
  2151. // that.abnormalVisit(val)
  2152. });
  2153. },
  2154. });
  2155. });
  2156. wx.error(function (res) {
  2157. loading1.clear();
  2158. that.$dialog
  2159. .alert({
  2160. message: '定位失败,请开启企微定位权限',
  2161. })
  2162. .then(() => {});
  2163. });
  2164. } else {
  2165. loading1.clear();
  2166. this.$toast.fail(dataList.msg);
  2167. }
  2168. });
  2169. // this.$router.push({path: "/outabnormalVisit", query: {
  2170. // storeId:"179792",
  2171. // rdId:"null",
  2172. // lat:"31.1882020000",
  2173. // lon:"120.6801770000",
  2174. // visitId:"null",
  2175. // visitModel:"5",
  2176. // storeCode:"0190141901",
  2177. // tabVal:"0",
  2178. // latNew:34.621855582632264,
  2179. // lonNew:112.45382530736684,
  2180. // PointSum:857246.44
  2181. // }})
  2182. localStorage.setItem('startTime', new Date());
  2183. localStorage.setItem('ORGName', val.deptName);
  2184. localStorage.setItem('chainNameR', val.storeName);
  2185. }
  2186. }
  2187. } else {
  2188. this.$dialog.alert({
  2189. title: '系统提示',
  2190. message: res.msg,
  2191. });
  2192. }
  2193. });
  2194. },
  2195. visitFn(val) {
  2196. this.$router.push({
  2197. path: '/storeDetail',
  2198. query: { id: val.storeId, detilId: 'a' },
  2199. });
  2200. },
  2201. // 大客户签约
  2202. signAdd(val) {
  2203. this.$router.push({
  2204. path: '/sign',
  2205. query: { id: val.storeId, detilId: 'a' },
  2206. });
  2207. },
  2208. Visit(val) {
  2209. this.$router.push({
  2210. path: '/historicalDetails',
  2211. query: {
  2212. visitId: val.visitId,
  2213. storeId: val.storeId,
  2214. storeCode: val.storeCode,
  2215. },
  2216. });
  2217. },
  2218. onClickLeft() {
  2219. this.$router.go(-1);
  2220. },
  2221. onSearch() {
  2222. window.scrollTo(0, 0);
  2223. this.pageNum = 1;
  2224. this.list = [];
  2225. this.finished = true;
  2226. var postType = localStorage.getItem('postType');
  2227. this.customerVisits = localStorage.getItem('customerVisits');
  2228. if (postType == 'GZ') {
  2229. this.typeShow = false;
  2230. } else {
  2231. this.typeShow = true;
  2232. }
  2233. this.onLoad();
  2234. },
  2235. onSearchm() {
  2236. var postType = localStorage.getItem('postType');
  2237. if (postType == 'GZ') {
  2238. this.typeShow = false;
  2239. } else {
  2240. this.typeShow = true;
  2241. }
  2242. var StoreLabelsArr = [];
  2243. for (var k = 0; k < this.storeLabelTypes.length; k++) {
  2244. for (var k1 = 0; k1 < this.StoreLabels.length; k1++) {
  2245. if (this.StoreLabels[k1].dictValue == this.storeLabelTypes[k]) {
  2246. StoreLabelsArr.push(this.StoreLabels[k1].dictLabel);
  2247. }
  2248. }
  2249. }
  2250. var storeCategoryList = [];
  2251. for (var q = 0; q < this.result.length; q++) {
  2252. for (var q1 = 0; q1 < this.storeTypeLists.length; q1++) {
  2253. if (this.storeTypeLists[q1].dictValue == this.result[q]) {
  2254. storeCategoryList.push(this.storeTypeLists[q1].dictLabel);
  2255. }
  2256. }
  2257. }
  2258. if (this.tabVal == 1) {
  2259. if (this.storeLabelTypes.length > 0) {
  2260. this.buryingPoint({
  2261. systemModel: '计划外',
  2262. buryingPointType: 1,
  2263. buryingPointValue: StoreLabelsArr.join(','),
  2264. buryingPointName: '标签',
  2265. buryingPointPosition: '我的筛选',
  2266. });
  2267. }
  2268. if (this.storeCategoryList.length > 0) {
  2269. this.buryingPoint({
  2270. systemModel: '计划外',
  2271. buryingPointType: 1,
  2272. buryingPointValue: storeCategoryList.join(','),
  2273. buryingPointName: '类型',
  2274. buryingPointPosition: '我的筛选',
  2275. });
  2276. }
  2277. if (this.chainName != '') {
  2278. this.buryingPoint({
  2279. systemModel: '计划外',
  2280. buryingPointType: 1,
  2281. buryingPointValue: this.chainName,
  2282. buryingPointName: '经销商筛选',
  2283. buryingPointPosition: '我的筛选',
  2284. });
  2285. }
  2286. if (this.storeName != '') {
  2287. this.buryingPoint({
  2288. systemModel: '计划外',
  2289. buryingPointType: 1,
  2290. buryingPointValue: this.storeName,
  2291. buryingPointName: '搜索名称/编号/地址',
  2292. buryingPointPosition: '我的筛选',
  2293. });
  2294. }
  2295. } else {
  2296. if (this.storeLabelTypes.length > 0) {
  2297. this.buryingPoint({
  2298. systemModel: '计划外',
  2299. buryingPointType: 1,
  2300. buryingPointValue: StoreLabelsArr.join(','),
  2301. buryingPointName: '标签',
  2302. buryingPointPosition: '销售部的门店筛选',
  2303. });
  2304. }
  2305. if (this.storeCategoryList != '') {
  2306. this.buryingPoint({
  2307. systemModel: '计划外',
  2308. buryingPointType: 1,
  2309. buryingPointValue: storeCategoryList.join(','),
  2310. buryingPointName: '类型',
  2311. buryingPointPosition: '销售部的门店筛选',
  2312. });
  2313. }
  2314. if (this.chainName != '') {
  2315. this.buryingPoint({
  2316. systemModel: '计划外',
  2317. buryingPointType: 1,
  2318. buryingPointValue: this.chainName,
  2319. buryingPointName: '经销商筛选',
  2320. buryingPointPosition: '销售部的门店筛选',
  2321. });
  2322. }
  2323. if (this.storeName != '') {
  2324. this.buryingPoint({
  2325. systemModel: '计划外',
  2326. buryingPointType: 1,
  2327. buryingPointValue: this.storeName,
  2328. buryingPointName: '搜索名称/编号/地址',
  2329. buryingPointPosition: '销售部的门店筛选',
  2330. });
  2331. }
  2332. }
  2333. localStorage.setItem('outvstoreName', this.storeName);
  2334. localStorage.setItem('outvchainName', this.chainName);
  2335. localStorage.setItem('outvstoreLabelTypes', this.storeLabelTypes);
  2336. localStorage.setItem('outvstoreCategoryList', this.result);
  2337. localStorage.setItem('outvchainCode', this.chainCode);
  2338. this.onSearch();
  2339. },
  2340. tabChange(name) {
  2341. window.scrollTo(0, 0);
  2342. this.finished = true;
  2343. this.pageNum = 1;
  2344. this.list = [];
  2345. this.tabVal = name;
  2346. localStorage.setItem('tabVal', name);
  2347. this.onLoad();
  2348. },
  2349. // 滚动条与底部距离小于 offset 时触发 初始化会触发
  2350. onLoad() {
  2351. // 授权
  2352. getTicketFun().then(() => {
  2353. var postType = localStorage.getItem('postType');
  2354. if (postType == 'GZ') {
  2355. this.typeShow = false;
  2356. } else {
  2357. this.typeShow = true;
  2358. }
  2359. if (this.lon == '' && this.tabVal != 1) {
  2360. this.positionFn(1);
  2361. } else {
  2362. if (this.tabVal == 1) {
  2363. this.positionFn();
  2364. // this.getUserOutPlaListFun();
  2365. } else {
  2366. this.getUserOrgStoreList();
  2367. }
  2368. }
  2369. });
  2370. },
  2371. },
  2372. };
  2373. </script>
  2374. <style lang="scss">
  2375. .van-dialog__confirm,
  2376. .van-dialog__confirm:active {
  2377. color: #0057ba;
  2378. }
  2379. .searchDiv {
  2380. .van-search {
  2381. background: #fff;
  2382. }
  2383. .van-search__action {
  2384. font-size: 14px;
  2385. color: #0057ba;
  2386. font-weight: bold;
  2387. background: #f1f1f1;
  2388. border-bottom-right-radius: 60px;
  2389. border-top-right-radius: 60px;
  2390. border: 1px solid #ccc;
  2391. padding: 0 20px;
  2392. }
  2393. .van-search--show-action {
  2394. padding-right: 12px;
  2395. }
  2396. .van-search__content {
  2397. border: 1px solid #ccc;
  2398. border-bottom-left-radius: 60px;
  2399. border-top-left-radius: 60px;
  2400. background: #f1f1f1;
  2401. border-right: 0;
  2402. }
  2403. }
  2404. .myTab {
  2405. .van-tabs__nav--card {
  2406. margin: 0 !important;
  2407. border-left: 0;
  2408. border-right: 0;
  2409. }
  2410. .van-tabs__wrap,
  2411. .van-tabs__nav--card {
  2412. height: 39px;
  2413. }
  2414. .van-tab {
  2415. line-height: 40px;
  2416. }
  2417. }
  2418. .myList {
  2419. .van-cell {
  2420. padding: 0;
  2421. &:after {
  2422. border-bottom: none;
  2423. }
  2424. }
  2425. }
  2426. </style>
  2427. <style lang="scss" scoped>
  2428. .bgcolor {
  2429. background-color: #f5f5f5;
  2430. }
  2431. .container {
  2432. padding-bottom: 50px;
  2433. }
  2434. .card {
  2435. padding: 10px 16px;
  2436. box-sizing: border-box;
  2437. }
  2438. .card .title {
  2439. font-size: 15px;
  2440. font-weight: bold;
  2441. color: #333;
  2442. line-height: 22px;
  2443. padding-right: 52px;
  2444. }
  2445. .card .info {
  2446. font-size: 14px;
  2447. color: #909090;
  2448. line-height: 26px;
  2449. }
  2450. .btnbox {
  2451. padding-top: 14px;
  2452. border-top: 1px solid #eee;
  2453. margin: 0 10px;
  2454. }
  2455. .navBarTOP {
  2456. position: fixed;
  2457. width: 100%;
  2458. z-index: 2;
  2459. top: 0;
  2460. }
  2461. .cellcontent .centerBtn {
  2462. margin: 0 auto 10px;
  2463. display: block;
  2464. width: 92%;
  2465. color: #0057ba;
  2466. border-radius: 5px;
  2467. padding: 0 2px;
  2468. }
  2469. .cellcontent .centerBtn1 {
  2470. background-color: #0057ba;
  2471. color: #fff;
  2472. border-color: #0057ba;
  2473. }
  2474. .cellcontent .centerBtn2 {
  2475. margin: 0 auto 10px;
  2476. display: block;
  2477. width: 92%;
  2478. color: #0057ba;
  2479. border-radius: 5px;
  2480. padding: 0;
  2481. }
  2482. .statstext {
  2483. background-color: #0057ba;
  2484. position: absolute;
  2485. right: 0;
  2486. top: 6px;
  2487. padding: 2px 6px 2px 12px;
  2488. border-bottom-left-radius: 60px;
  2489. border-top-left-radius: 60px;
  2490. color: #fff;
  2491. }
  2492. .cellcontent .van-cell {
  2493. padding: 10px 0;
  2494. }
  2495. .statstext .van-icon__image {
  2496. height: 0.7em;
  2497. }
  2498. .tipsTitle {
  2499. padding: 5px 0;
  2500. text-align: center;
  2501. font-size: 16px;
  2502. font-weight: 600;
  2503. }
  2504. </style>
  2505. <style>
  2506. .van-tabs__nav--card .van-tab.van-tab--active {
  2507. background-color: #0057ba !important;
  2508. }
  2509. .visitSearch {
  2510. width: 68px;
  2511. color: #0057ba;
  2512. font-size: 14px;
  2513. }
  2514. .visitSearch .van-dropdown-menu__bar {
  2515. box-shadow: 0 0 0 #fff;
  2516. height: 52px;
  2517. }
  2518. .visitSearch .van-dropdown-menu__item {
  2519. justify-content: normal;
  2520. }
  2521. .visitSearch .van-dropdown-menu__title {
  2522. border-left: 1px solid #ccc;
  2523. }
  2524. .visitSearch .van-cell {
  2525. border: 1px solid #ccc;
  2526. border-radius: 5px;
  2527. padding: 6px;
  2528. }
  2529. .positionContent {
  2530. position: fixed;
  2531. color: #666;
  2532. display: inline-block;
  2533. box-shadow: 0px 2px 7px -5px #000;
  2534. border-radius: 100px;
  2535. overflow: hidden;
  2536. right: 14px;
  2537. cursor: pointer;
  2538. bottom: 96px;
  2539. background-color: white;
  2540. }
  2541. .positionContent .img {
  2542. border-radius: 100px;
  2543. float: left;
  2544. }
  2545. .positionContent .img .van-icon__image {
  2546. border-radius: 100px;
  2547. }
  2548. .zDialog .van-dialog__header {
  2549. padding: 10px;
  2550. border-bottom: 1px solid #f5f5f5;
  2551. }
  2552. .zDialog .infoText {
  2553. margin: 10px;
  2554. font-size: 14px;
  2555. color: #909090;
  2556. width: 98%;
  2557. }
  2558. .visitStoreIco {
  2559. float: left;
  2560. float: left;
  2561. width: 26px;
  2562. text-align: center;
  2563. background-color: #ffba13;
  2564. color: #fff;
  2565. border-radius: 100%;
  2566. margin-left: 14px;
  2567. line-height: 26px;
  2568. height: 26px;
  2569. }
  2570. .searchcheck {
  2571. padding: 0 10px 10px;
  2572. }
  2573. .searchcheck .van-checkbox {
  2574. /*width: 44%;*/
  2575. padding-bottom: 10px;
  2576. }
  2577. .searchcheck .checkbox {
  2578. font-size: 14px;
  2579. display: inline-block;
  2580. width: 50%;
  2581. line-height: 28px;
  2582. }
  2583. .searchcheck .checkbox .van-checkbox {
  2584. margin-bottom: 2px;
  2585. }
  2586. .searchcheck .checkbox1 {
  2587. font-size: 14px;
  2588. float: left;
  2589. line-height: 28px;
  2590. width: 50%;
  2591. }
  2592. .searchcheck .checkbox1 .child {
  2593. width: 100%;
  2594. }
  2595. .searchcheck {
  2596. height: 93vh;
  2597. overflow-y: auto;
  2598. }
  2599. .searchchecktitle {
  2600. width: 100%;
  2601. margin: 20px 0;
  2602. font-size: 16px;
  2603. border-left: 3px solid #0057ba;
  2604. line-height: 18px;
  2605. }
  2606. .searchchecktitle1 {
  2607. width: 100%;
  2608. margin: 20px 0;
  2609. font-size: 16px;
  2610. line-height: 18px;
  2611. }
  2612. .textsize {
  2613. font-size: 14px;
  2614. }
  2615. </style>