From a40dedacd26d962bbb57a4be14b8357e27f6dea3 Mon Sep 17 00:00:00 2001
From: Zhu Zhonghua <zhonghua@qq.com>
Date: 星期一, 14 四月 2025 10:26:23 +0800
Subject: [PATCH] 修改loading的背景色
---
src/views/basicData/ApsResourceGroup/index.vue | 179 +++++++++++++++++++++++++++++------------------------------
1 files changed, 87 insertions(+), 92 deletions(-)
diff --git a/src/views/basicData/ApsResourceGroup/index.vue b/src/views/basicData/ApsResourceGroup/index.vue
index 6a7cd11..bf9d6be 100644
--- a/src/views/basicData/ApsResourceGroup/index.vue
+++ b/src/views/basicData/ApsResourceGroup/index.vue
@@ -1,6 +1,9 @@
<template>
<div class="app-container">
- <el-form :model="queryParams" ref="queryRef" :inline="true" v-show="showSearch" label-width="68px">
+ <el-form :model="queryParams" ref="queryRef" :inline="true" v-show="showSearch" label-width="90px">
+ <el-row :gutter="20">
+ <el-col
+ :span="6">
<el-form-item label="璧勬簮缁�" prop="resourceGroupName">
<el-input
v-model="queryParams.resourceGroupName"
@@ -9,6 +12,9 @@
@keyup.enter="handleQuery"
/>
</el-form-item>
+ </el-col>
+ <el-col
+ :span="6">
<el-form-item label="鎴鏈哄姞闇�姹傛棩鏈�" style="width: 400px" label-width="150px">
<el-date-picker
v-model="daterangeRequestDate"
@@ -19,10 +25,16 @@
end-placeholder="缁撴潫鏃ユ湡"
></el-date-picker>
</el-form-item>
+ </el-col>
+ <el-col
+ :span="12"
+ style="text-align: right;">
<el-form-item>
<el-button type="primary" icon="Search" @click="handleQuery">鎼滅储</el-button>
<el-button icon="Refresh" @click="resetQuery">閲嶇疆</el-button>
</el-form-item>
+ </el-col>
+ </el-row>
</el-form>
<el-row :gutter="10" class="mb8">
@@ -32,7 +44,7 @@
plain
icon="Upload"
@click="handleImport"
- v-hasPermi="['partPlan:import']"
+ v-hasPermi="['ApsResourceGroup:ApsResourceGroup:import']"
>瀵煎叆</el-button>
</el-col>
<el-col :span="1.5">
@@ -85,6 +97,16 @@
</el-col>
</el-row>
<el-row style="margin-top: 20px;">
+ <el-form-item label="鎴鏈哄姞闇�姹傛棩鏈�" prop="requestDate" >
+ <el-date-picker clearable
+ v-model="requestDate"
+ type="date"
+ value-format="YYYY-MM-DD HH:mm:ss"
+ placeholder="璇烽�夋嫨鏈哄姞闇�姹傛棩鏈�"
+ :disabled-date="disabledDate"
+ >
+ </el-date-picker>
+ </el-form-item>
<el-col>
<div>
<el-button
@@ -165,6 +187,16 @@
const exampleHeight = ref("500px");
const uploadRef = ref();
const exampleList = ref([]);
+const requestDate = ref(null);
+// 璁$畻褰撳墠鏃堕棿寰�鍚庢帹 15 澶╃殑鏃ユ湡
+const disabledDate = (time) => {
+ // return time.getTime() > Date.now()
+ // 璁$畻 15 澶╃殑姣鏁�
+ const fifteenDaysInMillis = 15 * 24 * 60 * 60 * 1000;
+ // 璁$畻褰撳墠鏃堕棿鍔犱笂 15 澶╁悗鐨勬绉掓暟
+ const maxTime = Date.now() + fifteenDaysInMillis;
+ return time.getTime() > maxTime;
+}
/*** 鐢ㄦ埛瀵煎叆鍙傛暟 */
const upload = reactive({
// 鏄惁鏄剧ず寮瑰嚭灞傦紙鐢ㄦ埛瀵煎叆锛�
@@ -185,63 +217,39 @@
{ type: 'checkbox', width: 60, align:"center"},
{ type: 'seq', title: '搴忓彿', width: 60 },
{
- title: '鏂欏彿',
- field: 'itemNo',
+ title: '璧勬簮缁勫悕绉�',
+ field: 'resourceGroupName',
+ width: 300,
+ align:"center",
+ },
+ {
+ title: '璁惧鏁伴噺',
+ field: 'devicesQuantity',
width: 150,
align:"center",
},
{
- title: '宸ュ崟鍙�',
- field: 'workOrderNo',
- width: 150,
+ title: '姣忔棩鐞嗚鏃堕棿',
+ field: 'theoryHours',
+ width: 300,
align:"center",
},
{
- title: '宸ュ簭搴忓彿',
- field: 'processNumber',
- width: 100,
+ title: '鎴闇�姹傛棩鍓╀綑澶╂暟',
+ field: 'restDays',
+ width: 210,
align:"center",
},
{
- title: '宸ュ簭鍚嶇О',
- field: 'processName',
- width: 150,
+ title: '鐞嗚浜ц兘',
+ field: 'theoryCapacity',
+ width: 300,
align:"center",
},
{
- title: '宸ュ簭璁″垝寮�濮嬫棩鏈�',
- field: 'processPlanStartDay',
- width: 200,
- align:"center",
- },
- {
- title: '宸ュ簭璁″垝缁撴潫鏃ユ湡',
- field: 'processPlanEndDay',
- width: 200,
- align:"center",
- },
- {
- title: '鏈紑宸ユ暟閲�',
- field: 'notStartWorkCount',
- width: 150,
- align:"center",
- },
- {
- title: '宸插畬鎴愭暟閲�',
- field: 'completedCount',
- width: 150,
- align:"center",
- },
- {
- title: '搴熷純鏁伴噺',
- field: 'discardCount',
- width: 150,
- align:"center",
- },
- {
- title: '闆嗘垚鏃ユ湡',
- field: 'integrationDay',
- width: 160,
+ title: '鎴鏈哄姞闇�姹傛棩鏈�',
+ field: 'requestDate',
+ width: 300,
align:"center",
}
]);
@@ -249,63 +257,39 @@
const exampleColumns = ref([
{ type: 'seq', title: '搴忓彿', width: 60 },
{
- title: '鏂欏彿',
- field: 'itemNo',
+ title: '璧勬簮缁勫悕绉�',
+ field: 'resourceGroupName',
+ width: 300,
+ align:"center",
+ },
+ {
+ title: '璁惧鏁伴噺',
+ field: 'devicesQuantity',
width: 150,
align:"center",
},
{
- title: '宸ュ崟鍙�',
- field: 'workOrderNo',
- width: 150,
+ title: '姣忔棩鐞嗚鏃堕棿',
+ field: 'theoryHours',
+ width: 300,
align:"center",
},
{
- title: '宸ュ簭搴忓彿',
- field: 'processNumber',
- width: 100,
+ title: '鎴闇�姹傛棩鍓╀綑澶╂暟',
+ field: 'restDays',
+ width: 210,
align:"center",
},
{
- title: '宸ュ簭鍚嶇О',
- field: 'processName',
- width: 150,
+ title: '鐞嗚浜ц兘',
+ field: 'theoryCapacity',
+ width: 300,
align:"center",
},
{
- title: '宸ュ簭璁″垝寮�濮嬫棩鏈�',
- field: 'processPlanStartDay',
- width: 200,
- align:"center",
- },
- {
- title: '宸ュ簭璁″垝缁撴潫鏃ユ湡',
- field: 'processPlanEndDay',
- width: 200,
- align:"center",
- },
- {
- title: '鏈紑宸ユ暟閲�',
- field: 'notStartWorkCount',
- width: 150,
- align:"center",
- },
- {
- title: '宸插畬鎴愭暟閲�',
- field: 'completedCount',
- width: 150,
- align:"center",
- },
- {
- title: '搴熷純鏁伴噺',
- field: 'discardCount',
- width: 150,
- align:"center",
- },
- {
- title: '闆嗘垚鏃ユ湡',
- field: 'integrationDay',
- width: 160,
+ title: '鎴鏈哄姞闇�姹傛棩鏈�',
+ field: 'requestDate',
+ width: 370,
align:"center",
}
]);
@@ -323,6 +307,7 @@
plant: null
},
rules: {
+
}
});
@@ -342,7 +327,7 @@
loading.value = false;
});
}
-
+function handleCheckboxChange(){}
// 鍙栨秷鎸夐挳
function cancel() {
open.value = false;
@@ -485,8 +470,15 @@
}
/** 涓婁紶骞惰В鏋愭寜閽搷浣� */
function uploadParse() {
+ if (requestDate.value === null || typeof requestDate.value === 'undefined' || requestDate.value === '') {
+ ElMessage({
+ message: '璇烽�夋嫨鎴鏈哄姞闇�姹傛棩鏈�',
+ type: 'warning',
+ })
+ return
+ }
queryParams.value.params = {};
- queryParams.value.params["batchNumber"] = batchNumber.value;
+ queryParams.value.params["requestDate"] = requestDate.value;
confirmApsResourceGroup(queryParams.value).then(response => {
exampleList.value = response.rows;
loading.value = false;
@@ -494,6 +486,7 @@
isError.value = false;
planned.value = true;
upload.open = false;
+ requestDate.value = null;
ElMessage({
message: '璧勬簮姹犳暟鎹凡鎴愬姛涓婁紶鍜岃В鏋�',
type: 'success',
@@ -507,10 +500,12 @@
if (uploadRef.value) {
uploadRef.value.clearFiles();
}
+ requestDate.value = null;
isVisible.value = false;
isError.value = false;
planned.value = true;
upload.open = false;
+
}
getList();
--
Gitblit v1.9.3