!441 fix: id=0导致sqlserver的insert失败

Merge pull request !441 from dhb52/dev
This commit is contained in:
芋道源码 2024-05-07 01:10:01 +00:00 committed by Gitee
commit e8e1467f27
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
14 changed files with 24 additions and 24 deletions

View File

@ -141,7 +141,7 @@ export const getExpressTrackList = async (id: number | null) => {
}
export interface DeliveryVO {
id: number // 订单编号
id?: number // 订单编号
logisticsId: number | null // 物流公司编号
logisticsNo: string // 物流编号
}

View File

@ -100,7 +100,7 @@ const dialogTitle = ref('') // 弹窗的标题
const formLoading = ref(false) // 12
const formType = ref('') // create - update -
const formData = ref({
id: 0,
id: undefined,
name: '',
deptIds: [],
statuses: []
@ -168,7 +168,7 @@ const submitForm = async () => {
const resetForm = () => {
checkStrictly.value = true
formData.value = {
id: 0,
id: undefined,
name: '',
deptIds: [],
statuses: []

View File

@ -138,7 +138,7 @@ const resetForm = () => {
const getProductCategoryTree = async () => {
productCategoryTree.value = []
const data = await ProductCategoryApi.getProductCategoryList()
const root: Tree = { id: 0, name: '顶级产品分类', children: [] }
const root: Tree = { id: undefined, name: '顶级产品分类', children: [] }
root.children = handleTree(data, 'id', 'parentId')
productCategoryTree.value.push(root)
}

View File

@ -107,7 +107,7 @@ const resetForm = () => {
const getDemo02CategoryTree = async () => {
demo02CategoryTree.value = []
const data = await Demo02CategoryApi.getDemo02CategoryList()
const root: Tree = { id: 0, name: '顶级示例分类', children: [] }
const root: Tree = { id: undefined, name: '顶级示例分类', children: [] }
root.children = handleTree(data, 'id', 'parentId')
demo02CategoryTree.value.push(root)
}

View File

@ -27,7 +27,7 @@ const message = useMessage() // 消息弹窗
const dialogVisible = ref(false) //
const formLoading = ref(false) // 12
const formData = ref({
id: 0, //
id: undefined, //
auditReason: '' //
})
const formRef = ref() // Ref
@ -62,7 +62,7 @@ const submitForm = async () => {
/** 重置表单 */
const resetForm = () => {
formData.value = {
id: 0, //
id: undefined, //
auditReason: '' //
}
formRef.value?.resetFields()

View File

@ -103,7 +103,7 @@ const submitForm = async () => {
/** 重置表单 */
const resetForm = () => {
formData.value = {
id: 0,
id: undefined,
bindUserId: undefined
}
formRef.value?.resetFields()

View File

@ -43,7 +43,7 @@ const dialogVisible = ref(false) // 弹窗的是否展示
const formLoading = ref(false) // 12
const expressType = ref('express') // expressnone
const formData = ref<TradeOrderApi.DeliveryVO>({
id: 0, //
id: undefined, //
logisticsId: null, //
logisticsNo: '' //
})
@ -86,7 +86,7 @@ const submitForm = async () => {
/** 重置表单 */
const resetForm = () => {
formData.value = {
id: 0, //
id: undefined, //
logisticsId: null, //
logisticsNo: '' //
}

View File

@ -44,7 +44,7 @@ const message = useMessage() // 消息弹窗
const dialogVisible = ref(false) //
const formLoading = ref(false) // 12
const formData = ref({
id: 0, //
id: undefined, //
receiverName: '', //
receiverMobile: '', //
receiverAreaId: null, //
@ -82,7 +82,7 @@ const submitForm = async () => {
/** 重置表单 */
const resetForm = () => {
formData.value = {
id: 0, //
id: undefined, //
receiverName: '', //
receiverMobile: '', //
receiverAreaId: null, //

View File

@ -31,7 +31,7 @@ const message = useMessage() // 消息弹窗
const dialogVisible = ref(false) //
const formLoading = ref(false) // 12
const formData = ref({
id: 0, //
id: undefined, //
adjustPrice: 0, //
payPrice: '', // ()
newPayPrice: '' // ()
@ -85,7 +85,7 @@ const submitForm = async () => {
/** 重置表单 */
const resetForm = () => {
formData.value = {
id: 0, //
id: undefined, //
adjustPrice: 0, //
payPrice: '', // ()
newPayPrice: '' // ()

View File

@ -27,7 +27,7 @@ const message = useMessage() // 消息弹窗
const dialogVisible = ref(false) //
const formLoading = ref(false) // 12
const formData = ref({
id: 0, //
id: undefined, //
remark: '' //
})
const formRef = ref() // Ref
@ -62,7 +62,7 @@ const submitForm = async () => {
/** 重置表单 */
const resetForm = () => {
formData.value = {
id: 0, //
id: undefined, //
remark: '' //
}
formRef.value?.resetFields()

View File

@ -167,7 +167,7 @@ const resetForm = () => {
const getTree = async () => {
deptTree.value = []
const data = await DeptApi.getSimpleDeptList()
let dept: Tree = { id: 0, name: '顶级部门', children: [] }
let dept: Tree = { id: undefined, name: '顶级部门', children: [] }
dept.children = handleTree(data)
deptTree.value.push(dept)
}

View File

@ -130,7 +130,7 @@ const dialogTitle = ref('') // 弹窗的标题
const formLoading = ref(false) // 12
const formType = ref('') // create - update -
const formData = ref({
id: 0,
id: undefined,
name: '',
permission: '',
type: SystemMenuTypeEnum.DIR,
@ -223,7 +223,7 @@ const menuTree = ref<Tree[]>([]) // 树形结构
const getTree = async () => {
menuTree.value = []
const res = await MenuApi.getSimpleMenusList()
let menu: Tree = { id: 0, name: '主类目', children: [] }
let menu: Tree = { id: undefined, name: '主类目', children: [] }
menu.children = handleTree(res)
menuTree.value.push(menu)
}
@ -231,7 +231,7 @@ const getTree = async () => {
/** 重置表单 */
const resetForm = () => {
formData.value = {
id: 0,
id: undefined,
name: '',
permission: '',
type: SystemMenuTypeEnum.DIR,

View File

@ -58,7 +58,7 @@ const message = useMessage() // 消息弹窗
const dialogVisible = ref(false) //
const formLoading = ref(false) // 12
const formData = reactive({
id: 0,
id: undefined,
name: '',
code: '',
menuIds: []
@ -126,7 +126,7 @@ const resetForm = () => {
menuExpand.value = false
//
formData.value = {
id: 0,
id: undefined,
name: '',
code: '',
menuIds: []

View File

@ -78,7 +78,7 @@ const message = useMessage() // 消息弹窗
const dialogVisible = ref(false) //
const formLoading = ref(false) // 12
const formData = reactive({
id: 0,
id: undefined,
name: '',
code: '',
dataScope: undefined,
@ -141,7 +141,7 @@ const resetForm = () => {
checkStrictly.value = true
//
formData.value = {
id: 0,
id: undefined,
name: '',
code: '',
dataScope: undefined,