Compare commits

..

2 Commits

Author SHA1 Message Date
mengfanliang 20b4ca00fb feat: code saved 2024-08-29 08:35:22 +08:00
mengfanliang db25047877 feat: 修改安全环保检查样式统一 2024-08-28 18:12:34 +08:00
9 changed files with 827 additions and 514 deletions

View File

@ -1,15 +1,9 @@
<template> <template>
<u-sticky bgColor="#ffffff"> <u-sticky bgColor="#ffffff">
<view class="card"> <view class="card top-flex-box">
<u-search <u--text v-if="isHasFilter" suffixIcon="arrow-down" text="筛选" @click="selfHandleShowPicker" style="flex: 0.2" />
v-model="localInputSearchValue" <u-search v-model="localInputSearchValue" :showAction="true" actionText="搜索" :animation="false"
:showAction="true" @search="selfHandlerSearch" @custom="selfHandlerSearch" @clear="selfHandlerClear" />
actionText="搜索"
:animation="false"
@search="selfHandlerSearch"
@custom="selfHandlerSearch"
@clear="selfHandlerClear"
/>
</view> </view>
<app-line /> <app-line />
</u-sticky> </u-sticky>
@ -22,6 +16,11 @@ export default {
type: String, type: String,
required: true, required: true,
}, },
/** 是否需要启用前置筛选能力 */
isHasFilter: {
type: Boolean,
required: false
}
}, },
data() { data() {
return { return {
@ -29,19 +28,27 @@ export default {
localInputSearchValue: this.inputSearchValue, localInputSearchValue: this.inputSearchValue,
}; };
}, },
watch: { watch: {
// prop // prop
inputSearchValue(newVal) { inputSearchValue(newVal) {
this.localInputSearchValue = newVal; this.localInputSearchValue = newVal;
}, },
}, },
methods: { methods: {
selfHandlerSearch() { selfHandlerSearch() {
this.$emit("search", this.localInputSearchValue); this.$emit("search", this.localInputSearchValue);
}, },
selfHandlerClear() { selfHandlerClear() {
this.localInputSearchValue = ""; this.localInputSearchValue = "";
} },
/** 组件自身的筛选器处理事件 */
selfHandleShowPicker() {
if (!this.isHasFilter) {
console.log("%c%s", "background: orange; color: black", "请添加 is-has-filter 属性使其生效")
return;
}
this.$emit("showPicker");
}
}, },
}; };
</script> </script>
@ -50,4 +57,8 @@ export default {
.key-word-search-input-box { .key-word-search-input-box {
margin: 20rpx; margin: 20rpx;
} }
.top-flex-box {
display: flex;
}
</style> </style>

View File

@ -1,7 +1,7 @@
<template> <template>
<view v-if="list.length > 0"> <view v-if="list.length > 0">
<view class="list"> <view class="list">
<u-list @scrolltolower="selfScrollToLower"> <u-list @scrolltolower="selfScrollToLower" :height="height" style="box-sizing: border-box;">
<u-list-item v-for="(item, index) in list" :key="index" style="border-bottom: none; padding: 0rpx;"> <u-list-item v-for="(item, index) in list" :key="index" style="border-bottom: none; padding: 0rpx;">
<view class="item"> <view class="item">
<slot :item="item" :index="index" /> <slot :item="item" :index="index" />
@ -20,6 +20,11 @@ export default {
type: Array, type: Array,
required: true, required: true,
}, },
height: {
type: String,
requierd: false,
default: '100%'
}
}, },
data() { data() {

View File

@ -48,20 +48,18 @@
type="primary" type="primary"
size="mini" size="mini"
shape="circle" shape="circle"
text="确认"
@click="handleClickConfirm(item)" @click="handleClickConfirm(item)"
> />
确认
</u-button>
</view> </view>
<view class="ml-10"> <view class="ml-10">
<u-button <u-button
type="primary" type="primary"
size="mini" size="mini"
shape="circle" shape="circle"
text="查看"
@click="handleClickView(item)" @click="handleClickView(item)"
> />
查看
</u-button>
</view> </view>
</view> </view>
</view> </view>
@ -84,17 +82,25 @@ export default {
data() { data() {
return { return {
store: this.$store, // store /** 全局store */
store: this.$store,
searchForm: { searchForm: {
HIDDENDESCR: "", HIDDENDESCR: "",
}, },
isRequestEnd: false, // /** 请求是否已结束 */
isRequestEnd: false,
/** 分页配置 */
pagination: { pagination: {
/** 展示总数 */
showCount: 10, showCount: 10,
/** 当前页 */
currentPage: 1, currentPage: 1,
/** 状态确认 */
stateConfirm: "0", stateConfirm: "0",
/** 总页数 */
total: 0, total: 0,
}, },
/** 列表数据存储 */
list: [], list: [],
}; };
}, },
@ -118,6 +124,10 @@ export default {
userInfo() { userInfo() {
return this.$store.getters.getUserInfo; return this.$store.getters.getUserInfo;
}, },
/** 动态计算 list 列表的高度 */
calcListHeight() {
return this.totalHeight;
},
}, },
methods: { methods: {
@ -169,22 +179,16 @@ export default {
}, },
/** 处理点击确认按钮事件 */ /** 处理点击确认按钮事件 */
handleClickConfirm(ext) { handleClickConfirm(ext) {
uni.$u.route( uni.$u.route("/hiddenManageSubPackages/pages/hidden_confirm/confirm", {
"/hiddenManageSubPackages/pages/hidden_confirm/confirm", HIDDEN_ID: ext.HIDDEN_ID,
{ });
HIDDEN_ID: ext.HIDDEN_ID,
}
);
}, },
/** 处理点击查看按钮事件 */ /** 处理点击查看按钮事件 */
handleClickView(ext) { handleClickView(ext) {
uni.$u.route( uni.$u.route("/hiddenManageSubPackages/pages/hidden_confirm/view", {
"/hiddenManageSubPackages/pages/hidden_confirm/view", HIDDEN_ID: ext.HIDDEN_ID,
{ });
HIDDEN_ID: ext.HIDDEN_ID, },
}
)
}
}, },
}; };
</script> </script>

