Compare commits

..

6 Commits
master ... main

Author SHA1 Message Date
lupeng_zz 00a5f4a3bd 修改中英文滚动条 2026-05-19 16:54:18 +08:00
lupeng_zz b1984d3039 修改进度条问题,中文版已经修改完成。 2026-05-19 15:44:49 +08:00
lupeng_zz b951d518c3 提交前端代码 2026-05-19 15:06:53 +08:00
lupeng_zz 4aff2af250 最新代码 2026-01-29 15:13:21 +08:00
lupeng 1d2bf2042c 修改前端页面 2025-08-26 12:46:43 +08:00
lupeng 819ec53de1 修改页面上的冒号和样式 2025-08-19 16:29:18 +08:00
57 changed files with 6141 additions and 2407 deletions

View File

@ -2,5 +2,6 @@
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="$PROJECT_DIR$/../.." vcs="Git" />
<mapping directory="$PROJECT_DIR$" vcs="Git" />
</component>
</project>

2
.vscode/settings.json vendored Normal file
View File

@ -0,0 +1,2 @@
{
}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -57,6 +57,9 @@
<script src="scripts/ps.js"></script>
<script src="scripts/nbs.js"></script>
<script src="scripts/month.js"></script>
<script src="scripts/updatePwd.js"></script>
<script src="scripts/battery.js"></script>
</head>
<body style="margin: 0px;">
@ -79,7 +82,7 @@
<el-dropdown-menu slot="dropdown" style="font-size: 12px;">
<el-dropdown-item command='setting'>显示设置</el-dropdown-item>
<el-dropdown-item command='help'>帮助</el-dropdown-item>
<el-dropdown-item command='updatepwd'>修改密码</el-dropdown-item>
<el-dropdown-item command='updatePwd'>修改密码</el-dropdown-item>
<el-dropdown-item command='exit'>退出</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>

View File

