Parcourir la source

修改title图标

zhangxc il y a 4 ans
Parent
commit
401a541da0

+ 1 - 0
package.json

@@ -16,6 +16,7 @@
     "babel-loader": "^8.0.5",
     "babel-polyfill": "^6.26.0",
     "clean-webpack-plugin": "^2.0.1",
+    "copy-webpack-plugin": "^5.1.1",
     "css-loader": "^2.1.1",
     "echarts": "^4.6.0",
     "express": "^4.16.4",

+ 1 - 0
src/html/knowledgeGraph.html

@@ -6,6 +6,7 @@
 	<meta name="viewport" content="width=device-width, initial-scale=1.0">
 	<meta http-equiv="X-UA-Compatible" content="ie=edge">
 	<title><%= htmlWebpackPlugin.options.title %></title>
+	<link href="../resources/favicon.ico" rel="shortcut icon">
 	<!-- <link rel="stylesheet" href="./../resources/zTree/css/zTreeStyle/zTreeStyle.css" type="text/css"> -->
 	<!-- <script type="text/javascript" src="./../resources/zTree/js/jquery.ztree.core.min.js"></script> -->
 </head>

+ 1 - 0
src/html/knowledgeTree.html

@@ -6,6 +6,7 @@
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   <meta http-equiv="X-UA-Compatible" content="ie=edge">
   <title><%= htmlWebpackPlugin.options.title %></title>
+	<link href="../resources/favicon.ico" rel="shortcut icon">
   <!-- <link rel="stylesheet" href="./../resources/zTree/css/zTreeStyle/zTreeStyle.css" type="text/css"> -->
 	<!-- <script type="text/javascript" src="./../resources/zTree/js/jquery.ztree.core.min.js"></script> -->
 </head>

+ 1 - 0
src/html/medicalTermMap.html

@@ -6,6 +6,7 @@
 	<meta name="viewport" content="width=device-width, initial-scale=1.0">
 	<meta http-equiv="X-UA-Compatible" content="ie=edge">
 	<title><%= htmlWebpackPlugin.options.title %></title>
+	<link href="../resources/favicon.ico" rel="shortcut icon">
 	<!-- <link rel="stylesheet" href="./../resources/zTree/css/zTreeStyle/zTreeStyle.css" type="text/css"> -->
 	<!-- <script type="text/javascript" src="./../resources/zTree/js/jquery.ztree.core.min.js"></script> -->
 </head>

+ 1 - 0
src/html/participle.html

@@ -6,6 +6,7 @@
 	<meta name="viewport" content="width=device-width, initial-scale=1.0">
 	<meta http-equiv="X-UA-Compatible" content="ie=edge">
 	<title><%= htmlWebpackPlugin.options.title %></title>
+	<link href="../resources/favicon.ico" rel="shortcut icon">
 </head>
 
 <body>

+ 1 - 0
src/html/qaPage.html

@@ -6,6 +6,7 @@
     <meta name="viewport" content="width=device-width, initial-scale=1.0">
     <meta http-equiv="X-UA-Compatible" content="ie=edge">
     <title><%= htmlWebpackPlugin.options.title %></title>
+    <link href="../resources/favicon.ico" rel="shortcut icon">
 </head>
 
 <body>

+ 0 - 2
src/js/graphMap.js

@@ -47,7 +47,6 @@ function drawGraph(data,resultShowId) {
     for(let i = 0; i < legends.length; i++){
 
         sum += 2+legends[i].name.length+1
-        console.log(sum)
         if(sum <= 60){
             showLegendNum ++
         }
@@ -460,7 +459,6 @@ function getKeyEvent(evt) {
 }
 
 function getTab(tabName){
-    console.log('tabName', tabName)
     let tabList = ["疾病","药品通用名","症状","手术和操作","实验室检查","辅助检查"]
     let tabListCopy = tabList.slice()
     const index = tabList.findIndex(item => item == tabName)

+ 0 - 2
src/js/medicalTermMap.js

@@ -126,9 +126,7 @@ function drawGraph(data,resultShowId) {
     for(let i = 0; i < legends.length; i++){
 
         sum += 2+legends[i].name.length+1
-        console.log(sum)
         if(sum <= 65){
-            console.log(111111)
             showLegendNum ++
         }
     }

BIN
src/resources/images/favicon.ico


+ 8 - 0
webpack.config.js

@@ -3,6 +3,7 @@ const HtmlWebpackPlugin = require('html-webpack-plugin');
 const CleanWebpackPlugin = require('clean-webpack-plugin') // 清空打包目录的插件
 const MiniCssExtractPlugin = require('mini-css-extract-plugin');
 const UglifyJsPlugin = require('uglifyjs-webpack-plugin');
+const CopyWebpackPlugin = require('copy-webpack-plugin');
 const ExtractTextPlugin = require("extract-text-webpack-plugin");
 const webpack = require('webpack');
 const proxyHost = "http://192.168.2.241:5050";
@@ -91,6 +92,13 @@ module.exports = {
           collapseWhitespace: true //删除空白符与换行符
         }
       }),
+      new CopyWebpackPlugin([
+        {
+          from:'src/resources',
+          to:path.resolve(__dirname,'dist','resources'),
+          flatten:true,   //false会拷贝原始文件夹路径
+        }
+      ]),
       new MiniCssExtractPlugin({
         filename: 'css/[name].css',
         chunkFilename: '[id].css'