Report1.vue 34 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153
  1. <template>
  2. <div class="out">
  3. <!---lxh-修改密码-->
  4. <div class="dig_update">
  5. <el-dialog
  6. :visible.sync="dialogVisible"
  7. :close-on-click-modal="false"
  8. width="80%"
  9. style="border-radius: 40px"
  10. >
  11. <div slot="title">
  12. <div label-width="150px" class="demo-ruleForm">
  13. <p v-if="isView" class="dig_title">
  14. {{ proDataLin.userName }}的{{ proDataLin.planName }}计划
  15. </p>
  16. <p v-if="!isView" class="dig_title">编辑计划</p>
  17. <div slot=""></div>
  18. <div slot="footer"></div>
  19. <div class="table-content">
  20. <el-table
  21. :data="tableData"
  22. :row-style="{ height: '0px' }"
  23. :cell-style="{ padding: '5px' }"
  24. :header-cell-style="{ background: '#F8F8F8', color: '#606266' }"
  25. >
  26. <el-table-column
  27. show-overflow-tooltip
  28. prop="planName"
  29. label="计划名称"
  30. align="center"
  31. width=""
  32. >
  33. </el-table-column>
  34. <el-table-column
  35. show-overflow-tooltip
  36. prop="planEndTime"
  37. label="计划结束时间"
  38. align="center"
  39. width=""
  40. >
  41. </el-table-column>
  42. <el-table-column label="操作" width="350px" align="center">
  43. <template slot-scope="scope">
  44. <div
  45. class="detail_button_out"
  46. v-if="scope.row.hasOwnProperty('contentEntities')"
  47. >
  48. <div v-for="item in scope.row.contentEntities" :key="item.id">
  49. <div
  50. v-if="item.isDisplayed == 1"
  51. style="
  52. color: #00bf78;
  53. display: flex;
  54. justify-content: flex-start;
  55. align-items: center;
  56. cursor: pointer;
  57. "
  58. @click="radioClick(item, scope.row)"
  59. >
  60. <img
  61. style="width: 15px; margin-left: 10px"
  62. src="../assets/img/table/search.png"
  63. />
  64. {{ item.name }}
  65. </div>
  66. </div>
  67. </div>
  68. </template>
  69. </el-table-column>
  70. </el-table>
  71. </div>
  72. <!-- <el-pagination
  73. class="pag_class"
  74. background
  75. @size-change="handleSizeChange"
  76. @current-change="handleCurrentChange"
  77. :current-page.sync="pageNum"
  78. layout="total, sizes, prev, pager, next"
  79. :page-size="pageSize"
  80. :page-sizes="[10, 20, 50, 100]"
  81. :total="total"
  82. >
  83. </el-pagination> -->
  84. <div class="dig_button"></div>
  85. </div>
  86. </div>
  87. </el-dialog>
  88. </div>
  89. <div>
  90. <el-dialog
  91. :visible.sync="topicVisible"
  92. :close-on-click-modal="false"
  93. width="40%"
  94. style="border-radius: 40px"
  95. >
  96. <div slot="title">
  97. <div label-width="150px" class="demo-ruleForm">
  98. <p v-if="isView" class="dig_title">选择题目</p>
  99. <div slot=""></div>
  100. <div slot="footer"></div>
  101. <div
  102. class="table-content"
  103. style="display: flex; justify-content: space-around"
  104. >
  105. <el-button
  106. type="success"
  107. style="border-radius: 20px"
  108. v-for="item in topPicList"
  109. :key="item.name"
  110. @click="radioClick(item)"
  111. >
  112. {{ item.name }}
  113. </el-button>
  114. </div>
  115. <div class="dig_button"></div>
  116. </div>
  117. </div>
  118. </el-dialog>
  119. </div>
  120. <div class="dig_update">
  121. <el-dialog
  122. :visible.sync="userVisible"
  123. append-to-body
  124. width="82%"
  125. style="border-radius: 40px"
  126. >
  127. <div slot="title" style="border-radius: 40px">
  128. <p style="text-align: center; font-weight: 700; font-size: 20px">
  129. {{ proDataLin.userName }}{{ planObj.planName }}的报告
  130. </p>
  131. <div class="kply">
  132. <div class="kply_inner">
  133. <div style="padding: 20px 40px">
  134. <div>
  135. <div class="report_info_out">
  136. <img v-show="gender=='1'" src="../assets/report/man1.png" />
  137. <img v-show="gender=='0'" src="../assets/report/woman1.png" />
  138. <div class="report_info_user">
  139. <span class="info">姓名:&nbsp;&nbsp;{{ proDataLin.userName }}</span>
  140. <span class="info" v-show="proDataLin.planType=='0'">学号:&nbsp;&nbsp;{{ proDataLin.userNo }}</span>
  141. <span class="info" v-show="proDataLin.planType=='1'">编号:&nbsp;&nbsp;{{ proDataLin.userNo }}</span>
  142. <span class="info">测试用时:&nbsp;&nbsp;{{ useTime }}</span>
  143. <span class="info"
  144. >所属组织结构:&nbsp;&nbsp;<span style="">{{
  145. orgName
  146. }}</span></span
  147. >
  148. </div>
  149. </div>
  150. <div class="report_totol_score">
  151. <div class="report_bei">
  152. <img height="200px !impotent" src="../assets/report/bei.png" />
  153. <div class="score" v-if="reportData.length > 0">
  154. {{ reportData[0].dimensionScore }}
  155. </div>
  156. </div>
  157. <div class="totol_result_des" v-if="reportData.length > 0">
  158. <div
  159. v-show="currentFlag == 'SHAPE_RANDOM'"
  160. class="progress_out"
  161. :style="{
  162. width: currentFlag != 'SHAPE_RANDOM' ? '100%' : '50%',
  163. }"
  164. style="display: flex; align-items: center"
  165. v-for="(item, index) in echarts_name_list"
  166. :key="index"
  167. >
  168. <span
  169. class="progress_out_name"
  170. style="width: 200px; font-size: 16px; font-weight: 700"
  171. >
  172. {{ item.name }}
  173. </span>
  174. <el-progress
  175. :percentage="echarts_data_list[index]"
  176. style="width: 100%"
  177. :stroke-width="18"
  178. :show-text="false"
  179. :color="colorPro"
  180. />
  181. <span class="progress_out_score">
  182. <span
  183. style="color: #ff1e00; font-size: 14px; font-weight: 700"
  184. >{{ echarts_data_list[index] }}</span
  185. ><span style="color: #000000; font-size: 12px; opacity: 0.4"
  186. >/100</span
  187. ></span
  188. >
  189. </div>
  190. 结论:{{ reportData[0].dimensionSymptom }},{{
  191. reportData[0].dimensionImprovement
  192. }}
  193. </div>
  194. </div>
  195. <div class="out_p" v-show="currentFlag != 'SHAPE_RANDOM'">
  196. <div
  197. v-show="currentFlag != 'SHAPE_RANDOM'"
  198. class="echrts_sty"
  199. ref="echarts_ld"
  200. ></div>
  201. <div class="report_echarts_out">
  202. <div
  203. style="
  204. display: flex;
  205. flex-direction: row;
  206. width: 100%;
  207. flex-wrap: wrap;
  208. padding-top: 40px;
  209. padding-bottom: 40px;
  210. "
  211. >
  212. <div
  213. class="progress_out"
  214. :style="{
  215. width: currentFlag != 'SHAPE_RANDOM' ? '100%' : '50%',
  216. }"
  217. v-for="(item, index) in echarts_name_list"
  218. :key="index"
  219. >
  220. <span class="progress_out_name" style="width: 150px">
  221. {{ item.name }}
  222. </span>
  223. <el-progress
  224. :percentage="echarts_data_list[index]"
  225. style="width: 100%"
  226. :stroke-width="18"
  227. :show-text="false"
  228. :color="colorPro"
  229. />
  230. <span class="progress_out_score"
  231. >{{ echarts_data_list[index]
  232. }}<span style="color: #000000; font-size: 12px; opacity: 0.4"
  233. >/100</span
  234. ></span
  235. >
  236. </div>
  237. </div>
  238. </div>
  239. </div>
  240. <!-- **********************************开始1 -->
  241. <div
  242. v-show="currentFlag != 'SHAPE_RANDOM'"
  243. v-for="(item, index) in reportDataAll"
  244. :key="index"
  245. style="padding-top: 20px"
  246. >
  247. <div class="des_zhishu">
  248. {{ item.dimensionName }}
  249. </div>
  250. <div class="report_des_out">
  251. <div class="score">
  252. <div class="score_lin">
  253. <img
  254. src="../assets/img/report/score.png"
  255. style="width: 20px; height: 20px"
  256. alt=""
  257. />
  258. <span class="score_tt">分数:</span>
  259. </div>
  260. <span
  261. v-if="
  262. item.dimensionSymptom == '重度' ||
  263. item.dimensionSymptom == '高风险'
  264. "
  265. style="color: red"
  266. >
  267. {{ item.dimensionScore }}</span
  268. >
  269. <span
  270. v-if="
  271. item.dimensionSymptom == '无症状或轻度' ||
  272. item.dimensionSymptom == '无或轻风险'
  273. "
  274. style="color: #00bf78"
  275. >
  276. {{ item.dimensionScore }}</span
  277. >
  278. <span
  279. v-if="
  280. item.dimensionSymptom == '中度' ||
  281. item.dimensionSymptom == '中风险'
  282. "
  283. style="color: #f0a900"
  284. >
  285. {{ item.dimensionScore }}</span
  286. >
  287. <span
  288. style="
  289. font-size: 16px;
  290. color: rgb(153, 153, 153);
  291. letter-spacing: 0px;
  292. "
  293. >&nbsp;&nbsp;(满分100)</span
  294. >
  295. </div>
  296. <div class="score">
  297. <span class="score_tt">
  298. <div class="score_lin">
  299. <img
  300. src="../assets/img/report/result.png"
  301. style="width: 20px; height: 20px"
  302. alt=""
  303. />
  304. <span class="score_tt">结论:</span>
  305. </div>
  306. </span>
  307. <span
  308. v-if="
  309. item.dimensionSymptom == '重度' ||
  310. item.dimensionSymptom == '高风险'
  311. "
  312. style="color: red"
  313. >
  314. {{ item.dimensionSymptom }}</span
  315. >
  316. <span
  317. v-if="
  318. item.dimensionSymptom == '无症状或轻度' ||
  319. item.dimensionSymptom == '无或轻风险'
  320. "
  321. style="color: #00bf78"
  322. >
  323. {{ item.dimensionSymptom }}</span
  324. >
  325. <span
  326. v-if="
  327. item.dimensionSymptom == '中度' ||
  328. item.dimensionSymptom == '中风险'
  329. "
  330. style="color: #f0a900"
  331. >
  332. {{ item.dimensionSymptom }}</span
  333. >
  334. </div>
  335. <div class="scoreAsy">
  336. <span class="scoreAsyTitle">
  337. <div class="score_lin">
  338. <img
  339. src="../assets/img/report/asy.png"
  340. style="width: 20px; height: 20px"
  341. alt=""
  342. />
  343. <span class="score_tt">分析:</span>
  344. </div> </span
  345. ><span class="scoreAsyDes">{{ item.dimensionImprovement }}</span>
  346. </div>
  347. <!-- <div class="des">{{ item.dimensionImprovement }}</div> -->
  348. <div class="scoreAsy">
  349. <span class="scoreAsyTitle">
  350. <div class="score_lin">
  351. <img
  352. src="../assets/img/report/sm.png"
  353. style="width: 20px; height: 20px"
  354. alt=""
  355. />
  356. <span class="score_tt">说明:</span>
  357. </div> </span
  358. ><span class="scoreAsyDes">{{ item.dimensionDesc }}</span>
  359. </div>
  360. <div class="scoreAsy">
  361. <span class="scoreAsyTitle">
  362. <div class="score_lin">
  363. <img
  364. src="../assets/img/report/sug.png"
  365. style="width: 20px; height: 20px"
  366. alt=""
  367. />
  368. <span class="score_tt">建议:</span>
  369. </div> </span
  370. ><span class="scoreAsyDes">{{ item.dimensionSuggestion }}</span>
  371. </div>
  372. </div>
  373. </div>
  374. </div>
  375. </div>
  376. </div>
  377. </div>
  378. </div>
  379. </el-dialog>
  380. </div>
  381. </div>
  382. </template>
  383. <script>
  384. // import { oSessionStorage } from "../../utils/utils";
  385. import { oSessionStorage } from "../utils/utils";
  386. import * as echarts from "echarts";
  387. import md5 from "md5";
  388. export default {
  389. data() {
  390. return {
  391. topicVisible: false,
  392. //接收所属组织结构的词语
  393. orgName: "",
  394. userVisible: false,
  395. //编辑返回的值
  396. userDetailData: {},
  397. //组织架构名字
  398. groupName: "",
  399. disableFlag: false,
  400. phoneFlag: false,
  401. flag: 3,
  402. dialogVisible: false,
  403. //渠道列表
  404. isView: true,
  405. //当前计划ID
  406. planId: "",
  407. userInfo: {},
  408. proDataLin: [],
  409. total: 0,
  410. pageSize: 10,
  411. pageNum: 1,
  412. tableData: [],
  413. userTotal: 0,
  414. userpageSize: 10,
  415. userPageNum: 1,
  416. userTableData: [],
  417. multipleSelection: [],
  418. //获取报告总数据
  419. reportData: [],
  420. //获取不过滤的数据
  421. reportDataAll: [],
  422. echarts_des_list: ["", "", "", "", "", ""],
  423. echarts_data_list: [10, 20, 30, 40, 0, 0],
  424. echarts_name_list: [
  425. { name: "阳光指数", max: 100 },
  426. { name: "情绪稳定指数", max: 100 },
  427. { name: "社交能力", max: 100 },
  428. { name: "自律能力", max: 100 },
  429. { name: "爱情观", max: 100 },
  430. { name: "人生观", max: 100 },
  431. ],
  432. option: {},
  433. echarts_ld: "",
  434. colorPro: "linear-gradient(to right,#FF4E00 ,#ffffff)",
  435. //该用户的需要做的题目的列表
  436. topPicList: [],
  437. radio1: "",
  438. currentFlag: "",
  439. useTime: "",
  440. //当前用户选择的测试
  441. planObj: "",
  442. gender:'1'
  443. };
  444. },
  445. mounted() {
  446. this.echarts_ld = this.$refs.echarts_ld;
  447. this.userInfo = JSON.parse(oSessionStorage.getItem("userInfo"));
  448. },
  449. methods: {
  450. isRadioFun(val) {},
  451. forMatCom(val) {
  452. if (val.isComplete == "0") {
  453. return "未完成";
  454. } else {
  455. return "已完成";
  456. }
  457. },
  458. //查询报告 //根据planId 和用户编号
  459. queryRport(val) {
  460. //打印计划信息
  461. //调用接口--根据计划ID查询计划中题目需要显示的个数及名称
  462. let url = `/planContent/findAllByPlanId?planId=${val.id}&userNo=${val.userNo}`;
  463. this.$http.get(url, {}, (res) => {
  464. //查询题目列表
  465. let list = [];
  466. list = res.data;
  467. //过滤一下list
  468. this.topPicList = list.filter((item) => {
  469. return item.isDisplayed == "1";
  470. });
  471. });
  472. //出现选择了几个题目//需要显示--需要出现个弹出框进行选择
  473. this.topicVisible = true;
  474. },
  475. radioClick(val, planObj) {
  476. this.planObj = planObj;
  477. if (this.userInfo.roleType != "5") {
  478. if (planObj.enable == "0") {
  479. this.$message({
  480. type: "error",
  481. message: "暂未授权",
  482. });
  483. return;
  484. }
  485. }
  486. //在数组中招待
  487. let params = {
  488. planId: val.planId,
  489. userNo: this.proDataLin.userNo,
  490. flag: val.flag,
  491. };
  492. this.currentFlag = val.flag;
  493. this.userVisible = true;
  494. this.reportDetail(params);
  495. },
  496. reportDetail(params) {
  497. let url = `/userRecordScore/findByFlagAndUserNo?planId=${params.planId}&userNo=${params.userNo}&flag=${params.flag}`;
  498. this.$http.get(url, {}, (res) => {
  499. if (res.code == 200) {
  500. // this.reportData = res.data;
  501. this.gender=res.data.gender
  502. let listTmp1 = [];
  503. listTmp1 = res.data.dimensionScore.filter((item) => {
  504. return item.dimensionName != "总分";
  505. });
  506. let listTmp2 = [];
  507. listTmp2 = listTmp1.filter((item) => {
  508. return (
  509. item.dimensionName == "躯体化" ||
  510. item.dimensionName == "焦虑" ||
  511. item.dimensionName == "抑郁"
  512. );
  513. });
  514. let listTmp3 = [];
  515. listTmp3 = listTmp1.filter((item) => {
  516. return !(
  517. item.dimensionName == "躯体化" ||
  518. item.dimensionName == "焦虑" ||
  519. item.dimensionName == "抑郁"
  520. );
  521. });
  522. this.reportDataAll = listTmp2.concat(listTmp3);
  523. //将数组中的躯体化---抑郁---焦虑 取出来
  524. //然后将数组中的不是焦虑--抑郁 --躯体化的 取出来 --进行排序
  525. // this.reportDataAll = res.data.dimensionScore.filter((item) => {
  526. // return item.dimensionName != "总分";
  527. // });
  528. //将三个维度提前
  529. this.useTime = res.data.usedTime;
  530. this.orgName = res.data.dimensionScore[0].orgName;
  531. this.reportData = res.data.dimensionScore;
  532. // let a =[res.data[0].]
  533. //修改文本
  534. let scoreList = [];
  535. let scoreDes = [];
  536. let nameList = [];
  537. for (let i = 0; i < this.reportData.length; i++) {
  538. //
  539. if (this.reportData[i].dimensionName != "总分") {
  540. scoreList.push(parseInt(this.reportData[i].dimensionScore));
  541. scoreDes.push(this.reportData[i].dimensionImprovement);
  542. let ob = { name: this.reportData[i].dimensionName, max: 100 };
  543. nameList.push(ob);
  544. }
  545. }
  546. this.echarts_des_list = scoreDes;
  547. this.echarts_data_list = scoreList;
  548. this.echarts_name_list = nameList;
  549. // currentFlag != 'SHAPE_RANDOM'
  550. if (this.currentFlag != "SHAPE_RANDOM") {
  551. const myChart = echarts.init(this.echarts_ld);
  552. // this.option.series[0].data[0] = a;
  553. this.option.series[0].data[0].value = this.echarts_data_list;
  554. this.option.radar.indicator = this.echarts_name_list; //name
  555. //当是认知任务时---不执行
  556. myChart.setOption(this.option);
  557. }
  558. } else {
  559. ElMessage({
  560. message: res.msg,
  561. type: "error",
  562. });
  563. }
  564. });
  565. },
  566. deleteUser(val) {
  567. let data = [val.id];
  568. //调用接口开始添加
  569. let url = `/planUser/deletePlanUsers`;
  570. this.$http.post(url, data, (res) => {
  571. if (res && res.code == 200) {
  572. this.searchTarget();
  573. this.tableData = res.data.content;
  574. this.total = res.data.totalElements;
  575. } else {
  576. // this.$toast.fail(res.msg);
  577. this.$message.error(res.msg);
  578. }
  579. });
  580. },
  581. addUser() {
  582. this.userVisible = true;
  583. //调用待添加的用户
  584. this.userSearchTarget();
  585. },
  586. isComUser(val, row) {
  587. //添加已选用户
  588. let data = [];
  589. if (val == 1) {
  590. for (let i = 0; i < this.multipleSelection.length; i++) {
  591. //
  592. let obj = {
  593. orgName: this.multipleSelection[i].orgName,
  594. orgNo: this.multipleSelection[i].orgNo,
  595. planId: this.proDataLin.id,
  596. userName: this.multipleSelection[i].userName,
  597. userNo: this.multipleSelection[i].userNo,
  598. };
  599. data.push(obj);
  600. }
  601. } else {
  602. let obj = {
  603. orgName: row.orgName,
  604. orgNo: row.orgNo,
  605. planId: this.proDataLin.id,
  606. userName: row.userName,
  607. userNo: row.userNo,
  608. };
  609. data.push(obj);
  610. }
  611. //调用接口开始添加
  612. let url = `/planUser/savePlanUsers`;
  613. this.$http.post(url, data, (res) => {
  614. if (res && res.code == 200) {
  615. this.searchTarget();
  616. this.userSearchTarget();
  617. this.tableData = res.data.content;
  618. this.total = res.data.totalElements;
  619. } else {
  620. // this.$toast.fail(res.msg);
  621. this.$message.error(res.msg);
  622. }
  623. });
  624. },
  625. searchTarget() {
  626. this.pageNum = 1;
  627. this.searchList();
  628. },
  629. userSearchTarget() {
  630. this.userPageNum = 1;
  631. this.userSearchList();
  632. },
  633. //进来调用已选列表接口
  634. searchList() {
  635. let url = `/plan/findPlanById?id=${this.proDataLin.planId}`;
  636. this.$http.get(url, {}, (res) => {
  637. if (res && res.code == 200) {
  638. this.tableData = [];
  639. this.tableData.push(res.data);
  640. // this.total = res.data.totalElements;
  641. } else {
  642. // this.$toast.fail(res.msg);
  643. this.$message.error(res.msg);
  644. }
  645. });
  646. },
  647. userSearchList() {
  648. let url = `/plan/planAddUser?pageSize=${this.userpageSize}&pageNum=${this.userPageNum}&planId=${this.proDataLin.id}&orgNo=${this.proDataLin.planOrgNo}`;
  649. this.$http.get(url, {}, (res) => {
  650. if (res && res.code == 200) {
  651. this.userTableData = res.data.content;
  652. this.userTotalotal = res.data.totalElements;
  653. } else {
  654. // this.$toast.fail(res.msg);
  655. this.$message.error(res.msg);
  656. }
  657. });
  658. },
  659. //每页多少条
  660. handleSizeChange(val) {
  661. //将首页重置为1时---且总条数变化
  662. //设置为当前总条数
  663. },
  664. handleCurrentChange(val) {
  665. this.pageNum = val;
  666. this.searchList();
  667. },
  668. //已选选项
  669. handleSelectionChange(val) {
  670. this.multipleSelection = val;
  671. },
  672. resetForm(val) {
  673. this.cancle();
  674. },
  675. formatterTime(val) {
  676. let date = new Date(val);
  677. let year = date.getFullYear();
  678. let month = date.getMonth() + 1;
  679. month = this.formatterMon(month);
  680. let day = date.getDate();
  681. day = this.formatterMon(day);
  682. return year + "-" + month + "-" + day;
  683. },
  684. formatterMon(val) {
  685. if (val < 10) {
  686. return "0" + val;
  687. } else {
  688. return val;
  689. }
  690. },
  691. open(val) {
  692. // debugger;
  693. this.proDataLin = val;
  694. this.dialogVisible = true;
  695. //查询用户下边的计划
  696. //获取渠道信息
  697. // this.option.radar.indicator=[] //name
  698. this.option = {
  699. title: {
  700. // text: 'Basic Radar Chart'
  701. },
  702. legend: {
  703. // data: ['Allocated Budget', 'Actual Spending']
  704. },
  705. radar: {
  706. shape: "square", //设置雷达图形状,值有circle、square,默认为方形
  707. splitNumber: 3, // 雷达图圈数设置
  708. // shape: 'circle',
  709. indicator: this.echarts_name_list,
  710. name: {
  711. //修改indicator文字的颜色
  712. textStyle: {
  713. // color: "#999999",
  714. },
  715. },
  716. },
  717. series: [
  718. {
  719. type: "radar",
  720. symbolSize: 6,
  721. data: [
  722. {
  723. value: this.echarts_data_list,
  724. lineStyle: {
  725. normal: {
  726. color: "#FF1E00",
  727. },
  728. },
  729. //折线拐点颜色
  730. itemStyle: {
  731. normal: {
  732. color: "#FF1E00",
  733. borderWidth: 3, //拐点边框大小
  734. },
  735. // emphasis: {
  736. // color: '#000000'//hover拐点颜色定义
  737. // }
  738. },
  739. // name: 'Actual Spending'
  740. areaStyle: {
  741. //阴影区域背景
  742. // color: 'rgba(255, 228, 52, 0.6)'
  743. color: "#F8B4AB",
  744. },
  745. },
  746. ],
  747. },
  748. ],
  749. };
  750. this.searchTarget();
  751. },
  752. edit(val) {
  753. this.dialogVisible = true;
  754. this.isView = false;
  755. this.userDetailData = val;
  756. //调用查询详情的接口
  757. },
  758. //调用查询详情的接口
  759. disableFlagStatus() {
  760. setTimeout(() => {
  761. this.disableFlag = false;
  762. }, 1500);
  763. },
  764. register() {
  765. let that = this;
  766. this.$http.post(`/plan/addOrUpdate`, {}, (res) => {
  767. this.disableFlagStatus();
  768. // this.disableFlag = false;
  769. if (res && res.code == 200) {
  770. this.dialogVisible = false;
  771. // this.$toast.success({ message: "成功" });
  772. //调用父组件的查询方法
  773. that.$emit("search");
  774. } else {
  775. // this.$toast.fail({ message: res.msg });
  776. this.$message.error(res.msg);
  777. }
  778. //清空缓存
  779. this.cancle();
  780. });
  781. },
  782. },
  783. };
  784. </script>
  785. <style scoped>
  786. .progress_cla >>> .el-progress-bar__inner {
  787. background-color: #00bf78;
  788. }
  789. </style>
  790. <style>
  791. input[aria-hidden="true"] {
  792. display: none !important;
  793. }
  794. .el-radio:focus:not(.is-focus):not(:active):not(.is-disabled) .el-radio__inner {
  795. box-shadow: none;
  796. }
  797. .el-dialog {
  798. border-radius: 20px !important;
  799. /* background-color: #f7f7f7 !important; */
  800. }
  801. </style>
  802. <style lang="less" scoped>
  803. // .out /deep/.el-dialog {
  804. // border-radius: 20px !important;
  805. // // background-color: #f7f7f7 !important;
  806. // }
  807. // .out/deep/ .el-dialog__header {
  808. // padding: 0px 0px 0px !important;
  809. // }
  810. .progress_out/deep/ .el-progress-bar__inner {
  811. background-image: linear-gradient(to right, #ff4e00, #ffffff);
  812. }
  813. .dig_update /deep/.el-cascader {
  814. position: relative;
  815. font-size: 14px;
  816. line-height: 40px;
  817. width: 100%;
  818. }
  819. // .dig_update /deep/.el-dialog {
  820. // border-radius: 20px !important;
  821. // box-shadow: none !important;
  822. // background: transparent !important;
  823. // }
  824. .demo-ruleForm /deep/ .el-form-item {
  825. // margin-right: 10px;
  826. vertical-align: top;
  827. display: flex !important;
  828. flex-direction: column;
  829. }
  830. .demo-ruleForm /deep/.el-form-item__label {
  831. text-align: left;
  832. vertical-align: middle;
  833. float: left;
  834. font-size: 14px;
  835. color: #606266;
  836. line-height: 40px;
  837. padding: 0 12px 0 0;
  838. -webkit-box-sizing: border-box;
  839. box-sizing: border-box;
  840. }
  841. .demo-ruleForm /deep/.el-input {
  842. width: 100% !important;
  843. }
  844. .demo-ruleForm /deep/.el-input__inner {
  845. width: 100% !important;
  846. background-color: #f7f7f7;
  847. border: 0px;
  848. }
  849. .dig_button {
  850. display: flex;
  851. width: 100%;
  852. justify-content: space-around;
  853. }
  854. .demo-ruleForm {
  855. background-color: #ffffff;
  856. // border-radius: 20px;
  857. // margin-right: -10px;
  858. margin-top: -10px;
  859. padding-right: 100px;
  860. padding-left: 100px;
  861. border-radius: 20px;
  862. padding-top: 20px;
  863. padding-bottom: 40px;
  864. .dig_title {
  865. font-size: 20px;
  866. margin-bottom: 30px;
  867. text-align: center;
  868. font-weight: 700;
  869. }
  870. }
  871. .kply {
  872. width: 100%;
  873. margin-top: 20px;
  874. // background-color: #FAFAFA;
  875. .kply_inner {
  876. // padding: 20px 20px;
  877. left: 0;
  878. right: 0;
  879. margin: auto;
  880. width: 1200px;
  881. min-height: 500px;
  882. background-color: #ffffff;
  883. border-radius: 40px;
  884. .report_totol_score {
  885. margin-top: 20px;
  886. display: flex;
  887. flex-direction: row;
  888. // justify-content: space-between;
  889. align-items: center;
  890. .report_bei {
  891. position: relative;
  892. img {
  893. height: 150px !important;
  894. width: 210px !important;
  895. }
  896. // background-color: #111111;
  897. .score {
  898. width: 100%;
  899. height: 40px;
  900. text-align: center;
  901. position: absolute;
  902. left: 0;
  903. right: 0;
  904. top: -20px;
  905. bottom: 0;
  906. margin: auto;
  907. color: #ffffff;
  908. font-size: 30px;
  909. }
  910. }
  911. .totol_result_des {
  912. font-size: 18px;
  913. margin-left: 30px;
  914. letter-spacing: 3px;
  915. line-height: 30px;
  916. }
  917. }
  918. .des_zhishu {
  919. color: #222222;
  920. font-size: 20px;
  921. background-color: #00bf78;
  922. letter-spacing: 3px;
  923. color: #ffffff;
  924. display: inline-flex;
  925. border-radius: 26px;
  926. padding: 5px 20px;
  927. }
  928. .report_des_out {
  929. margin-top: 10px;
  930. // background-color: #f7f7f7;
  931. border: 4px solid #f2f2f2;
  932. padding: 20px 40px;
  933. border-radius: 40px;
  934. .score {
  935. // color: #48d68e;
  936. font-size: 16px;
  937. line-height: 30px;
  938. letter-spacing: 2px;
  939. margin-bottom: 20px;
  940. display: flex;
  941. .score_lin {
  942. display: flex;
  943. align-items: center;
  944. .score_tt {
  945. font-weight: 700;
  946. margin-left: 5px;
  947. }
  948. }
  949. }
  950. .des {
  951. color: #000000;
  952. font-size: 18px;
  953. line-height: 28px;
  954. letter-spacing: 3px;
  955. }
  956. .scoreAsy {
  957. display: flex;
  958. flex-direction: row;
  959. margin-bottom: 20px;
  960. .scoreAsyTitle {
  961. // color: #48d68e;
  962. font-size: 16px;
  963. line-height: 30px;
  964. letter-spacing: 2px;
  965. .score_lin {
  966. display: flex;
  967. align-items: center;
  968. .score_tt {
  969. font-weight: 700;
  970. margin-left: 5px;
  971. }
  972. }
  973. }
  974. .scoreAsyDes {
  975. flex: 1;
  976. font-size: 16px;
  977. line-height: 30px;
  978. letter-spacing: 2px;
  979. color: #555555;
  980. }
  981. }
  982. }
  983. .start_button_out {
  984. margin-top: 100px;
  985. margin-bottom: 40px;
  986. display: flex;
  987. flex-direction: row;
  988. justify-content: center;
  989. .start_button_self {
  990. cursor: pointer;
  991. // width: 100px;
  992. border-radius: 12px;
  993. border: 3px solid #48d68e;
  994. color: #ffffff;
  995. background-color: #000000;
  996. margin-right: 20px;
  997. padding: 8px 60px;
  998. cursor: pointer;
  999. display: flex;
  1000. align-items: center;
  1001. }
  1002. }
  1003. }
  1004. }
  1005. .report_info_out {
  1006. background-color: #f8f8f8;
  1007. border-radius: 40px;
  1008. padding-top: 40px;
  1009. padding-left: 40px;
  1010. padding-bottom: 40px;
  1011. display: flex;
  1012. align-items: center;
  1013. img {
  1014. width: 100px !important;
  1015. height: 100px !important;
  1016. }
  1017. .report_info_user {
  1018. display: flex;
  1019. flex-direction: column;
  1020. margin-left: 20px;
  1021. justify-content: space-around;
  1022. color: #000000;
  1023. font-size: 20px;
  1024. .info {
  1025. margin-bottom: 10px;
  1026. font-size: 18px;
  1027. color: #333333;
  1028. }
  1029. // font-weight: 700;
  1030. }
  1031. }
  1032. .detail_button_out {
  1033. flex: 1;
  1034. display: flex;
  1035. justify-content: space-around;
  1036. .detail_button {
  1037. display: flex;
  1038. align-items: center;
  1039. cursor: pointer;
  1040. letter-spacing: 2px;
  1041. img {
  1042. width: 15px;
  1043. margin-right: 5px;
  1044. }
  1045. span {
  1046. color: #00bf78;
  1047. // font-weight: 600;
  1048. }
  1049. }
  1050. }
  1051. .out_p {
  1052. display: flex;
  1053. flex: 1;
  1054. width: 100%;
  1055. align-items: center;
  1056. .echrts_sty {
  1057. flex: 6;
  1058. height: 400px;
  1059. }
  1060. .report_echarts_out {
  1061. flex: 4;
  1062. // margin-top: 100px;
  1063. // background-color: #f7f7f7;
  1064. border-radius: 40px;
  1065. display: flex;
  1066. flex-direction: row;
  1067. // justify-content: space-between;
  1068. // height: 200px;
  1069. .progress_out {
  1070. margin-bottom: 40px;
  1071. width: 100%;
  1072. display: flex;
  1073. justify-content: start;
  1074. flex-direction: row;
  1075. // align-items: center;
  1076. // padding-right: 40px;
  1077. .progress_out_name {
  1078. color: #000000;
  1079. font-weight: 600;
  1080. padding-left: 20px;
  1081. }
  1082. .progress_out_score {
  1083. color: #ff1e00;
  1084. font-weight: 600;
  1085. margin-right: 5px;
  1086. margin-left: 15px;
  1087. }
  1088. }
  1089. }
  1090. }
  1091. </style>