st-comp 0.0.154 → 0.0.155

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "st-comp",
3
3
  "public": true,
4
- "version": "0.0.154",
4
+ "version": "0.0.155",
5
5
  "type": "module",
6
6
  "scripts": {
7
7
  "dev": "vite",
@@ -200,13 +200,23 @@ const submitDialog = () => {
200
200
  }
201
201
  // 校验
202
202
  if (!radio) return ElMessage.warning("格式错误: 请选择时间");
203
- if (!checkNumber(rankRange[0]) || !checkNumber(rankRange[1])) {
203
+ if (!checkNumber(rankRange[0]) && !checkNumber(rankRange[1])) {
204
204
  return ElMessage.warning(`格式错误: 请填写${mainFlowRadioType === '0' ? '涨幅范围' : '排名范围'}`);
205
205
  }
206
206
  // 格式化文案
207
- indicatorValue.value.tagText = `${label}: ${radio}日${
208
- mainFlowRadioType === '0' ? '涨幅范围' : '排名范围'
209
- }: ${rankRange[0]}${mainFlowRadioType === '0' ? '%' : ''} ~ ${rankRange[1]}${mainFlowRadioType === '0' ? '%' : ''}`;
207
+ if (!["", null].includes(rankRange[0]) && !["", null].includes(rankRange[1])) {
208
+ indicatorValue.value.tagText = `${label}: ${radio}日${
209
+ mainFlowRadioType === '0' ? '涨幅范围' : '排名范围'
210
+ }: ${rankRange[0]}${mainFlowRadioType === '0' ? '%' : ''} ~ ${rankRange[1]}${mainFlowRadioType === '0' ? '%' : ''}`;
211
+ } else if (!["", null].includes(rankRange[0])) {
212
+ indicatorValue.value.tagText = `${label}: ${radio}日${
213
+ mainFlowRadioType === '0' ? '涨幅范围' : '排名范围'
214
+ }: ≥${rankRange[0]}${mainFlowRadioType === '0' ? '%' : ''}`;
215
+ } else {
216
+ indicatorValue.value.tagText = `${label}: ${radio}日${
217
+ mainFlowRadioType === '0' ? '涨幅范围' : '排名范围'
218
+ }: ≤${rankRange[1]}${mainFlowRadioType === '0' ? '%' : ''}`;
219
+ }
210
220
  break;
211
221
  }
212
222
  // 其它的通用处理