Browse Source

Merge branch 'dev' of http://git.elinkit.com.cn:7070/r/epmet-oper-gov into dev

shibei_master
jiangyy 3 years ago
parent
commit
be22f1fa0d
  1. 36
      src/views/modules/communityService/dqfwzx/index.vue

36
src/views/modules/communityService/dqfwzx/index.vue

@ -16,13 +16,11 @@
:class="{ 'z-on': currentIndex == index }" :class="{ 'z-on': currentIndex == index }"
:key="'ct' + index" :key="'ct' + index"
v-for="(item, index) in tableData"> v-for="(item, index) in tableData">
<div class="item-btns"> <div class="item-btn"
<a v-if="currentIndex == index" v-if="currentIndex == index"
@click="handleEdit">修改</a> @click="handleEdit">
<a v-if="currentIndex == index" 修改
@click="handleDel">删除</a>
</div> </div>
<div class="item-name">{{ item.centerName }}</div> <div class="item-name">{{ item.centerName }}</div>
<div class="item-prop"> <div class="item-prop">
<div class="prop-field">社区地址</div> <div class="prop-field">社区地址</div>
@ -138,7 +136,7 @@
</template> </template>
<script> <script>
import { requestPost } from "@/js/dai/request2"; import { requestPost } from "@/js/dai/request";
import nextTick from "dai-js/tools/nextTick"; import nextTick from "dai-js/tools/nextTick";
import { mapGetters } from "vuex"; import { mapGetters } from "vuex";
import editForm from "./cpts/edit"; import editForm from "./cpts/edit";
@ -294,19 +292,21 @@ export default {
this.$refs.eleOrderList.init(this.tableData[this.currentIndex], index); this.$refs.eleOrderList.init(this.tableData[this.currentIndex], index);
}, },
async handleDel () { async handleDel (rowData, rowIndex) {
if (!confirm("删除后不可恢复,确定删除?")) return; console.log(rowData, rowIndex);
const url =
const item = this.tableData[this.currentIndex]; "/heart/iccommunityselforganization/delcommunityselforganization";
const url = "/gov/org/icpartyservicecenter/del"; const { tableData } = this;
const { data, code, msg } = await requestPost(url, [ const { data, code, msg } = await requestPost(url, {
item.partyServiceCenterId, orgId: tableData[rowIndex].orgId,
]); });
if (code === 0) { if (code === 0) {
this.$message.success("删除成功!"); this.$message.success("删除成功!");
this.getTableData(); this.getTableData();
} else {
this.$message.success("操作失败!");
} }
}, },
@ -339,6 +339,8 @@ export default {
if (code === 0) { if (code === 0) {
this.agencyId = data.agencyId; this.agencyId = data.agencyId;
} else {
this.$message.error(msg);
} }
}, },
}, },
@ -392,8 +394,7 @@ export default {
background-color: #ffffff; background-color: #ffffff;
box-shadow: 0 0 10px #6aa; box-shadow: 0 0 10px #6aa;
} }
.item-btn {
.item-btns {
position: absolute; position: absolute;
top: 5px; top: 5px;
right: 5px; right: 5px;
@ -408,7 +409,6 @@ export default {
color: #00a7a9; color: #00a7a9;
} }
} }
.item-name { .item-name {
font-size: 16px; font-size: 16px;
font-weight: bold; font-weight: bold;

Loading…
Cancel
Save