View File

@ -78,7 +78,6 @@ export default {
this.baseList[baseListKey].NUM = resData.repulseAndCheckCount.repulseAndCheckCount ? resData.repulseAndCheckCount.repulseAndCheckCount : 0 this.baseList[baseListKey].NUM = resData.repulseAndCheckCount.repulseAndCheckCount ? resData.repulseAndCheckCount.repulseAndCheckCount : 0
} }
} }
}, },
}, },
} }

View File

@ -1,108 +1,156 @@
<template> <template>
<view class="content"> <view>
<view class="search card"> <!-- 吸顶搜索框 start -->
<u--input class="ml-10" prefixIcon="search" placeholder="请输入关键字" border="surround" v-model="keyword" clearable <key-word-search-input
shape="circle"></u--input> :inputSearchValue="searchForm.HIDDENDESCR"
<u-button class="bth-mini ml-10" type="success" text="确定" @click="resetList"></u-button> @search="resetList"
</view> @showPicker="showPicker"
<u-list @scrolltolower="scrolltolower" v-if="list.length > 0"> />
<u-list-item v-for="(item, index) in list" :key="index"> <!-- 吸顶搜索框 end -->
<view>
<view class="flex-between main-title"> <!-- 列表渲染 start -->
<text>被检查单位{{ item.INSPECTED_CORPINFO_ID_NAME }}</text> <list :list="list" @scroll-to-lower="scrollToLower">
</view> <template #default="{ item }">
<view class="flex-between mt-10 subtitle"> <view class="flex-between main-title">
<text>检查发起人{{ item.INSPECTION_ORIGINATOR_NAME }}</text> <text>被检查单位{{ item.INSPECTED_CORPINFO_ID_NAME }}</text>
<text>检查类型{{ item.INSPECTION_TYPE_NAME }}</text> </view>
</view> <view class="flex-between mt-10 subtitle">
<view class="flex-between mt-10 subtitle"> <text>检查发起人{{ item.INSPECTION_ORIGINATOR_NAME }}</text>
<text>检查时间 {{ item.INSPECTION_TIME_START }} {{ item.INSPECTION_TIME_END }} </text> <text>检查类型{{ item.INSPECTION_TYPE_NAME }}</text>
</view> </view>
<view class="flex-between mt-10 subtitle"> <view class="flex-between mt-10 subtitle">
<text> <text
状态 >检查时间 {{ item.INSPECTION_TIME_START }}
<template v-if="item.INSPECTION_STATUS == '0'"></template> {{ item.INSPECTION_TIME_END }} </text
<template v-else-if="item.INSPECTION_STATUS == '1'">检查人核实中</template> >
<template v-else-if="item.INSPECTION_STATUS == '2'">待被检查人确认</template> </view>
<template v-else-if="item.INSPECTION_STATUS == '3'">待指派</template> <view class="flex-between mt-10 subtitle">
<template v-else-if="item.INSPECTION_STATUS == '4'">指派中</template> <text>
<template v-else-if="item.INSPECTION_STATUS == '5'">指派完成</template> 状态
<template v-else-if="item.INSPECTION_STATUS == '6'">检查待验收</template> <template v-if="item.INSPECTION_STATUS == '0'"
<template v-else-if="item.INSPECTION_STATUS == '7'">检查已验收</template> >待检查人核实</template
<template v-else-if="item.INSPECTION_STATUS == '8'">已归档</template> >
<template v-else-if="item.INSPECTION_STATUS == '-1'">检查人核实打回</template> <template v-else-if="item.INSPECTION_STATUS == '1'"
<template v-else-if="item.INSPECTION_STATUS == '-2'">被检查人申辩</template> >检查人核实中</template
</text> >
<u-button type="primary" text="申辩记录" size="mini" class="bth-mini ml-10" <template v-else-if="item.INSPECTION_STATUS == '2'"
@click="fnNavigatorPlead(item.INSPECTION_ID)"></u-button> >待被检查人确认</template
</view> >
</view> <template v-else-if="item.INSPECTION_STATUS == '3'"
</u-list-item> >待指派</template
</u-list> >
<empty v-else></empty> <template v-else-if="item.INSPECTION_STATUS == '4'"
</view> >指派中</template
>
<template v-else-if="item.INSPECTION_STATUS == '5'"
>指派完成</template
>
<template v-else-if="item.INSPECTION_STATUS == '6'"
>检查待验收</template
>
<template v-else-if="item.INSPECTION_STATUS == '7'"
>检查已验收</template
>
<template v-else-if="item.INSPECTION_STATUS == '8'"
>已归档</template
>
<template v-else-if="item.INSPECTION_STATUS == '-1'"
>检查人核实打回</template
>
<template v-else-if="item.INSPECTION_STATUS == '-2'"
>被检查人申辩</template
>
</text>
</view>
<view class="flex-end">
<u-button
type="primary"
text="申辩记录"
size="mini"
shape="circle"
@click="fnNavigatorPlead(item.INSPECTION_ID)"
/>
</view>
</template>
</list>
<!-- 列表渲染 end -->
</view>
</template> </template>
<script> <script>
import { getpleadList, getSafetyenvironmentalList } from "../../api"; import { getpleadList, getSafetyenvironmentalList } from "../../api";
import { initiateList } from '../../../Mock/safetyEnvirData'; import keyWordSearchInput from "@/components/keyWordSearchInput/index.vue";
import List from "@/components/list/list.vue";
import { initiateList } from "../../../Mock/safetyEnvirData";
export default { export default {
data() { components: { keyWordSearchInput, List },
return {
keyword: '',
pageSize: 10,
currentPage: 1,
totalPage: 0,
list: [],
}
},
computed: {
userInfo() {
return this.$store.getters.getUserInfo
}
},
onShow() {
this.resetList()
},
methods: {
async getData() {
// TODO: ,
// let resData = await getpleadList({
// loginUserId: this.userInfo.USER_ID,
// supDeparIds: this.userInfo.supDeparIds,
// roleLevel: this.userInfo.roleLevel,
// CORPINFO_ID: this.userInfo.CORPINFO_ID,
// KEYWORDS: this.keyword,
// showCount: this.pageSize,
// currentPage: this.currentPage,
// });
// this.list = [...this.list, ...resData.varList];
// this.totalPage = resData.page.totalPage;
this.list = initiateList; data() {
this.totalPage = initiateList.length; return {
}, searchForm: {
resetList() { HIDDENDESCR: "",
this.pageSize = 10 },
this.currentPage = 1 pageSize: 10,
this.list = [] currentPage: 1,
this.getData() totalPage: 0,
}, list: [],
fnNavigatorPlead(INSPECTION_ID) { };
uni.$u.route({ },
url: '/safetyEnvirSubPackages/pages/defense-record/plead-list', computed: {
params: { userInfo() {
INSPECTION_ID, return this.$store.getters.getUserInfo;
} },
}) },
}, onShow() {
scrolltolower() { this.resetList();
this.currentPage++; },
if (this.totalPage >= this.currentPage) this.getData(); methods: {
}, async getData() {
} uni.showLoading({
} title: "加载中",
});
// TODO: ,
// let resData = await getpleadList({
// loginUserId: this.userInfo.USER_ID,
// supDeparIds: this.userInfo.supDeparIds,
// roleLevel: this.userInfo.roleLevel,
// CORPINFO_ID: this.userInfo.CORPINFO_ID,
// KEYWORDS: this.keyword,
// showCount: this.pageSize,
// currentPage: this.currentPage,
// });
// this.list = [...this.list, ...resData.varList];
// this.totalPage = resData.page.totalPage;
// mock
setTimeout(() => {
this.list = initiateList;
this.totalPage = initiateList.length;
uni.hideLoading();
}, 400);
},
resetList() {
this.pageSize = 10;
this.currentPage = 1;
this.list = [];
this.getData();
},
fnNavigatorPlead(INSPECTION_ID) {
uni.$u.route({
url: "/safetyEnvirSubPackages/pages/defense-record/plead-list",
params: {
INSPECTION_ID,
},
});
},
scrolltolower() {
this.currentPage++;
if (this.totalPage >= this.currentPage) this.getData();
},
},
};
</script> </script>
<style scoped></style> <style scoped></style>

