Bläddra i källkod

医学术语映射(未完成)

zhangxc 4 år sedan
förälder
incheckning
f3ca86e9a2
4 ändrade filer med 157 tillägg och 25 borttagningar
  1. 61 0
      src/css/medicalTermMap.less
  2. 52 0
      src/html/medicalTermMap.html
  3. 4 0
      src/js/medicalTermMap.js
  4. 40 25
      webpack.config.js

+ 61 - 0
src/css/medicalTermMap.less

@@ -0,0 +1,61 @@
+.knowledgeMapWrapper{
+    min-width: 1200px;
+  /* .title{
+        position: relative;
+        height: 40px;
+        line-height: 40px;
+        background-image: linear-gradient(to right, #5A8EEE , #7EABFF);
+       filter:progid:DXImageTransform.Microsoft.gradient(GradientType=1, startColorstr=#1471da,endColorstr=#1C85FB);!*IE<9>*!
+        -ms-filter:"progid:DXImageTransform.Microsoft.gradient(GradientType=1, startColorstr=#1471da, endColorstr=#1C85FB)";!*IE8+*!
+
+    }
+    .titleTxt{
+        position: relative;
+        width: 1200px;
+        left: 50%;
+        margin-left: -600px;
+        color: #fff;
+        font-size: 14px;
+    }
+    .titleLogo{
+        position: relative;
+        top: -2px;
+        height: 20px;
+        margin: 0 20px 0 0;
+    }
+    .titleLogoShaiyifu{
+        top: 5px;
+        height: 30px;
+    }
+    .titleInfo{
+        position: relative;
+        display: inline-block;
+        top: -4px;
+        height: 40px;
+        line-height: 40px;
+    }*/
+   .content{
+       position: relative;
+       width: 1200px;
+       left: 50%;
+       margin-left: -600px;
+       cursor: default;
+       height: 100%;
+   }
+   .bottom{
+    
+       background: #fff;
+     
+       position: relative;
+   }
+   
+  .footer{
+      position: absolute;
+      width: 100%;
+      bottom: 10px;
+      text-align: center;
+      font-size: 12px;
+      color: #ccc;
+  }
+  
+}

+ 52 - 0
src/html/medicalTermMap.html

@@ -0,0 +1,52 @@
+<!DOCTYPE html>
+<html lang="en">
+
+<head>
+	<meta charset="UTF-8">
+	<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 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>
+
+<body>
+	<div class="knowledgeMapWrapper wrappper">
+		<div class="title">
+			<div class="titleTxt">
+				<img class="titleLogo" src="./images/logo.png" alt="logo">
+				 <img class="titleLogo titleLogoShaiyifu" src="./images/logo_shaoyifu.png" alt="logo">
+				<span class="titleInfo">|&nbsp;&nbsp;医学术语映射</span>
+			</div>
+		</div>
+		<div class="content clearfix">
+            <div class="top">
+                <div class="topLeft">
+                    <div class="tabList"></div>
+                    <textarea name="" id="" cols="30" rows="10"></textarea>
+                </div>
+                <div class="topRight">
+                    <p class="mapResultTitle">
+                        标准词映射结果
+                    </p>
+                    <div class="mapResult"></div>
+                </div>
+                <div>
+                    <span class="submit">提交</span>
+                </div>
+            </div>
+			<div class="bottom">
+                <p class="graphTitle">图谱映射结果</p>
+				<div id="main" class="mapWrapper" style="width: 796px;height:600px;cursor: pointer;"></div>
+				 <div class="footer">
+					杭州朗通信息技术有限公司 & 浙江大学医学院附属邵逸夫医院&nbsp;&nbsp;&nbsp;联合开发
+				</div>
+			</div>
+			
+		</div>
+		
+	</div>
+
+</body>
+
+</html>

+ 4 - 0
src/js/medicalTermMap.js

@@ -0,0 +1,4 @@
+const $ = require("jquery");
+require("babel-polyfill");
+const echarts = require("echarts");
+require("./../css/medicalTermMap.less");

+ 40 - 25
webpack.config.js

@@ -13,6 +13,7 @@ module.exports = {
     knowledgeTree: path.resolve(__dirname, 'src/js', 'knowledgeTree.js'),
     participle: path.resolve(__dirname,'src/js', 'participle.js'),
     qaPage:path.resolve(__dirname,'src/js', 'qaPage.js'),
+    medicalTermMap:path.resolve(__dirname,'src/js', 'medicalTermMap.js'),
     vendor: 'lodash'// 多个页面所需的公共库文件,防止重复打包带入
   },
   output: {
@@ -63,31 +64,45 @@ module.exports = {
           removeComments: true, //移除HTML中的注释
           collapseWhitespace: true //删除空白符与换行符
         }
-      }),new HtmlWebpackPlugin({
-      title: '智能问答',
-      template: path.resolve(__dirname, 'src/html', 'qaPage.html'),
-      filename: 'qaPage.html',
-      chunks: ['qaPage', 'vendor', 'common'],
-      inject: true,
-      hash: true, //防止缓存
-      minify: {
-        removeAttributeQuotes: true, //压缩 去掉引号
-        removeComments: true, //移除HTML中的注释
-        collapseWhitespace: true //删除空白符与换行符
-      }
-    }),
-    new MiniCssExtractPlugin({
-      filename: 'css/[name].css',
-      chunkFilename: '[id].css'
-    }),
-    new webpack.ProvidePlugin({
-        $: 'jquery',
-        jQuery: 'jquery',
-        'window.jQuery': 'jquery'
-    }),
-    new webpack.HotModuleReplacementPlugin(),
-    new CleanWebpackPlugin(),
-    new ExtractTextPlugin("stylesheets/[name].css"),
+      }),
+      new HtmlWebpackPlugin({
+        title: '智能问答',
+        template: path.resolve(__dirname, 'src/html', 'qaPage.html'),
+        filename: 'qaPage.html',
+        chunks: ['qaPage', 'vendor', 'common'],
+        inject: true,
+        hash: true, //防止缓存
+        minify: {
+          removeAttributeQuotes: true, //压缩 去掉引号
+          removeComments: true, //移除HTML中的注释
+          collapseWhitespace: true //删除空白符与换行符
+        }
+      }),
+      new HtmlWebpackPlugin({
+        title: '医学术语映射',
+        template: path.resolve(__dirname, 'src/html', 'medicalTermMap.html'),
+        filename: 'medicalTermMap.html',
+        chunks: ['medicalTermMap', 'vendor', 'common'],
+        inject: true,
+        hash: true, //防止缓存
+        minify: {
+          removeAttributeQuotes: true, //压缩 去掉引号
+          removeComments: true, //移除HTML中的注释
+          collapseWhitespace: true //删除空白符与换行符
+        }
+      }),
+      new MiniCssExtractPlugin({
+        filename: 'css/[name].css',
+        chunkFilename: '[id].css'
+      }),
+      new webpack.ProvidePlugin({
+          $: 'jquery',
+          jQuery: 'jquery',
+          'window.jQuery': 'jquery'
+      }),
+      new webpack.HotModuleReplacementPlugin(),
+      new CleanWebpackPlugin(),
+      new ExtractTextPlugin("stylesheets/[name].css"),
   ],
   optimization: { //webpack4.x的最新优化配置项,用于提取公共代码
     minimizer: [