Merge remote-tracking branch 'origin/main'

# Conflicts:
#	src/views/book/component/home.vue
#	src/views/maku/t_book/index.vue
#	src/views/maku/t_purchase/index.vue
#	src/views/maku/t_shopping_trolley/index.vue
This commit is contained in:
周添峰 2024-07-18 16:40:31 +08:00
commit 4ba7f85676
5 changed files with 85 additions and 36 deletions

View File

@ -1,5 +1,24 @@
<script setup lang="ts"> <script setup lang="ts">
import { router } from '@/router/index.js' import {useT_bookApi} from 'src\\api\\maku\\t_book.ts'
import {ref} from 'vue'
const book =ref({
id:0,
bookname:'',
author:'',
price:'',
bookcover:'',
store:0,
introduction:'',
description:''
})
// function getbook(){
// useT_bookApi(1).then(res=>{
// book.value=res.data
// })
// }
// getbook()
</script> </script>
<template> <template>
@ -10,7 +29,7 @@ import { router } from '@/router/index.js'
</div> </div>
</div> </div>
<div class="screen-outer"> <div class="screen-outer">
<div class="tb-pick-content-item" @click="router.push('/book/details')"> <div class="tb-pick-content-item">
<div class="img-wrapper"></div> <div class="img-wrapper"></div>
<div class="info-wrapper">进口安佳淡奶油1L动物奶油新西兰家用生日蛋糕裱花蛋挞液专用烘焙</div> <div class="info-wrapper">进口安佳淡奶油1L动物奶油新西兰家用生日蛋糕裱花蛋挞液专用烘焙</div>
<div class="price-wrapper"> <div class="price-wrapper">
@ -18,11 +37,21 @@ import { router } from '@/router/index.js'
<span class="price-value">30</span> <span class="price-value">30</span>
</div> </div>
</div> </div>
<div class="tb-pick-content-item"></div> <div class="tb-pick-content-item">
<div class="tb-pick-content-item"></div> <div class="img-wrapper"></div>
<div class="tb-pick-content-item"></div> </div>
<div class="tb-pick-content-item"></div> <div class="tb-pick-content-item">
<div class="tb-pick-content-item"></div> <div class="img-wrapper"></div>
</div>
<div class="tb-pick-content-item">
<div class="img-wrapper"></div>
</div>
<div class="tb-pick-content-item">
<div class="img-wrapper"></div>
</div>
<div class="tb-pick-content-item">
<div class="img-wrapper"></div>
</div>
</div> </div>
</template> </template>

View File

@ -32,7 +32,7 @@
<el-table-column prop="price" label="价格" header-align="center" align="center"></el-table-column> <el-table-column prop="price" label="价格" header-align="center" align="center"></el-table-column>
<el-table-column prop="bookCover" label="封面" header-align="center" align="center"> <el-table-column prop="bookCover" label="封面" header-align="center" align="center">
<template #default="scope"> <template #default="scope">
<el-image style="width: 150px; height: 150px" :src="scope.row.bookCover" /> <img :src="scope.row.bookCover" style="max-width: 100%; max-height: 100px;" />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="introduction" label="书籍介绍" header-align="center" align="center"></el-table-column> <el-table-column prop="introduction" label="书籍介绍" header-align="center" align="center"></el-table-column>
@ -59,7 +59,7 @@
</el-pagination> </el-pagination>
<!-- 弹窗, 新增 / 修改 --> <!-- 弹窗, 新增 / 修改 -->
<add-or-update ref="addOrUpdateRef" @refresh-data-list="getDataList"></add-or-update> <add-or-update ref="addOrUpdateRef" @refreshDataList="getDataList"></add-or-update>
</el-card> </el-card>
</template> </template>
@ -74,7 +74,7 @@ const state: IHooksOptions = reactive({
deleteUrl: '/maku/t_book', deleteUrl: '/maku/t_book',
queryForm: { queryForm: {
bookName: '', bookName: '',
author: '' author: '',
} }
}) })

