index.vue 39 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455
  1. <template>
  2. <div class="Vbox">
  3. <div class="head">
  4. <div class="VisTitle"></div>
  5. <div class="Vgradation">
  6. <div class="tab" v-for="(item, index) in gradationMun" :key="index" :class="{ active: activeTab === index }"
  7. @click="setActiveTab(index, item)">
  8. {{ item.name }}
  9. </div>
  10. </div>
  11. </div>
  12. <div class="container">
  13. <div class="center">
  14. <div ref="mapContainer" class="allmap"></div>
  15. </div>
  16. <div class="left">
  17. <div class="rightParkBox">
  18. <div class="rightParkTtile">园区概况</div>
  19. <div class="rightParkContent">
  20. <div class="RPCBox" v-for="(item, index) in parkData" :key="index">
  21. <div class="RPCBImg">
  22. <img :src=item.img alt="">
  23. </div>
  24. <div class="RPCBData">
  25. <div class="RPCBDNumber">{{ item.value }}</div>
  26. <div class="RPCBDName" v-html="item.title"></div>
  27. </div>
  28. </div>
  29. </div>
  30. </div>
  31. <div class="leftTwoBox">
  32. <div class="leftGDPTitle">园区生产总值(千元)</div>
  33. <div class="leftGDPContent">
  34. <baseEcharts :NamechartData="NamechartData" :ArrOneData="ArrOneData" :ArrTwoData="ArrTwoData">
  35. </baseEcharts>
  36. </div>
  37. </div>
  38. <div class="leftThreeBox">
  39. <div class="leftTaxationTitle">企业税收TOP10</div>
  40. <el-scrollbar height="calc(100% - 40px)">
  41. <div class="leftTaxationContent">
  42. <div class="LTCKing" v-for="(item, index) in RanKingData" :key="index">
  43. <div class="ranking">
  44. <img :src=item.mig alt="">
  45. </div>
  46. <div class="companyName">{{ item.name }}</div>
  47. <div class="companyValue">{{ item.value }}万元</div>
  48. </div>
  49. </div>
  50. </el-scrollbar>
  51. </div>
  52. <!-- <div>2</div> -->
  53. </div>
  54. <div class="boxBottom">
  55. <div class="parkLoan">
  56. <div class="PCFLTitle">园区特色融资贷款</div>
  57. <div class="PCFLContent">
  58. <div class="PCFLNumber">
  59. <div class="RPCBData" v-for="(item, index) in sumUsingNumber" :key="index">
  60. <div class="RPCBDNumber">{{ item.sum }}(万元)</div>
  61. <div class="RPCBDName">{{ item.name }}</div>
  62. </div>
  63. </div>
  64. <div class="PCFLImg" style="color:white;text-align:center">
  65. <div v-for="(item, index) in sumUsingNumber" :key="index">
  66. <div style="width: 7.5vw;"><img style="width: 100%;" :src=item.img></div>
  67. <span>贷款企业数:{{ item.number }}</span>
  68. </div>
  69. </div>
  70. </div>
  71. </div>
  72. <div class="boxBttTwo">
  73. <div class="businessManagTitle">企业管理</div>
  74. <div class="businessManagContent">
  75. <div class="RPCBox" v-for="(item, index) in business" :key="index">
  76. <div class="RPCBImg">
  77. <img :src=item.img alt="">
  78. </div>
  79. <div class="RPCBData">
  80. <div class="RPCBDName">{{ item.title }}</div>
  81. <div class="RPCBDNumber">{{ item.value }}(家)</div>
  82. <div class="RPCBDRatio">{{ item.ratio }}</div>
  83. </div>
  84. </div>
  85. </div>
  86. </div>
  87. </div>
  88. <div class="right">
  89. <div class="leftOneBox">
  90. <div class="leftOBTitle">企业评价分析</div>
  91. <div class="leftOBContent">
  92. <PieEcharts :message="PieChartData"></PieEcharts>
  93. </div>
  94. </div>
  95. <div class="rightIndustryComplianceBox">
  96. <div class="RICBTitle">企业经营合规</div>
  97. <div class="RICBTContent">
  98. <div class="RICBTCBoxOne">
  99. <div class="" style="
  100. margin-left: 20px;" v-for="(item, index) in hyhgData" :key="index">
  101. <div class="proportion">{{ item.value }}</div>
  102. <div class="administrativeS">{{ item.name }}</div>
  103. </div>
  104. </div>
  105. <div class="RICBTCBoxOne">
  106. <div class="" style="
  107. margin-left: 20px;" v-for="(item, index) in xzqzzxData" :key="index">
  108. <div class="proportion">{{ item.value }}</div>
  109. <div class="administrativeS">{{ item.name }}</div>
  110. </div>
  111. </div>
  112. <!-- <div class="RICBTCBoxTwo"></div> -->
  113. </div>
  114. </div>
  115. <div class="leftOneBox">
  116. <div class="leftOBTitle">风险预警</div>
  117. <el-scrollbar height="calc(100% - 40px)">
  118. <div class="leftOBContent">
  119. <div class="HTB_CB_List">
  120. <div class="HTBCBL_table" v-for="(itemss, index) in ssyjList" :key="index"
  121. :style="{ backgroundImage: 'url(' + itemss.img + ')' }">
  122. <div class="HTBTCL_data">
  123. <div class="HTBTCLD_text"
  124. :style="{ color: itemss.state == 0 ? '#FF0000' : itemss.state == 1 ? '#D9AF36' : '', }">
  125. {{ itemss.name }}
  126. </div>
  127. </div>
  128. <div class="HTBTCL_time">
  129. <div>
  130. {{ itemss.time }}
  131. </div>
  132. </div>
  133. </div>
  134. </div>
  135. <!-- <baseEcharts></baseEcharts> -->
  136. </div>
  137. </el-scrollbar>
  138. </div>
  139. </div>
  140. </div>
  141. </div>
  142. </template>
  143. <script setup>
  144. import one from '@/assets/visualizationimg/one.png';
  145. import two from '@/assets/visualizationimg/two.png';
  146. import three from '@/assets/visualizationimg/three.png';
  147. import four from '@/assets/visualizationimg/four.png';
  148. import five from '@/assets/visualizationimg/five.png';
  149. import six from '@/assets/visualizationimg/six.png';
  150. import seven from '@/assets/visualizationimg/seven.png';
  151. import eight from '@/assets/visualizationimg/eight.png';
  152. import nine from '@/assets/visualizationimg/nine.png';
  153. import ten from '@/assets/visualizationimg/ten.png';
  154. import {ref, onMounted, computed, reactive} from 'vue';
  155. import baseEcharts from '@/components/baseEcharts/index.vue'
  156. import PieEcharts from '@/components/baseEcharts/pieChart.vue'
  157. import sumUsingNumberOne from '@/assets/visualizationimg/onepick.png';
  158. import sumUsingNumberTwo from '@/assets/visualizationimg/twopack.png';
  159. import sumUsingNumberthree from '@/assets/visualizationimg/threepick.png';
  160. import {
  161. getClassificationValueData
  162. , getLngLatValueData
  163. , getCreditScoreList
  164. , getTrossDomesticProduct
  165. , getTopTenTaxation
  166. , getXiaoxiangCaiyinLoan
  167. , getTechnologyLoan
  168. , getHuiyuanLoan
  169. , getNumberOfEnterprises
  170. , getListedCompanies
  171. , getHighTechEnterprises
  172. , getTechnologySmallAndmediumSizedEnterprises
  173. , getPatentInformation
  174. , getAdministrativeSanction
  175. , getAdministrativeEnforcement
  176. , getBusinessAdnormalities
  177. , getDishonestDebtor
  178. , getSocialSecurity, getTaxes
  179. } from '@/api/visualization'
  180. import parkOne from '@/assets/visualizationimg/parkOne.png';
  181. import parktwo from '@/assets/visualizationimg/parktwo.png';
  182. import parkthree from '@/assets/visualizationimg/parkthree.png';
  183. import parkfour from '@/assets/visualizationimg/parkfour.png';
  184. import parkfive from '@/assets/visualizationimg/parkfive.png';
  185. import parksix from '@/assets/visualizationimg/parksix.png';
  186. import gaojingkuang from '@/assets/visualizationimg/gaojingkuang.png';
  187. import zhuyikuang from '@/assets/visualizationimg/zhuyikuang.png';
  188. import {onBeforeUnmount} from 'vue';
  189. import {getLastQuarterYoY2} from '@/api/buscmonitoring';
  190. const mapContainer = ref(null);
  191. let map = null;
  192. let marker = null
  193. const companyNumber = ref();
  194. const data = reactive({
  195. form: {},
  196. queryParams: {
  197. pageNum: 1,
  198. pageSize: 100000,
  199. unifiedSocialCreditCode: '',
  200. condition: "",
  201. grade: null,
  202. total: null
  203. },
  204. })
  205. const {queryParams} = toRefs(data)
  206. const getCurrentQuarter = () => {
  207. const month = new Date().getMonth() + 1;
  208. return Math.ceil(month / 3);
  209. };
  210. const specialQuarter = computed(() => {
  211. let a = getCurrentQuarter()-1;
  212. if(a == 0){
  213. a = 4
  214. }
  215. return a;
  216. })
  217. const specialQuarter2 = computed(() => {
  218. let a = getCurrentQuarter()-2;
  219. if(a == 0){
  220. a = 4
  221. }else if(a == -1){
  222. a = 3
  223. }
  224. return a;
  225. })
  226. const RanKingData = ref([]);
  227. const rankImgIconArr = [one, two, three, four, five, six, seven, eight, nine, ten];
  228. const getTaxTop10 = async () => {
  229. let res = await getLastQuarterYoY2(specialQuarter.value);
  230. console.log(res,7777);
  231. if (res.code == 200) {
  232. if(res.data[0].lastQuarterCurrentTotal == 0){
  233. res = await getLastQuarterYoY2(specialQuarter2.value);
  234. }
  235. res.data = res.data.slice(0, 10);
  236. res.data.forEach(w => w.lastQuarterCurrentTotal = (w.lastQuarterCurrentTotal / 10000).toFixed(2));
  237. res.data.sort((a, b) => b.lastQuarterCurrentTotal - a.lastQuarterCurrentTotal)
  238. RanKingData.value = res.data.map((q, index) => ({
  239. name: q.enterpriseName,
  240. value: q.lastQuarterCurrentTotal,
  241. mig: rankImgIconArr[index]
  242. }))
  243. }
  244. }
  245. getTaxTop10();
  246. const gradationMun = [{
  247. name: "3A级企业",
  248. state: 3,
  249. type: 'AAA'
  250. }, {
  251. name: "2A级企业",
  252. state: 2,
  253. type: 'AA'
  254. }, {
  255. name: "1A级企业",
  256. state: 1,
  257. type: 'A'
  258. }, {
  259. name: "B级企业",
  260. state: 4,
  261. type: 'B'
  262. }, {
  263. name: "C级企业",
  264. state: 5,
  265. type: 'C'
  266. }, {
  267. name: "D级企业",
  268. state: 6,
  269. type: 'D'
  270. }, {
  271. name: "全部企业",
  272. state: 0,
  273. type: ''
  274. }]
  275. const activeTab = ref(6); // 默认激活第一个tab
  276. // const resultArray = ref;
  277. onMounted(async () => {
  278. // 初始化地图
  279. map = new BMapGL.Map(mapContainer.value);
  280. var point = new BMapGL.Point(109.94211746215822, 27.377939585109653);
  281. map.centerAndZoom(point, 15); // 初始化地图,设置中心点坐标和地图级别
  282. map.enableScrollWheelZoom(true);
  283. map.setMinZoom(15);
  284. map.setMaxZoom(19);
  285. map.setMapStyleV2({
  286. styleId: '62ce43ad2a1362c23e612b783d7406e7'
  287. });
  288. map.setTilt(50);
  289. map.disableInertialDragging();
  290. // 定义允许的拖拽范围
  291. const allowedBounds = new BMapGL.Bounds(
  292. new BMapGL.Point(109.90207672119142, 27.365250190931242), // 西南角
  293. new BMapGL.Point(109.97014045715333, 27.422461872492594) // 东北角
  294. );
  295. // 监听拖拽结束事件
  296. map.addEventListener('dragend', function () {
  297. // 获取当前地图的中心点
  298. const center = map.getCenter();
  299. // 检查中心点是否在允许的范围内
  300. if (!allowedBounds.containsPoint(center)) {
  301. // 如果不在范围内,将地图中心调整回允许范围的中心点
  302. const adjustCenter = allowedBounds.getCenter();
  303. map.panTo(adjustCenter);
  304. }
  305. });
  306. // 导入JSON文件
  307. try {
  308. var path = [];
  309. // await Promise.all(
  310. // 假设你有一个json文件,里面包含了管辖区域的边界数据
  311. fetch('jwdata.json').then(response => response.json()).then(data => {
  312. var points = data
  313. for (var j = 0; j < points.length; j++) {
  314. var lng = points[j].split(',')[0];
  315. var lat = points[j].split(',')[1];
  316. path.push(new BMapGL.Point(lng, lat));
  317. }
  318. var prism = new BMapGL.Prism(path, 10, {
  319. topFillColor: '#5679ea',
  320. topFillOpacity: 0.5,
  321. sideFillColor: '#5679ea',
  322. sideFillOpacity: 0.5
  323. });
  324. map.addOverlay(prism);
  325. })
  326. } catch (error) {
  327. // console.error('Error loading JSON data:', error);
  328. }
  329. });
  330. // );
  331. /** 查询用户列表 */
  332. function getClassificationList() {
  333. getLngLatValueData(queryParams.value).then((res) => {
  334. const LNgLatData = res.data;
  335. // console.log("外层", res.data)
  336. getclassData(LNgLatData)
  337. })
  338. }
  339. function getclassData(lngLat) {
  340. getClassificationValueData(queryParams.value).then((res) => {
  341. const array1 = lngLat;
  342. const array2 = res.data.result;
  343. const mergedData = {};
  344. array1.forEach(item => {
  345. mergedData[item.unifiedSocialCreditCode] = {...item};
  346. });
  347. array2.forEach(item => {
  348. if (mergedData[item.unifiedSocialCreditCode]) {
  349. mergedData[item.unifiedSocialCreditCode] = {...mergedData[item.unifiedSocialCreditCode], ...item};
  350. } else {
  351. mergedData[item.unifiedSocialCreditCode] = {...item};
  352. }
  353. });
  354. const resultArray = Object.values(mergedData);
  355. resultArray.forEach(item => {
  356. if (item.grade) {
  357. const markers = new BMapGL.Point(item.longitude, item.latitude)
  358. marker = new BMapGL.Marker(markers)
  359. map.addOverlay(marker);
  360. // 创建信息窗口
  361. var opts = {
  362. width: 300,
  363. // height: 100,
  364. title: item.enterpriseName
  365. };
  366. var infoWindow = new BMapGL.InfoWindow("等级:" + item.grade + "<br/>"
  367. + "统一信用代码:" + item.unifiedSocialCreditCode + "<br/>"
  368. + "总分:" + item.total + "<br/>"
  369. + "负责人:" + item.enterpriseLeader + "<br/>"
  370. + "联系方式:" + item.contactPhone, opts);
  371. // 点标记添加点击事件
  372. marker.addEventListener('click', function () {
  373. map.openInfoWindow(infoWindow, markers); // 开启信息窗口
  374. });
  375. }
  376. })
  377. })
  378. }
  379. const setActiveTab = (index, value) => {
  380. //获取地图上所有的覆盖物
  381. var allOverlay = map.getOverlays();
  382. for (var i = 0; i < allOverlay.length; i++) {
  383. // console.log(11, allOverlay[i].toString())
  384. if (allOverlay[i].toString() == "Marker") {
  385. map.removeOverlay(allOverlay[i]);
  386. }
  387. }
  388. queryParams.value.condition = value.type;
  389. getClassificationList();
  390. activeTab.value = index;
  391. };
  392. getClassificationList()
  393. /** 查询评价分析 */
  394. const PieChartData = ref([]);
  395. function obtainCreditScoreList() {
  396. getCreditScoreList(queryParams.value).then((res) => {
  397. const state1Array = [];
  398. const state2Array = [];
  399. const state3Array = [];
  400. const state4Array = [];
  401. const state5Array = [];
  402. const state6Array = [];
  403. res.data.result.forEach(item => {
  404. if (item.grade === 'AAA') {
  405. state1Array.push(item);
  406. } else if (item.grade === 'AA') {
  407. state2Array.push(item);
  408. } else if (item.grade === 'A') {
  409. state3Array.push(item);
  410. } else if (item.grade === 'B') {
  411. state4Array.push(item);
  412. } else if (item.grade === 'C') {
  413. state5Array.push(item);
  414. } else if (item.grade === 'D') {
  415. state6Array.push(item);
  416. }
  417. PieChartData.value = [
  418. {value: state1Array.length, name: 'AAA'},
  419. {value: state2Array.length, name: 'AA'},
  420. {value: state3Array.length, name: 'A'},
  421. {value: state4Array.length, name: 'B'},
  422. {value: state5Array.length, name: 'C'},
  423. {value: state6Array.length, name: 'D'},
  424. ]
  425. });
  426. })
  427. }
  428. /** 查询产值 */
  429. const NamechartData = ref([]);
  430. const ArrOneData = ref([]);
  431. const ArrTwoData = ref([]);
  432. const currentDate = ref(new Date());//获取季度值
  433. //当前季度
  434. const currentQuarter = computed(() => {
  435. const month = currentDate.value.getMonth();
  436. return Math.floor(month / 3) + 1;
  437. });
  438. //上一个季度
  439. const previousQuarter = computed(() => {
  440. return currentQuarter.value <= 1 ? 4 : currentQuarter.value - 1;
  441. });
  442. //当前年份
  443. const currentYear = computed(() => currentDate.value.getFullYear());
  444. // 上一年
  445. const lastYear = computed(() => currentDate.value.getFullYear() - 1);
  446. const quarterToAmountMap = {
  447. '1': 'firstQuarterAmount',
  448. '2': 'secondQuarterAmount',
  449. '3': 'thirdQuarterAmount',
  450. '4': 'fourthQuarterAmount'
  451. };
  452. function obtaingetTrossDomesticProduct() {
  453. getTrossDomesticProduct(queryParams.value).then((res) => {
  454. const state2023Array = res.reduce((container, item)=>{
  455. if(item.annualAmount == lastYear.value){
  456. container[0] += item.firstQuarterAmount*1;
  457. container[1] += item.secondQuarterAmount*1;
  458. container[2] += item.thirdQuarterAmount*1;
  459. container[3] += item.fourthQuarterAmount*1;
  460. container[4] = container[0] + container[1] + container[2] + container[3];
  461. }
  462. return container;
  463. },[0,0,0,0,0])
  464. const state2024Array = res.reduce((container, item)=>{
  465. if(item.annualAmount == currentYear.value){
  466. container[0] += item.firstQuarterAmount*1;
  467. container[1] += item.secondQuarterAmount*1;
  468. container[2] += item.thirdQuarterAmount*1;
  469. container[3] += item.fourthQuarterAmount*1;
  470. container[4] = container[0] + container[1] + container[2] + container[3];
  471. }
  472. return container;
  473. },[0,0,0,0,0])
  474. const name = ['第一季度', '第二季度', '第三季度', '第四季度','年度'];
  475. NamechartData.value = name;
  476. ArrOneData.value = state2023Array.map(q=>q.toFixed(2))
  477. ArrTwoData.value = state2024Array.map(q=>q.toFixed(2))
  478. // res.forEach(item => {
  479. // if (item.annualAmount == lastYear.value) {
  480. // if (quarterToAmountMap.hasOwnProperty(previousQuarter.value)) {
  481. // const amountProperty = quarterToAmountMap[previousQuarter.value];
  482. // state2023Array.push(item[amountProperty]);
  483. // } else {
  484. // // console.error(`Invalid quarter: ${previousQuarter.value}`);
  485. // }
  486. // name.push(item.enterpriseName)
  487. // } else if (item.annualAmount == currentYear.value) {
  488. // if (quarterToAmountMap.hasOwnProperty(previousQuarter.value)) {
  489. // const amountProperty = quarterToAmountMap[previousQuarter.value];
  490. // state2024Array.push(item[amountProperty]);
  491. // } else {
  492. // // console.error(`Invalid quarter: ${previousQuarter.value}`);
  493. // }
  494. // }
  495. // NamechartData.value = name
  496. // ArrOneData.value = state2023Array
  497. // ArrTwoData.value = state2024Array
  498. // })
  499. // console.log(state2023Array,state2024Array)
  500. })
  501. }
  502. const RanKingDatas = ref([])
  503. /** 查询纳税Top10 */
  504. function obtaingetTopTenTaxation() {
  505. getTopTenTaxation(queryParams.value).then((res) => {
  506. if (quarterToAmountMap.hasOwnProperty(previousQuarter.value)) {
  507. const amountProperty = quarterToAmountMap[previousQuarter.value];
  508. const sortedItems = computed(() => {
  509. return [...res].sort((a, b) => b[amountProperty] - a[amountProperty]);
  510. });
  511. for (var i = 0; i < 10; i++) {
  512. RanKingDatas.value.push({
  513. name: sortedItems.value[i].enterpriseName,
  514. value: sortedItems.value[i].amountProperty
  515. })
  516. }
  517. // console.log("查询纳税Top10:", sortedItems, RanKingDatas)
  518. } else {
  519. // console.error(`Invalid quarter: ${previousQuarter.value}`);
  520. }
  521. })
  522. }
  523. const sumUsingNumber = [
  524. {
  525. sum: '0',
  526. name: '潇湘财银贷',
  527. img: sumUsingNumberOne,
  528. number: ''
  529. }, {
  530. sum: '0',
  531. name: '科技贷',
  532. img: sumUsingNumberTwo,
  533. number: ''
  534. }, {
  535. sum: '0',
  536. name: '惠园贷',
  537. img: sumUsingNumberthree,
  538. number: ''
  539. }
  540. ];
  541. /** 查询潇湘财银贷 */
  542. function obtaingetXiaoxiangCaiyinLoan() {
  543. getXiaoxiangCaiyinLoan(queryParams.value).then((res) => {
  544. const state1Array = [];
  545. res.data.forEach(item => {
  546. state1Array.push(item.currentLoanBalance);
  547. })
  548. // console.log("xxdd", res)
  549. // const sum = state1Array.reduce((accumulator, currentValue) => {
  550. // return accumulator + Number(currentValue);
  551. // }, 0);
  552. sumUsingNumber[0].sum = 7305;
  553. sumUsingNumber[0].number = state1Array.length;
  554. })
  555. }
  556. /** 查询评科技贷: */
  557. function obtaingetTechnologyLoan() {
  558. getTechnologyLoan(queryParams.value).then((res) => {
  559. const state1Array = [];
  560. res.forEach(item => {
  561. state1Array.push(item.loanAmount);
  562. })
  563. const sum = state1Array.reduce((accumulator, currentValue) => {
  564. return accumulator + Number(currentValue);
  565. }, 0);
  566. sumUsingNumber[1].sum = sum;
  567. sumUsingNumber[1].number = state1Array.length;
  568. })
  569. }
  570. /** 惠园贷: */
  571. function obtaingetHuiyuanLoan() {
  572. getHuiyuanLoan(queryParams.value).then((res) => {
  573. const state1Array = [];
  574. res.forEach(item => {
  575. state1Array.push(item.loanAmount);
  576. })
  577. const sum = state1Array.reduce((accumulator, currentValue) => {
  578. return accumulator + Number(currentValue);
  579. }, 0);
  580. sumUsingNumber[2].sum = sum;
  581. sumUsingNumber[2].number = state1Array.length;
  582. })
  583. }
  584. const business = [{
  585. title: '园区纳税企业',
  586. value: 96,
  587. ratio: '80.67%',
  588. state: 1,
  589. img: parkOne
  590. }, {
  591. title: '园区缴纳社保企业',
  592. value: '',
  593. ratio: '',
  594. state: 0,
  595. img: parktwo
  596. }]
  597. /** 查询社保 */
  598. function obtaingetSocialSecurity() {
  599. getSocialSecurity(queryParams.value).then((res) => {
  600. res.data = res.data.filter(q=>q.remarks.includes(currentYear.value));
  601. business[1].value = res.data.length;
  602. business[1].ratio = (res.data.length / companyNumber.value * 100).toFixed(2) + '%';
  603. })
  604. getTaxes().then((res) => {
  605. let result;
  606. let a;
  607. if(res){
  608. a = res.filter(q=>{
  609. return q.annualAmount == currentYear.value-1
  610. })
  611. if(a.length>0){
  612. result = a.length/companyNumber.value*100;
  613. }
  614. }
  615. business[0].value = a.length
  616. business[0].ratio = result.toFixed(2)+'%'
  617. })
  618. }
  619. const parkData = ref([{
  620. title: "(平方公里)<br>占地面积",
  621. value: '11.83',
  622. img: parksix
  623. }])
  624. /** 查询入驻企业、企业数量 */
  625. const obtaingetNumberOfEnterprises = async () => {
  626. const res = await getNumberOfEnterprises(queryParams.value);
  627. parkData.value.push({
  628. title: '入驻企业',
  629. value: res.data.length,
  630. // value: 121,
  631. img: parkOne
  632. })
  633. // companyNumber.value = 121;
  634. companyNumber.value = res.data.length;
  635. }
  636. /** 查询上市企业 */
  637. function obtaingetListedCompanies() {
  638. getListedCompanies('规上').then((res) => {
  639. res.data = [...new Set(res.data.map(item => item.enterpriseName))]
  640. .map(name => res.data.find(item => item.enterpriseName === name))
  641. const ObjectValue = {
  642. title: '规上工业<br>企业数量',
  643. value: res.data.length,
  644. img: parktwo
  645. }
  646. parkData.value.push(ObjectValue)
  647. })
  648. }
  649. /** 查询高新技术企业 */
  650. function obtaingetHighTechEnterprises() {
  651. getHighTechEnterprises(queryParams.value).then((res) => {
  652. const ObjectValue = {
  653. title: '高新技术企业',
  654. value: res.data.length,
  655. img: parkthree
  656. }
  657. parkData.value.push(ObjectValue)
  658. })
  659. }
  660. /** 查询科技中小型企业 */
  661. function obtaingetTechnologySmallAndmediumSizedEnterprises() {
  662. getTechnologySmallAndmediumSizedEnterprises(queryParams.value).then((res) => {
  663. const ObjectValue = {
  664. title: '科技型中小企业',
  665. value: res.data.length,
  666. img: parkfour
  667. }
  668. parkData.value.push(ObjectValue)
  669. })
  670. }
  671. /** 查询专利信息 */
  672. function obtaingetPatentInformation() {
  673. getPatentInformation(queryParams.value).then((res) => {
  674. const ObjectValue = {
  675. title: '园区企业专利数',
  676. value: res.data.length,
  677. img: parkfive
  678. }
  679. parkData.value.push(ObjectValue)
  680. })
  681. }
  682. const hyhgData = ref([])
  683. /** 查询行业合规 */
  684. function obtaingetAdministrativeSanction() {
  685. getAdministrativeSanction(queryParams.value).then((res) => {
  686. hyhgData.value = [{
  687. name: '企业数量',
  688. value: companyNumber.value
  689. }, {
  690. name: '行政处罚',
  691. value: (([...new Set(res.data)].length / companyNumber.value) * 100).toFixed(2) + '%'
  692. }, {
  693. name: '被处罚企业数',
  694. value: [...new Set(res.data)].length
  695. }, {
  696. name: '行政处罚条数',
  697. value: res.data.length
  698. }]
  699. // 企业数量 被处罚企业数 行政处罚条数
  700. })
  701. }
  702. const xzqzzxData = ref([])
  703. /** 查询行政强制执行 */
  704. function obtaingetAdministrativeEnforcement() {
  705. getAdministrativeEnforcement(queryParams.value).then((res) => {
  706. xzqzzxData.value = [{
  707. name: '企业数量',
  708. value: companyNumber.value
  709. }, {
  710. name: '行政强制执行',
  711. value: ([...new Set(res.data.map(item => item.unifiedSocialCreditCode))]
  712. .map(code => res.data.find(item => item.unifiedSocialCreditCode === code)).length / companyNumber.value).toFixed(2) * 100 + '%'
  713. }, {
  714. name: '被执行企业数',
  715. value: [...new Set(res.data.map(item => item.unifiedSocialCreditCode))]
  716. .map(code => res.data.find(item => item.unifiedSocialCreditCode === code)).length
  717. }, {
  718. name: '行政执行条数',
  719. value: res.data.length
  720. }]
  721. })
  722. }
  723. const ssyjList = ref([])
  724. /** 查询经营异常 */
  725. function obtaingetBusinessAdnormalities() {
  726. getBusinessAdnormalities(queryParams.value).then((res) => {
  727. // console.log("查询经营异常:", res)
  728. res.forEach(item => {
  729. const ObjectValue = {
  730. name: item.companyName,
  731. time: '经营异常',
  732. state: 0,
  733. img: gaojingkuang
  734. }
  735. ssyjList.value.push(ObjectValue)
  736. })
  737. })
  738. }
  739. /** 查询失信被执行人 */
  740. function obtaingetDishonestDebtor() {
  741. getDishonestDebtor(queryParams.value).then((res) => {
  742. // console.log("查询失信被执行人:", res)
  743. res.forEach(item => {
  744. const ObjectValue = {
  745. name: item.enterpriseName,
  746. time: '失信被执行人',
  747. state: 1,
  748. img: zhuyikuang
  749. }
  750. ssyjList.value.push(ObjectValue)
  751. })
  752. })
  753. }
  754. const init = async () => {
  755. await obtaingetNumberOfEnterprises();
  756. obtainCreditScoreList();
  757. obtaingetTrossDomesticProduct();
  758. obtaingetTopTenTaxation();
  759. obtaingetXiaoxiangCaiyinLoan();
  760. obtaingetTechnologyLoan();
  761. obtaingetHuiyuanLoan();
  762. obtaingetListedCompanies();
  763. obtaingetHighTechEnterprises();
  764. obtaingetTechnologySmallAndmediumSizedEnterprises();
  765. obtaingetPatentInformation();
  766. obtaingetAdministrativeSanction();
  767. obtaingetAdministrativeEnforcement();
  768. obtaingetBusinessAdnormalities();
  769. obtaingetDishonestDebtor();
  770. obtaingetSocialSecurity();
  771. }
  772. init();
  773. // 如果需要的话,在beforeUnmount中清理资源
  774. onBeforeUnmount(() => {
  775. if (map) {
  776. // 清理地图资源
  777. map.dispose();
  778. map = null;
  779. }
  780. });
  781. </script>
  782. <style scoped lang="scss">
  783. .Vbox {
  784. height: 100vh;
  785. overflow: hidden;
  786. .head {
  787. height: 120px;
  788. top: 0;
  789. width: 100%;
  790. position: absolute;
  791. z-index: 999;
  792. // background-color: rgba($color: #0e2a41, $alpha: .5);
  793. .VisTitle {
  794. height: 60px;
  795. background-image: url("../../assets/visualizationimg/title.png");
  796. }
  797. .Vgradation {
  798. height: 60px;
  799. width: 40vw;
  800. margin-left: 30vw;
  801. display: flex;
  802. //justify-content: center;
  803. align-items: center;
  804. .tab {
  805. width: 100px;
  806. height: 40px;
  807. margin: 0 10px;
  808. text-align: center;
  809. line-height: 40px;
  810. color: white;
  811. font-weight: 500;
  812. font-size: 0.9vw;
  813. background-image: url("../../assets/visualizationimg/headg.png");
  814. background-size: 100% 100%;
  815. }
  816. .active {
  817. background-image: url("../../assets/visualizationimg/headgactive.png");
  818. background-size: 100% 100%;
  819. }
  820. }
  821. }
  822. .container {
  823. height: 100%;
  824. position: relative;
  825. .left {
  826. left: 20px;
  827. float: left;
  828. position: relative;
  829. margin-left: -100%;
  830. width: 26vw;
  831. // background-color: rgba($color: #000000, $alpha: 0.2);
  832. height: 100%;
  833. top: 60px;
  834. z-index: 999;
  835. .rightParkBox {
  836. height: 30%;
  837. background-color: rgba($color: #000000, $alpha: .6);
  838. margin-bottom: 14px;
  839. .leftOBTitle,
  840. .rightParkTtile,
  841. .RICBTitle {
  842. height: 40px;
  843. color: white;
  844. line-height: 40px;
  845. padding-left: 60px;
  846. font-weight: bold;
  847. background-image: url("../../assets/visualizationimg/centertitle.png");
  848. background-size: 100% 100%;
  849. }
  850. .leftOBContent {
  851. height: calc(100% - 40px);
  852. .HTB_CB_List {
  853. width: 100%;
  854. .HTBCBL_table {
  855. margin-top: 5px;
  856. // border-radius: 10px;
  857. height: 34px;
  858. padding: 0 10px;
  859. background-size: 100% 100%;
  860. display: flex;
  861. align-items: center;
  862. justify-content: space-between;
  863. .HTBTCL_data {
  864. display: flex;
  865. align-items: center;
  866. margin-top: 5px;
  867. img {
  868. width: 16px;
  869. height: 14px;
  870. margin-right: 5px;
  871. }
  872. .HTBTCLD_text {
  873. font-size: 19px;
  874. }
  875. }
  876. .HTBTCL_time {
  877. font-size: 15px;
  878. display: flex;
  879. margin-top: 2px;
  880. img {
  881. width: 100px;
  882. }
  883. div {
  884. color: #ddd;
  885. }
  886. }
  887. }
  888. }
  889. }
  890. .rightParkContent {
  891. height: calc(100% - 40px);
  892. display: grid;
  893. grid-template-columns: repeat(3, 33.33%);
  894. grid-template-rows: repeat(2, 50%);
  895. align-items: center;
  896. .RPCBox {
  897. width: 100%;
  898. height: 70%;
  899. display: flex;
  900. align-items: center;
  901. // justify-content: center;
  902. .RPCBImg {
  903. width: 60px;
  904. height: 60px;
  905. }
  906. .RPCBData {
  907. margin-left: 10px;
  908. .RPCBDNumber {
  909. font-weight: normal;
  910. font-size: 1.2vw;
  911. color: #21F2FF;
  912. }
  913. .RPCBDName {
  914. font-weight: 500;
  915. font-size: 0.7vw;
  916. color: #C9E2FF;
  917. }
  918. }
  919. }
  920. }
  921. .RICBTContent {
  922. height: calc(100% - 40px);
  923. display: grid;
  924. grid-template-columns: repeat(1, 100%);
  925. grid-template-rows: repeat(2, 50%);
  926. align-items: center;
  927. justify-content: center;
  928. .RICBTCBoxOne {
  929. width: 100%;
  930. height: 100%;
  931. background-image: url("../../assets/visualizationimg/imdustryCompliance.png");
  932. background-size: 100% 100%;
  933. display: flex;
  934. justify-content: space-around;
  935. align-items: center;
  936. .proportion {
  937. font-weight: bold;
  938. font-size: 34px;
  939. color: #3BA9FF;
  940. line-height: 25px;
  941. }
  942. .administrativeS {
  943. font-weight: normal;
  944. font-size: 14px;
  945. color: #F8FEFF;
  946. line-height: 25px;
  947. }
  948. }
  949. }
  950. }
  951. .leftTwoBox {
  952. height: 30%;
  953. background-color: rgba($color: #000000, $alpha: .6);
  954. margin-bottom: 14px;
  955. .leftOBTitle,
  956. .leftGDPTitle,
  957. .leftTaxationTitle {
  958. height: 40px;
  959. color: white;
  960. line-height: 40px;
  961. padding-left: 60px;
  962. font-weight: bold;
  963. background-image: url("../../assets/visualizationimg/centertitle.png");
  964. background-size: 100% 100%;
  965. }
  966. .leftOBContent,
  967. .leftGDPContent,
  968. .leftTaxationContent {
  969. height: calc(100% - 40px);
  970. .LTCKing {
  971. display: flex;
  972. color: white;
  973. // justify-content: space-between;
  974. align-items: center;
  975. background-image: url("../../assets/visualizationimg/rankingbu.png");
  976. background-size: 100% 100%;
  977. padding: 10px 10px;
  978. .ranking {
  979. width: 25px;
  980. height: 25px;
  981. margin-right: 10px;
  982. img {
  983. width: 25px;
  984. height: 25px;
  985. }
  986. }
  987. .companyName {
  988. flex: 1;
  989. font-size: 1vw;
  990. font-weight: 500;
  991. }
  992. .companyValue {
  993. color: #DFD92C;
  994. }
  995. }
  996. }
  997. }
  998. .leftOneBox,
  999. .leftThreeBox {
  1000. height: 30%;
  1001. background-color: rgba($color: #000000, $alpha: .6);
  1002. margin-bottom: 14px;
  1003. .leftOBTitle,
  1004. .leftGDPTitle,
  1005. .leftTaxationTitle {
  1006. height: 40px;
  1007. color: white;
  1008. line-height: 40px;
  1009. padding-left: 60px;
  1010. font-weight: bold;
  1011. background-image: url("../../assets/visualizationimg/centertitle.png");
  1012. background-size: 100% 100%;
  1013. }
  1014. .leftOBContent,
  1015. .leftGDPContent,
  1016. .leftTaxationContent {
  1017. height: calc(100% - 40px);
  1018. .LTCKing {
  1019. display: flex;
  1020. color: white;
  1021. // justify-content: space-between;
  1022. align-items: center;
  1023. background-image: url("../../assets/visualizationimg/rankingbu.png");
  1024. background-size: 100% 100%;
  1025. padding: 10px 10px;
  1026. .ranking {
  1027. width: 25px;
  1028. height: 25px;
  1029. margin-right: 10px;
  1030. img {
  1031. width: 25px;
  1032. height: 25px;
  1033. }
  1034. }
  1035. .companyName {
  1036. flex: 1;
  1037. font-size: 1vw;
  1038. font-weight: 500;
  1039. }
  1040. .companyValue {
  1041. color: #DFD92C;
  1042. }
  1043. }
  1044. }
  1045. }
  1046. }
  1047. .boxBottom {
  1048. position: absolute;
  1049. z-index: 999;
  1050. height: 150px;
  1051. bottom: 0;
  1052. width: 45vw;
  1053. left: 27.5vw;
  1054. display: flex;
  1055. .parkLoan {
  1056. width: 50%;
  1057. height: 100%;
  1058. background-color: rgba($color: #000000, $alpha: .6);
  1059. .PCFLTitle {
  1060. height: 40px;
  1061. color: white;
  1062. line-height: 40px;
  1063. padding-left: 60px;
  1064. font-weight: bold;
  1065. background-image: url("../../assets/visualizationimg/centertitle.png");
  1066. background-size: 100% 100%;
  1067. }
  1068. .PCFLContent {
  1069. height: calc(100% - 40px);
  1070. .PCFLNumber {
  1071. height: 50%;
  1072. display: flex;
  1073. justify-content: space-around;
  1074. align-items: center;
  1075. margin: 0 10px;
  1076. .RPCBData {
  1077. width: 100%;
  1078. .RPCBDNumber {
  1079. font-weight: normal;
  1080. font-size: 1.1vw;
  1081. color: #21F2FF;
  1082. text-align: center;
  1083. }
  1084. .RPCBDName {
  1085. font-weight: 500;
  1086. font-size: 14px;
  1087. text-align: center;
  1088. color: #C9E2FF;
  1089. }
  1090. }
  1091. }
  1092. .PCFLImg {
  1093. margin-top: -50px;
  1094. display: flex;
  1095. justify-content: center;
  1096. align-items: center;
  1097. }
  1098. }
  1099. }
  1100. .boxBttTwo {
  1101. width: 50%;
  1102. height: 100%;
  1103. margin-left: 10px;
  1104. background-color: rgba($color: #000000, $alpha: .6);
  1105. .businessManagTitle {
  1106. height: 40px;
  1107. color: white;
  1108. line-height: 40px;
  1109. padding-left: 60px;
  1110. font-weight: bold;
  1111. background-image: url("../../assets/visualizationimg/centertitle.png");
  1112. background-size: 100% 100%;
  1113. }
  1114. .businessManagContent {
  1115. height: calc(100% - 40px);
  1116. display: flex;
  1117. justify-content: center;
  1118. align-items: center;
  1119. .RPCBox {
  1120. width: 100%;
  1121. height: 70%;
  1122. display: flex;
  1123. align-items: center;
  1124. justify-content: center;
  1125. .RPCBImg {
  1126. width: 60px;
  1127. height: 60px;
  1128. }
  1129. .RPCBData {
  1130. margin-left: 10px;
  1131. .RPCBDNumber {
  1132. font-weight: normal;
  1133. font-size: 1vw;
  1134. color: #21F2FF;
  1135. }
  1136. .RPCBDName {
  1137. font-weight: 500;
  1138. font-size: 0.8vw;
  1139. color: #C9E2FF;
  1140. }
  1141. .RPCBDRatio {
  1142. font-weight: 500;
  1143. font-size: 0.8vw;
  1144. color: #C9E2FF;
  1145. }
  1146. }
  1147. }
  1148. }
  1149. }
  1150. }
  1151. .center {
  1152. float: left;
  1153. height: 100%;
  1154. width: 100%;
  1155. background-color: green;
  1156. .allmap {
  1157. /* // 注意给dom宽高,不然地图不出来 */
  1158. width: 100%;
  1159. height: 100%;
  1160. margin: auto;
  1161. padding: 0;
  1162. }
  1163. }
  1164. .right {
  1165. //right: 20px;
  1166. left: 73vw;
  1167. float: left;
  1168. position: absolute;
  1169. //margin-left: -500px;
  1170. width: 26.5vw;
  1171. // background-color: rgba($color: #000000, $alpha: 0.2);
  1172. height: 100%;
  1173. top: 60px;
  1174. z-index: 999;
  1175. .leftOneBox,
  1176. .rightParkBox,
  1177. .rightIndustryComplianceBox {
  1178. height: 30%;
  1179. background-color: rgba($color: #000000, $alpha: .6);
  1180. margin-bottom: 14px;
  1181. .leftOBTitle,
  1182. .rightParkTtile,
  1183. .RICBTitle {
  1184. height: 40px;
  1185. color: white;
  1186. line-height: 40px;
  1187. padding-left: 60px;
  1188. font-weight: bold;
  1189. background-image: url("../../assets/visualizationimg/centertitle.png");
  1190. background-size: 100% 100%;
  1191. }
  1192. .leftOBContent {
  1193. height: calc(100% - 40px);
  1194. .HTB_CB_List {
  1195. width: 100%;
  1196. .HTBCBL_table {
  1197. margin-top: 5px;
  1198. // border-radius: 10px;
  1199. height: 34px;
  1200. padding: 0 10px;
  1201. background-size: 100% 100%;
  1202. display: flex;
  1203. align-items: center;
  1204. justify-content: space-between;
  1205. .HTBTCL_data {
  1206. display: flex;
  1207. align-items: center;
  1208. margin-top: 5px;
  1209. img {
  1210. width: 16px;
  1211. height: 14px;
  1212. margin-right: 5px;
  1213. }
  1214. .HTBTCLD_text {
  1215. font-size: 1.05vw;
  1216. }
  1217. }
  1218. .HTBTCL_time {
  1219. font-size: 15px;
  1220. display: flex;
  1221. margin-top: 2px;
  1222. img {
  1223. width: 100px;
  1224. }
  1225. div {
  1226. color: #ddd;
  1227. }
  1228. }
  1229. }
  1230. }
  1231. }
  1232. .rightParkContent {
  1233. height: calc(100% - 40px);
  1234. display: grid;
  1235. grid-template-columns: repeat(3, 33.33%);
  1236. grid-template-rows: repeat(2, 50%);
  1237. align-items: center;
  1238. .RPCBox {
  1239. width: 100%;
  1240. height: 70%;
  1241. display: flex;
  1242. align-items: center;
  1243. // justify-content: center;
  1244. .RPCBImg {
  1245. width: 60px;
  1246. height: 60px;
  1247. }
  1248. .RPCBData {
  1249. margin-left: 10px;
  1250. .RPCBDNumber {
  1251. font-weight: normal;
  1252. font-size: 1vw;
  1253. color: #21F2FF;
  1254. }
  1255. .RPCBDName {
  1256. font-weight: 500;
  1257. font-size: 0.8vw;
  1258. color: #C9E2FF;
  1259. }
  1260. }
  1261. }
  1262. }
  1263. .RICBTContent {
  1264. height: calc(100% - 40px);
  1265. display: grid;
  1266. grid-template-columns: repeat(1, 100%);
  1267. grid-template-rows: repeat(2, 50%);
  1268. align-items: center;
  1269. justify-content: center;
  1270. .RICBTCBoxOne {
  1271. width: 100%;
  1272. height: 100%;
  1273. background-image: url("../../assets/visualizationimg/imdustryCompliance.png");
  1274. background-size: 100% 100%;
  1275. display: flex;
  1276. justify-content: space-around;
  1277. align-items: center;
  1278. .proportion {
  1279. font-weight: bold;
  1280. font-size: 1.6vw;
  1281. color: #3BA9FF;
  1282. line-height: 25px;
  1283. }
  1284. .administrativeS {
  1285. font-weight: normal;
  1286. font-size: 14px;
  1287. color: #F8FEFF;
  1288. line-height: 25px;
  1289. }
  1290. }
  1291. }
  1292. }
  1293. }
  1294. }
  1295. }
  1296. </style>