addChart.vue 41 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387
  1. <template>
  2. <div class="addchart-container" id="box">
  3. <span
  4. class="slide-icon slide-right"
  5. @click="isSlideLeft = !isSlideLeft"
  6. v-show="isSlideLeft"
  7. >
  8. <i class="el-icon-d-arrow-right"></i>
  9. </span>
  10. <div class="left-cont" v-show="!isSlideLeft" id="left">
  11. <div class="left-top">
  12. <el-button
  13. type="primary"
  14. @click="saveHandle"
  15. :disabled="chartInfo.ChartType === 5 && tableData.length !== 2"
  16. ><!-- 保存 -->{{$t('Dialog.confirm_save_btn')}}</el-button>
  17. <el-button type="primary" plain @click="$router.back()"><!-- 取消 -->{{$t('Dialog.cancel_btn')}}</el-button>
  18. </div>
  19. <div class="left-min">
  20. <el-form
  21. ref="diaForm"
  22. label-position="top"
  23. label-width="80px"
  24. :model="chartInfo"
  25. :rules="chartRules"
  26. >
  27. <el-form-item :label="$t('EtaChartAddPage.label_chart_type')" prop="ChartType">
  28. <chartTypeSelect v-model="chartInfo.ChartType" style="width:90%"/>
  29. </el-form-item>
  30. <el-form-item :label="$t('EtaChartAddPage.label_chart_theme')" prop="Theme">
  31. <el-select
  32. v-model="chartInfo.ChartThemeId"
  33. placeholder="请选择图表主题"
  34. style="width: 90%"
  35. @change="changeThemeHandle"
  36. >
  37. <el-option
  38. v-for="item in chartThemeArr"
  39. :key="item.ChartThemeId"
  40. :label="item.ChartThemeName"
  41. :value="item.ChartThemeId"
  42. >
  43. </el-option>
  44. </el-select>
  45. </el-form-item>
  46. <el-form-item label="">
  47. <div class="search-cont" v-if="![10,14].includes(chartInfo.ChartType)">
  48. <div>
  49. <label><!-- 选择指标 -->{{$t('Edb.choose_edb')}}:</label>
  50. <el-radio-group v-model="edbFromType">
  51. <el-radio :label="0" style="margin-right: 15px"><!-- ETA指标 -->{{$t('Edb.eta_name')}}</el-radio>
  52. <el-radio :label="1"><!-- ETA预测指标 -->{{$t('Edb.eta_predictor_name')}}</el-radio>
  53. </el-radio-group>
  54. </div>
  55. <el-select
  56. v-model="search_txt"
  57. v-loadMore="searchLoad"
  58. ref="searchRef"
  59. :filterable="!search_txt"
  60. remote
  61. clearable
  62. :placeholder="$t('Edb.InputHolderAll.input_name_orid')"
  63. style="width:90%;margin-top: 10px;display: block;"
  64. :remote-method="searchHandle"
  65. @click.native="inputFocusHandle"
  66. @change="selectTarget($event && searchOptions.find(_ => _.EdbInfoId === $event))"
  67. >
  68. <i slot="prefix" class="el-input__icon el-icon-search"></i>
  69. <el-option
  70. v-for="item in searchOptions"
  71. :key="item.EdbInfoId"
  72. :label="chart_lang==='en'?(item.EdbNameEn||item.EdbName):item.EdbName"
  73. :value="item.EdbInfoId"
  74. :disabled="!item.HaveOperaAuth"
  75. >
  76. <edbDetailPopover :info="item">
  77. <div slot="reference">
  78. <img
  79. :src="$icons.lock_ico2"
  80. width="18"
  81. height="18"
  82. style="vertical-align:middle"
  83. v-if="!item.HaveOperaAuth"
  84. />
  85. {{chart_lang==='en'?(item.EdbNameEn||item.EdbName):item.EdbName }}
  86. </div>
  87. </edbDetailPopover>
  88. </el-option>
  89. </el-select>
  90. </div>
  91. </el-form-item>
  92. <el-form-item :label="$t('Chart.Detail.chart_name')" prop="ChartName">
  93. <el-input
  94. v-model="chartInfo.ChartName"
  95. style="width: 90%"
  96. :placeholder="$t('Dialog.require_vaild')"
  97. clearable
  98. />
  99. </el-form-item>
  100. <el-form-item :label="$t('Chart.Detail.chart_classify')" prop="classify">
  101. <el-cascader
  102. v-model="chartInfo.classify"
  103. :options="classifyOptions"
  104. :props="levelProps"
  105. style="width: 90%"
  106. :placeholder="$t('Chart.InputHolderAll.input_classify')"
  107. />
  108. </el-form-item>
  109. <el-form-item :label="$t('Chart.Detail.chart_unit')" prop="Unit" v-if="[7,11].includes(chartInfo.ChartType)">
  110. <el-select
  111. v-model="chartInfo.Unit"
  112. filterable
  113. allow-create
  114. default-first-option
  115. clearable
  116. @change="changeUnit"
  117. :placeholder="$t('Chart.InputHolderAll.input_common',{label:$t('Chart.Detail.chart_unit')})">
  118. <el-option
  119. v-for="item in UnitOptions"
  120. :key="item.label"
  121. :label="item.label"
  122. :value="item.value">
  123. </el-option>
  124. </el-select>
  125. </el-form-item>
  126. </el-form>
  127. <div class="xaxis-range-cont" v-if="chartInfo.ChartType===2 && tableData && tableData.length>0">
  128. <!-- 仅用于季节性图配置 -->
  129. <div style="margin-bottom: 12px;" class="xaxis-range-tip">
  130. {{$t('EtaChartAddPage.label_xserie_range')}}<!-- 横坐标显示范围 -->
  131. <el-tooltip>
  132. <div slot="content" v-html="$t('EtaChartAddPage.xserie_range_tip')">
  133. </div>
  134. <img src="~@/assets/img/icons/question_mark_black.png" style="height: 16px;cursor: pointer;margin-left: 6px;" />
  135. </el-tooltip>
  136. </div>
  137. <el-date-picker
  138. style="width: 45%;"
  139. v-model="SeasonExtraConfig.XStartDate"
  140. value-format="MM-dd"
  141. popper-class="x-range-picker-date"
  142. format="MM-dd"
  143. :placeholder="$t('Common.ph_time_start')"
  144. @change="xAxisChange"
  145. :clearable="false"
  146. ></el-date-picker>
  147. <el-date-picker
  148. style="width: 45%;"
  149. v-model="SeasonExtraConfig.XEndDate"
  150. value-format="MM-dd"
  151. popper-class="x-range-picker-date"
  152. format="MM-dd"
  153. :placeholder="$t('Common.ph_time_end')"
  154. @change="xAxisChange"
  155. :clearable="false"
  156. ></el-date-picker>
  157. <el-checkbox
  158. :label="$t('EtaChartAddPage.label_cross_year')"
  159. v-model="isSpanYear"
  160. :disabled="isSpanYearDisable"
  161. style="margin-top: 12px;"
  162. @change="changeIsSpanYear"
  163. ></el-checkbox>
  164. <br />
  165. <div class="legend-set-text" @click="openLegendEditDia">
  166. <span>{{$t('EtaChartAddPage.label_legend_set')}}<!-- 图例名称设置 --></span>
  167. <img src="~@/assets/img/icons/edit-blue.png" />
  168. </div>
  169. </div>
  170. <div class="targetset-cont">
  171. <!-- 仅用于散点图配置 -->
  172. <div class="scatter-setting" v-if="chartInfo.ChartType === 5 && tableData.length">
  173. <div style="display: flex;margin-right: 15px;">
  174. <span style="margin-right: 3px"><!-- 散点颜色: -->{{$t('Chart.Detail.scatter_color')}}:</span>
  175. <el-color-picker
  176. v-model="tableData[0].ChartColor"
  177. size="mini"
  178. show-alpha
  179. :predefine="predefineColors"
  180. ></el-color-picker>
  181. </div>
  182. <el-checkbox v-model="tableData[0].IsOrder"><!-- 逆序 -->{{$t('Chart.Detail.re_order')}}</el-checkbox>
  183. </div>
  184. <!-- 配置区 柱形 截面 雷达不需要-->
  185. <el-collapse v-model="activeNames" class="target-list" v-if="tableData.length&&![7,10,11,14].includes(chartInfo.ChartType)">
  186. <el-collapse-item v-for="(item,index) in tableData" :key="item.EdbInfoId" :disabled="[2,5].includes(chartInfo.ChartType)">
  187. <template slot="title">
  188. <span class="text_oneLine">{{currentLang==='en'?(item.EdbNameEn||item.EdbName):item.EdbName}}</span>
  189. <!-- 当为季节性图的第二个轴时,隐藏删除按钮 -->
  190. <i class="el-icon-delete del-icon" @click.stop="delTarget(item)" v-if="!(chartInfo.ChartType===2&&index===1)"></i>
  191. </template>
  192. <ul class="setting-cont" v-if="sameOptionType.includes(chartInfo.ChartType)">
  193. <!-- 堆叠图 或组合图中的堆叠类型 非第一项隐藏配置 -->
  194. <template v-if="showYOptionsHandle(item,index)">
  195. <li>
  196. <el-checkbox v-model="item.IsOrder"><!-- 逆序 -->{{$t('Chart.Detail.re_order')}}</el-checkbox>
  197. </li>
  198. <li>
  199. <el-radio-group v-model="item.IsAxis" size="mini" @input="isChangeEdbAxis=true">
  200. <el-radio-button :label="1"><!-- 左轴 -->{{$t('Chart.Detail.l_axis')}}</el-radio-button>
  201. <el-radio-button :label="0"><!-- 右轴 -->{{$t('Chart.Detail.r_axis')}}</el-radio-button>
  202. <!-- 指标有右轴时才可以选右2轴 不然没有右2这个概念的意义 -->
  203. <el-radio-button
  204. v-if="[1,6].includes(chartInfo.ChartType)"
  205. :label="2"
  206. :disabled="(tableData.findIndex(_ => _.IsAxis===0) === -1)
  207. || (tableData.findIndex(_ => _.IsAxis===0) === index
  208. && tableData.filter(_ => _.IsAxis===0).length === 1)"
  209. ><!-- 右2轴 -->{{$t('Chart.Detail.rtwo_axis')}}</el-radio-button>
  210. </el-radio-group>
  211. </li>
  212. </template>
  213. <li style="min-width: 250px">
  214. <el-radio
  215. v-model="item.EdbInfoType"
  216. :label="1"
  217. @change="getPreviewSplineInfo"
  218. ><!-- 标准指标 -->{{$t('Chart.Detail.stand_lead')}}</el-radio
  219. >
  220. <div style="margin-top: 15px">
  221. <el-radio
  222. v-model="item.EdbInfoType"
  223. :label="0"
  224. style="margin-right: 10px"
  225. @change="getPreviewSplineInfo"
  226. ><!-- 领先指标 -->{{$t('Chart.Detail.leading_lead')}}</el-radio
  227. >
  228. <template v-if="item.EdbInfoType === 0">
  229. <!-- 领先 -->{{$t('EtaChartAddPage.label_lead')}}
  230. <el-input
  231. style="width: 60px"
  232. size="mini"
  233. type="number"
  234. min="0"
  235. v-model="item.LeadValue"
  236. @change="getPreviewSplineInfo"
  237. @keyup.native="filterCode(item)"
  238. ></el-input>
  239. <el-select
  240. v-model="item.LeadUnit"
  241. placeholder=""
  242. style="width: 60px"
  243. size="mini"
  244. @change="getPreviewSplineInfo"
  245. >
  246. <el-option
  247. v-for="item in fre_options"
  248. :key="item"
  249. :label="item"
  250. :value="item"
  251. >
  252. </el-option>
  253. </el-select>
  254. </template>
  255. </div>
  256. </li>
  257. <li>
  258. <div style="display: flex">
  259. <span style="margin-right: 3px"><!-- 线条颜色 -->{{$t('Chart.Detail.line_color')}}:</span>
  260. <el-color-picker
  261. v-model="item.ChartColor"
  262. size="mini"
  263. show-alpha
  264. :predefine="predefineColors"
  265. ></el-color-picker>
  266. </div>
  267. <div style="display: flex;margin-top: 12px" v-if="item.EdbInfoCategoryType === 1">
  268. <span style="margin-right: 3px"><!-- 预测值颜色 -->{{$t('Chart.Detail.predict_color')}}:</span>
  269. <el-color-picker
  270. v-model="item.PredictChartColor"
  271. size="mini"
  272. show-alpha
  273. :predefine="predefineColors"
  274. ></el-color-picker>
  275. </div>
  276. <div
  277. style="margin-top: 12px"
  278. v-if="chartInfo.ChartType === 1
  279. || (chartInfo.ChartType === 6 &&item.ChartStyle==='spline')"
  280. >
  281. <!-- 线条粗细 -->{{$t('Chart.Detail.line_size')}}:
  282. <el-input
  283. style="width: 60px"
  284. size="mini"
  285. type="number"
  286. :min="1"
  287. v-model="item.ChartWidth"
  288. />
  289. </div>
  290. </li>
  291. <li v-if="chartInfo.ChartType === 6">
  292. <div style="display: flex">
  293. <span style="margin-right: 3px"><!-- 生成样式 -->{{$t('Chart.label_create_sty')}}:</span>
  294. <el-select
  295. v-model="item.ChartStyle"
  296. placeholder="请选择生成样式"
  297. style="width: 50%"
  298. class="edb-item-style"
  299. >
  300. <el-option
  301. v-for="item in chartItemStyleArr"
  302. :key="item.key"
  303. :label="item.label"
  304. :value="item.value"
  305. >
  306. </el-option>
  307. </el-select>
  308. </div>
  309. </li>
  310. </ul>
  311. <div style="margin: 10px;text-align: center;color: #999;" v-else><!-- 暂无配置 -->{{$t('EtaChartAddPage.no_set_msg')}}</div>
  312. </el-collapse-item>
  313. </el-collapse>
  314. <!-- 奇怪柱状图配置 雷达图也要用 -->
  315. <bar-option
  316. v-if="[7,11].includes(chartInfo.ChartType)"
  317. ref="BarOptRef"
  318. :chartInfo="chartInfo"
  319. :edblist="tableData"
  320. :datedata="chartInfo.ChartType===7?barDateList:radarChartData.YDataList"
  321. @getData="barOptionPreviewMap"
  322. />
  323. <!-- 截面散点图 -->
  324. <sectional-scatter-option
  325. v-if="chartInfo.ChartType===10"
  326. ref="SectionScatterOptRef"
  327. :chartInfo="chartInfo"
  328. @getData="getSectionScatterData"
  329. @modifySeriesName="IsNameDefault = false"
  330. />
  331. <!-- 截面组合图 -->
  332. <sectional-combination-option
  333. ref="sectionalCombinationIns"
  334. v-if="chartInfo.ChartType===14"
  335. :chartInfo="chartInfo"
  336. :defaultData="sectionalCombinationData"
  337. @getData="getSectionalCombination"
  338. @hideChart="tableData=[];"
  339. @updateChart="handleUpdateSectionalCombinationChart"
  340. />
  341. <!-- 标识区 标记线 图表说明 -->
  342. <markersSection
  343. v-if="tableData.length"
  344. ref="markerSectionRef"
  345. :chartInfo="chartInfo"
  346. :tableData="tableData"
  347. @update="setChartMarkerInfo"
  348. @updateSeason="updateSeasonChart"
  349. @previewSeason="previewSeasonChart"
  350. @previewSeasonRight="previewSeasonRight"
  351. />
  352. </div>
  353. </div>
  354. <span
  355. class="move-btn resize"
  356. v-drag
  357. id="resize"
  358. ></span>
  359. <span class="slide-icon slide-left" @click="isSlideLeft = !isSlideLeft">
  360. <i class="el-icon-d-arrow-left"></i>
  361. </span>
  362. </div>
  363. <div class="right-cont" id="right" :style="isSlideLeft ? 'width:100%' : `width:80%`">
  364. <div class="chart-min-cont" v-if="tableData.length">
  365. <div class="cont-top">
  366. <div class="top-left">
  367. <!-- 默认曲线图 -->
  368. <template v-if="sameOptionType.includes(chartInfo.ChartType)">
  369. <el-button
  370. type="primary"
  371. v-for="item in yearSelector"
  372. :key="item.value"
  373. size="medium"
  374. :plain="item.value !== year_select"
  375. class="year-btn"
  376. @click.native="changeYear(item)"
  377. >{{ item.name }}</el-button
  378. >
  379. <el-button type="text" class="btn-sty" @click="openDateDia">{{
  380. dateTip
  381. }}</el-button>
  382. </template>
  383. <!-- 季节性图选择年份区间 -->
  384. <!-- <date-picker
  385. v-else-if="chartInfo.ChartType === 2"
  386. v-model="season_year"
  387. type="month"
  388. value-type="format"
  389. range
  390. placeholder="年份日期选择"
  391. @change="seasonYearChange"
  392. /> -->
  393. <div v-else-if="chartInfo.ChartType === 2" @click="openDateDia" class="date-setting">
  394. {{ season_year && season_year.length>0 ? season_year[0]+'~'+season_year[1]:"年份日期选择" }}
  395. </div>
  396. </div>
  397. </div>
  398. <div class="cont-bottom">
  399. <div class="chart-show-cont" v-show="options.series">
  400. <div class="chartWrapper" id="chartWrapper">
  401. <h2
  402. class="chart-title"
  403. v-show="chartInfo.ChartName"
  404. :style="`
  405. textAlign:${JSON.parse(chartInfo.ChartThemeStyle).titleOptions.align};
  406. fontSize:${JSON.parse(chartInfo.ChartThemeStyle).titleOptions.style.fontSize}px;
  407. color:${JSON.parse(chartInfo.ChartThemeStyle).titleOptions.style.color}
  408. `"
  409. >
  410. {{ chartInfo.ChartName }}
  411. </h2>
  412. <Chart :options="options" :chartInfo="chartInfo" ref="chartRef"/>
  413. <!-- <div class="range-cont left" v-if="leftIndex != -1">
  414. <el-input
  415. style="width: 60px; display: block"
  416. size="mini"
  417. type="number"
  418. placeholder="上限"
  419. v-model="tableData[leftIndex].MaxData"
  420. />
  421. <el-input
  422. class="min-data-input"
  423. size="mini"
  424. type="number"
  425. placeholder="下限"
  426. v-model="tableData[leftIndex].MinData"
  427. />
  428. </div>
  429. <div class="range-cont right" v-if="rightIndex != -1">
  430. <el-input
  431. style="width: 60px; display: block"
  432. size="mini"
  433. type="number"
  434. placeholder="上限"
  435. v-model="tableData[rightIndex].MaxData"
  436. />
  437. <el-input
  438. class="min-data-input"
  439. size="mini"
  440. type="number"
  441. placeholder="下限"
  442. v-model="tableData[rightIndex].MinData"
  443. />
  444. </div>
  445. <div class="range-cont rightTwo" v-if="rightTwoIndex != -1">
  446. <el-input
  447. style="width: 60px; display: block"
  448. size="mini"
  449. type="number"
  450. placeholder="上限"
  451. v-model="tableData[rightTwoIndex].MaxData"
  452. />
  453. <el-input
  454. class="min-data-input"
  455. size="mini"
  456. type="number"
  457. placeholder="下限"
  458. v-model="tableData[rightTwoIndex].MinData"
  459. />
  460. </div> -->
  461. <!-- 需求:曲线图、堆积柱状图、组合图加入新指标时上下限自动调整 -->
  462. <template v-if="![7,10,11].includes(chartInfo.ChartType)">
  463. <div class="range-cont left" v-if="leftIndex !== -1">
  464. <el-input
  465. style="width: 60px; display: block"
  466. size="mini"
  467. type="number"
  468. placeholder="上限"
  469. v-model="chartLimit.max"
  470. @change="changeLimit"
  471. />
  472. <el-input
  473. class="min-data-input"
  474. size="mini"
  475. type="number"
  476. placeholder="下限"
  477. v-model="chartLimit.min"
  478. @change="changeLimit"
  479. />
  480. </div>
  481. <div class="range-cont right" v-if="rightIndex !== -1">
  482. <el-input
  483. style="width: 60px; display: block"
  484. size="mini"
  485. type="number"
  486. placeholder="上限"
  487. v-model="chartLimit.rightMax"
  488. @change="changeLimit"
  489. />
  490. <el-input
  491. class="min-data-input"
  492. size="mini"
  493. type="number"
  494. placeholder="下限"
  495. v-model="chartLimit.rightMin"
  496. @change="changeLimit"
  497. />
  498. </div>
  499. <!-- 右2上下限设置 -->
  500. <div class="range-cont rightTwo" v-if="rightTwoIndex !== -1">
  501. <el-input
  502. style="width: 60px; display: block"
  503. size="mini"
  504. type="number"
  505. placeholder="上限"
  506. v-model="chartLimit.rightTwoMax"
  507. @change="changeLimit"
  508. />
  509. <el-input
  510. class="min-data-input"
  511. size="mini"
  512. type="number"
  513. placeholder="下限"
  514. v-model="chartLimit.rightTwoMin"
  515. @change="changeLimit"
  516. />
  517. </div>
  518. </template>
  519. <!-- 后续新图专用上下限 和其他数据依赖不公用 柱形图 截面散点-->
  520. <template v-if="[7,10,11].includes(chartInfo.ChartType)">
  521. <div class="range-cont left">
  522. <el-input
  523. style="width: 60px; display: block"
  524. size="mini"
  525. type="number"
  526. placeholder="上限"
  527. v-model="chartLimit.max"
  528. @change="changeLimit"
  529. />
  530. <el-input
  531. class="min-data-input"
  532. size="mini"
  533. type="number"
  534. placeholder="下限"
  535. v-model="chartLimit.min"
  536. @change="changeLimit"
  537. />
  538. </div>
  539. <!-- x轴上下限 -->
  540. <div class="range-cont bottom" v-if="chartLimit.x_min||chartLimit.x_max">
  541. <el-input
  542. class="left"
  543. size="mini"
  544. type="number"
  545. placeholder="下限"
  546. v-model="chartLimit.x_min"
  547. @change="changeLimit"
  548. />
  549. <el-input
  550. class="left"
  551. size="mini"
  552. type="number"
  553. placeholder="上限"
  554. v-model="chartLimit.x_max"
  555. @change="changeLimit"
  556. />
  557. </div>
  558. </template>
  559. </div>
  560. <div class="chart-bottom-insruction-info">
  561. <div class="chart-source">
  562. <span
  563. v-if="chartInfo.SourcesFrom"
  564. :style="`
  565. color: ${JSON.parse(chartInfo.SourcesFrom).isShow ? JSON.parse(chartInfo.SourcesFrom).color : '#999'};
  566. fontSize: ${ JSON.parse(chartInfo.SourcesFrom).fontSize }px;
  567. `"
  568. ><!-- 来源 -->{{$t('Chart.Detail.source')}}:{{ JSON.parse(chartInfo.SourcesFrom).text}}
  569. </span>
  570. <el-switch
  571. v-if="chartInfo.SourcesFrom"
  572. v-model="chartInfo.SourcesFromVisable"
  573. :active-value="true"
  574. :inactive-value="false"
  575. style="margin:0 15px;"
  576. @change="changeSourceVisable"
  577. />
  578. <span class="editsty" @click="isShowSourceDialog=true"><!-- 编辑 -->{{$t('Chart.chart_edit_btn')}}</span>
  579. </div>
  580. <!-- 是否堆积 -->
  581. <div v-if="showIsHeap">
  582. <span>{{$t('EtaChartAddPage.bar_stacking')}}</span>
  583. <el-tooltip
  584. :content="$t('EtaChartAddPage.stack_tips')"
  585. placement="top"
  586. >
  587. <i class="el-icon-info"></i>
  588. </el-tooltip>
  589. <el-switch
  590. style="margin-left: 20px"
  591. v-model="IsHeap"
  592. @change="handleHeapChange"
  593. >
  594. </el-switch>
  595. </div>
  596. <!-- 公历农历切换 只用于季节性图 -->
  597. <el-radio-group
  598. v-model="calendar_type"
  599. class="calendar-cont"
  600. v-if="chartInfo.ChartType === 2"
  601. @change="getPreviewSplineInfo"
  602. >
  603. <el-radio-button label="公历">{{$t('Chart.calendar_gre')}}</el-radio-button>
  604. <el-radio-button label="农历">{{$t('Chart.calendar_lunar_text')}}</el-radio-button>
  605. </el-radio-group>
  606. <!-- 图表说明 -->
  607. <div
  608. class="chart-instruction"
  609. v-if="chartInfo.Instructions&&JSON.parse(chartInfo.Instructions).isShow"
  610. v-text="JSON.parse(chartInfo.Instructions).text"
  611. :style="`
  612. color: ${JSON.parse(chartInfo.Instructions).color};
  613. fontSize: ${ JSON.parse(chartInfo.Instructions).fontSize }px
  614. `"
  615. ></div>
  616. </div>
  617. <span class="chart-author"
  618. ><!-- 作者 -->{{$t('Chart.Detail.author')}}:{{ chartInfo.SysUserRealName || roleName }}</span
  619. >
  620. </div>
  621. <!-- 关联指标 -->
  622. <chartRelationEdbList
  623. :chartInfo="chartInfo"
  624. :tableData="tableData"
  625. :updateData="updateData"
  626. @changeTableData="changeTableData"
  627. @delTarget="delTarget"
  628. @copyCode="copyCode"
  629. @viewTarget="viewTarget"
  630. />
  631. </div>
  632. </div>
  633. <div class="nodata" v-else>
  634. <tableNoData :text="$t('Common.no_info_msg')"/>
  635. </div>
  636. </div>
  637. <!-- 日期端选择弹窗 -->
  638. <DateChooseDia
  639. :isDateDia="isDateDia"
  640. :dateForm="dateForm"
  641. :earliestDate="earliestDate"
  642. @cancel="isDateDia = false"
  643. @dateBack="dataChangeBack"
  644. />
  645. <!-- 季节性 图例设置 -->
  646. <LegendEditDia
  647. :isEditLegend="legendEditDiaShow"
  648. :legendList="SeasonExtraConfig.ChartLegend"
  649. @cancel="legendEditDiaShow = false"
  650. @saveLegend="saveLegend"
  651. />
  652. <!-- 数据来源编辑弹窗 -->
  653. <chartSourceEditDia
  654. :isShow.sync="isShowSourceDialog"
  655. :chartInfo="chartInfo"
  656. @update="value => {chartInfo.SourcesFrom=JSON.stringify({...value,isShow:chartInfo.SourcesFromVisable})}"
  657. />
  658. </div>
  659. </template>
  660. <script>
  661. import { dataBaseInterface } from '@/api/api.js';
  662. import { chartSetMixin } from './mixins/chartPublic';
  663. import {unitSelectList} from '@/utils/defaultOptions.js';
  664. import addOrEditMixn from './mixins/addOreditMixin';
  665. import Chart from './components/chart';
  666. import DateChooseDia from './components/DateChooseDia';
  667. import barOption from './components/barOptionSection.vue';
  668. import sectionalScatterOption from './components/sectionalScatterOption.vue';
  669. import LegendEditDia from './components/LegendEditDia.vue';
  670. import markersSection from './components/markersSection.vue';
  671. import chartSourceEditDia from './components/chartSourceEditDialog.vue';
  672. import chartRelationEdbList from './components/chartReleationEdbTable.vue';
  673. import sectionalCombinationOption from './components/sectionalCombination/sectionalCombinationOption.vue';
  674. export default {
  675. components: {
  676. Chart,
  677. DateChooseDia,
  678. barOption,
  679. sectionalScatterOption,
  680. LegendEditDia,
  681. markersSection,
  682. chartSourceEditDia,
  683. chartRelationEdbList,
  684. sectionalCombinationOption
  685. },
  686. directives: {
  687. drag(el, bindings) {
  688. el.onmousedown = function (e) {
  689. var init = e.clientX;
  690. // console.log(init);
  691. var box = $('#box')[0];
  692. // console.log(box.clientWidth)
  693. let total_wid = box.offsetWidth;
  694. var left = $('#left')[0];
  695. var right = $('#right')[0];
  696. var initWidth = left.offsetWidth;
  697. document.onmousemove = function (e) {
  698. var end = e.clientX;
  699. var newWidth = end - init + initWidth;
  700. left.style.width = newWidth + 'px';
  701. right.style.width = newWidth > 300 ? total_wid - newWidth + 'px' : total_wid - 320 + 'px';
  702. };
  703. document.onmouseup = function () {
  704. document.onmousemove = document.onmouseup = null;
  705. e.releaseCapture && e.releaseCapture();
  706. };
  707. e.setCapture && e.setCapture();
  708. return false;
  709. };
  710. },
  711. },
  712. watch: {
  713. tableData: {
  714. handler(newval, oldval) {
  715. if(newval.length) {
  716. if([7,10,11,14].includes(this.chartInfo.ChartType)) {
  717. // 奇怪柱形图
  718. this.chartInfo.ChartType === 7 && this.barDateList.length && this.$refs.BarOptRef.getBarData();
  719. //雷达图
  720. this.chartInfo.ChartType === 11 && this.$refs.BarOptRef.getBarData();
  721. }else {
  722. //拼接标题
  723. this.chartInfo.ChartName = this.sameOptionType.includes(this.chartInfo.ChartType)
  724. ? newval.map((item,index) => index === newval.length-1
  725. ? (this.currentLang==='en'?item.EdbNameEn:item.EdbName)
  726. : `${(this.currentLang==='en'?item.EdbNameEn:item.EdbName)}和`).join('')
  727. : `${this.currentLang==='en'?newval[0].EdbNameEn:newval[0].EdbName}季节性`;
  728. if(this.updateLimit){
  729. this.EdbAxisChange()
  730. }
  731. this.setAddChartDefault();
  732. this.setChartOptionHandle(newval);
  733. }
  734. // 设置起始日期和最新日期
  735. this.setExtremumDate()
  736. }else {
  737. this.chartInfo.ChartName = '';
  738. }
  739. },
  740. deep: true,
  741. }
  742. },
  743. computed: {
  744. roleName() {
  745. return localStorage.getItem('userName');
  746. },
  747. UnitOptions(){
  748. return unitSelectList()
  749. }
  750. },
  751. mixins: [chartSetMixin,addOrEditMixn],
  752. data() {
  753. return {
  754. isSlideLeft: false,
  755. search_txt: '',
  756. calendar_type: '公历',//默认公历
  757. season_year:'',//季节图时间段
  758. activeNames:'',
  759. needWatch: true,
  760. IsNameDefault:true,
  761. /* UnitOptions:unitArr, */
  762. useUnit:''
  763. };
  764. },
  765. methods: {
  766. /* 保存 */
  767. saveHandle() {
  768. if(!this.tableData.length)
  769. return this.$message.warning(/* '暂未选择指标' */this.$t('ToolBox.CommodityPriceChart.tips_msg05'));
  770. console.log(this.chartInfo)
  771. this.$refs.diaForm.validate((valid) => {
  772. if(valid) {
  773. // 季节图只允许添加一个指标
  774. if(this.chartInfo.ChartType === 2 && this.tableData.length > 1){}
  775. //return this.$message.warning(/* '您选择的图表样式为季节性图表,只支持单指标画图' */this.$t('Chart.OptMsg.season_one_msg'));
  776. else if([7,11].includes(this.chartInfo.ChartType) && !this.$refs.BarOptRef.dateList.length)
  777. return this.$message.warning(/*'请添加日期'*/this.$t('ToolBox.CommodityPriceChart.tips_msg06'));
  778. else if(this.chartInfo.ChartType === 10 && !this.$refs.SectionScatterOptRef.seriesArr[0].edbs)
  779. return this.$message.warning(/* '请添加系列指标' */this.$t('Chart.OptMsg.season_add_hint'));
  780. if(this.chartInfo.ChartType === 2){
  781. if(!(this.SeasonExtraConfig.XStartDate && this.SeasonExtraConfig.XEndDate)){
  782. return this.$message.warning(/* '横坐标显示范围不能为空' */this.$t('Chart.OptMsg.season_area_hint'));
  783. }
  784. }
  785. let db_arr = this.tableData.map((item,index) => ({
  786. ChartColor: item.ChartColor,
  787. PredictChartColor: item.PredictChartColor,
  788. ChartStyle: item.ChartStyle,
  789. ChartWidth: Number(item.ChartWidth),
  790. EdbInfoId: item.EdbInfoId,
  791. EdbAliasName: item.EdbAliasName,
  792. EdbInfoType: item.EdbInfoType,
  793. IsAxis: item.IsAxis,
  794. IsOrder: item.IsOrder,
  795. LeadUnit: item.EdbInfoType ? '' : item.LeadUnit,
  796. LeadValue: item.EdbInfoType ? 0 : Number(item.LeadValue),
  797. MaxData: Number(item.MaxData),
  798. MinData: Number(item.MinData)
  799. })
  800. )
  801. let hasLimitChange = false
  802. //需检测上下限是否修改
  803. if(![7,10,11].includes(this.chartInfo.ChartType)){
  804. const limitSame= this.getLimitInfo()
  805. hasLimitChange = !limitSame
  806. }
  807. if(![10,11,14].includes(this.chartInfo.ChartType)){
  808. //每个数据转换需要检测是否合法
  809. for(let i=0;i<db_arr.length;i++){
  810. const {IsConvert,ConvertType,ConvertValue} = this.updateData[i]
  811. //计算方式是否合法
  812. if(IsConvert&&!this.checkConver(ConvertType,ConvertValue)){
  813. //提示语:第${i+1}个指标数据转换不合法,请检查数值
  814. return this.$message.warning(this.$t('EtaChartAddPage.data_transformation_list_hint',{num:i+1}))
  815. }
  816. //如果类型为对数,检测数据是否包含负数
  817. if(IsConvert&&ConvertType===3){
  818. if(!this.checkEdbData(this.tableData[i].DataList)){
  819. //提示语:第${i+1}个指标数据含有负数或0,无法进行对数运算,请检查
  820. return this.$message.warning(this.$t('EtaChartAddPage.data_transformation_list_hint2',{num:i+1}))
  821. }
  822. }
  823. }
  824. db_arr = db_arr.map((item,index)=>{
  825. const {IsConvert,ConvertType,ConvertValue,ConvertUnit,ConvertEnUnit} = this.updateData[index]
  826. return {
  827. ...item,
  828. IsConvert:Number(IsConvert),
  829. ConvertType:IsConvert?ConvertType:1,
  830. ConvertValue:IsConvert?Number(ConvertValue):100,
  831. ConvertUnit:IsConvert?ConvertUnit:'',
  832. ConvertEnUnit:IsConvert?ConvertEnUnit:''
  833. }
  834. })
  835. }
  836. const { ChartType,ChartName,ChartThemeId,SourcesFrom,Instructions,MarkersLines,MarkersAreas,ChartThemeStyle } = this.chartInfo;
  837. let public_param = {
  838. ChartClassifyId: this.chartInfo.classify.length ? this.chartInfo.classify[this.chartInfo.classify.length - 1] : 0,
  839. ChartEdbInfoList: db_arr,
  840. ChartName,
  841. ChartType,
  842. ChartThemeId,
  843. SourcesFrom,
  844. Instructions,
  845. MarkersLines,
  846. MarkersAreas,
  847. ChartThemeStyle
  848. }
  849. //提交参数
  850. const typePrams = this.getSaveParamsByChartType(public_param);
  851. let params = this.sameOptionType.includes(this.chartInfo.ChartType)
  852. ? {
  853. ...public_param,
  854. DateType: this.year_select,
  855. StartYear: this.count_year || 0,
  856. StartDate:
  857. [5,6].includes(this.year_select)
  858. ? this.select_date[0]
  859. : '',
  860. EndDate: this.year_select === 5 ? this.select_date[1] : '',
  861. ExtraConfig:JSON.stringify({IsHeap:this.IsHeap?1:0})//时间序列组合图是否堆积控制
  862. }
  863. : typePrams
  864. if(![7,10,11].includes(this.chartInfo.ChartType)){
  865. const {
  866. min,max,rightMin,rightMax,rightTwoMin,rightTwoMax
  867. } = this.chartLimit
  868. params = {
  869. ...params,
  870. LeftMin:min+'',
  871. LeftMax:max+'',
  872. RightMin:rightMin+'',
  873. RightMax:rightMax+'',
  874. Right2Min:rightTwoMin+'',
  875. Right2Max:rightTwoMax+'',
  876. MinMaxSave:Number(hasLimitChange)
  877. }
  878. }
  879. //如果是季节性图,在这里加上同期/右轴的参数
  880. if(this.chartInfo.ChartType===2){
  881. //const {MaxMinLimits={},SamePeriodAverage={},SamePeriodStandardDeviation={}} = this.chartInfo.SeasonAverageConfig||{}
  882. const {SeasonRightConfig={}} = this.chartInfo
  883. const tempData = _.cloneDeep(this.chartInfo.SeasonAverageConfig||{})
  884. const {MaxMinLimits={},SamePeriodAverage={},SamePeriodStandardDeviation={}} = tempData||{}
  885. delete MaxMinLimits.List
  886. delete SamePeriodAverage.List
  887. delete SamePeriodStandardDeviation.List
  888. const tempConfig = _.cloneDeep(SeasonRightConfig)
  889. delete tempConfig.EdbInfoList
  890. params.SeasonExtraConfig = {
  891. ...this.SeasonExtraConfig,
  892. MaxMinLimits:MaxMinLimits.IsAdd?MaxMinLimits:{},
  893. SamePeriodAverage:SamePeriodAverage.IsAdd?SamePeriodAverage:{},
  894. SamePeriodStandardDeviation:SamePeriodStandardDeviation.IsAdd?SamePeriodStandardDeviation:{},
  895. RightAxis:SeasonRightConfig.IsAdd?tempConfig:{}//右轴的具体配置
  896. }
  897. }
  898. dataBaseInterface.chartAdd(params).then(res => {
  899. if(res.Ret !== 200) return;
  900. this.setChartImage(res.Data);
  901. })
  902. }
  903. })
  904. },
  905. /* 设置图表封面图片 */
  906. setChartImage(data) {
  907. let svg = this.$refs.chartRef.chart.getSVG({
  908. chart: {
  909. width: 340,
  910. height: 230,
  911. }
  912. });
  913. let form = new FormData();
  914. form.append('Img', svg);
  915. this.setImageHandle(form,data);
  916. },
  917. async setImageHandle(form,{ UniqueCode,ChartInfoId }) {
  918. // let { Data } = await dataBaseInterface.uploadImgSvg(form);
  919. // // let { Data } = await dataBaseInterface.uploadImg(form);
  920. // await dataBaseInterface.setChartImage({
  921. // ChartInfoId: ChartInfoId,
  922. // ImageUrl: Data.ResourceUrl,
  923. // });
  924. form.append('ChartInfoId',ChartInfoId)
  925. await dataBaseInterface.setChartThumbnail(form)
  926. // this.$message.success('添加成功');
  927. this.$message.success(this.$t('MsgPrompt.add_msg2'));
  928. this.$router.replace({
  929. path: '/chartsetting',
  930. query: {
  931. code: UniqueCode,
  932. id: ChartInfoId
  933. }
  934. })
  935. },
  936. },
  937. mounted() {
  938. this.getMenu();
  939. this.getChartBaseSetting()
  940. this.getThemeList('init');
  941. window.addEventListener('resize', this.reloadRightWid);
  942. },
  943. destroyed() {
  944. window.removeEventListener('resize', this.reloadRightWid);
  945. }
  946. };
  947. </script>
  948. <style lang="scss">
  949. .addchart-container {
  950. $font-small: 12px; $font-normal: 14px;
  951. display: flex;
  952. *{ box-sizing: border-box; }
  953. .el-form--label-top .el-form-item__label {
  954. padding: 0;
  955. }
  956. .el-form-item {
  957. margin-bottom: 8px;
  958. }
  959. .el-input-number .el-input__inner {
  960. padding: 0 34px 0 4px;
  961. }
  962. .target-other-name .el-input__inner {
  963. padding: 0 30px 0 5px !important;
  964. height: 40px !important;
  965. line-height: 40px !important;
  966. }
  967. .el-color-picker--mini .el-color-picker__trigger {
  968. width: 60px;
  969. height: 25px;
  970. padding: 0;
  971. }
  972. .el-color-picker--mini .el-color-picker__mask {
  973. width: 60px;
  974. height: 25px;
  975. }
  976. .slide-icon {
  977. padding: 20px 0;
  978. /* display: block; */
  979. box-shadow: 0px 3px 6px rgba(0, 0, 0, 0.3);
  980. border-radius: 5px;
  981. cursor: pointer;
  982. position: absolute;
  983. top: 50%;
  984. transform: translateY(-50%);
  985. z-index: 99;
  986. &:hover {
  987. background-color: rgba(0, 0, 0, 0.05);
  988. }
  989. &.slide-left {
  990. right: 0;
  991. }
  992. &.slide-right {
  993. left: 0;
  994. }
  995. }
  996. .left-cont {
  997. width: 400px;
  998. min-width: 300px;
  999. background: #fff;
  1000. margin-right: 20px;
  1001. border: 1px solid #ececec;
  1002. border-radius: 4px;
  1003. box-shadow: 0px 3px 6px rgba(0, 0, 0, 0.05);
  1004. height: calc(100vh - 113px);
  1005. overflow: hidden;
  1006. position: relative;
  1007. box-sizing: border-box;
  1008. .left-top {
  1009. padding: 15px 20px;
  1010. border: 1px solid #ececec;
  1011. box-shadow: 0px 3px 6px rgba(167, 167, 167, 0.09);
  1012. }
  1013. .left-min {
  1014. padding: 30px 20px;
  1015. max-height: calc(100vh - 194px);
  1016. overflow-y: auto;
  1017. .search-cont {
  1018. color: #606266;
  1019. }
  1020. .xaxis-range-cont{
  1021. color: #606266;
  1022. margin-top: 20px;
  1023. .xaxis-range-tip{
  1024. display: flex;
  1025. align-items: center;
  1026. justify-content: flex-start;
  1027. .hint-message{
  1028. font-size: 15px;
  1029. line-height: 22px;
  1030. }
  1031. }
  1032. .legend-set-text{
  1033. font-size: 15px;
  1034. color: #1B7BDE;
  1035. display: inline-flex;
  1036. align-items: center;
  1037. justify-content: flex-start;
  1038. margin-top: 20px;
  1039. cursor: pointer;
  1040. img{
  1041. height: 16px;
  1042. margin-left: 5px;
  1043. }
  1044. }
  1045. }
  1046. .targetset-cont {
  1047. padding: 30px 0 20px;
  1048. .el-input__inner {
  1049. height: 27px;
  1050. line-height: 27px;
  1051. padding: 0 4px;
  1052. }
  1053. .el-collapse-item.is-disabled .el-collapse-item__header {
  1054. color: #333;
  1055. }
  1056. .target-list {
  1057. border: 1px solid #DCDFE6;
  1058. .del-icon {
  1059. position: absolute;
  1060. right: 10px;
  1061. font-size: 16px;
  1062. color: #f00;
  1063. cursor: pointer;
  1064. }
  1065. .setting-cont {
  1066. padding: 20px 20px 0;
  1067. li {
  1068. padding-bottom: 20px;
  1069. margin-bottom: 20px;
  1070. border-bottom: 1px solid #DCDFE6;
  1071. &:last-child {
  1072. padding-bottom: 0;
  1073. margin-bottom: 0;
  1074. border-bottom: none;
  1075. }
  1076. }
  1077. }
  1078. }
  1079. .el-collapse-item__header {
  1080. background-color: #F0F2F5;
  1081. margin-bottom: 0;
  1082. border-bottom: 1px solid #DCDFE6;
  1083. padding: 0 30px;
  1084. .el-collapse-item__arrow {
  1085. position: absolute;
  1086. left: 8px;
  1087. }
  1088. }
  1089. .scatter-setting {
  1090. display: flex;
  1091. margin-bottom: 20px;
  1092. }
  1093. }
  1094. }
  1095. .move-btn {
  1096. height: 100%;
  1097. width: 4px;
  1098. position: absolute;
  1099. right: 0px;
  1100. top: 0;
  1101. &:hover {
  1102. cursor: col-resize;
  1103. }
  1104. }
  1105. }
  1106. .right-cont {
  1107. width: 80%;
  1108. .mx-datepicker {
  1109. width: 220px !important;
  1110. }
  1111. /* =================== */
  1112. .chart-min-cont {
  1113. background: #fff;
  1114. border: 1px solid #ececec;
  1115. height: calc(100vh - 118px);
  1116. overflow: auto;
  1117. /* overflow: hidden; */
  1118. border-radius: 4px;
  1119. box-shadow: 0px 3px 6px rgba(0, 0, 0, 0.05);
  1120. .cont-top {
  1121. padding: 12px 30px;
  1122. border-bottom: 1px solid #ececec;
  1123. display: flex;
  1124. justify-content: space-between;
  1125. align-items: center;
  1126. box-shadow: 0px 3px 6px rgba(167, 167, 167, 0.09);
  1127. .top-left {
  1128. .year-btn {
  1129. margin-right: 5px;
  1130. margin-bottom: 5px;
  1131. }
  1132. .btn-sty {
  1133. border: 1px solid #409eff;
  1134. }
  1135. .date-setting{
  1136. border: 1px solid #DCDFE6;
  1137. border-radius: 4px;
  1138. cursor: pointer;
  1139. color: #333333;
  1140. line-height: 16px;
  1141. }
  1142. }
  1143. .top-right {
  1144. font-size: 16px;
  1145. .join_txt {
  1146. color: #409eff;
  1147. cursor: pointer;
  1148. &:hover {
  1149. text-decoration: underline;
  1150. }
  1151. }
  1152. .collected {
  1153. color: #f00;
  1154. cursor: pointer;
  1155. &:hover {
  1156. text-decoration: underline;
  1157. }
  1158. }
  1159. .span-item {
  1160. color: #409eff;
  1161. cursor: pointer;
  1162. &:hover {
  1163. text-decoration: underline;
  1164. }
  1165. .el-icon-collection,
  1166. .el-icon-document-copy {
  1167. color: #409eff;
  1168. }
  1169. }
  1170. }
  1171. }
  1172. .cont-bottom {
  1173. padding: 20px 30px;
  1174. /* height: calc(100vh - 250px);
  1175. overflow: auto; */
  1176. .el-input__inner {
  1177. height: 27px;
  1178. line-height: 27px;
  1179. padding: 0 4px;
  1180. }
  1181. .el-input-number .el-input__inner {
  1182. padding: 0 34px 0 4px;
  1183. }
  1184. .highcharts-range-selector-group {
  1185. display: none;
  1186. .highcharts-input-group {
  1187. display: none;
  1188. }
  1189. }
  1190. .highcharts-axis-title {
  1191. display: block;
  1192. }
  1193. /* =================== */
  1194. .chart-show-cont {
  1195. min-height: 300px;
  1196. padding: 0 150px 60px 120px;
  1197. position: relative;
  1198. .chart-title {
  1199. font-size: 16px;
  1200. font-weight: normal;
  1201. text-align: center;
  1202. margin-bottom: 10px;
  1203. }
  1204. .chart-author {
  1205. font-size: 14px;
  1206. color: #333;
  1207. position: absolute;
  1208. bottom: 20px;
  1209. right: 50px;
  1210. }
  1211. .chartWrapper {
  1212. position: relative;
  1213. .range-cont {
  1214. position: absolute;
  1215. top: 15%;
  1216. .min-data-input {
  1217. width: 60px;
  1218. display: block;
  1219. }
  1220. &.left {
  1221. left: -80px;
  1222. }
  1223. &.right {
  1224. right: -65px;
  1225. }
  1226. &.rightTwo {
  1227. right: -130px;
  1228. }
  1229. &.bottom {
  1230. width: 100%;
  1231. display: flex;
  1232. justify-content: space-between;
  1233. top: auto;
  1234. right: 0;
  1235. bottom: -2%;
  1236. .left {
  1237. width: 60px;
  1238. display: block;
  1239. flex-shrink: 0;
  1240. }
  1241. }
  1242. }
  1243. }
  1244. }
  1245. .options-cont {
  1246. display: flex;
  1247. flex-wrap: wrap;
  1248. justify-content: space-between;
  1249. }
  1250. }
  1251. }
  1252. .nodata {
  1253. height: calc(100vh - 120px);
  1254. background-color: #fff;
  1255. text-align: center;
  1256. font-size: 16px;
  1257. color: #666;
  1258. padding: 100px 0;
  1259. }
  1260. @media screen and (min-width: 1711px){
  1261. .min-data-input {
  1262. margin-top: 310px;
  1263. }
  1264. .btn-sty {
  1265. padding: 10px;
  1266. }
  1267. .year-btn,.btn-sty {
  1268. font-size: $font-normal;
  1269. }
  1270. .date-setting{
  1271. width: 210px;
  1272. height: 40px;
  1273. padding: 12px;
  1274. font-size: $font-normal;
  1275. }
  1276. }
  1277. @media screen and (max-width: 1710px){
  1278. .min-data-input {
  1279. margin-top: 230px;
  1280. }
  1281. .year-btn {
  1282. font-size: $font-small;
  1283. margin-left: 5px;
  1284. margin-right: 5px;
  1285. margin-bottom: 5px;
  1286. padding: 6px 12px;
  1287. }
  1288. .btn-sty {
  1289. font-size: $font-small;
  1290. margin-left: 5px;
  1291. padding: 6px;
  1292. border: 1px solid #409eff;
  1293. }
  1294. .date-setting{
  1295. width: 180px;
  1296. height: 36px;
  1297. padding: 10px;
  1298. font-size: $font-small;
  1299. }
  1300. }
  1301. }
  1302. .expand-wrap{
  1303. display: flex;
  1304. justify-content: center;
  1305. align-items: center;
  1306. gap:30px;
  1307. .el-checkbox{
  1308. margin-right: 15px;
  1309. }
  1310. .el-input{
  1311. width:100px;
  1312. height:27px;
  1313. line-height: 27px;
  1314. .el-input__icon{
  1315. line-height: 27px;
  1316. }
  1317. }
  1318. }
  1319. }
  1320. </style>
  1321. <style lang="scss">
  1322. .edb-item-style .el-input__icon {
  1323. line-height: 27px;
  1324. }
  1325. /*他不要下拉选择框 QAQ */
  1326. .x-range-picker-date {
  1327. display: none;
  1328. }
  1329. </style>