View File

@ -1,6 +1,14 @@
<template> <template>
<el-card class="layout-query"> <el-card class="layout-query">
<el-form ref="queryRef" :inline="true" :model="state.queryForm" @keyup.enter="getDataList()"> <el-form ref="queryRef" :inline="true" :model="state.queryForm" @keyup.enter="getDataList()">
<el-form-item prop="id">
<el-input v-model="state.queryForm.id" placeholder="序号"></el-input>
</el-form-item>
<el-form-item prop="">
<el-input v-model="state.queryForm.totalPrice" placeholder="订单总价"></el-input>
</el-form-item>
<el-form-item> <el-form-item>
<el-button icon="Search" type="primary" @click="getDataList()">查询</el-button> <el-button icon="Search" type="primary" @click="getDataList()">查询</el-button>
</el-form-item> </el-form-item>
@ -45,7 +53,7 @@
</el-pagination> </el-pagination>
<!-- 弹窗, 新增 / 修改 --> <!-- 弹窗, 新增 / 修改 -->
<add-or-update ref="addOrUpdateRef" @refresh-data-list="getDataList"></add-or-update> <add-or-update ref="addOrUpdateRef" @refreshDataList="getDataList"></add-or-update>
</el-card> </el-card>
</template> </template>
@ -58,7 +66,10 @@ import AddOrUpdate from './add-or-update.vue'
const state: IHooksOptions = reactive({ const state: IHooksOptions = reactive({
dataListUrl: '/maku/t_purchase/page', dataListUrl: '/maku/t_purchase/page',
deleteUrl: '/maku/t_purchase', deleteUrl: '/maku/t_purchase',
queryForm: {} queryForm: {
id: '',
totalPrice: ''
}
}) })
const queryRef = ref() const queryRef = ref()

View File

@ -1,6 +1,13 @@
<template> <template>
<el-card class="layout-query"> <el-card class="layout-query">
<el-form ref="queryRef" :inline="true" :model="state.queryForm" @keyup.enter="getDataList()"> <el-form ref="queryRef" :inline="true" :model="state.queryForm" @keyup.enter="getDataList()">
<el-form-item prop="userId">
<el-input v-model="state.queryForm.userId" placeholder="用户序号"></el-input>
</el-form-item>
<el-form-item prop="bookId">
<el-input v-model="state.queryForm.bookId" placeholder="书本序号"></el-input>
</el-form-item>
<el-form-item> <el-form-item>
<el-button icon="Search" type="primary" @click="getDataList()">查询</el-button> <el-button icon="Search" type="primary" @click="getDataList()">查询</el-button>
</el-form-item> </el-form-item>
@ -44,7 +51,7 @@
</el-pagination> </el-pagination>
<!-- 弹窗, 新增 / 修改 --> <!-- 弹窗, 新增 / 修改 -->
<add-or-update ref="addOrUpdateRef" @refresh-data-list="getDataList"></add-or-update> <add-or-update ref="addOrUpdateRef" @refreshDataList="getDataList"></add-or-update>
</el-card> </el-card>
</template> </template>
@ -57,7 +64,10 @@ import AddOrUpdate from './add-or-update.vue'
const state: IHooksOptions = reactive({ const state: IHooksOptions = reactive({
dataListUrl: '/maku/t_shopping_trolley/page', dataListUrl: '/maku/t_shopping_trolley/page',
deleteUrl: '/maku/t_shopping_trolley', deleteUrl: '/maku/t_shopping_trolley',
queryForm: {} queryForm: {
bookId: '',
userId: ''
}
}) })
const queryRef = ref() const queryRef = ref()

View File

@ -14,7 +14,6 @@
</el-form-item> </el-form-item>
</el-form> </el-form>
</template> </template>
<script setup lang="ts"> <script setup lang="ts">
import { reactive, ref } from 'vue' import { reactive, ref } from 'vue'
import { useI18n } from 'vue-i18n' import { useI18n } from 'vue-i18n'