| | |
| | | </el-form-item> |
| | | </div> |
| | | <div class="fomItem2"> |
| | | <el-form-item class="fomItemInput1" label="公式:"> |
| | | <!-- <formula :returnFormula="evalResult"/> --> |
| | | <el-input type="textarea" autosi:autosize="{ minRows: 2, maxRows: 4}"ze placeholder="请输入内容" v-model="configForm.formula" @change="evalResult"> </el-input> |
| | | <el-form-item class="fomItemInput1"> |
| | | <template v-slot="label"> |
| | | 公式: |
| | | <el-tooltip class="itemFomItem" effect="dark" content="求参数最大值,参数个数最少两个,如:MAX(1,2)" placement="top"> |
| | | <label>MAX()</label> |
| | | </el-tooltip> |
| | | <el-tooltip class="itemFomItem" effect="dark" content="求参数最小值,参数个数最少两个,如:MIN(1,2)" placement="top"> |
| | | <label>MIN()</label> |
| | | </el-tooltip> |
| | | <el-tooltip class="itemFomItem" effect="dark" content="求和,参数个数最少两个,如:SUM(1,2)" placement="top"> |
| | | <label>SUM()</label> |
| | | </el-tooltip> |
| | | <el-tooltip class="itemFomItem" effect="dark" content="求绝对值,参数个数最少一个,如:ABS(1)" placement="top"> |
| | | <label>ABS()</label> |
| | | </el-tooltip> |
| | | <el-tooltip class="itemFomItem" effect="dark" content="求平均值,参数个数最少两个个,如:AVERAGE(1,2)" placement="top"> |
| | | <label>AVERAGE()</label> |
| | | </el-tooltip> |
| | | <el-tooltip class="itemFomItem" effect="dark" content="求中值,参数个数最少两个个,如:MEDIAN(1,2)" placement="top"> |
| | | <label>MEDIAN()</label> |
| | | </el-tooltip> |
| | | <el-input type="textarea" autosi:autosize="{ minRows: 2, maxRows: 4}"ze placeholder="请输入内容" v-model="configForm.formula" @change="evalResult"> </el-input> |
| | | </template> |
| | | </el-form-item> |
| | | </div> |
| | | </el-form> |
| | |
| | | </template> |
| | | |
| | | <script> |
| | | import formula from '../../tool/formula.vue' |
| | | |
| | | export default { |
| | | name: "dataAcquisitionConfig", |
| | | // import 引入的组件需要注入到对象中才能使用 |
| | | components: { |
| | | formula |
| | | }, |
| | | props: { |
| | | deviceId: { |
| | |
| | | this.$axios.get(this.$api.deviceScope.queryDataAcquisitionConfiguration + "?deviceId=" + this.deviceId + "&isDevice=" + false).then(res => { |
| | | this.tableList = res.data |
| | | this.tableList.forEach(i => { |
| | | i.sample = i.sample.replaceAll('"', '').replaceAll("],", ';').replaceAll("[", '').replaceAll('"', '').replaceAll(']', '') |
| | | // replace(/=/g, ' ') |
| | | i.sample = i.sample.replace(/"/g, '').replace(/],/g, ';').replace(/\[/g, '').replace(/]/g, '') |
| | | }) |
| | | if(this.tableList[0]) { |
| | | this.$set(this.configForm, 'fileType', this.tableList[0].fileType) |
| | |
| | | </script> |
| | | |
| | | <style scoped> |
| | | .itemFomItem { |
| | | margin-left: 20px; |
| | | } |
| | | |
| | | .search_thing { |
| | | width: 350px; |
| | | display: flex; |