|
@@ -20,6 +20,9 @@
|
|
<el-option v-for="item in leaderList" :key="item._id" :label="item.name" :value="item._id"> </el-option>
|
|
<el-option v-for="item in leaderList" :key="item._id" :label="item.name" :value="item._id"> </el-option>
|
|
</el-select>
|
|
</el-select>
|
|
</template>
|
|
</template>
|
|
|
|
+ <template #status>
|
|
|
|
+ <el-option v-for="i in statusList" :key="i.value" :label="i.label" :value="i.value"></el-option>
|
|
|
|
+ </template>
|
|
</data-search>
|
|
</data-search>
|
|
<data-btn :fields="btnList" @add="toAdd"></data-btn>
|
|
<data-btn :fields="btnList" @add="toAdd"></data-btn>
|
|
<data-table
|
|
<data-table
|
|
@@ -81,6 +84,7 @@ export default {
|
|
searchFields: [
|
|
searchFields: [
|
|
{ label: '商品名称', model: 'goods', custom: true },
|
|
{ label: '商品名称', model: 'goods', custom: true },
|
|
{ label: '团长', model: 'leader', custom: true },
|
|
{ label: '团长', model: 'leader', custom: true },
|
|
|
|
+ { label: '状态', model: 'status', type: 'select' },
|
|
],
|
|
],
|
|
searchInfo: {},
|
|
searchInfo: {},
|
|
list: [],
|
|
list: [],
|
|
@@ -105,6 +109,7 @@ export default {
|
|
...group(['query', 'delete', 'fetch', 'update', 'create']),
|
|
...group(['query', 'delete', 'fetch', 'update', 'create']),
|
|
// 查询
|
|
// 查询
|
|
async search({ skip = 0, limit = this.$limit, ...others } = {}) {
|
|
async search({ skip = 0, limit = this.$limit, ...others } = {}) {
|
|
|
|
+ // others.status = '0';
|
|
let query = { skip, limit, ...others };
|
|
let query = { skip, limit, ...others };
|
|
if (Object.keys(this.searchInfo).length > 0) query = { ...query, ...this.searchInfo };
|
|
if (Object.keys(this.searchInfo).length > 0) query = { ...query, ...this.searchInfo };
|
|
const res = await this.query(query);
|
|
const res = await this.query(query);
|