| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118 |
- <!DOCTYPE html>
- <html>
- <head>
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
- <meta http-equiv="X-UA-Compatible" content="IE=edge">
- <meta name="viewport" content="width=device-width,initial-scale=1.0">
- <meta name="apple-mobile-web-app-capable" content="yes">
- <meta name="apple-mobile-web-app-status-bar-style" content="black">
- <meta name="format-detection" content="telephone=no">
- <meta http-equiv="X-UA-Compatible" content="chrome=1" >
- <title>湖南宝悦新型建材有限公司</title>
- <style>
- *{
- outline: 0;
- padding: 0;
- margin: 0;
- border: none;
- box-sizing: border-box;
- background-size: contain;
- background-position: center;
- background-repeat: no-repeat;
- }
- ul,ol{
- list-style: none outside none;
- }
- ul.product-info {
- padding: 20px;
- }
- ul.product-info > li {
- line-height: 30px;
- font-size: 14px;
- }
- </style>
- </head>
- <body>
- <ul class="product-info">
- <li>
- <label for="">产品名称:</label>
- <span id="productName">-</span>
- </li>
- <li>
- <label for="">规 格:</label>
- <span id="specification">-</span>
- </li>
- <li>
- <label for="">编 码:</label>
- <span id="productCode">-</span>
- </li>
- <li>
- <label for="">批次号:</label>
- <span id="batchNo">-</span>
- </li>
- <li>
- <label for="">生产日期:</label>
- <span id="createTime">-</span>
- </li>
- <li>
- <label for="">产品检验:</label>
- <span>合格</span>
- </li>
- <li>
- <label for="">质量等级:</label>
- <span>优级</span>
- </li>
- <li>
- <label for="">生产厂家:</label>
- <span>湖南宝悦新型建材有限公司</span>
- </li>
- <li id="designDrawing">
- <!-- <img style="width: 100%; margin-top: 20px;" src="./view.jpeg" alt=""> -->
- </li>
- </ul>
- </body>
- <script>
- function str_to_obj(str){
- var obj = {};
- var temp = str.split('&');
- for(var i = 0; i < temp .length;i++) {
- var t = temp[i].split('=');
- obj[t[0]]=t[1];
- }
- return obj
- }
-
- var queryObj = str_to_obj(window.location.search.substring(1));
- var productName = document.querySelector('#productName');
- var specification = document.querySelector('#specification');
- var productCode = document.querySelector('#productCode');
- var batchNo = document.querySelector('#batchNo');
- var createTime = document.querySelector('#createTime');
- var designDrawing = document.querySelector('#designDrawing');
- if(queryObj.productName){
- productName.innerHTML = decodeURIComponent(queryObj.productName);
- }
- if(queryObj.specification){
- specification.innerHTML =decodeURIComponent(queryObj.specification)
- }
- if(queryObj.productCode){
- productCode.innerHTML = queryObj.productCode
- }
- if(queryObj.batchNo){
- batchNo.innerHTML = queryObj.batchNo;
- }
- if(queryObj.createTime){
- createTime.innerHTML = decodeURIComponent(queryObj.createTime);
- }
- // if(queryObj.de) {
- // var _img = document.createElement('img');
- // _img.src = window.location.origin + '/' + decodeURIComponent(queryObj.de);
- // // _img.src = './view.jpeg';
- // _img.style = 'width: 100%; margin-top: 20px;';
- // designDrawing.appendChild(_img);
- // }
- </script>
- </html>
|