DTStack / DTStack/Taier

[Bug] [taier-ui] 同步任务使用变量报 task params content can not be null

Open
#1,154 0 comments 0 reactions 1 assignee Claimed by @jin-sir View on GitHub
bug
Dominant language
Java
Stars
1.3k
Forks
350
PR merge metrics
No merged PRs in 30d

Description

### Search before asking

- [X] I had searched in the [issues](https://github.com/DTStack/Taier/issues) and found no similar issues.

### What happened

**1.4.0 版本**

### 场景一
同步任务向导模式,配置了系统变量,点击转化成脚本模式报异常
---
![image](https://github.com/DTStack/Taier/assets/8185717/b25ef649-abf9-498e-98b5-3d0e2837190a)

### 场景二
同步任务脚本模式,脚本中存在系统变量,任务保存失败
---
![image](https://github.com/DTStack/Taier/assets/8185717/648461d2-c3c2-4cb4-95ca-bf048188cf45)

### What you expected to happen

任务保存成功或脚本转化成功

### How to reproduce

```sql
# 示例脚本
{
"job": {
"content": [
{
"reader": {
"parameter": {
"url": "xxx",
"fetchSize": 1000,
"collectionName": "AlarmType",
"filter": "{tenantId:'system'}",
"column": [
{
"name": "_id",
"type": "string"
},
{
"name": "notificationMode",
"type": "string",
"value": "${bdp.system.cyctime}"
}
]
},
"name": "mongodbreader"
},
"writer": {
"parameter": {
"mode": "update",
"postSql": [],
"password": "xxx",
"uniqueKey": [
"id"
],
"column": [
{
"name": "id",
"type": "string"
},
{
"name": "notificationMode",
"type": "string"
}
],
"connection": [
{
"jdbcUrl": "xxxx",
"table": [
"alarm_type"
]
}
],
"username": "root"
},
"name": "mysqlwriter"
}
}
]
}
}
```

### Anything else

_No response_

### Version

v1.4

### Are you willing to submit PR?

- [ ] Yes I am willing to submit a PR!

### Code of Conduct

- [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.