Browse Source

固定资产问题和里程碑问题

master
ljlong_2630 7 months ago
parent
commit
ae92c93326
  1. 1
      src/api/eam/basic/inspection/index.ts
  2. 15
      src/components/Detail/src/DetailDeviceLedger.vue
  3. 5
      src/views/eam/basic/fixedAssets/index.vue

1
src/api/eam/basic/inspection/index.ts

@ -55,7 +55,6 @@ export const createDeviceMoldItems = async (data: DeviceMoldItemsVO) => {
} }
//新增模具 //新增模具
export const creatMoldItems = async (data: DeviceMoldItemsVO) => { export const creatMoldItems = async (data: DeviceMoldItemsVO) => {
debugger
data.type="MOLD" data.type="MOLD"
data.status="INSPECTION" data.status="INSPECTION"
return await request.post({ url: `/eam/device-mold-items/create`, data }) return await request.post({ url: `/eam/device-mold-items/create`, data })

15
src/components/Detail/src/DetailDeviceLedger.vue

@ -912,8 +912,8 @@ const setBeiJian = () => {
// - // -
const butttondata = (row) => { const butttondata = (row) => {
return [ return [
defaultButtons.mainListEditBtn({ hide: !hasmMilestoneRight(row)}), // defaultButtons.mainListEditBtn({ hasPermi: 'eam:mold-milestone:edit'}), //
defaultButtons.uploadFileBtn({ hide: !hasmMilestoneRight(row)}),// defaultButtons.uploadFileBtn({ hasPermi: 'eam:mold-milestone:upload'}),//
] ]
} }
@ -996,17 +996,6 @@ function dialogUploadFile() {
}) })
} }
const hasmMilestoneRight = (row) => {
const rolesOk = userStore.roles.find(item => {
return item == 'mold_Engineer_role'
})
if (rolesOk != undefined && rolesOk != null) {
return true
} else {
return false
}
}
</script> </script>
<style lang="scss"> <style lang="scss">
.el-drawer__body { .el-drawer__body {

5
src/views/eam/basic/fixedAssets/index.vue

@ -64,6 +64,7 @@ import download from '@/utils/download'
import { FixedAssets,FixedAssetsRules } from './fixedAssets.data' import { FixedAssets,FixedAssetsRules } from './fixedAssets.data'
import * as FixedAssetsApi from '@/api/eam/basic/fixedAssets' import * as FixedAssetsApi from '@/api/eam/basic/fixedAssets'
import * as defaultButtons from '@/utils/disposition/defaultButtons' import * as defaultButtons from '@/utils/disposition/defaultButtons'
import { checkPermi } from '@/utils/permission'
// import TableHead from '@/components/TableHead/src/TableHead.vue' // import TableHead from '@/components/TableHead/src/TableHead.vue'
// import ImportForm from '@/components/ImportForm/src/ImportForm.vue' // import ImportForm from '@/components/ImportForm/src/ImportForm.vue'
// import Detail from '@/components/Detail/src/Detail.vue' // import Detail from '@/components/Detail/src/Detail.vue'
@ -179,12 +180,16 @@ const formsSuccess = async (formType,data) => {
matchingRole = userStore.getUser.id matchingRole = userStore.getUser.id
} }
if (formType === 'create') { if (formType === 'create') {
if(!checkPermi(['gdzc_admin'])){
data.manageDept = matchingRole data.manageDept = matchingRole
}
await FixedAssetsApi.createFixedAssets(data) await FixedAssetsApi.createFixedAssets(data)
message.success(t('common.createSuccess')) message.success(t('common.createSuccess'))
} else { } else {
if(!checkPermi(['gdzc_admin'])){
data.manageDept = matchingRole data.manageDept = matchingRole
}
await FixedAssetsApi.updateFixedAssets(data) await FixedAssetsApi.updateFixedAssets(data)
message.success(t('common.updateSuccess')) message.success(t('common.updateSuccess'))
} }

Loading…
Cancel
Save