Commit 3ec57629 authored by lei's avatar lei

权重修改

parent b495d97a
...@@ -2,13 +2,9 @@ ...@@ -2,13 +2,9 @@
<template> <template>
<div class="datamanage-wrapper"> <div class="datamanage-wrapper">
<div class="search-wrapper"> <div class="search-wrapper">
<el-button <el-button size="mini" type="primary" icon="el-icon-circle-plus" class="addbtn" @click="addDialogData()"
size="mini" >新增</el-button
type="primary" >
icon="el-icon-circle-plus"
class="addbtn"
@click="addDialogData()"
>新增</el-button>
</div> </div>
<div class="table-wrapper"> <div class="table-wrapper">
<div class="infoline">信息分类列表</div> <div class="infoline">信息分类列表</div>
...@@ -26,24 +22,13 @@ ...@@ -26,24 +22,13 @@
<el-table-column type="index" label="序号" style="width: 100px" /> <el-table-column type="index" label="序号" style="width: 100px" />
<el-table-column label="操作" fixed="right"> <el-table-column label="操作" fixed="right">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button size="mini" type="primary" icon="el-icon-edit" @click="typeEdit($event, scope.$index, scope.row)"
size="mini" >编辑</el-button
type="primary" >
icon="el-icon-edit" <el-button size="mini" type="danger" icon="el-icon-delete" @click="typeDelete(scope.row)">删除</el-button>
@click="typeEdit($event, scope.$index, scope.row)" <el-button size="mini" type="primary" icon="el-icon-zoom-in" @click="lookClassButton(scope.row)"
>编辑</el-button> >查看</el-button
<el-button >
size="mini"
type="danger"
icon="el-icon-delete"
@click="typeDelete(scope.row)"
>删除</el-button>
<el-button
size="mini"
type="primary"
icon="el-icon-zoom-in"
@click="lookClassButton(scope.row)"
>查看</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
...@@ -51,26 +36,11 @@ ...@@ -51,26 +36,11 @@
<el-dialog title="新增分类名称" :visible.sync="typeManage.addDialog"> <el-dialog title="新增分类名称" :visible.sync="typeManage.addDialog">
<el-form ref="addDataForm" :model="typeManage.from" :rules="formrules"> <el-form ref="addDataForm" :model="typeManage.from" :rules="formrules">
<el-form-item prop="addname" label="分类名称:" :label-width="'120px'"> <el-form-item prop="addname" label="分类名称:" :label-width="'120px'">
<el-input <el-input v-model="typeManage.from.addname" clearable style="width: 220px" placeholder="请输入类别" />
v-model="typeManage.from.addname"
clearable
style="width: 220px"
placeholder="请输入类别"
/>
</el-form-item> </el-form-item>
<el-form-item prop="test" label="推送信息:" :label-width="'120px'"> <el-form-item prop="test" label="推送信息:" :label-width="'120px'">
<el-select <el-select v-model="typeManage.from.test" multiple placeholder="请选择" style="width: 220px">
v-model="typeManage.from.test" <el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value" />
multiple
placeholder="请选择"
style="width: 220px"
>
<el-option
v-for="item in options"
:key="item.value"
:label="item.label"
:value="item.value"
/>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item prop="id" label="添加到:" :label-width="'120px'"> <el-form-item prop="id" label="添加到:" :label-width="'120px'">
...@@ -84,11 +54,7 @@ ...@@ -84,11 +54,7 @@
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer"> <div slot="footer">
<el-button <el-button type="primary" :loading="typeManage.flag === 0" @click="determine">确定</el-button>
type="primary"
:loading="typeManage.flag === 0"
@click="determine"
>确定</el-button>
</div> </div>
</el-dialog> </el-dialog>
<el-dialog title="编辑分类名称" :visible.sync="typeManage.editDialog"> <el-dialog title="编辑分类名称" :visible.sync="typeManage.editDialog">
...@@ -109,12 +75,7 @@ ...@@ -109,12 +75,7 @@
style="width: 220px; margin-left: 20px" style="width: 220px; margin-left: 20px"
@change="selectChange" @change="selectChange"
> >
<el-option <el-option v-for="item in newoptions" :key="item.value" :label="item.label" :value="item.value" />
v-for="item in newoptions"
:key="item.value"
:label="item.label"
:value="item.value"
/>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item prop="pid" label="添加到:" :label-width="'120px'"> <el-form-item prop="pid" label="添加到:" :label-width="'120px'">
...@@ -128,37 +89,17 @@ ...@@ -128,37 +89,17 @@
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer"> <div slot="footer">
<el-button <el-button type="primary" icon="el-icon-success" :loading="editFormInfo.flag === 0" @click="uploadAddForm"
type="primary" >确定</el-button
icon="el-icon-success" >
:loading="editFormInfo.flag === 0"
@click="uploadAddForm"
>确定</el-button>
</div> </div>
</el-dialog> </el-dialog>
<el-dialog <el-dialog title="查看信息分类人员信息" :visible.sync="lookClassData.dialogOff">
title="查看信息分类人员信息"
:visible.sync="lookClassData.dialogOff"
>
<!--表格渲染--> <!--表格渲染-->
<el-table ref="table" :data="lookClassData.tableData" style="width: 100%"> <el-table ref="table" :data="lookClassData.tableData" style="width: 100%">
<el-table-column <el-table-column :show-overflow-tooltip="true" prop="username" label="用户名" />
:show-overflow-tooltip="true" <el-table-column :show-overflow-tooltip="true" prop="phone" width="100" label="电话" />
prop="username" <el-table-column :show-overflow-tooltip="true" width="135" prop="email" label="邮箱" />
label="用户名"
/>
<el-table-column
:show-overflow-tooltip="true"
prop="phone"
width="100"
label="电话"
/>
<el-table-column
:show-overflow-tooltip="true"
width="135"
prop="email"
label="邮箱"
/>
<el-table-column :show-overflow-tooltip="true" prop="name" label="部门"> <el-table-column :show-overflow-tooltip="true" prop="name" label="部门">
<template slot-scope="scope"> <template slot-scope="scope">
<div>{{ scope.row.name }}</div> <div>{{ scope.row.name }}</div>
...@@ -194,12 +135,17 @@ ...@@ -194,12 +135,17 @@
> >
信息权重 信息权重
</el-button> --> </el-button> -->
信息权重
<el-input-number <el-input-number
v-model="scope.row.value" v-model="scope.row.value"
small small
step-strictly step-strictly
:disabled=" controls-position="right"
:min="1"
:max="3"
@change="lookClassDataInputChange(scope.row)"
/>
</template>
<!-- :disabled="
scope.row.name != '销售三中心' && scope.row.name != '销售三中心' &&
scope.row.name != '销售五中心' && scope.row.name != '销售五中心' &&
scope.row.name != '销售一中心' && scope.row.name != '销售一中心' &&
...@@ -210,13 +156,7 @@ ...@@ -210,13 +156,7 @@
scope.row.name != '销售二部' && scope.row.name != '销售二部' &&
scope.row.name != '外贸部' && scope.row.name != '外贸部' &&
scope.row.name != '副总经理' scope.row.name != '副总经理'
" " -->
controls-position="right"
:min="1"
:max="3"
@change="lookClassDataInputChange(scope.row)"
/>
</template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<el-pagination <el-pagination
...@@ -231,7 +171,8 @@ ...@@ -231,7 +171,8 @@
icon="el-icon-success" icon="el-icon-success"
:loading="editFormInfo.flag === 0" :loading="editFormInfo.flag === 0"
@click="lookClassData.dialogOff = !lookClassData.dialogOff" @click="lookClassData.dialogOff = !lookClassData.dialogOff"
>确定</el-button> >确定</el-button
>
</div> </div>
</el-dialog> </el-dialog>
</div> </div>
...@@ -327,15 +268,11 @@ export default { ...@@ -327,15 +268,11 @@ export default {
// 验证 // 验证
formrules: { formrules: {
addname: [{ required: true, message: '请输入类别', trigger: 'blur' }], addname: [{ required: true, message: '请输入类别', trigger: 'blur' }],
test: [ test: [{ required: true, message: '请选择推送信息', trigger: 'change' }]
{ required: true, message: '请选择推送信息', trigger: 'change' }
]
}, },
rules: { rules: {
type: [{ required: true, message: '请输入类别', trigger: 'blur' }], type: [{ required: true, message: '请输入类别', trigger: 'blur' }],
choose: [ choose: [{ required: true, message: '请选择推送信息', trigger: 'change' }]
{ required: true, message: '请选择推送信息', trigger: 'change' }
]
}, },
infoTree: { infoTree: {
menus: [{ id: 0, label: '信息分类', children: null, pid: -1 }] menus: [{ id: 0, label: '信息分类', children: null, pid: -1 }]
...@@ -361,14 +298,12 @@ export default { ...@@ -361,14 +298,12 @@ export default {
}, },
methods: { methods: {
// 构建 Tree列表 // 构建 Tree列表
reqBuildTreeList: function() { reqBuildTreeList: function () {
var that = this var that = this
reqAllInfoTreeList().then(function(res) { reqAllInfoTreeList().then(function (res) {
if (res.code === 200) { if (res.code === 200) {
var list = res.object.records || [] var list = res.object.records || []
that.infoTree.menus = [ that.infoTree.menus = [{ id: 0, label: '信息分类', children: null, pid: -1 }]
{ id: 0, label: '信息分类', children: null, pid: -1 }
]
list.push(that.infoTree.menus[0]) list.push(that.infoTree.menus[0])
qf.Utils.treeListBuild(list) qf.Utils.treeListBuild(list)
} }
...@@ -455,7 +390,7 @@ export default { ...@@ -455,7 +390,7 @@ export default {
(res) => { (res) => {
this.typeManage.addDialog = false this.typeManage.addDialog = false
this.classification() this.classification()
setTimeout(function() { setTimeout(function () {
self.typeManage.flag = 1 self.typeManage.flag = 1
}, 300) }, 300)
self.$message({ self.$message({
...@@ -505,7 +440,7 @@ export default { ...@@ -505,7 +440,7 @@ export default {
this.CacheItem.label = params.name this.CacheItem.label = params.name
this.CacheItem.pushnew = params.pushNew this.CacheItem.pushnew = params.pushNew
setTimeout(function() { setTimeout(function () {
self.editFormInfo.flag = 1 self.editFormInfo.flag = 1
}, 300) }, 300)
// 重新构建列表 // 重新构建列表
......
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment