¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <a-drawer |
| | | :title="title" |
| | | :width="drawerWidth" |
| | | :visible="visible" |
| | | @close="handleCancel" |
| | | :confirmLoading="confirmLoading" |
| | | :maskClosable="maskClosable" |
| | | > |
| | | <a-card :style="getBackground()"> |
| | | <template> |
| | | <a-card> |
| | | <div :style="{width: '100%',border: '1px solid #e9e9e9',padding: '10px 16px',background: '#fff',}"> |
| | | <a-row :style="{textAlign:'left'}"> |
| | | <a-button |
| | | :style="{marginRight: '8px'}" |
| | | @click="handleSW" |
| | | :disabled=SWbuttonDistable |
| | | type="primary" |
| | | >å¼å·¥</a-button> |
| | | <a-button |
| | | :style="{marginRight: '8px'}" |
| | | @click="handleReport" |
| | | :disabled="buttonDistable" |
| | | type="primary" |
| | | >æ¥å·¥</a-button> |
| | | <a-button |
| | | :style="{marginRight: '8px'}" |
| | | @click="handleReset" |
| | | :disabled="revocationDistable" |
| | | type="primary" |
| | | >æ¤é</a-button> |
| | | </a-row> |
| | | </div> |
| | | <div :style="{width: '100%',border: '1px solid #e9e9e9',padding: '10px 16px',background: '#fff',}"> |
| | | <a-row :gutter="24"> |
| | | <a-col :span="8"> |
| | | <a-form-item |
| | | :labelCol="labelCol" |
| | | :wrapperCol="wrapperCol" |
| | | label="ç¶æ" |
| | | class="hightColor" |
| | | > |
| | | <span |
| | | v-if="this.model != null" |
| | | class="hightColor" |
| | | >{{ this.model.status_dictText }}</span> |
| | | <span |
| | | v-else |
| | | class="frozenRowClass" |
| | | >-</span> |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :span="8"> |
| | | <a-form-item |
| | | :labelCol="labelCol" |
| | | :wrapperCol="wrapperCol" |
| | | label="å·¥åç»ä¸ç¼ç " |
| | | class="hightColor" |
| | | > |
| | | <span |
| | | v-if="this.model != null" |
| | | class="hightColor" |
| | | >{{ this.model.num }}</span> |
| | | <span |
| | | v-else |
| | | class="frozenRowClass" |
| | | >-</span> |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :span="8"> |
| | | <a-form-item |
| | | :labelCol="labelCol" |
| | | :wrapperCol="wrapperCol" |
| | | label="çæ§ç±»å" |
| | | class="hightColor" |
| | | > |
| | | <span |
| | | v-if="this.model != null" |
| | | class="hightColor" |
| | | >{{ this.model.monitorType_dictText }}</span> |
| | | <span |
| | | v-else |
| | | class="frozenRowClass" |
| | | >-</span> |
| | | </a-form-item> |
| | | </a-col> |
| | | </a-row> |
| | | <a-row :gutter="24"> |
| | | <a-col :span="8"> |
| | | <a-form-item |
| | | :labelCol="labelCol" |
| | | :wrapperCol="wrapperCol" |
| | | label="æ åç¼ç " |
| | | class="hightColor" |
| | | > |
| | | <span |
| | | v-if="this.model != null" |
| | | class="hightColor" |
| | | >{{ this.model.planNum }}</span> |
| | | <span |
| | | v-else |
| | | class="frozenRowClass" |
| | | >-</span> |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :span="8"> |
| | | <a-form-item |
| | | :labelCol="labelCol" |
| | | :wrapperCol="wrapperCol" |
| | | label="责任çç»" |
| | | class="hightColor" |
| | | > |
| | | <span |
| | | v-if="this.model != null" |
| | | class="hightColor" |
| | | >{{ this.model.teamId_dictText }}</span> |
| | | <span |
| | | v-else |
| | | class="frozenRowClass" |
| | | >-</span> |
| | | </a-form-item> |
| | | </a-col> |
| | | </a-row> |
| | | </div> |
| | | <div :style="{width: '100%',border: '1px solid #e9e9e9',padding: '10px 16px',background: '#fff',}"> |
| | | <a-row :gutter="24"> |
| | | <a-col :span="8"> |
| | | <a-form-item |
| | | :labelCol="labelCol" |
| | | :wrapperCol="wrapperCol" |
| | | label="设å¤ç¼å·" |
| | | class="hightColor" |
| | | > |
| | | <span |
| | | v-if="this.model != null" |
| | | class="hightColor" |
| | | >{{ this.model.equipmentNum }}</span> |
| | | <span |
| | | v-else |
| | | class="frozenRowClass" |
| | | >-</span> |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :span="8"> |
| | | <a-form-item |
| | | :labelCol="labelCol" |
| | | :wrapperCol="wrapperCol" |
| | | label="设å¤åç§°" |
| | | class="hightColor" |
| | | > |
| | | <span |
| | | v-if="this.model != null" |
| | | class="hightColor" |
| | | >{{ this.model.equipmentName }}</span> |
| | | <span |
| | | v-else |
| | | class="frozenRowClass" |
| | | >-</span> |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :span="8"> |
| | | <a-form-item |
| | | :labelCol="labelCol" |
| | | :wrapperCol="wrapperCol" |
| | | label="设å¤åå·" |
| | | class="hightColor" |
| | | > |
| | | <span |
| | | v-if="this.model != null" |
| | | class="hightColor" |
| | | >{{ this.model.model }}</span> |
| | | <span |
| | | v-else |
| | | class="frozenRowClass" |
| | | >-</span> |
| | | </a-form-item> |
| | | </a-col> |
| | | </a-row> |
| | | </div> |
| | | <a-tabs |
| | | type="card" |
| | | defaultActiveKey="1" |
| | | > |
| | | <a-tab-pane |
| | | tab='çæ§è®°å½' |
| | | key="1" |
| | | class="hightColor" |
| | | > |
| | | <div |
| | | class="table-operator" |
| | | style="margin:-16px" |
| | | > |
| | | <predictive-parameters :orderId='model.id' v-show="model.monitorType == 'cskz'"/> |
| | | <!-- v-if="selectionRows[0].monitorType == 'cskz'" --> |
| | | <predictive-warn :orderId='model.id' v-show="model.monitorType == 'bjkz'"/> |
| | | <!-- v-if="selectionRows[0].monitorType == 'bjkz'"--> |
| | | </div> |
| | | </a-tab-pane> |
| | | <a-tab-pane |
| | | tab='ç»´æ¤å
容' |
| | | key="2" |
| | | class="hightColor" |
| | | > |
| | | <predictive-order-detail-list :mainId='workPlanId'></predictive-order-detail-list> |
| | | </a-tab-pane> |
| | | |
| | | <a-tab-pane |
| | | tab='计åç¨æ' |
| | | key="3" |
| | | > |
| | | <div |
| | | class="table-operator" |
| | | style="margin:-16px" |
| | | > |
| | | <plan-material :maintenanceStandardId="workPlanId" /> |
| | | </div> |
| | | </a-tab-pane> |
| | | <a-tab-pane |
| | | tab='å±é©é²æ§' |
| | | key="4" |
| | | > |
| | | <div |
| | | class="table-operator" |
| | | style="margin:-16px" |
| | | > |
| | | <maintenance-standard-safety-requirement :maintenanceStandardId='workPlanId' /> |
| | | </div> |
| | | </a-tab-pane> |
| | | <a-tab-pane |
| | | tab='ä½ä¸æå¯¼ä¹¦' |
| | | key="5" |
| | | > |
| | | <div |
| | | class="table-operator" |
| | | style="margin:-16px" |
| | | > |
| | | <predictive-work-instruction :maintenanceStandardId='workPlanId'></predictive-work-instruction> |
| | | </div> |
| | | </a-tab-pane> |
| | | <a-tab-pane |
| | | tab='å®é
ç¨æ' |
| | | key="6" |
| | | > |
| | | <div |
| | | class="table-operator" |
| | | style="margin:-16px" |
| | | > |
| | | <actual-material-edit-table |
| | | ref="actualMaterialTabel" |
| | | :orderId="orderId" |
| | | :orderStatus="orderStatus" |
| | | :equipmentId="equipmentId" |
| | | ></actual-material-edit-table> |
| | | </div> |
| | | </a-tab-pane> |
| | | <a-tab-pane |
| | | tab='å®é
å·¥æ¶' |
| | | key="7" |
| | | > |
| | | <div |
| | | class="table-operator" |
| | | style="margin:-16px" |
| | | > |
| | | <actual-work-hours-edit-table |
| | | :orderId="orderId" |
| | | :orderStatus="orderStatus" |
| | | :equipmentId="equipmentId" |
| | | :teamId = "teamId" |
| | | ></actual-work-hours-edit-table> |
| | | </div> |
| | | </a-tab-pane> |
| | | </a-tabs> |
| | | </a-card> |
| | | </template> |
| | | </a-card> |
| | | |
| | | <div :style="{width: '100%',border: '1px solid #e9e9e9',padding: '10px 16px',background: '#fff',}"> |
| | | <a-row :style="{textAlign:'right'}"> |
| | | <a-button |
| | | :style="{marginRight: '8px'}" |
| | | @click="handleCancel" |
| | | > |
| | | åæ¶ |
| | | </a-button> |
| | | <a-button |
| | | :style="{marginRight: '8px'}" |
| | | @click="handleTS" |
| | | :disabled="buttonDistable" |
| | | type="primary" |
| | | v-if="false" |
| | | >æå</a-button> |
| | | <a-button |
| | | @click="handleOk" |
| | | :disabled="buttonDistable" |
| | | type="primary" |
| | | v-if="false" |
| | | >ä¿å</a-button> |
| | | </a-row> |
| | | </div> |
| | | </a-drawer> |
| | | </template> |
| | | |
| | | <script> |
| | | import { JeecgListMixin } from '@/mixins/JeecgListMixin' |
| | | import { requestPut, getAction, downFile } from '@/api/manage' |
| | | import Tooltip from 'ant-design-vue/es/tooltip' |
| | | |
| | | import { preview } from 'vue-photo-preview' |
| | | import { ACCESS_TOKEN } from '@/store/mutation-types' |
| | | import Vue from 'vue' |
| | | import PdfView from '@views/common/PdfView' |
| | | import { getFileAccessHttpUrl } from '@/api/manage'; |
| | | |
| | | import PlanMaterial from './PlanMaterial.vue' |
| | | import MaintenanceStandardSafetyRequirement from './SafetyRequirement' |
| | | import ActualMaterialEditTable from './ActualMaterialEditTable' |
| | | import ActualWorkHoursEditTable from './ActualWorkHoursEditTable' |
| | | //æ°ä¸è¥¿ |
| | | import PredictiveParameters from './boms/PredictiveParameters.vue' |
| | | import PredictiveSpareParts from './boms/PredictiveSpareParts.vue' |
| | | import PredictiveWarn from './boms/PredictiveWarn.vue' |
| | | import PredictiveOrderDetailList from './DetailList' |
| | | import PredictiveWorkInstruction from './WorkInstruction' |
| | | |
| | | export default { |
| | | name: 'PredictiveWorkOrderExeDrawer', |
| | | mixins: [JeecgListMixin], |
| | | components: { |
| | | PdfView, |
| | | Tooltip, |
| | | PlanMaterial, |
| | | MaintenanceStandardSafetyRequirement, |
| | | ActualMaterialEditTable, |
| | | ActualWorkHoursEditTable, |
| | | PredictiveParameters, |
| | | PredictiveSpareParts, |
| | | PredictiveWarn, |
| | | PredictiveOrderDetailList, |
| | | PredictiveWorkInstruction |
| | | |
| | | }, |
| | | data() { |
| | | return { |
| | | pageSizeOptions: ['1'], |
| | | currentPage: 1, |
| | | pageSize: 1, |
| | | total: 10, |
| | | // |
| | | workPlanId:'', |
| | | orderId:'', |
| | | orderStatus:'', |
| | | equipmentId:'', |
| | | teamId:'', |
| | | // |
| | | title: "ä¸ä¸å·¥åæ§è¡", |
| | | visible: false, |
| | | maskClosable: true, |
| | | confirmLoading: false, |
| | | drawerWidth: "100%", |
| | | buttonDistable: false, |
| | | SWbuttonDistable: false, |
| | | revocationDistable: false, |
| | | currentNodeSelect: '', |
| | | specialtyMaintenancePlanId: '', |
| | | maintenanceStandardId: '-1', |
| | | model: {}, |
| | | labelCol: { |
| | | xs: { span: 24 }, |
| | | sm: { span: 6 }, |
| | | }, |
| | | wrapperCol: { |
| | | xs: { span: 24 }, |
| | | sm: { span: 18 }, |
| | | }, |
| | | url: { |
| | | listMaterial: "/eam/maintenanceOrderActualMaterial/getMaintenanceOrderActualMaterialList", |
| | | listHours: "/eam/maintenanceOrderActualWorkingHour/getMaintenanceOrderActualWorkingHourList", |
| | | getEquipmentTotalByOrderId: "/eam/predictiveworkorder/getEquipmentTotalByOrderId", |
| | | urlDownload: window._CONFIG['staticDomainURL'], |
| | | download: '/sys/upload/downloadFile', |
| | | editStatus: "/eam/predictiveworkorder/editStatus", |
| | | revocation: "/eam/predictiveworkorder/revocation", |
| | | report: "/eam/predictiveworkorder/report", |
| | | }, |
| | | } |
| | | }, |
| | | mounted() { |
| | | this.$bus.$on('closeDrawer', (data) => { |
| | | this.visible = false; |
| | | }) |
| | | }, |
| | | |
| | | methods: { |
| | | |
| | | onChange(page, pageSize) { |
| | | this.queryParam.specialtyMaintenanceOrderId = this.specialtyMaintenanceOrderId |
| | | this.queryParam.pageSize = pageSize |
| | | this.queryParam.pageNo = page |
| | | this.getEquipmentTotal() |
| | | }, |
| | | |
| | | handleShow(record) { |
| | | this.model = Object.assign({}, record); |
| | | this.workPlanId = record.workPlanId; |
| | | this.orderId = record.id; |
| | | this.orderStatus = record.status; |
| | | this.equipmentId = record.equipmentId; |
| | | this.teamId = record.teamId; |
| | | this.visible = true; |
| | | if(record.status=='4'){ |
| | | this.$message.success("工忣卿§è¡å½ä¸ï¼è¯·å¨æ¤è¿ç¨ä¸å½å
¥å®é
ç¨æåå·¥æ¶") |
| | | } |
| | | |
| | | }, |
| | | getEquipmentTotal() { |
| | | var params = this.queryParam;//æ¥è¯¢æ¡ä»¶ |
| | | getAction(this.url.getEquipmentTotalByOrderId, params).then((res) => { |
| | | if (res.success) { |
| | | this.total = res.result.total |
| | | this.model.equipmentNum = res.result.records[0].equipmentNum |
| | | this.model.equipmentName = res.result.records[0].equipmentName |
| | | this.model.equipmentModel = res.result.records[0].equipmentModel |
| | | this.model.equipmentId = res.result.records[0].equipmentId |
| | | this.queryParam.equipmentId = res.result.records[0].equipmentId |
| | | this.loadData1(1) |
| | | } else { |
| | | this.$message.warning(res.message) |
| | | } |
| | | }).finally(() => { |
| | | |
| | | }) |
| | | }, |
| | | loadData1(arg) { |
| | | if (!this.url.list) { |
| | | this.$message.error("请设置url.list屿§!") |
| | | return |
| | | } |
| | | //å è½½æ°æ® è¥ä¼ å
¥åæ°1åå 载第ä¸é¡µçå
容 |
| | | if (arg === 1) { |
| | | this.ipagination.current = 1; |
| | | } |
| | | var params = this.getQueryParams();//æ¥è¯¢æ¡ä»¶ |
| | | this.loading = true; |
| | | getAction(this.url.list, params).then((res) => { |
| | | if (res.success) { |
| | | for (let i = 0; i < res.result.records.length; i++) { |
| | | this.maintenanceStandardId = res.result.records[i].maintenanceStandardId; |
| | | let r = res.result.records[i].sketchPhoto; |
| | | r.src = this.getSrc(res.result.records[i].sketchPhoto); |
| | | } |
| | | //update-begin---author:zhangyafei Date:20201118 forï¼éé
ä¸åé¡µçæ°æ®å表------------ |
| | | this.dataSource = res.result.records || res.result; |
| | | if (res.result.total) { |
| | | this.ipagination.total = res.result.total; |
| | | } else { |
| | | this.ipagination.total = 0; |
| | | } |
| | | //update-end---author:zhangyafei Date:20201118 forï¼éé
ä¸åé¡µçæ°æ®å表------------ |
| | | } else { |
| | | this.$message.warning(res.message) |
| | | } |
| | | }).finally(() => { |
| | | this.loading = false |
| | | }) |
| | | }, |
| | | |
| | | modalFormOk() { |
| | | this.getEquipmentTotal() |
| | | //æ¸
空å表éä¸ |
| | | this.onClearSelected() |
| | | }, |
| | | loadData() { |
| | | // this.getEquipmentTotal() |
| | | }, |
| | | getBackground() { |
| | | return "background-color:rgba(127, 127, 127,0.08)"; |
| | | }, |
| | | handleCancel() { |
| | | this.$emit('ok'); |
| | | this.alterFlag = new Date(); |
| | | this.close() |
| | | }, |
| | | close() { |
| | | this.visible = false; |
| | | }, |
| | | //æå |
| | | handleTS() { |
| | | const that = this; |
| | | that.confirmLoading = true; |
| | | let formData = Object.assign(this.model); |
| | | formData.specialtyInspectionOrderDetails = that.dataSource |
| | | requestPut(this.url.edit, formData).then((res) => { |
| | | if (res.success) { |
| | | that.$message.success("æåæå!"); |
| | | that.getEquipmentTotal() |
| | | that.$emit('ok'); |
| | | that.alterFlag = new Date(); |
| | | } else { |
| | | that.$message.warning(res.message); |
| | | } |
| | | }).finally(() => { |
| | | that.confirmLoading = false; |
| | | // that.close(); |
| | | }) |
| | | }, |
| | | //å¼å·¥ |
| | | handleSW() { |
| | | const that = this; |
| | | that.confirmLoading = true; |
| | | this.$confirm({ |
| | | title: 'å·¥åå¼å·¥', |
| | | content: 'æç¤ºï¼å¼å·¥åæ æ³æ¤åï¼è¯·è°¨æ
æä½ï¼', |
| | | okText: '确认', |
| | | cancelText: 'åæ¶', |
| | | onOk() { |
| | | requestPut(that.url.editStatus, { id: that.model.id, status: '4' }).then((res) => { |
| | | if (res.success) { |
| | | that.model.status = '4' |
| | | that.$message.success("å·¥åå¼å·¥æåï¼") |
| | | that.buttonDistable = false |
| | | that.revocationDistable = true |
| | | that.SWbuttonDistable = true |
| | | } else { |
| | | that.$message.warning("å·¥åå¼å·¥å¤±è´¥ï¼") |
| | | } |
| | | }).finally(() => { |
| | | that.confirmLoading = false; |
| | | // that.close(); |
| | | }) |
| | | }, |
| | | }) |
| | | }, |
| | | //æ¥å·¥ |
| | | handleReport() { |
| | | const that = this; |
| | | that.confirmLoading = true; |
| | | that.$confirm({ |
| | | title: '工忥工', |
| | | content: 'æç¤ºï¼å¦ææªå¡«åçå¿
填项æå¯¼è´æ¥å·¥å¤±è´¥ï¼ç¡®è®¤æ¥å·¥åï¼', |
| | | okText: '确认', |
| | | cancelText: 'åæ¶', |
| | | onOk() { |
| | | requestPut(that.url.report, { id: that.orderId, status: '5' }).then((res) => { |
| | | if (res.success) { |
| | | that.model.status = '5' |
| | | that.$message.success(res.message) |
| | | that.buttonDistable = false |
| | | that.revocationDistable = true |
| | | that.SWbuttonDistable = true |
| | | that.$emit('ok'); |
| | | that.alterFlag = new Date(); |
| | | that.close(); |
| | | } else { |
| | | that.$message.warning(res.message) |
| | | } |
| | | }).finally(() => { |
| | | that.confirmLoading = false; |
| | | // |
| | | }) |
| | | }, |
| | | }) |
| | | }, |
| | | //æ¤é |
| | | handleReset() { |
| | | const that = this; |
| | | that.confirmLoading = true; |
| | | this.$confirm({ |
| | | title: 'å®å·¥æ¤é', |
| | | content: 'æç¤ºï¼å®å·¥æ¤éåå¯ç»§ç»æ¥å·¥æä½ï¼', |
| | | okText: '确认', |
| | | cancelText: 'åæ¶', |
| | | onOk() { |
| | | requestPut(that.url.revocation, { id: that.orderId, status: '4' }).then((res) => { |
| | | if (res.success) { |
| | | that.model.status = '4' |
| | | that.orderStatus = '4' |
| | | that.$message.success(res.message) |
| | | that.buttonDistable = false |
| | | that.revocationDistable = true |
| | | that.SWbuttonDistable = true |
| | | that.$emit('ok'); |
| | | } else { |
| | | that.$message.warning(res.message) |
| | | } |
| | | }).finally(() => { |
| | | that.confirmLoading = false; |
| | | // that.close(); |
| | | }) |
| | | }, |
| | | }) |
| | | }, |
| | | //ä¿å |
| | | handleOk() { |
| | | const that = this; |
| | | that.confirmLoading = true; |
| | | let formData = Object.assign(this.model); |
| | | for (let i = 0; i < that.dataSource.length; i++) { |
| | | let o = this.dataSource[i] |
| | | if (o.inspectionProjectResult == null || o.inspectionProjectResult == '') { |
| | | that.$message.warning('请è¾å
¥ç¹æ£ç»æï¼') |
| | | that.confirmLoading = false; |
| | | return |
| | | } |
| | | if (o.treatmentMeasure == null || o.treatmentMeasure == '') { |
| | | that.$message.warning('è¯·éæ©å¼å¸¸å¤ç½®ï¼') |
| | | that.confirmLoading = false; |
| | | return |
| | | } |
| | | } |
| | | formData.specialtyInspectionOrderDetails = that.dataSource |
| | | requestPut(this.url.save, formData).then((res) => { |
| | | if (res.success) { |
| | | that.$message.success("ä¿åæå!"); |
| | | that.getEquipmentTotal() |
| | | that.$emit('ok'); |
| | | that.alterFlag = new Date(); |
| | | } else { |
| | | that.$message.warning("ä¿å失败!"); |
| | | } |
| | | }).finally(() => { |
| | | that.confirmLoading = false; |
| | | // that.close(); |
| | | }) |
| | | }, |
| | | |
| | | view(record) { |
| | | this.$refs.pdfview.showPdf(record.src); |
| | | }, |
| | | |
| | | handleDownload(record) { |
| | | downFile(this.url.download, { id: record.upload.id }).then((res) => { |
| | | if (!res) { |
| | | this.$message.warning('æä»¶ä¸è½½å¤±è´¥') |
| | | return |
| | | } else { |
| | | let fileName = record.upload.name; |
| | | if (typeof window.navigator.msSaveBlob !== 'undefined') { |
| | | window.navigator.msSaveBlob(new Blob([res]), fileName); |
| | | } else { |
| | | let url = window.URL.createObjectURL(new Blob([res])); |
| | | let link = document.createElement('a'); |
| | | link.style.display = 'none'; |
| | | link.href = url; |
| | | link.setAttribute('download', fileName); |
| | | document.body.appendChild(link); |
| | | link.click() |
| | | document.body.removeChild(link) //ä¸è½½å®æç§»é¤å
ç´ |
| | | window.URL.revokeObjectURL(url) //éæ¾æblob对象 |
| | | } |
| | | } |
| | | }) |
| | | }, |
| | | |
| | | getSrc(record) { |
| | | if (!record.path) { |
| | | return ''; |
| | | } |
| | | //æ¬å°ï¼local\Minioï¼minio\é¿éäºï¼alioss |
| | | if (record.uploadType == 'local') { |
| | | |
| | | let ssoLoginFlag = Vue.ls.get("ssoLoginFlag"); |
| | | let deployMode = Vue.ls.get("deployMode"); |
| | | |
| | | if (ssoLoginFlag && deployMode == "container") { |
| | | var baseProject = Vue.ls.get("baseProject"); |
| | | console.log("baseProject==>" + baseProject) |
| | | |
| | | var hostname = window.location.protocol + "//" + window.location.host; |
| | | var url = hostname + '/' + baseProject + '/sys/common/static'; |
| | | return getFileAccessHttpUrl(record.path + record.encodeName, url, window._CONFIG['hyperTextTransfer']) |
| | | } else { |
| | | //æ ¹æ®åå¸ç¶æä¿®æ¹https æ http |
| | | return getFileAccessHttpUrl(record.path + record.encodeName, this.url.urlDownload, window._CONFIG['hyperTextTransfer']) |
| | | } |
| | | |
| | | } else if (record.uploadType == 'alioss') { |
| | | |
| | | const OSS = require('ali-oss') |
| | | const client = new OSS({ |
| | | // region以æå·ä¸ºä¾ï¼oss-cn-hangzhouï¼ï¼å
¶ä»regionæå®é
æ
åµå¡«åã |
| | | region: window._CONFIG['region'], |
| | | // é¿éäºä¸»è´¦å·AccessKeyæ¥æææAPIçè®¿é®æéï¼é£é©å¾é«ã强ç建议æ¨å建并使ç¨RAMè´¦å·è¿è¡APIè®¿é®ææ¥å¸¸è¿ç»´ï¼è¯·ç»å½RAMæ§å¶å°å建RAMè´¦å·ã |
| | | accessKeyId: window._CONFIG['accessKeyId'], |
| | | accessKeySecret: window._CONFIG['accessKeySecret'], |
| | | bucket: window._CONFIG['bucket'], |
| | | }) |
| | | // object-key表示ä»OSSä¸è½½æä»¶æ¶éè¦æå®å
嫿件åç¼å¨å
ç宿´è·¯å¾ï¼ä¾å¦abc/efg/123.jpgã |
| | | return client.signatureUrl(record.path) |
| | | } |
| | | }, |
| | | }, |
| | | |
| | | } |
| | | </script> |
| | | |
| | | <style scoped> |
| | | @import '~@assets/less/common.less'; |
| | | .hightColor { |
| | | height: 10%; |
| | | font-weight: bold; |
| | | font-size: 20px; |
| | | color: #1b1e1e; |
| | | } |
| | | .frozenRowClass { |
| | | color: #c9c9c9; |
| | | } |
| | | .fontweight { |
| | | font-weight: bold; |
| | | } |
| | | .hight { |
| | | color: #f5222d; |
| | | } |
| | | .red { |
| | | color: red; |
| | | } |
| | | </style> |