123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497 |
- import { defineAsyncComponent } from 'vue';
- import { BasicColumn } from '/@/components/Table';
- import { useGlobSetting } from '/@/hooks/setting';
- export const locationList = [
- {
- title: '风门',
- deviceType: 'gate',
- isVisible: 0,
- },
- {
- title: '风窗',
- deviceType: 'gate1',
- isVisible: 0,
- },
- {
- title: '测风装置',
- deviceType: 'gate2',
- isVisible: 0,
- },
- {
- title: '传感器',
- deviceType: 'gate3',
- isVisible: 0,
- },
- {
- title: '局部风机',
- deviceType: 'gate4',
- isVisible: 0,
- },
- {
- title: '主风机',
- deviceType: 'gate5',
- isVisible: 0,
- },
- {
- title: '风筒',
- deviceType: 'gate6',
- isVisible: 0,
- },
- {
- title: '密闭墙',
- deviceType: 'gate7',
- isVisible: 0,
- },
- ];
- export function getMonitorComponent() {
- const { sysOrgCode } = useGlobSetting();
- // const sysOrgCode = 'sdmtjtcctmk';
- let FiberModal;
- switch (sysOrgCode) {
- case 'sdmtjthlgmk': //哈拉沟
- FiberModal = defineAsyncComponent(() => import('./modal/fiber.modal.hlg.vue'));
- break;
- case 'sdmtjtcctmk': // 寸草塔
- FiberModal = defineAsyncComponent(() => import('./modal/fiber.modal.cct.vue'));
- break;
- case 'shsddlsjh': //沙吉海
- FiberModal = defineAsyncComponent(() => import('./modal/fiber.modal.sjh.vue'));
- break;
- case 'sdmtjtbdmk': //保德
- FiberModal = defineAsyncComponent(() => import('./modal/fiber.modal.bd.vue'));
- break;
- default:
- FiberModal = defineAsyncComponent(() => import('./modal/fiber.modal.bd.vue'));
- }
- const BundleModal = defineAsyncComponent(() => import('./modal/bundle.modal.vue'));
- const FiremonModal = defineAsyncComponent(() => import('./modal/firemon.modal.vue'));
- const DustModal = defineAsyncComponent(() => import('./modal/dust.modal.vue'));
- const BallvalveModal = defineAsyncComponent(() => import('./modal/ballvalve.modal.vue'));
- const AtomizingModal = defineAsyncComponent(() => import('./modal/atomizing.modal.vue'));
- const GaspatrolModal = defineAsyncComponent(() => import('./modal/gaspatrol.modal.vue'));
- const WisdomBallModal = defineAsyncComponent(() => import('./modal/wisdomball.modal.vue'));
- return { FiberModal, BundleModal, DustModal, BallvalveModal, AtomizingModal, GaspatrolModal, WisdomBallModal };
- }
- export const chartsColumnList = [
- {
- legend: '一氧化碳',
- seriesName: '(ppm)',
- ymax: 15,
- yname: 'ppm',
- linetype: 'line',
- yaxispos: 'left',
- color: '#FDB146',
- sort: 1,
- xRotate: 0,
- dataIndex: 'coval',
- },
- {
- legend: '乙炔',
- seriesName: '',
- ymax: 15,
- yname: 'ppm',
- linetype: 'line',
- yaxispos: 'left',
- color: '#00FFA8',
- sort: 1,
- xRotate: 0,
- dataIndex: 'chval',
- },
- {
- legend: '乙烯',
- seriesName: '',
- ymax: 15,
- yname: 'ppm',
- linetype: 'line',
- yaxispos: 'left',
- color: '#AE19FF',
- sort: 1,
- xRotate: 0,
- dataIndex: 'ch2val',
- },
- {
- legend: '二氧化碳',
- seriesName: '(%)',
- ymax: 20,
- yname: '%',
- linetype: 'line',
- yaxispos: 'right',
- color: '#9C83D9',
- sort: 2,
- xRotate: 0,
- dataIndex: 'co2val',
- },
- {
- legend: '甲烷',
- seriesName: '',
- ymax: 20,
- yname: '%',
- linetype: 'line',
- yaxispos: 'right',
- color: '#DA3914',
- sort: 2,
- xRotate: 0,
- dataIndex: 'gasval',
- },
- {
- legend: '氧气',
- seriesName: '(%)',
- ymax: 30,
- yname: '%',
- linetype: 'line',
- yaxispos: 'right',
- color: '#03C2EC',
- sort: 3,
- xRotate: 0,
- dataIndex: 'o2val',
- },
- ];
- export const chartsColumnListBall = [
- {
- legend: '一氧化碳',
- seriesName: '(ppm)',
- ymax: 30,
- yname: 'ppm',
- linetype: 'line',
- yaxispos: 'left',
- color: '#FDB146',
- sort: 1,
- xRotate: 0,
- dataIndex: 'coValue',
- },
- {
- legend: '氧气',
- seriesName: '',
- ymax: 30,
- yname: '%',
- linetype: 'line',
- yaxispos: 'right',
- color: '#00FFA8',
- sort: 2,
- xRotate: 0,
- dataIndex: 'o2Value',
- },
- {
- legend: '温度',
- seriesName: '(℃)',
- ymax: 30,
- yname: '℃',
- linetype: 'line',
- yaxispos: 'right',
- color: '#AE19FF',
- sort: 3,
- xRotate: 0,
- dataIndex: 'tempValue',
- },
- {
- legend: '二氧化碳',
- seriesName: '(%)',
- ymax: 30,
- yname: '%',
- linetype: 'line',
- yaxispos: 'right',
- color: '#9C83D9',
- sort: 2,
- xRotate: 0,
- dataIndex: 'co2val',
- },
- ];
- export const majorColumns: BasicColumn[] = [
- {
- title: '序号',
- dataIndex: '',
- key: 'rowIndex',
- width: 60,
- align: 'center',
- customRender: ({ index }) => {
- return `${index + 1}`;
- },
- },
- {
- title: '测段名称',
- align: 'center',
- dataIndex: 'name',
- width: 110,
- },
- {
- title: '始点',
- children: [
- {
- title: '测点位置',
- align: 'center',
- dataIndex: 'name1',
- width: 140,
- },
- {
- title: '风压(Pa)',
- align: 'center',
- dataIndex: 'pressure1',
- width: 100,
- },
- // {
- // title:'风压(KPa)',
- // align:"center",
- // dataIndex: 'name1'
- // },
- {
- title: '密度(kg/m³)',
- align: 'center',
- dataIndex: 'density1',
- width: 100,
- },
- {
- title: '标高(m)',
- align: 'center',
- dataIndex: 'elevation1',
- width: 100,
- },
- ],
- },
- {
- title: '末点',
- children: [
- {
- title: '测点位置',
- align: 'center',
- dataIndex: 'name2',
- width: 140,
- },
- {
- title: '风压(Pa)',
- align: 'center',
- dataIndex: 'pressure2',
- width: 100,
- },
- // {
- // title:'风压(KPa)',
- // align:"center",
- // dataIndex: 'name1'
- // },
- {
- title: '密度(kg/m³)',
- align: 'center',
- dataIndex: 'density2',
- width: 100,
- },
- {
- title: '标高(m)',
- align: 'center',
- dataIndex: 'elevation2',
- width: 100,
- },
- ],
- },
- {
- title: '风量(m³/min)',
- align: 'center',
- dataIndex: 'm3',
- width: 110,
- },
- {
- title: '阻力(Pa)',
- align: 'center',
- dataIndex: 'drag',
- width: 100,
- },
- {
- title: '风阻(Ns²/m⁸)',
- align: 'center',
- dataIndex: 'wdrag',
- width: 110,
- },
- {
- title: '更新时间',
- dataIndex: 'datatime',
- align: 'center',
- width: 127,
- },
- ];
- export const surfaceChartsColumns = [
- {
- legend: '进风',
- seriesName: '(m³/min)',
- ymax: 5000,
- yname: 'm³/min',
- linetype: 'line',
- yaxispos: 'left',
- color: '#00FFA8',
- sort: 1,
- xRotate: 0,
- dataIndex: 'jin',
- },
- {
- legend: '回风',
- seriesName: '',
- ymax: 5000,
- yname: 'm³/min',
- linetype: 'line',
- yaxispos: 'left',
- color: '#F07070',
- sort: 1,
- xRotate: 0,
- dataIndex: 'hui',
- },
- ];
- export const ballvalveColumns: BasicColumn[] = [
- {
- title: '设备编号',
- dataIndex: 'deviceNum',
- width: 60,
- align: 'center',
- },
- {
- title: '温度(℃)',
- dataIndex: 'tempRealtime',
- align: 'center',
- width: 60,
- },
- {
- title: 'CO(ppm)',
- dataIndex: 'CORealtime',
- align: 'center',
- width: 50,
- },
- {
- title: '压力(Pa)',
- dataIndex: 'PressureRealtime',
- align: 'center',
- width: 50,
- },
- {
- title: '烟雾(%)',
- dataIndex: 'SmokeRealtime485',
- align: 'center',
- width: 50,
- },
- {
- title: '是否报警',
- dataIndex: 'isWarn',
- align: 'center',
- width: 50,
- // customRender: () => {
- // return `正常`;
- // },
- },
- ];
- export const noDetailArr = ['nitrogen', 'forcFan']; // 前端详情的,
- // 棋盘井球阀监测数据只有温度
- export const haveDetailArr = [
- 'windrect',
- 'window',
- 'gate',
- 'fanlocal',
- 'fanmain',
- 'fiber',
- 'bundletube',
- 'gaspatrol',
- // 'dusting', // 保德要求去掉
- // 'ballvalve',
- 'pump',
- 'safetymonitor',
- 'nitrogen',
- 'atomizing',
- 'firemon',
- 'forcFan',
- 'pulping',
- ];
- export const locationFormConfig = {
- labelAlign: 'left',
- showAdvancedButton: false,
- showResetButton: true,
- showSubmitButton: false,
- size: 'small',
- // baseColProps: {
- // // offset: 0.5,
- // xs: 24,
- // sm: 24,
- // md: 24,
- // lg: 9,
- // xl: 7,
- // xxl: 4,
- // },
- schemas: [
- {
- label: '人员名称',
- field: 'strname',
- component: 'Input',
- },
- {
- label: '所属部门',
- field: 'department',
- component: 'MTreeSelect',
- componentProps: {
- placeholder: '请选择所属部门',
- virtual: false,
- api: '/monitor/getDepartmentInfo',
- },
- },
- {
- label: '分站名称',
- field: 'stationname',
- component: 'Input',
- },
- ],
- colProps: {
- span: 4,
- },
- };
- export const vehicleFormConfig = {
- labelAlign: 'left',
- showAdvancedButton: false,
- showResetButton: true,
- showSubmitButton: false,
- // size: 'small',
- // baseColProps: {
- // // offset: 0.5,
- // xs: 24,
- // sm: 24,
- // md: 24,
- // lg: 9,
- // xl: 7,
- // xxl: 4,
- // },
- schemas: [
- {
- label: '车辆名称',
- field: 'strname',
- component: 'Input',
- },
- {
- label: '分站名称',
- field: 'stationname',
- component: 'Input',
- },
- ],
- colProps: {
- span: 4,
- },
- };
- export const haveHandlerArr = [
- 'windrect',
- 'window',
- 'gate',
- 'fanlocal',
- 'fanmain',
- 'pump',
- 'obfurage',
- 'nitrogen',
- 'pulping',
- 'spray',
- 'dustdev',
- // 'firemon',
- ]; // table无操作
- export const noWarningArr = ['location', 'vehicle', 'cheliang', 'majorpath']; // 无预警详情的
- export const haveSysDetailArr = ['forcFan', 'pulping']; //有场景详情的
- // export const haveSysDetailArr = ['']; //有场景详情的
- export const noHistoryArr = () => (History_Type['type'] == 'remote' ? ['surface_history', 'majorpath'] : ['majorpath']);
|