round完成
This commit is contained in:
@@ -29,6 +29,7 @@ import { reactive, ref, onMounted } from "vue"
|
||||
import MaTreeSlider from "@/components/ma-treeSlider/index.vue"
|
||||
import userApi from "@/api/system/user"
|
||||
import user from "@/api/system/user"
|
||||
import { Message } from "@arco-design/web-vue"
|
||||
// 切换状态按钮
|
||||
const changeStatus = (e, id) => {
|
||||
console.log("当前值:", e)
|
||||
@@ -183,9 +184,24 @@ const crudOptions = reactive({
|
||||
viewType: "modal"
|
||||
// isFull: true
|
||||
},
|
||||
// 用户点击编辑/删除前的hook
|
||||
beforeOpenEdit: (record) => {
|
||||
if (record.id === 1) {
|
||||
Message.error("创始人不可编辑,请关闭窗口!")
|
||||
return false
|
||||
}
|
||||
return true
|
||||
},
|
||||
beforeDelete: (ids) => {
|
||||
if (ids.includes(1)) {
|
||||
Message.error("创始人不可删除")
|
||||
return false
|
||||
}
|
||||
return true
|
||||
}
|
||||
})
|
||||
const crudColumns = reactive([
|
||||
{ title: "ID", dataIndex: "id", addDisplay: false, editDisplay: false, width: 50, hide: false, search: true },
|
||||
{ title: "ID", dataIndex: "id", addDisplay: false, editDisplay: false, width: 50, hide: false },
|
||||
{
|
||||
title: "名称",
|
||||
align: "center",
|
||||
@@ -235,7 +251,7 @@ const crudColumns = reactive([
|
||||
},
|
||||
{
|
||||
title: "注册时间",
|
||||
dataIndex: "created_at",
|
||||
dataIndex: "create_datetime",
|
||||
align: "center",
|
||||
width: 180,
|
||||
addDisplay: false,
|
||||
|
||||
@@ -100,9 +100,11 @@ const handleSubmit = async ({ values, errors }) => {
|
||||
await userStore.login(form)
|
||||
const { redirect, ...otherQuery } = router.currentRoute.value.query
|
||||
router.push({
|
||||
name: redirect || "Workplace"
|
||||
name: redirect || "Workplace",
|
||||
query:{
|
||||
...otherQuery // 将退出时的查询参数放入,这样就不会错误
|
||||
}
|
||||
})
|
||||
Message.success("登录成功,等待跳转")
|
||||
} catch (err) {
|
||||
errorMessage.value = err.message
|
||||
} finally {
|
||||
|
||||
@@ -26,18 +26,20 @@ const crudOptions = ref({
|
||||
showIndex: false,
|
||||
rowSelection: { showCheckedAll: true },
|
||||
add: { show: true },
|
||||
edit: { show: true },
|
||||
edit: { show: true, api: designDemandApi.editDesignDemand },
|
||||
delete: { show: true },
|
||||
searchColNumber: 3,
|
||||
tablePagination: true,
|
||||
operationColumn: true,
|
||||
operationColumnAlign:'center',
|
||||
formOption: {
|
||||
width: 1200
|
||||
width: 1200,
|
||||
}
|
||||
})
|
||||
const crudColumns = ref([
|
||||
{
|
||||
title: "ID",
|
||||
align:'center',
|
||||
width: 50,
|
||||
dataIndex: "id",
|
||||
search: true,
|
||||
@@ -46,6 +48,7 @@ const crudColumns = ref([
|
||||
},
|
||||
{
|
||||
title: "标识",
|
||||
align:'center',
|
||||
width: 120,
|
||||
dataIndex: "ident",
|
||||
search: true,
|
||||
@@ -54,6 +57,7 @@ const crudColumns = ref([
|
||||
},
|
||||
{
|
||||
title: "需求名称",
|
||||
align:'center',
|
||||
width: 150,
|
||||
dataIndex: "name",
|
||||
search: true,
|
||||
@@ -63,6 +67,7 @@ const crudColumns = ref([
|
||||
{
|
||||
title: "需求类型",
|
||||
width: 150,
|
||||
align:'center',
|
||||
dataIndex: "demandType",
|
||||
formType: "radio",
|
||||
search: true,
|
||||
@@ -73,6 +78,7 @@ const crudColumns = ref([
|
||||
{
|
||||
title: "需求描述",
|
||||
dataIndex: "description",
|
||||
hide:true,
|
||||
width: 300,
|
||||
formType: "editor",
|
||||
height: 300
|
||||
|
||||
@@ -23,9 +23,9 @@ const crudRef = ref()
|
||||
const crudOptions = ref({
|
||||
rowSelection: { showCheckedAll: true },
|
||||
api: projectApi.getPageList,
|
||||
add: { show: true },
|
||||
edit: { show: true },
|
||||
delete: { show: true },
|
||||
add: { show: true,api: projectApi.save},
|
||||
edit: { show: true,api: projectApi.update},
|
||||
delete: { show: true ,api:projectApi.delete},
|
||||
searchColNumber: 3,
|
||||
tablePagination: true,
|
||||
operationColumn: true,
|
||||
@@ -193,7 +193,7 @@ const crudColumns = ref([
|
||||
search: true,
|
||||
commonRules: [{ required: true, message: "责任人必选" }],
|
||||
formType: "select",
|
||||
dict: { url: "system/user/index", props: { label: "name", value: "name" }, translation: true }
|
||||
dict: { url: "system/user/list", props: { label: "name", value: "name" }, translation: true }
|
||||
},
|
||||
{
|
||||
title: "成员",
|
||||
@@ -202,7 +202,7 @@ const crudColumns = ref([
|
||||
search: true,
|
||||
formType: "select",
|
||||
multiple: true,
|
||||
dict: { url: "system/user/index", props: { label: "name", value: "name" }, translation: true },
|
||||
dict: { url: "system/user/list", props: { label: "name", value: "name" }, translation: true },
|
||||
commonRules: [{ required: true, message: "成员至少选择一个" }]
|
||||
},
|
||||
{
|
||||
@@ -213,7 +213,7 @@ const crudColumns = ref([
|
||||
commonRules: [{ required: true, message: "关键等级必填" }],
|
||||
search: true,
|
||||
formType: "radio",
|
||||
dict: { name: "security_level", props: { label: "value", value: "key" } }
|
||||
dict: { name: "security_level", props: { label: "title", value: "key" } }
|
||||
},
|
||||
{
|
||||
title: "测试级别",
|
||||
|
||||
Reference in New Issue
Block a user