Эх сурвалжийг харах

Merge branch 'feature/v4.8.70' of https://jygit.jydev.jianyu360.cn/qmx/jy into dev/v4.8.70_wmh

wenmenghao321 1 жил өмнө
parent
commit
77e7b10c03

+ 1 - 1
src/jfw/modules/subscribepay/src/service/dataexportPack.go

@@ -54,7 +54,7 @@ func (des *DataExportPack) ScreenList() {
 				"$gte": time.Now().AddDate(-1, 0, 0).Unix(),
 			},
 		}
-		data, ok := util.MQFW.Find("export_condition", qMap, `{"update_time":1}`, "", false, -1, -1)
+		data, ok := util.MQFW.Find("export_condition", qMap, `{"update_time":-1}`, "", false, -1, -1)
 		if !ok {
 			log.Printf("获取筛选条件失败;qMap:%v", qMap)
 			return nil, errors.New("获取筛选条件失败")

+ 67 - 1
src/web/staticres/dataExport/css/previewData.css

@@ -36,6 +36,14 @@ body{
     white-space: nowrap;
 }
 
+.d_body .d_gj tr:nth-child(1) td,.d_gj tr:nth-child(2) td{
+  background-color: transparent;
+}
+
+.d_body .d_bz tr:nth-child(1) td,.d_bz tr:nth-child(2) td{
+  background-color: transparent;
+}
+
 .d_bz tr:nth-child(odd),.d_gj tr:nth-child(odd){
 	background-color: #f9f9f9;
 }
@@ -209,7 +217,9 @@ body{
 .d_gj tr.multi_packet_tr:last-child td{
   border-bottom: none;
 }
-
+th {
+  height: 54px; /* 设置多级表头的高度 */
+}
 .floatBtn{
     border-radius: 5px;
     padding-top: 15px;
@@ -248,3 +258,59 @@ body{
 	top: 0px;
     left: 0px;
 }
+
+.d_body {
+  position: relative;
+  width: fit-content;
+}
+.d_body .d_gj {
+  min-width: initial;
+}
+.d_body .d_gj .el-table__header-wrapper .is-group tr th {
+  padding: 0;
+}
+.d_body .d_gj .el-table__header-wrapper .is-group tr th .cell {
+  padding: 0 4px;
+}
+
+.d_body .d_bz {
+  min-width: initial;
+}
+.d_body .d_bz .el-table__header-wrapper tr th {
+  padding: 0;
+}
+.d_body .d_bz .el-table__header-wrapper tr th .cell {
+  padding: 0 4px;
+}
+
+.d_body td {
+  font-family: MyNewFont,'微软雅黑';
+}
+
+.d_body .d_gj tr:nth-child(1) td,.d_gj tr:nth-child(2) td{
+  padding: 0;
+}
+.d_body .el-table .el-table__cell{
+  padding: 0;
+}
+.d_body .el-table .cell {
+  padding: 2px 5px;
+  line-height: 18px;
+}
+
+.d_body .el-table .winner_list{
+  display: flex;
+  flex-direction: column;
+}
+
+.d_body .el-table .set-table-line{
+  width: 100%;
+  height: 24px;
+  border-bottom: 1px solid #e6e6e6;
+}
+.d_body .el-table .set-table-line:last-child{
+  border-bottom: none;
+}
+.d_body .el-table .set-cell-padding .cell {
+  padding:  2px 0;
+}

+ 26 - 9
src/web/templates/pc/dataExport_sieve.html

@@ -729,7 +729,7 @@
                     <span v-if="item.additionalWords && item.searchvalue">,</span>
                     ${formatToComma(item.additionalWords)}
                     <span v-if="item.additionalWords">${!item.wordsMode ? '(包含所有关键词)' : '(包含任意关键词)'}</span> -->
-                    筛选${index + 1}
+                    筛选${filterData.length - index}
                   </span>
                 </div>
                 <i class="j-icon icon-clean" @click.stop="onDeleteFilter(item._id)"></i>
@@ -743,7 +743,7 @@
                     <p class="f-l-c-item" v-if="item.industry">行业:<em class="i-value">${formatIndustry(item.industry)}</em></p>
                     <p class="f-l-c-item" v-if="item.buyerclass">采购单位类型:<em class="i-value">${formatBuyerClass(item.buyerclass)}</em></p>
                     <p class="f-l-c-item" v-if="item.keyword">关键词:<em class="i-value">${formatKeyword(item.keyword)}</em></p>
-                    <p class="f-l-c-item" v-if="item.buyerclass">关键词匹配方式:<em class="i-value">${formatScope(item.selectType, 'CN')}</em></p>
+                    <p class="f-l-c-item" v-if="item.selectType">关键词匹配方式:<em class="i-value">${formatScope(item.selectType, 'CN')}</em></p>
                     <p class="f-l-c-item">
                       <span v-if="item.minprice || item.maxprice">金额:<em class="i-value">${formatPriceScope(item.minprice, item.maxprice)}</em></span>
                       <!-- <span v-if="item.publishtime">发布时间:<em class="i-value">${item.publishtime}</em></span> -->
@@ -3082,6 +3082,14 @@
         }
     });
 
+    $("#keyInput").on('input', function () {
+        if($(this).val()) {
+          $(this).next().show()
+        } else {
+          $(this).next().hide()
+        }
+    })
+
     $("#sieve").click(function () {
         dataNode.loading = true
         $("#sieve").addClass("sussecc");
@@ -3235,8 +3243,8 @@
         $(".add-input-w").hide();
         window["inputDel_0"] = [];
         //selectType
-        $(".selectType button").removeClass("select");
-        $(".selectType button").eq(0).addClass("select");
+        $(".selectType .el-checkbox__input").removeClass("is-checked");
+        $(".selectType .el-checkbox__input").eq(0).addClass("is-checked");
         //price
         $("#minprice").val("");
         $("#maxprice").val("");
@@ -3640,6 +3648,13 @@
             });
         }
         //金额
+        const min = paramObj["minprice"];
+        const max = paramObj["maxprice"];
+        if(min || max) {
+          priceAllBtnSel == "0"
+        } else {
+          priceAllBtnSel = "1"
+        }
         priceDisSel();
         priceConfirmHide();
         if (priceAllBtnSel == "1") {
@@ -3726,11 +3741,13 @@
     if (selectType.indexOf('purchasing,projectname.pname') !== -1) {
       dataNode.checkList.push('4')
     }
-    $(".selectType button").each(function () {
-        if ($(this).text() === select) {
-            $(".selectType button").removeClass("select");
-            $(this).addClass("select");
-        }
+    $(".selectType .el-checkbox").each(function () {
+      const checked = $(this).hasClass('is-checked')
+      if(checked) {
+        $(this).find('.el-checkbox__input').addClass('is-checked')
+      } else {
+        $(this).find('.el-checkbox__input').removeClass('is-checked')
+      }
     });
   }
   function arrToString(v){

+ 103 - 65
src/web/templates/pc/previewData.html

@@ -33,8 +33,11 @@
       <div class="d_bz" v-if="dataType == '1'">
         <el-table
           :data="getList"
-          stripe
-          style="width: 100%">
+          :row-style="rowStyle"
+          style="width: 100%"
+          :header-row-style="headerRowStyle"
+          :header-cell-style="setHeaderStyle"
+          >
           <el-table-column
           v-for="(item, index) in bzInfo"
             :key="index"
@@ -51,10 +54,11 @@
       <div class="d_gj" v-if="dataType == '2'">
         <el-table
           :data="getList"
-          stripe
+          :header-row-style="headerRowStyle"
+          :header-cell-style="setHeaderStyle"
           style="width: 100%">
           <el-table-column
-          v-for="(item, index) in gjInfo"
+            v-for="(item, index) in gjInfo"
             :key="index"
             :type="index === 0 ? 'index' : undefined"
             :prop="item.filed"
@@ -84,7 +88,7 @@
                 align="center"
                 >
                 <template slot-scope="scope">
-                  ${textFormatForMosaic(scope.row.buyerperson)}
+                  {scope.row.buyerperson ? textFormatForMosaic(scope.row.buyerperson) : '-'}
                 </template>
               </el-table-column>
               <el-table-column
@@ -94,7 +98,7 @@
                 align="center"
                 >
                 <template slot-scope="scope">
-                  ${textFormatForMosaic(scope.row.buyertel)}
+                  {textFormatForMosaic(scope.row.buyertel)}
                 </template>
               </el-table-column>
               <el-table-column
@@ -108,90 +112,95 @@
             <template v-if="item.title == '中标单位信息(来源:招标公告网站)'">
               <el-table-column
                 prop="s_winner"
-                width="154"
+                width="200"
                 label="单位名称"
+                class-name="set-cell-padding"
                 align="center"
                 >
                 <template slot-scope="scope">
-                  <div v-if="scope.row.winnerList && scope.row.winnerList.length">
-                    <div v-for="win in scope.row.winnerList" class="mosaic-text">
-                      ${win}<br>
+                  <div class="winner_list" v-if="scope.row.winnerList && scope.row.winnerList.length">
+                    <div class="set-table-line" v-for="win in scope.row.winnerList">
+                      {win}<br>
                     </div>
                   </div>
-                  <div v-else class="mosaic-text">${scope.row.s_winner}</div>
+                  <div v-else>{scope.row.s_winner}</div>
                 </template>
               </el-table-column>
               <el-table-column
                 prop="winnerperson"
-                width="47"
+                width="74"
                 label="联系人"
                 align="center"
                 >
                 <template slot-scope="scope">
-                  ${textFormatForMosaic(scope.row.winnerperson)}
+                  {scope.row.winnerperson}
                 </template>
               </el-table-column>
               <el-table-column
                 prop="winnertel"
-                width="59"
+                width="66"
                 label="联系电话"
                 align="center"
                 >
                 <template slot-scope="scope">
-                  ${textFormatForMosaic(scope.row.winnertel)}
+                  {scope.row.winnertel}
                 </template>
               </el-table-column>
             </template>
             <template v-if="item.title == '中标单位信息(来源:国家企业公示网站)'">
               <el-table-column
                 prop="legal_person"
-                width="48"
+                width="60"
                 label="联系人"
+                class-name="set-cell-padding"
                 align="center"
                 >
                 <template slot-scope="scope">
-                  <div v-if="scope.row.personArr && scope.row.personArr.length">
-                    <div v-for="person in scope.row.personArr">
-                      ${person}<br>
+                  <div class="winner_list" v-if="scope.row.personArr && scope.row.personArr.length">
+                    <div class="set-table-line" v-for="person in scope.row.personArr">
+                      {person || '-'}<br>
                     </div>
                   </div>
-                  <div v-else>${scope.row.legal_person}</div>
+                  <div v-else>{scope.row.legal_person}</div>
                 </template>
               </el-table-column>
               <el-table-column
                 prop="company_phone"
-                width="60"
+                width="100"
                 label="联系电话"
+                class-name="set-cell-padding"
                 align="center"
                 >
                 <template slot-scope="scope">
-                  <div v-if="scope.row.phoneArr && scope.row.phoneArr.length">
-                    <div v-for="phone in scope.row.phoneArr">
-                      ${phone}<br>
+                  <div class="winner_list" v-if="scope.row.phoneArr && scope.row.phoneArr.length">
+                    <div class="set-table-line" v-for="phone in scope.row.phoneArr">
+                      {phone || '-'}<br>
                     </div>
                   </div>
-                  <div v-else>${scope.row.company_phone}"></div>
+                  <div v-else>{scope.row.company_phone}</div>
                 </template>
               </el-table-column>
               <el-table-column
                 prop="company_email"
                 width="106"
                 label="电子邮箱"
+                class-name="set-cell-padding"
                 align="center"
                 >
                 <template slot-scope="scope">
-                  <div v-if="scope.row.emailArr && scope.row.emailArr.length">
-                    <div v-for="email in scope.row.emailArr">
-                      ${email}<br>
+                  <div class="winner_list" v-if="scope.row.emailArr && scope.row.emailArr.length">
+                    <div class="set-table-line" v-for="email in scope.row.emailArr">
+                      {email || '-'}<br>
                     </div>
                   </div>
-                  <div v-else>${scope.row.company_email}"></div>
+                  <div v-else>{scope.row.company_email}</div>
                 </template>
               </el-table-column>
             </template>
           </el-table-column>
         </el-table>
       </div>
+      <div class="sy"></div>
     </div>
 	</body>
 	<script>
@@ -210,39 +219,39 @@
           {width: '60', filed: 'city', title: '城市'},
           {width: '262', filed: 'title', title: '公告标题'},
           {width: '60', filed: 'subtype', title: '公告类别'},
-          {width: '80', filed: 'publishtime', title: '发布时间'},
+          {width: '90', filed: 'publishtime', title: '发布时间'},
           {width: '202', filed: 'buyer', title: '采购单位'},
           {width: '202', filed: 's_winner', title: '中标单位'},
-          {width: '75', filed: 'bidamount', title: '中标金额'},
-          {width: '202', filed: 'projectname', title: '项目名称'},
+          {width: '75', filed: 'bidamount', title: '中标金额(万元)'},
+          {width: '262', filed: 'projectname', title: '项目名称'},
           {width: '484', filed: 'detail', title: '公告内容'},
-          {width: '156', filed: 'url', title: '剑鱼标讯地址'}
+          {width: '200', filed: 'url', title: '剑鱼标讯地址'}
         ],
         gjInfo: [
           {width: '40', filed: 'index', title: '序号',},
           {width: '70', filed: 'keyword', title: '匹配关键词',},
-          {width: '50', filed: 'area', title: '省份',},
-          {width: '50', filed: 'city', title: '城市',},
-          {width: '50', filed: 'district', title: '区县',},
-          {width: '155', filed: 'title', title: '公告标题',},
+          {width: '60', filed: 'area', title: '省份',},
+          {width: '60', filed: 'city', title: '城市',},
+          {width: '60', filed: 'district', title: '区县',},
+          {width: '153', filed: 'title', title: '公告标题',},
           {width: '60', filed: 'subtype', title: '公告类别',},
           {width: '221', filed: 'detail', title: '公告内容',},
-          {width: '82', filed: 'publishtime', title: '发布时间',},
+          {width: '90', filed: 'publishtime', title: '发布时间',},
           {width: '116', filed: 'href', title: '公告地址',},
           {width: '123', filed: 'url', title: '剑鱼标讯地址',},
           {width: '136', filed: 'projectname', title: '项目名称',},
           {width: '160', filed: 'buyerclass', title: '行业',},
           {width: '146', filed: 'projectcode', title: '项目编号',},
           {width: '146', filed: 'projectscope', title: '项目范围',},
-          {width: '84', filed: 'budget', title: '预算金额(万元)',},
-          {width: '84', filed: 'bidamount', title: '中标金额(万元)',},
-          {width: '76', filed: 'signendtime', title: '报名截止日期',},
-          {width: '84', filed: 'bidopentime', title: '开标日期',},
-          {width: '76', filed: 'bidendtime', title: '投标截止日期',},
+          {width: '64', filed: 'budget', title: '预算金额(万元)',},
+          {width: '64', filed: 'bidamount', title: '中标金额(万元)',},
+          {width: '90', filed: 'signendtime', title: '报名截止日期',},
+          {width: '90', filed: 'bidopentime', title: '开标日期',},
+          {width: '90', filed: 'bidendtime', title: '投标截止日期',},
           {width: '', filed: '', title: '采购单位信息',},
           {width: '143', filed: 's_topscopeclass', title: '招标代理机构',},
-          {width: '', filed: 'buyerperson', title: '中标单位信息(来源:招标公告网站)',},
-          {width: '', filed: 'buyertel', title: '中标单位信息(来源:国家企业公示网站)',}
+          {width: '', filed: '', title: '中标单位信息(来源:招标公告网站)',},
+          {width: '', filed: '', title: '中标单位信息(来源:国家企业公示网站)',}
         ]
       }
     },
