Commit 73b0a9d7 authored by 祁正's avatar 祁正

通知单管理-列表

parent 9ae35479
...@@ -44,3 +44,11 @@ export function insert(data) { ...@@ -44,3 +44,11 @@ export function insert(data) {
data:data data:data
}) })
} }
// 获取列表
export function list(data) {
return request({
url: '/control/notificationManagement/list',
method: 'get',
params:data
})
}
...@@ -113,24 +113,34 @@ ...@@ -113,24 +113,34 @@
<el-table :data="tableList"> <el-table :data="tableList">
<el-table-column type="index" width="55" align="center" label="序号"/> <el-table-column type="index" width="55" align="center" label="序号"/>
<el-table-column label="序号" align="center" prop="applicableBrand" /> <el-table-column label="通知单编号" align="center" prop="notificationNumber" >
<el-table-column label="通知单编号" align="center" prop="listCode" >
</el-table-column> </el-table-column>
<el-table-column label="认证机构" align="center" prop="createUserName" /> <el-table-column label="认证机构" align="center" prop="certificationBody" />
<el-table-column label="事业部" align="center" prop="createTime" /> <el-table-column label="事业部" align="center" prop="businessUnitName" />
<el-table-column label="品牌" align="center" prop="updateUserName" /> <el-table-column label="品牌" align="center" prop="brand" />
<el-table-column label="车型代码" align="center" prop="updateTime" /> <el-table-column label="车型代码" align="center" prop="vehicleModelCode" />
<el-table-column label="车型系列" align="center" prop="updateTime" /> <el-table-column label="车型系列" align="center" prop="vehicleSeries" >
<el-table-column label="车型代码" align="center" prop="updateTime" /> <template #default="scope">
<el-table-column label="生产地址" align="center" prop="updateTime" /> <dict-tag :options="getDictList(scope.row.vehicleSeries)?vehicle_model_series_icar:vehicle_model_series" :value="scope.row.vehicleSeries" />
<el-table-column label="车型公告号" align="center" prop="updateTime" /> </template>
<el-table-column label="变更类型" align="center" prop="updateTime" /> </el-table-column>
<el-table-column label="认证负责人" align="center" prop="updateTime" /> <el-table-column label="生产地址" align="center" prop="productionAddress" width="150" />
<el-table-column label="批准日期" align="center" prop="updateTime" /> <el-table-column label="车型公告号" align="center" prop="vehicleAnnouncementNumber" >
<el-table-column label="通知单状态" align="center" prop="updateTime" /> <template #default="scope">
<el-table-column label="创建人" align="center" prop="updateTime" /> <span>{{}}</span>
<el-table-column label="批准人" align="center" prop="updateTime" /> </template>
</el-table-column>
<el-table-column label="变更类型" align="center" prop="changeType" />
<el-table-column label="认证负责人" align="center" prop="certificationResponsiblePerson" />
<el-table-column label="批准日期" align="center" prop="approvalDate" />
<el-table-column label="通知单状态" align="center" prop="notificationStatus" >
<template #default="scope">
<dict-tag :options="notification_status" :value="scope.row.notificationStatus" />
</template>
</el-table-column>
<el-table-column label="创建人" align="center" prop="createUserName" />
<el-table-column label="批准人" align="center" prop="ApprovalUserName" />
<el-table-column label="操作" align="center" class-name="small-padding fixed-width"> <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template #default="scope"> <template #default="scope">
...@@ -139,7 +149,13 @@ ...@@ -139,7 +149,13 @@
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<pagination
v-show="total>0"
:total="total"
v-model:page="queryParams.pageNum"
v-model:limit="queryParams.pageSize"
@pagination="getList"
/>
<!-- 抽屉--> <!-- 抽屉-->
<el-drawer @close="drawerColse" v-model="drawer"> <el-drawer @close="drawerColse" v-model="drawer">
...@@ -273,7 +289,7 @@ ...@@ -273,7 +289,7 @@
</el-col> </el-col>
<el-col :offset="1" :span="5"> <el-col :offset="1" :span="5">
<el-button type="primary" icon="User" class="btn-C" plain>选择用户</el-button> <el-button type="primary" icon="User" @click="singleOpenDialog" class="btn-C" plain>选择用户</el-button>
</el-col> </el-col>
</el-row> </el-row>
...@@ -285,7 +301,7 @@ ...@@ -285,7 +301,7 @@
</el-col> </el-col>
<el-col :offset="1" :span="5"> <el-col :offset="1" :span="5">
<el-button type="primary" icon="User" class="btn-C" plain>选择用户</el-button> <el-button type="primary" icon="User" @click="openDialog" class="btn-C" plain>选择用户</el-button>
</el-col> </el-col>
</el-row> </el-row>
</el-form> </el-form>
...@@ -301,24 +317,27 @@ ...@@ -301,24 +317,27 @@
<!-- <select-role--> <select-role
<!-- v-model="selectRole"--> v-if="userList.length > 0"
<!-- :dept-list="userList"--> v-model="selectRole"
<!-- name-key="nickName"--> :dept-list="userList"
<!-- dept-key="dept"--> name-key="nickName"
<!-- :selection-mode="selectType"--> dept-key="dept"
<!-- @submit="handleSelectionSubmit"--> :selection-mode="selectType"
<!-- @close="() => selectRole = false"--> @submit="handleSelectionSubmit"
<!-- />--> @close="() => selectRole = false"
/>
</div> </div>
</template> </template>
<script setup> <script setup>
import SelectRole from "@/components/SelectRole/index.vue" import SelectRole from "@/components/SelectRole/index.vue"
import {getUnitList,brandData,getALLManufacturerList,getAllModelCode,getALLUserList,insert} from "@/api/notificationManagement/list.js" import {getUnitList,brandData,getALLManufacturerList,getAllModelCode,getALLUserList,insert,list} from "@/api/notificationManagement/list.js"
import { ref } from "vue"; import { ref } from "vue";
import { ElMessage } from 'element-plus' import { ElMessage } from 'element-plus'
const { proxy } = getCurrentInstance(); const { proxy } = getCurrentInstance();
const { certification_body } = proxy.useDict('certification_body') const { certification_body
} = proxy.useDict('certification_body')
const { notification_status } = proxy.useDict('notification_status')
//车型系列-事业部icar才能选这个 //车型系列-事业部icar才能选这个
const { vehicle_model_series_icar } = proxy.useDict('vehicle_model_series_icar') const { vehicle_model_series_icar } = proxy.useDict('vehicle_model_series_icar')
//车型系列-除了事业部icar选这个 //车型系列-除了事业部icar选这个
...@@ -333,7 +352,7 @@ const selectType = ref('multiple') //默认多选 ...@@ -333,7 +352,7 @@ const selectType = ref('multiple') //默认多选
const vehicleModelSeriesList = ref([]) const vehicleModelSeriesList = ref([])
const addressList = ref([]) const addressList = ref([])
const drawer = ref(false) const drawer = ref(false)
const total = ref(0)
const unitList = ref([]) const unitList = ref([])
const brandList = ref([]) const brandList = ref([])
const drawerQueryParams = ref({ const drawerQueryParams = ref({
...@@ -384,7 +403,6 @@ const rules = ref({ ...@@ -384,7 +403,6 @@ const rules = ref({
function confirmClick(formRef) { function confirmClick(formRef) {
drawerQueryRef.value.validate((valid) => { drawerQueryRef.value.validate((valid) => {
if (valid) { if (valid) {
console.log(drawerQueryParams.value);
insert(drawerQueryParams.value).then(res=>{ insert(drawerQueryParams.value).then(res=>{
console.log("新增结果",res) console.log("新增结果",res)
if(res.code === 200){ if(res.code === 200){
...@@ -393,7 +411,6 @@ function confirmClick(formRef) { ...@@ -393,7 +411,6 @@ function confirmClick(formRef) {
} }
}) })
} else { } else {
console.log('表单验证失败');
return false; return false;
} }
}); });
...@@ -405,6 +422,17 @@ function getUnitDataList(){ ...@@ -405,6 +422,17 @@ function getUnitDataList(){
}) })
} }
function getDictList(v){
//车型系列-除了事业部icar选这个
let a = toRaw(toRaw(vehicle_model_series_icar)._object).vehicle_model_series_icar
console.log("a",a)
// let b = toValue(vehicle_model_series)
if(a.find(item => item.value === v)) {
return true
}else return false
}
//获取品牌列表 //获取品牌列表
function getBrandDataList(){ function getBrandDataList(){
brandData().then(res=>{ brandData().then(res=>{
...@@ -413,7 +441,6 @@ function getBrandDataList(){ ...@@ -413,7 +441,6 @@ function getBrandDataList(){
} }
function onChange(){ function onChange(){
console.log(drawerQueryParams.value.businessDivisionId)
let id = drawerQueryParams.value.businessDivisionId let id = drawerQueryParams.value.businessDivisionId
drawerQueryParams.value.vehicleSeries = null drawerQueryParams.value.vehicleSeries = null
//icak的id(暂时) //icak的id(暂时)
...@@ -424,7 +451,6 @@ function onChange(){ ...@@ -424,7 +451,6 @@ function onChange(){
vehicleModelSeriesList.value =toValue(vehicle_model_series) vehicleModelSeriesList.value =toValue(vehicle_model_series)
} }
console.log(vehicleModelSeriesList.value)
} }
//多选 //多选
...@@ -441,7 +467,6 @@ const singleOpenDialog = () => { ...@@ -441,7 +467,6 @@ const singleOpenDialog = () => {
//获取所有制造商数据-生产地址 //获取所有制造商数据-生产地址
function getALLManufacturerDataList(){ function getALLManufacturerDataList(){
getALLManufacturerList().then(res=>{ getALLManufacturerList().then(res=>{
console.log(res)
addressList.value = res.data addressList.value = res.data
}) })
} }
...@@ -449,6 +474,17 @@ function drawerColse(){ ...@@ -449,6 +474,17 @@ function drawerColse(){
drawerQueryRef.value.resetFields() drawerQueryRef.value.resetFields()
} }
//获取列表
function getList(){
console.log("查询参数",queryParams.value)
list(queryParams.value).then(res=>{
console.log(res)
tableList.value = res.rows
total.value = res.total
})
}
//获取所有车型代码 //获取所有车型代码
function getALLModelCodeList(){ function getALLModelCodeList(){
getAllModelCode().then(res=>{ getAllModelCode().then(res=>{
...@@ -473,10 +509,10 @@ const handleSelectionSubmit = (selectedItems) => { ...@@ -473,10 +509,10 @@ const handleSelectionSubmit = (selectedItems) => {
//获取所有人员 //获取所有人员
function getALLUserDeptList(){ function getALLUserDeptList(){
getALLUserList().then(res=>{ getALLUserList().then(res=>{
console.log("人员",res.data)
userList.value = res.data userList.value = res.data
}) })
} }
getList()
getALLUserDeptList() getALLUserDeptList()
getALLModelCodeList() getALLModelCodeList()
getALLManufacturerDataList() getALLManufacturerDataList()
...@@ -499,4 +535,13 @@ getBrandDataList() ...@@ -499,4 +535,13 @@ getBrandDataList()
padding-bottom: 20px; padding-bottom: 20px;
background-color: rgb(245, 245, 245); background-color: rgb(245, 245, 245);
} }
:deep(.el-pagination) {
display: flex;
justify-content: center;
width: 100%;
margin-top: 24px;
}
:deep(.el-pagination.is-background .el-pager li.is-active){
background-color: #0154FB;
}
</style> </style>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment