Browse Source

提交修改

master
daikun1@bosssoft.com.cn 11 months ago
parent
commit
79d70be37c
  1. 4
      .env
  2. 13
      .env.production
  3. 4
      .env.test
  4. 4
      src/api/pszc/pselectricdata/index.ts
  5. 6
      src/api/tjanalysis/index.ts
  6. 17
      src/views/Home/Index.vue
  7. 6
      src/views/Login/components/LoginForm.vue
  8. 2
      src/views/lab/platscale/index.vue
  9. 136
      src/views/lab/platscale/platscale.data.ts
  10. 1
      src/views/report/goview/index.vue
  11. 64
      src/views/tjanalysis/electricdata/index.vue
  12. 3
      src/views/tjanalysis/irealdata/index.vue
  13. 120
      src/views/tjanalysis/natgasdatatotal/index.vue
  14. 2
      src/views/tjanalysis/platscale/index.vue

4
.env

@ -1,5 +1,5 @@
# 标题 # 标题
VITE_APP_TITLE=闻荫管理系统 VITE_APP_TITLE=铸诚钢管
# 项目本地运行端口号 # 项目本地运行端口号
VITE_PORT=80 VITE_PORT=80
@ -8,7 +8,7 @@ VITE_PORT=80
VITE_OPEN=true VITE_OPEN=true
# 租户开关 # 租户开关
VITE_APP_TENANT_ENABLE=true VITE_APP_TENANT_ENABLE=false
# 验证码的开关 # 验证码的开关
VITE_APP_CAPTCHA_ENABLE=true VITE_APP_CAPTCHA_ENABLE=true

13
.env.production

@ -4,16 +4,19 @@ NODE_ENV=production
VITE_DEV=false VITE_DEV=false
# 请求路径 # 请求路径
VITE_BASE_URL='http://localhost:12080' # VITE_BASE_URL='http://dev.ccwin-in.com:26110'
VITE_BASE_URL='http://10.140.10.4:26110'
# 上传路径 # 上传路径
VITE_UPLOAD_URL='http://localhost:12080/admin-api/infra/file/upload' # VITE_UPLOAD_URL='http://dev.ccwin-in.com:26110/api/admin-api/infra/file/upload'
VITE_UPLOAD_URL='http://10.140.10.4:26110/api/admin-api/infra/file/upload'
# 接口前缀 # 接口前缀
VITE_API_BASEPATH= VITE_API_BASEPATH=
# 接口地址 # 接口地址
VITE_API_URL=/admin-api # VITE_API_URL=/api/admin-api
VITE_API_URL=/api
# 是否删除debugger # 是否删除debugger
VITE_DROP_DEBUGGER=true VITE_DROP_DEBUGGER=true
@ -31,4 +34,6 @@ VITE_BASE_PATH=/
VITE_OUT_DIR=dist-pro VITE_OUT_DIR=dist-pro
# 积木报表请求路径 # 积木报表请求路径
VITE_JMREPORT_BASE_URL='http://dev.ccwin-in.com:25110' # VITE_JMREPORT_BASE_URL='http://dev.ccwin-in.com:26110'
VITE_JMREPORT_BASE_URL='http://10.140.10.4:26110'

4
.env.test

@ -31,7 +31,7 @@ VITE_BASE_PATH=/
VITE_OUT_DIR=dist-test VITE_OUT_DIR=dist-test
# 自定义接口路径 # 自定义接口路径
VITE_INTERFACE_URL='http://dev.ccwin-in.com:25110/magic/web/index.html' # VITE_INTERFACE_URL='http://dev.ccwin-in.com:25110/magic/web/index.html'
# 积木报表请求路径 # 积木报表请求路径
VITE_JMREPORT_BASE_URL='http://dev.ccwin-in.com:25110' # VITE_JMREPORT_BASE_URL='http://dev.ccwin-in.com:25110'

4
src/api/pszc/pselectricdata/index.ts

