diff --git a/src/views/xm/core/xmMenu/XmMenuEdit.vue b/src/views/xm/core/xmMenu/XmMenuEdit.vue
index 791ae58f..5e8fc7d6 100644
--- a/src/views/xm/core/xmMenu/XmMenuEdit.vue
+++ b/src/views/xm/core/xmMenu/XmMenuEdit.vue
@@ -50,25 +50,29 @@
-
+
+
+ 取消
+ 提交
+
+
+
+
+
-
- 取消
- 提交
-
-
+
-
+
@@ -79,6 +83,7 @@
import { mapGetters } from 'vuex'
import UsersSelect from "@/views/mdp/sys/user/UsersSelect";
import XmMenuOverview from './XmMenuOverview.vue';
+import XmMenuExchangeMng from '../xmMenuExchange/XmMenuExchangeMng.vue';
import TagMng from "@/views/mdp/arc/tag/TagMng";
@@ -209,6 +214,7 @@ import XmMenuOverview from './XmMenuOverview.vue';
UsersSelect,
XmMenuOverview,
TagMng,
+ XmMenuExchangeMng,
},
mounted() {
this.editForm=Object.assign(this.editForm, this.xmMenu);
diff --git a/src/views/xm/core/xmMenu/XmMenuMng.vue b/src/views/xm/core/xmMenu/XmMenuMng.vue
index df80aeda..aab642a2 100644
--- a/src/views/xm/core/xmMenu/XmMenuMng.vue
+++ b/src/views/xm/core/xmMenu/XmMenuMng.vue
@@ -921,8 +921,7 @@
if(this.xmProduct && this.xmProduct.id){
this.productVisible=false;
}
- this.$nextTick(() => {
- debugger;
+ this.$nextTick(() => {
this.maxTableHeight = util.calcTableMaxHeight(this.$refs.table.$el);
this.getXmMenus();
});
diff --git a/src/views/xm/core/xmMenuExchange/MenuUserEditor.vue b/src/views/xm/core/xmMenuExchange/MenuUserEditor.vue
index ce51f641..d311e85b 100644
--- a/src/views/xm/core/xmMenuExchange/MenuUserEditor.vue
+++ b/src/views/xm/core/xmMenuExchange/MenuUserEditor.vue
@@ -9,7 +9,7 @@
- 发布 清空内容
+ 发布 清空内容 关闭窗口
@@ -32,18 +32,18 @@ export default {
}
},
methods: {
- publish() {
- let params = {
- content: this.content,
- }
+ publish() {
if(!this.content){
this.$notify.error("请输入内容再提交");
return;
}
- this.$emit('publish',params);
+ this.$emit('publish',this.content);
},
clearContent(){
this.content="";
+ },
+ close(){
+ this.$emit("close")
}
},
mounted() {
diff --git a/src/views/xm/core/xmMenuExchange/XmMenuExchangeMng.vue b/src/views/xm/core/xmMenuExchange/XmMenuExchangeMng.vue
index c27a7737..f06651f6 100644
--- a/src/views/xm/core/xmMenuExchange/XmMenuExchangeMng.vue
+++ b/src/views/xm/core/xmMenuExchange/XmMenuExchangeMng.vue
@@ -1,31 +1,27 @@
-
-
+
+
+
+ 查询
+ 发表需求建议
+
+
-
-
-
+
+
@@ -50,6 +48,8 @@
import MenuUserEditor from './MenuUserEditor'
import { mapGetters } from 'vuex'
import {sn} from '@/common/js/sequence';
+
+ import VueEditor from '@/components/Tinymce/index';
export default {
computed: {
@@ -69,6 +69,7 @@
filters: {
key: '',
xmMenu:null,
+ menuId:''
},
xmMenuExchanges: [],//查询结果
pageInfo:{//分页数据
@@ -90,14 +91,18 @@
addForm: {
menuId:'',menuName:'',productId:'',remark:'',id:'',pid:'',cuserid:'',cusername:'',ctime:'',cbranchId:'',adopt:'',adoptUserid:'',adoptUsername:'',adoptTime:'',closed:'',puserid:'',pusername:'',premark:'',notifyUserids:'',notifyChannels:'',notifyUsernames:'',cuserHeadImg:'',replyType:''
},
-
+ addFormInit: {
+ menuId:'',menuName:'',productId:'',remark:'',id:'',pid:'',cuserid:'',cusername:'',ctime:'',cbranchId:'',adopt:'',adoptUserid:'',adoptUsername:'',adoptTime:'',closed:'',puserid:'',pusername:'',premark:'',notifyUserids:'',notifyChannels:'',notifyUsernames:'',cuserHeadImg:'',replyType:''
+ },
editFormVisible: false,//编辑界面是否显示
//编辑xmMenuExchange界面初始化数据
editForm: {
menuId:'',menuName:'',productId:'',remark:'',id:'',pid:'',cuserid:'',cusername:'',ctime:'',cbranchId:'',adopt:'',adoptUserid:'',adoptUsername:'',adoptTime:'',closed:'',puserid:'',pusername:'',premark:'',notifyUserids:'',notifyChannels:'',notifyUsernames:'',cuserHeadImg:'',replyType:''
},
xmMenuVisible:false,
- tableHeight:300,
+ maxTableHeight:300,
+ content:'',
+ headEditorVisible:false,
/**begin 自定义属性请在下面加 请加备注**/
/**end 自定义属性请在上面加 请加备注**/
@@ -146,7 +151,7 @@
params.orderBy= orderBys.join(",")
}
if(this.filters.key!==""){
- //params.xxx=this.filters.key
+ params.key=this.filters.key
}else{
//params.xxx=xxxxx
}
@@ -159,6 +164,9 @@
}
}
+ if(this.filters.menuId){
+ params.menuId=this.filters.menuId
+ }
if(!params.menuId){
params.branchId=this.userInfo.branchId
}
@@ -168,7 +176,9 @@
if(tips.isOk){
this.pageInfo.total = res.data.total;
this.pageInfo.count=false;
- this.xmMenuExchanges = res.data.data;
+ var data=res.data.data;
+ data.forEach(i=>i.showEditor=false)
+ this.xmMenuExchanges = data;
}else{
this.$notify({showClose: true, message: tips.msg, type: 'error' });
}
@@ -238,18 +248,26 @@
this.$emit('row-click',row, event, column);// @row-click="rowClick"
},
/**begin 自定义函数请在下面加**/
-
- onPublishContent:function(editor,parentXmMenuExchange){
+ showEditor(item,replyType){
+ this.editForm=item;
- var params={};
- params.remark=editor.content;
-
- if(!parentXmMenuExchange && !this.xmMenu && !this.filters.xmMenu){
- this.$notify.error("请选择需求再发表评论")
- return;
- }
- params.id=sn()
- if(this.xmMenu){
+ this.addForm={...this.addFOrmInit}
+ this.addForm.replyType=replyType;
+ item.showEditor=true;
+ },
+ onPublishContent:function(content,item){
+ debugger;
+ var params={...this.addForm}
+ params.remark=content;
+ if(item){
+ params.puserid=item.cuserid
+ params.premark=item.remark
+ params.pusername=item.cusername
+ params.productId=item.productId
+ params.menuId=item.menuId
+ params.menuName=item.menuName
+ params.pid=item.id
+ }else if(this.xmMenu){
params.menuId=this.xmMenu.menuId
params.productId=this.xmMenu.productId
params.menuName=this.xmMenu.menuName
@@ -260,28 +278,24 @@
params.menuName=this.filters.xmMenu.menuName
}else{
- params.menuId=parentXmMenuExchange.menuId
- params.productId=parentXmMenuExchange.productId
- params.menuName=parentXmMenuExchange.menuName
+ params.menuId=item.menuId
+ params.productId=item.productId
+ params.menuName=item.menuName
}
- }
-
-
+ }
params.cuserid=this.userInfo.userid
params.cusername=this.userInfo.username
params.cbranchId=this.userInfo.branchId
- params.cuserHeadImg=this.userInfo.headimgurl
- if(parentXmMenuExchange){
- params.pid=parentXmMenuExchange.id
- params.premark=parentXmMenuExchange.remark
- params.puserid=parentXmMenuExchange.cuserid
- params.pusername=parentXmMenuExchange.cusername
- }
+ params.cuserHeadImg=this.userInfo.headimgurl
addXmMenuExchange(params).then(res=>{
var tips =res.data.tips;
if(tips.isOk){
- this.xmMenuExchanges.unshift(res.data.data);
+ var data=res.data.data;
+ data.showEditor=false;
+ this.xmMenuExchanges.unshift(data);
+ this.editForm.showEditor=false;
+ this.headEditorVisible=false;
}
this.$notify({showClose: true, message: tips.msg, type: tips.isOk?'success':'error'});
})
@@ -299,10 +313,12 @@
},//end methods
components: {
//在下面添加其它组件
- MenuUserEditor
+ MenuUserEditor,VueEditor
},
mounted() {
this.$nextTick(() => {
+
+ this.maxTableHeight = util.calcTableMaxHeight(this.$refs.table.$el);
this.filters.xmMenu=this.xmMenu
this.getXmMenuExchanges();
});
diff --git a/src/views/xm/core/xmMenuExchange/XmMenuExchangeRoute.vue b/src/views/xm/core/xmMenuExchange/XmMenuExchangeRoute.vue
new file mode 100644
index 00000000..8bbf6577
--- /dev/null
+++ b/src/views/xm/core/xmMenuExchange/XmMenuExchangeRoute.vue
@@ -0,0 +1,44 @@
+
+
+
+
+
+
+
\ No newline at end of file