master
赵玉瑞 2 years ago
parent 4235c0a781
commit da4e304e70
  1. 85
      ant-design-vue-jeecg/src/views/modulex/ModulexList.vue
  2. 1
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/demo/functionx/controller/FunctionxController.java

@ -50,46 +50,58 @@
class="j-table-force-nowrap"
@change="handleTableChange">
<!-- 管理 公用部分-->
<span slot="htmlSlot" slot-scope="text, record">
<!-- <div v-html="text"></div>-->
<a @click="functionManage(record)">功能</a>
<a-divider type="vertical"/>
<a @click="tablexManage(record)">实体</a>
</span>
<span slot="action" slot-scope="text, record">
<a @click="fuzhiProject(record)">复制</a>
<!--功能 管理员-->
<span slot="actionManage" slot-scope="text, record" v-if="userRole1 === '1'">
<a @click="chehui(record)">撤回</a>
<a-divider type="vertical"/>
<a @click="bugfankui(record)">BUG反馈</a>
<a-divider type="vertical"/>
<a @click="shenhe(record)">审核</a>
</span>
<!--功能 开发者-->
<!--这里只能用v-else-if / v-else v-if -->
<span slot="actionManage" slot-scope="text, record" v-else>
<a @click="fabu(record)">发布</a>
<a-divider type="vertical"/>
<a @click="kaishi(record)">开始</a>
<a @click="kaishi(record)">开始</a>
<a-divider type="vertical"/>
<a @click="tijiao(record)">提交</a>
</span>
<a-divider type="vertical"/>
<a @click="chehui(record)">撤回</a>
<a-divider type="vertical"/>
<a @click="bugfankui(record)">BUG反馈</a>
<a-divider type="vertical"/>
<a @click="shenhe(record)">审核</a>
<!--操作 -->
<span slot="action1" slot-scope="text, record" >
<a @click="fuzhiProject(record)">复制</a>
<a-divider type="vertical"/>
<a @click="handleEdit(record)">编辑</a>
<a @click="handleEdit(record)">编辑</a>
<a-divider type="vertical"/>
<a @click="handleDetail(record)">详情</a>
<a @click="handleDetail(record)">详情</a>
<a-divider type="vertical"/>
<a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
<a>删除</a>
</a-popconfirm>
</span>
</a-table>
@ -110,6 +122,7 @@ import ModulexModal from './modules/ModulexModal'
import {getAction} from "@api/manage";
import BugxModal from "@views/modulex/modules/BugxModal";
import store from "@/store";
export default {
name: 'ModulexList',
@ -242,26 +255,40 @@ export default {
align: "center",
dataIndex: 'verisonStatus_dictText'
},
// {
// title:'',
// align:"center",
// dataIndex: 'verison'
// },
// {
// title: '',
// align: "center",
// dataIndex: 'createTime'
// },
{
title: '管理',
dataIndex: 'htmlSlot',
align: "center",
fixed: "right",
// width: 147,
width:98,
scopedSlots: {customRender: 'htmlSlot'}
},
// {
// title:'',
// align:"center",
// dataIndex: 'verison'
// },
{
title: '功能',
dataIndex: 'actionManage',
align: "center",
fixed: "right",
width:147,
scopedSlots: {customRender: 'actionManage'}
},
{
title: '操作',
dataIndex: 'action',
dataIndex: 'action1',
align: "center",
fixed: "right",
// width: 147,
scopedSlots: {customRender: 'action'}
width:147,
scopedSlots: {customRender: 'action1'}
}
],
url: {
@ -274,9 +301,14 @@ export default {
},
dictOptions: {},
superFieldList: [],
userRole1: '', //1 2
}
},
created() {
let usercode = store.getters.userInfo.id
//id
this.loginRole(usercode)
//console.log('userole1',this.userRole1)
this.getSuperFieldList();
},
computed: {
@ -285,6 +317,15 @@ export default {
},
},
methods: {
loginRole(id){
getAction('functionx/functionx/loginrole',{id:id}).then((res)=>{
if (res.success) {
//
this.userRole1 = res.result;
//console.log('this.userRole1',this.userRole1)
}
})
},
shenhe(record) {
getAction('/modulex/modulex/shenhe', {id: record.id}).then((res) => {
if (res.success) {

@ -206,6 +206,7 @@ public class FunctionxController extends JeecgController<Functionx, IFunctionxSe
@GetMapping(value = "/loginrole")
public Result<?> loginrole(@RequestParam(name="id",required=true) String id) {
List<String> list=functionxService.findRole(id);
//如果角色是项目管理员或管理员 就返回1 其他的返回 2
if(list.contains("1645284981182980098")||list.contains("f6817f48af4fb3af11b9e8bf182f618b"))//是项目负责人,管理员也可以
return Result.OK("1");
else

Loading…
Cancel
Save