Commit e2c1843e authored by 王李辉's avatar 王李辉

隐患巡查模块模拟接口还原

parent a8042319
...@@ -11,11 +11,11 @@ ...@@ -11,11 +11,11 @@
<div @click="onSearch" >搜索</div> <div @click="onSearch" >搜索</div>
</template> </template>
</van-search> </van-search>
<van-cell-group inset v-if="finalDangerList.length > 0"> <van-cell-group inset v-if="dangerList.length > 0">
<van-grid :column-num="4"> <van-grid :column-num="4">
<van-grid-item <van-grid-item
@click="dangerJump(item.path)" @click="dangerJump(item.path)"
v-for="item in finalDangerList" v-for="item in dangerList"
:key="item.key" :key="item.key"
:icon="item.imgUrl" :icon="item.imgUrl"
:text="item.text" :text="item.text"
...@@ -60,6 +60,7 @@ export default { ...@@ -60,6 +60,7 @@ export default {
return { return {
text: "隐患巡查", text: "隐患巡查",
finalDangerList:[], finalDangerList:[],
value:"",
dangerList:[ dangerList:[
{ {
key: "1", key: "1",
...@@ -86,7 +87,7 @@ export default { ...@@ -86,7 +87,7 @@ export default {
path: "/approval-patrol", path: "/approval-patrol",
}, },
{ {
key: "4", key: "5",
imgUrl: require("@/assets/workbench/danger-acceptance.png"), imgUrl: require("@/assets/workbench/danger-acceptance.png"),
text: "巡查统计", text: "巡查统计",
path: "/statistics", path: "/statistics",
...@@ -143,7 +144,7 @@ export default { ...@@ -143,7 +144,7 @@ export default {
}, },
created() { created() {
// 根据权限显示对应的图标 // 根据权限显示对应的图标
this.getWorkList(); // this.getWorkList();
}, },
mounted() {}, mounted() {},
methods: { methods: {
......
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
<!-- v-for="(item, index) in messageList" <!-- v-for="(item, index) in messageList"
:key="index" :key="index"
@click="touchstart(index, item)"--> @click="touchstart(index, item)"-->
<van-cell-group inset> <van-cell-group inset @click="touchstart">
<van-row gutte> <van-row gutte>
<van-col span="12"> <van-col span="12">
<span class="record-time">2022年4月8日</span> <span class="record-time">2022年4月8日</span>
...@@ -36,9 +36,9 @@ ...@@ -36,9 +36,9 @@
</van-row> </van-row>
<!-- 长按显示遮罩层 --> <!-- 长按显示遮罩层 -->
<!-- :show="showIndex == index" --> <!-- :show="showIndex == index" -->
<van-overlay :show="true"> <van-overlay :show="showIndex">
<div class="wrapper" @click.stop="showIndex = null"> <div class="wrapper" @click.stop="showIndex = null">
<van-button round type="primary" @click="goDetail(item)">详情</van-button> <van-button round type="primary" @click="goDetail()">详情</van-button>
</div> </div>
</van-overlay> </van-overlay>
</van-cell-group> </van-cell-group>
...@@ -90,7 +90,7 @@ export default { ...@@ -90,7 +90,7 @@ export default {
}; };
}, },
created() { created() {
this.getList(); // this.getList();
}, },
methods: { methods: {
getList(select = "") { getList(select = "") {
...@@ -122,11 +122,12 @@ export default { ...@@ -122,11 +122,12 @@ export default {
}, },
touchstart(index, item) { touchstart(index, item) {
if (this.showIndex != null) { // if (this.showIndex != null) {
this.showIndex = null; // this.showIndex = null;
return; // return;
} // }
this.showIndex = index; // this.showIndex = index;
this.showIndex = true
}, },
// 详情 // 详情
......
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