@ -875,7 +875,7 @@
handleSizeChange(val) {
this.$data.pagesize = val;
this.$data.currentPage = 1;
var _this = this;
var objs;

View File

@ -209,7 +209,7 @@
this.$data.pagesize = val;
var _this = this;
this.$data.currentPage = 1;
var objs;
axios.post('/deescloud/getAuthHisPos', {
opuser:localStorage.getItem("online_user"),

View File

@ -455,7 +455,7 @@
handleSizeChange(val) {
//console.log(`每页 ${val} 条`);
this.$data.pagesize = val;
this.$data.currentPage = 1;
var _this = this;
var objs;

View File

@ -455,7 +455,7 @@
handleSizeChange(val) {
//console.log(`每页 ${val} 条`);
this.$data.pagesize = val;
this.$data.currentPage = 1;
var _this = this;
var objs;

File diff suppressed because it is too large Load Diff

View File

@ -1,18 +1,62 @@
//组件
var devcomponent = {
var devcomponent = {
template:`
<div>
<div style="display: flex;margin-top: 10px;">
<el-input v-model="input" placeholder="请输入井名" clearable style="width: 20%;"></el-input>
<div style="display: flex;margin-top: 10px; flex-wrap: wrap; align-items: center;">
<el-radio-group v-model="radio1" @change="radio_change" style="display: inline-flex; flex-direction: row; flex-wrap: nowrap;">
<el-radio-button label="1">井位</el-radio-button>
<el-radio-button label="2">设备</el-radio-button>
</el-radio-group>
<!-- 井位页签的筛选框放在这里与页签同行 -->
<div v-if="radio1=='1'" style="display: flex; margin-left: 20px; align-items: center;">
<el-input v-model="input" placeholder="请输入井名" clearable style="width: 200px;"></el-input>
<el-button style="margin-left: 5px;" id ="bt_serach" plain type="primary" icon="el-icon-search" @click="getWell(input)">搜索</el-button>
<el-button style="margin-left: 5px;" id ="bt_add" plain type="primary" icon="el-icon-circle-plus-outline" @click="add_dev_manage_dialog()">新增</el-button>
</div>
<!-- 设备页签的时间筛选框与页签同行 -->
<div v-if="radio1=='2'" style="display: flex; margin-left: 20px; align-items: center; flex-wrap: wrap;">
<el-date-picker
v-model="devSearchForm.in_time_start"
type="date"
placeholder="入井开始时间"
value-format="yyyy-MM-dd"
:picker-options="startTimeOptions"
style="width: 160px;">
</el-date-picker>
<el-date-picker
v-model="devSearchForm.in_time_end"
type="date"
placeholder="入井结束时间"
value-format="yyyy-MM-dd"
:picker-options="endTimeOptions"
style="width: 160px; margin-left: 5px;">
</el-date-picker>
</div>
<div class="span">
<!-- 设备页签的时间筛选框与页签同行 -->
<div v-if="radio1=='2'" style="display: flex; align-items: center; margin-top: 10px; flex-wrap: wrap; white-space: nowrap;">
<el-select v-model="devSearchForm.wellnameList" placeholder="请输入井名称" filterable clearable multiple collapse-tags style="width: 240px; max-width: 380px; margin-left: 0px;">
<el-option v-for="item in devWellnameOptions" :key="item.value" :label="item.label" :value="item.value"></el-option>
</el-select>
<el-select v-model="devSearchForm.sid" placeholder="请输入系列号" filterable clearable multiple collapse-tags style="width: 180px; max-width: 320px; margin-left: 5px;">
<el-option v-for="item in devSidOptions" :key="item.value" :label="item.label" :value="item.value"></el-option>
</el-select>
<el-select v-model="devSearchForm.iid" placeholder="请输入编号" filterable clearable multiple collapse-tags style="width: 180px; max-width: 320px; margin-left: 5px;">
<el-option v-for="item in devIidOptions" :key="item.value" :label="item.label" :value="item.value"></el-option>
</el-select>
<el-select v-model="devSearchForm.engineerList" placeholder="请输入仪器工程师" filterable clearable multiple collapse-tags style="width: 200px; max-width: 320px; margin-left: 5px;">
<el-option v-for="item in devEngineerOptions" :key="item.value" :label="item.label" :value="item.value"></el-option>
</el-select>
<el-button style="margin-left: 5px;" plain type="primary" icon="el-icon-search" @click="getDevList()">搜索</el-button>
<el-button style="margin-left: 5px;" plain type="primary" icon="el-icon-document-checked" @click="exportSeirDetail()">导出仪器明细</el-button>
<el-button style="margin-left: 5px;" plain type="primary" icon="el-icon-document-checked" @click="exportWellDetail()">导出井位明细</el-button>
</div>
</div>
<div class="span" v-if='radio1=="1"' style="height: calc(100vh - 200px); overflow-x: auto;">
<el-table
:data="tableData"
style="width: 100%;font-size:14px"
:height="tHeight"
height="100%"
:cell-style="{background:'#304156'}"
border
>
@ -50,7 +94,7 @@
</el-table-column>
</el-table>
</div>
<div class="block">
<div class="block" v-if='radio1=="1"'>
<span class="demonstration" style="background-color: #ECF5FF;"></span>
<el-pagination
@size-change="handleSizeChange"
@ -61,6 +105,83 @@
layout="total, sizes, prev, pager, next, jumper"
:total="recordTotal" style="background-color: #ECF5FF;">
</el-pagination>
</div>
<div class="span" v-if='radio1=="2"' style="height: calc(100vh - 250px); overflow-x: auto;">
<el-table
:data="devListTableData"
style="width: 100%;font-size:14px"
height="100%"
:cell-style="{background:'#304156'}"
border
>
<el-table-column
prop="instrument_name"
label="仪器名称"
:width="150"
:show-overflow-tooltip="true">
</el-table-column>
<el-table-column
prop="sid"
label="系列号"
:width="120">
</el-table-column>
<el-table-column
prop="iid"
label="编号"
:width="120"
:show-overflow-tooltip="true">
</el-table-column>
<el-table-column
prop="wellname"
label="井名称"
:width="150"
:show-overflow-tooltip="true">
</el-table-column>
<el-table-column
prop="in_time"
label="入井时间"
width="160">
</el-table-column>
<el-table-column
prop="out_time"
label="出井时间"
width="160">
</el-table-column>
<el-table-column
prop="engineer"
label="仪器工程师"
width="120">
</el-table-column>
<el-table-column
prop="duration_current"
label="本次时长(h)"
width="120">
</el-table-column>
<el-table-column
prop="duration_total"
label="累计时长(h)"
width="120">
</el-table-column>
<el-table-column
prop="location"
label="所在地"
width="150"
:show-overflow-tooltip="true">
</el-table-column>
</el-table>
</div>
<div class="block" v-if='radio1=="2"' style="margin-top: 5px; margin-bottom: 5px;">
<span class="demonstration" style="background-color: #ECF5FF;"></span>
<el-pagination
@size-change="handleDevSizeChange"
@current-change="handleDevCurrentChange"
:current-page="devCurrentPage"
:page-sizes="[50,100, 200, 300]"
:page-size="devPagesize"
layout="total, sizes, prev, pager, next, jumper"
:total="devRecordTotal" style="background-color: #ECF5FF;">
</el-pagination>
</div>
<el-dialog
@ -247,7 +368,6 @@
value-format="yyyy-MM-dd">
</el-date-picker>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="10">
@ -384,7 +504,6 @@
value-format="yyyy-MM-dd">
</el-date-picker>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="10">
@ -441,13 +560,34 @@
console.log("screen width:",screenW);
console.log("screen height:",screenH);
return {
tHeight:screenH-192,
tHeight1:screenH*0.5,
tableData: Array(0),
input:'',
tHeight1: screenH * 0.5,
tableData: [],
input: '',
currentPage: 1,
pagesize:50,
recordTotal:0,
pagesize: 50,
recordTotal: 0,
radio1: '1',
// 设备列表相关数据
devListTableData: [],
devSearchForm: {
sid: [],
iid: [],
wellname: '',
wellnameList: [],
engineerList: [],
in_time_start: '',
in_time_end: ''
},
// 设备筛选下拉选项
devSidOptions: [],
devIidOptions: [],
devWellnameOptions: [],
devEngineerOptions: [],
devCurrentPage: 1,
devPagesize: 50,
devRecordTotal: 0,
pdf_visible:false,
dev_tableData:[],
@ -488,11 +628,32 @@
if_show_bt:true,
if_show_et:false,
ps_info:'',
// 日期选择器配置
startTimeOptions: {
disabledDate: (time) => {
if (this.devSearchForm.in_time_end) {
return time.getTime() > new Date(this.devSearchForm.in_time_end).getTime();
}
return false;
}
},
endTimeOptions: {
disabledDate: (time) => {
if (this.devSearchForm.in_time_start) {
return time.getTime() < new Date(this.devSearchForm.in_time_start).getTime();
}
return false;
}
},
}
},
mounted() {
var _this = this;
this.getQueryWellData();
this.getWell();
axios.post('/deescloud/get_page_setting', {
opuser:localStorage.getItem("online_user"),
opuser_uuid:localStorage.getItem("uuid"),
@ -511,26 +672,243 @@
console.log(error);
});
var objs;
axios.post('/deescloud/get_well_dev', {
opuser:localStorage.getItem("online_user"),
opuser_uuid:localStorage.getItem("uuid"),
index: this.$data.currentPage,
count: this.$data.pagesize
// 获取设备筛选选项
this.getDevFilterOptions();
// 初始加载时自动执行查询,传入空字符串以获取所有数据或默认数据
// 直接调用,不依赖 nextTick因为 axios 请求不依赖 DOM 渲染
this.getWell('');
},
methods: {
getQueryWellData() {
var _this = this;
axios.post('/deescloud/getQueryWell', {
opuser: localStorage.getItem("online_user"),
opuser_uuid: localStorage.getItem("uuid")
})
.then(function (response) {
console.log("getQueryWell 响应参数:", response.data);
if (response.data && response.data.code === 0 && response.data.data) {
const data = response.data.data;
// 映射井名称选项
if (data.wellNames && Array.isArray(data.wellNames)) {
_this.devWellnameOptions = data.wellNames.map(name => ({
value: name,
label: name
}));
}
// 映射系列号选项
if (data.series && Array.isArray(data.series)) {
_this.devSidOptions = data.series.map(sid => ({
value: sid,
label: sid
}));
}
// 映射编号/仪器选项
if (data.instruments && Array.isArray(data.instruments)) {
_this.devIidOptions = data.instruments.map(inst => ({
value: inst,
label: inst
}));
}
// 映射工程师选项
if (data.engineers && Array.isArray(data.engineers)) {
_this.devEngineerOptions = data.engineers.map(engineer => ({
value: engineer,
label: engineer
}));
}
// 注意locations 目前前端模板中没有对应的 select 绑定变量,
// 如果后续需要添加所在地和工程师的下拉筛选,需先在 data 中定义对应 options 变量并在模板中添加 el-select
}
})
.catch(function (error) {
console.error("getQueryWell 请求失败:", error);
});
},
radio_change(){
console.log(this.$data.radio1);
// 切换到设备页签时,可以自动加载一次数据,或者依赖用户点击搜索
if(this.$data.radio1 == '2') {
this.getDevList();
}
},
// 获取设备列表
getDevList() {
// 校验时间范围
if (this.devSearchForm.in_time_start && this.devSearchForm.in_time_end) {
if (new Date(this.devSearchForm.in_time_end) < new Date(this.devSearchForm.in_time_start)) {
this.$message({
message: "结束时间不能早于开始时间",
type: "warning",
duration: 2000
});
return;
}
}
var _this = this;
axios.post('/deescloud/get_dev_list', {
opuser: localStorage.getItem("online_user"), // 操作用户
opuser_uuid: localStorage.getItem("uuid"), // 用户UUID
serial: this.$data.devSearchForm.sid, // 系列号筛选条件
number: this.$data.devSearchForm.iid, // 编号筛选条件
wellname: this.$data.devSearchForm.wellnameList, // 井名称筛选条件,使用用户选择的列表
engineer: this.$data.devSearchForm.engineerList, // 仪器工程师筛选条件
in_time_start: this.$data.devSearchForm.in_time_start, // 入井开始时间筛选条件
in_time_end: this.$data.devSearchForm.in_time_end, // 入井结束时间筛选条件
index: this.$data.devCurrentPage, // 当前页码
count: this.$data.devPagesize // 每页数量
})
.then(function (response) {
console.log(response.data);
objs = response.data.data;
rcnt = response.data.total;
_this.$data.tableData = objs;
_this.$data.recordTotal = rcnt;
if(response.data && response.data.data) {
// 兼容后端字段命名差异,统一映射到前端表格使用的字段
_this.$data.devListTableData = (response.data.data || []).map(function(item) {
var sid = item.sid != null ? item.sid : (item.serial != null ? item.serial : '');
var iid = item.iid != null ? item.iid : (item.number != null ? item.number : '');
var durationCurrent = item.duration_current != null ? item.duration_current : (item.current_work_time != null ? item.current_work_time : '');
var durationTotal = item.duration_total != null ? item.duration_total : (item.total_work_time != null ? item.total_work_time : '');
// 兼容 product_name 到 instrument_name
var instrumentName = item.instrument_name != null ? item.instrument_name : (item.product_name != null ? item.product_name : '');
return Object.assign({}, item, {
sid: sid,
iid: iid,
duration_current: durationCurrent,
duration_total: durationTotal,
instrument_name: instrumentName
});
});
_this.$data.devRecordTotal = response.data.total || 0;
}
})
.catch(function (error) {
console.log(error);
});
},
methods: {
handleDevSizeChange(val) {
this.$data.devPagesize = val;
this.$data.devCurrentPage = 1;
this.getDevList();
},
handleDevCurrentChange(val) {
this.$data.devCurrentPage = val;
this.getDevList();
},
exportSeirDetail() {
// 校验时间范围
if (this.devSearchForm.in_time_start && this.devSearchForm.in_time_end) {
if (new Date(this.devSearchForm.in_time_end) < new Date(this.devSearchForm.in_time_start)) {
this.$message({
message: "结束时间不能早于开始时间",
type: "warning",
duration: 2000
});
return;
}
}
// 调用导出接口,参数与 getDevList 一致
axios.post('/deescloud/export_Seir_detail', {
opuser: localStorage.getItem("online_user"),
opuser_uuid: localStorage.getItem("uuid"),
serial: this.devSearchForm.sid,
number: this.devSearchForm.iid,
wellname: this.devSearchForm.wellnameList,
engineer: this.devSearchForm.engineerList,
in_time_start: this.devSearchForm.in_time_start,
in_time_end: this.devSearchForm.in_time_end,
index: this.devCurrentPage,
count: this.devPagesize
})
.then(response => {
console.log("导出井位明细响应:", response.data);
// 判断返回码
if (response.data && response.data.code === 1) {
// 当 code=1 时,显示错误信息
this.$message({
message: response.data.msg || "导出失败",
type: "error",
duration: 2000
});
return;
}
// code 不为 1 时,正常处理文件下载
if (response.data && response.data.fileId) {
const fileid = response.data.fileId;
const downUrl = 'file/' + fileid;
downloadUrl("井上仪器明细清单(按仪器查询).xlsx", downUrl);
} else {
this.$message({
message: "导出失败:未获取到文件",
type: "error",
duration: 2000
});
}
})
.catch(error => {
console.error("导出井位明细错误:", error);
this.$message({
message: "导出请求失败",
type: "error",
duration: 2000
});
});
},
exportWellDetail() {
var _this = this;
// 调用导出接口,参数与 getDevList 一致,支持多选井名
axios.post('/deescloud/export_Well_detail', {
opuser: localStorage.getItem("online_user"),
opuser_uuid: localStorage.getItem("uuid"),
serial: this.devSearchForm.sid,
number: this.devSearchForm.iid,
wellname: this.devSearchForm.wellnameList,
engineer: this.devSearchForm.engineerList,
in_time_start: this.devSearchForm.in_time_start,
in_time_end: this.devSearchForm.in_time_end,
index: this.devCurrentPage,
count: this.devPagesize
})
.then(response => {
console.log("导出井位明细响应:", response.data);
// 增加 code=1 的错误处理
if (response.data && response.data.code === 1) {
_this.$message({
message: response.data.msg || "导出失败",
type: "error",
duration: 2000
});
return;
}
if (response.data && response.data.fileId) {
const fileid = response.data.fileId;
const downUrl = 'file/' + fileid;
downloadUrl("井上仪器明细清单(按井位查询).xlsx", downUrl);
} else {
_this.$message({
message: "导出失败:未获取到文件",
type: "error",
duration: 2000
});
}
})
.catch(error => {
console.error("导出井位明细错误:", error);
_this.$message({
message: "导出请求失败",
type: "error",
duration: 2000
});
});
},
remove_dev_m(row){
var _this = this;
@ -659,7 +1037,7 @@
}
if (row.cal_date.length>=10){
var arr = row.p_date.split("-")
var arr = row.cal_date.split("-")
var t = arr[2]+"-"+arr[0]+"-"+arr[1];
console.log(t);
this.$data.form.cal_date=t;
@ -799,8 +1177,6 @@
},
getWell(_search_name){
document.getElementById("bt_serach").blur();
this.$data.currentPage=1;
var _this = this;
@ -828,7 +1204,7 @@
handleSizeChange(val) {
//console.log(`每页 ${val} 条`);
this.$data.pagesize = val;
this.$data.currentPage = 1;
var _this = this;
var objs;
@ -876,7 +1252,6 @@
});
},
}
}

View File

@ -412,7 +412,7 @@
handleSizeChange(val) {
//console.log(`每页 ${val} 条`);
this.$data.pagesize = val;
this.$data.currentPage = 1;
var beginTime= '';
var endTime = '';

View File

@ -414,7 +414,7 @@
handleSizeChange(val) {
//console.log(`每页 ${val} 条`);
this.$data.pagesize = val;
this.$data.currentPage = 1;
var beginTime= '';
var endTime = '';

View File

@ -537,7 +537,7 @@
handleSizeChange(val) {
this.$data.pagesize = val;
this.$data.currentPage = 1;
var _this = this;
var objs;

View File

@ -520,7 +520,7 @@
handleSizeChange(val) {
this.$data.pagesize = val;
this.$data.currentPage = 1;
var _this = this;
var objs;

View File

@ -305,7 +305,7 @@ history.pushState(null, null, document.URL);
handleSizeChange(val) {
this.$data.pagesize = val;
this.$data.currentPage = 1;
if (this.$data.begin_t != '' && this.$data.end_t != '' && this.$data.begin_t>this.$data.end_t) {
this.$message({
message: 'The end time must be after the start time!',

View File

@ -339,7 +339,7 @@ history.pushState(null, null, document.URL);
handleSizeChange(val) {
this.$data.pagesize = val;
this.$data.currentPage = 1;
if (this.$data.begin_t != '' && this.$data.end_t != '' && this.$data.begin_t>this.$data.end_t) {
this.$message({
message: '结束时间必须在开始时间之后!',

View File

@ -481,7 +481,7 @@
handleSizeChange(val) {
this.$data.pagesize = val;
this.$data.currentPage = 1;
if (this.$data.begin_t != '' && this.$data.end_t != '' && this.$data.begin_t>this.$data.end_t) {
this.$message({
message: 'The end time must be after the start time!',

View File

@ -481,7 +481,7 @@
handleSizeChange(val) {
this.$data.pagesize = val;
this.$data.currentPage = 1;
if (this.$data.begin_t != '' && this.$data.end_t != '' && this.$data.begin_t>this.$data.end_t) {
this.$message({
message: '结束时间必须在开始时间之后!',

View File

@ -342,7 +342,7 @@ history.pushState(null, null, document.URL);
handleSizeChange(val) {
this.$data.pagesize = val;
this.$data.currentPage = 1;
if (this.$data.begin_t != '' && this.$data.end_t != '' && this.$data.begin_t>this.$data.end_t) {
this.$message({
message: 'The end time must be after the start time!',

View File

@ -564,7 +564,7 @@ history.pushState(null, null, document.URL);
handleSizeChange(val) {
this.$data.pagesize = val;
this.$data.currentPage = 1;
if (this.$data.begin_t != '' && this.$data.end_t != '' && this.$data.begin_t>this.$data.end_t) {
this.$message({
message: '结束时间必须在开始时间之后!',

View File

@ -283,7 +283,7 @@
handleSizeChange(val) {
var beginTime= '';
var endTime = '';
this.$data.currentPage = 1;
if (this.$data.date_value != null && this.$data.date_value.length > 1) {
console.log("len:",this.$data.date_value.length)
console.log("date_value:",this.$data.date_value);

View File

@ -283,7 +283,7 @@
handleSizeChange(val) {
var beginTime= '';
var endTime = '';
this.$data.currentPage = 1;
if (this.$data.date_value != null && this.$data.date_value.length > 1) {
console.log("len:",this.$data.date_value.length)
console.log("date_value:",this.$data.date_value);

View File

@ -244,7 +244,7 @@
handleSizeChange(val) {
//console.log(`每页 ${val} 条`);
this.$data.pagesize = val;
this.$data.currentPage = 1;
if (this.$data.begin_t != '' && this.$data.end_t != '' && this.$data.begin_t>this.$data.end_t) {
this.$message({
message: 'The end time must be after the start time!',

View File

@ -245,7 +245,7 @@
handleSizeChange(val) {
//console.log(`每页 ${val} 条`);
this.$data.pagesize = val;
this.$data.currentPage = 1;
if (this.$data.begin_t != '' && this.$data.end_t != '' && this.$data.begin_t>this.$data.end_t) {
this.$message({
message: '结束时间必须在开始时间之后!',

View File

@ -129,7 +129,7 @@
handleSizeChange(val) {
this.$data.pagesize = val;
this.$data.currentPage = 1;
var _this = this;
var objs;

View File

@ -128,7 +128,7 @@
handleSizeChange(val) {
this.$data.pagesize = val;
this.$data.currentPage = 1;
var _this = this;
var objs;

View File

@ -577,7 +577,7 @@
handleSizeChange(val) {
this.$data.pagesize = val;
this.$data.currentPage = 1;
var _this = this;
var objs;

View File

@ -575,7 +575,7 @@
handleSizeChange(val) {
this.$data.pagesize = val;
this.$data.currentPage = 1;
var _this = this;
var objs;

View File

@ -358,7 +358,7 @@
this.$data.pagesize = val;
var _this = this;
this.$data.currentPage = 1;
var objs;
axios.post('/deescloud/getMss_en', {
opuser:localStorage.getItem("online_user"),

View File

@ -376,7 +376,8 @@
handleSizeChange(val) {
this.$data.pagesize = val;
// 添加:重置到第一页
this.$data.currentPage = 1;
var _this = this;
var objs;

View File

@ -1010,7 +1010,7 @@
handleSizeChange(val) {
//console.log(`每页 ${val} 条`);
this.$data.pagesize = val;
this.$data.currentPage = 1;
var _this = this;
var objs;

View File

@ -1030,7 +1030,7 @@
handleSizeChange(val) {
//console.log(`每页 ${val} 条`);
this.$data.pagesize = val;
this.$data.currentPage = 1;
var _this = this;
var objs;

View File

@ -48,7 +48,7 @@
style="margin-left: 10px"
v-model="scope.row.pumpExport"
@change="(value) => handlePumpExportChange(value, scope.row)">
<span style="color: green">导出泵</span>
<span style="color: #409EFF">泵信息</span>
</el-checkbox>
</template>
</el-table-column>
@ -261,7 +261,7 @@
handleSizeChange(val) {
//console.log(`每页 ${val} 条`);
this.$data.pagesize = val;
this.$data.currentPage = 1;
var _this = this;
var objs;

View File

@ -253,7 +253,7 @@
handleSizeChange(val) {
//console.log(`每页 ${val} 条`);
this.$data.pagesize = val;
this.$data.currentPage = 1;
var _this = this;
var objs;

View File

@ -193,7 +193,7 @@ history.pushState(null, null, document.URL);
},
handleSizeChange(val) {
this.$data.pagesize = val;
this.$data.currentPage = 1;
var _this = this;
var objs;

View File

@ -191,7 +191,7 @@ history.pushState(null, null, document.URL);
handleSizeChange(val) {
this.$data.pagesize = val;
this.$data.currentPage = 1;
var _this = this;
var objs;

1911
scripts/tool_detail-en.js Normal file

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -69,51 +69,86 @@
</el-pagination>
</div>
<!-- 仪器状态弹窗 -->
<el-dialog
title="Instrument Status Information"
title="Instrument Status Message"
:visible.sync="pdf_visible"
:lock-scroll ="false"
:lock-scroll="false"
:append-to-body="true"
width="60%">
<div style="height: 450px;overflow: auto;">
<div v-if="tool_warning_data.length>0">
<div>Risk warning: </div>
<div v-for="item in tool_warning_data">
<div style="display: flex;padding-top: 10px;">
<div style="width: 100%;">
{{item.time}}
&nbsp;{{item.err_level}}:
&nbsp;{{item.context}}
width="60%"
>
<div style="height: 450px; overflow: auto;">
<div v-if="tool_warning_data.length > 0">
<div>Risk warning:</div>
<div v-for="item in tool_warning_data" :key="item.id">
<div style="display: flex; padding-top: 10px; align-items: center;">
<div
style="width: 100%;"
:style="{ color: item.flag === 1 ? 'red' : 'inherit' }"
>
<span style="font-weight: 500;">
<template v-if="item.flag === 0">
&nbsp;&nbsp;{{ item.series_num }} {{ item.instrument_id }} | Normal
</template>
</span>
<template v-if="item.flag === 1">
<span style="margin-left: 6px;">
{{ item.time }} | {{ item.context }}
</span>
</template>
<el-button
v-if="item.series_num"
@click="openDetail(item)"
type="text"
size="medium"
style="margin-left: 12px; padding: 0 4px;"
>
Details
</el-button>
</div>
</div>
</div>
</div>
<div v-if="tool_warning_data.length==0">
<div>The instruments in this well are working normally.</div>
<div v-if="tool_warning_data.length == 0">
<div>The instruments in this well are working normally</div>
</div>
<el-divider></el-divider>
</div>
</el-dialog>
</div>
`,
data(){
// 获取当前屏幕的分辨率
let screenW = window.screen.width;
let screenH = window.innerHeight;
console.log("screen width:",screenW);
console.log("screen height:",screenH);
console.log("screen width:", screenW);
console.log("screen height:", screenH);
return {
tHeight:screenH-192,
tHeight: screenH - 192,
tableData: Array(0),
input:'',
input: '',
currentPage: 1,
pagesize:50,
recordTotal:0,
pdf_visible:false,
tool_warning_data:{},
checked:false,
}
pagesize: 50,
recordTotal: 0,
pdf_visible: false,
tool_warning_data: [],
checked: false,
currentWellName: '' // 新增:存储当前查看的井名
};
},
mounted() {
var _this = this;
@ -151,7 +186,27 @@
var fileid = response.data.fileId;
var downUrl = 'file/'+fileid;
downloadUrl(row.wellNameSource+"-Instrument status report.pdf",downUrl);
downloadUrl(row.wellNameSource+"_Instrument status report.pdf",downUrl);
})
.catch(function (error) {
console.log(error);
});
},
export_mess_pdf(row) {
var _this = this;
axios.post('deescloud/get_tool_warning_pdf_en', {
opuser: localStorage.getItem("online_user"),
opuser_uuid: localStorage.getItem("uuid"),
wellname: row.wellNameSource
})
.then(function (response) {
console.log(response.data);
var fileid = response.data.fileId;
var downUrl = 'file/' + fileid;
console.log("downUrl-----------",downUrl);
console.log("wellNameSource-----------",row.wellNameSource);
downloadUrl(row.wellNameSource + "_Instrument status report.pdf", downUrl);
})
.catch(function (error) {
console.log(error);
@ -159,6 +214,7 @@
},
show_pdf(row){
let _this= this;
this.currentWellName = row.wellNameSource;
axios.post('/deescloud/get_tool_warning_en', {
opuser:localStorage.getItem("online_user"),
opuser_uuid:localStorage.getItem("uuid"),
@ -205,7 +261,7 @@
handleSizeChange(val) {
//console.log(`每页 ${val} 条`);
this.$data.pagesize = val;
this.$data.currentPage = 1;
var _this = this;
var objs;
@ -256,6 +312,33 @@
},
// 新增:打开详情页方法
openDetail(item) {
// 使用当前井名和预警项ID构建详情页URL
const wellName = this.currentWellName; // 不要预先编码
// 使用预警ID或时间戳作为唯一标识
// 构建基础URL参数留待URLSearchParams处理
const detailUrl = 'tool_detail-en.html';
// 使用URLSearchParams自动处理编码
const params = new URLSearchParams({
well: wellName,
id: item.opuser_uuid,
name : item.name,
series: item.series_num,
instrument: item.instrument_id,
flag:item.flag,
content: item.context || ''
});
// 完整URL
const fullUrl = `${detailUrl}?${params.toString()}`;
// 在新标签页打开详情页
window.open(fullUrl, '_blank');
}
}
}

View File

@ -22,7 +22,7 @@ var toolscomponent = {
<el-table-column prop="welltime" label="建井时间" :width="170"></el-table-column>
<el-table-column prop="welloperator" label="操作用户" :width="150" :show-overflow-tooltip="true"></el-table-column>
<el-table-column prop="upload_user" label="上传用户" :width="150" :show-overflow-tooltip="true"></el-table-column>
<el-table-column label="操作" width="240">
<el-table-column label="操作" width="200">
<template slot-scope="scope">
<div style="flex: 1; display: inline-flex;">
<div v-if="!scope.row.tsw">
@ -31,8 +31,8 @@ var toolscomponent = {
</svg>
</div>
<el-button @click="show_pdf(scope.row)" type="text" size="medium">报告明细</el-button>
<el-button @click="export_pdf(scope.row)" type="text" size="medium">导出</el-button>
<el-button @click="export_mess_pdf(scope.row)" type="text" size="medium">仪器报告导出</el-button>
<!-- <el-button @click="export_pdf(scope.row)" type="text" size="medium">导出</el-button> -->
<el-button @click="export_mess_pdf(scope.row)" type="text" size="medium">导出</el-button>
</div>
</template>
</el-table-column>
@ -63,7 +63,6 @@ var toolscomponent = {
width="60%"
>
<div style="height: 450px; overflow: auto;">
<div v-if="tool_warning_data.length > 0">
<div>风险预警:</div>
@ -78,17 +77,13 @@ var toolscomponent = {
>
<span style="font-weight: 500;">
<template v-if="item.flag === 0">
{{ item.series_num }} {{ item.instrument_id }} | 仪器正常
</template>
<template v-else>
{{ item.time }} | {{ item.series_num }} |
&nbsp;&nbsp;{{ item.series_num }} {{ item.instrument_id }} | 仪器正常
</template>
</span>
<template v-if="item.flag === 1">
<span style="margin-left: 6px;">
{{ item.err_level }} | {{ item.context }}
{{ item.time }} | {{ item.context }}
</span>
</template>
@ -109,7 +104,7 @@ var toolscomponent = {
</div>
<div v-if="tool_warning_data.length == 0">
<div>本口井仪器工作正常</div>
<div>本口井未上传仪器信息</div>
</div>
<el-divider></el-divider>
</div>
@ -117,7 +112,6 @@ var toolscomponent = {
</div>
`,
data() {
// 获取当前屏幕的分辨率
let screenW = window.screen.width;
let screenH = window.innerHeight;
console.log("screen width:", screenW);
@ -169,7 +163,9 @@ var toolscomponent = {
console.log(response.data);
var fileid = response.data.fileId;
var downUrl = 'file/' + fileid;
downloadUrl(row.wellNameSource + "-仪器状态报告.pdf", downUrl);
console.log("downUrl-----------",downUrl);
console.log("wellNameSource-----------",row.wellNameSource);
downloadUrl(row.wellNameSource + "_仪器状态报告.pdf", downUrl);
})
.catch(function (error) {
console.log(error);
@ -179,7 +175,7 @@ var toolscomponent = {
export_mess_pdf(row) {
var _this = this;
axios.post('deescloud/get_tool_mess_pdf', {
axios.post('deescloud/get_tool_warning_pdf', {
opuser: localStorage.getItem("online_user"),
opuser_uuid: localStorage.getItem("uuid"),
wellname: row.wellNameSource
@ -188,7 +184,9 @@ var toolscomponent = {
console.log(response.data);
var fileid = response.data.fileId;
var downUrl = 'file/' + fileid;
// downloadUrl(row.wellNameSource + "-仪器报告.pdf", downUrl);
console.log("downUrl-----------",downUrl);
console.log("wellNameSource-----------",row.wellNameSource);
downloadUrl(row.wellNameSource + "_仪器报告.pdf", downUrl);
})
.catch(function (error) {
console.log(error);
@ -245,7 +243,7 @@ var toolscomponent = {
handleSizeChange(val) {
this.$data.pagesize = val;
var _this = this;
this.$data.currentPage = 1;
var objs;
axios.post('/deescloud/get_well_tool', {
opuser: localStorage.getItem("online_user"),
@ -291,8 +289,6 @@ var toolscomponent = {
console.log(error);
});
},
// 新增:打开详情页方法
// 新增:打开详情页方法
openDetail(item) {
// 使用当前井名和预警项ID构建详情页URL
@ -310,7 +306,7 @@ var toolscomponent = {
series: item.series_num,
instrument: item.instrument_id,
flag:item.flag,
content: item.content || ''
content: item.context || ''
});
// 完整URL

View File

@ -261,7 +261,7 @@
handleSizeChange(val) {
this.$data.pagesize = val;
this.$data.currentPage = 1;
var _this = this;
var objs;

View File

@ -263,7 +263,7 @@
handleSizeChange(val) {
this.$data.pagesize = val;
this.$data.currentPage = 1;
var _this = this;
var objs;

View File

@ -182,7 +182,7 @@
handleSizeChange(val) {
this.$data.pagesize = val;
this.$data.currentPage = 1;
var beginTime= '';
var endTime = '';

View File

@ -182,7 +182,7 @@
handleSizeChange(val) {
this.$data.pagesize = val;
this.$data.currentPage = 1;
var beginTime= '';
var endTime = '';

View File

@ -188,7 +188,7 @@
handleSizeChange(val) {
//console.log(`每页 ${val} 条`);
this.$data.pagesize = val;
this.$data.currentPage = 1;
var _this = this;
var objs;

View File

@ -394,7 +394,7 @@
handleSizeChange(val) {
this.$data.pagesize = val;
this.$data.currentPage = 1;
var _this = this;
var objs;

View File

@ -405,7 +405,7 @@
handleSizeChange(val) {
//console.log(`每页 ${val} 条`);
this.$data.pagesize = val;
this.$data.currentPage = 1;
var _this = this;
var objs;

View File

@ -397,7 +397,7 @@
handleSizeChange(val) {
//console.log(`每页 ${val} 条`);
this.$data.pagesize = val;
this.$data.currentPage = 1;
var _this = this;
var objs;

View File

@ -401,7 +401,7 @@
handleSizeChange(val) {
//console.log(`每页 ${val} 条`);
this.$data.pagesize = val;
this.$data.currentPage = 1;
var _this = this;
var objs;

View File

@ -315,7 +315,7 @@
handleSizeChange(val) {
//console.log(`每页 ${val} 条`);
this.$data.pagesize = val;
this.$data.currentPage = 1;
if (this.$data.begin_t != '' && this.$data.end_t != '' && this.$data.begin_t>this.$data.end_t) {
this.$message({
message: 'The end time must be later than start time!',

View File

@ -1,11 +1,11 @@
//组件
var WellHistorycomponent = {
var WellHistorycomponent = {
template:`
<div style="height: 100%;width: 100%;">
<div v-show="if_show0">
<div id="" style="display: inline-block;width: 100%;margin-top: 10px;">
<div style="float: left;display: flex;background-color: #ECF5FF;">
<el-input v-model="input" placeholder="请输入井名" clearable ></el-input>
<el-input v-model="input" placeholder="请输入井名" clearable style="width: 150px;"></el-input>
</div>
<div style="float: left;display: flex;background-color: #ECF5FF;">
<el-date-picker
@ -58,6 +58,23 @@
value-format="yyyy-MM-dd HH:mm:ss">
</el-date-picker>
</div>
<!-- 新增类型筛选下拉框多选 -->
<div style="float: left;display: flex;background-color: #ECF5FF;">
<el-select
v-model="selectedTypes"
multiple
collapse-tags
placeholder="请选择井测试类型"
clearable
style="width: 220px;">
<el-option
v-for="item in typeOptions"
:key="item.value"
:label="item.label"
:value="item.value">
</el-option>
</el-select>
</div>
<div style="float: left;margin-left: 5px;">
<el-checkbox style="background-color: #ECF5FF;" v-model="checked" label="工程服务" border></el-checkbox>
</div>
@ -89,12 +106,18 @@
label="建井时间"
:width="170">
</el-table-column>
<el-table-column
prop="welloperator"
label="操作用户"
:width="150"
:show-overflow-tooltip="true">
</el-table-column>
<!-- 修改将井测试类型列改为普通文本列以保持与其他列样式一致 -->
<el-table-column
prop="type_name"
label="井测试类型"
:width="200"
:show-overflow-tooltip="true">
</el-table-column>
<el-table-column
label="操作"
@ -106,9 +129,7 @@
</div>
<el-button @click="handleClick(scope.row)" type="text" size="medium">历史详情</el-button>
<el-button @click="exportWellHis(scope.row)" type="text" size="medium">导出</el-button>
</div>
</template>
</el-table-column>
</el-table>
@ -189,6 +210,19 @@
if_show_et:false,
checked:false,
// 新增:类型筛选相关
selectedTypes: [], // 选中的类型值数组,如 [0, 2, 5]
typeOptions: [
{ value: 0, label: '测斜' },
{ value: 1, label: '近钻头' },
{ value: 2, label: '电阻率' },
{ value: 3, label: '探管式方位伽马' },
{ value: 4, label: '钻铤式方位伽马' },
{ value: 5, label: '自然伽马' },
{ value: 6, label: '工程参数' },
{ value: 7, label: '振动粘滑' }
]
}
},
mounted() {
@ -223,26 +257,50 @@
console.log(error);
});
var objs;
// 初始化加载数据
this.fetchData();
},
methods: {
// 新增:将选中的类型数组转换为位掩码
getTypeMask() {
let mask = 0;
if (this.selectedTypes && this.selectedTypes.length > 0) {
this.selectedTypes.forEach(val => {
mask |= (1 << val);
});
}
return mask;
},
// 新增:统一的查询数据方法
fetchData() {
var _this = this;
// 获取类型位掩码
const typeMask = this.getTypeMask();
axios.post('/deescloud/get_well_history', {
opuser:localStorage.getItem("online_user"),
opuser_uuid:localStorage.getItem("uuid"),
index: this.$data.currentPage,
count: this.$data.pagesize,
checked:this.$data.checked
opuser: localStorage.getItem("online_user"),
opuser_uuid: localStorage.getItem("uuid"),
Wellname: this.input,
index: this.currentPage,
count: this.pagesize,
BeginTime: this.begin_t,
EndTime: this.end_t,
checked: this.checked,
type: typeMask // 新增:传递类型筛选参数
})
.then(function (response) {
console.log(response.data);
objs = response.data.data;
rcnt = response.data.total;
_this.$data.tableData = objs;
_this.$data.recordTotal = rcnt;
_this.tableData = response.data.data || [];
_this.recordTotal = response.data.total || 0;
})
.catch(function (error) {
console.log(error);
_this.$message.error('查询失败,请稍后重试');
});
},
methods: {
export_his(){
this.$data.dialogVisible=false;
@ -279,9 +337,9 @@
document.getElementById("bt_serach").blur();
this.$data.currentPage=1;
this.currentPage = 1;
if (this.$data.begin_t != '' && this.$data.end_t != '' && this.$data.begin_t>this.$data.end_t) {
if (this.begin_t != '' && this.end_t != '' && this.begin_t > this.end_t) {
this.$message({
message: '结束时间必须在开始时间之后!',
type: 'warning',
@ -290,37 +348,15 @@
return;
}
var _this = this;
var objs;
axios.post('/deescloud/get_well_history', {
opuser:localStorage.getItem("online_user"),
opuser_uuid:localStorage.getItem("uuid"),
Wellname: _search_name,
index: this.$data.currentPage,
count: this.$data.pagesize,
BeginTime:this.$data.begin_t,
EndTime:this.$data.end_t,
checked:this.$data.checked
})
.then(function (response) {
console.log(response.data);
objs = response.data.data;
rcnt = response.data.total;
_this.$data.tableData = objs;
_this.$data.recordTotal = rcnt;
})
.catch(function (error) {
console.log(error);
});
// 调用统一的查询方法
this.fetchData();
},
handleSizeChange(val) {
//console.log(`每页 ${val} 条`);
this.$data.pagesize = val;
this.pagesize = val;
this.currentPage = 1;
if (this.$data.begin_t != '' && this.$data.end_t != '' && this.$data.begin_t>this.$data.end_t) {
if (this.begin_t != '' && this.end_t != '' && this.begin_t > this.end_t) {
this.$message({
message: '结束时间必须在开始时间之后!',
type: 'warning',
@ -329,35 +365,13 @@
return;
}
var _this = this;
var objs;
axios.post('/deescloud/get_well_history', {
opuser:localStorage.getItem("online_user"),
opuser_uuid:localStorage.getItem("uuid"),
Wellname: this.$data.input,
index: this.$data.currentPage,
count: this.$data.pagesize,
BeginTime:this.$data.begin_t,
EndTime:this.$data.end_t,
checked:this.$data.checked
})
.then(function (response) {
console.log(response.data);
objs = response.data.data;
rcnt = response.data.total;
_this.$data.tableData = objs;
_this.$data.recordTotal = rcnt;
})
.catch(function (error) {
console.log(error);
});
this.fetchData();
},
handleCurrentChange(val) {
//console.log(`当前页: ${val}`);
this.$data.currentPage = val;
if (this.$data.begin_t != '' && this.$data.end_t != '' && this.$data.begin_t>this.$data.end_t) {
handleCurrentChange(val) {
this.currentPage = val;
if (this.begin_t != '' && this.end_t != '' && this.begin_t > this.end_t) {
this.$message({
message: '结束时间必须在开始时间之后!',
type: 'warning',
@ -366,29 +380,7 @@
return;
}
var _this = this;
var objs;
axios.post('/deescloud/get_well_history', {
opuser:localStorage.getItem("online_user"),
opuser_uuid:localStorage.getItem("uuid"),
Wellname: this.$data.input,
index: this.$data.currentPage,
count: this.$data.pagesize,
BeginTime:this.$data.begin_t,
EndTime:this.$data.end_t,
checked:this.$data.checked
})
.then(function (response) {
console.log(response.data);
objs = response.data.data;
rcnt = response.data.total;
_this.$data.tableData = objs;
_this.$data.recordTotal = rcnt;
})
.catch(function (error) {
console.log(error);
});
this.fetchData();
},
handleClick(row){
@ -478,6 +470,5 @@
console.log("max_flex_width:",max_flex_width);
return max_flex_width + 'px'
},
}
}
}

View File

@ -408,7 +408,7 @@ export_pdf(row, is_memory = false) {
handleSizeChange(val) {
this.$data.pagesize = val;
this.$data.currentPage = 1;
var beginTime= '';
var endTime = '';

View File

@ -390,7 +390,7 @@ var Welltypecomponent = {
handleSizeChange(val) {
this.$data.pagesize = val;
this.$data.currentPage = 1;
var beginTime= '';
var endTime = '';

File diff suppressed because one or more lines are too long

610
tool_detail-en.html Normal file
View File

@ -0,0 +1,610 @@
<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Summary of Instrument Information</title>
<style>
* {
margin: 0;
padding: 0;
box-sizing: border-box;
font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}
body {
background: white;
min-height: 100vh;
display: flex;
justify-content: center;
align-items: center;
padding: 20px;
}
.container {
width: 100%;
max-width: 1200px;
background: white;
padding: 40px;
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}
header {
text-align: center;
margin-bottom: 40px;
padding-bottom: 20px;
border-bottom: 1px solid #eee;
}
h1 {
font-size: 2.5rem;
font-weight: 600;
color: #222;
margin-bottom: 10px;
}
.subtitle {
font-size: 1.1rem;
color: #666;
}
.info-section {
margin-bottom: 30px;
padding: 20px;
border: 1px solid #e0e0e0;
border-radius: 5px;
}
.file-item a {
font-size: 14px;
text-decoration: none;
}
/* 基本信息无边框表格样式 */
.basic-info-table {
width: 100%;
border-collapse: collapse;
margin-top: 20px;
margin-left: auto;
margin-right: auto;
}
.basic-info-table th,
.basic-info-table td {
padding: 15px 20px;
text-align: left;
font-size: 1.1rem;
font-weight: 500;
color: #333;
}
.basic-info-table th {
background-color: transparent;
}
/* 其他表格样式保持不变 */
.info-table {
width: 100%;
border-collapse: collapse;
margin-top: 20px;
table-layout: fixed;
}
.info-table th,
.info-table td {
padding: 15px;
text-align: center;
border: 1px solid #e0e0e0;
}
.info-table th {
background-color: #f5f7fa;
font-weight: 400;
color: #333;
}
.info-table td {
font-size: 1.1rem;
font-weight: 500;
color: #222;
}
/* 固定宽度列样式 */
.fixed-width-260 {
width: 200px;
}
.fixed-width-160 {
width: 160px;
}
.fixed-width-180 {
width: 180px;
}
.fixed-width-90 {
width: 90px;
}
.fixed-width-100 {
width: 100px;
}
.fixed-width-80 {
width: 80px;
}
.fixed-width-40 {
width: 40px;
}
/* 表格内容换行样式 */
.table-cell-wrap {
word-wrap: break-word;
word-break: break-all;
white-space: normal;
}
.info-row {
display: flex;
margin-bottom: 25px;
flex-wrap: wrap;
}
.info-item {
width: 100%;
margin-bottom: 20px;
}
.info-label {
font-size: 1.1rem;
font-weight: 500;
color: #333;
margin-bottom: 8px;
text-align: center;
}
.info-value {
font-size: 1.1rem;
color: #333;
padding: 8px 0;
text-align: center;
}
.stat-card {
border: 1px solid #e0e0e0;
border-radius: 4px;
padding: 15px;
margin-top: 10px;
text-align: center;
}
.stat-title {
font-size: 1rem;
color: #555;
margin-bottom: 10px;
}
.stat-value {
font-size: 1.8rem;
font-weight: 700;
}
footer {
text-align: center;
padding: 20px 0;
color: #777;
font-size: 0.9rem;
border-top: 1px solid #eee;
margin-top: 40px;
}
/* 内部组件样式 */
.component-item {
display: flex;
margin-bottom: 15px;
padding: 12px 0;
border-bottom: 1px solid #f0f0f0;
}
.component-item:last-child {
border-bottom: none;
}
.component-name {
width: 150px;
font-weight: 400;
color: #444;
padding-right: 10px;
}
.component-detail {
flex: 1;
color: #666;
}
.quality-item {
margin-bottom: 15px;
padding: 10px 0;
border-bottom: 1px solid #f0f0f0;
}
.quality-header {
display: flex;
align-items: center;
width: 100%;
}
.quality-title {
font-size: 1.1rem;
color: #333;
font-weight: 500;
width: auto;
padding-right: 10px;
margin-left: 40px;
flex-shrink: 0;
}
.quality-display {
flex: 1;
padding: 6px 12px;
min-height: 20px;
margin-right: 10px;
}
.edit-btn {
padding: 6px 12px;
background-color: #409eff;
border: 1px solid #409eff;
border-radius: 4px;
color: white;
font-size: 14px;
cursor: pointer;
flex-shrink: 0;
}
.edit-input {
flex: 1;
padding: 6px 12px;
border: 1px solid #dcdfe6;
border-radius: 4px;
font-size: 14px;
margin-right: 10px;
min-width: 200px;
}
.confirm-btn {
background-color: #67c23a;
border-color: #67c23a;
}
/* 文件列表样式 */
.file-list {
margin-top: 10px;
text-align: left;
}
.file-item {
display: flex;
align-items: center;
padding: 5px 0;
}
.file-item a {
color: #409eff;
text-decoration: none;
margin-left: 5px;
}
.file-item a:hover {
text-decoration: underline;
}
.file-icon {
color: #409eff;
margin-right: 5px;
}
/* 文件列表样式 */
.file-list {
margin-top: 10px;
text-align: left;
}
.file-item {
display: flex;
align-items: center;
padding: 5px 0;
}
.file-item a {
color: #409eff;
text-decoration: none;
margin-left: 5px;
}
.file-item a:hover {
text-decoration: underline;
}
.file-icon {
color: #409eff;
margin-right: 5px;
}
/* 文件列样式 */
.file-column {
text-align: left;
}
.upload-button {
background-color: #409eff;
border: 1px solid #409eff;
border-radius: 4px;
color: white;
padding: 6px 12px;
font-size: 14px;
cursor: pointer;
transition: all 0.3s;
}
.upload-button:hover {
background-color: #66b1ff;
border-color: #66b1ff;
}
.upload-button:disabled {
background-color: #a0cfff;
border-color: #a0cfff;
cursor: not-allowed;
}
.fixed-width-40 {
width: 50px;
}
.fixed-width-80 {
width: 80px;
}
.fixed-width-140 {
width: 140px;
}
.fixed-width-130 {
width: 130px;
}
.fixed-width-180 {
width: 180px;
}
.link-container {
display: flex;
align-items: center;
flex-wrap: wrap;
}
.link-display, .link-input {
flex: 1;
min-width: 0; /* 允许输入框收缩 */
white-space: normal; /* 允许换行 */
word-wrap: break-word; /* 长单词换行 */
}
.edit-link-btn, .confirm-link-btn {
flex-shrink: 0; /* 防止按钮被压缩 */
margin-left: 5px;
}
/* 当输入框显示时,使用不同的布局 */
.link-input {
margin-right: 5px;
}
.confirm-link-btn {
margin-left: 0;
}
@media (max-width: 768px) {
.container {
padding: 20px;
}
h1 {
font-size: 2rem;
}
.info-table th,
.info-table td {
padding: 10px 5px;
font-size: 0.9rem;
}
.info-table td {
font-size: 1rem;
}
.component-item {
flex-direction: column;
}
.component-name {
width: 100%;
margin-bottom: 5px;
}
}
</style>
</head>
<script src="scripts/checkuser.js"></script>
<script src="./scripts/tool_detail-en.js"></script>
<script src="scripts/axiosmin.js"></script>
<script src="./scripts/polyfill.js"></script>
<script src="./scripts/vue.min.js"></script>
<script src="./scripts/vue-router.js"></script>
<body>
<div class="container">
<header>
<h1></h1>
</header>
<div class="content">
<div style="text-align: left; margin-bottom: 20px; font-size: 1.2rem; font-weight: 400;">
Instrument Name: <span id="seriesNum"></span>
</div>
<div class="info-section">
<h2 class="info-label">Basic Information</h2>
<div style="padding: 0 20px;">
<table class="basic-info-table">
<tbody>
<tr>
<th>Date Of Manufacture:</th>
<td></td>
<th>Date Of Warehousing:</th>
<td></td>
</tr>
<tr>
<td>Total Working Time:</td>
<td></td>
<td>Current Working Time:</td>
<td></td>
</tr>
<tr>
<td>Firmware Version:</td>
<td colspan="3"></td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="info-section">
<h2 class="info-label">Product Quality Inspection Record</h2>
<div style="padding: 15px 0;">
<!-- 生产过程记录 -->
<div class="quality-item">
<div class="quality-header">
<div class="quality-title">Production Process Record:</div>
<div class="quality-display" id="processRecordDisplay"></div>
<button id="editProcessRecord" class="edit-btn" style="margin-right: 120px;">Redact</button>
</div>
</div>
<!-- 生产过程检验 -->
<div class="quality-item">
<div class="quality-header">
<div class="quality-title">Production Process Inspection:</div>
<div class="quality-display" id="processInspectionDisplay"></div>
<button id="editProcessInspection" class="edit-btn" style="margin-right: 120px;">Redact</button>
</div>
</div>
<!-- 成品检验记录 -->
<div class="quality-item">
<div class="quality-header">
<div class="quality-title">Final Inspection Display:</div>
<div class="quality-display" id="finalInspectionDisplay"></div>
<button id="editFinalInspection" class="edit-btn" style="margin-right: 120px;">Redact</button>
</div>
</div>
</div>
</div>
<div class="info-section">
<h2 class="info-label">Summary Of Instrument Construction</h2>
<table class="info-table">
<thead>
<tr>
<th class="table-cell-wrap">Well Name</th>
<th class="table-cell-wrap">Well Work Situation</th>
<th class="fixed-width-130 table-cell-wrap">Well Section</th>
<th class="table-cell-wrap">Max Temp</th>
<th class="fixed-width-130 table-cell-wrap">Max Pressure</th>
<th class="fixed-width-80 table-cell-wrap">Status</th>
<th class="table-cell-wrap">Person</th>
<th class="table-cell-wrap">File</th>
<th class="fixed-width-180 table-cell-wrap">Link</th>
</tr>
</thead>
<tbody id="wellDataBody">
</tbody>
</table>
</div>
<div class="info-section">
<div style="display: flex; justify-content: space-between; align-items: center;">
<div style="flex: 1;"></div>
<h2 class="info-label" style="flex: 1; text-align: center;">Maintenance And Repair Situation</h2>
<div style="flex: 1; display: flex; justify-content: flex-end;">
<button id="bt_add" style="margin-left: 5px; padding: 8px 16px; background-color: #67c23a; border: 1px solid #67c23a; border-radius: 4px; color: white; font-size: 14px; cursor: pointer; display: inline-flex; align-items: center;" onclick="addMaintenanceRecord()">
<i style="margin-right: 5px;">
<svg viewBox="0 0 1024 1024" width="14" height="14" fill="currentColor">
<path d="M512 128C304.3 128 128 304.3 128 512s176.3 384 384 384 384-176.3 384-384S719.7 128 512 128z m0 64c176.7 0 320 143.3 320 320s-143.3 320-320 320S192 688.7 192 512 335.3 192 512 192z m48 304h-96v96h-96v-96H320v-96h96v-96h96v96h96v96z"></path>
</svg>
</i>
Add
</button>
</div>
</div>
<table class="info-table">
<thead>
<tr>
<th class="fixed-width-100 table-cell-wrap">Time</th>
<th class="fixed-width-40 table-cell-wrap">Level</th>
<th class="fixed-width-160 table-cell-wrap">Maintenance Info</th>
<th class="fixed-width-90 table-cell-wrap">Maintenance Person</th>
<th class="fixed-width-160 table-cell-wrap">File</th>
<th class="fixed-width-260 table-cell-wrap">Link</th>
</tr>
</thead>
<tbody id="maintenanceDataBody">
<tr>
<td colspan="6" style="text-align: center;">No Data</td>
</tr>
</tbody>
</table>
</div>
<div class="info-section">
<h2 class="info-label">Internal Components</h2>
<div class="no-data">No Data</div>
</div>
<div class="info-section">
<h2 class="info-label">The Department To Which The Instrument Belongs</h2>
<div class="component-item">
<div class="component-name" id="deptContainer" style="width: auto; white-space: nowrap;">No Data</div>
</div>
</div>
</div>
<footer>
<p>All rights reserved © Beijing Liuhe Weiye Technology Co., LTD</p>
</footer>
</div>
<script>
// 获取URL参数
function getUrlParameter(name) {
name = name.replace(/[\[\]]/g, '\\$&');
const regex = new RegExp('[?&]' + name + '(=([^&#]*)|&|#|$)');
const results = regex.exec(window.location.href);
if (!results) return null;
if (!results[2]) return '';
return decodeURIComponent(results[2].replace(/\+/g, ' '));
}
// 设置序列号
document.addEventListener('DOMContentLoaded', function() {
const seriesNum = getUrlParameter('series');
const instrument = getUrlParameter('instrument');
if (seriesNum) {
document.getElementById('seriesNum').textContent = seriesNum + '1'+ instrument;
}
});
</script>
</body>
</html>

View File

@ -4,528 +4,551 @@
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>仪器信息汇总</title>
<script src="./scripts/polyfill.js"></script>
<script src="./scripts/vue.min.js"></script>
<script src="./scripts/vue-router.js"></script>
<script src="./scripts/elementindex.js"></script>
<link rel="stylesheet" href="./scripts/elementindex.css">
<script src="scripts/axiosmin.js"></script>
<script src="scripts/checkuser.js"></script>
<style>
* {
margin: 0;
padding: 0;
box-sizing: border-box;
font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}
body {
background: white;
min-height: 100vh;
display: flex;
justify-content: center;
align-items: center;
background-color: rgb(18,25,34);
margin: 0;
font-family: "Microsoft YaHei", Arial, Helvetica, sans-serif, "宋体";
color: rgb(255,255,0);
}
.homeWrap {
padding: 20px;
}
.container {
width: 100%;
max-width: 1200px;
background: white;
padding: 40px;
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}
header {
.page-header {
text-align: center;
margin-bottom: 40px;
padding-bottom: 20px;
border-bottom: 1px solid #eee;
}
h1 {
font-size: 2.5rem;
font-weight: 600;
color: #222;
margin-bottom: 10px;
}
.subtitle {
font-size: 1.1rem;
color: #666;
}
.info-section {
margin-bottom: 30px;
padding: 20px;
border: 1px solid #e0e0e0;
border-radius: 5px;
}
/* 基本信息无边框表格样式 */
.basic-info-table {
width: 100%;
border-collapse: collapse;
margin-top: 20px;
margin-left: auto;
margin-right: auto;
}
.basic-info-table th,
.basic-info-table td {
padding: 15px 20px;
text-align: left;
}
.basic-info-table th {
background-color: transparent;
font-weight: 600;
color: #333;
}
.basic-info-table td {
font-size: 1.1rem;
font-weight: 500;
color: #222;
}
/* 其他表格样式保持不变 */
.info-table {
width: 100%;
border-collapse: collapse;
margin-top: 20px;
}
.info-table th,
.info-table td {
padding: 15px;
text-align: center;
border: 1px solid #e0e0e0;
}
.info-table th {
background-color: #f5f7fa;
font-weight: 600;
color: #333;
}
.info-table td {
font-size: 1.1rem;
font-weight: 500;
color: #222;
}
.info-row {
display: flex;
margin-bottom: 25px;
flex-wrap: wrap;
}
.info-item {
width: 100%;
margin-bottom: 20px;
padding-bottom: 15px;
border-bottom: 1px solid #3C8DBC;
}
.info-label {
font-size: 1.1rem;
font-weight: 500;
color: #555;
margin-bottom: 8px;
text-align: center;
}
.info-value {
font-size: 1.4rem;
font-weight: 600;
color: #222;
padding: 8px 0;
text-align: center;
}
.stat-card {
border: 1px solid #e0e0e0;
border-radius: 4px;
padding: 15px;
margin-top: 10px;
text-align: center;
}
.stat-title {
font-size: 1rem;
color: #555;
.page-title {
font-size: 24px;
font-weight: bolder;
color: rgb(255,255,0);
margin-bottom: 10px;
}
.stat-value {
font-size: 1.8rem;
font-weight: 700;
.page-subtitle {
font-size: 16px;
color: rgb(255,255,200);
}
footer {
.instrument-info {
background-color: #fdf6ec;
color: #e6a23c;
padding: 12px 20px;
border-radius: 4px;
margin-bottom: 20px;
text-align: center;
padding: 20px 0;
color: #777;
font-size: 0.9rem;
border-top: 1px solid #eee;
margin-top: 40px;
font-size: 16px;
font-weight: 500;
}
/* 内部组件样式 */
.component-item {
display: flex;
margin-bottom: 15px;
padding: 12px 0;
border-bottom: 1px solid #f0f0f0;
.section-card {
margin-bottom: 20px;
border: 1px solid #3C8DBC;
border-radius: 4px;
background: rgba(30, 40, 50, 0.8);
}
.component-item:last-child {
border-bottom: none;
}
.component-name {
width: 150px;
.section-header {
background-color: #00a2e8;
padding: 12px 20px;
color: rgb(255,255,0);
font-size: 16px;
font-weight: 600;
color: #444;
padding-right: 10px;
border-bottom: 1px solid #3C8DBC;
}
.component-detail {
flex: 1;
color: #666;
.section-content {
padding: 15px;
}
/* 表格样式 - 与lcm.html完全一致 */
.el-table {
font-family: "Microsoft YaHei", Arial, Helvetica, sans-serif, "宋体";
background-color: rgb(18,25,34);
}
.el-table th {
background-color: #00a2e8;
padding: 8px 0;
}
.el-table th>.cell {
color: rgb(255,255,0);
text-align: center;
font-weight: 600;
padding: 0;
}
.el-table td {
background-color: rgb(18,25,34);
border-right: 1px solid #EBEEF5;
padding: 4px 0;
}
.el-table td>.cell {
color: rgb(255,255,0);
text-align: center;
font-size: 13px;
padding: 3px 0;
}
.el-table .warning-row {
color: #ff0000;
}
/* 分页样式 */
.pagination-container {
margin-top: 15px;
background-color: #ECF5FF;
padding: 10px;
border-radius: 4px;
}
/* 按钮样式 */
.action-buttons {
display: flex;
gap: 10px;
margin-bottom: 15px;
flex-wrap: wrap;
}
.quality-item {
margin-bottom: 15px;
padding: 10px 0;
border-bottom: 1px solid #f0f0f0;
padding: 12px;
border: 1px solid #3C8DBC;
border-radius: 4px;
background: rgba(40, 50, 60, 0.6);
}
.quality-header {
display: flex;
align-items: center;
width: 100%;
gap: 15px;
}
.quality-title {
font-size: 1.1rem;
color: #333;
width: 120px;
flex-shrink: 0;
color: rgb(255,255,200);
font-weight: 500;
min-width: 150px;
}
.quality-display {
flex: 1;
color: rgb(255,255,0);
padding: 6px 12px;
min-height: 20px;
margin-right: 10px;
}
.edit-btn {
padding: 6px 12px;
background-color: #409eff;
border: 1px solid #409eff;
border-radius: 4px;
color: white;
font-size: 14px;
cursor: pointer;
flex-shrink: 0;
}
.edit-input {
flex: 1;
padding: 6px 12px;
border: 1px solid #dcdfe6;
border-radius: 4px;
font-size: 14px;
margin-right: 10px;
min-width: 200px;
}
.confirm-btn {
background-color: #67c23a;
border-color: #67c23a;
}
/* 文件列表样式 */
.file-list {
margin-top: 10px;
text-align: left;
}
.file-item {
background: rgba(30, 40, 50, 0.8);
border-radius: 3px;
min-height: 32px;
display: flex;
align-items: center;
padding: 5px 0;
}
.file-item a {
color: #409eff;
text-decoration: none;
margin-left: 5px;
.no-data {
text-align: center;
color: rgb(255,255,200);
padding: 30px;
font-style: italic;
}
.file-item a:hover {
text-decoration: underline;
}
.file-icon {
color: #409eff;
margin-right: 5px;
}
/* 文件列表样式 */
.file-list {
margin-top: 10px;
text-align: left;
}
.file-item {
display: flex;
align-items: center;
padding: 5px 0;
}
.file-item a {
color: #409eff;
text-decoration: none;
margin-left: 5px;
}
.file-item a:hover {
text-decoration: underline;
}
.file-icon {
color: #409eff;
margin-right: 5px;
}
/* 文件列样式 */
.file-column {
text-align: left;
}
.upload-button {
background-color: #409eff;
border: 1px solid #409eff;
border-radius: 4px;
color: white;
padding: 6px 12px;
font-size: 14px;
cursor: pointer;
transition: all 0.3s;
}
.upload-button:hover {
background-color: #66b1ff;
border-color: #66b1ff;
}
.upload-button:disabled {
background-color: #a0cfff;
border-color: #a0cfff;
cursor: not-allowed;
}
@media (max-width: 768px) {
.container {
padding: 20px;
}
h1 {
font-size: 2rem;
}
.info-table th,
.info-table td {
padding: 10px 5px;
font-size: 0.9rem;
}
.info-table td {
font-size: 1rem;
.component-list {
display: grid;
gap: 10px;
}
.component-item {
flex-direction: column;
display: flex;
padding: 10px 15px;
border: 1px solid #3C8DBC;
border-radius: 4px;
background: rgba(40, 50, 60, 0.6);
}
.component-name {
width: 100%;
color: rgb(255,255,200);
font-weight: 500;
min-width: 120px;
}
.component-detail {
color: rgb(255,255,0);
flex: 1;
}
.file-item {
display: flex;
align-items: center;
margin-bottom: 5px;
}
.file-item a {
color: #66b1ff;
text-decoration: none;
margin-left: 5px;
}
.file-item a:hover {
text-decoration: underline;
}
@media (max-width: 768px) {
.homeWrap {
padding: 10px;
}
.quality-header {
flex-direction: column;
align-items: flex-start;
gap: 10px;
}
.quality-title {
min-width: auto;
}
.action-buttons {
flex-direction: column;
}
}
</style>
</head>
<script src="./scripts/tool_detail.js"></script>
<script src="scripts/axiosmin.js"></script>
<script src="./scripts/polyfill.js"></script>
<script src="./scripts/vue.min.js"></script>
<script src="./scripts/vue-router.js"></script>
<body>
<div class="container">
<header>
<h1>仪器汇总</h1>
</header>
<div id="app" class="homeWrap">
<!-- 页面头部 -->
<div class="page-header">
<div class="page-title">DEES 测井作业管理云系统 V1.0.1</div>
<div class="page-subtitle">仪器信息汇总</div>
</div>
<div class="content">
<div style="text-align: left; margin-bottom: 20px; font-size: 1.2rem; font-weight: 600;">
<!-- 仪器基本信息 -->
<div class="instrument-info">
仪器名称: <span id="seriesNum"></span>
</div>
<div class="info-section">
<h2 class="info-label">基本信息</h2>
<div style="padding: 0 20px;">
<el-container style="gap: 20px;">
<!-- 左侧区域 -->
<el-aside style="width: 45%;">
<!-- 基本信息 -->
<div class="section-card">
<div class="section-header">基本信息</div>
<div class="section-content">
<div style="padding: 0 15px;">
<table class="basic-info-table">
<tbody>
<tr>
<th>出厂日期</th>
<th>出厂日期</th>
<td></td>
<th>入库日期</th>
<th>入库日期</th>
<td></td>
</tr>
<tr>
<td>累计工作时间</td>
<td>累计工作时间</td>
<td></td>
<td>当次工作时间</td>
<td>当次累计工作时间</td>
<td></td>
</tr>
<tr>
<td>固件版本号</td>
<td>固件版本号</td>
<td colspan="3"></td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="info-section">
<h2 class="info-label">质检记录</h2>
</div>
<!-- 产品质检记录 -->
<div class="section-card">
<div class="section-header">产品质检记录</div>
<div class="section-content">
<div style="padding: 15px 0;">
<!-- 生产过程记录 -->
<div class="quality-item">
<div class="quality-header">
<div class="quality-title">生产过程记录</div>
<div class="quality-title">生产过程记录</div>
<div class="quality-display" id="processRecordDisplay"></div>
<button id="editProcessRecord" class="edit-btn">编辑</button>
<button id="editProcessRecord" class="edit-btn" style="margin-right: 120px;">编辑</button>
</div>
</div>
<!-- 生产过程检验 -->
<div class="quality-item">
<div class="quality-header">
<div class="quality-title">生产过程检验</div>
<div class="quality-title">生产过程检验</div>
<div class="quality-display" id="processInspectionDisplay"></div>
<button id="editProcessInspection" class="edit-btn">编辑</button>
<button id="editProcessInspection" class="edit-btn" style="margin-right: 120px;">编辑</button>
</div>
</div>
<!-- 成品检验记录 -->
<div class="quality-item">
<div class="quality-header">
<div class="quality-title">成品检验记录</div>
<div class="quality-title">成品检验记录</div>
<div class="quality-display" id="finalInspectionDisplay"></div>
<button id="editFinalInspection" class="edit-btn">编辑</button>
<button id="editFinalInspection" class="edit-btn" style="margin-right: 120px;">编辑</button>
</div>
</div>
</div>
</div>
<div class="info-section">
<h2 class="info-label">仪器施工汇总</h2>
<table class="info-table">
<thead>
<tr>
<th>井名</th>
<th>入井工作情况</th>
<th>施工井段</th>
<th>最高工作温度</th>
<th>最高承压</th>
<th>仪器工作情况</th>
<th>上井人</th>
<th>文件</th>
</tr>
</thead>
<tbody id="wellDataBody">
</tbody>
</table>
</div>
<div class="info-section">
<div style="display: flex; justify-content: space-between; align-items: center;">
<h2 class="info-label">维保情况</h2>
<button id="bt_add" style="margin-left: 5px; padding: 8px 16px; background-color: #409eff; border: 1px solid #409eff; border-radius: 4px; color: white; font-size: 14px; cursor: pointer; display: inline-flex; align-items: center;" onclick="addMaintenanceRecord()">
<i style="margin-right: 5px;">
<svg viewBox="0 0 1024 1024" width="14" height="14" fill="currentColor">
<path d="M512 128C304.3 128 128 304.3 128 512s176.3 384 384 384 384-176.3 384-384S719.7 128 512 128z m0 64c176.7 0 320 143.3 320 320s-143.3 320-320 320S192 688.7 192 512 335.3 192 512 192z m48 304h-96v96h-96v-96H320v-96h96v-96h96v96h96v96z"></path>
</svg>
</i>
新增维保记录
</button>
</div>
<table class="info-table">
<thead>
<tr>
<th>时间</th>
<th>等级</th>
<th>维保信息</th>
<th>维保人</th>
</tr>
</thead>
<tbody id="maintenanceDataBody">
<!-- 动态数据将在这里插入 -->
</tbody>
</table>
</div>
<div class="info-section">
<h2 class="info-label">内部组件</h2>
<div class="component-item">
<div class="component-name">伽马传感器:</div>
<div class="component-detail">编码 GH2025-001序列号 SN-GM-0625A</div>
</div>
<div class="component-item">
<div class="component-name">温度传感器:</div>
<div class="component-detail">编码 TP2025-002序列号 SN-TP-0521B</div>
</div>
<div class="component-item">
<div class="component-name">压力传感器:</div>
<div class="component-detail">编码 PS2025-003序列号 SN-PS-0415C</div>
</div>
</div>
<div class="info-section">
<h2 class="info-label">仪器所属部门</h2>
<!-- 内部组件 -->
<div class="section-card">
<div class="section-header">内部组件</div>
<div class="section-content">
<div class="no-data">暂无数据</div>
</div>
</div>
<!-- 仪器所属部门 -->
<div class="section-card">
<div class="section-header">仪器所属部门</div>
<div class="section-content">
<div class="component-item">
<div class="component-name" id="deptContainer" style="width: auto; white-space: nowrap;">暂无部门信息</div>
</div>
</div>
</div>
</el-aside>
<footer>
<p>版权所有 © 北京六合伟业科技股份有限公司</p>
</footer>
<!-- 右侧区域 -->
<el-main style="width: 55%; padding: 0; margin: 0;">
<!-- 仪器施工汇总 -->
<div class="section-card">
<div class="section-header" style="display: flex; justify-content: space-between; align-items: center;">
<span>仪器施工汇总</span>
</div>
<div class="section-content">
<el-table
style="background-color: #121922;"
:data="tableData"
tooltip-effect="dark"
style="width: 100%"
:height="tHeight"
:cell-style="{background:'#121922'}"
border>
<el-table-column
prop="wellname"
label="井名"
width="80"
:show-overflow-tooltip="true">
</el-table-column>
<el-table-column
prop="workStatus"
label="入井工作情况"
width="100"
:show-overflow-tooltip="true">
</el-table-column>
<el-table-column
prop="workSection"
label="施工井段"
width="100"
:show-overflow-tooltip="true">
</el-table-column>
<el-table-column
prop="maxTemp"
label="最高工作温度"
width="80">
</el-table-column>
<el-table-column
prop="maxPressure"
label="最高承压"
width="80">
</el-table-column>
<el-table-column
prop="instrumentStatus"
label="仪器工作情况"
width="80">
</el-table-column>
<el-table-column
prop="worker"
label="上井人"
width="100">
</el-table-column>
<el-table-column
prop="files"
label="文件"
width="160"
:show-overflow-tooltip="true">
</el-table-column>
<el-table-column
prop="links"
label="链接"
width="260"
:show-overflow-tooltip="true">
</el-table-column>
</el-table>
<div class="pagination-container">
<el-pagination
@size-change="handleSizeChange"
@current-change="handleCurrentChange"
:current-page="currentPage"
:page-sizes="[50,100, 200, 300]"
:page-size="pagesize"
layout="total, sizes, prev, pager, next, jumper"
:total="recordTotal"
style="background-color: #ECF5FF;">
</el-pagination>
</div>
</div>
</div>
<!-- 维保情况 -->
<div class="section-card">
<div class="section-header" style="display: flex; justify-content: space-between; align-items: center;">
<span>维保情况</span>
<el-button id="bt_add" style="margin-left: 5px;" plain type="primary" icon="el-icon-circle-plus-outline" @click="addMaintenanceRecord()">新增维保记录</el-button>
</div>
<div class="section-content">
<el-table
style="background-color: #121922;"
:data="tableData"
tooltip-effect="dark"
style="width: 100%"
:height="tHeight"
:cell-style="{background:'#121922'}"
border>
<el-table-column
prop="time"
label="时间"
width="100">
</el-table-column>
<el-table-column
prop="level"
label="等级"
width="40">
</el-table-column>
<el-table-column
prop="info"
label="维保信息"
width="180"
:show-overflow-tooltip="true">
</el-table-column>
<el-table-column
prop="maintainer"
label="维保人"
width="80">
</el-table-column>
<el-table-column
prop="files"
label="文件"
width="160"
:show-overflow-tooltip="true">
</el-table-column>
<el-table-column
prop="links"
label="链接"
width="260"
:show-overflow-tooltip="true">
</el-table-column>
</el-table>
<script>
<div class="pagination-container">
<el-pagination
@size-change="handleSizeChange"
@current-change="handleCurrentChange"
:current-page="currentPage"
:page-sizes="[50,100, 200, 300]"
:page-size="pagesize"
layout="total, sizes, prev, pager, next, jumper"
:total="recordTotal"
style="background-color: #ECF5FF;">
</el-pagination>
</div>
</div>
</div>
</el-main>
</el-container>
<!-- 底部版权 -->
<div style="text-align: center; padding: 20px 0; color: rgb(255,255,200); font-size: 12px; border-top: 1px solid #3C8DBC; margin-top: 20px;">
<span>版权所有 © 北京六合伟业科技股份有限公司</span>
</div>
</div>
<script>
new Vue({
el: '#app',
data() {
return {
// 仅保留必要的空数据结构
tableData: [],
currentPage: 1,
pagesize: 50,
recordTotal: 0,
tHeight: 400
}
},
mounted() {
// 仅保留原有的设置仪器名称的逻辑
const seriesNum = this.getUrlParameter('series');
const instrument = this.getUrlParameter('instrument');
if (seriesNum) {
document.getElementById('seriesNum').textContent = seriesNum + '-' + instrument;
}
// 设置表格高度
this.calculateTableHeight();
window.addEventListener('resize', this.calculateTableHeight);
},
beforeDestroy() {
window.removeEventListener('resize', this.calculateTableHeight);
},
methods: {
// 获取URL参数
function getUrlParameter(name) {
getUrlParameter(name) {
name = name.replace(/[\[\]]/g, '\\$&');
const regex = new RegExp('[?&]' + name + '(=([^&#]*)|&|#|$)');
const results = regex.exec(window.location.href);
if (!results) return null;
if (!results[2]) return '';
return decodeURIComponent(results[2].replace(/\+/g, ' '));
}
},
// 设置序列号
document.addEventListener('DOMContentLoaded', function() {
const seriesNum = getUrlParameter('series');
if (seriesNum) {
document.getElementById('seriesNum').textContent = seriesNum;
// 计算表格高度
calculateTableHeight() {
const windowHeight = window.innerHeight;
this.tHeight = windowHeight - 400;
},
// 分页处理 - 空方法由外部JS文件实现
handleSizeChange(val) {
// 由外部JS文件实现
},
handleCurrentChange(val) {
// 由外部JS文件实现
},
// 新增维保记录 - 空方法由外部JS文件实现
addMaintenanceRecord() {
// 由外部JS文件实现
}
}
});
</script>
</script>
<!-- 原有的脚本引入 -->
<script src="./scripts/tool_detail.js"></script>
</body>
</html>