Browse Source

多选

master
gengby 2 years ago
parent
commit
3184564486
  1. 43
      acs/nladmin-ui/src/views/acs/route/routeLine/index.vue

43
acs/nladmin-ui/src/views/acs/route/routeLine/index.vue

@ -41,7 +41,7 @@
@keyup.enter.native="crud.toQuery" @keyup.enter.native="crud.toQuery"
/> />
</el-col> </el-col>
<rrOperation/> <rrOperation />
</el-row> </el-row>
</div> </div>
<!--如果想在工具栏加入更多按钮可以使用插槽方式 slot = 'left' or 'right'--> <!--如果想在工具栏加入更多按钮可以使用插槽方式 slot = 'left' or 'right'-->
@ -67,7 +67,7 @@
> >
<el-form ref="form" :model="form" :rules="rules" size="small" label-width="120px"> <el-form ref="form" :model="form" :rules="rules" size="small" label-width="120px">
<el-form-item v-if="false" label="路线标识" prop="line_uuid"> <el-form-item v-if="false" label="路线标识" prop="line_uuid">
<el-input v-model="form.line_uuid" style="width: 370px;"/> <el-input v-model="form.line_uuid" style="width: 370px;" />
</el-form-item> </el-form-item>
<el-form-item label="路由方案" prop="route_plan_id"> <el-form-item label="路由方案" prop="route_plan_id">
@ -87,15 +87,15 @@
<el-form-item label="当前设备名称" prop="device_code"> <el-form-item label="当前设备名称" prop="device_code">
<el-select <el-select
ref="test"
v-model="form.device_code" v-model="form.device_code"
filterable filterable
ref="test"
clearable clearable
multiple multiple
reserveKeyword reserve-keyword
@change="change"
placeholder="请选择" placeholder="请选择"
style="width: 370px;" style="width: 370px;"
@change="change"
> >
<el-option <el-option
v-for="item in deviceList" v-for="item in deviceList"
@ -111,7 +111,7 @@
v-model="form.next_device_code" v-model="form.next_device_code"
filterable filterable
clearable clearable
reserveKeyword reserve-keyword
multiple multiple
placeholder="请选择" placeholder="请选择"
style="width: 370px;" style="width: 370px;"
@ -140,10 +140,10 @@
</el-form-item> </el-form-item>
<el-form-item label="权值" prop="weights"> <el-form-item label="权值" prop="weights">
<el-input-number v-model="form.weights" :min="1" :max="10" label="描述文字"/> <el-input-number v-model="form.weights" :min="1" :max="10" label="描述文字" />
</el-form-item> </el-form-item>
<el-form-item label="描述信息" prop="description"> <el-form-item label="描述信息" prop="description">
<el-input v-model="form.remark" style="width: 370px;" rows="5" type="textarea"/> <el-input v-model="form.remark" style="width: 370px;" rows="5" type="textarea" />
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
@ -161,20 +161,20 @@
style="width: 100%;" style="width: 100%;"
@selection-change="crud.selectionChangeHandler" @selection-change="crud.selectionChangeHandler"
> >
<el-table-column type="selection" width="55"/> <el-table-column type="selection" width="55" />
<el-table-column v-if="false" prop="line_uuid" label="路线标识"/> <el-table-column v-if="false" prop="line_uuid" label="路线标识" />
<el-table-column prop="device_code" label="设备编码"/> <el-table-column prop="device_code" label="设备编码" />
<el-table-column v-if="false" prop="device_code" label="设备名称"/> <el-table-column v-if="false" prop="device_code" label="设备名称" />
<el-table-column prop="type" label="路由类型"> <el-table-column prop="type" label="路由类型">
<template slot-scope="scope"> <template slot-scope="scope">
<span v-if="scope.row.type=='0' ">输送路由</span> <span v-if="scope.row.type=='0' ">输送路由</span>
<span v-if="scope.row.type=='1' ">agv路由</span> <span v-if="scope.row.type=='1' ">agv路由</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="next_device_code" min-width="120" label="后置设备号"/> <el-table-column prop="next_device_code" min-width="120" label="后置设备号" />
<el-table-column v-if="false" prop="next_device_code" min-width="120" label="后置设备名称"/> <el-table-column v-if="false" prop="next_device_code" min-width="120" label="后置设备名称" />
<el-table-column v-if="false" prop="next_device_code" min-width="120" label="后置设备类型"/> <el-table-column v-if="false" prop="next_device_code" min-width="120" label="后置设备类型" />
<el-table-column prop="weights" label="权值"/> <el-table-column prop="weights" label="权值" />
<el-table-column label="是否启用" align="center" prop="is_active"> <el-table-column label="是否启用" align="center" prop="is_active">
<template slot-scope="scope"> <template slot-scope="scope">
@ -189,8 +189,8 @@
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="update_by" label="修改者"/> <el-table-column prop="update_by" label="修改者" />
<el-table-column prop="update_time" min-width="160" label="修改时间"/> <el-table-column prop="update_time" min-width="160" label="修改时间" />
<el-table-column <el-table-column
v-permission="['admin','routeLine:edit','routeLine:del']" v-permission="['admin','routeLine:edit','routeLine:del']"
label="操作" label="操作"
@ -207,7 +207,7 @@
</el-table-column> </el-table-column>
</el-table> </el-table>
<!--分页组件--> <!--分页组件-->
<pagination/> <pagination />
</div> </div>
</div> </div>
</template> </template>
@ -308,6 +308,11 @@ export default {
[CRUD.HOOK.beforeRefresh]() { [CRUD.HOOK.beforeRefresh]() {
return true return true
}, },
[CRUD.HOOK.beforeToEdit](data) {
this.form.device_code = Array.of(data.form.device_code.split('').join(''))
this.form.next_device_code = Array.of(data.form.next_device_code.split('').join(''))
return true
},
// //
changeEnabled(data) { changeEnabled(data) {
var msg = '停用' var msg = '停用'

Loading…
Cancel
Save