From bd25d9a8a058e8c618ee4188ed5f15a898c0f7e8 Mon Sep 17 00:00:00 2001
From: jiangping <jp@doumee.com>
Date: 星期六, 27 一月 2024 11:43:37 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'

---
 platform/src/views/business/anchor.vue |  108 ++++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 files changed, 108 insertions(+), 0 deletions(-)

diff --git a/platform/src/views/business/anchor.vue b/platform/src/views/business/anchor.vue
new file mode 100644
index 0000000..bddb751
--- /dev/null
+++ b/platform/src/views/business/anchor.vue
@@ -0,0 +1,108 @@
+<template>
+  <TableLayout :permissions="['business:companyUser:query']">
+    <!-- 鎼滅储琛ㄥ崟 -->
+    <el-form ref="searchForm" slot="search-form" :model="searchForm" label-width="100px" inline>
+      <el-form-item label="浼佷笟鍚嶇О" prop="companyName">
+        <el-input v-model="searchForm.companyName" placeholder="璇疯緭鍏ヤ紒涓氬悕绉�" @keypress.enter.native="search"></el-input>
+      </el-form-item>
+      <!-- <el-form-item label="浼佷笟绠�绉�" prop="shortName">
+        <el-input v-model="searchForm.shortName" placeholder="璇疯緭鍏ヤ紒涓氱畝绉�" @keypress.enter.native="search"></el-input>
+      </el-form-item> -->
+      <el-form-item label="璐﹀彿淇℃伅" prop="keyWords">
+        <el-input v-model="searchForm.keyWords" placeholder="璇疯緭鍏ョ櫥褰曡处鍙�/濮撳悕" @keypress.enter.native="search"></el-input>
+      </el-form-item>
+      <el-form-item label="鐘舵��" prop="status">
+        <el-select v-model="searchForm.status" clearable placeholder="璇烽�夋嫨" @change="search">
+          <el-option label="鍚敤" :value="0"></el-option>
+          <el-option label="绂佺敤" :value="1"></el-option>
+        </el-select>
+      </el-form-item>
+      <section>
+        <el-button type="primary" @click="search">鎼滅储</el-button>
+        <el-button @click="reset">閲嶇疆</el-button>
+      </section>
+    </el-form>
+    <!-- 琛ㄦ牸鍜屽垎椤� -->
+    <template v-slot:table-wrap>
+      <el-table v-loading="isWorking.search" :data="tableData.list" border stripe
+        @selection-change="handleSelectionChange">
+        <!-- <el-table-column type="selection" width="55" align="center"></el-table-column> -->
+        <el-table-column prop="companyName" label="浼佷笟鍚嶇О" min-width="100px" align="center"></el-table-column>
+        <el-table-column prop="username" label="鐧诲綍璐﹀彿" min-width="100px" align="center"></el-table-column>
+        <el-table-column prop="realname" label="濮撳悕" min-width="100px" align="center"></el-table-column>
+        <el-table-column prop="mobile" label="鎵嬫満鍙�" min-width="100px" align="center"></el-table-column>
+        <el-table-column prop="status" label="鐘舵��" min-width="100px" align="center">
+          <template slot-scope="{row}">
+            <!-- 0鍚敤 1绂佺敤 -->
+            <el-switch :disabled="!containPermissions(['business:companyUser:update'])" v-model="row.status"
+              :inactive-value="1" :active-value="0" @change="changeStatus(row)">
+            </el-switch>
+          </template>
+
+        </el-table-column>
+        <el-table-column prop="createTime" label="鍒涘缓鏃堕棿" min-width="140px" align="center"></el-table-column>
+      </el-table>
+      <pagination @size-change="handleSizeChange" @current-change="handlePageChange" :pagination="tableData.pagination">
+      </pagination>
+    </template>
+
+  </TableLayout>
+</template>
+
+<script>
+import BaseTable from '@/components/base/BaseTable'
+import TableLayout from '@/layouts/TableLayout'
+import Pagination from '@/components/common/Pagination'
+import { updateById } from '@/api/system/user'
+export default {
+  name: 'Company',
+  extends: BaseTable,
+  components: { TableLayout, Pagination },
+  data() {
+    return {
+      oepnValidDate: [],
+      // 鎼滅储
+      searchForm: {
+        companyName: '',
+        keyWords: '',
+        status: '',
+        type: 2
+      }
+    }
+  },
+  created() {
+    this.config({
+      module: '绯荤粺-浼佷笟淇℃伅琛�',
+      api: '/business/companyUser',
+      'field.id': 'id',
+      'field.main': 'id'
+    })
+    this.search()
+  },
+  methods: {
+    selectOepnValidDate(v) {
+      [this.searchForm.oepnValidDateStart, this.searchForm.oepnValidDateEnd] = v
+    },
+    reset() {
+      // this.reset()
+      this.$refs.searchForm.resetFields()
+      this.searchForm.oepnValidDateStart = ''
+      this.searchForm.oepnValidDateEnd = ''
+      this.oepnValidDate = []
+      this.search()
+    },
+    changeStatus(row) {
+      updateById(row)
+        .then(() => {
+          this.$tip.apiSuccess('鏇存柊鎴愬姛')
+        })
+        .catch(err => {
+          this.$tip.apiFailed(err)
+        })
+        .finally(() => {
+          this.handlePageChange()
+        })
+    }
+  },
+}
+</script>

--
Gitblit v1.9.3