Browse Source

fix:手动创建信息价库,期数缺失分割符“-”

vian 5 years ago
parent
commit
2bfc308c89
1 changed files with 1 additions and 1 deletions
  1. 1 1
      modules/price_info_lib/facade/index.js

+ 1 - 1
modules/price_info_lib/facade/index.js

@@ -16,7 +16,7 @@ async function getLibs(query) {
 async function createLib(name, period, compilationID) {
 async function createLib(name, period, compilationID) {
     // 将2020-01变成2020年01月
     // 将2020-01变成2020年01月
     const reg = /(\d{4})-(\d{2})/;
     const reg = /(\d{4})-(\d{2})/;
-    const formattedPeriod = period.replace(reg, '$1年$2月');
+    const formattedPeriod = period.replace(reg, '$1年-$2月');
     const lib = {
     const lib = {
         ID: uuidV1(),
         ID: uuidV1(),
         name,
         name,