You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
121 lines
4.4 KiB
121 lines
4.4 KiB
<template>
|
|
<div class="app-container">
|
|
<el-row>
|
|
<el-form :inline="true">
|
|
<el-form-item>
|
|
<el-input v-model="queryParams.productName" placeholder="请输入商品名称" />
|
|
</el-form-item>
|
|
<el-form-item>
|
|
<el-input v-model="queryParams.productCode" placeholder="请输入商品编码" />
|
|
</el-form-item>
|
|
<el-form-item>
|
|
<el-cascader placeholder="请选择商品分类" v-model="queryParams.productCategory"
|
|
:options="categoryOptions"></el-cascader>
|
|
</el-form-item>
|
|
<el-form-item>
|
|
<el-select v-model="queryParams.productStatus" placeholder="状态" clearable>
|
|
<el-option v-for="dict in dict.type.product_status" :key="dict.value" :label="dict.label"
|
|
:value="dict.value"></el-option>
|
|
</el-select>
|
|
</el-form-item>
|
|
<el-form-item>
|
|
<el-date-picker v-model="queryParams.dateRange" style="width: 240px" value-format="yyyy-MM-dd"
|
|
type="daterange" range-separator="-" start-placeholder="开始日期"
|
|
end-placeholder="结束日期"></el-date-picker>
|
|
</el-form-item>
|
|
<el-form-item>
|
|
<el-button type="primary" icon="el-icon-search" size="mini">查询</el-button>
|
|
<el-button icon="el-icon-refresh" size="mini">重置</el-button>
|
|
</el-form-item>
|
|
</el-form>
|
|
</el-row>
|
|
<el-row type="flex" justify="space-between">
|
|
<el-col :span="12">
|
|
<el-button type="primary" @click="$emit('show-add')">新增商品</el-button>
|
|
<el-button>批量上架</el-button>
|
|
<el-button>批量下架</el-button>
|
|
<el-button>批量删除</el-button>
|
|
</el-col>
|
|
<el-col :span="6">
|
|
<el-button type="text">下载模板</el-button>
|
|
<el-button>导入</el-button>
|
|
<el-button>导出</el-button>
|
|
</el-col>
|
|
</el-row>
|
|
<el-row class="table">
|
|
<el-table>
|
|
<el-table-column type="selection" width="50" align="center" />
|
|
<el-table-column label="序号" align="center">
|
|
|
|
</el-table-column>
|
|
<el-table-column label="商品编码" align="center">
|
|
|
|
</el-table-column>
|
|
<el-table-column label="商品名称" align="center">
|
|
|
|
</el-table-column>
|
|
<el-table-column label="商品图片" align="center">
|
|
|
|
</el-table-column>
|
|
<el-table-column label="商品分类" align="center">
|
|
|
|
</el-table-column>
|
|
<el-table-column label="单位" align="center">
|
|
|
|
</el-table-column>
|
|
<el-table-column label="销售价" align="center">
|
|
|
|
</el-table-column>
|
|
<el-table-column label="吊牌价" align="center">
|
|
|
|
</el-table-column>
|
|
<el-table-column label="销量" align="center">
|
|
|
|
</el-table-column>
|
|
<el-table-column label="库存" align="center">
|
|
|
|
</el-table-column>
|
|
<el-table-column label="状态" align="center">
|
|
|
|
</el-table-column>
|
|
<el-table-column label="创建时间" align="center">
|
|
|
|
</el-table-column>
|
|
<el-table-column label="操作" align="center">
|
|
|
|
</el-table-column>
|
|
</el-table>
|
|
</el-row>
|
|
</div>
|
|
</template>
|
|
<script>
|
|
import { mapState } from 'vuex'
|
|
export default {
|
|
name: "BaseForm",
|
|
dicts: ['product_status'],
|
|
data() {
|
|
return {
|
|
// 查询参数
|
|
queryParams: {
|
|
pageNum: 1,
|
|
pageSize: 10,
|
|
productName: undefined,
|
|
productCode: undefined,
|
|
productCategory: undefined,
|
|
productStatus: undefined,
|
|
dateRange: undefined
|
|
},
|
|
}
|
|
},
|
|
computed: {
|
|
...mapState({
|
|
categoryOptions: state => state.platformShop.categoryOptions
|
|
})
|
|
}
|
|
}
|
|
</script>
|
|
<style scoped lang="scss">
|
|
.table {
|
|
margin-top: 20px;
|
|
}
|
|
</style> |