@ -49,3 +49,7 @@ export const exportPsElectricdata = async (params) => {
export const importTemplate = () => { export const importTemplate = () => {
return request.download({ url: '/pszc/pselectricdata/get-import-template' }) return request.download({ url: '/pszc/pselectricdata/get-import-template' })
} }
export const getAllDbTypes = async () => {
return await request.get({ url: `/pszc/pselectricdata/getAllDbTypes`})
}

6
src/api/tjanalysis/index.ts

@ -19,3 +19,9 @@ export const queryTjPlatScales = async (params) => {
export const exportPsales = async (params) => { export const exportPsales = async (params) => {
return await request.download({ url: `/tjanalysis/exportPsales`, params}) return await request.download({ url: `/tjanalysis/exportPsales`, params})
} }
// 天然气总流量日统计
export const queryNatgasdatatotal = async (params) => {
return await request.get({ url: `/tjanalysis/queryNatgasdatatotal`, params })
}

17
src/views/Home/Index.vue

@ -1,16 +1,13 @@
<template> <template>
<!-- <img class="homebg" src="@/assets/imgs/bgnew.jpg" /> --> <ContentWrap>
<div></div> <IFrame :src="src" />
</ContentWrap>
</template> </template>
<style lang="scss">
.homebg { <script lang="ts" setup>
padding: 0px; defineOptions({ name: 'GoView' })
width: 100%;
height: 100%;
// background-size: cover;
}
const src = '' //'http://localhost:3000/#/chart/preview/15'
</script>
</style>

6
src/views/Login/components/LoginForm.vue

@ -125,8 +125,10 @@ const loginData = reactive({
tenantEnable: import.meta.env.VITE_APP_TENANT_ENABLE, tenantEnable: import.meta.env.VITE_APP_TENANT_ENABLE,
loginForm: { loginForm: {
tenantName: '铸诚钢管', tenantName: '铸诚钢管',
username: 'admin', // username: 'admin',
password: '123456', // password: '123456',
username: '',
password: '',
captchaVerification: '', captchaVerification: '',
rememberMe: false, rememberMe: false,
code: '', code: '',

2
src/views/lab/platscale/index.vue

@ -33,7 +33,7 @@
</el-button> </el-button>
</template> </template>
<template #action="{ row }"> <template #action="{ row }">
<el-button type="text" @click="auditStatus(row)">确认</el-button> <!-- <el-button type="text" @click="auditStatus(row)">确认</el-button> -->
<ButtonBase :Butttondata="butttondata" @button-base-click="buttonTableClick($event,row)" /> <ButtonBase :Butttondata="butttondata" @button-base-click="buttonTableClick($event,row)" />
</template> </template>
</Table> </Table>

136
src/views/lab/platscale/platscale.data.ts

@ -12,62 +12,62 @@ export const Platscale = useCrudSchemas(reactive<CrudSchema[]>([
// sort: 'custom', // sort: 'custom',
// isForm: false, // isForm: false,
// }, // },
{ // {
label: '批号', // label: '批号',
field: 'batchNo', // field: 'batchNo',
sort: 'custom', // sort: 'custom',
isSearch: true, // isSearch: true,
table: { // table: {
width: 150 // width: 150
} // }
}, // },
{ // {
label: '送样单位', // label: '送样单位',
field: 'sydw', // field: 'sydw',
sort: 'custom', // sort: 'custom',
isSearch: false, // isSearch: false,
table: { // table: {
width: 150 // width: 150
} // }
}, // },
{ // {
label: '标准', // label: '标准',
field: 'standard', // field: 'standard',
sort: 'custom', // sort: 'custom',
isSearch: false, // isSearch: false,
table: { // table: {
width: 150 // width: 150
} // }
}, // },
{ // {
label: '材质', // label: '材质',
field: 'cz', // field: 'cz',
sort: 'custom', // sort: 'custom',
isSearch: false, // isSearch: false,
table: { // table: {
width: 150 // width: 150
} // }
}, // },
{ // {
label: '规格', // label: '规格',
field: 'guig', // field: 'guig',
sort: 'custom', // sort: 'custom',
isSearch: false, // isSearch: false,
table: { // table: {
width: 150 // width: 150
} // }
}, // },
{ // {
label: '实验人', // label: '实验人',
field: 'testUser', // field: 'testUser',
sort: 'custom', // sort: 'custom',
isSearch: true, // isSearch: true,
table: { // table: {
width: 150 // width: 150
}, // },
dictType: DICT_TYPE.LAB_USER_TEST_TYPE, // dictType: DICT_TYPE.LAB_USER_TEST_TYPE,
dictClass: 'number' // dictClass: 'number'
}, // },
{ {
label: '车号', label: '车号',
field: 'ch', field: 'ch',
@ -288,18 +288,18 @@ export const Platscale = useCrudSchemas(reactive<CrudSchema[]>([
width: 150 width: 150
} }
}, },
{ // {
label: '审核状态', // label: '审核状态',
field: 'auditStatus', // field: 'auditStatus',
sort: 'custom', // sort: 'custom',
isSearch: true, // isSearch: true,
table: { // table: {
width: 120, // width: 120,
fixed: 'right' // fixed: 'right'
}, // },
dictType: DICT_TYPE.LAB_AUDIT_STATUS, // dictType: DICT_TYPE.LAB_AUDIT_STATUS,
dictClass: 'number' // dictClass: 'number'
}, // },
{ {
label: '采集时间', label: '采集时间',
field: 'createTime', field: 'createTime',

1
src/views/report/goview/index.vue

@ -7,4 +7,5 @@
defineOptions({ name: 'GoView' }) defineOptions({ name: 'GoView' })
const src = 'http://127.0.0.1:3000' const src = 'http://127.0.0.1:3000'
// const src = 'http://10.140.10.4:26111'
</script> </script>

64
src/views/tjanalysis/electricdata/index.vue

@ -10,6 +10,15 @@
type="date" type="date"
/> />
</el-form-item> </el-form-item>
<el-form-item label="电表" prop="mcode">
<el-select v-model="queryParams.mcode" placeholder="请选择">
<el-option
v-for="item in dbTypes.typeList"
:key="item.mcode"
:label="item.mname"
:value="item.mcode" />
</el-select>
</el-form-item>
<el-form-item> <el-form-item>
<el-button type="primary" size="mini" @click="handleQuery">搜索</el-button> <el-button type="primary" size="mini" @click="handleQuery">搜索</el-button>
<el-button size="mini" @click="resetQuery">重置</el-button> <el-button size="mini" @click="resetQuery">重置</el-button>
@ -22,9 +31,8 @@
<el-divider content-position="left"><div style="font-size:16px; float: left"><b>二次计量</b></div><div style="float: left">一九八六年五月三日安全运行{{ dataList.days }}</div></el-divider> <el-divider content-position="left"><div style="font-size:16px; float: left"><b>二次计量</b></div><div style="float: left">一九八六年五月三日安全运行{{ dataList.days }}</div></el-divider>
<el-table <el-table
v-loading="loading" :data="dataList.dList" border="true" highlight-current-row="true" v-loading="loading" :data="dataList.dList" border="true" highlight-current-row="true"
header-row-style="height: 50px; text-align: center" :span-method="arraySpanMethod" header-row-style="height: 50px; text-align: center">
:row-class-name="tableRowClassName" :cell-class-name="tableCellClassName"> <!-- <el-table-column label="" prop="mname" align="right" :show-overflow-tooltip="true" width="250" /> -->
<el-table-column label="" prop="mname" align="right" :show-overflow-tooltip="true" width="150" />
<el-table-column label="" prop="name" align="right" :show-overflow-tooltip="true" width="150" /> <el-table-column label="" prop="name" align="right" :show-overflow-tooltip="true" width="150" />
<el-table-column label="00:00" prop="num0" align="center" :show-overflow-tooltip="true" width="100" /> <el-table-column label="00:00" prop="num0" align="center" :show-overflow-tooltip="true" width="100" />
<el-table-column label="06:00" prop="num6" align="center" :show-overflow-tooltip="true" width="100" /> <el-table-column label="06:00" prop="num6" align="center" :show-overflow-tooltip="true" width="100" />
@ -49,9 +57,11 @@
<script setup lang="ts"> <script setup lang="ts">
import * as TjanalysisApi from '@/api/tjanalysis' import * as TjanalysisApi from '@/api/tjanalysis'
import * as PselectricdataApi from '@/api/pszc/pselectricdata'
import { formatDate } from '@/utils/formatTime' import { formatDate } from '@/utils/formatTime'
import { get } from 'http'
defineOptions({ name: 'Irealanalysis' }) defineOptions({ name: 'ElectricdataAnalysis' })
const message = useMessage() // const message = useMessage() //
const { t } = useI18n() // const { t } = useI18n() //
@ -60,6 +70,7 @@ const route = useRoute() // 路由信息
const routeName = ref() const routeName = ref()
routeName.value = route.name routeName.value = route.name
const loading = ref(true) const loading = ref(true)
const dbTypes = reactive({typeList: []})
const dataList = reactive({dList: [] , days: 0}) const dataList = reactive({dList: [] , days: 0})
const queryParams = reactive({ const queryParams = reactive({
@ -76,6 +87,15 @@ const resetQuery = async () => {
getList() getList()
} }
const getDbTypes = async () => {
const res = await PselectricdataApi.getAllDbTypes()
if (res != null && res.length > 0) {
dbTypes.typeList = res
queryParams.mcode = res[0].mcode
getList()
}
}
const getList = async () => { const getList = async () => {
const res = await TjanalysisApi.queryElectricdataTj(queryParams) const res = await TjanalysisApi.queryElectricdataTj(queryParams)
if (res != null && res.trList != null) { if (res != null && res.trList != null) {
@ -85,43 +105,11 @@ const getList = async () => {
loading.value = false loading.value = false
} }
function arraySpanMethod ({ row, column, rowIndex, columnIndex }) {
if (rowIndex == 7) {
if (columnIndex == 0) {
return {
rowspan: 1,
colspan: 10
}
} else if (columnIndex == 10) {
return {
rowspan: 1,
colspan: 2
}
} else {
return {
rowspan: 0,
colspan: 0
}
}
}
}
function tableRowClassName({row, rowIndex}) {
if (rowIndex === 7) {
return 'success-row'
}
return ''
}
function tableCellClassName({row, column, rowIndex, columnIndex}) {
if (columnIndex == 0) {
return 'success-cols'
}
}
/** 初始化 **/ /** 初始化 **/
onMounted(async () => { onMounted(async () => {
getList() getDbTypes()
// getList()
}) })
</script> </script>

3
src/views/tjanalysis/irealdata/index.vue

@ -74,13 +74,14 @@ const getList = async () => {
const res = await TjanalysisApi.queryIrealdataTj(queryParams) const res = await TjanalysisApi.queryIrealdataTj(queryParams)
if (res != null && res.trList != null) { if (res != null && res.trList != null) {
dataList.days = res.days dataList.days = res.days
dataList.dList = []
dataList.dList = res.trList dataList.dList = res.trList
} }
loading.value = false loading.value = false
} }
function arraySpanMethod ({ row, column, rowIndex, columnIndex }) { function arraySpanMethod ({ row, column, rowIndex, columnIndex }) {
if (rowIndex == 7) { if (rowIndex == 6) {
if (columnIndex == 0) { if (columnIndex == 0) {
return { return {
rowspan: 1, rowspan: 1,

120
src/views/tjanalysis/natgasdatatotal/index.vue

@ -0,0 +1,120 @@
<template>
<ContentWrap>
<!-- 搜索工作栏 -->
<el-form :model="queryParams" ref="queryForm" :inline="true">
<el-form-item label="日期" prop="date">
<el-date-picker
v-model="queryParams.date"
style="width: 240px; height: 30px"
value-format="YYYY-MM-DD"
type="date"
/>
</el-form-item>
<el-form-item label="位置" prop="mcode">
<el-select v-model="queryParams.flag" placeholder="请选择">
<el-option
v-for="item in types.flagList"
:key="item.value"
:label="item.name"
:value="item.value" />
</el-select>
</el-form-item>
<el-form-item>
<el-button type="primary" size="mini" @click="handleQuery">搜索</el-button>
<el-button size="mini" @click="resetQuery">重置</el-button>
</el-form-item>
</el-form>
</ContentWrap>
<!-- 列表 -->
<ContentWrap>
<el-divider content-position="left"><div style="font-size:16px; float: left"><b>天然气</b></div></el-divider>
<el-table
v-loading="loading" :data="dataList.dList" border="true" highlight-current-row="true"
header-row-style="height: 50px; text-align: center">
<!-- <el-table-column label="" prop="mname" align="right" :show-overflow-tooltip="true" width="250" /> -->
<el-table-column label="" prop="name" align="right" :show-overflow-tooltip="true" width="150" />
<el-table-column label="00:00" prop="num0" align="center" :show-overflow-tooltip="true" width="120" />
<el-table-column label="06:00" prop="num6" align="center" :show-overflow-tooltip="true" width="120" />
<el-table-column label="08:00" prop="num8" align="center" :show-overflow-tooltip="true" width="120" />
<el-table-column label="12:00" prop="num12" align="center" :show-overflow-tooltip="true" width="120" />
<el-table-column label="16:00" prop="num16" align="center" :show-overflow-tooltip="true" width="120" />
<el-table-column label="18:00" prop="num18" align="center" :show-overflow-tooltip="true" width="120" />
<el-table-column label="20:00" prop="num20" align="center" :show-overflow-tooltip="true" width="120" />
<el-table-column label="22:00" prop="num22" align="center" :show-overflow-tooltip="true" width="120" />
<el-table-column label="24:00" prop="num24" align="center" :show-overflow-tooltip="true" width="120" />
<el-table-column label="08:00-00:00" prop="num0008" align="center" :show-overflow-tooltip="true" width="150" />
<el-table-column label="16:00-08:00" prop="num0816" align="center" :show-overflow-tooltip="true" width="150" />
<el-table-column label="24:00-16:00" prop="num1624" align="center" :show-overflow-tooltip="true" width="150" />
<el-table-column label="12:00-00:00" prop="num0012" align="center" :show-overflow-tooltip="true" width="150" />
<el-table-column label="24:00-12:00" prop="num1224" align="center" :show-overflow-tooltip="true" width="150" />
<el-table-column label="总(24:00-00:00)" prop="num0024" align="center" :show-overflow-tooltip="true" width="150" />
<!-- <el-table-column label="电量" prop="numTj" align="center" :show-overflow-tooltip="true" width="100" /> -->
</el-table>
</ContentWrap>
</template>
<script setup lang="ts">
import * as TjanalysisApi from '@/api/tjanalysis'
import * as PselectricdataApi from '@/api/pszc/pselectricdata'
import { formatDate } from '@/utils/formatTime'
import { get } from 'http'
defineOptions({ name: 'Natgasdatatotal' })
const message = useMessage() //
const { t } = useI18n() //
const route = useRoute() //
const routeName = ref()
routeName.value = route.name
const loading = ref(true)
const types = reactive({flagList: [
{name: '热轧' , value: '1'},
{name: '冷拔' , value: '2'}
]})
const dataList = reactive({dList: [] , days: 0})
const queryParams = reactive({
date: formatDate(new Date() , 'YYYY-MM-DD'),
flag: '1'
})
const handleQuery = async () => {
dataList.dList = []
getList()
}
const resetQuery = async () => {
dataList.dList = []
queryParams.date = formatDate(new Date() , 'YYYY-MM-DD')
getList()
}
const getList = async () => {
const res = await TjanalysisApi.queryNatgasdatatotal(queryParams)
if (res != null && res.trList != null) {
dataList.dList = res.trList
}
loading.value = false
}
/** 初始化 **/
onMounted(async () => {
getList()
})
</script>
<style>
.el-table .success-row {
background: #f0f9eb;
}
.el-table .success-cols {
font-weight: bold;
}
</style>

2
src/views/tjanalysis/platscale/index.vue

@ -50,7 +50,7 @@
import * as TjanalysisApi from '@/api/tjanalysis' import * as TjanalysisApi from '@/api/tjanalysis'
import { formatDate } from '@/utils/formatTime' import { formatDate } from '@/utils/formatTime'
defineOptions({ name: 'Irealanalysis' }) defineOptions({ name: 'PlatscaleAnalysis' })
const message = useMessage() // const message = useMessage() //
const { t } = useI18n() // const { t } = useI18n() //

Loading…
Cancel
Save