View File

@ -1,165 +1,252 @@
<template> <template>
<view class="content"> <view>
<view class="search card"> <!-- 吸顶搜索框 start -->
<u--text suffixIcon="arrow-down" text="筛选" @click="showPicker"></u--text> <key-word-search-input
<u--input class="ml-10" prefixIcon="search" placeholder="请输入关键字" border="surround" v-model="keyword" clearable :inputSearchValue="searchForm.HIDDENDESCR"
shape="circle"></u--input> @search="resetList"
<u-button class="bth-mini ml-10" type="success" text="确定" @click="resetList"></u-button> is-has-filter
</view> @showPicker="showPicker"
<u-picker :show="show" :columns="columns" keyName="name" @cancel="show = false" @confirm="confirmPicker"></u-picker> />
<u-list @scrolltolower="scrolltolower" v-if="list.length > 0"> <!-- 吸顶搜索框 end -->
<u-list-item v-for="(item, index) in list" :key="index">
<view> <!-- 筛选器 start -->
<view class="flex-between main-title"> <u-picker
<text>被检查单位{{ item.INSPECTED_CORPINFO_ID_NAME }}</text> :show="show"
</view> :columns="columns"
<view class="flex-between mt-10 subtitle"> keyName="name"
<text>检查发起人{{ item.INSPECTION_ORIGINATOR_NAME }}</text> @cancel="show = false"
<text>检查类型{{ item.INSPECTION_TYPE_NAME }}</text> @confirm="confirmPicker"
</view> />
<view class="flex-between mt-10 subtitle"> <!-- 筛选器 end -->
<text>检查时间 {{ item.INSPECTION_TIME_START }} {{ item.INSPECTION_TIME_END }} </text>
</view> <!-- 列表渲染 start -->
<view class="flex-between mt-10 subtitle"> <list :list="list" @scroll-to-lower="scrollToLower">
<text> <template #default="{ item }">
状态 <view class="flex-between main-title">
<template v-if="item.INSPECTION_STATUS == '0'"></template> <text>被检查单位{{ item.INSPECTED_CORPINFO_ID_NAME }}</text>
<template v-else-if="item.INSPECTION_STATUS == '1'">检查人核实中</template> </view>
<template v-else-if="item.INSPECTION_STATUS == '2'">待被检查人确认</template> <view class="flex-between mt-10 subtitle">
<template v-else-if="item.INSPECTION_STATUS == '3'">待指派</template> <text>检查发起人{{ item.INSPECTION_ORIGINATOR_NAME }}</text>
<template v-else-if="item.INSPECTION_STATUS == '4'">指派中</template> <text>检查类型{{ item.INSPECTION_TYPE_NAME }}</text>
<template v-else-if="item.INSPECTION_STATUS == '5'">指派完成</template> </view>
<template v-else-if="item.INSPECTION_STATUS == '6'">检查待验收</template> <view class="flex-between mt-10 subtitle">
<template v-else-if="item.INSPECTION_STATUS == '7'">检查已验收</template> <text
<template v-else-if="item.INSPECTION_STATUS == '8'">已归档</template> >检查时间 {{ item.INSPECTION_TIME_START }}
<template v-else-if="item.INSPECTION_STATUS == '-1'">检查人核实打回</template> {{ item.INSPECTION_TIME_END }} </text
<template v-else-if="item.INSPECTION_STATUS == '-2'">被检查人申辩</template> >
</text> </view>
</view> <view class="flex-between mt-10 subtitle">
<view class="flex-end mt-10"> <text>
<u-button type="primary" text="查看" size="mini" class="bth-mini" 状态
@click="fnNavigatorDetail(item.INSPECTION_ID, 'view')"></u-button> <template v-if="item.INSPECTION_STATUS == '0'"
<u-button type="primary" text="流程图" size="mini" class="bth-mini ml-10" >待检查人核实</template
@click="showFlowChart(item.INSPECTION_ID)"></u-button> >
<u-button type="primary" text="编辑" size="mini" class="bth-mini ml-10" <template v-else-if="item.INSPECTION_STATUS == '1'"
v-show="item.INSPECTION_STATUS === '-1'" @click="fnNavigatorDetail(item.INSPECTION_ID, 'edit')"></u-button> >检查人核实中</template
<u-button type="primary" text="申辩处理" size="mini" class="bth-mini ml-10" >
v-show="item.INSPECTION_STATUS === '-2'" @click="fnNavigatorPlead(item.INSPECTION_ID)"></u-button> <template v-else-if="item.INSPECTION_STATUS == '2'"
</view> >待被检查人确认</template
</view> >
</u-list-item> <template v-else-if="item.INSPECTION_STATUS == '3'"
</u-list> >待指派</template
<empty v-else></empty> >
</view> <template v-else-if="item.INSPECTION_STATUS == '4'"
>指派中</template
>
<template v-else-if="item.INSPECTION_STATUS == '5'"
>指派完成</template
>
<template v-else-if="item.INSPECTION_STATUS == '6'"
>检查待验收</template
>
<template v-else-if="item.INSPECTION_STATUS == '7'"
>检查已验收</template
>
<template v-else-if="item.INSPECTION_STATUS == '8'"
>已归档</template
>
<template v-else-if="item.INSPECTION_STATUS == '-1'"
>检查人核实打回</template
>
<template v-else-if="item.INSPECTION_STATUS == '-2'"
>被检查人申辩</template
>
</text>
</view>
<view class="flex-end">
<view>
<u-button
type="primary"
text="查看"
size="mini"
shape="circle"
@click="fnNavigatorDetail(item.INSPECTION_ID, 'view')"
/>
</view>
<view class="ml-10">
<u-button
type="primary"
text="流程图"
size="mini"
shape="circle"
@click="showFlowChart(item.INSPECTION_ID)"
/>
</view>
<view class="ml-10" v-if="item.INSPECTION_STATUS === '-1'">
<u-button
type="primary"
text="编辑"
size="mini"
shape="circle"
@click="fnNavigatorDetail(item.INSPECTION_ID, 'edit')"
/>
</view>
<view class="ml-10" v-if="item.INSPECTION_STATUS === '-2'">
<u-button
type="primary"
text="申辩处理"
size="mini"
shape="circle"
@click="fnNavigatorPlead(item.INSPECTION_ID)"
/>
</view>
</view>
</template>
</list>
<!-- 列表渲染 end -->
</view>
</template> </template>
<script> <script>
import { getSafetyenvironmentalList } from "../../api"; import { getSafetyenvironmentalList } from "../../api";
import { initiateList } from '../../../Mock/safetyEnvirData'; import keyWordSearchInput from "@/components/keyWordSearchInput/index.vue";
import List from "@/components/list/list.vue";
import { initiateList } from "../../../Mock/safetyEnvirData";
export default { export default {
data() { components: { keyWordSearchInput, List },
return {
show: false,
columns: [
[
{ id: '', name: '请选择' },
{ id: '0', name: '待检查人核实' },
{ id: '1', name: '检查人核实中' },
{ id: '2', name: '待被检查人确认' },
{ id: '3', name: '已归档' },
{ id: '4', name: '指派中' },
{ id: '5', name: '指派完成' },
{ id: '6', name: '待验收' },
{ id: '7', name: '已验收' },
{ id: '-1', name: '检查人核实打回' },
{ id: '-2', name: '被检查人申辩' }
]
],
keyword: '',
INSPECTION_STATUS: '',
pageSize: 10,
currentPage: 1,
totalPage: 0,
list: [],
}
},
onNavigationBarButtonTap(e) {
if (e.index === 0) {
this.fnNavigatorDetail('', 'add');
}
},
computed: {
userInfo() {
return this.$store.getters.getUserInfo
}
},
onShow() {
this.resetList()
},
methods: {
async getData() {
// TODO: ,
// let resData = await getSafetyenvironmentalList({
// loginUserId: this.userInfo.USER_ID,
// supDeparIds: this.userInfo.supDeparIds,
// roleLevel: this.userInfo.roleLevel,
// KEYWORDS: this.keyword,
// INSPECTION_STATUS: this.INSPECTION_STATUS,
// showCount: this.pageSize,
// currentPage: this.currentPage,
// });
// this.list = [...this.list, ...resData.varList];
// this.totalPage = resData.page.totalPage;
this.list = initiateList; data() {
this.totalPage = initiateList.length; return {
}, show: false,
resetList() { columns: [
this.pageSize = 10 [
this.currentPage = 1 { id: "", name: "请选择" },
this.list = [] { id: "0", name: "待检查人核实" },
this.getData() { id: "1", name: "检查人核实中" },
}, { id: "2", name: "待被检查人确认" },
showPicker() { { id: "3", name: "已归档" },
this.show = true; { id: "4", name: "指派中" },
}, { id: "5", name: "指派完成" },
confirmPicker(e) { { id: "6", name: "待验收" },
this.INSPECTION_STATUS = e.value[0].id { id: "7", name: "已验收" },
this.show = false; { id: "-1", name: "检查人核实打回" },
this.resetList() { id: "-2", name: "被检查人申辩" },
}, ],
fnNavigatorDetail(INSPECTION_ID, type) { ],
uni.$u.route({ searchForm: {
url: '/safetyEnvirSubPackages/pages/initiate/detail', HIDDENDESCR: "",
params: { },
INSPECTION_ID, INSPECTION_STATUS: "",
type pageSize: 10,
} currentPage: 1,
}) totalPage: 0,
}, list: [],
// };
fnNavigatorPlead(INSPECTION_ID) { },
uni.$u.route({ onNavigationBarButtonTap(e) {
url: '/safetyEnvirSubPackages/pages/initiate/plead', if (e.index === 0) {
params: { this.fnNavigatorDetail("", "add");
INSPECTION_ID, }
} },
}) computed: {
}, userInfo() {
// return this.$store.getters.getUserInfo;
scrolltolower() { },
this.currentPage++; },
if (this.totalPage >= this.currentPage) this.getData(); onShow() {
}, this.resetList();
// },
showFlowChart(id) { methods: {
uni.navigateTo({ async getData() {
url: '/safetyEnvirSubPackages/pages/initiate/steps?ID=' + id uni.showLoading({
}); title: "加载中",
}, });
} // TODO: ,
} // let resData = await getSafetyenvironmentalList({
// loginUserId: this.userInfo.USER_ID,
// supDeparIds: this.userInfo.supDeparIds,
// roleLevel: this.userInfo.roleLevel,
// KEYWORDS: this.keyword,
// INSPECTION_STATUS: this.INSPECTION_STATUS,
// showCount: this.pageSize,
// currentPage: this.currentPage,
// });
// this.list = [...this.list, ...resData.varList];
// this.totalPage = resData.page.totalPage;
// mock
setTimeout(() => {
this.list = initiateList;
this.totalPage = initiateList.length;
uni.hideLoading();
}, 400);
},
resetList() {
this.pageSize = 10;
this.currentPage = 1;
this.list = [];
this.getData();
},
showPicker() {
this.show = true;
},
confirmPicker(e) {
this.INSPECTION_STATUS = e.value[0].id;
this.show = false;
this.resetList();
},
fnNavigatorDetail(INSPECTION_ID, type) {
uni.$u.route({
url: "/safetyEnvirSubPackages/pages/initiate/detail",
params: {
INSPECTION_ID,
type,
},
});
},
/**
* 申辩处理按钮事件
*/
fnNavigatorPlead(INSPECTION_ID) {
uni.$u.route({
url: "/safetyEnvirSubPackages/pages/initiate/plead",
params: {
INSPECTION_ID,
},
});
},
/**
* 滚动加载数据
*/
scrolltolower() {
this.currentPage++;
if (this.totalPage >= this.currentPage) this.getData();
},
/**
* 查看流程图
*/
showFlowChart(id) {
uni.navigateTo({
url: "/safetyEnvirSubPackages/pages/initiate/steps?ID=" + id,
});
},
},
};
</script> </script>
<style scoped lang="scss"></style> <style scoped lang="scss">
.self-time {
font-size: 14px;
}
</style>

View File

@ -1,121 +1,184 @@
<template> <template>
<view class="content"> <view>
<view class="search card"> <!-- 吸顶搜索框 start -->
<u--input prefixIcon="search" placeholder="请输入关键字" border="surround" v-model="keyword" clearable <key-word-search-input
shape="circle"></u--input> :inputSearchValue="searchForm.HIDDENDESCR"
<u-button class="bth-mini ml-10" type="success" text="确定" @click="resetList"></u-button> @search="resetList"
</view> @showPicker="showPicker"
<u-list @scrolltolower="scrolltolower" v-if="list.length > 0"> />
<u-list-item v-for="(item, index) in list" :key="index"> <!-- 吸顶搜索框 end -->
<view>
<view class="flex-between main-title"> <!-- 列表渲染 start -->
<text>被检查单位{{ item.INSPECTED_CORPINFO_ID_NAME }}</text> <list :list="list" @scroll-to-lower="scrollToLower">
</view> <template #default="{ item }">
<view class="flex-between mt-10 subtitle"> <view class="flex-between main-title">
<text>检查发起人{{ item.INSPECTION_ORIGINATOR_NAME }}</text> <text>被检查单位{{ item.INSPECTED_CORPINFO_ID_NAME }}</text>
<text>检查类型{{ item.INSPECTION_TYPE_NAME }}</text> </view>
</view> <view class="flex-between mt-10 subtitle">
<view class="flex-between mt-10 subtitle"> <text>检查发起人{{ item.INSPECTION_ORIGINATOR_NAME }}</text>
<text>检查时间 {{ item.INSPECTION_TIME_START }} {{ item.INSPECTION_TIME_END }} </text> <text>检查类型{{ item.INSPECTION_TYPE_NAME }}</text>
</view> </view>
<view class="flex-between mt-10 subtitle"> <view class="flex-between mt-10 subtitle">
<text> <text
状态 >检查时间 {{ item.INSPECTION_TIME_START }}
<template v-if="item.INSPECTION_STATUS == '0'"></template> {{ item.INSPECTION_TIME_END }} </text
<template v-else-if="item.INSPECTION_STATUS == '1'">检查人核实中</template> >
<template v-else-if="item.INSPECTION_STATUS == '2'">待被检查人确认</template> </view>
<template v-else-if="item.INSPECTION_STATUS == '3'">待指派</template> <view class="flex-between mt-10 subtitle">
<template v-else-if="item.INSPECTION_STATUS == '4'">指派中</template> <text>
<template v-else-if="item.INSPECTION_STATUS == '5'">指派完成</template> 状态
<template v-else-if="item.INSPECTION_STATUS == '6'">检查待验收</template> <template v-if="item.INSPECTION_STATUS == '0'"
<template v-else-if="item.INSPECTION_STATUS == '7'">检查已验收</template> >待检查人核实</template
<template v-else-if="item.INSPECTION_STATUS == '8'">已归档</template> >
<template v-else-if="item.INSPECTION_STATUS == '-1'">检查人核实打回</template> <template v-else-if="item.INSPECTION_STATUS == '1'"
<template v-else-if="item.INSPECTION_STATUS == '-2'">被检查人申辩</template> >检查人核实中</template
</text> >
</view> <template v-else-if="item.INSPECTION_STATUS == '2'"
<view class="flex-end mt-10"> >待被检查人确认</template
<u-button type="primary" text="查看" size="mini" class="bth-mini" >
@click="fnNavigatorDetail(item.INSPECTION_ID)"></u-button> <template v-else-if="item.INSPECTION_STATUS == '3'"
<u-button >待指派</template
v-show="(item.INSPECTION_STATUS === '6' || item.INSPECTION_STATUS === '5' || item.INSPECTION_STATUS === '7') && item.checkout === 1" >
type="primary" text="验收" size="mini" class="bth-mini ml-10" <template v-else-if="item.INSPECTION_STATUS == '4'"
@click="fnNavigatorAcceptance(item.INSPECTION_ID)"></u-button> >指派中</template
</view> >
</view> <template v-else-if="item.INSPECTION_STATUS == '5'"
</u-list-item> >指派完成</template
</u-list> >
<empty v-else></empty> <template v-else-if="item.INSPECTION_STATUS == '6'"
</view> >检查待验收</template
>
<template v-else-if="item.INSPECTION_STATUS == '7'"
>检查已验收</template
>
<template v-else-if="item.INSPECTION_STATUS == '8'"
>已归档</template
>
<template v-else-if="item.INSPECTION_STATUS == '-1'"
>检查人核实打回</template
>
<template v-else-if="item.INSPECTION_STATUS == '-2'"
>被检查人申辩</template
>
</text>
</view>
<view class="flex-end">
<view>
<u-button
type="primary"
text="查看"
size="mini"
shape="circle"
@click="fnNavigatorDetail(item.INSPECTION_ID)"
/>
</view>
<view
class="ml-10"
v-if="
(item.INSPECTION_STATUS === '6' ||
item.INSPECTION_STATUS === '5' ||
item.INSPECTION_STATUS === '7') &&
item.checkout === 1
"
>
<u-button
type="primary"
text="验收"
size="mini"
shape="circle"
@click="fnNavigatorAcceptance(item.INSPECTION_ID)"
></u-button>
</view>
</view>
</template>
</list>
</view>
</template> </template>
<script> <script>
import { getSafetyenvironmentalCheckList, getSafetyenvironmentalList } from "../../api"; import {
import { initiateList } from '../../../Mock/safetyEnvirData'; getSafetyenvironmentalCheckList,
getSafetyenvironmentalList,
} from "../../api";
import keyWordSearchInput from "@/components/keyWordSearchInput/index.vue";
import List from "@/components/list/list.vue";
import { initiateList } from "../../../Mock/safetyEnvirData";
export default { export default {
data() { components: { keyWordSearchInput, List },
return {
keyword: '',
pageSize: 10,
currentPage: 1,
totalPage: 0,
list: [],
}
},
computed: {
userInfo() {
return this.$store.getters.getUserInfo
}
},
onShow() {
this.resetList()
},
methods: {
async getData() {
// TODO: ,
// let resData = await getSafetyenvironmentalCheckList({
// INSPECTION_ORIGINATOR_ID: this.userInfo.USER_ID,
// KEYWORDS: this.keyword,
// INSPECTION_STATUS: '3-7',
// showCount: this.pageSize,
// currentPage: this.currentPage,
// ARCHIVE_USER_ID: this.userInfo.USER_ID
// });
// this.list = [...this.list, ...resData.varList];
// this.totalPage = resData.page.totalPage;
this.list = initiateList; data() {
this.totalPage = initiateList.length; return {
}, searchForm: {
resetList() { HIDDENDESCR: "",
this.pageSize = 10 },
this.currentPage = 1 pageSize: 10,
this.list = [] currentPage: 1,
this.getData() totalPage: 0,
}, list: [],
fnNavigatorDetail(INSPECTION_ID) { };
uni.$u.route({ },
url: '/safetyEnvirSubPackages/pages/inspector-archives/detail', computed: {
params: { userInfo() {
INSPECTION_ID, return this.$store.getters.getUserInfo;
} },
}) },
}, onShow() {
fnNavigatorAcceptance(INSPECTION_ID) { this.resetList();
uni.$u.route({ },
url: '/safetyEnvirSubPackages/pages/inspector-archives/acceptance-list', methods: {
params: { async getData() {
INSPECTION_ID, uni.showLoading({
} title: "加载中",
}) });
}, // TODO: ,
scrolltolower() { // let resData = await getSafetyenvironmentalCheckList({
this.currentPage++; // INSPECTION_ORIGINATOR_ID: this.userInfo.USER_ID,
if (this.totalPage >= this.currentPage) this.getData(); // KEYWORDS: this.keyword,
}, // INSPECTION_STATUS: '3-7',
} // showCount: this.pageSize,
} // currentPage: this.currentPage,
// ARCHIVE_USER_ID: this.userInfo.USER_ID
// });
// this.list = [...this.list, ...resData.varList];
// this.totalPage = resData.page.totalPage;
// mock
setTimeout(() => {
this.list = initiateList;
this.totalPage = initiateList.length;
uni.hideLoading();
}, 400);
},
resetList() {
this.pageSize = 10;
this.currentPage = 1;
this.list = [];
this.getData();
},
fnNavigatorDetail(INSPECTION_ID) {
uni.$u.route({
url: "/safetyEnvirSubPackages/pages/inspector-archives/detail",
params: {
INSPECTION_ID,
},
});
},
fnNavigatorAcceptance(INSPECTION_ID) {
uni.$u.route({
url: "/safetyEnvirSubPackages/pages/inspector-archives/acceptance-list",
params: {
INSPECTION_ID,
},
});
},
scrolltolower() {
this.currentPage++;
if (this.totalPage >= this.currentPage) this.getData();
},
},
};
</script> </script>
<style scoped lang="scss"></style> <style scoped lang="scss"></style>

View File

@ -1,119 +1,215 @@
<template> <template>
<view class="content"> <view>
<view class="search card"> <!-- 吸顶搜索框 start -->
<u--input prefixIcon="search" placeholder="请输入关键字" border="surround" v-model="keyword" clearable <key-word-search-input
shape="circle"></u--input> :inputSearchValue="searchForm.HIDDENDESCR"
<u-button class="bth-mini ml-10" type="success" text="确定" @click="resetList"></u-button> @search="resetList"
</view> @showPicker="showPicker"
<u-list @scrolltolower="scrolltolower" v-if="list.length > 0"> />
<u-list-item v-for="(item, index) in list" :key="index"> <!-- 吸顶搜索框 end -->
<view>
<view class="flex-between main-title"> <!-- 列表渲染 start -->
<text>被检查单位{{ item.INSPECTED_CORPINFO_ID_NAME }}</text> <list :list="list" @scroll-to-lower="scrollToLower">
</view> <template #default="{ item }">
<view class="flex-between mt-10 subtitle"> <view class="flex-between main-title">
<text>检查发起人{{ item.INSPECTION_ORIGINATOR_NAME }}</text> <text>被检查单位{{ item.INSPECTED_CORPINFO_ID_NAME }}</text>
<text>检查类型{{ item.INSPECTION_TYPE_NAME }}</text> </view>
</view> <view class="flex-between mt-10 subtitle">
<view class="flex-between mt-10 subtitle"> <text>检查发起人{{ item.INSPECTION_ORIGINATOR_NAME }}</text>
<text>检查时间 {{ item.INSPECTION_TIME_START }} {{ item.INSPECTION_TIME_END }} </text> <text>检查类型{{ item.INSPECTION_TYPE_NAME }}</text>
</view> </view>
<view class="flex-between mt-10 subtitle"> <view class="flex-between mt-10 subtitle">
<text> <text
状态 >检查时间 {{ item.INSPECTION_TIME_START }}
<template v-if="item.INSPECTION_STATUS == '0'"></template> {{ item.INSPECTION_TIME_END }} </text
<template v-else-if="item.INSPECTION_STATUS == '1'">检查人核实中</template> >
<template v-else-if="item.INSPECTION_STATUS == '2'">待被检查人确认</template> </view>
<template v-else-if="item.INSPECTION_STATUS == '3'">待指派</template> <view class="flex-between mt-10 subtitle">
<template v-else-if="item.INSPECTION_STATUS == '4'">指派中</template> <text>
<template v-else-if="item.INSPECTION_STATUS == '5'">指派完成</template> 状态
<template v-else-if="item.INSPECTION_STATUS == '6'">检查待验收</template> <template v-if="item.INSPECTION_STATUS == '0'"
<template v-else-if="item.INSPECTION_STATUS == '7'">检查已验收</template> >待检查人核实</template
<template v-else-if="item.INSPECTION_STATUS == '8'">已归档</template> >
<template v-else-if="item.INSPECTION_STATUS == '-1'">检查人核实打回</template> <template v-else-if="item.INSPECTION_STATUS == '1'"
<template v-else-if="item.INSPECTION_STATUS == '-2'">被检查人申辩</template> >检查人核实中</template
</text> >
</view> <template v-else-if="item.INSPECTION_STATUS == '2'"
<view class="flex-end mt-10"> >待被检查人确认</template
<u-button type="primary" text="查看" size="mini" class="bth-mini" >
@click="fnNavigatorDetail(item.INSPECTION_ID, item.INSPECTION_USER_ID, item.INSPECTION_INSPECTOR_ID, 'view')"></u-button> <template v-else-if="item.INSPECTION_STATUS == '3'"
<u-button >待指派</template
v-if="!validStr(item.INSPECTION_USER_SIGN_TIME) && (item.INSPECTION_STATUS == '0' || item.INSPECTION_STATUS == '1')" >
type="primary" text="核实" size="mini" class="bth-mini ml-10" <template v-else-if="item.INSPECTION_STATUS == '4'"
@click="fnNavigatorDetail(item.INSPECTION_ID, item.INSPECTION_USER_ID, item.INSPECTION_INSPECTOR_ID, 'verify')"></u-button> >指派中</template
</view> >
</view> <template v-else-if="item.INSPECTION_STATUS == '5'"
</u-list-item> >指派完成</template
</u-list> >
<empty v-else></empty> <template v-else-if="item.INSPECTION_STATUS == '6'"
</view> >检查待验收</template
>
<template v-else-if="item.INSPECTION_STATUS == '7'"
>检查已验收</template
>
<template v-else-if="item.INSPECTION_STATUS == '8'"
>已归档</template
>
<template v-else-if="item.INSPECTION_STATUS == '-1'"
>检查人核实打回</template
>
<template v-else-if="item.INSPECTION_STATUS == '-2'"
>被检查人申辩</template
>
</text>
</view>
<view class="flex-end">
<u-button
type="primary"
text="查看"
size="mini"
shape="circle"
@click="
fnNavigatorDetail(
item.INSPECTION_ID,
item.INSPECTION_USER_ID,
item.INSPECTION_INSPECTOR_ID,
'view'
)
"
/>
<view class="ml-10">
<u-button
type="primary"
text="流程图"
size="mini"
shape="circle"
@click="showFlowChart(item.INSPECTION_ID)"
/>
</view>
<view
class="ml-10"
v-if="
!validStr(item.INSPECTION_USER_SIGN_TIME) &&
(item.INSPECTION_STATUS == '0' || item.INSPECTION_STATUS == '1')
"
>
<u-button
type="primary"
text="核实"
size="mini"
shape="circle"
@click="
fnNavigatorDetail(
item.INSPECTION_ID,
item.INSPECTION_USER_ID,
item.INSPECTION_INSPECTOR_ID,
'verify'
)
"
/>
</view>
</view>
</template>
</list>
</view>
</template> </template>
<script> <script>
import { getSafetyenvironmentalinspectorList } from "../../api"; import { getSafetyenvironmentalinspectorList } from "../../api";
import { initiateList } from '../../../Mock/safetyEnvirData'; import keyWordSearchInput from "@/components/keyWordSearchInput/index.vue";
import List from "@/components/list/list.vue";
import { initiateList } from "../../../Mock/safetyEnvirData";
export default { export default {
data() { components: { keyWordSearchInput, List },
return {
keyword: '',
INSPECTION_STATUS: '',
pageSize: 10,
currentPage: 1,
totalPage: 0,
list: [],
}
},
computed: {
userInfo() {
return this.$store.getters.getUserInfo
}
},
onShow() {
this.resetList()
},
methods: {
validStr(str) {
if (str != null && str != '' && typeof (str) != 'undefined' && str != 'undefined' && str != 0 && str != 'null') { return true }
return false
},
async getData() {
// TODO: ,
// let resData = await getSafetyenvironmentalinspectorList({
// INSPECTION_USER_ID: this.userInfo.USER_ID,
// KEYWORDS: this.keyword,
// showCount: this.pageSize,
// currentPage: this.currentPage,
// });
// this.list = [...this.list,...resData.varList];
// this.totalPage = resData.page.totalPage;
this.list = initiateList; data() {
this.totalPage = initiateList.length; return {
}, searchForm: {
resetList() { HIDDENDESCR: "",
this.pageSize = 10 },
this.currentPage = 1 INSPECTION_STATUS: "",
this.list = [] pageSize: 10,
this.getData() currentPage: 1,
}, totalPage: 0,
fnNavigatorDetail(INSPECTION_ID, INSPECTION_USER_ID, INSPECTION_INSPECTOR_ID, type) { list: [],
uni.$u.route({ };
url: '/safetyEnvirSubPackages/pages/inspector-confirms/detail', },
params: { computed: {
INSPECTION_ID, userInfo() {
INSPECTION_USER_ID, return this.$store.getters.getUserInfo;
INSPECTION_INSPECTOR_ID, },
type },
} onShow() {
}) this.resetList();
}, },
scrolltolower() { methods: {
this.currentPage++; validStr(str) {
if (this.totalPage >= this.currentPage) this.getData(); if (
}, str != null &&
} str != "" &&
} typeof str != "undefined" &&
str != "undefined" &&
str != 0 &&
str != "null"
) {
return true;
}
return false;
},
async getData() {
uni.showLoading({
title: "加载中",
});
// TODO: ,
// let resData = await getSafetyenvironmentalinspectorList({
// INSPECTION_USER_ID: this.userInfo.USER_ID,
// KEYWORDS: this.keyword,
// showCount: this.pageSize,
// currentPage: this.currentPage,
// });
// this.list = [...this.list,...resData.varList];
// this.totalPage = resData.page.totalPage;
// mock
setTimeout(() => {
this.list = initiateList;
this.totalPage = initiateList.length;
uni.hideLoading();
}, 400);
},
resetList() {
this.pageSize = 10;
this.currentPage = 1;
this.list = [];
this.getData();
},
fnNavigatorDetail(
INSPECTION_ID,
INSPECTION_USER_ID,
INSPECTION_INSPECTOR_ID,
type
) {
uni.$u.route({
url: "/safetyEnvirSubPackages/pages/inspector-confirms/detail",
params: {
INSPECTION_ID,
INSPECTION_USER_ID,
INSPECTION_INSPECTOR_ID,
type,
},
});
},
/**
* 滚动加载数据
*/
scrolltolower() {
this.currentPage++;
if (this.totalPage >= this.currentPage) this.getData();
},
},
};
</script> </script>
<style scoped lang="scss"></style> <style scoped lang="scss"></style>

View File

@ -1,4 +1,4 @@
let requestPath = "http://192.168.0.115:8088"; let requestPath = "http://192.168.0.112:8088";
// let requestPath = 'http://192.168.0.31:8992/qa-prevention-xgf/'; // 后台请求地址 // let requestPath = 'http://192.168.0.31:8992/qa-prevention-xgf/'; // 后台请求地址
// let requestPath = 'https://skqhdg.porthebei.com:9006/qa-prevention-xgf/'; // 后台请求地址 // let requestPath = 'https://skqhdg.porthebei.com:9006/qa-prevention-xgf/'; // 后台请求地址
// let requestPath = 'https://qgxgf.qhdsafety.com/qa-prevention-xgf/'; // 外网地址 // let requestPath = 'https://qgxgf.qhdsafety.com/qa-prevention-xgf/'; // 外网地址