@@ -297,31 +306,60 @@
         }
         this.listInfo = list
         return this.listInfo
+      },
+      setHeaderStyle () {
+        return {
+            textAlign: 'center',
+            height: '14px',
+            background: '#e9f6ff',
+            color: '#565f66',
+            'border-right': '1px solid #DCE1E4',
+            'border-bottom': '1px solid #DCE1E4'
+        }
+      },
+      headerRowStyle () {
+        if(this.dataType === '1') {
+          return {
+            height: '54px',
+            fontSize: '12px',
+          }
+        } else if(this.dataType === '2') {
+          return {
+            height: '31px',
+            fontSize: '12px',
+          }
+        }
+      },
+      rowStyle () {
+        return {
+          'min-height': '58px',
+          'height': '58px',
+        }
       }
     },
     methods: {
     }
   })
 	// 字体加载异常处理
-	// try {
-	// 	document.fonts.ready.then(function() {
-	// 		renderImg()
-	// 	});
-	// } catch (err) {
-	// 	console.log(err)
-	// }
-	// try {
-	// 	var font = new FontFaceObserver('MyNewFont');
-	// 	font.load().then(function () {
-	// 		var html = document.querySelector('body');
-	// 		html.classList.add('font-loaded');
-	// 		renderImg()
-	// 	}, function () {
-	// 		console.log('Font is not available');
-	// 	});
-	// } catch (err) {
-	// 	console.log(err)
-	// }
+	try {
+		document.fonts.ready.then(function() {
+			renderImg()
+		});
+	} catch (err) {
+		console.log(err)
+	}
+	try {
+		var font = new FontFaceObserver('MyNewFont');
+		font.load().then(function () {
+			var html = document.querySelector('.d_body');
+			html.classList.add('font-loaded');
+			renderImg()
+		}, function () {
+			console.log('Font is not available');
+		});
+	} catch (err) {
+		console.log(err)
+	}
 	function isIE(){
 		if(!!window.ActiveXObject || "ActiveXObject" in window){
 			return true;
@@ -366,7 +404,7 @@
 	function renderImg () {
 		var w=$("table").width();
 		var h=$("table").height();
-		$(".sy").width($("table").width()).height($("table").height());
+		$(".sy").width($("table").width()).height('100%');
 		html2canvas(document.querySelector("body"),{
 			useCORS:true,
 			scale:1,