ygp-gdzwfw-gov-cn/assets/objectDestructuringEmpty-a5c19c06.js
秦秋旭 5acb847bc1 优化爬虫:增量爬取、API参数优化、Excel兼容
主要变更:
1. 重命名 ygp_crawler.py -> main.py
2. API参数优化:
   - tradingProcess 固定传 "513,2C52,3C52" 精准筛选中标结果
   - pageSize 固定为 50 提高抓取效率
   - 通过 publishStartTime/publishEndTime 传入时间范围
3. 默认查询最近3个月(原为当天)
4. 增量爬取改为默认开启(移除 -i 参数)
5. CSV文件添加 UTF-8 BOM,Excel可直接打开
6. 更新 README.md 文档
7. 添加前端 JS 代码参考文件到 assets/ 目录

使用方法:
- 增量更新:python main.py
- 全量查询:rm results.csv && python main.py

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-02-05 00:37:07 +08:00

19 lines
3.5 KiB
JavaScript

import{d as p,n as l}from"./default-1fc3bc07.js";var m=`accept acceptcharset accesskey action allowfullscreen allowtransparency
alt async autocomplete autofocus autoplay capture cellpadding cellspacing challenge
charset checked classid classname colspan cols content contenteditable contextmenu
controls coords crossorigin data datetime default defer dir disabled download draggable
enctype form formaction formenctype formmethod formnovalidate formtarget frameborder
headers height hidden high href hreflang htmlfor for httpequiv icon id inputmode integrity
is keyparams keytype kind label lang list loop low manifest marginheight marginwidth max maxlength media
mediagroup method min minlength multiple muted name novalidate nonce open
optimum pattern placeholder poster preload radiogroup readonly rel required
reversed role rowspan rows sandbox scope scoped scrolling seamless selected
shape size sizes span spellcheck src srcdoc srclang srcset start step style
summary tabindex target title type usemap value width wmode wrap`,h=`onCopy onCut onPaste onCompositionend onCompositionstart onCompositionupdate onKeydown
onKeypress onKeyup onFocus onBlur onChange onInput onSubmit onClick onContextmenu onDoubleclick onDblclick
onDrag onDragend onDragenter onDragexit onDragleave onDragover onDragstart onDrop onMousedown
onMouseenter onMouseleave onMousemove onMouseout onMouseover onMouseup onSelect onTouchcancel
onTouchend onTouchmove onTouchstart onTouchstartPassive onTouchmovePassive onScroll onWheel onAbort onCanplay onCanplaythrough
onDurationchange onEmptied onEncrypted onEnded onError onLoadeddata onLoadedmetadata
onLoadstart onPause onPlay onPlaying onProgress onRatechange onSeeked onSeeking onStalled onSuspend onTimeupdate onVolumechange onWaiting onLoad onError`,s="".concat(m," ").concat(h).split(/[\s\n]+/),f="aria-",g="data-";function d(n,e){return n.indexOf(e)===0}function b(n){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,o;e===!1?o={aria:!0,data:!0,attr:!0}:e===!0?o={aria:!0}:o=p({},e);var t={};return Object.keys(n).forEach(function(a){(o.aria&&(a==="role"||d(a,f))||o.data&&d(a,g)||o.attr&&(s.includes(a)||s.includes(a.toLowerCase())))&&(t[a]=n[a])}),t}var E=function(){return l()&&window.document.documentElement},u=function(e){if(l()&&window.document.documentElement){var o=Array.isArray(e)?e:[e],t=window.document.documentElement;return o.some(function(a){return a in t.style})}return!1},v=function(e,o){if(!u(e))return!1;var t=document.createElement("div"),a=t.style[e];return t.style[e]=o,t.style[e]!==a};function C(n,e){return!Array.isArray(n)&&e!==void 0?v(n,e):u(n)}var i;function y(n){if(typeof document>"u")return 0;if(n||i===void 0){var e=document.createElement("div");e.style.width="100%",e.style.height="200px";var o=document.createElement("div"),t=o.style;t.position="absolute",t.top="0",t.left="0",t.pointerEvents="none",t.visibility="hidden",t.width="200px",t.height="150px",t.overflow="hidden",o.appendChild(e),document.body.appendChild(o);var a=e.offsetWidth;o.style.overflow="scroll";var r=e.offsetWidth;a===r&&(r=o.clientWidth),document.body.removeChild(o),i=a-r}return i}function c(n){var e=n.match(/^(.*)px$/),o=Number(e==null?void 0:e[1]);return Number.isNaN(o)?y():o}function S(n){if(typeof document>"u"||!n||!(n instanceof Element))return{width:0,height:0};var e=getComputedStyle(n,"::-webkit-scrollbar"),o=e.width,t=e.height;return{width:c(o),height:c(t)}}function x(n){if(n==null)throw new TypeError("Cannot destructure "+n)}export{x as _,S as a,E as c,y as g,C as i,b as p};