| | |
| | | /> |
| | | </el-form-item> |
| | | <el-form-item label="采集类型" prop="type"> |
| | | <el-input |
| | | v-model="queryParams.node" |
| | | placeholder="请输入采集类型" |
| | | clearable |
| | | @keyup.enter.native="handleQuery" |
| | | /> |
| | | <el-select v-model="queryParams.type" placeholder="请选择订阅状态" clearable> |
| | | <el-option |
| | | v-for="dict in dict.type.collection_type" |
| | | :key="dict.value" |
| | | :label="dict.label" |
| | | :value="dict.value" |
| | | /> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="订阅" prop="subscribe"> |
| | | <el-select v-model="queryParams.subscribe" placeholder="请选择订阅状态" clearable> |
| | | <el-option |
| | | v-for="dict in dict.type.sys_yes_no" |
| | | :key="dict.value" |
| | | :label="dict.label" |
| | | :value="dict.value" |
| | | /> |
| | | </el-select> |
| | | </el-form-item> |
| | | |
| | | <el-form-item style="float: right" > |
| | |
| | | v-hasPermi="['sc:opcConf:export']" |
| | | >导出</el-button> |
| | | </el-col> |
| | | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> |
| | | </el-row> |
| | | |
| | | <el-table v-loading="loading" border :data="opcConfList" @selection-change="handleSelectionChange"> |
| | |
| | | <el-table-column label="工位编码" align="center" prop="locationCode" /> |
| | | <el-table-column label="工位名称" align="center" prop="locationName" /> |
| | | <el-table-column label="地址" align="center" prop="node" /> |
| | | <el-table-column label="采集类型" align="center" prop="type" /> |
| | | <el-table-column label="采集类型" align="center" prop="type" > |
| | | <template slot-scope="scope"> |
| | | <dict-tag :options="dict.type.collection_type" :value="scope.row.type"/> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="是否订阅" align="center" prop="subscribe" > |
| | | <template slot-scope="scope"> |
| | | <dict-tag :options="dict.type.sys_yes_no" :value="scope.row.subscribe"/> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="操作" align="center" class-name="small-padding fixed-width"> |
| | | <template slot-scope="scope"> |
| | | <el-button |
| | | size="mini" |
| | | style="width: 72px" |
| | | type="success" |
| | | plain |
| | | icon="el-icon-edit" |
| | | @click="handleUpdate(scope.row)" |
| | | v-hasPermi="['sc:opcConf:edit']" |
| | | >修改</el-button> |
| | | <el-button |
| | | size="mini" |
| | | style="width: 72px" |
| | | type="danger" |
| | | plain |
| | | icon="el-icon-delete" |
| | | @click="handleDelete(scope.row)" |
| | | v-hasPermi="['sc:opcConf:remove']" |
| | | >删除</el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | |
| | | <el-input v-model="form.node" placeholder="请输入地址" /> |
| | | </el-form-item> |
| | | <el-form-item label="采集类型" prop="type"> |
| | | <el-input v-model="form.type" placeholder="请输入采集类型" /> |
| | | <el-select v-model="form.type" placeholder="请选择采集类型" > |
| | | <el-option |
| | | v-for="dict in dict.type.collection_type" |
| | | :key="dict.value" |
| | | :label="dict.label" |
| | | :value="dict.value" |
| | | /> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="是否订阅" prop="subscribe"> |
| | | <el-radio-group v-model="form.subscribe"> |
| | |
| | | |
| | | export default { |
| | | name: "OpcConf", |
| | | dicts: ['sys_yes_no'], |
| | | dicts: ['sys_yes_no','collection_type'], |
| | | data() { |
| | | return { |
| | | advancedSearchVisible: false, |
| | |
| | | locationName: [ |
| | | { required: true, message: "工位名称不能为空", trigger: "blur" }, |
| | | ], |
| | | subscribe: [ |
| | | { required: true, message: "订阅不能为空", trigger: "blur" }, |
| | | ], |
| | | node: [ |
| | | { required: true, message: "地址不能为空", trigger: "blur" }, |
| | | { pattern: /^[a-zA-Z0-9]*$/, message: "地址不能包含中文字符", trigger: "blur" } |
| | | ], |
| | | } |
| | | }; |