commit
9ac0ebfff3
|
@ -21,7 +21,12 @@ export const cartListApi = (data) => {
|
|||
noAuth: true
|
||||
});
|
||||
}
|
||||
|
||||
//购物车-批发列表
|
||||
export const cartWholesaleListApi = (data) => {
|
||||
return request.get('/order/cart/wholesale_lists', data, {
|
||||
noAuth: true
|
||||
});
|
||||
}
|
||||
//购物车-常买记录
|
||||
export const frequentlyPurchaseApi = (data) => {
|
||||
return request.get('/order/order/frequently_purchase', data);
|
||||
|
|
13
api/good.js
13
api/good.js
|
@ -10,4 +10,15 @@ export const goodClassListApi = (data) => {
|
|||
|
||||
export const storeProductListApi = (data) => {
|
||||
return request.get('/product/product/store_lists', data);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 批发商品列表
|
||||
*/
|
||||
export const storeProductWholesaleListApi = (data) => {
|
||||
return request.get('/product/product/wholesale_lists', data);
|
||||
}
|
||||
|
||||
export const BranchProductListsApi = (data) => {
|
||||
return request.get('/branch_product/BranchProduct/lists', data);
|
||||
}
|
||||
|
|
|
@ -9,6 +9,10 @@ export const createOrderApi = (data) => {
|
|||
export const orderListApi = (data) => {
|
||||
return request.get('/order/order/order_list', data);
|
||||
}
|
||||
//门店订单列表
|
||||
export const storeOrderListApi = (data) => {
|
||||
return request.get('/order/order/store_order_list', data);
|
||||
}
|
||||
|
||||
//订单详情
|
||||
export const orderDetailApi = (data) => {
|
||||
|
|
|
@ -0,0 +1,15 @@
|
|||
import request from '@/utils/request';
|
||||
|
||||
export const purchaseProductOfferLists = (data) => {
|
||||
return request.get('/purchase_product_offer/purchaseproductoffer/lists', data);
|
||||
}
|
||||
//报价单提交
|
||||
export const purchaseProductOfferUpdate = (data) => {
|
||||
return request.post('/purchase_product_offer/purchaseproductoffer/offer_update', data);
|
||||
}
|
||||
export const purchaseProductOfferOutboundFloatingLv = (data) => {
|
||||
return request.get('/purchase_product_offer/purchaseproductoffer/outbound_floating_lv', data);
|
||||
}
|
||||
export const supplierListApi = (data) => {
|
||||
return request.get('/purchase_product_offer/purchaseproductoffer/supplier', data);
|
||||
}
|
|
@ -0,0 +1,9 @@
|
|||
import request from '@/utils/request';
|
||||
|
||||
export const menuList = (data) => {
|
||||
return request.get('/store/store/menu_list', data);
|
||||
}
|
||||
|
||||
export const store_statistics = (data) => {
|
||||
return request.get('/store/store/store_statistics', data);
|
||||
}
|
|
@ -0,0 +1,9 @@
|
|||
import request from '@/utils/request';
|
||||
|
||||
export const StoreOrderCartInfoLists = (data) => {
|
||||
return request.get('/store_order_cart_info/StoreOrderCartInfo/lists', data);
|
||||
}
|
||||
|
||||
export const StoreOrderCartInfoGroupLists = (data) => {
|
||||
return request.get('/store_order_cart_info/StoreOrderCartInfo/group_lists', data);
|
||||
}
|
|
@ -0,0 +1,13 @@
|
|||
import request from '@/utils/request';
|
||||
|
||||
export const SystemStoreStorageLists = (data) => {
|
||||
return request.get('/system_store_storage/SystemStoreStorage/lists', data);
|
||||
}
|
||||
|
||||
export const SystemStoreStorageGroupLists = (data) => {
|
||||
return request.get('/system_store_storage/SystemStoreStorage/group_lists', data);
|
||||
}
|
||||
// 确认入库
|
||||
export const SystemStoreStorageWarehousingAdd = (data) => {
|
||||
return request.post('/system_store_storage/SystemStoreStorage/warehousing_add', data);
|
||||
}
|
|
@ -184,4 +184,10 @@ export const CashApplicationApi = (data) => {
|
|||
*/
|
||||
export const getCashRecordApi = (data) => {
|
||||
return request.get('/user/User/cash_record', data);
|
||||
}
|
||||
/**
|
||||
* 提交身份证
|
||||
*/
|
||||
export const UpdateIdCardApi = (data) => {
|
||||
return request.post('/user/User/update_id_card', data);
|
||||
}
|
|
@ -14,7 +14,8 @@
|
|||
</view>
|
||||
<view class="row">
|
||||
<view>商品单位</view>
|
||||
<view>{{ datas.unit_name }}</view>
|
||||
<view >{{ datas.unit_name }}
|
||||
</view>
|
||||
</view>
|
||||
<view class="row">
|
||||
<view>商品价格</view>
|
||||
|
@ -37,7 +38,19 @@
|
|||
<view v-if="datas.is_bulk" class="row" style="height: 100rpx;">
|
||||
<view>购买重量<text style="color: #F55726;">*</text></view>
|
||||
<view style="justify-content: end;">
|
||||
<up-number-box :min="0" v-model="datas.cart_num" @change="valChange"></up-number-box>
|
||||
<up-input
|
||||
type="digit"
|
||||
placeholder="请输入重量"
|
||||
border="surround"
|
||||
v-model="datas.cart_num"
|
||||
@change="valChange"
|
||||
style="width: 100rpx;"
|
||||
>
|
||||
<template #suffix>
|
||||
<span>{{ datas.unit_name }}</span>
|
||||
</template>
|
||||
</up-input>
|
||||
<!-- <up-number-box :min="0.1" :step="0.1" v-model="datas.cart_num" @change="valChange"></up-number-box> -->
|
||||
</view>
|
||||
</view>
|
||||
<view v-else class="row" style="height: 100rpx;">
|
||||
|
@ -78,7 +91,7 @@
|
|||
|
||||
})
|
||||
|
||||
const valChange = () => {
|
||||
const valChange = (e) => {
|
||||
uni.vibrateShort();
|
||||
}
|
||||
|
||||
|
@ -87,8 +100,11 @@
|
|||
});
|
||||
const setData = (e) => {
|
||||
datas.value = e;
|
||||
if (Number(e.batch) > 0) datas.value.cart_num = e.batch;
|
||||
else datas.value.cart_num = 1;
|
||||
if (Number(e.batch) > 0) {
|
||||
datas.value.cart_num = e.batch;
|
||||
} else {
|
||||
datas.value.cart_num = 1;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
@ -114,6 +130,11 @@
|
|||
let sell = +datas.value[props.priceKey.off_activity == 1 ? props.priceKey.price : props
|
||||
.priceKey
|
||||
.op_price];
|
||||
if (!sell) {
|
||||
sell = datas.value.price
|
||||
num = datas.value.cart_num
|
||||
}
|
||||
|
||||
return Number(num * sell * 100 / 100).toFixed(2)
|
||||
})
|
||||
|
||||
|
|
|
@ -3,9 +3,9 @@ let WSS_URL
|
|||
import store from "@/store/user.js"
|
||||
// 环境
|
||||
// let env = "dev"
|
||||
// let env = "prod"
|
||||
let env = "prod"
|
||||
// let env = "release";
|
||||
let env = "local";
|
||||
// let env = "local";
|
||||
|
||||
switch (env) {
|
||||
case 'dev':
|
||||
|
@ -17,7 +17,7 @@ switch (env) {
|
|||
WSS_URL = 'wss://ceshi-multi-store.lihaink.cn/pull'
|
||||
break;
|
||||
case 'local':
|
||||
BASE_URL = 'http://192.168.1.231:8545';
|
||||
BASE_URL = 'http://192.168.1.7:8545';
|
||||
WSS_URL = 'wss://ceshi-multi-store.lihaink.cn/pull'
|
||||
break;
|
||||
default:
|
||||
|
@ -33,6 +33,7 @@ let config = {
|
|||
WSS_URL: WSS_URL,
|
||||
HEADER: {
|
||||
'content-type': 'application/json',
|
||||
'accept':'json',
|
||||
//#ifdef MP
|
||||
'Form-type': 'routine',
|
||||
//#endif
|
||||
|
|
|
@ -0,0 +1,372 @@
|
|||
<template>
|
||||
<view>
|
||||
<up-subsection :list="menu_list" :current="0" @change="sectionChange"></up-subsection>
|
||||
<view class="content">
|
||||
<up-transition :show="true" mode="slide-left">
|
||||
<view v-if="goodsList1.length>0">
|
||||
<view class="card" v-for="(item,index) in goodsList1" :key='index'>
|
||||
<view class="head">
|
||||
<!-- <text> {{orer_sn}}</text> -->
|
||||
<!-- <text style="color: #989898;">{{time}}</text> -->
|
||||
</view>
|
||||
<view class="card-content">
|
||||
<view class="card-content-l" style="width: 152rpx;height: 152rpx;">
|
||||
<image style="width: 152rpx;height: 152rpx;" :src="item.image" mode=""></image>
|
||||
</view>
|
||||
<view class="card-content-r">
|
||||
<view class="title ellipsis">
|
||||
编号:{{item.order_id}}|{{item.store_name}}
|
||||
</view>
|
||||
<view>
|
||||
单位:{{item.unit_name}}
|
||||
</view>
|
||||
<view>
|
||||
规格:{{item.store_info}}
|
||||
</view>
|
||||
<view>
|
||||
备注:{{item.mark}}
|
||||
</view>
|
||||
<view style="color: red;">
|
||||
需求量: {{item.need_num}}
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
<view class="card-footer">
|
||||
<up-button size="small" type="primary" shape="circle" @click="cancleOrder(item)"
|
||||
v-if="item.buyer_confirm==0">确认已采购</up-button>
|
||||
<up-button size="small" type="success" shape="circle" v-else @click="cancleOrder(item)"
|
||||
>修改采购信息</up-button>
|
||||
</view>
|
||||
<up-line style="margin-top: 30rpx;" color="#F3F3F3"></up-line>
|
||||
</view>
|
||||
</view>
|
||||
<up-empty @click='test2' v-else mode="data" icon="http://cdn.uviewui.com/uview/empty/data.png">
|
||||
</up-empty>
|
||||
</up-transition>
|
||||
<up-modal :show="show" title="采购确认" showCancelButton @cancel="show=false" @confirm="offerUpdate()">
|
||||
<up-form labelPosition="left">
|
||||
<up-form-item label="供应商" labelWidth='auto'>
|
||||
<up-input @click="showSupplier = true">
|
||||
<template #suffix>
|
||||
<span>{{supplierText}}</span>
|
||||
</template>
|
||||
</up-input>
|
||||
</up-form-item>
|
||||
<up-form-item label="名称">
|
||||
<up-input v-model="formData.store_name" border="none" disabled=""></up-input>
|
||||
</up-form-item>
|
||||
<up-form-item label="数量">
|
||||
<up-input v-model="formData.buyer_nums" @change='changeInputPrice'> <template #suffix>
|
||||
<span>{{formData.unit_name}}</span>
|
||||
</template></up-input>
|
||||
</up-form-item>
|
||||
<up-form-item label="单价">
|
||||
<up-input v-model="formData.purchase" @change='changeInputPrice'></up-input>
|
||||
</up-form-item>
|
||||
<up-form-item label="总价">
|
||||
<up-input v-model="formData.total_price"></up-input>
|
||||
</up-form-item>
|
||||
<up-form-item label="付款方式" labelWidth='auto'>
|
||||
<up-radio-group v-model="radio_value">
|
||||
<up-radio v-for="(item, index) in radiolist1" :key="index" :label="item.name"
|
||||
:name="item.name" @change="radioChange"></up-radio>
|
||||
</up-radio-group>
|
||||
</up-form-item>
|
||||
<up-form-item label="包装">
|
||||
<up-input v-model="formData.package"></up-input>
|
||||
</up-form-item>
|
||||
<up-form-item label="规格">
|
||||
<up-input v-model="formData.store_info"></up-input>
|
||||
</up-form-item>
|
||||
<up-form-item label="型号">
|
||||
<up-input v-model="formData.marques"></up-input>
|
||||
</up-form-item>
|
||||
<up-form-item label="售后">
|
||||
<up-input v-model="formData.after_sales"></up-input>
|
||||
</up-form-item>
|
||||
</up-form>
|
||||
</up-modal>
|
||||
<up-picker :show="showSupplier" :columns="supplierList" keyName="mer_name" @confirm="supplierConfirm"
|
||||
@cancel="showSupplier = false"></up-picker>
|
||||
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
|
||||
<script setup>
|
||||
import {
|
||||
ref,
|
||||
reactive,
|
||||
} from "vue"
|
||||
import {
|
||||
supplierListApi,
|
||||
purchaseProductOfferLists,
|
||||
purchaseProductOfferUpdate,
|
||||
purchaseProductOfferOutboundFloatingLv
|
||||
} from "@/api/purchase_product_offer.js"
|
||||
const menu_list = ref(['未采购', '已采购']);
|
||||
|
||||
const test2 = () => {
|
||||
console.log("点解")
|
||||
uni.navigateTo({
|
||||
url: '/pages/index/index'
|
||||
})
|
||||
}
|
||||
const show = ref(false)
|
||||
const showSupplier = ref(false)
|
||||
const supplierText = ref('')
|
||||
const pickerText = ref('')
|
||||
const picker_price = ref(0)
|
||||
const pickerShow = ref(false)
|
||||
const formData = ref({
|
||||
id: '',
|
||||
bhoid: '',
|
||||
supplier_id: '',
|
||||
purchase: '',
|
||||
total_price: '',
|
||||
buyer_nums: 0,
|
||||
package: '',
|
||||
store_info: '',
|
||||
marques: '',
|
||||
after_sales: '',
|
||||
pay_type: 1
|
||||
})
|
||||
// tabsindex
|
||||
const radiolist1=ref([{name:'赊账', value: 1},{name:'现金', value: 2}])
|
||||
const radio_value=ref('赊账')
|
||||
const tabIndex = ref(1)
|
||||
const {
|
||||
windowWidth
|
||||
} = uni.getSystemInfoSync();
|
||||
const tabsLeft = ref(((windowWidth / 2) - 26) / 2)
|
||||
const tabsRight = ref(tabsLeft.value + (windowWidth / 2))
|
||||
// tabsindex结束
|
||||
|
||||
const priceBlur = (index, goodsList) => {
|
||||
goodsList[index].price = Number(goodsList[index].price).toFixed(2)
|
||||
}
|
||||
|
||||
// 列表
|
||||
const showGoods = ref(false)
|
||||
const showGoods1 = ref(false)
|
||||
const goodsList = ref([])
|
||||
const goodsList1 = ref([])
|
||||
const where = ref({
|
||||
buyer_confirm: 0
|
||||
})
|
||||
const getGoodsList = async () => {
|
||||
let res = await purchaseProductOfferLists(where.value)
|
||||
goodsList1.value = res.data.lists
|
||||
}
|
||||
const supplierList = ref([])
|
||||
const getSupplierList = () => {
|
||||
supplierListApi().then(res => {
|
||||
supplierList.value = [res.data.lists]
|
||||
})
|
||||
}
|
||||
const supplierConfirm = (e) => {
|
||||
showSupplier.value = false
|
||||
supplierText.value = e.value[0].mer_name
|
||||
formData.value.supplier_id = e.value[0].id
|
||||
}
|
||||
const cancleOrder = (item) => {
|
||||
columns.value[0].forEach(e => {
|
||||
if (e['name_b'] == item['category_name']) {
|
||||
pickerText.value = e['name']
|
||||
picker_price.value = e['value']
|
||||
}
|
||||
})
|
||||
show.value = true
|
||||
formData.value.store_name = item['store_name']
|
||||
formData.value.id = item['id']
|
||||
formData.value.bhoid = item.order_id
|
||||
formData.value.buyer_nums = item['need_num']
|
||||
formData.value.product_id = item['product_id']
|
||||
formData.value.unit_name = item['unit_name']
|
||||
formData.value.package = item.package
|
||||
formData.value.store_info = item.store_info
|
||||
formData.value.marques = item.marques
|
||||
formData.value.after_sales = item.after_sales
|
||||
if (item.buyer_confirm == 1) {
|
||||
formData.value.purchase = item.price
|
||||
formData.value.buyer_nums = item.buyer_nums
|
||||
formData.value.total_price = item.total_price
|
||||
formData.value.supplier_id = item.supplier_id
|
||||
formData.value.pay_type = item.pay_type
|
||||
supplierText.value = item.supplier_name
|
||||
if (item.pay_type == 1) {
|
||||
radio_value.value = '赊账'
|
||||
} else {
|
||||
radio_value.value = '现金'
|
||||
}
|
||||
} else {
|
||||
formData.value.purchase = ''
|
||||
formData.value.total_price =
|
||||
formData.value.supplier_id = ''
|
||||
formData.value.pay_type = 1
|
||||
supplierText.value = ''
|
||||
radio_value.value = '赊账'
|
||||
}
|
||||
}
|
||||
const offerUpdate = () => {
|
||||
purchaseProductOfferUpdate(formData.value).then(res => {
|
||||
uni.$u.toast(res.msg);
|
||||
show.value = false
|
||||
getGoodsList()
|
||||
})
|
||||
}
|
||||
const changeInputPrice = (e) => {
|
||||
if (formData.value.buyer_nums > 0 && formData.value.purchase > 0) {
|
||||
formData.value.total_price = (formData.value.buyer_nums * formData.value.purchase).toFixed(2)
|
||||
}
|
||||
}
|
||||
const sectionChange = (index) => {
|
||||
where.value.buyer_confirm = index
|
||||
goodsList1.value = []
|
||||
getGoodsList()
|
||||
}
|
||||
const columns = ref([]);
|
||||
const pickerConfirm = (e) => {
|
||||
pickerShow.value = false
|
||||
let outbound_price = (formData.value.price * e.value[0].value)
|
||||
pickerText.value = e.value[0].name
|
||||
formData.value.outbound_price = (parseInt(formData.value.price) + outbound_price).toFixed(2)
|
||||
}
|
||||
const OutboundFloatingLv = () => {
|
||||
purchaseProductOfferOutboundFloatingLv().then(res => {
|
||||
columns.value = res.data
|
||||
})
|
||||
}
|
||||
const radioChange=(e)=>{
|
||||
if(e=='赊账'){
|
||||
formData.value.pay_type = 1
|
||||
}else{
|
||||
formData.value.pay_type = 2
|
||||
}
|
||||
}
|
||||
getGoodsList()
|
||||
OutboundFloatingLv()
|
||||
getSupplierList()
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
.head {
|
||||
padding: 20rpx;
|
||||
background-color: white;
|
||||
position: relative;
|
||||
|
||||
.act {
|
||||
color: #20B128;
|
||||
}
|
||||
|
||||
.line {
|
||||
width: 26px;
|
||||
height: 5rpx;
|
||||
background-color: #20B128;
|
||||
border-radius: 50rpx;
|
||||
position: absolute;
|
||||
transition: 300ms;
|
||||
}
|
||||
}
|
||||
|
||||
.content {
|
||||
padding: 20rpx;
|
||||
padding-bottom: 150rpx;
|
||||
|
||||
.card {
|
||||
width: 710rpx;
|
||||
margin: 0 auto;
|
||||
padding: 20rpx;
|
||||
box-sizing: border-box;
|
||||
background-color: white;
|
||||
|
||||
|
||||
|
||||
.card-content {
|
||||
display: flex;
|
||||
position: relative;
|
||||
|
||||
.card-content-l {
|
||||
margin-right: 20rpx;
|
||||
position: relative;
|
||||
|
||||
.status {
|
||||
width: 152rpx;
|
||||
height: 40rpx;
|
||||
background-color: rgba(0, 0, 0, .3);
|
||||
text-align: center;
|
||||
color: white;
|
||||
font-size: 24rpx;
|
||||
line-height: 40rpx;
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.card-content-r {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
|
||||
.title {
|
||||
font-size: 30rpx;
|
||||
width: 500rpx;
|
||||
}
|
||||
|
||||
.need {
|
||||
color: #777777;
|
||||
font-size: 24rpx;
|
||||
}
|
||||
|
||||
.ipt {
|
||||
display: flex;
|
||||
height: 56rpx;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
.status-png {
|
||||
position: absolute;
|
||||
right: 20rpx;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
.card-footer {
|
||||
margin-top: 30rpx;
|
||||
text-align: right;
|
||||
font-size: 28rpx;
|
||||
color: #060606;
|
||||
}
|
||||
}
|
||||
|
||||
.submit-btn {
|
||||
position: fixed;
|
||||
bottom: 50rpx;
|
||||
width: 710rpx;
|
||||
margin: 0 auto;
|
||||
}
|
||||
}
|
||||
|
||||
.detail {
|
||||
width: 88rpx;
|
||||
height: 88rpx;
|
||||
border-radius: 88rpx;
|
||||
text-align: center;
|
||||
line-height: 88rpx;
|
||||
background-color: #50C758;
|
||||
color: white;
|
||||
position: absolute;
|
||||
bottom: 300rpx;
|
||||
right: 20rpx;
|
||||
}
|
||||
|
||||
.ellipsis {
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
</style>
|
65
pages.json
65
pages.json
|
@ -121,6 +121,13 @@
|
|||
{
|
||||
"navigationBarTitleText" : "提现申请记录"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path" : "pages/wholesale/index",
|
||||
"style" :
|
||||
{
|
||||
"navigationBarTitleText" : "批发"
|
||||
}
|
||||
}
|
||||
],
|
||||
"subPackages": [{
|
||||
|
@ -202,7 +209,56 @@
|
|||
"path" : "delivery/index",
|
||||
"style" :
|
||||
{
|
||||
"navigationBarTitleText" : "配送员订单"
|
||||
"navigationBarTitleText" : "门店订单"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path" : "store/index",
|
||||
"style" :
|
||||
{
|
||||
"navigationBarTitleText" : "门店管理"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path" : "deliveryOrder/index",
|
||||
"style" :
|
||||
{
|
||||
"navigationBarTitleText" : "每日配送统计"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path" : "deliveryOrder/count",
|
||||
"style" :
|
||||
{
|
||||
"navigationBarTitleText" : "累计配送统计"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path" : "productSales/index",
|
||||
"style" :
|
||||
{
|
||||
"navigationBarTitleText" : "每日销量统计"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path" : "productSales/count",
|
||||
"style" :
|
||||
{
|
||||
"navigationBarTitleText" : "累计销售统计"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path" : "store_product/index",
|
||||
"style" :
|
||||
{
|
||||
"navigationBarTitleText" : "商品库存"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path" : "statistics/index",
|
||||
"style" :
|
||||
{
|
||||
"navigationBarTitleText" : "门店收支"
|
||||
}
|
||||
}
|
||||
]
|
||||
|
@ -306,6 +362,13 @@
|
|||
"navigationBarTitleText": "余额明细",
|
||||
"enablePullDownRefresh": true
|
||||
}
|
||||
},
|
||||
{
|
||||
"path" : "purchase_product_offer/index",
|
||||
"style" :
|
||||
{
|
||||
"navigationBarTitleText" : "采购商品列表"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
@ -29,7 +29,7 @@
|
|||
</view>
|
||||
<view class="afterSales-goods-right-info">
|
||||
<text class="goods_desc">{{item.unit}}</text>
|
||||
<text class="goods_num">x5</text>
|
||||
<text class="goods_num">x{{item.cart_num}}</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
@ -142,7 +142,6 @@
|
|||
// 上一个页面传递的售后参数
|
||||
const eventChannel = instance.getOpenerEventChannel();
|
||||
eventChannel.on('orderDetail', function(data) {
|
||||
console.log(data);
|
||||
refundForm.id = data.id;
|
||||
refundForm.old_cart_id = data.old_cart_id;
|
||||
refundForm.refund_type = data.refund_type;
|
||||
|
@ -215,7 +214,6 @@
|
|||
//图片 refund_reason_wap_img
|
||||
if (fileList1.value.length > 0) {
|
||||
fileList1.value.map(i => {
|
||||
console.log(i.url.uri);
|
||||
urls.push(i.url.uri);
|
||||
});
|
||||
refundForm.refund_reason_wap_img = urls.join(',');
|
||||
|
|
|
@ -244,7 +244,7 @@
|
|||
const cartList = ref([]);
|
||||
const cartInfo = ref({});
|
||||
const getcartList = (check = true) => {
|
||||
cartListApi().then(res => {
|
||||
cartListApi({store_id:STORE_INFO.id}).then(res => {
|
||||
if (check) {
|
||||
res.data.lists = res.data.lists.map(item => {
|
||||
item.check = true;
|
||||
|
|
|
@ -23,21 +23,16 @@
|
|||
<template #left>
|
||||
<view class="store-info">
|
||||
<view style="display: flex;font-size: 30rpx;font-weight: bold;">
|
||||
<!-- <text v-if=" vipList.includes(userStore.userInfo.user_ship) || shareInfo.store_id"
|
||||
style="max-width: 400rpx;overflow: hidden;text-overflow: ellipsis;white-space: nowrap;">
|
||||
<text v-if="vipList.includes(userStore.userInfo.user_ship)">
|
||||
{{ (userStore.userInfo.real_name || userStore.userInfo.nickname) + '的个人门店' }}</text>
|
||||
<text v-else>
|
||||
{{(shareInfo.real_name || (userStore.userInfo.real_name || userStore.userInfo.nickname)) + '的供销店' }}</text>
|
||||
</text> -->
|
||||
<text v-if="shareInfo.uid"
|
||||
style="max-width: 400rpx;overflow: hidden;text-overflow: ellipsis;white-space: nowrap;">
|
||||
{{shareInfo.real_name}}
|
||||
style="max-width: 400rpx;overflow: hidden;text-overflow: ellipsis;white-space: nowrap;" @click="navgo('/multipleShop/index/index?event=store_info')">
|
||||
{{shareInfo.real_name}}
|
||||
</text>
|
||||
<text v-else
|
||||
style="max-width: 400rpx;overflow: hidden;text-overflow: ellipsis;white-space: nowrap;">{{
|
||||
style="max-width: 400rpx;overflow: hidden;text-overflow: ellipsis;white-space: nowrap;"
|
||||
@click="navgo('/multipleShop/index/index?event=store_info')">{{
|
||||
STORE_INFO.store_name }}</text>
|
||||
<up-icon name="arrow-right"></up-icon>
|
||||
<up-icon name="arrow-right" label="切换" labelSize="10px"
|
||||
@click="navgo('/multipleShop/index/index?event=store_info')"></up-icon>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
@ -187,6 +182,10 @@
|
|||
<view class="shop-content-li-r" style="color:#FC452F ;">¥<text
|
||||
style="font-size: 28rpx;">{{item[priceKey.op_price]}}</text>
|
||||
</view>
|
||||
<view class="tag" v-if="item.tag">
|
||||
<view class="icon" />
|
||||
{{item.tag}}
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="shop-content-li" style="justify-content: space-between;"
|
||||
|
@ -207,7 +206,8 @@
|
|||
</view> -->
|
||||
</view>
|
||||
<view class="shopconetent-btn">
|
||||
<u--icon name="plus-circle-fill" size="20" color="#20b128"></u--icon>
|
||||
<u--icon name="plus-circle-fill" size="20" color="#20b128" v-if="item.is_lack==0"></u--icon>
|
||||
<u--icon name="plus-circle-fill" size="20" color="#c1ffc0" v-else></u--icon>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
@ -258,6 +258,20 @@
|
|||
</view>
|
||||
</view>
|
||||
</u-overlay>
|
||||
<up-popup :show="LocationShow" mode="bottom" @open="LocationShowOpen()">
|
||||
<view style="margin: 40rpx 10rpx;">
|
||||
<up-row customStyle="margin-bottom: 10px" gutter="10">
|
||||
<up-col span="6">
|
||||
<up-button text="取消" @click="userLocationfalse()"></up-button>
|
||||
</up-col>
|
||||
<up-col span="6">
|
||||
<up-button type="primary" text="设置授权" color="#20B128" @click="opensettings()"></up-button>
|
||||
</up-col>
|
||||
</up-row>
|
||||
|
||||
</view>
|
||||
|
||||
</up-popup>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
|
@ -298,11 +312,17 @@
|
|||
} from "@/api/multipleShop.js";
|
||||
|
||||
import useUserStore from "@/store/user";
|
||||
//定位坐标
|
||||
let location = {
|
||||
lat: '',
|
||||
long: "",
|
||||
};
|
||||
const vipList = reactive([1, 2, 3, 4, 5, 6, 7, 8])
|
||||
const userStore = useUserStore();
|
||||
const STORE_INFO = reactive({
|
||||
id: '',
|
||||
store_name: ""
|
||||
store_name: "",
|
||||
abbreviation: ''
|
||||
})
|
||||
const priceKey = reactive({
|
||||
off_activity: "",
|
||||
|
@ -310,23 +330,45 @@
|
|||
price: ""
|
||||
})
|
||||
|
||||
const showModal = ref(false)
|
||||
const navgo = (url) => {
|
||||
showModal.value &&= false
|
||||
uni.navigateTo({
|
||||
url
|
||||
})
|
||||
}
|
||||
const LocationShow = ref(false)
|
||||
|
||||
uni.$on('store_info', function(data) {
|
||||
let datas = JSON.parse(data)
|
||||
if (datas) {
|
||||
datas.store_name = datas.name
|
||||
uni.setStorageSync("STORE_INFO", JSON.stringify(datas));
|
||||
STORE_INFO.id = datas.id
|
||||
STORE_INFO.store_name = datas.name
|
||||
STORE_INFO.abbreviation = datas.abbreviation
|
||||
shareInfo.value.real_name = datas.name
|
||||
shareInfo.value.store_id = datas.id
|
||||
}
|
||||
getgoodClassList(0)
|
||||
getGoodList()
|
||||
})
|
||||
const getStoreInfoFn = () => {
|
||||
if (uni.getStorageSync('STORE_INFO').length) {
|
||||
let data = JSON.parse(uni.getStorageSync('STORE_INFO'))
|
||||
for (let key in data) {
|
||||
STORE_INFO[key] = data[key]
|
||||
}
|
||||
} else {
|
||||
getStoreInfo().then(res => {
|
||||
uni.setStorageSync("STORE_INFO", JSON.stringify(res.data));
|
||||
let data = res.data;
|
||||
for (let key in data) {
|
||||
STORE_INFO[key] = data[key]
|
||||
}
|
||||
})
|
||||
}
|
||||
getStoreInfo().then(res => {
|
||||
uni.setStorageSync("STORE_INFO", JSON.stringify(res.data));
|
||||
let data = res.data;
|
||||
for (let key in data) {
|
||||
STORE_INFO[key] = data[key]
|
||||
}
|
||||
getgoodClassList(0);
|
||||
getGoodList();
|
||||
|
||||
})
|
||||
getAll()
|
||||
}
|
||||
|
||||
|
||||
|
@ -334,7 +376,10 @@
|
|||
onShareAppMessage(() => {
|
||||
let shareStr = '?id=' + STORE_INFO.id;
|
||||
if (vipList.includes(userStore.userInfo.user_ship)) {
|
||||
shareStr = shareStr + '&spread_uid=' + userStore.userInfo.id + '&real_name=' + (userStore.userInfo.share_name)
|
||||
shareStr = shareStr + '&spread_uid=' + userStore.userInfo.id + '&real_name=' + (userStore.userInfo
|
||||
.share_name)
|
||||
} else {
|
||||
shareStr = shareStr + '&real_name=' + STORE_INFO.abbreviation
|
||||
}
|
||||
let shareInfo = {
|
||||
// title: (userStore.userInfo.real_name || userStore.userInfo.nickname) + '的供销个人门店',
|
||||
|
@ -608,6 +653,9 @@
|
|||
const goodRef = ref(null);
|
||||
const goodData = ref({});
|
||||
const openGoodPopup = (item) => { // 打开数量/重量弹窗
|
||||
if(item.is_lack==1){
|
||||
return false
|
||||
}
|
||||
navTo(false)
|
||||
if (!userStore.token || !userStore.userInfo.mobile) return;
|
||||
goodData.value = item;
|
||||
|
@ -655,7 +703,7 @@
|
|||
}
|
||||
|
||||
const settleAccounts = () => {
|
||||
if (+cartInfo.value.pay_price < 500 && userStore.userInfo.user_ship==0 ) return showOverlay.value = true;
|
||||
if (+cartInfo.value.pay_price < 500 && userStore.userInfo.user_ship == 0) return showOverlay.value = true;
|
||||
uni.navigateTo({
|
||||
url: '/pagesOrder/settle/settle'
|
||||
})
|
||||
|
@ -672,6 +720,7 @@
|
|||
cartListApi({
|
||||
page_no: 1,
|
||||
page_size: 100,
|
||||
store_id: STORE_INFO.id,
|
||||
}).then(res => {
|
||||
cartInfo.value = {
|
||||
total_price: res.data?.extend?.total_price || '0.00',
|
||||
|
@ -699,37 +748,38 @@
|
|||
store_id: ''
|
||||
});
|
||||
|
||||
const getShareInfo = () => {
|
||||
if (uni.getStorageSync('SHARE_INFO')) {
|
||||
shareInfo.value = (uni.getStorageSync('SHARE_INFO'))
|
||||
}
|
||||
}
|
||||
getShareInfo()
|
||||
// const getShareInfo = () => {
|
||||
// if (uni.getStorageSync('SHARE_INFO')) {
|
||||
// shareInfo.value = (uni.getStorageSync('SHARE_INFO'))
|
||||
// }
|
||||
// }
|
||||
|
||||
onLoad(async (opt) => {
|
||||
console.log('opt', opt)
|
||||
if (opt.id) {
|
||||
where.value.store_id = (opt.id == 'undefined' ? STORE_INFO.id : opt.id);
|
||||
} else {
|
||||
where.value.store_id = STORE_INFO.id
|
||||
}
|
||||
// 店铺id
|
||||
if (opt.id && opt.id != 'undefined') {
|
||||
where.value.store_id = opt.id;
|
||||
const info = await shopDetailApi({
|
||||
store_id: where.value.store_id
|
||||
});
|
||||
STORE_INFO.id = opt.id
|
||||
STORE_INFO.store_name = opt.real_name
|
||||
if (opt.real_name == '' || opt.real_name == undefined) {
|
||||
shopDetailApi({
|
||||
store_id: opt.id
|
||||
}).then(res => {
|
||||
STORE_INFO.store_name=res.data.name
|
||||
})
|
||||
}
|
||||
// 分享参数至当前用户参数
|
||||
if (opt.spread_uid) {
|
||||
if (opt.spread_uid) {
|
||||
shareInfo.value.uid = opt.spread_uid;
|
||||
shareInfo.value.real_name = opt.real_name;
|
||||
shareInfo.value.store_id = opt.id;
|
||||
uni.setStorageSync('SHARE_INFO', shareInfo.value);
|
||||
}
|
||||
getAll()
|
||||
} else {
|
||||
uni.removeStorageSync('SHARE_INFO')
|
||||
getLocation()
|
||||
}
|
||||
|
||||
getStoreInfoFn()
|
||||
|
||||
// #ifndef H5
|
||||
// 胶囊布局信息
|
||||
btns.value = uni.getMenuButtonBoundingClientRect();
|
||||
|
@ -737,9 +787,12 @@
|
|||
})
|
||||
|
||||
onShow(() => {
|
||||
if (STORE_INFO.id) {
|
||||
getCartList();
|
||||
}
|
||||
// 如果后台变更核销人员权限 可以及时切换
|
||||
if (userStore.token && userStore.userInfo.mobile) {
|
||||
userInfoApi().then(res => {
|
||||
userInfoApi({store_id:STORE_INFO.id}).then(res => {
|
||||
const user = res.data;
|
||||
userStore.setUserInfo(user);
|
||||
if (!user.openid) loginUpdateUserApi({
|
||||
|
@ -750,14 +803,116 @@
|
|||
uni.reLaunch({
|
||||
url: "/multipleShop/verificationOrder/index"
|
||||
})
|
||||
} else {
|
||||
getCartList();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
//获取定位
|
||||
const getLocation = () => {
|
||||
// #ifdef MP-WEIXIN
|
||||
uni.getSetting({
|
||||
success(res) {
|
||||
if (res.authSetting["scope.userLocation"] == false) {
|
||||
LocationShowOpen()
|
||||
} else {
|
||||
opensettings(true)
|
||||
}
|
||||
}
|
||||
})
|
||||
// #endif
|
||||
// #ifdef H5
|
||||
userLocationfalse()
|
||||
// #endif
|
||||
|
||||
}
|
||||
const LocationShowOpen = () => {
|
||||
LocationShow.value = true;
|
||||
}
|
||||
const getAll = () => {
|
||||
getgoodClassList(0)
|
||||
getGoodList()
|
||||
getCartList();
|
||||
}
|
||||
|
||||
//获取小程序定位
|
||||
const opensettings = (a = false) => {
|
||||
if (a == false) {
|
||||
uni.openSetting({
|
||||
success(res) {
|
||||
LocationShow.value = false;
|
||||
if (res.authSetting["scope.userLocation"] == true) {
|
||||
uni.authorize({
|
||||
scope: 'scope.userLocation',
|
||||
success() {
|
||||
uni.getLocation({
|
||||
type: "gcj02",
|
||||
success(res) {
|
||||
location.lat = res.latitude;
|
||||
location.long = res.longitude;
|
||||
uni.setStorageSync('location', JSON.stringify(
|
||||
location))
|
||||
getStoreInfo(location).then(res => {
|
||||
STORE_INFO.id = res.data.id
|
||||
STORE_INFO.store_name = res.data.store_name
|
||||
STORE_INFO.abbreviation = res.data
|
||||
.abbreviation
|
||||
getAll()
|
||||
uni.setStorageSync('STORE_INFO', JSON
|
||||
.stringify(STORE_INFO))
|
||||
})
|
||||
|
||||
},
|
||||
})
|
||||
},
|
||||
fail(e) {
|
||||
userLocationfalse()
|
||||
},
|
||||
})
|
||||
}
|
||||
},
|
||||
fail(e) {
|
||||
userLocationfalse()
|
||||
}
|
||||
});
|
||||
} else {
|
||||
uni.authorize({
|
||||
scope: 'scope.userLocation',
|
||||
success() {
|
||||
uni.getLocation({
|
||||
type: "gcj02",
|
||||
success(res) {
|
||||
location.lat = res.latitude;
|
||||
location.long = res.longitude;
|
||||
uni.setStorageSync('location', JSON.stringify(location))
|
||||
getStoreInfo(location).then(res => {
|
||||
STORE_INFO.id = res.data.id
|
||||
STORE_INFO.store_name = res.data.store_name
|
||||
STORE_INFO.abbreviation = res.data.abbreviation
|
||||
|
||||
getAll()
|
||||
uni.setStorageSync('STORE_INFO', JSON.stringify(STORE_INFO))
|
||||
|
||||
})
|
||||
|
||||
},
|
||||
})
|
||||
},
|
||||
fail(e) {
|
||||
userLocationfalse()
|
||||
},
|
||||
})
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
//取消定位获取默认门店
|
||||
const userLocationfalse = () => {
|
||||
LocationShow.value = false;
|
||||
uni.$u.toast('获取位置失败,为你展示默认门店')
|
||||
getStoreInfoFn()
|
||||
}
|
||||
let instance; // 获取组件实例
|
||||
const getWXDom = () => {
|
||||
let query = uni.createSelectorQuery().in(instance).select("#drag_area");
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
<view class="login-box">
|
||||
<image class="logo" src="https://lihai001.oss-cn-chengdu.aliyuncs.com/def/35adb202404271727457954.png" @click="test()">
|
||||
</image>
|
||||
<view class="tips">欢迎登录泸优采</view>
|
||||
<view class="tips">欢迎登录蜀优采</view>
|
||||
<block v-if="showWeixin">
|
||||
<up-transition :show="showWeixin">
|
||||
<view class="btn">
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<view style="text-align: center;">
|
||||
<image class="logo" src="https://lihai001.oss-cn-chengdu.aliyuncs.com/def/35adb202404271727457954.png">
|
||||
</image>
|
||||
<view class="tips">欢迎登录泸优采</view>
|
||||
<view class="tips">欢迎登录蜀优采</view>
|
||||
</view>
|
||||
|
||||
<view class='card'>
|
||||
|
|
|
@ -123,8 +123,9 @@
|
|||
<up-cell title="我的地址" :isLink="true" url="/pagesOrder/addressList/addressList"></up-cell>
|
||||
<up-cell title="支付密码" :isLink="true" url="/pagesOrder/setPayPassword/index"></up-cell>
|
||||
<up-cell title="商品列表" :isLink="true" url="pages/product/product" v-if="userInfo.system_store_id>0"></up-cell>
|
||||
<up-cell title="配送员订单" :isLink="true" url="pagesOrder/delivery/index" v-if="userInfo.system_store_id>0"></up-cell>
|
||||
|
||||
<up-cell title="门店管理" :isLink="true" url="pagesOrder/store/index" v-if="userInfo.system_store_id>0"></up-cell>
|
||||
<up-cell title="采购列表" :isLink="true" url="pageQuota/purchase_product_offer/index" v-if="userInfo.delivery_service_id>0"></up-cell>
|
||||
<up-cell title="我要批发" :isLink="true" url="pages/wholesale/index" v-if="userInfo.label_id==99"></up-cell>
|
||||
</up-cell-group>
|
||||
</view>
|
||||
|
||||
|
|
|
@ -55,7 +55,7 @@
|
|||
const frequentlyList = ref([]);
|
||||
let text = '没有商品'
|
||||
let status = ref('loadmore')
|
||||
let list1 = ['零售', '商户', '会员']
|
||||
let list1 = ['零售', '商户', '供货价']
|
||||
let keyword = ref('');
|
||||
let enable_flex=ref(true)
|
||||
const where = ref({
|
||||
|
|
|
@ -43,6 +43,9 @@
|
|||
</navigator>
|
||||
|
||||
</view>
|
||||
<view class='tip'>
|
||||
本月已提现金额:<text class="num">¥{{userInfo.extract_price}}</text>
|
||||
</view>
|
||||
<view class='tip'>
|
||||
说明: <text class="num">{{userInfo.notes}}</text>
|
||||
</view>
|
||||
|
@ -56,6 +59,20 @@
|
|||
<!-- #ifdef MP -->
|
||||
<authorize v-if="isShowAuth" @authColse="authColse" @onLoadFun="onLoadFun"></authorize>
|
||||
<!-- #endif -->
|
||||
|
||||
<up-modal :show="IDCardShow" title="提现信息补充" showCancelButton @cancel="IDCardShow=false" @confirm="UpdateCard()">
|
||||
<up-form labelPosition="left">
|
||||
<up-form-item label="姓名:" label-width="80px">
|
||||
<up-input v-model="real_name" border="none" placeholder="请输入对应的真实姓名"></up-input>
|
||||
</up-form-item>
|
||||
<up-form-item label="电话:" label-width="80px">
|
||||
<up-input v-model="mobile" border="none" disabled></up-input>
|
||||
</up-form-item>
|
||||
<up-form-item label="身份证号:" label-width="80px">
|
||||
<up-input v-model="id_card" border="none" placeholder="请输入身份证号"></up-input>
|
||||
</up-form-item>
|
||||
</up-form>
|
||||
</up-modal>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
|
@ -63,7 +80,8 @@
|
|||
import {
|
||||
getCashInfoApi,
|
||||
CashApplicationApi,
|
||||
getCashRecordApi
|
||||
getCashRecordApi,
|
||||
UpdateIdCardApi
|
||||
} from "@/api/user.js"
|
||||
// import {
|
||||
// extractCash,
|
||||
|
@ -79,13 +97,17 @@
|
|||
getHeight: this.getWXStatusHeight(),
|
||||
// #endif
|
||||
index: 0,
|
||||
minPrice: 0.00, //最低提现金额
|
||||
minPrice: 1.00, //最低提现金额
|
||||
userInfo: [],
|
||||
prevent: true, //避免重复提交成功多次
|
||||
moneyMaxLeng: 8,
|
||||
withdraw_fee: '0',
|
||||
true_money: 0,
|
||||
cashVal: '',
|
||||
IDCardShow: false,
|
||||
id_card:'',
|
||||
real_name:'',
|
||||
mobile:''
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
|
@ -98,6 +120,8 @@
|
|||
onShow() {
|
||||
getCashInfoApi().then(res => {
|
||||
this.userInfo = res.data;
|
||||
this.mobile=res.data.mobile;
|
||||
this.real_name=res.data.real_name;
|
||||
})
|
||||
},
|
||||
methods: {
|
||||
|
@ -110,7 +134,7 @@
|
|||
this.cashVal = this.userInfo.now_money;
|
||||
})
|
||||
},
|
||||
// 计算头部自定义导航高度;
|
||||
// 计算头部自定义导航高度;
|
||||
getWXStatusHeight() {
|
||||
// 获取距上
|
||||
const barTop = uni.getSystemInfoSync().statusBarHeight;
|
||||
|
@ -145,19 +169,33 @@
|
|||
} else {
|
||||
return
|
||||
}
|
||||
console.log(value)
|
||||
if (this.userInfo.id_card==''||this.userInfo.id_card==null) {
|
||||
this.IDCardShow = true
|
||||
return
|
||||
}
|
||||
CashApplicationApi(value).then(res => {
|
||||
uni.$u.toast(res.msg);
|
||||
setTimeout(()=>{
|
||||
setTimeout(() => {
|
||||
uni.navigateTo({
|
||||
url: `/pages/my/my`
|
||||
})
|
||||
},1500)
|
||||
}, 1500)
|
||||
}).catch(err => {
|
||||
return uni.$u.toast(err);
|
||||
return uni.$u.toast(err.msg);
|
||||
});
|
||||
},
|
||||
UpdateCard:function(){
|
||||
UpdateIdCardApi({'id_card':this.id_card,'real_name':this.real_name}).then(res => {
|
||||
uni.$u.toast(res.msg);
|
||||
setTimeout(() => {
|
||||
uni.navigateTo({
|
||||
url: `/pages/user_cash/index`
|
||||
})
|
||||
}, 1500)
|
||||
}).catch(err => {
|
||||
return uni.$u.toast(err.msg);
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,211 @@
|
|||
<template>
|
||||
<view class="shop-item">
|
||||
<view class="item-title" @click="navTo">
|
||||
<view>{{order_id}}</view>
|
||||
<view v-if="datas.paid==0">
|
||||
<text>待付款</text>
|
||||
</view>
|
||||
<view v-else>
|
||||
<text v-if="datas.status==0">待核销</text>
|
||||
<text v-if="datas.status==1">待核销</text>
|
||||
<text v-if="datas.status==2||datas.status==3">已完成</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="item-body" @click="navTo">
|
||||
<view class="body-content">
|
||||
<view>
|
||||
<view v-for="(item,index) in datas.goods_list" :key="index"
|
||||
style="display: flex;margin-bottom: 20rpx;">
|
||||
<image class="image" :src="item.image"></image>
|
||||
<view style="width: 520rpx;">
|
||||
<view class="" style="display: flex;justify-content: space-between;">
|
||||
<view>
|
||||
{{item.store_name}}
|
||||
</view>
|
||||
<view style="font-size: 32rpx;">
|
||||
¥{{item.price}}
|
||||
</view>
|
||||
</view>
|
||||
<view class="" style="display: flex;justify-content: space-between;">
|
||||
<view>
|
||||
{{item.unit_name}}
|
||||
</view>
|
||||
<view style="font-size: 32rpx;">
|
||||
x{{item.cart_num}}
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
|
||||
<!-- <view
|
||||
style="display: flex;flex-direction: column;align-items: center;justify-content: center;width: 100rpx;">
|
||||
<up-icon name="arrow-right-double" color="#20B128"></up-icon>
|
||||
</view> -->
|
||||
</view>
|
||||
<view class="all">共 {{datas.goods_count}} 件商品, 总金额 <text>¥{{datas.pay_price}}</text> </view>
|
||||
</view>
|
||||
|
||||
<view class="item-btn">
|
||||
|
||||
<view @click="navTo" style="width: 80px;">
|
||||
<up-button size="small" plain color="#20B128" shape="circle">查看详情</up-button>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
|
||||
|
||||
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import {
|
||||
ref,
|
||||
reactive,
|
||||
nextTick
|
||||
} from "vue"
|
||||
// 订单状态(0:待发货;1:待收货;2:已完成;3:已完成)
|
||||
const props = defineProps({
|
||||
type: {
|
||||
type: Number,
|
||||
default: 0
|
||||
},
|
||||
datas: {
|
||||
type: Object,
|
||||
default: () => {}
|
||||
},
|
||||
status: {
|
||||
type: String,
|
||||
default: ''
|
||||
},
|
||||
order_id: {
|
||||
type: String,
|
||||
default: '0'
|
||||
}
|
||||
})
|
||||
|
||||
const navTo = () => {
|
||||
uni.navigateTo({
|
||||
url: `/pagesOrder/detail/detail?is_mer=1&id=${props.datas.id}`
|
||||
})
|
||||
}
|
||||
|
||||
const emit = defineEmits(['cancleOrder', 'rePay', 'takeOrder', 'purchaseAgain']);
|
||||
const cancleOrder = () => {
|
||||
emit('cancleOrder', props.datas)
|
||||
}
|
||||
|
||||
const takeOrder = () => {
|
||||
emit('takeOrder', props.datas)
|
||||
}
|
||||
|
||||
const purchaseAgain = () => {
|
||||
emit('purchaseAgain', props.datas)
|
||||
}
|
||||
|
||||
const rePay = () => {
|
||||
emit('rePay', props.datas)
|
||||
}
|
||||
|
||||
const applySh = () => {
|
||||
emit('applyAfterSales', props.datas)
|
||||
}
|
||||
|
||||
const showVerifyFn = () => {
|
||||
emit('showVerifyFn', props.datas)
|
||||
}
|
||||
|
||||
const showVerifyPop = ref(false)
|
||||
const options = reactive({
|
||||
width: 500, // 宽度 单位rpx
|
||||
height: 100, // 高度 单位rpx
|
||||
code: props.datas.verify_code, // 生成条形码的值
|
||||
}, )
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
.shop-item {
|
||||
width: 710rpx;
|
||||
margin-bottom: 20rpx;
|
||||
background-color: #fff;
|
||||
border-radius: 14rpx;
|
||||
padding: 20rpx;
|
||||
box-sizing: border-box;
|
||||
|
||||
.item-title {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
}
|
||||
|
||||
.item-body {
|
||||
margin: 20rpx 0;
|
||||
|
||||
.body-content {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
color: #989898;
|
||||
|
||||
.image {
|
||||
width: 120rpx;
|
||||
height: 120rpx;
|
||||
margin-right: 20rpx;
|
||||
border-radius: 14rpx;
|
||||
}
|
||||
|
||||
.title {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
font-size: 28rpx;
|
||||
color: #444;
|
||||
}
|
||||
|
||||
.tips {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
font-size: 24rpx;
|
||||
margin-top: 10rpx;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
.all {
|
||||
text-align: right;
|
||||
font-size: 26rpx;
|
||||
|
||||
text {
|
||||
color: #F55726;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.item-btn {
|
||||
display: flex;
|
||||
justify-content: flex-end;
|
||||
|
||||
view {
|
||||
width: 80rpx;
|
||||
margin-left: 20rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.item-close {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
background-color: #F6F6F6;
|
||||
padding: 15rpx;
|
||||
border-radius: 14rpx;
|
||||
|
||||
.title {
|
||||
display: flex;
|
||||
|
||||
.type {
|
||||
font-weight: 600;
|
||||
margin-right: 20rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
|
@ -1,10 +1,6 @@
|
|||
<template>
|
||||
<view class="wrap">
|
||||
<up-navbar placeholder style="z-index: 100800;" @leftClick="navBack">
|
||||
<template #center>
|
||||
<view>订单</view>
|
||||
</template>
|
||||
</up-navbar>
|
||||
|
||||
<up-sticky bgColor="#fff">
|
||||
<view style="padding: 10rpx 20rpx 0 20rpx;">
|
||||
<up-search shape="round" v-model="keyword" @custom="searchOn" @search="searchOn" @clear="searchOn"
|
||||
|
@ -45,8 +41,6 @@
|
|||
</swiper-item>
|
||||
</swiper>
|
||||
</view>
|
||||
<orderCanclePopup :show="showCancel" @close="showCancel=false" @change="submitCancel" />
|
||||
<modal :show="showTake" title="确认收货" content="请确认您已收到货" @close="showTake=false" @change="confirmReceipt" />
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
|
@ -58,7 +52,7 @@
|
|||
import {
|
||||
ref
|
||||
} from 'vue';
|
||||
import good from "../order/component/good.vue";
|
||||
import good from "./component/goods.vue";
|
||||
import orderCanclePopup from "@/components/orderCanclePopup.vue"
|
||||
import modal from "@/components/modal.vue"
|
||||
import ZyPasswordboard from '@/uni_modules/zy-passwordboard/components/zy-passwordboard/zy-passwordboard.vue';
|
||||
|
@ -66,7 +60,7 @@
|
|||
cancelOrderApi,
|
||||
rePaymentApi,
|
||||
confirmReceiptApi,
|
||||
orderListApi,
|
||||
storeOrderListApi,
|
||||
purchaseAgainApi
|
||||
} from "@/api/order.js"
|
||||
import {
|
||||
|
@ -84,6 +78,10 @@
|
|||
}
|
||||
const tablist = ref([{
|
||||
name: '全部'
|
||||
},{
|
||||
name: '待核销'
|
||||
}, {
|
||||
name: '已核销'
|
||||
}, {
|
||||
name: '退款/售后'
|
||||
}]);
|
||||
|
@ -98,6 +96,8 @@
|
|||
tabsActive.value = current;
|
||||
|
||||
if (swiperCurrent.value == 0 && orderList.value[0].length == 0) getOrderList(0, '', ''); //全部
|
||||
if (swiperCurrent.value == 2 && orderList.value[2].length == 0) getOrderList(2, 1, 1); //待核销
|
||||
if (swiperCurrent.value == 3 && orderList.value[3].length == 0) getOrderList(3, 2, 1); //已核销
|
||||
if (swiperCurrent.value == 4 && orderList.value[4].length == 0) getOrderList(4, -1, 1); //退款
|
||||
}
|
||||
|
||||
|
@ -109,28 +109,6 @@
|
|||
}
|
||||
|
||||
|
||||
// 取消订单
|
||||
const showCancel = ref(false);
|
||||
let cancelId = '';
|
||||
const submitCancel = (e) => {
|
||||
showCancel.value = false;
|
||||
cancelOrderApi({
|
||||
order_id: cancelId,
|
||||
value: e.name
|
||||
}).then(res => {
|
||||
uni.showToast({
|
||||
title: '取消成功',
|
||||
icon: 'none'
|
||||
})
|
||||
orderList.value[1] = orderList.value[1].filter(item => item.id !== cancelId)
|
||||
})
|
||||
}
|
||||
|
||||
// 取消订单
|
||||
const cancleOrder = (e) => {
|
||||
cancelId = e.id;
|
||||
showCancel.value = true;
|
||||
}
|
||||
|
||||
// 确认收货
|
||||
const showTake = ref(false);
|
||||
|
@ -151,17 +129,7 @@
|
|||
})
|
||||
}
|
||||
|
||||
// 再次购买
|
||||
const purchaseAgain = (e) => {
|
||||
purchaseAgainApi({
|
||||
order_id: e.id
|
||||
}).then(res => {
|
||||
uni.$u.toast('已加入购物车');
|
||||
uni.navigateTo({
|
||||
url: '/pages/cart/cart'
|
||||
})
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
// 申请售后<!--sb项目-->
|
||||
const refundShow = ref(false);
|
||||
|
@ -215,78 +183,14 @@
|
|||
}
|
||||
}
|
||||
|
||||
const pay_type = ref('3')
|
||||
|
||||
const rePay = async (e) => {
|
||||
payFn(e)
|
||||
return
|
||||
if (!pay_type.value) return uni.$u.toast('请选择支付方式');
|
||||
if (pay_type.value == 3 || pay_type.value == 18) {
|
||||
let res = await userInfoApi()
|
||||
return res.data.pay_password ? passwordBoardVisible.value = true : showModal.value = true
|
||||
}
|
||||
}
|
||||
// 支付密码
|
||||
const password = ref(''); // 支付密码
|
||||
const passwordBoardVisible = ref(false);
|
||||
const passwordBoardProps = {
|
||||
title: '输入支付密码',
|
||||
onComplete(value) {
|
||||
password.value = value
|
||||
passwordBoardVisible.value = false
|
||||
console.log(password.value)
|
||||
// payFn()
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
const closeKeyBord = () => {
|
||||
password.value = ''
|
||||
}
|
||||
|
||||
|
||||
const payFn = (e) => {
|
||||
rePaymentApi({
|
||||
order_id: e.id,
|
||||
address_id: e.address_id,
|
||||
mer_id: e.merchant,
|
||||
pay_type: e.pay_type
|
||||
}).then(res => {
|
||||
if (res.data?.nonceStr) {
|
||||
uni.requestPayment({
|
||||
provider: 'wxpay',
|
||||
timeStamp: res.data.timeStamp,
|
||||
nonceStr: res.data.nonceStr,
|
||||
package: res.data.package,
|
||||
signType: res.data.signType,
|
||||
paySign: res.data.paySign,
|
||||
success: (e) => {
|
||||
if (e.errMsg == 'requestPayment:ok') {
|
||||
uni.showToast({
|
||||
title: '订单支付成功',
|
||||
icon: 'success'
|
||||
})
|
||||
reloadAll();
|
||||
} else uni.$u.toast('支付失败')
|
||||
},
|
||||
fail: (e) => {
|
||||
uni.$u.toast('用户取消支付')
|
||||
}
|
||||
})
|
||||
} else {
|
||||
uni.showToast({
|
||||
title: '订单支付成功',
|
||||
icon: 'success'
|
||||
})
|
||||
reloadAll();
|
||||
}
|
||||
|
||||
}).catch(err => {
|
||||
uni.$u.toast(err.msg || '网络错误')
|
||||
})
|
||||
}
|
||||
|
||||
const notWxPay = () => {
|
||||
alert("不是微信支付")
|
||||
}
|
||||
|
||||
|
||||
// 订单
|
||||
|
@ -331,7 +235,7 @@
|
|||
const getOrderList = (type = 0, status = '', paid = 1, ifPullReFresh = false) => {
|
||||
if (where.value[type].loadend) return;
|
||||
where.value[type].loading = true;
|
||||
orderListApi({
|
||||
storeOrderListApi({
|
||||
page_no: where.value[type].page_no,
|
||||
page_size: where.value[type].page_size,
|
||||
order_id: keyword.value,
|
||||
|
@ -400,6 +304,7 @@
|
|||
if (options.back) back = options.back;
|
||||
|
||||
uni.$on('reLoadOrderList', reloadAll);
|
||||
getOrderList(0, '', ''); //全部
|
||||
})
|
||||
|
||||
onUnload(() => {
|
||||
|
|
|
@ -0,0 +1,197 @@
|
|||
<template>
|
||||
<view style="background-color: #ffffff;">
|
||||
<up-sticky offset-top="0" style="background-color: #ffffff;">
|
||||
<view class="navbar">
|
||||
<view style="width:35%;">
|
||||
<up-search placeholder="请输入商品" @search="searchKeyword" @clear="searchKeyword" v-model="keyword"
|
||||
:showAction="false"></up-search>
|
||||
</view>
|
||||
<view style="width:65%;padding-left: 10rpx;">
|
||||
<uni-datetime-picker v-model="range" type="daterange" @change="calendarConfirm" />
|
||||
</view>
|
||||
</view>
|
||||
</up-sticky>
|
||||
|
||||
<view class="content">
|
||||
<up-transition :show="true" mode="slide-left">
|
||||
<up-list @scrolltolower="scrolltolower" v-if="goodsList1.length>0">
|
||||
<up-list-item class="card" v-for="(item,index) in goodsList1" :key='index'>
|
||||
|
||||
<view class="card-content">
|
||||
<view class="card-content-l" style="width: 152rpx;height: 152rpx;">
|
||||
<image style="width: 152rpx;height: 152rpx;" :src="item.image" mode=""></image>
|
||||
</view>
|
||||
<view class="card-content-r">
|
||||
<view class="title ellipsis">
|
||||
{{item.store_name}}
|
||||
</view>
|
||||
<view>
|
||||
单位:{{item.unit_name}}
|
||||
</view>
|
||||
<view>
|
||||
规格:{{item.store_info}}
|
||||
</view>
|
||||
<view style="color: red;">
|
||||
数量: {{item.nums}}
|
||||
</view>
|
||||
<view style="color: red;" v-if="item.staff_id>0">
|
||||
确认人: {{item.nums}}
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
<up-line style="margin-top: 30rpx;" color="#F3F3F3"></up-line>
|
||||
</up-list-item>
|
||||
</up-list>
|
||||
<up-empty @click='test2' v-else mode="data" icon="http://cdn.uviewui.com/uview/empty/data.png">
|
||||
</up-empty>
|
||||
</up-transition>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</template>
|
||||
|
||||
|
||||
<script setup>
|
||||
import {
|
||||
timeFrom
|
||||
} from '@/uni_modules/uview-plus';
|
||||
|
||||
import {
|
||||
ref,
|
||||
reactive,
|
||||
} from "vue"
|
||||
import {
|
||||
SystemStoreStorageGroupLists,
|
||||
} from "@/api/system_store_storage.js"
|
||||
|
||||
const show = ref(false)
|
||||
const where = ref({
|
||||
store_name: '',
|
||||
page_no: 1,
|
||||
start_time: timeFrom(new Date()),
|
||||
end_time: timeFrom(new Date())
|
||||
})
|
||||
const calendarShow = ref(false)
|
||||
|
||||
const calendarConfirm = (e) => {
|
||||
where.value.start_time = e[0];
|
||||
where.value.end_time = e[1];
|
||||
goodsList1.value=[]
|
||||
getGoodsList()
|
||||
calendarShow.value = false
|
||||
}
|
||||
|
||||
// 列表
|
||||
const goodsList = ref([])
|
||||
const goodsList1 = ref([])
|
||||
|
||||
const getGoodsList = async () => {
|
||||
let res = await SystemStoreStorageGroupLists(where.value)
|
||||
goodsList1.value.push(...res.data.lists)
|
||||
}
|
||||
|
||||
const keyword = ref('');
|
||||
|
||||
const searchKeyword = () => {
|
||||
where.value.store_name = keyword.value;
|
||||
goodsList1.value=[]
|
||||
getGoodsList();
|
||||
}
|
||||
const scrolltolower = () => {
|
||||
where.value.page_no += 1
|
||||
getGoodsList()
|
||||
}
|
||||
getGoodsList()
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
.navbar {
|
||||
padding: 0 20rpx;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
font-size: 22rpx;
|
||||
color: #777;
|
||||
|
||||
.nav-item {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
position: relative;
|
||||
|
||||
image {
|
||||
height: 40rpx;
|
||||
width: 40rpx;
|
||||
}
|
||||
|
||||
.badge {
|
||||
position: absolute;
|
||||
top: -10rpx;
|
||||
right: 10rpx;
|
||||
background-color: #FF0000;
|
||||
color: #FFFFFF;
|
||||
text-align: center;
|
||||
width: 30rpx;
|
||||
height: 30rpx;
|
||||
border-radius: 30rpx;
|
||||
font-size: 18rpx;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
.content {
|
||||
padding: 20rpx;
|
||||
padding-bottom: 150rpx;
|
||||
|
||||
.card {
|
||||
width: 710rpx;
|
||||
margin: 0 auto;
|
||||
padding: 20rpx;
|
||||
box-sizing: border-box;
|
||||
background-color: white;
|
||||
|
||||
|
||||
|
||||
.card-content {
|
||||
display: flex;
|
||||
position: relative;
|
||||
|
||||
.card-content-l {
|
||||
margin-right: 20rpx;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.card-content-r {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
|
||||
.title {
|
||||
font-size: 30rpx;
|
||||
width: 500rpx;
|
||||
}
|
||||
.ipt {
|
||||
display: flex;
|
||||
height: 56rpx;
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
.ellipsis {
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
</style>
|
|
@ -0,0 +1,242 @@
|
|||
<template>
|
||||
<view style="background-color: #ffffff;">
|
||||
<up-sticky offset-top="0" style="background-color: #ffffff;">
|
||||
<view class="navbar">
|
||||
<view style="width:55%;">
|
||||
<up-search placeholder="请输入商品" @search="searchKeyword" @clear="searchKeyword" v-model="keyword"
|
||||
:showAction="false"></up-search>
|
||||
</view>
|
||||
<view style="width:45%;padding-left: 10rpx;">
|
||||
<uni-datetime-picker v-model="range" type="date" @change="calendarConfirm" />
|
||||
</view>
|
||||
</view>
|
||||
</up-sticky>
|
||||
|
||||
<view class="content">
|
||||
<up-transition :show="true" mode="slide-left">
|
||||
<up-list @scrolltolower="scrolltolower" v-if="goodsList1.length>0">
|
||||
<up-list-item class="card" v-for="(item,index) in goodsList1" :key='index'>
|
||||
|
||||
<view class="card-content">
|
||||
<view class="card-content-l" style="width: 152rpx;height: 152rpx;">
|
||||
<image style="width: 152rpx;height: 152rpx;" :src="item.image" mode=""></image>
|
||||
</view>
|
||||
<view class="card-content-r">
|
||||
<view class="title ellipsis">
|
||||
{{item.store_name}}
|
||||
</view>
|
||||
<view>
|
||||
单位:{{item.unit_name}}
|
||||
</view>
|
||||
<view>
|
||||
规格:{{item.store_info}}
|
||||
</view>
|
||||
<view style="color: red;">
|
||||
数量: {{item.nums}}
|
||||
</view>
|
||||
<view style="color: red;" v-if="item.staff_id>0">
|
||||
确认人: {{item.nums}}
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
<view class="card-footer">
|
||||
<up-button size="small" type="primary" shape="circle" @click="cancleOrder(item)"
|
||||
v-if="item.status==0">确认已入库</up-button>
|
||||
</view>
|
||||
<up-line style="margin-top: 30rpx;" color="#F3F3F3"></up-line>
|
||||
</up-list-item>
|
||||
</up-list>
|
||||
<up-empty v-else mode="data" icon="http://cdn.uviewui.com/uview/empty/data.png">
|
||||
</up-empty>
|
||||
</up-transition>
|
||||
<up-modal :show="show" title="入库确认" content="是否确认该商品入库" showCancelButton @cancel="show=false" @confirm="offerUpdate()">
|
||||
|
||||
</up-modal>
|
||||
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
|
||||
<script setup>
|
||||
import {
|
||||
timeFrom
|
||||
} from '@/uni_modules/uview-plus';
|
||||
|
||||
import {
|
||||
ref,
|
||||
reactive,
|
||||
} from "vue"
|
||||
import {
|
||||
SystemStoreStorageLists,
|
||||
SystemStoreStorageWarehousingAdd
|
||||
} from "@/api/system_store_storage.js"
|
||||
|
||||
const show = ref(false)
|
||||
const dates=ref(timeFrom(new Date()))
|
||||
const where = ref({
|
||||
store_name: '',
|
||||
page_no: 1,
|
||||
start_time: dates.value,
|
||||
end_time: dates.value
|
||||
})
|
||||
const calendarShow = ref(false)
|
||||
const formData = ref({
|
||||
"id": '',
|
||||
'product_id': '',
|
||||
})
|
||||
const calendarConfirm = (e) => {
|
||||
where.value.start_time = e;
|
||||
where.value.end_time = e;
|
||||
where.value.page_no = 1;
|
||||
goodsList1.value = []
|
||||
getGoodsList()
|
||||
calendarShow.value = false
|
||||
}
|
||||
|
||||
// 列表
|
||||
const showGoods1 = ref(false)
|
||||
const goodsList1 = ref([])
|
||||
|
||||
const getGoodsList = async () => {
|
||||
let res = await SystemStoreStorageLists(where.value)
|
||||
goodsList1.value.push(...res.data.lists)
|
||||
}
|
||||
const cancleOrder = (item) => {
|
||||
show.value = true
|
||||
formData.value.id = item['id']
|
||||
formData.value.product_id = item['product_id']
|
||||
}
|
||||
const offerUpdate = () => {
|
||||
SystemStoreStorageWarehousingAdd(formData.value).then(res => {
|
||||
uni.$u.toast(res.msg);
|
||||
show.value = false
|
||||
goodsList1.value = []
|
||||
getGoodsList()
|
||||
})
|
||||
}
|
||||
|
||||
const keyword = ref('');
|
||||
|
||||
const searchKeyword = () => {
|
||||
where.value.store_name = keyword.value;
|
||||
goodsList1.value = []
|
||||
getGoodsList();
|
||||
}
|
||||
const scrolltolower = () => {
|
||||
where.value.page_no += 1
|
||||
getGoodsList()
|
||||
}
|
||||
getGoodsList()
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
.navbar {
|
||||
padding: 0 20rpx;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
font-size: 22rpx;
|
||||
color: #777;
|
||||
|
||||
.nav-item {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
position: relative;
|
||||
|
||||
image {
|
||||
height: 40rpx;
|
||||
width: 40rpx;
|
||||
}
|
||||
|
||||
.badge {
|
||||
position: absolute;
|
||||
top: -10rpx;
|
||||
right: 10rpx;
|
||||
background-color: #FF0000;
|
||||
color: #FFFFFF;
|
||||
text-align: center;
|
||||
width: 30rpx;
|
||||
height: 30rpx;
|
||||
border-radius: 30rpx;
|
||||
font-size: 18rpx;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
.content {
|
||||
padding: 20rpx;
|
||||
padding-bottom: 150rpx;
|
||||
|
||||
.card {
|
||||
width: 710rpx;
|
||||
margin: 0 auto;
|
||||
padding: 20rpx;
|
||||
box-sizing: border-box;
|
||||
background-color: white;
|
||||
|
||||
|
||||
|
||||
.card-content {
|
||||
display: flex;
|
||||
position: relative;
|
||||
|
||||
.card-content-l {
|
||||
margin-right: 20rpx;
|
||||
position: relative;
|
||||
|
||||
.status {
|
||||
width: 152rpx;
|
||||
height: 40rpx;
|
||||
background-color: rgba(0, 0, 0, .3);
|
||||
text-align: center;
|
||||
color: white;
|
||||
font-size: 24rpx;
|
||||
line-height: 40rpx;
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.card-content-r {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
|
||||
.title {
|
||||
font-size: 30rpx;
|
||||
width: 500rpx;
|
||||
}
|
||||
|
||||
.need {
|
||||
color: #777777;
|
||||
font-size: 24rpx;
|
||||
}
|
||||
|
||||
.ipt {
|
||||
display: flex;
|
||||
height: 56rpx;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
.card-footer {
|
||||
margin-top: 30rpx;
|
||||
text-align: right;
|
||||
font-size: 28rpx;
|
||||
color: #060606;
|
||||
}
|
||||
}
|
||||
}
|
||||
.ellipsis {
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
</style>
|
|
@ -9,7 +9,7 @@
|
|||
@click="callPhone(store_info.phone)">
|
||||
<view class="top" style="align-items: flex-start;">
|
||||
<view style="color: #333;display: flex;align-items: center;flex-shrink: 0;">
|
||||
<text style="margin: 0 10rpx;color:#20B128">自提点</text>
|
||||
<text style="margin: 0 10rpx;color:#20B128">配送点</text>
|
||||
</view>
|
||||
<view>
|
||||
<view style="color: #333;">
|
||||
|
@ -104,7 +104,7 @@
|
|||
</view>
|
||||
</view>
|
||||
|
||||
<view class="qr_code" v-if="datas.paid == 1 && datas.status == 1">
|
||||
<view class="qr_code" v-if="datas.paid == 1 && datas.status == 1 &&is_mer!=1">
|
||||
<up-image :src="datas.verify_base64" width="404rpx" height="60rpx"></up-image>
|
||||
<view style="font-weight: bold;color: #333;font-size: 26;margin-top: 20rpx;">
|
||||
核销码 {{datas.verify_code}}
|
||||
|
@ -167,6 +167,10 @@
|
|||
<view>下单时间</view>
|
||||
<view>{{datas.create_time}}</view>
|
||||
</view>
|
||||
<view class="row">
|
||||
<view>备注</view>
|
||||
<view>{{datas.mark}}</view>
|
||||
</view>
|
||||
<view class="row" style="margin-bottom: 0;">
|
||||
<view>支付状态</view>
|
||||
<view v-if="datas.paid == 1">已支付</view>
|
||||
|
@ -186,7 +190,7 @@
|
|||
</block>
|
||||
<block v-else>
|
||||
<view></view>
|
||||
<view style="width: 450rpx;">
|
||||
<view style="width: 450rpx;" v-if="is_mer!=1">
|
||||
<!-- <up-button v-if="datas.status==0||datas.status==1" color="#20B128" shape="circle"
|
||||
@click="showTake=true">确认收货</up-button> -->
|
||||
<up-button color="#20B128" plain shape="circle" @click="purchaseAgain">再次购买</up-button>
|
||||
|
@ -259,9 +263,11 @@
|
|||
|
||||
const store_info = ref({})
|
||||
const datas = ref({})
|
||||
const is_mer = ref(0)
|
||||
const getDetails = () => {
|
||||
orderDetailApi({
|
||||
order_id: datas.value.id,
|
||||
is_mer:is_mer.value
|
||||
// ...location
|
||||
}).then(res => {
|
||||
datas.value = res.data;
|
||||
|
@ -386,9 +392,9 @@
|
|||
const rePay = () => {
|
||||
rePaymentApi({
|
||||
order_id: datas.value.id,
|
||||
mer_id: shopInfo.value.mer_id,
|
||||
// mer_id: shopInfo.value.mer_id,
|
||||
address_id: addressInfo.value.address_id,
|
||||
pay_type: 1
|
||||
pay_type: datas.value.pay_type
|
||||
}).then(res => {
|
||||
if (!res.data?.nonceStr) return uni.$u.toast('支付失败!');
|
||||
uni.requestPayment({
|
||||
|
@ -512,6 +518,7 @@
|
|||
});
|
||||
if (option.id) {
|
||||
datas.value.id = option.id;
|
||||
is_mer.value = option.is_mer;
|
||||
getLocation()
|
||||
}
|
||||
})
|
||||
|
|
|
@ -71,7 +71,7 @@
|
|||
<view class="scroll-wrap">
|
||||
<scroll-view style="max-height: 50vh;padding-bottom: 20rpx;" scroll-y>
|
||||
<block v-for="(item,index) in goodsList" :key="index">
|
||||
<view class="goods">
|
||||
<view v-if="item.status == 0" class="goods">
|
||||
<view class="goods-item">
|
||||
<view class="goods-item-left">
|
||||
<view class="goods-item-left-img">
|
||||
|
@ -264,7 +264,7 @@
|
|||
let goodsListSel = [];
|
||||
goodsList.value.map(i => {
|
||||
if (i.isSelected) {
|
||||
ids.push(i.old_cart_id);
|
||||
ids.push(i.id);
|
||||
goodsListSel.push(i);
|
||||
}
|
||||
});
|
||||
|
|
|
@ -0,0 +1,213 @@
|
|||
<template>
|
||||
<view style="background-color: #ffffff;">
|
||||
<up-sticky offset-top="0" style="background-color: #ffffff;">
|
||||
<view class="navbar">
|
||||
<view style="width:35%;">
|
||||
<up-search placeholder="请输入商品" @search="searchKeyword" @clear="searchKeyword" v-model="keyword"
|
||||
:showAction="false"></up-search>
|
||||
</view>
|
||||
<view style="width:65%;padding-left: 10rpx;">
|
||||
<uni-datetime-picker v-model="range" type="daterange" @change="calendarConfirm" />
|
||||
</view>
|
||||
</view>
|
||||
</up-sticky>
|
||||
|
||||
<view class="content">
|
||||
<up-transition :show="true" mode="slide-left">
|
||||
<up-list @scrolltolower="scrolltolower" v-if="goodsList1.length>0">
|
||||
<up-list-item class="card" v-for="(item,index) in goodsList1" :key='index'>
|
||||
|
||||
<view class="card-content">
|
||||
<view class="card-content-l" style="width: 152rpx;height: 152rpx;">
|
||||
<image style="width: 152rpx;height: 152rpx;" :src="item.image" mode=""></image>
|
||||
</view>
|
||||
<view class="card-content-r">
|
||||
<view class="title ellipsis">
|
||||
{{item.store_name}}
|
||||
</view>
|
||||
<view>
|
||||
时间:{{item.create_time}}
|
||||
</view>
|
||||
<view>
|
||||
规格:{{item.store_info}}
|
||||
</view>
|
||||
|
||||
<view>
|
||||
单价:<span style="margin-right: 20rpx;color: red;">{{item.price}}</span>
|
||||
数量:<span style="margin-right: 20rpx;color: red;">{{item.cart_num}}/{{item.unit_name}}</span>
|
||||
总价:<span style="margin-right: 20rpx;color: red;">{{item.total_price}}</span>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
<up-line style="margin-top: 30rpx;" color="#F3F3F3"></up-line>
|
||||
</up-list-item>
|
||||
</up-list>
|
||||
<up-empty @click='test2' v-else mode="data" icon="http://cdn.uviewui.com/uview/empty/data.png">
|
||||
</up-empty>
|
||||
</up-transition>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</template>
|
||||
|
||||
|
||||
<script setup>
|
||||
import {
|
||||
timeFrom
|
||||
} from '@/uni_modules/uview-plus';
|
||||
|
||||
import {
|
||||
ref,
|
||||
reactive,
|
||||
} from "vue"
|
||||
import {
|
||||
StoreOrderCartInfoGroupLists,
|
||||
} from "@/api/store_order_cart_info.js"
|
||||
|
||||
const test2 = () => {
|
||||
console.log("点解")
|
||||
uni.navigateTo({
|
||||
url: '/pages/index/index'
|
||||
})
|
||||
}
|
||||
const show = ref(false)
|
||||
const min_date = ref('')
|
||||
const where = ref({
|
||||
store_name: '',
|
||||
page_no: 1,
|
||||
start_time: timeFrom(new Date()),
|
||||
end_time: timeFrom(new Date())
|
||||
})
|
||||
const calendarShow = ref(false)
|
||||
|
||||
const calendarConfirm = (e) => {
|
||||
where.value.start_time = e[0];
|
||||
where.value.end_time = e[1];
|
||||
goodsList1.value = []
|
||||
getGoodsList()
|
||||
calendarShow.value = false
|
||||
}
|
||||
let currentDate = new Date();
|
||||
min_date.value=currentDate.setFullYear(currentDate.getFullYear() - 1);
|
||||
// 列表
|
||||
|
||||
const goodsList1 = ref([])
|
||||
|
||||
const getGoodsList = async () => {
|
||||
let res = await StoreOrderCartInfoGroupLists(where.value)
|
||||
goodsList1.value.push(...res.data.lists)
|
||||
}
|
||||
|
||||
const keyword = ref('');
|
||||
|
||||
const searchKeyword = () => {
|
||||
where.value.store_name = keyword.value;
|
||||
goodsList1.value = []
|
||||
getGoodsList();
|
||||
}
|
||||
const scrolltolower = () => {
|
||||
where.value.page_no += 1
|
||||
getGoodsList()
|
||||
}
|
||||
getGoodsList()
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
.navbar {
|
||||
padding: 0 20rpx;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
font-size: 22rpx;
|
||||
color: #777;
|
||||
|
||||
.nav-item {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
position: relative;
|
||||
|
||||
image {
|
||||
height: 40rpx;
|
||||
width: 40rpx;
|
||||
}
|
||||
|
||||
.badge {
|
||||
position: absolute;
|
||||
top: -10rpx;
|
||||
right: 10rpx;
|
||||
background-color: #FF0000;
|
||||
color: #FFFFFF;
|
||||
text-align: center;
|
||||
width: 30rpx;
|
||||
height: 30rpx;
|
||||
border-radius: 30rpx;
|
||||
font-size: 18rpx;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
.content {
|
||||
padding: 20rpx;
|
||||
padding-bottom: 150rpx;
|
||||
|
||||
.card {
|
||||
width: 710rpx;
|
||||
margin: 0 auto;
|
||||
padding: 20rpx;
|
||||
box-sizing: border-box;
|
||||
background-color: white;
|
||||
|
||||
|
||||
|
||||
.card-content {
|
||||
display: flex;
|
||||
position: relative;
|
||||
|
||||
.card-content-l {
|
||||
margin-right: 20rpx;
|
||||
position: relative;
|
||||
|
||||
}
|
||||
|
||||
.card-content-r {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
|
||||
.title {
|
||||
font-size: 30rpx;
|
||||
width: 500rpx;
|
||||
}
|
||||
|
||||
.need {
|
||||
color: #777777;
|
||||
font-size: 24rpx;
|
||||
}
|
||||
|
||||
.ipt {
|
||||
display: flex;
|
||||
height: 56rpx;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
.ellipsis {
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
</style>
|
|
@ -0,0 +1,212 @@
|
|||
<template>
|
||||
<view style="background-color: #ffffff;">
|
||||
<up-sticky offset-top="0" style="background-color: #ffffff;">
|
||||
<view class="navbar">
|
||||
<view style="width:55%;">
|
||||
<up-search placeholder="请输入商品" @search="searchKeyword" @clear="searchKeyword" v-model="keyword"
|
||||
:showAction="false"></up-search>
|
||||
</view>
|
||||
<view style="width:45%;padding-left: 10rpx;">
|
||||
<uni-datetime-picker v-model="range" type="date" @change="calendarConfirm" />
|
||||
</view>
|
||||
</view>
|
||||
</up-sticky>
|
||||
|
||||
<view class="content">
|
||||
<up-transition :show="true" mode="slide-left">
|
||||
<up-list @scrolltolower="scrolltolower" v-if="goodsList1.length>0">
|
||||
<up-list-item class="card" v-for="(item,index) in goodsList1" :key='index'>
|
||||
|
||||
<view class="card-content">
|
||||
<view class="card-content-l" style="width: 152rpx;height: 152rpx;">
|
||||
<image style="width: 152rpx;height: 152rpx;" :src="item.image" mode=""></image>
|
||||
</view>
|
||||
<view class="card-content-r">
|
||||
<view class="title ellipsis">
|
||||
{{item.store_name}}
|
||||
</view>
|
||||
<view>
|
||||
时间:{{item.create_time}}
|
||||
</view>
|
||||
<view>
|
||||
规格:{{item.store_info}}
|
||||
</view>
|
||||
|
||||
<view>
|
||||
单价:<span style="margin-right: 20rpx;color: red;">{{item.price}}</span>
|
||||
数量:<span style="margin-right: 20rpx;color: red;">{{item.cart_num}}/{{item.unit_name}}</span>
|
||||
总价:<span style="margin-right: 20rpx;color: red;">{{item.total_price}}</span>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
<up-line style="margin-top: 30rpx;" color="#F3F3F3"></up-line>
|
||||
</up-list-item>
|
||||
</up-list>
|
||||
<up-empty @click='test2' v-else mode="data" icon="http://cdn.uviewui.com/uview/empty/data.png">
|
||||
</up-empty>
|
||||
</up-transition>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
|
||||
<script setup>
|
||||
import {
|
||||
timeFrom
|
||||
} from '@/uni_modules/uview-plus';
|
||||
|
||||
import {
|
||||
ref,
|
||||
reactive,
|
||||
} from "vue"
|
||||
import {
|
||||
StoreOrderCartInfoLists,
|
||||
} from "@/api/store_order_cart_info.js"
|
||||
|
||||
const test2 = () => {
|
||||
console.log("点解")
|
||||
uni.navigateTo({
|
||||
url: '/pages/index/index'
|
||||
})
|
||||
}
|
||||
const show = ref(false)
|
||||
const min_date = ref('')
|
||||
const where = ref({
|
||||
store_name: '',
|
||||
page_no: 1,
|
||||
start_time: timeFrom(new Date()),
|
||||
end_time: timeFrom(new Date())
|
||||
})
|
||||
const calendarShow = ref(false)
|
||||
|
||||
const calendarConfirm = (e) => {
|
||||
where.value.start_time = e;
|
||||
where.value.end_time = e;
|
||||
goodsList1.value = []
|
||||
getGoodsList()
|
||||
calendarShow.value = false
|
||||
}
|
||||
let currentDate = new Date();
|
||||
min_date.value=currentDate.setFullYear(currentDate.getFullYear() - 1);
|
||||
// 列表
|
||||
|
||||
const goodsList1 = ref([])
|
||||
|
||||
const getGoodsList = async () => {
|
||||
let res = await StoreOrderCartInfoLists(where.value)
|
||||
goodsList1.value.push(...res.data.lists)
|
||||
}
|
||||
|
||||
const keyword = ref('');
|
||||
|
||||
const searchKeyword = () => {
|
||||
where.value.store_name = keyword.value;
|
||||
goodsList1.value = []
|
||||
getGoodsList();
|
||||
}
|
||||
const scrolltolower = () => {
|
||||
where.value.page_no += 1
|
||||
getGoodsList()
|
||||
}
|
||||
getGoodsList()
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
.navbar {
|
||||
padding: 0 20rpx;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
font-size: 22rpx;
|
||||
color: #777;
|
||||
|
||||
.nav-item {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
position: relative;
|
||||
|
||||
image {
|
||||
height: 40rpx;
|
||||
width: 40rpx;
|
||||
}
|
||||
|
||||
.badge {
|
||||
position: absolute;
|
||||
top: -10rpx;
|
||||
right: 10rpx;
|
||||
background-color: #FF0000;
|
||||
color: #FFFFFF;
|
||||
text-align: center;
|
||||
width: 30rpx;
|
||||
height: 30rpx;
|
||||
border-radius: 30rpx;
|
||||
font-size: 18rpx;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
.content {
|
||||
padding: 20rpx;
|
||||
padding-bottom: 150rpx;
|
||||
|
||||
.card {
|
||||
width: 710rpx;
|
||||
margin: 0 auto;
|
||||
padding: 20rpx;
|
||||
box-sizing: border-box;
|
||||
background-color: white;
|
||||
|
||||
|
||||
|
||||
.card-content {
|
||||
display: flex;
|
||||
position: relative;
|
||||
|
||||
.card-content-l {
|
||||
margin-right: 20rpx;
|
||||
position: relative;
|
||||
|
||||
}
|
||||
|
||||
.card-content-r {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
|
||||
.title {
|
||||
font-size: 30rpx;
|
||||
width: 500rpx;
|
||||
}
|
||||
|
||||
.need {
|
||||
color: #777777;
|
||||
font-size: 24rpx;
|
||||
}
|
||||
|
||||
.ipt {
|
||||
display: flex;
|
||||
height: 56rpx;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
.ellipsis {
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
</style>
|
|
@ -1,46 +1,14 @@
|
|||
<template>
|
||||
<view class="">
|
||||
<!-- <view class="m-card m-address"> -->
|
||||
<!-- <view class="address-info" @click="showAddress = true">
|
||||
<view class="top">
|
||||
<up-icon name="account"></up-icon>
|
||||
<view class="t-name">{{ addressInfo.real_name }}</view>
|
||||
<view>{{ addressInfo.phone }}</view>
|
||||
</view>
|
||||
<view class="bottom u-line-2">
|
||||
{{ addressInfo.detail }}
|
||||
</view>
|
||||
</view> -->
|
||||
<!-- <view class="address-info">
|
||||
<view class="top">
|
||||
{{ STORE_INFO.name }}是的
|
||||
</view>
|
||||
<view class="bottom u-line-2">
|
||||
{{ STORE_INFO.detailed_address }}
|
||||
</view>
|
||||
</view> -->
|
||||
<!-- <view class="address-btn item-center">
|
||||
<view class='ship-type' style="">
|
||||
<view class="ship-type-item" :class='{ actShipItem: orderInfo.shipping_type == 2 }'
|
||||
@click='orderInfo.shipping_type = 2'>
|
||||
自提
|
||||
</view>
|
||||
<view class="ship-type-item" @click='orderInfo.shipping_type = 1'
|
||||
:class='{ actShipItem: orderInfo.shipping_type == 1 }' v-if='orderInfo.default_delivery == 1'>
|
||||
配送
|
||||
</view>
|
||||
</view>
|
||||
</view> -->
|
||||
|
||||
<view class="m-card m-address" style="margin-top: 20rpx;">
|
||||
<view class="address-info"
|
||||
style='display: flex;justify-content: space-between;width: 690rpx;align-items: center;'>
|
||||
<view class="top" style="align-items: flex-start;">
|
||||
<view style="color: #333;width: 200rpx;">
|
||||
<view style="margin: 0 10rpx;color:#20B128;width: 150rpx;">推荐自提点</view>
|
||||
<!-- <view style="color: #333;width: 200rpx;">
|
||||
<view style="margin: 0 10rpx;color:#20B128;width: 150rpx;">配送点</view>
|
||||
<view class="isreser"> {{reservation?"次日可提":"当日可提" }}
|
||||
</view>
|
||||
</view>
|
||||
</view> -->
|
||||
<view>
|
||||
<view style="color: #333;">
|
||||
{{shop_Info.name}}
|
||||
|
@ -57,31 +25,34 @@
|
|||
</view>
|
||||
<view style="padding: 20rpx;background-color:#20B128;color: white;border-radius: 40rpx;flex-shrink: 0;"
|
||||
@click="navgo(`/multipleShop/index/index?event=settle&cart_id=${cartStore.cartList.join(',')}`)">
|
||||
切换门店
|
||||
切换配送点
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="m-card good-info">
|
||||
<view class="head-title">商品明细</view>
|
||||
|
||||
<!-- </view> -->
|
||||
<view class="m-card m-good" v-for="(item, index) in cartList" :key="index">
|
||||
<view class="image">
|
||||
<up-image width="160rpx" height="160rpx" :src="item.imgs"></up-image>
|
||||
</view>
|
||||
<view class="body-content">
|
||||
<view>
|
||||
<view class="title">
|
||||
<view>{{ item.name }}</view>
|
||||
<view>¥{{ item.price }}</view>
|
||||
<view class="m-good" v-for="(item, index) in cartList" :key="index">
|
||||
<view class="image">
|
||||
<up-image width="160rpx" height="160rpx" :src="item.imgs"></up-image>
|
||||
</view>
|
||||
<view class="body-content">
|
||||
<view>
|
||||
<view class="title">
|
||||
<view>{{ item.name }}</view>
|
||||
<view>¥{{ item.price }}</view>
|
||||
</view>
|
||||
<view class="tips">
|
||||
<view>{{ item.unit_name }}</view>
|
||||
<view>x{{ item.cart_num }}</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="tips">
|
||||
<view>{{ item.unit_name }}</view>
|
||||
<view>x{{ item.cart_num }}</view>
|
||||
<view class="time">
|
||||
{{ orderInfo.delivery_msg }}
|
||||
</view>
|
||||
</view>
|
||||
<view class="time">
|
||||
{{ orderInfo.delivery_msg }}
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
<view class="m-card good-info">
|
||||
|
@ -92,7 +63,7 @@
|
|||
<text>¥</text>{{ c_price(orderInfo.pay_price, 0) }}<text>.{{ c_price(orderInfo.pay_price, 1) }}</text>
|
||||
</view>
|
||||
<view v-else>
|
||||
<up-skeleton :loading="true" :animate="true" ></up-skeleton>
|
||||
<up-skeleton :loading="true" :animate="true"></up-skeleton>
|
||||
</view>
|
||||
</view>
|
||||
<view class="row">
|
||||
|
@ -101,16 +72,25 @@
|
|||
</view>
|
||||
<view class="row" v-if="[4,5,6].includes(userInfo.user_ship)" style="color: red;">
|
||||
<view>优惠减免</view>
|
||||
<view>
|
||||
<view v-if="orderInfo.frozen_money">
|
||||
<text>¥</text>{{ c_price(orderInfo.frozen_money, 0) }}<text>.{{ c_price(orderInfo.frozen_money, 1) }}</text>
|
||||
</view>
|
||||
<view v-else>
|
||||
<up-skeleton :loading="true" :animate="true"></up-skeleton>
|
||||
</view>
|
||||
</view>
|
||||
<view class="row" v-if="userInfo.user_ship==1 ">
|
||||
<view>优惠返还</view>
|
||||
<view>
|
||||
<view v-if="orderInfo.activity_price">
|
||||
<text>¥</text>{{ c_price(orderInfo.activity_price, 0) }}<text>.{{ c_price(orderInfo.activity_price, 1) }}</text>
|
||||
</view>
|
||||
<view v-else>
|
||||
<up-skeleton :loading="true" :animate="true"></up-skeleton>
|
||||
</view>
|
||||
</view>
|
||||
<up-alert v-if="timeContent!=''" type="error" :description="timeContent"></up-alert>
|
||||
<!-- <up-notice-bar text="门店切换已移动到首页,若切换店铺,购物车商品将跟随门店一起切换"></up-notice-bar> -->
|
||||
|
||||
</view>
|
||||
|
||||
<view class="m-card order-remark">
|
||||
|
@ -201,6 +181,7 @@
|
|||
</view>
|
||||
|
||||
</view>
|
||||
<up-modal :show="timeShow" :content='timeContent' @confirm="timeShow=false"></up-modal>
|
||||
|
||||
<addressPopup ref="addressRef" :show="showAddress" :list="addressList" @close="showAddress = false"
|
||||
@change="changeAddress" />
|
||||
|
@ -213,20 +194,6 @@
|
|||
<up-modal :show="showModal" title="您还没设置密码" :closeOnClickOverlay="true" zoom confirmText='去设置' showCancelButton
|
||||
@close='showModal=false' @cancel='showModal=false' @confirm="navgo('/pagesOrder/setPayPassword/index')"
|
||||
confirmColor='#27B52F' cancelText='取消'></up-modal>
|
||||
<up-popup :show="LocationShow" mode="bottom" @open="LocationShowOpen()">
|
||||
<view style="margin: 40rpx 10rpx;">
|
||||
<up-row customStyle="margin-bottom: 10px" gutter="10">
|
||||
<up-col span="6">
|
||||
<up-button text="取消" @click="userLocationfalse()"></up-button>
|
||||
</up-col>
|
||||
<up-col span="6">
|
||||
<up-button type="primary" text="设置授权" color="#20B128" @click="opensettings()"></up-button>
|
||||
</up-col>
|
||||
</up-row>
|
||||
|
||||
</view>
|
||||
|
||||
</up-popup>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
|
@ -260,18 +227,22 @@
|
|||
|
||||
const userInfo = useUserStore().userInfo;
|
||||
const shop_Info = ref({})
|
||||
|
||||
|
||||
// 用户选择的门店信息
|
||||
let STORE_INFO = uni.getStorageSync('STORE_INFO');
|
||||
if (STORE_INFO){
|
||||
console.log(STORE_INFO)
|
||||
if (STORE_INFO) {
|
||||
shop_Info.value = JSON.parse(STORE_INFO)
|
||||
} else {
|
||||
uni.$u.toast('获取门店信息失败,请在首页选择门店')
|
||||
}
|
||||
|
||||
const cartStore = useCartStore();
|
||||
const reservation_time = ref('')
|
||||
const is_storage = ref(0)
|
||||
const LocationShow = ref(false)
|
||||
|
||||
const timeShow = ref(false)
|
||||
const timeContent = ref('')
|
||||
const formData = ref({
|
||||
remark: ""
|
||||
})
|
||||
|
@ -413,6 +384,10 @@
|
|||
cartList.value = res.data.cart_list;
|
||||
orderInfo.value = res.data.order;
|
||||
shop_Info.value = res.data.shopInfo || {}
|
||||
if (res.data.alert != '') {
|
||||
timeShow.value = true
|
||||
timeContent.value = res.data.alert
|
||||
}
|
||||
checkInventoryApi({
|
||||
cart_id: cartStore.cartList,
|
||||
store_id: store_id || res.data.shopInfo.id
|
||||
|
@ -425,24 +400,6 @@
|
|||
})
|
||||
}
|
||||
|
||||
|
||||
uni.$on('settle', function(data) {
|
||||
let datas = JSON.parse(data)
|
||||
shop_Info.value = datas
|
||||
console.log(datas)
|
||||
checkInventoryApi({
|
||||
cart_id: cartStore.cartList,
|
||||
store_id: datas.id
|
||||
}).then(res => {
|
||||
reservation.value = res.data.reservation
|
||||
})
|
||||
checkOrder(datas.id)
|
||||
// formData.store_id = datas.id
|
||||
// formData.store_name = datas.name
|
||||
})
|
||||
|
||||
|
||||
|
||||
// const checkOrderA
|
||||
const pay_type = ref('7');
|
||||
|
||||
|
@ -560,98 +517,18 @@
|
|||
}
|
||||
|
||||
onLoad(options => {
|
||||
// if (uni.getStorageSync('location')) {
|
||||
// try {
|
||||
// location = JSON.parse(uni.getStorageSync('location'))
|
||||
// checkOrder();
|
||||
// } catch (e) {
|
||||
// getLocation()
|
||||
// }
|
||||
// } else {
|
||||
getLocation()
|
||||
// }
|
||||
checkOrder(shop_Info.value.id);
|
||||
|
||||
})
|
||||
|
||||
const getLocation = () => {
|
||||
// #ifdef H5
|
||||
userLocationfalse()
|
||||
// #endif
|
||||
// #ifdef MP-WEIXIN
|
||||
uni.getSetting({
|
||||
success(res) {
|
||||
if (res.authSetting["scope.userLocation"] == false) {
|
||||
LocationShowOpen()
|
||||
} else {
|
||||
opensettings(true)
|
||||
}
|
||||
}
|
||||
})
|
||||
// #endif
|
||||
|
||||
}
|
||||
const LocationShowOpen = () => {
|
||||
LocationShow.value = true;
|
||||
}
|
||||
const userLocationfalse = () => {
|
||||
LocationShow.value = false;
|
||||
uni.$u.toast('获取位置当前失败,为你推荐当前门店')
|
||||
checkOrder(shop_Info.value.id);
|
||||
}
|
||||
const opensettings = (a = false) => {
|
||||
if (a == false) {
|
||||
uni.openSetting({
|
||||
success(res) {
|
||||
LocationShow.value = false;
|
||||
if (res.authSetting["scope.userLocation"] == true) {
|
||||
uni.authorize({
|
||||
scope: 'scope.userLocation',
|
||||
success() {
|
||||
uni.getLocation({
|
||||
type: "gcj02",
|
||||
success(res) {
|
||||
location.lat = res.latitude;
|
||||
location.long = res.longitude;
|
||||
uni.setStorageSync('location', JSON.stringify(
|
||||
location))
|
||||
checkOrder();
|
||||
},
|
||||
})
|
||||
},
|
||||
fail(e) {
|
||||
userLocationfalse()
|
||||
},
|
||||
})
|
||||
}
|
||||
},
|
||||
fail(e) {
|
||||
userLocationfalse()
|
||||
}
|
||||
});
|
||||
} else {
|
||||
uni.authorize({
|
||||
scope: 'scope.userLocation',
|
||||
success() {
|
||||
uni.getLocation({
|
||||
type: "gcj02",
|
||||
success(res) {
|
||||
location.lat = res.latitude;
|
||||
location.long = res.longitude;
|
||||
uni.setStorageSync('location', JSON.stringify(location))
|
||||
checkOrder();
|
||||
},
|
||||
})
|
||||
},
|
||||
fail(e) {
|
||||
userLocationfalse()
|
||||
},
|
||||
})
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
onShow(() => {
|
||||
getAddressList();
|
||||
})
|
||||
|
||||
uni.$on('settle', function(data) {
|
||||
let datas = JSON.parse(data)
|
||||
shop_Info.value = datas
|
||||
})
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
|
|
|
@ -0,0 +1,120 @@
|
|||
<template>
|
||||
<view style="background-color: #fff;">
|
||||
<up-row customStyle="margin-bottom: 10px;">
|
||||
<up-col span="6">
|
||||
<view style="padding: 30rpx 40rpx 0 40rpx;">
|
||||
<up-count-to :startVal="30" :endVal="data.total_price" fontSize="40" decimals="2"></up-count-to>
|
||||
<view style="padding: 20rpx;">累计铺货金额</view>
|
||||
</view>
|
||||
</up-col>
|
||||
<up-col span="6">
|
||||
<view style="padding: 30rpx 40rpx 0 40rpx;">
|
||||
<up-count-to :startVal="30" :endVal="data.pay_price" fontSize="40" decimals="2"></up-count-to>
|
||||
<view style="padding: 20rpx;">累计销售金额</view>
|
||||
</view>
|
||||
</up-col>
|
||||
</up-row>
|
||||
<up-row customStyle="margin-bottom: 10px;">
|
||||
<up-col span="6">
|
||||
<view style="padding: 30rpx 40rpx 0 40rpx;">
|
||||
<up-count-to :startVal="30" :endVal="data.expenditure" fontSize="40" decimals="2"></up-count-to>
|
||||
<view style="padding: 20rpx;">总支出</view>
|
||||
</view>
|
||||
</up-col>
|
||||
<up-col span="6">
|
||||
<view style="padding: 30rpx 40rpx 0 40rpx;">
|
||||
<up-count-to :startVal="30" :endVal="data.store_money" fontSize="40" decimals="2"></up-count-to>
|
||||
<view style="padding: 20rpx;">利润</view>
|
||||
</view>
|
||||
</up-col>
|
||||
</up-row>
|
||||
<view>
|
||||
<span style="font-size: 20px;padding: 10rpx;">支出明细</span>
|
||||
<up-divider></up-divider>
|
||||
</view>
|
||||
<qiun-data-charts type="column" :opts="opts" :chartData="chartData" />
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script setup="ts">
|
||||
import {
|
||||
ref
|
||||
} from 'vue';
|
||||
import {
|
||||
store_statistics,
|
||||
} from "@/api/store.js"
|
||||
const data = ref({
|
||||
total_price: 0,
|
||||
pay_price: 0,
|
||||
store_money:0,
|
||||
commission: 0,
|
||||
bond: 0,
|
||||
village: 0,
|
||||
vip: 0,
|
||||
brigade: 0,
|
||||
attrition: 0
|
||||
})
|
||||
const getLists = () => {
|
||||
store_statistics().then(res => {
|
||||
data.value = res.data
|
||||
chartData.value.series=res.data.list
|
||||
|
||||
})
|
||||
}
|
||||
getLists()
|
||||
const opts = ref({
|
||||
color: ["#1890FF", "#91CB74", "#FAC858", "#EE6666", "#73C0DE", "#3CA272", "#FC8452", "#9A60B4", "#ea7ccc"],
|
||||
padding: [15, 15, 0, 5],
|
||||
enableScroll: false,
|
||||
legend: {},
|
||||
xAxis: {
|
||||
disableGrid: true
|
||||
},
|
||||
yAxis: {
|
||||
data: [{
|
||||
min: 0
|
||||
}]
|
||||
},
|
||||
extra: {
|
||||
column: {
|
||||
type: "group",
|
||||
seriesGap:30,
|
||||
width: 30,
|
||||
activeBgColor: "#000000",
|
||||
activeBgOpacity: 0.08
|
||||
}
|
||||
}
|
||||
})
|
||||
const chartData = ref({
|
||||
categories: [""],
|
||||
series: [{
|
||||
name: "手续费",
|
||||
data: [0]
|
||||
},
|
||||
{
|
||||
name: "保证金",
|
||||
data: [0]
|
||||
},
|
||||
{
|
||||
name: "损耗金",
|
||||
data: [0]
|
||||
},
|
||||
{
|
||||
name: "村长",
|
||||
data: [0]
|
||||
},
|
||||
{
|
||||
name: "队长",
|
||||
data: [0]
|
||||
},
|
||||
{
|
||||
name: "厨师",
|
||||
data: [0]
|
||||
}
|
||||
]
|
||||
})
|
||||
</script>
|
||||
|
||||
<style>
|
||||
|
||||
</style>
|
|
@ -0,0 +1,176 @@
|
|||
<template>
|
||||
<view
|
||||
style="--view-theme: rgb(32, 177, 40);--view-priceColor:#FF7600;--view-minorColor:rgba(108, 198, 94, 0.5);--view-minorColorT:rgba(66, 202, 77, 0.1);--view-bntColor:#FE960F;--view-gradient:#4DEA4D">
|
||||
<!-- <view class='cash-withdrawal'>
|
||||
<view class="accountTitle">
|
||||
<view :style="{height:getHeight.barTop+'px'}"></view>
|
||||
<view class="sysTitle acea-row row-center-wrapper" :style="{height:getHeight.barHeight+'px'}">
|
||||
<text class="iconfont icon-ic_leftarrow" @click="goarrow"></text>
|
||||
</view>
|
||||
</view>
|
||||
<view :style="{height:(getHeight.barTop+getHeight.barHeight)+'px'}"></view>
|
||||
<view class="header">
|
||||
<view class="headerCon">
|
||||
<view class="money">000</view>
|
||||
<view>可提现金额</view>
|
||||
</view>
|
||||
</view>
|
||||
</view> -->
|
||||
<view class="content">
|
||||
|
||||
<up-transition :show="true" mode="slide-left">
|
||||
<view v-if="goodsList1.length>0">
|
||||
<navigator :url="item.url" hover-class="navigator-hover" class="card" v-for="(item,index) in goodsList1" :key='index'>
|
||||
<view class="card-content">
|
||||
<view class="card-content-r">
|
||||
<view class="title ellipsis">
|
||||
{{item.name}}
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</navigator>
|
||||
</view>
|
||||
<up-empty @click='test2' v-else mode="data" icon="http://cdn.uviewui.com/uview/empty/data.png">
|
||||
</up-empty>
|
||||
</up-transition>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import {
|
||||
ref,
|
||||
reactive
|
||||
} from 'vue';
|
||||
import {
|
||||
onLoad,
|
||||
onShow
|
||||
} from '@dcloudio/uni-app';
|
||||
import {
|
||||
menuList
|
||||
} from "@/api/store"
|
||||
const goodsList1 = ref([])
|
||||
const getGoodsList = async () => {
|
||||
let res = await menuList({})
|
||||
goodsList1.value = res.data.menu
|
||||
}
|
||||
getGoodsList()
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
.cash-withdrawal {
|
||||
.accountTitle {
|
||||
background: linear-gradient(90deg, var(--view-theme) 0%, var(--view-gradient) 100%);
|
||||
position: fixed;
|
||||
left: 0;
|
||||
top: 0;
|
||||
width: 100%;
|
||||
z-index: 99;
|
||||
|
||||
.sysTitle {
|
||||
width: 100%;
|
||||
position: relative;
|
||||
font-weight: 500;
|
||||
color: #fff;
|
||||
font-size: 30rpx;
|
||||
|
||||
.iconfont {
|
||||
position: absolute;
|
||||
font-size: 36rpx;
|
||||
left: 11rpx;
|
||||
width: 60rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.header {
|
||||
width: 100%;
|
||||
height: 310rpx;
|
||||
background: linear-gradient(90deg, var(--view-theme) 0%, var(--view-gradient) 100%);
|
||||
font-size: 30rpx;
|
||||
font-weight: 400;
|
||||
color: #F5F5F5;
|
||||
text-align: center;
|
||||
padding-top: 88rpx;
|
||||
position: relative;
|
||||
|
||||
|
||||
|
||||
.headerCon {
|
||||
background-image: url('../static/cashBg.png');
|
||||
background-repeat: no-repeat;
|
||||
background-size: 100% 100%;
|
||||
width: 100%;
|
||||
height: 278rpx;
|
||||
}
|
||||
|
||||
.money {
|
||||
font-size: 76rpx;
|
||||
font-weight: 600;
|
||||
color: #FFFFFF;
|
||||
font-family: 'Regular';
|
||||
margin-bottom: 16rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.content {
|
||||
padding: 20rpx;
|
||||
padding-bottom: 150rpx;
|
||||
|
||||
.card {
|
||||
width: 350rpx;
|
||||
margin: 2rpx;
|
||||
padding: 92rpx;
|
||||
box-sizing: border-box;
|
||||
background-color: white;
|
||||
display: inline-block;
|
||||
|
||||
|
||||
|
||||
.card-content {
|
||||
display: flex;
|
||||
position: relative;
|
||||
|
||||
.card-content-l {
|
||||
margin-right: 20rpx;
|
||||
position: relative;
|
||||
|
||||
.status {
|
||||
width: 152rpx;
|
||||
height: 40rpx;
|
||||
background-color: rgba(0, 0, 0, .3);
|
||||
text-align: center;
|
||||
color: white;
|
||||
font-size: 24rpx;
|
||||
line-height: 40rpx;
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.card-content-r {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
|
||||
.title {
|
||||
font-size: 30rpx;
|
||||
width: 500rpx;
|
||||
}
|
||||
|
||||
.need {
|
||||
color: #777777;
|
||||
font-size: 24rpx;
|
||||
}
|
||||
|
||||
.ipt {
|
||||
display: flex;
|
||||
height: 56rpx;
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
|
@ -0,0 +1,959 @@
|
|||
<style lang="scss" scoped>
|
||||
.share-btn {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
position: fixed;
|
||||
width: 60rpx;
|
||||
z-index: 20;
|
||||
|
||||
::v-deep.u-button {
|
||||
border: 0;
|
||||
border-color: transparent;
|
||||
|
||||
.u-icon__icon {
|
||||
font-size: 60rpx !important;
|
||||
color: #030303;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
<template>
|
||||
<view class="content">
|
||||
<view class="navbar">
|
||||
<view style="width: 100%;">
|
||||
<up-search placeholder="请输入商品" @search="searchKeyword" @clear="searchKeyword" v-model="keyword"
|
||||
:showAction="false"></up-search>
|
||||
</view>
|
||||
</view>
|
||||
<view class='headScoll' ref='headscroll' :style="{ height: isScroll ? '0' : '170rpx' }">
|
||||
<scroll-view class="head-view" scroll-x @scrolltolower="getgoodClassList(0)">
|
||||
<view class="list">
|
||||
<view class="item" :class="{ 'item-active': topActive === item.id }"
|
||||
v-for="(item, index) in goodClassList" :key="index" @click="changeOne(item, index)">
|
||||
<view class="c-img"><up-image height="100rpx" width="100rpx" :src="item.pic"></up-image></view>
|
||||
<view class="c-text u-line-1">{{ item.name }}</view>
|
||||
</view>
|
||||
<view class="item" style="width: 80rpx;height: 20rpx;">
|
||||
</view>
|
||||
</view>
|
||||
</scroll-view>
|
||||
<view class="r-btn" @click="show = 1">
|
||||
<view>全</view>
|
||||
<view>部</view>
|
||||
<up-icon name="list"></up-icon>
|
||||
</view>
|
||||
</view>
|
||||
<viewPopup nav v-if="show === 1" @close="show = 0">
|
||||
<view class="cateOne">
|
||||
<view class="head-title">全部分类</view>
|
||||
<scroll-view scroll-y style="height: 600rpx;">
|
||||
<view class="list">
|
||||
<view class="item" :class="{ 'item-active': topActive === item.id }"
|
||||
v-for="(item, index) in goodClassList" :key="index" @click="changeOne(item, index)">
|
||||
<view class="c-img"><up-image height="100rpx" width="100rpx" :src="item.pic"></up-image>
|
||||
</view>
|
||||
<view class="c-text u-line-1">{{ item.name }}</view>
|
||||
</view>
|
||||
</view>
|
||||
</scroll-view>
|
||||
</view>
|
||||
</viewPopup>
|
||||
<view class="scroll-box">
|
||||
<scroll-view class="left" scroll-y @scrolltolower="getgoodClassList(topActive)">
|
||||
<view class="item u-line-1" :class="{ 'item-active': leftActive === item.id }"
|
||||
v-for="(item, index) in goodClassTow" :key="index" @click="changeTwo(item, index)">{{ item.name }}
|
||||
</view>
|
||||
<view style="width: 100%;height: 450rpx;"></view>
|
||||
</scroll-view>
|
||||
<view class="right">
|
||||
<view class="classify">
|
||||
<scroll-view style="height: 90rpx;" scroll-x @scrolltolower="getgoodClassList(leftActive)">
|
||||
<view class="classify-list">
|
||||
<view class="classify-list-item u-line-1"
|
||||
:class="{ 'item-active': rightActive === item.id }"
|
||||
v-for="(item, index) in goodClassThree" :key="index" @click="changeThree(item, index)">
|
||||
{{ item.name }}
|
||||
</view>
|
||||
<view style="width: 70rpx;flex-shrink: 0;"></view>
|
||||
</view>
|
||||
</scroll-view>
|
||||
<view class="done" @click="show = 2">
|
||||
<up-icon name="arrow-down"></up-icon>
|
||||
</view>
|
||||
<!-- <view class="order-by">
|
||||
<view class="item" :class="{ 'order-active': where.order == '' }" @click="changeOrder('')">综合
|
||||
</view>
|
||||
<view class="item" style="display: flex;align-items: center;"
|
||||
:class="{ 'order-active': where.order == 'desc' || where.order == 'asc' }"
|
||||
@click="changeOrder(where.order == 'asc' ? 'desc' : 'asc')">
|
||||
价格
|
||||
<view style="color: black;">
|
||||
<up-icon name="arrow-up-fill" :color="where.order=='asc'?'#20b128':'' "
|
||||
size="8"></up-icon>
|
||||
<up-icon name="arrow-down-fill" :color="where.order=='desc'?'#20b128':'' "
|
||||
size="8"></up-icon>
|
||||
</view>
|
||||
</view>
|
||||
<view class="item" :class="{ 'order-active': where.order == 'sales' }"
|
||||
@click="changeOrder('sales')">销量
|
||||
</view>
|
||||
</view> -->
|
||||
</view>
|
||||
<viewPopup v-if="show === 2" @close="show = 0">
|
||||
<view class="cateOne">
|
||||
<scroll-view scroll-y style="height: 230rpx;" @scrolltolower="getgoodClassList(leftActive)">
|
||||
<view class="classify-list">
|
||||
<view class="classify-list-item u-line-1"
|
||||
:class="{ 'item-active': rightActive === item.id }"
|
||||
v-for="(item, index) in goodClassThree" :key="index"
|
||||
@click="changeThree(item, index)">
|
||||
{{ item.name }}
|
||||
</view>
|
||||
</view>
|
||||
</scroll-view>
|
||||
</view>
|
||||
</viewPopup>
|
||||
<scroll-view class="list" id='drag_area' style="overscroll-behavior: none;" @scroll="hideHeadView"
|
||||
scroll-y @scrolltolower="loadMoreGood">
|
||||
<view class="shop-item" v-for="(item, index) in goodList" :key="item.id">
|
||||
<view class="shop-img"
|
||||
:style="{ backgroundImage: `url(${item.image}?x-oss-process=image/format,webp)` }">
|
||||
</view>
|
||||
|
||||
<view class="shop-content">
|
||||
<view class="goods-name" style="font-size: 28rpx;color: #060606;">
|
||||
{{ item.store_name }}
|
||||
</view>
|
||||
<view class="shop-content-li" style="justify-content: space-between;"
|
||||
v-if="item.store_info">
|
||||
<view style="display: flex;">
|
||||
<view class="shop-content-li-l">规格</view>
|
||||
<view class="shop-content-li-r">{{ item.store_info }}</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
<view class="shop-content-li">
|
||||
<view style="margin-right: 60rpx;">
|
||||
<span class="shop-content-li-l">
|
||||
铺货量
|
||||
</span>
|
||||
<span class="shop-content-li-r" style="color:#FC452F ;"><text
|
||||
style="font-size: 30rpx;">{{item.distribution_nums}}</text>
|
||||
</span>
|
||||
</view>
|
||||
<view >
|
||||
|
||||
<span class="shop-content-li-l">
|
||||
销售量
|
||||
</span>
|
||||
<span class="shop-content-li-r" style="color:#FC452F ;"><text
|
||||
style="font-size: 30rpx;">{{item.sales}}</text>
|
||||
</span>
|
||||
</view>
|
||||
</view>
|
||||
<view class="shop-content-li">
|
||||
<view class="shop-content-li-l">
|
||||
库存
|
||||
</view>
|
||||
<view class="shop-content-li-r" style="color:#FC452F ;"><text
|
||||
style="font-size: 30rpx;">{{item.stock}}</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="shop-content-li">
|
||||
<view class="shop-content-li-l">
|
||||
价值
|
||||
</view>
|
||||
<view class="shop-content-li-r" style="color:#FC452F ;">¥<text
|
||||
style="font-size: 30rpx;">{{item.total_price}}</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view style="width: 100%;height: 470rpx;"></view>
|
||||
</scroll-view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import {
|
||||
onLoad,
|
||||
onShow,
|
||||
onShareAppMessage,
|
||||
} from "@dcloudio/uni-app"
|
||||
import {
|
||||
reactive,
|
||||
ref,
|
||||
onMounted,
|
||||
} from "vue"
|
||||
import {
|
||||
goodListApi,
|
||||
BranchProductListsApi,
|
||||
goodClassListApi
|
||||
} from "@/api/good.js"
|
||||
|
||||
import viewPopup from "@/components/viewPopup.vue"
|
||||
import {
|
||||
getCurrentInstance
|
||||
} from 'vue';
|
||||
import {
|
||||
shopDetailApi
|
||||
} from "@/api/multipleShop.js";
|
||||
|
||||
const priceKey = reactive({
|
||||
off_activity: "",
|
||||
op_price: "",
|
||||
price: ""
|
||||
})
|
||||
|
||||
const showModal = ref(false)
|
||||
const navgo = (url) => {
|
||||
showModal.value &&= false
|
||||
uni.navigateTo({
|
||||
url
|
||||
})
|
||||
}
|
||||
|
||||
/*商品列表滚动隐藏头部导航 */
|
||||
const targetHeight = ref(0)
|
||||
let scoHeight = 0
|
||||
const isScroll = ref(false)
|
||||
let lastScollTop = 0
|
||||
const hideHeadView = (e) => {
|
||||
if (e.detail.scrollTop < 100) return
|
||||
if (e.detail.scrollTop <= 0 || e.detail.scrollTop > targetHeight.value)
|
||||
return
|
||||
isScroll.value = e.detail.scrollTop > lastScollTop
|
||||
lastScollTop = e.detail.scrollTop
|
||||
}
|
||||
|
||||
/*商品列表滚动隐藏头部导航结束 */
|
||||
const show = ref(0);
|
||||
const topActive = ref(0);
|
||||
const changeOne = async (item, index) => {
|
||||
where.value.top_cate_id = item.id
|
||||
delete where.value.two_cate_id // 删除二级分类的id, 因为切换一级分类时, 二级分类的id应该为空, 否则会获取到错误的商品列表数据
|
||||
topActive.value = item.id;
|
||||
show.value = 0;
|
||||
goodClassTow.value = item?.children || [];
|
||||
goodClassThree.value = goodClassTow.value[0]?.children || [];
|
||||
leftActive.value = goodClassTow.value[0]?.id || '';
|
||||
rightActive.value = goodClassThree.value[0]?.id || '';
|
||||
getGoodList();
|
||||
if (!item.isLoading && item.id) getgoodClassList(topActive.value, 2); // 判断是否加载过数据, 加载过则不进行加载,节约资源
|
||||
}
|
||||
|
||||
const leftActive = ref(0);
|
||||
const changeTwo = (item, index) => {
|
||||
console.log(item)
|
||||
where.value.two_cate_id = item.id
|
||||
isScroll.value = false;
|
||||
getWXDom(instance)
|
||||
leftActive.value = item.id;
|
||||
show.value = 0;
|
||||
goodClassThree.value = item?.children || [];
|
||||
rightActive.value = goodClassThree.value[0]?.id || '';
|
||||
getGoodList();
|
||||
if (!item.isLoading && item.id) getgoodClassList(leftActive.value, 3); // 判断是否加载过数据, 加载过则不进行加载,节约资源
|
||||
}
|
||||
|
||||
const rightActive = ref(0);
|
||||
const changeThree = (item, index) => {
|
||||
rightActive.value = item.id;
|
||||
show.value = 0;
|
||||
getGoodList();
|
||||
}
|
||||
|
||||
|
||||
|
||||
const keyword = ref('');
|
||||
|
||||
const searchKeyword = () => {
|
||||
where.value.name = keyword.value;
|
||||
where.value.store_name = keyword.value;
|
||||
getGoodList();
|
||||
}
|
||||
|
||||
const changeOrder = (order) => {
|
||||
switch (order) {
|
||||
case 'asc':
|
||||
where.value.field = 'price'
|
||||
break;
|
||||
case 'desc':
|
||||
where.value.field = 'price'
|
||||
break;
|
||||
case 'sales':
|
||||
where.value.field = 'sales'
|
||||
break;
|
||||
default:
|
||||
where.value.field = ''
|
||||
}
|
||||
where.value.order = order;
|
||||
getGoodList();
|
||||
}
|
||||
|
||||
const where = ref({
|
||||
page_no: 1,
|
||||
page_size: 15,
|
||||
name: '',
|
||||
order: '',
|
||||
store_name: '',
|
||||
store_id: '',
|
||||
field: "",
|
||||
})
|
||||
|
||||
const loading = ref(true);
|
||||
const goodList = ref([]);
|
||||
const getGoodList = (loadmore = false) => {
|
||||
loading.value = true;
|
||||
let class_id = rightActive.value || leftActive.value || topActive.value || '';
|
||||
let class_all = '';
|
||||
// 若分类没有选中时,则直接查询上一级分类
|
||||
if (rightActive.value == '') class_all = leftActive.value;
|
||||
if (leftActive.value == '') class_all = topActive.value;
|
||||
if (topActive.value == '') class_all = '';
|
||||
if (class_all) class_id = ""; //只能带其中一个
|
||||
if (loadmore) where.value.page_no++;
|
||||
else where.value.page_no = 1;
|
||||
let data = {
|
||||
...where.value,
|
||||
class_all: class_all,
|
||||
class: class_id,
|
||||
cate_id: class_id,
|
||||
source: 4,
|
||||
// top_cate_id: "",
|
||||
// two_cate_id: ""
|
||||
}
|
||||
BranchProductListsApi(data).then(res => {
|
||||
for (let key in res.data.extend) {
|
||||
priceKey[key] = res.data.extend[key]
|
||||
}
|
||||
uni.setStorageSync("PRICE_KEY", JSON.stringify(priceKey))
|
||||
if (loadmore) goodList.value.push(...res.data.lists);
|
||||
else goodList.value = res.data.lists;
|
||||
})
|
||||
}
|
||||
|
||||
// 商品列表触底
|
||||
const loadMoreGood = () => {
|
||||
|
||||
getWXDom(instance)
|
||||
getGoodList(true);
|
||||
}
|
||||
|
||||
const goodClassList = ref([]); // 一级分类
|
||||
const goodClassTow = ref([]); // 二级分类
|
||||
const goodClassThree = ref([]); // 三级分类
|
||||
const classMap = new Map();
|
||||
const getgoodClassList = (pid = 0, three = 1) => {
|
||||
let page_no = classMap.get(pid) || 1;
|
||||
goodClassListApi({
|
||||
pid: pid,
|
||||
page_no: page_no,
|
||||
page_size: 30,
|
||||
level: three,
|
||||
source: 4 //来源
|
||||
}).then(res => {
|
||||
if (pid == 0) { // 加载一级分类时设置全部分类
|
||||
if (!res.data?.lists?.length) return;
|
||||
res.data?.lists?.unshift({
|
||||
id: "",
|
||||
name: "全部",
|
||||
pic: "https://lihai001.oss-cn-chengdu.aliyuncs.com/def/35adb202404271727457954.png",
|
||||
children: []
|
||||
})
|
||||
res.data.lists = res.data.lists.map(item => {
|
||||
if (!item.children) item.children = [];
|
||||
item.children?.unshift({
|
||||
id: "",
|
||||
pid: item.id, //子分类的全部选项其实就是它本身
|
||||
name: "全部",
|
||||
})
|
||||
item.children = item.children.map(t => {
|
||||
if (!t.children) t.children = [];
|
||||
t.children?.unshift({
|
||||
id: "",
|
||||
pid: t.id,
|
||||
name: "全部",
|
||||
})
|
||||
return t;
|
||||
})
|
||||
return item;
|
||||
})
|
||||
// 给所有子级分配
|
||||
goodClassList.value = [...goodClassList.value, ...res.data?.lists];
|
||||
goodClassTow.value = goodClassList.value[0]?.children || [];
|
||||
goodClassThree.value = goodClassTow.value[0]?.children || [];
|
||||
topActive.value = goodClassList.value[0]?.id;
|
||||
leftActive.value = goodClassTow.value[0]?.id;
|
||||
rightActive.value = goodClassThree.value[0]?.id;
|
||||
} else {
|
||||
let flag = 1;
|
||||
goodClassList.value.forEach(item => { // 给相应的一级分类添加子菜单
|
||||
if (item.id == pid) {
|
||||
if (!item.children) {
|
||||
item.children = [];
|
||||
item.children.unshift({
|
||||
id: "",
|
||||
pid: item.id,
|
||||
name: "全部",
|
||||
})
|
||||
}
|
||||
item.children = [...item.children, ...res.data.lists];
|
||||
item.isLoading = true;
|
||||
goodClassTow.value = item.children;
|
||||
flag = 0;
|
||||
}
|
||||
})
|
||||
if (flag) goodClassTow.value.forEach(item => { //给响应的二级子分类添加菜单
|
||||
if (item.id == pid) {
|
||||
if (!item.children) {
|
||||
item.children = [];
|
||||
item.children.unshift({
|
||||
id: "",
|
||||
pid: item.id,
|
||||
name: "全部",
|
||||
})
|
||||
}
|
||||
item.children = [...item.children, ...res.data.lists];
|
||||
item.isLoading = true;
|
||||
goodClassThree.value = item.children;
|
||||
}
|
||||
})
|
||||
}
|
||||
page_no++;
|
||||
classMap.set(pid, page_no);
|
||||
})
|
||||
}
|
||||
|
||||
// 胶囊布局
|
||||
const btns = ref({
|
||||
height: 0,
|
||||
top: 0,
|
||||
bottom: 0,
|
||||
left: 0
|
||||
});
|
||||
|
||||
|
||||
onLoad(async (opt) => {
|
||||
getAll()
|
||||
|
||||
// #ifndef H5
|
||||
// 胶囊布局信息
|
||||
btns.value = uni.getMenuButtonBoundingClientRect();
|
||||
// #endif
|
||||
})
|
||||
|
||||
const getAll = () => {
|
||||
getgoodClassList(0)
|
||||
getGoodList()
|
||||
}
|
||||
|
||||
|
||||
let instance; // 获取组件实例
|
||||
const getWXDom = () => {
|
||||
let query = uni.createSelectorQuery().in(instance).select("#drag_area");
|
||||
query.fields({
|
||||
size: true,
|
||||
scrollOffset: true,
|
||||
},
|
||||
(data) => {
|
||||
scoHeight = data.scrollHeight
|
||||
targetHeight.value = data.scrollHeight - data.height
|
||||
}
|
||||
).exec();
|
||||
}
|
||||
|
||||
onMounted(() => {
|
||||
instance = getCurrentInstance(); // 获取组件实例
|
||||
setTimeout(() => {
|
||||
getWXDom(instance)
|
||||
}, 500)
|
||||
})
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
.content {
|
||||
background-color: #fff;
|
||||
}
|
||||
|
||||
.navbar {
|
||||
padding: 20rpx;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
font-size: 22rpx;
|
||||
color: #777;
|
||||
// margin-top: 40rpx;
|
||||
|
||||
.nav-item {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
position: relative;
|
||||
|
||||
image {
|
||||
height: 40rpx;
|
||||
width: 40rpx;
|
||||
}
|
||||
|
||||
.badge {
|
||||
position: absolute;
|
||||
top: -10rpx;
|
||||
right: 10rpx;
|
||||
background-color: #FF0000;
|
||||
color: #FFFFFF;
|
||||
text-align: center;
|
||||
width: 30rpx;
|
||||
height: 30rpx;
|
||||
border-radius: 30rpx;
|
||||
font-size: 18rpx;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
.head-view {
|
||||
background-color: #fff;
|
||||
height: 180rpx;
|
||||
width: 750rpx;
|
||||
|
||||
.list {
|
||||
height: 100%;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
padding: 0 20rpx;
|
||||
font-size: 22rpx;
|
||||
|
||||
.item {
|
||||
width: 120rpx;
|
||||
flex-shrink: 0;
|
||||
margin-right: 20rpx;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
|
||||
.c-img {
|
||||
height: 100rpx;
|
||||
width: 100rpx;
|
||||
flex-shrink: 0;
|
||||
border-radius: 50%;
|
||||
border: 2px solid transparent;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.c-text {
|
||||
width: 100%;
|
||||
text-align: center;
|
||||
box-sizing: border-box;
|
||||
padding: 2rpx 4rpx 3rpx 4rpx;
|
||||
border-radius: 50rpx;
|
||||
margin-top: 5rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.item-active {
|
||||
.c-img {
|
||||
border: 2px solid #20b128;
|
||||
}
|
||||
|
||||
.c-text {
|
||||
background-color: #20b128;
|
||||
color: #fff;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.r-btn {
|
||||
position: absolute;
|
||||
right: 0;
|
||||
top: 0;
|
||||
height: 100%;
|
||||
width: 60rpx;
|
||||
font-size: 24rpx;
|
||||
background-color: #fff;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
box-shadow: -10rpx 0 60rpx 1rpx rgba(0, 0, 0, 0.3);
|
||||
}
|
||||
|
||||
.cateOne {
|
||||
background-color: #fff;
|
||||
|
||||
.head-title {
|
||||
color: #666666;
|
||||
font-size: 30rpx;
|
||||
height: 80rpx;
|
||||
line-height: 80rpx;
|
||||
padding-left: 30rpx;
|
||||
}
|
||||
|
||||
.list {
|
||||
padding: 20rpx 20rpx;
|
||||
font-size: 22rpx;
|
||||
display: grid;
|
||||
grid-template-columns: repeat(5, 1fr);
|
||||
justify-content: center;
|
||||
grid-gap: 20rpx;
|
||||
|
||||
|
||||
.item {
|
||||
width: 120rpx;
|
||||
margin: 0 auto;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
|
||||
.c-img {
|
||||
height: 100rpx;
|
||||
width: 100rpx;
|
||||
flex-shrink: 0;
|
||||
border-radius: 50%;
|
||||
border: 2px solid transparent;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.c-text {
|
||||
width: 100%;
|
||||
text-align: center;
|
||||
box-sizing: border-box;
|
||||
padding: 2rpx 4rpx 3rpx 4rpx;
|
||||
border-radius: 50rpx;
|
||||
margin-top: 5rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.item-active {
|
||||
.c-img {
|
||||
border: 2px solid #20b128;
|
||||
}
|
||||
|
||||
.c-text {
|
||||
background-color: #20b128;
|
||||
color: #fff;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.classify-list {
|
||||
padding: 20rpx 30rpx;
|
||||
font-size: 22rpx;
|
||||
display: grid;
|
||||
grid-template-columns: repeat(3, 1fr);
|
||||
justify-content: center;
|
||||
grid-gap: 20rpx;
|
||||
|
||||
.classify-list-item {
|
||||
flex-shrink: 0;
|
||||
text-align: center;
|
||||
width: 150rpx;
|
||||
height: 42rpx;
|
||||
line-height: 42rpx;
|
||||
background: #F6F6F6;
|
||||
border-radius: 22rpx 22rpx 22rpx 22rpx;
|
||||
border: 1rpx solid transparent;
|
||||
}
|
||||
|
||||
.item-active {
|
||||
border: 1rpx solid #20b128;
|
||||
color: #20b128;
|
||||
background-color: rgba(#20b128, 0.1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.scroll-box {
|
||||
// background-color: red;
|
||||
display: flex;
|
||||
|
||||
.left {
|
||||
height: calc(100vh - var(--window-top) - var(--window-bottom) - 300rpx);
|
||||
/* #ifdef H5 */
|
||||
height: calc(100vh - 44px - 100rpx);
|
||||
/* #endif */
|
||||
width: 170rpx;
|
||||
box-sizing: border-box;
|
||||
background-color: #f6f6f6;
|
||||
font-size: 24rpx;
|
||||
|
||||
.item {
|
||||
height: 96rpx;
|
||||
line-height: 96rpx;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.item-active {
|
||||
background-color: #fff;
|
||||
position: relative;
|
||||
color: #20b128;
|
||||
|
||||
&::before {
|
||||
content: '';
|
||||
background-color: #20b128;
|
||||
width: 6rpx;
|
||||
height: 48rpx;
|
||||
border-radius: 10rpx;
|
||||
position: absolute;
|
||||
left: 0;
|
||||
top: 50%;
|
||||
transform: translate(0, -50%);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.right {
|
||||
height: calc(100vh - var(--window-top) - 300rpx);
|
||||
/* #ifdef H5 */
|
||||
height: calc(100vh - 96px + 20rpx);
|
||||
/* #endif */
|
||||
width: 580rpx;
|
||||
box-sizing: border-box;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
|
||||
.classify {
|
||||
height: 150rpx;
|
||||
background-color: #fff;
|
||||
border-bottom: 1rpx solid #f6f6f6;
|
||||
position: relative;
|
||||
font-size: 24rpx;
|
||||
|
||||
.classify-list {
|
||||
display: flex;
|
||||
padding: 20rpx;
|
||||
|
||||
.classify-list-item {
|
||||
flex-shrink: 0;
|
||||
text-align: center;
|
||||
width: 108rpx;
|
||||
height: 42rpx;
|
||||
line-height: 42rpx;
|
||||
background: #F6F6F6;
|
||||
border-radius: 22rpx 22rpx 22rpx 22rpx;
|
||||
margin-right: 20rpx;
|
||||
border: 1rpx solid transparent;
|
||||
}
|
||||
|
||||
.item-active {
|
||||
border: 1rpx solid #20b128;
|
||||
color: #20b128;
|
||||
background-color: rgba(#20b128, 0.1);
|
||||
}
|
||||
}
|
||||
|
||||
.done {
|
||||
height: 90rpx;
|
||||
width: 60rpx;
|
||||
position: absolute;
|
||||
top: 0;
|
||||
right: 0;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
background-color: #fff;
|
||||
}
|
||||
|
||||
.order-by {
|
||||
display: flex;
|
||||
justify-content: flex-end;
|
||||
align-items: center;
|
||||
|
||||
.item {
|
||||
padding-right: 20rpx;
|
||||
}
|
||||
|
||||
.order-active {
|
||||
color: #20b128;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.list {
|
||||
height: calc(100vh - var(--window-top) - 400rpx);
|
||||
/* #ifdef H5 */
|
||||
height: calc(100vh - 44px - 200rpx);
|
||||
|
||||
/* #endif */
|
||||
.shop-item {
|
||||
padding: 20rpx;
|
||||
border-bottom: 1rpx solid #f6f6f6;
|
||||
background-color: #fff;
|
||||
display: flex;
|
||||
|
||||
.shop-img {
|
||||
height: 164rpx;
|
||||
width: 164rpx;
|
||||
margin-right: 20rpx;
|
||||
border-radius: 14rpx;
|
||||
overflow: hidden;
|
||||
background-size: 100% 100%;
|
||||
// background-image: url();
|
||||
}
|
||||
|
||||
.shop-content {
|
||||
width: 380rpx;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-around;
|
||||
position: relative;
|
||||
|
||||
.shop-content-li {
|
||||
font-size: 22rpx;
|
||||
color: #333333;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
vertical-align: middle;
|
||||
|
||||
.line-through {
|
||||
text-decoration: line-through;
|
||||
}
|
||||
|
||||
.shop-content-li-l {
|
||||
font-size: 22rpx;
|
||||
width: 70rpx;
|
||||
text-align-last: justify;
|
||||
margin-right: 6rpx;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
.tag {
|
||||
font-size: 16rpx;
|
||||
color: #A17C3A;
|
||||
background-color: #F3E7C0;
|
||||
padding: 8rpx 4rpx;
|
||||
margin-left: 4rpx;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
}
|
||||
|
||||
.shopconetent-btn {
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
right: 0;
|
||||
}
|
||||
|
||||
// .icon {
|
||||
// background-image: url('https://lihai001.oss-cn-chengdu.aliyuncs.com/attach/3b653202406260957228679.png');
|
||||
// width: 17rpx;
|
||||
// height: 14rpx;
|
||||
// background-size: 100% 100%;
|
||||
// margin: 5rpx;
|
||||
// }
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.fiexd-btn-box {
|
||||
box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.1);
|
||||
height: 140rpx;
|
||||
height: calc(constant(safe-area-inset-bottom) + 140rpx);
|
||||
/* 适用于iOS设备 */
|
||||
height: calc(env(safe-area-inset-bottom) + 140rpx);
|
||||
/* 适用于Android设备 */
|
||||
padding-top: 40rpx;
|
||||
|
||||
.price-info {
|
||||
.row {
|
||||
display: flex;
|
||||
font-size: 26rpx;
|
||||
align-items: center;
|
||||
|
||||
&>view {
|
||||
margin-right: 15rpx;
|
||||
}
|
||||
|
||||
.price {
|
||||
color: #F55726;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.btn {
|
||||
width: 200rpx;
|
||||
}
|
||||
|
||||
.cart {
|
||||
position: absolute;
|
||||
top: -40rpx;
|
||||
left: 40rpx;
|
||||
|
||||
image {
|
||||
width: 80rpx;
|
||||
height: 80rpx;
|
||||
}
|
||||
|
||||
.badge {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
right: 0;
|
||||
background-color: #F55726;
|
||||
color: #fff;
|
||||
border-radius: 50%;
|
||||
width: 26rpx;
|
||||
height: 26rpx;
|
||||
text-align: center;
|
||||
line-height: 26rpx;
|
||||
font-size: 18rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.headScoll {
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
transition: 400ms;
|
||||
}
|
||||
|
||||
.store-info {
|
||||
margin: 0 0 20rpx 20rpx;
|
||||
margin-top: 20rpx;
|
||||
}
|
||||
|
||||
.warp {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.rect {
|
||||
width: 630rpx;
|
||||
height: 440rpx;
|
||||
background-image: url('https://lihai001.oss-cn-chengdu.aliyuncs.com/attach/9c70c202406261048431851.png');
|
||||
background-size: 100% 100%;
|
||||
box-sizing: border-box;
|
||||
text-align: center;
|
||||
// padding: 30rpx;
|
||||
padding: 50rpx 32rpx;
|
||||
|
||||
.rect-tit {
|
||||
text-align: center;
|
||||
font-size: 32rpx;
|
||||
color: #333333;
|
||||
margin-bottom: 60rpx;
|
||||
|
||||
}
|
||||
|
||||
.rect-contetn {
|
||||
font-size: 30rpx;
|
||||
color: #333333;
|
||||
}
|
||||
|
||||
.rect-btn {
|
||||
display: flex;
|
||||
margin-top: 50rpx;
|
||||
justify-content: space-around;
|
||||
}
|
||||
}
|
||||
</style>
|
|
@ -0,0 +1,320 @@
|
|||
## 2.5.0-20230101(2023-01-01)
|
||||
- 秋云图表组件 修改条件编译顺序,确保uniapp的cli方式的项目依赖不完整时可以正常显示
|
||||
- 秋云图表组件 恢复props属性directory的使用,以修复vue3项目中,开启echarts后,echarts目录识别错误的bug
|
||||
- uCharts.js 修复区域图、混合图只有一个数据时图表显示不正确的bug
|
||||
- uCharts.js 修复折线图、区域图中时间轴类别图表tooltip指示点显示不正确的bug
|
||||
- uCharts.js 修复x轴使用labelCount时,并且boundaryGap = 'justify' 并且关闭Y轴显示的时候,最后一个坐标值不显示的bug
|
||||
- uCharts.js 修复折线图只有一组数据时 ios16 渲染颜色不正确的bug
|
||||
- uCharts.js 修复玫瑰图半径显示不正确的bug
|
||||
- uCharts.js 柱状图、山峰图增加正负图功能,y轴网格如果需要显示0轴则由 min max 及 splitNumber 确定,后续版本优化自动显示0轴
|
||||
- uCharts.js 柱状图column增加 opts.extra.column.labelPosition,数据标签位置,有效值为 outside外部, insideTop内顶部, center内中间, bottom内底部
|
||||
- uCharts.js 雷达图radar增加 opts.extra.radar.labelShow,否显示各项标识文案是,默认true
|
||||
- uCharts.js 提示窗tooltip增加 opts.extra.tooltip.boxPadding,提示窗边框填充距离,默认3px
|
||||
- uCharts.js 提示窗tooltip增加 opts.extra.tooltip.fontSize,提示窗字体大小配置,默认13px
|
||||
- uCharts.js 提示窗tooltip增加 opts.extra.tooltip.lineHeight,提示窗文字行高,默认20px
|
||||
- uCharts.js 提示窗tooltip增加 opts.extra.tooltip.legendShow,是否显示左侧图例,默认true
|
||||
- uCharts.js 提示窗tooltip增加 opts.extra.tooltip.legendShape,图例形状,图例标识样式,有效值为 auto自动跟随图例, diamond◆, circle●, triangle▲, square■, rect▬, line-
|
||||
- uCharts.js 标记线markLine增加 opts.extra.markLine.labelFontSize,字体大小配置,默认13px
|
||||
- uCharts.js 标记线markLine增加 opts.extra.markLine.labelPadding,标签边框内填充距离,默认6px
|
||||
- uCharts.js 折线图line增加 opts.extra.line.linearType,渐变色类型,可选值 none关闭渐变色,custom 自定义渐变色。使用自定义渐变色时请赋值serie.linearColor作为颜色值
|
||||
- uCharts.js 折线图line增加 serie.linearColor,渐变色数组,格式为2维数组[起始位置,颜色值],例如[[0,'#0EE2F8'],[0.3,'#2BDCA8'],[0.6,'#1890FF'],[1,'#9A60B4']]
|
||||
- uCharts.js 折线图line增加 opts.extra.line.onShadow,是否开启折线阴影,开启后请赋值serie.setShadow阴影设置
|
||||
- uCharts.js 折线图line增加 serie.setShadow,阴影配置,格式为4位数组:[offsetX,offsetY,blur,color]
|
||||
- uCharts.js 折线图line增加 opts.extra.line.animation,动画效果方向,可选值为vertical 垂直动画效果,horizontal 水平动画效果
|
||||
- uCharts.js X轴xAxis增加 opts.xAxis.lineHeight,X轴字体行高,默认20px
|
||||
- uCharts.js X轴xAxis增加 opts.xAxis.marginTop,X轴文字距离轴线的距离,默认0px
|
||||
- uCharts.js X轴xAxis增加 opts.xAxis.title,当前X轴标题
|
||||
- uCharts.js X轴xAxis增加 opts.xAxis.titleFontSize,标题字体大小,默认13px
|
||||
- uCharts.js X轴xAxis增加 opts.xAxis.titleOffsetY,标题纵向偏移距离,负数为向上偏移,正数向下偏移
|
||||
- uCharts.js X轴xAxis增加 opts.xAxis.titleOffsetX,标题横向偏移距离,负数为向左偏移,正数向右偏移
|
||||
- uCharts.js X轴xAxis增加 opts.xAxis.titleFontColor,标题字体颜色,默认#666666
|
||||
|
||||
## 报错TypeError: Cannot read properties of undefined (reading 'length')
|
||||
- 如果是uni-modules版本组件,请先登录HBuilderX账号;
|
||||
- 在HBuilderX中的manifest.json,点击重新获取uniapp的appid,或者删除appid重新粘贴,重新运行;
|
||||
- 如果是cli项目请使用码云上的非uniCloud版本组件;
|
||||
- 或者添加uniCloud的依赖;
|
||||
- 或者使用原生uCharts;
|
||||
## 2.4.5-20221130(2022-11-30)
|
||||
- uCharts.js 优化tooltip当文字很多变为左侧显示时,如果画布仍显显示不下,提示框错位置变为以左侧0位置起画
|
||||
- uCharts.js 折线图修复特殊情况下只有单点数据,并改变线宽后点变为圆形的bug
|
||||
- uCharts.js 修复Y轴disabled启用后无效并报错的bug
|
||||
- uCharts.js 修复仪表盘起始结束角度特殊情况下显示不正确的bug
|
||||
- uCharts.js 雷达图新增参数 opts.extra.radar.radius , 自定义雷达图半径
|
||||
- uCharts.js 折线图、区域图增加tooltip指示点,opts.extra.line.activeType/opts.extra.area.activeType,可选值"none"不启用激活指示点,"hollow"空心点模式,"solid"实心点模式
|
||||
## 2.4.4-20221102(2022-11-02)
|
||||
- 秋云图表组件 修复使用echarts时reload、reshow无法调用重新渲染的bug,[详见码云PR](https://gitee.com/uCharts/uCharts/pulls/40)
|
||||
- 秋云图表组件 修复使用echarts时,初始化时宽高不正确的bug,[详见码云PR](https://gitee.com/uCharts/uCharts/pulls/42)
|
||||
- 秋云图表组件 修复uniapp的h5使用history模式时,无法加载echarts的bug
|
||||
- 秋云图表组件 小程序端@complete、@scrollLeft、@scrollRight、@getTouchStart、@getTouchMove、@getTouchEnd事件增加opts参数传出,方便一些特殊需求的交互获取数据。
|
||||
|
||||
- uCharts.js 修复calTooltipYAxisData方法内formatter格式化方法未与y轴方法同步的问题,[详见码云PR](https://gitee.com/uCharts/uCharts/pulls/43)
|
||||
- uCharts.js 地图新增参数opts.series[i].fillOpacity,以透明度方式来设置颜色过度效果,[详见码云PR](https://gitee.com/uCharts/uCharts/pulls/38)
|
||||
- uCharts.js 地图新增参数opts.extra.map.active,是否启用点击激活变色
|
||||
- uCharts.js 地图新增参数opts.extra.map.activeTextColor,是否启用点击激活变色
|
||||
- uCharts.js 地图新增渲染完成事件renderComplete
|
||||
- uCharts.js 漏斗图修复当部分数据相同时tooltip提示窗点击错误的bug
|
||||
- uCharts.js 漏斗图新增参数series.data[i].centerText 居中标签文案
|
||||
- uCharts.js 漏斗图新增参数series.data[i].centerTextSize 居中标签文案字体大小,默认opts.fontSize
|
||||
- uCharts.js 漏斗图新增参数series.data[i].centerTextColor 居中标签文案字体颜色,默认#FFFFFF
|
||||
- uCharts.js 漏斗图新增参数opts.extra.funnel.minSize 最小值的最小宽度,默认0
|
||||
- uCharts.js 进度条新增参数opts.extra.arcbar.direction,动画方向,可选值为cw顺时针、ccw逆时针
|
||||
- uCharts.js 混合图新增参数opts.extra.mix.line.width,折线的宽度,默认2
|
||||
- uCharts.js 修复tooltip开启horizentalLine水平横线标注时,图表显示错位的bug
|
||||
- uCharts.js 优化tooltip当文字很多变为左侧显示时,如果画布仍显显示不下,提示框错位置变为以左侧0位置起画
|
||||
- uCharts.js 修复开启滚动条后X轴文字超出绘图区域后的隐藏逻辑
|
||||
- uCharts.js 柱状图、条状图修复堆叠模式不能通过{value,color}赋值单个柱子颜色的问题
|
||||
- uCharts.js 气泡图修复不识别series.textSize和series.textColor的bug
|
||||
|
||||
## 报错TypeError: Cannot read properties of undefined (reading 'length')
|
||||
1. 如果是uni-modules版本组件,请先登录HBuilderX账号;
|
||||
2. 在HBuilderX中的manifest.json,点击重新获取uniapp的appid,或者删除appid重新粘贴,重新运行;
|
||||
3. 如果是cli项目请使用码云上的非uniCloud版本组件;
|
||||
4. 或者添加uniCloud的依赖;
|
||||
5. 或者使用原生uCharts;
|
||||
## 2.4.3-20220505(2022-05-05)
|
||||
- 秋云图表组件 修复开启canvas2d后将series赋值为空数组显示加载图标时,再次赋值后画布闪动的bug
|
||||
- 秋云图表组件 修复升级hbx最新版后ECharts的highlight方法报错的bug
|
||||
- uCharts.js 雷达图新增参数opts.extra.radar.gridEval,数据点位网格抽希,默认1
|
||||
- uCharts.js 雷达图新增参数opts.extra.radar.axisLabel, 是否显示刻度点值,默认false
|
||||
- uCharts.js 雷达图新增参数opts.extra.radar.axisLabelTofix,刻度点值小数位数,默认0
|
||||
- uCharts.js 雷达图新增参数opts.extra.radar.labelPointShow,是否显示末端刻度圆点,默认false
|
||||
- uCharts.js 雷达图新增参数opts.extra.radar.labelPointRadius,刻度圆点的半径,默认3
|
||||
- uCharts.js 雷达图新增参数opts.extra.radar.labelPointColor,刻度圆点的颜色,默认#cccccc
|
||||
- uCharts.js 雷达图新增参数opts.extra.radar.linearType,渐变色类型,可选值"none"关闭渐变,"custom"开启渐变
|
||||
- uCharts.js 雷达图新增参数opts.extra.radar.customColor,自定义渐变颜色,数组类型对应series的数组长度以匹配不同series颜色的不同配色方案,例如["#FA7D8D", "#EB88E2"]
|
||||
- uCharts.js 雷达图优化支持series.textColor、series.textSize属性
|
||||
- uCharts.js 柱状图中温度计式图标,优化支持全圆角类型,修复边框有缝隙的bug,详见官网【演示】中的温度计图表
|
||||
- uCharts.js 柱状图新增参数opts.extra.column.activeWidth,当前点击柱状图的背景宽度,默认一个单元格单位
|
||||
- uCharts.js 混合图增加opts.extra.mix.area.gradient 区域图是否开启渐变色
|
||||
- uCharts.js 混合图增加opts.extra.mix.area.opacity 区域图透明度,默认0.2
|
||||
- uCharts.js 饼图、圆环图、玫瑰图、漏斗图,增加opts.series[0].data[i].labelText,自定义标签文字,避免formatter格式化的繁琐,详见官网【演示】中的饼图
|
||||
- uCharts.js 饼图、圆环图、玫瑰图、漏斗图,增加opts.series[0].data[i].labelShow,自定义是否显示某一个指示标签,避免因饼图类别太多导致标签重复或者居多导致图形变形的问题,详见官网【演示】中的饼图
|
||||
- uCharts.js 增加opts.series[i].legendText/opts.series[0].data[i].legendText(与series.name同级)自定义图例显示文字的方法
|
||||
- uCharts.js 优化X轴、Y轴formatter格式化方法增加形参,统一为fromatter:function(value,index,opts){}
|
||||
- uCharts.js 修复横屏模式下无法使用双指缩放方法的bug
|
||||
- uCharts.js 修复当只有一条数据或者多条数据值相等的时候Y轴自动计算的最大值错误的bug
|
||||
- 【官网模板】增加外部自定义图例与图表交互的例子,[点击跳转](https://www.ucharts.cn/v2/#/layout/info?id=2)
|
||||
|
||||
## 注意:非unimodules 版本如因更新 hbx 至 3.4.7 导致报错如下,请到码云更新非 unimodules 版本组件,[点击跳转](https://gitee.com/uCharts/uCharts/tree/master/uni-app/uCharts-%E7%BB%84%E4%BB%B6)
|
||||
> Error in callback for immediate watcher "uchartsOpts": "SyntaxError: Unexpected token u in JSON at position 0"
|
||||
## 2.4.2-20220421(2022-04-21)
|
||||
- 秋云图表组件 修复HBX升级3.4.6.20220420版本后echarts报错的问题
|
||||
## 2.4.2-20220420(2022-04-20)
|
||||
## 重要!此版本uCharts新增了很多功能,修复了诸多已知问题
|
||||
- 秋云图表组件 新增onzoom开启双指缩放功能(仅uCharts),前提需要直角坐标系类图表类型,并且ontouch为true、opts.enableScroll为true,详见实例项目K线图
|
||||
- 秋云图表组件 新增optsWatch是否监听opts变化,关闭optsWatch后,动态修改opts不会触发图表重绘
|
||||
- 秋云图表组件 修复开启canvas2d功能后,动态更新数据后画布闪动的bug
|
||||
- 秋云图表组件 去除directory属性,改为自动获取echarts.min.js路径(升级不受影响)
|
||||
- 秋云图表组件 增加getImage()方法及@getImage事件,通过ref调用getImage()方法获,触发@getImage事件获取当前画布的base64图片文件流。
|
||||
- 秋云图表组件 支付宝、字节跳动、飞书、快手小程序支持开启canvas2d同层渲染设置。
|
||||
- 秋云图表组件 新增加【非uniCloud】版本组件,避免有些不需要uniCloud的使用组件发布至小程序需要提交隐私声明问题,请到码云[【非uniCloud版本】](https://gitee.com/uCharts/uCharts/tree/master/uni-app/uCharts-%E7%BB%84%E4%BB%B6),或npm[【非uniCloud版本】](https://www.npmjs.com/package/@qiun/uni-ucharts)下载使用。
|
||||
- uCharts.js 新增dobuleZoom双指缩放功能
|
||||
- uCharts.js 新增山峰图type="mount",数据格式为饼图类格式,不需要传入categories,具体详见新版官网在线演示
|
||||
- uCharts.js 修复折线图当数据中存在null时tooltip报错的bug
|
||||
- uCharts.js 修复饼图类当画布比较小时自动计算的半径是负数报错的bug
|
||||
- uCharts.js 统一各图表类型的series.formatter格式化方法的形参为(val, index, series, opts),方便格式化时有更多参数可用
|
||||
- uCharts.js 标记线功能增加labelText自定义显示文字,增加labelAlign标签显示位置(左侧或右侧),增加标签显示位置微调labelOffsetX、labelOffsetY
|
||||
- uCharts.js 修复条状图当数值很小时开启圆角后样式错误的bug
|
||||
- uCharts.js 修复X轴开启disabled后,X轴仍占用空间的bug
|
||||
- uCharts.js 修复X轴开启滚动条并且开启rotateLabel后,X轴文字与滚动条重叠的bug
|
||||
- uCharts.js 增加X轴rotateAngle文字旋转自定义角度,取值范围(-90至90)
|
||||
- uCharts.js 修复地图文字标签层级显示不正确的bug
|
||||
- uCharts.js 修复饼图、圆环图、玫瑰图当数据全部为0的时候不显示数据标签的bug
|
||||
- uCharts.js 修复当opts.padding上边距为0时,Y轴顶部刻度标签位置不正确的bug
|
||||
|
||||
## 另外我们还开发了各大原生小程序组件,已发布至码云和npm
|
||||
[https://gitee.com/uCharts/uCharts](https://gitee.com/uCharts/uCharts)
|
||||
[https://www.npmjs.com/~qiun](https://www.npmjs.com/~qiun)
|
||||
|
||||
## 对于原生uCharts文档我们已上线新版官方网站,详情点击下面链接进入官网
|
||||
[https://www.uCharts.cn/v2/](https://www.ucharts.cn/v2/)
|
||||
## 2.3.7-20220122(2022-01-22)
|
||||
## 重要!使用vue3编译,请使用cli模式并升级至最新依赖,HbuilderX编译需要使用3.3.8以上版本
|
||||
- uCharts.js 修复uni-app平台组件模式使用vue3编译到小程序报错的bug。
|
||||
## 2.3.7-20220118(2022-01-18)
|
||||
## 注意,使用vue3的前提是需要3.3.8.20220114-alpha版本的HBuilder!
|
||||
## 2.3.67-20220118(2022-01-18)
|
||||
- 秋云图表组件 组件初步支持vue3,全端编译会有些问题,具体详见下面修改:
|
||||
1. 小程序端运行时,在uni_modules文件夹的qiun-data-charts.js中搜索 new uni_modules_qiunDataCharts_js_sdk_uCharts_uCharts.uCharts,将.uCharts去掉。
|
||||
2. 小程序端发行时,在uni_modules文件夹的qiun-data-charts.js中搜索 new e.uCharts,将.uCharts去掉,变为 new e。
|
||||
3. 如果觉得上述步骤比较麻烦,如果您的项目只编译到小程序端,可以修改u-charts.js最后一行导出方式,将 export default uCharts;变更为 export default { uCharts: uCharts }; 这样变更后,H5和App端的renderjs会有问题,请开发者自行选择。(此问题非组件问题,请等待DC官方修复Vue3的小程序端)
|
||||
## 2.3.6-20220111(2022-01-11)
|
||||
- 秋云图表组件 修改组件 props 属性中的 background 默认值为 rgba(0,0,0,0)
|
||||
## 2.3.6-20211201(2021-12-01)
|
||||
- uCharts.js 修复bar条状图开启圆角模式时,值很小时圆角渲染错误的bug
|
||||
## 2.3.5-20211014(2021-10-15)
|
||||
- uCharts.js 增加vue3的编译支持(仅原生uCharts,qiun-data-charts组件后续会支持,请关注更新)
|
||||
## 2.3.4-20211012(2021-10-12)
|
||||
- 秋云图表组件 修复 mac os x 系统 mouseover 事件丢失的 bug
|
||||
## 2.3.3-20210706(2021-07-06)
|
||||
- uCharts.js 增加雷达图开启数据点值(opts.dataLabel)的显示
|
||||
## 2.3.2-20210627(2021-06-27)
|
||||
- 秋云图表组件 修复tooltipCustom个别情况下传值不正确报错TypeError: Cannot read property 'name' of undefined的bug
|
||||
## 2.3.1-20210616(2021-06-16)
|
||||
- uCharts.js 修复圆角柱状图使用4角圆角时,当数值过大时不正确的bug
|
||||
## 2.3.0-20210612(2021-06-12)
|
||||
- uCharts.js 【重要】uCharts增加nvue兼容,可在nvue项目中使用gcanvas组件渲染uCharts,[详见码云uCharts-demo-nvue](https://gitee.com/uCharts/uCharts)
|
||||
- 秋云图表组件 增加tapLegend属性,是否开启图例点击交互事件
|
||||
- 秋云图表组件 getIndex事件中增加返回uCharts实例中的opts参数,以便在页面中调用参数
|
||||
- 示例项目 pages/other/other.vue增加app端自定义tooltip的方法,详见showOptsTooltip方法
|
||||
## 2.2.1-20210603(2021-06-03)
|
||||
- uCharts.js 修复饼图、圆环图、玫瑰图,当起始角度不为0时,tooltip位置不准确的bug
|
||||
- uCharts.js 增加温度计式柱状图开启顶部半圆形的配置
|
||||
## 2.2.0-20210529(2021-05-29)
|
||||
- uCharts.js 增加条状图type="bar"
|
||||
- 示例项目 pages/ucharts/ucharts.vue增加条状图的demo
|
||||
## 2.1.7-20210524(2021-05-24)
|
||||
- uCharts.js 修复大数据量模式下曲线图不平滑的bug
|
||||
## 2.1.6-20210523(2021-05-23)
|
||||
- 秋云图表组件 修复小程序端开启滚动条更新数据后滚动条位置不符合预期的bug
|
||||
## 2.1.5-2021051702(2021-05-17)
|
||||
- uCharts.js 修复自定义Y轴min和max值为0时不能正确显示的bug
|
||||
## 2.1.5-20210517(2021-05-17)
|
||||
- uCharts.js 修复Y轴自定义min和max时,未按指定的最大值最小值显示坐标轴刻度的bug
|
||||
## 2.1.4-20210516(2021-05-16)
|
||||
- 秋云图表组件 优化onWindowResize防抖方法
|
||||
- 秋云图表组件 修复APP端uCharts更新数据时,清空series显示loading图标后再显示图表,图表抖动的bug
|
||||
- uCharts.js 修复开启canvas2d后,x轴、y轴、series自定义字体大小未按比例缩放的bug
|
||||
- 示例项目 修复format-e.vue拼写错误导致app端使用uCharts渲染图表
|
||||
## 2.1.3-20210513(2021-05-13)
|
||||
- 秋云图表组件 修改uCharts变更chartData数据为updateData方法,支持带滚动条的数据动态打点
|
||||
- 秋云图表组件 增加onWindowResize防抖方法 fix by ど誓言,如尘般染指流年づ
|
||||
- 秋云图表组件 H5或者APP变更chartData数据显示loading图表时,原数据闪现的bug
|
||||
- 秋云图表组件 props增加errorReload禁用错误点击重新加载的方法
|
||||
- uCharts.js 增加tooltip显示category(x轴对应点位)标题的功能,opts.extra.tooltip.showCategory,默认为false
|
||||
- uCharts.js 修复mix混合图只有柱状图时,tooltip的分割线显示位置不正确的bug
|
||||
- uCharts.js 修复开启滚动条,图表在拖动中动态打点,滚动条位置不正确的bug
|
||||
- uCharts.js 修复饼图类数据格式为echarts数据格式,series为空数组报错的bug
|
||||
- 示例项目 修改uCharts.js更新到v2.1.2版本后,@getIndex方法获取索引值变更为e.currentIndex.index
|
||||
- 示例项目 pages/updata/updata.vue增加滚动条拖动更新(数据动态打点)的demo
|
||||
- 示例项目 pages/other/other.vue增加errorReload禁用错误点击重新加载的demo
|
||||
## 2.1.2-20210509(2021-05-09)
|
||||
秋云图表组件 修复APP端初始化时就传入chartData或lacaldata不显示图表的bug
|
||||
## 2.1.1-20210509(2021-05-09)
|
||||
- 秋云图表组件 变更ECharts的eopts配置在renderjs内执行,支持在config-echarts.js配置文件内写function配置。
|
||||
- 秋云图表组件 修复APP端报错Prop being mutated: "onmouse"错误的bug。
|
||||
- 秋云图表组件 修复APP端报错Error: Not Found:Page[6][-1,27] at view.umd.min.js:1的bug。
|
||||
## 2.1.0-20210507(2021-05-07)
|
||||
- 秋云图表组件 修复初始化时就有数据或者数据更新的时候loading加载动画闪动的bug
|
||||
- uCharts.js 修复x轴format方法categories为字符串类型时返回NaN的bug
|
||||
- uCharts.js 修复series.textColor、legend.fontColor未执行全局默认颜色的bug
|
||||
## 2.1.0-20210506(2021-05-06)
|
||||
- 秋云图表组件 修复极个别情况下报错item.properties undefined的bug
|
||||
- 秋云图表组件 修复极个别情况下关闭加载动画reshow不起作用,无法显示图表的bug
|
||||
- 示例项目 pages/ucharts/ucharts.vue 增加时间轴折线图(type="tline")、时间轴区域图(type="tarea")、散点图(type="scatter")、气泡图demo(type="bubble")、倒三角形漏斗图(opts.extra.funnel.type="triangle")、金字塔形漏斗图(opts.extra.funnel.type="pyramid")
|
||||
- 示例项目 pages/format-u/format-u.vue 增加X轴format格式化示例
|
||||
- uCharts.js 升级至v2.1.0版本
|
||||
- uCharts.js 修复 玫瑰图面积模式点击tooltip位置不正确的bug
|
||||
- uCharts.js 修复 玫瑰图点击图例,只剩一个类别显示空白的bug
|
||||
- uCharts.js 修复 饼图类图点击图例,其他图表tooltip位置某些情况下不准的bug
|
||||
- uCharts.js 修复 x轴为矢量轴(时间轴)情况下,点击tooltip位置不正确的bug
|
||||
- uCharts.js 修复 词云图获取点击索引偶尔不准的bug
|
||||
- uCharts.js 增加 直角坐标系图表X轴format格式化方法(原生uCharts.js用法请使用formatter)
|
||||
- uCharts.js 增加 漏斗图扩展配置,倒三角形(opts.extra.funnel.type="triangle"),金字塔形(opts.extra.funnel.type="pyramid")
|
||||
- uCharts.js 增加 散点图(opts.type="scatter")、气泡图(opts.type="bubble")
|
||||
- 后期计划 完善散点图、气泡图,增加markPoints标记点,增加横向条状图。
|
||||
## 2.0.0-20210502(2021-05-02)
|
||||
- uCharts.js 修复词云图获取点击索引不正确的bug
|
||||
## 2.0.0-20210501(2021-05-01)
|
||||
- 秋云图表组件 修复QQ小程序、百度小程序在关闭动画效果情况下,v-for循环使用图表,显示不正确的bug
|
||||
## 2.0.0-20210426(2021-04-26)
|
||||
- 秋云图表组件 修复QQ小程序不支持canvas2d的bug
|
||||
- 秋云图表组件 修复钉钉小程序某些情况点击坐标计算错误的bug
|
||||
- uCharts.js 增加 extra.column.categoryGap 参数,柱状图类每个category点位(X轴点)柱子组之间的间距
|
||||
- uCharts.js 增加 yAxis.data[i].titleOffsetY 参数,标题纵向偏移距离,负数为向上偏移,正数向下偏移
|
||||
- uCharts.js 增加 yAxis.data[i].titleOffsetX 参数,标题横向偏移距离,负数为向左偏移,正数向右偏移
|
||||
- uCharts.js 增加 extra.gauge.labelOffset 参数,仪表盘标签文字径向便宜距离,默认13px
|
||||
## 2.0.0-20210422-2(2021-04-22)
|
||||
秋云图表组件 修复 formatterAssign 未判断 args[key] == null 的情况导致栈溢出的 bug
|
||||
## 2.0.0-20210422(2021-04-22)
|
||||
- 秋云图表组件 修复H5、APP、支付宝小程序、微信小程序canvas2d模式下横屏模式的bug
|
||||
## 2.0.0-20210421(2021-04-21)
|
||||
- uCharts.js 修复多行图例的情况下,图例在上方或者下方时,图例float为左侧或者右侧时,第二行及以后的图例对齐方式不正确的bug
|
||||
## 2.0.0-20210420(2021-04-20)
|
||||
- 秋云图表组件 修复微信小程序开启canvas2d模式后,windows版微信小程序不支持canvas2d模式的bug
|
||||
- 秋云图表组件 修改非uni_modules版本为v2.0版本qiun-data-charts组件
|
||||
## 2.0.0-20210419(2021-04-19)
|
||||
## v1.0版本已停更,建议转uni_modules版本组件方式调用,点击右侧绿色【使用HBuilderX导入插件】即可使用,示例项目请点击右侧蓝色按钮【使用HBuilderX导入示例项目】。
|
||||
## 初次使用如果提示未注册<qiun-data-charts>组件,请重启HBuilderX,如仍不好用,请重启电脑;
|
||||
## 如果是cli项目,请尝试清理node_modules,重新install,还不行就删除项目,再重新install。
|
||||
## 此问题已于DCloud官方确认,HBuilderX下个版本会修复。
|
||||
## 其他图表不显示问题详见[常见问题选项卡](https://demo.ucharts.cn)
|
||||
## <font color=#FF0000> 新手请先完整阅读帮助文档及常见问题3遍,右侧蓝色按钮示例项目请看2遍! </font>
|
||||
## [DEMO演示及在线生成工具(v2.0文档)https://demo.ucharts.cn](https://demo.ucharts.cn)
|
||||
## [图表组件在项目中的应用参见 UReport数据报表](https://ext.dcloud.net.cn/plugin?id=4651)
|
||||
- uCharts.js 修复混合图中柱状图单独设置颜色不生效的bug
|
||||
- uCharts.js 修复多Y轴单独设置fontSize时,开启canvas2d后,未对应放大字体的bug
|
||||
## 2.0.0-20210418(2021-04-18)
|
||||
- 秋云图表组件 增加directory配置,修复H5端history模式下如果发布到二级目录无法正确加载echarts.min.js的bug
|
||||
## 2.0.0-20210416(2021-04-16)
|
||||
## v1.0版本已停更,建议转uni_modules版本组件方式调用,点击右侧绿色【使用HBuilderX导入插件】即可使用,示例项目请点击右侧蓝色按钮【使用HBuilderX导入示例项目】。
|
||||
## 初次使用如果提示未注册<qiun-data-charts>组件,请重启HBuilderX,如仍不好用,请重启电脑;
|
||||
## 如果是cli项目,请尝试清理node_modules,重新install,还不行就删除项目,再重新install。
|
||||
## 此问题已于DCloud官方确认,HBuilderX下个版本会修复。
|
||||
## 其他图表不显示问题详见[常见问题选项卡](https://demo.ucharts.cn)
|
||||
## <font color=#FF0000> 新手请先完整阅读帮助文档及常见问题3遍,右侧蓝色按钮示例项目请看2遍! </font>
|
||||
## [DEMO演示及在线生成工具(v2.0文档)https://demo.ucharts.cn](https://demo.ucharts.cn)
|
||||
## [图表组件在项目中的应用参见 UReport数据报表](https://ext.dcloud.net.cn/plugin?id=4651)
|
||||
- 秋云图表组件 修复APP端某些情况下报错`Not Found Page`的bug,fix by 高级bug开发技术员
|
||||
- 示例项目 修复APP端v-for循环某些情况下报错`Not Found Page`的bug,fix by 高级bug开发技术员
|
||||
- uCharts.js 修复非直角坐标系tooltip提示窗右侧超出未变换方向显示的bug
|
||||
## 2.0.0-20210415(2021-04-15)
|
||||
- 秋云图表组件 修复H5端发布到二级目录下echarts无法加载的bug
|
||||
- 秋云图表组件 修复某些情况下echarts.off('finished')移除监听事件报错的bug
|
||||
## 2.0.0-20210414(2021-04-14)
|
||||
## v1.0版本已停更,建议转uni_modules版本组件方式调用,点击右侧绿色【使用HBuilderX导入插件】即可使用,示例项目请点击右侧蓝色按钮【使用HBuilderX导入示例项目】。
|
||||
## 初次使用如果提示未注册<qiun-data-charts>组件,请重启HBuilderX,如仍不好用,请重启电脑;
|
||||
## 如果是cli项目,请尝试清理node_modules,重新install,还不行就删除项目,再重新install。
|
||||
## 此问题已于DCloud官方确认,HBuilderX下个版本会修复。
|
||||
## 其他图表不显示问题详见[常见问题选项卡](https://demo.ucharts.cn)
|
||||
## <font color=#FF0000> 新手请先完整阅读帮助文档及常见问题3遍,右侧蓝色按钮示例项目请看2遍! </font>
|
||||
## [DEMO演示及在线生成工具(v2.0文档)https://demo.ucharts.cn](https://demo.ucharts.cn)
|
||||
## [图表组件在项目中的应用参见 UReport数据报表](https://ext.dcloud.net.cn/plugin?id=4651)
|
||||
- 秋云图表组件 修复H5端在cli项目下ECharts引用地址错误的bug
|
||||
- 示例项目 增加ECharts的formatter用法的示例(详见示例项目format-e.vue)
|
||||
- uCharts.js 增加圆环图中心背景色的配置extra.ring.centerColor
|
||||
- uCharts.js 修复微信小程序安卓端柱状图开启透明色后显示不正确的bug
|
||||
## 2.0.0-20210413(2021-04-13)
|
||||
- 秋云图表组件 修复百度小程序多个图表真机未能正确获取根元素dom尺寸的bug
|
||||
- 秋云图表组件 修复百度小程序横屏模式方向不正确的bug
|
||||
- 秋云图表组件 修改ontouch时,@getTouchStart@getTouchMove@getTouchEnd的触发条件
|
||||
- uCharts.js 修复饼图类数据格式series属性不生效的bug
|
||||
- uCharts.js 增加时序区域图 详见示例项目中ucharts.vue
|
||||
## 2.0.0-20210412-2(2021-04-12)
|
||||
## v1.0版本已停更,建议转uni_modules版本组件方式调用,点击右侧绿色【使用HBuilderX导入插件】即可使用,示例项目请点击右侧蓝色按钮【使用HBuilderX导入示例项目】。
|
||||
## 初次使用如果提示未注册<qiun-data-charts>组件,请重启HBuilderX。如仍不好用,请重启电脑,此问题已于DCloud官方确认,HBuilderX下个版本会修复。
|
||||
## [DEMO演示及在线生成工具(v2.0文档)https://demo.ucharts.cn](https://demo.ucharts.cn)
|
||||
## [图表组件在uniCloudAdmin中的应用 UReport数据报表](https://ext.dcloud.net.cn/plugin?id=4651)
|
||||
- 秋云图表组件 修复uCharts在APP端横屏模式下不能正确渲染的bug
|
||||
- 示例项目 增加ECharts柱状图渐变色、圆角柱状图、横向柱状图(条状图)的示例
|
||||
## 2.0.0-20210412(2021-04-12)
|
||||
- 秋云图表组件 修复created中判断echarts导致APP端无法识别,改回mounted中判断echarts初始化
|
||||
- uCharts.js 修复2d模式下series.textOffset未乘像素比的bug
|
||||
## 2.0.0-20210411(2021-04-11)
|
||||
## v1.0版本已停更,建议转uni_modules版本组件方式调用,点击右侧绿色【使用HBuilderX导入插件】即可使用,示例项目请点击右侧蓝色按钮【使用HBuilderX导入示例项目】。
|
||||
## 初次使用如果提示未注册<qiun-data-charts>组件,请重启HBuilderX,并清空小程序开发者工具缓存。
|
||||
## [DEMO演示及在线生成工具(v2.0文档)https://demo.ucharts.cn](https://demo.ucharts.cn)
|
||||
## [图表组件在uniCloudAdmin中的应用 UReport数据报表](https://ext.dcloud.net.cn/plugin?id=4651)
|
||||
- uCharts.js 折线图区域图增加connectNulls断点续连的功能,详见示例项目中ucharts.vue
|
||||
- 秋云图表组件 变更初始化方法为created,变更type2d默认值为true,优化2d模式下组件初始化后dom获取不到的bug
|
||||
- 秋云图表组件 修复左右布局时,右侧图表点击坐标错误的bug,修复tooltip柱状图自定义颜色显示object的bug
|
||||
## 2.0.0-20210410(2021-04-10)
|
||||
- 修复左右布局时,右侧图表点击坐标错误的bug,修复柱状图自定义颜色tooltip显示object的bug
|
||||
- 增加标记线及柱状图自定义颜色的demo
|
||||
## 2.0.0-20210409(2021-04-08)
|
||||
## v1.0版本已停更,建议转uni_modules版本组件方式调用,点击右侧【使用HBuilderX导入插件】即可体验,DEMO演示及在线生成工具(v2.0文档)[https://demo.ucharts.cn](https://demo.ucharts.cn)
|
||||
## 图表组件在uniCloudAdmin中的应用 [UReport数据报表](https://ext.dcloud.net.cn/plugin?id=4651)
|
||||
- uCharts.js 修复钉钉小程序百度小程序measureText不准确的bug,修复2d模式下饼图类activeRadius为按比例放大的bug
|
||||
- 修复组件在支付宝小程序端点击位置不准确的bug
|
||||
## 2.0.0-20210408(2021-04-07)
|
||||
- 修复组件在支付宝小程序端不能显示的bug(目前支付宝小程不能点击交互,后续修复)
|
||||
- uCharts.js 修复高分屏下柱状图类,圆弧进度条 自定义宽度不能按比例放大的bug
|
||||
## 2.0.0-20210407(2021-04-06)
|
||||
## v1.0版本已停更,建议转uni_modules版本组件方式调用,点击右侧【使用HBuilderX导入插件】即可体验,DEMO演示及在线生成工具(v2.0文档)[https://demo.ucharts.cn](https://demo.ucharts.cn)
|
||||
## 增加 通过tofix和unit快速格式化y轴的demo add by `howcode`
|
||||
## 增加 图表组件在uniCloudAdmin中的应用 [UReport数据报表](https://ext.dcloud.net.cn/plugin?id=4651)
|
||||
## 2.0.0-20210406(2021-04-05)
|
||||
# 秋云图表组件+uCharts v2.0版本同步上线,使用方法详见https://demo.ucharts.cn帮助页
|
||||
## 2.0.0(2021-04-05)
|
||||
# 秋云图表组件+uCharts v2.0版本同步上线,使用方法详见https://demo.ucharts.cn帮助页
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because one or more lines are too long
|
@ -0,0 +1,162 @@
|
|||
<template>
|
||||
<view class="container loading1">
|
||||
<view class="shape shape1"></view>
|
||||
<view class="shape shape2"></view>
|
||||
<view class="shape shape3"></view>
|
||||
<view class="shape shape4"></view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: 'loading1',
|
||||
data() {
|
||||
return {
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped="true">
|
||||
.container {
|
||||
width: 30px;
|
||||
height: 30px;
|
||||
position: relative;
|
||||
}
|
||||
.container.loading1 {
|
||||
-webkit-transform: rotate(45deg);
|
||||
transform: rotate(45deg);
|
||||
}
|
||||
|
||||
.container .shape {
|
||||
position: absolute;
|
||||
width: 10px;
|
||||
height: 10px;
|
||||
border-radius: 1px;
|
||||
}
|
||||
.container .shape.shape1 {
|
||||
left: 0;
|
||||
background-color: #1890FF;
|
||||
}
|
||||
.container .shape.shape2 {
|
||||
right: 0;
|
||||
background-color: #91CB74;
|
||||
}
|
||||
.container .shape.shape3 {
|
||||
bottom: 0;
|
||||
background-color: #FAC858;
|
||||
}
|
||||
.container .shape.shape4 {
|
||||
bottom: 0;
|
||||
right: 0;
|
||||
background-color: #EE6666;
|
||||
}
|
||||
|
||||
.loading1 .shape1 {
|
||||
-webkit-animation: animation1shape1 0.5s ease 0s infinite alternate;
|
||||
animation: animation1shape1 0.5s ease 0s infinite alternate;
|
||||
}
|
||||
|
||||
@-webkit-keyframes animation1shape1 {
|
||||
from {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
to {
|
||||
-webkit-transform: translate(16px, 16px);
|
||||
transform: translate(16px, 16px);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes animation1shape1 {
|
||||
from {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
to {
|
||||
-webkit-transform: translate(16px, 16px);
|
||||
transform: translate(16px, 16px);
|
||||
}
|
||||
}
|
||||
.loading1 .shape2 {
|
||||
-webkit-animation: animation1shape2 0.5s ease 0s infinite alternate;
|
||||
animation: animation1shape2 0.5s ease 0s infinite alternate;
|
||||
}
|
||||
|
||||
@-webkit-keyframes animation1shape2 {
|
||||
from {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
to {
|
||||
-webkit-transform: translate(-16px, 16px);
|
||||
transform: translate(-16px, 16px);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes animation1shape2 {
|
||||
from {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
to {
|
||||
-webkit-transform: translate(-16px, 16px);
|
||||
transform: translate(-16px, 16px);
|
||||
}
|
||||
}
|
||||
.loading1 .shape3 {
|
||||
-webkit-animation: animation1shape3 0.5s ease 0s infinite alternate;
|
||||
animation: animation1shape3 0.5s ease 0s infinite alternate;
|
||||
}
|
||||
|
||||
@-webkit-keyframes animation1shape3 {
|
||||
from {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
to {
|
||||
-webkit-transform: translate(16px, -16px);
|
||||
transform: translate(16px, -16px);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes animation1shape3 {
|
||||
from {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
to {
|
||||
-webkit-transform: translate(16px, -16px);
|
||||
transform: translate(16px, -16px);
|
||||
}
|
||||
}
|
||||
.loading1 .shape4 {
|
||||
-webkit-animation: animation1shape4 0.5s ease 0s infinite alternate;
|
||||
animation: animation1shape4 0.5s ease 0s infinite alternate;
|
||||
}
|
||||
|
||||
@-webkit-keyframes animation1shape4 {
|
||||
from {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
to {
|
||||
-webkit-transform: translate(-16px, -16px);
|
||||
transform: translate(-16px, -16px);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes animation1shape4 {
|
||||
from {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
to {
|
||||
-webkit-transform: translate(-16px, -16px);
|
||||
transform: translate(-16px, -16px);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
</style>
|
|
@ -0,0 +1,170 @@
|
|||
<template>
|
||||
<view class="container loading2">
|
||||
<view class="shape shape1"></view>
|
||||
<view class="shape shape2"></view>
|
||||
<view class="shape shape3"></view>
|
||||
<view class="shape shape4"></view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: 'loading2',
|
||||
data() {
|
||||
return {
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped="true">
|
||||
.container {
|
||||
width: 30px;
|
||||
height: 30px;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.container.loading2 {
|
||||
-webkit-transform: rotate(10deg);
|
||||
transform: rotate(10deg);
|
||||
}
|
||||
.container.loading2 .shape {
|
||||
border-radius: 5px;
|
||||
}
|
||||
.container.loading2{
|
||||
-webkit-animation: rotation 1s infinite;
|
||||
animation: rotation 1s infinite;
|
||||
}
|
||||
|
||||
.container .shape {
|
||||
position: absolute;
|
||||
width: 10px;
|
||||
height: 10px;
|
||||
border-radius: 1px;
|
||||
}
|
||||
.container .shape.shape1 {
|
||||
left: 0;
|
||||
background-color: #1890FF;
|
||||
}
|
||||
.container .shape.shape2 {
|
||||
right: 0;
|
||||
background-color: #91CB74;
|
||||
}
|
||||
.container .shape.shape3 {
|
||||
bottom: 0;
|
||||
background-color: #FAC858;
|
||||
}
|
||||
.container .shape.shape4 {
|
||||
bottom: 0;
|
||||
right: 0;
|
||||
background-color: #EE6666;
|
||||
}
|
||||
|
||||
|
||||
.loading2 .shape1 {
|
||||
-webkit-animation: animation2shape1 0.5s ease 0s infinite alternate;
|
||||
animation: animation2shape1 0.5s ease 0s infinite alternate;
|
||||
}
|
||||
|
||||
@-webkit-keyframes animation2shape1 {
|
||||
from {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
to {
|
||||
-webkit-transform: translate(20px, 20px);
|
||||
transform: translate(20px, 20px);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes animation2shape1 {
|
||||
from {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
to {
|
||||
-webkit-transform: translate(20px, 20px);
|
||||
transform: translate(20px, 20px);
|
||||
}
|
||||
}
|
||||
.loading2 .shape2 {
|
||||
-webkit-animation: animation2shape2 0.5s ease 0s infinite alternate;
|
||||
animation: animation2shape2 0.5s ease 0s infinite alternate;
|
||||
}
|
||||
|
||||
@-webkit-keyframes animation2shape2 {
|
||||
from {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
to {
|
||||
-webkit-transform: translate(-20px, 20px);
|
||||
transform: translate(-20px, 20px);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes animation2shape2 {
|
||||
from {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
to {
|
||||
-webkit-transform: translate(-20px, 20px);
|
||||
transform: translate(-20px, 20px);
|
||||
}
|
||||
}
|
||||
.loading2 .shape3 {
|
||||
-webkit-animation: animation2shape3 0.5s ease 0s infinite alternate;
|
||||
animation: animation2shape3 0.5s ease 0s infinite alternate;
|
||||
}
|
||||
|
||||
@-webkit-keyframes animation2shape3 {
|
||||
from {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
to {
|
||||
-webkit-transform: translate(20px, -20px);
|
||||
transform: translate(20px, -20px);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes animation2shape3 {
|
||||
from {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
to {
|
||||
-webkit-transform: translate(20px, -20px);
|
||||
transform: translate(20px, -20px);
|
||||
}
|
||||
}
|
||||
.loading2 .shape4 {
|
||||
-webkit-animation: animation2shape4 0.5s ease 0s infinite alternate;
|
||||
animation: animation2shape4 0.5s ease 0s infinite alternate;
|
||||
}
|
||||
|
||||
@-webkit-keyframes animation2shape4 {
|
||||
from {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
to {
|
||||
-webkit-transform: translate(-20px, -20px);
|
||||
transform: translate(-20px, -20px);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes animation2shape4 {
|
||||
from {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
to {
|
||||
-webkit-transform: translate(-20px, -20px);
|
||||
transform: translate(-20px, -20px);
|
||||
}
|
||||
}
|
||||
|
||||
</style>
|
|
@ -0,0 +1,173 @@
|
|||
<template>
|
||||
<view class="container loading3">
|
||||
<view class="shape shape1"></view>
|
||||
<view class="shape shape2"></view>
|
||||
<view class="shape shape3"></view>
|
||||
<view class="shape shape4"></view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: 'loading3',
|
||||
data() {
|
||||
return {
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped="true">
|
||||
.container {
|
||||
width: 30px;
|
||||
height: 30px;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.container.loading3 {
|
||||
-webkit-animation: rotation 1s infinite;
|
||||
animation: rotation 1s infinite;
|
||||
}
|
||||
.container.loading3 .shape1 {
|
||||
border-top-left-radius: 10px;
|
||||
}
|
||||
.container.loading3 .shape2 {
|
||||
border-top-right-radius: 10px;
|
||||
}
|
||||
.container.loading3 .shape3 {
|
||||
border-bottom-left-radius: 10px;
|
||||
}
|
||||
.container.loading3 .shape4 {
|
||||
border-bottom-right-radius: 10px;
|
||||
}
|
||||
|
||||
.container .shape {
|
||||
position: absolute;
|
||||
width: 10px;
|
||||
height: 10px;
|
||||
border-radius: 1px;
|
||||
}
|
||||
.container .shape.shape1 {
|
||||
left: 0;
|
||||
background-color: #1890FF;
|
||||
}
|
||||
.container .shape.shape2 {
|
||||
right: 0;
|
||||
background-color: #91CB74;
|
||||
}
|
||||
.container .shape.shape3 {
|
||||
bottom: 0;
|
||||
background-color: #FAC858;
|
||||
}
|
||||
.container .shape.shape4 {
|
||||
bottom: 0;
|
||||
right: 0;
|
||||
background-color: #EE6666;
|
||||
}
|
||||
|
||||
.loading3 .shape1 {
|
||||
-webkit-animation: animation3shape1 0.5s ease 0s infinite alternate;
|
||||
animation: animation3shape1 0.5s ease 0s infinite alternate;
|
||||
}
|
||||
|
||||
@-webkit-keyframes animation3shape1 {
|
||||
from {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
to {
|
||||
-webkit-transform: translate(5px, 5px);
|
||||
transform: translate(5px, 5px);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes animation3shape1 {
|
||||
from {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
to {
|
||||
-webkit-transform: translate(5px, 5px);
|
||||
transform: translate(5px, 5px);
|
||||
}
|
||||
}
|
||||
.loading3 .shape2 {
|
||||
-webkit-animation: animation3shape2 0.5s ease 0s infinite alternate;
|
||||
animation: animation3shape2 0.5s ease 0s infinite alternate;
|
||||
}
|
||||
|
||||
@-webkit-keyframes animation3shape2 {
|
||||
from {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
to {
|
||||
-webkit-transform: translate(-5px, 5px);
|
||||
transform: translate(-5px, 5px);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes animation3shape2 {
|
||||
from {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
to {
|
||||
-webkit-transform: translate(-5px, 5px);
|
||||
transform: translate(-5px, 5px);
|
||||
}
|
||||
}
|
||||
.loading3 .shape3 {
|
||||
-webkit-animation: animation3shape3 0.5s ease 0s infinite alternate;
|
||||
animation: animation3shape3 0.5s ease 0s infinite alternate;
|
||||
}
|
||||
|
||||
@-webkit-keyframes animation3shape3 {
|
||||
from {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
to {
|
||||
-webkit-transform: translate(5px, -5px);
|
||||
transform: translate(5px, -5px);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes animation3shape3 {
|
||||
from {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
to {
|
||||
-webkit-transform: translate(5px, -5px);
|
||||
transform: translate(5px, -5px);
|
||||
}
|
||||
}
|
||||
.loading3 .shape4 {
|
||||
-webkit-animation: animation3shape4 0.5s ease 0s infinite alternate;
|
||||
animation: animation3shape4 0.5s ease 0s infinite alternate;
|
||||
}
|
||||
|
||||
@-webkit-keyframes animation3shape4 {
|
||||
from {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
to {
|
||||
-webkit-transform: translate(-5px, -5px);
|
||||
transform: translate(-5px, -5px);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes animation3shape4 {
|
||||
from {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
to {
|
||||
-webkit-transform: translate(-5px, -5px);
|
||||
transform: translate(-5px, -5px);
|
||||
}
|
||||
}
|
||||
</style>
|
|
@ -0,0 +1,222 @@
|
|||
<template>
|
||||
<view class="container loading5">
|
||||
<view class="shape shape1"></view>
|
||||
<view class="shape shape2"></view>
|
||||
<view class="shape shape3"></view>
|
||||
<view class="shape shape4"></view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: 'loading5',
|
||||
data() {
|
||||
return {
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped="true">
|
||||
.container {
|
||||
width: 30px;
|
||||
height: 30px;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.container.loading5 .shape {
|
||||
width: 15px;
|
||||
height: 15px;
|
||||
}
|
||||
|
||||
.container .shape {
|
||||
position: absolute;
|
||||
width: 10px;
|
||||
height: 10px;
|
||||
border-radius: 1px;
|
||||
}
|
||||
.container .shape.shape1 {
|
||||
left: 0;
|
||||
background-color: #1890FF;
|
||||
}
|
||||
.container .shape.shape2 {
|
||||
right: 0;
|
||||
background-color: #91CB74;
|
||||
}
|
||||
.container .shape.shape3 {
|
||||
bottom: 0;
|
||||
background-color: #FAC858;
|
||||
}
|
||||
.container .shape.shape4 {
|
||||
bottom: 0;
|
||||
right: 0;
|
||||
background-color: #EE6666;
|
||||
}
|
||||
|
||||
.loading5 .shape1 {
|
||||
animation: animation5shape1 2s ease 0s infinite reverse;
|
||||
}
|
||||
|
||||
@-webkit-keyframes animation5shape1 {
|
||||
0% {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
25% {
|
||||
-webkit-transform: translate(0, 15px);
|
||||
transform: translate(0, 15px);
|
||||
}
|
||||
50% {
|
||||
-webkit-transform: translate(15px, 15px);
|
||||
transform: translate(15px, 15px);
|
||||
}
|
||||
75% {
|
||||
-webkit-transform: translate(15px, 0);
|
||||
transform: translate(15px, 0);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes animation5shape1 {
|
||||
0% {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
25% {
|
||||
-webkit-transform: translate(0, 15px);
|
||||
transform: translate(0, 15px);
|
||||
}
|
||||
50% {
|
||||
-webkit-transform: translate(15px, 15px);
|
||||
transform: translate(15px, 15px);
|
||||
}
|
||||
75% {
|
||||
-webkit-transform: translate(15px, 0);
|
||||
transform: translate(15px, 0);
|
||||
}
|
||||
}
|
||||
.loading5 .shape2 {
|
||||
animation: animation5shape2 2s ease 0s infinite reverse;
|
||||
}
|
||||
|
||||
@-webkit-keyframes animation5shape2 {
|
||||
0% {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
25% {
|
||||
-webkit-transform: translate(-15px, 0);
|
||||
transform: translate(-15px, 0);
|
||||
}
|
||||
50% {
|
||||
-webkit-transform: translate(-15px, 15px);
|
||||
transform: translate(-15px, 15px);
|
||||
}
|
||||
75% {
|
||||
-webkit-transform: translate(0, 15px);
|
||||
transform: translate(0, 15px);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes animation5shape2 {
|
||||
0% {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
25% {
|
||||
-webkit-transform: translate(-15px, 0);
|
||||
transform: translate(-15px, 0);
|
||||
}
|
||||
50% {
|
||||
-webkit-transform: translate(-15px, 15px);
|
||||
transform: translate(-15px, 15px);
|
||||
}
|
||||
75% {
|
||||
-webkit-transform: translate(0, 15px);
|
||||
transform: translate(0, 15px);
|
||||
}
|
||||
}
|
||||
.loading5 .shape3 {
|
||||
animation: animation5shape3 2s ease 0s infinite reverse;
|
||||
}
|
||||
|
||||
@-webkit-keyframes animation5shape3 {
|
||||
0% {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
25% {
|
||||
-webkit-transform: translate(15px, 0);
|
||||
transform: translate(15px, 0);
|
||||
}
|
||||
50% {
|
||||
-webkit-transform: translate(15px, -15px);
|
||||
transform: translate(15px, -15px);
|
||||
}
|
||||
75% {
|
||||
-webkit-transform: translate(0, -15px);
|
||||
transform: translate(0, -15px);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes animation5shape3 {
|
||||
0% {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
25% {
|
||||
-webkit-transform: translate(15px, 0);
|
||||
transform: translate(15px, 0);
|
||||
}
|
||||
50% {
|
||||
-webkit-transform: translate(15px, -15px);
|
||||
transform: translate(15px, -15px);
|
||||
}
|
||||
75% {
|
||||
-webkit-transform: translate(0, -15px);
|
||||
transform: translate(0, -15px);
|
||||
}
|
||||
}
|
||||
.loading5 .shape4 {
|
||||
animation: animation5shape4 2s ease 0s infinite reverse;
|
||||
}
|
||||
|
||||
@-webkit-keyframes animation5shape4 {
|
||||
0% {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
25% {
|
||||
-webkit-transform: translate(0, -15px);
|
||||
transform: translate(0, -15px);
|
||||
}
|
||||
50% {
|
||||
-webkit-transform: translate(-15px, -15px);
|
||||
transform: translate(-15px, -15px);
|
||||
}
|
||||
75% {
|
||||
-webkit-transform: translate(-15px, 0);
|
||||
transform: translate(-15px, 0);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes animation5shape4 {
|
||||
0% {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
25% {
|
||||
-webkit-transform: translate(0, -15px);
|
||||
transform: translate(0, -15px);
|
||||
}
|
||||
50% {
|
||||
-webkit-transform: translate(-15px, -15px);
|
||||
transform: translate(-15px, -15px);
|
||||
}
|
||||
75% {
|
||||
-webkit-transform: translate(-15px, 0);
|
||||
transform: translate(-15px, 0);
|
||||
}
|
||||
}
|
||||
|
||||
</style>
|
|
@ -0,0 +1,229 @@
|
|||
<template>
|
||||
<view class="container loading6">
|
||||
<view class="shape shape1"></view>
|
||||
<view class="shape shape2"></view>
|
||||
<view class="shape shape3"></view>
|
||||
<view class="shape shape4"></view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: 'loading6',
|
||||
data() {
|
||||
return {
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style scoped="true">
|
||||
.container {
|
||||
width: 30px;
|
||||
height: 30px;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.container.loading6 {
|
||||
-webkit-animation: rotation 1s infinite;
|
||||
animation: rotation 1s infinite;
|
||||
}
|
||||
.container.loading6 .shape {
|
||||
width: 12px;
|
||||
height: 12px;
|
||||
border-radius: 2px;
|
||||
}
|
||||
.container .shape {
|
||||
position: absolute;
|
||||
width: 10px;
|
||||
height: 10px;
|
||||
border-radius: 1px;
|
||||
}
|
||||
.container .shape.shape1 {
|
||||
left: 0;
|
||||
background-color: #1890FF;
|
||||
}
|
||||
.container .shape.shape2 {
|
||||
right: 0;
|
||||
background-color: #91CB74;
|
||||
}
|
||||
.container .shape.shape3 {
|
||||
bottom: 0;
|
||||
background-color: #FAC858;
|
||||
}
|
||||
.container .shape.shape4 {
|
||||
bottom: 0;
|
||||
right: 0;
|
||||
background-color: #EE6666;
|
||||
}
|
||||
|
||||
|
||||
.loading6 .shape1 {
|
||||
-webkit-animation: animation6shape1 2s linear 0s infinite normal;
|
||||
animation: animation6shape1 2s linear 0s infinite normal;
|
||||
}
|
||||
|
||||
@-webkit-keyframes animation6shape1 {
|
||||
0% {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
25% {
|
||||
-webkit-transform: translate(0, 18px);
|
||||
transform: translate(0, 18px);
|
||||
}
|
||||
50% {
|
||||
-webkit-transform: translate(18px, 18px);
|
||||
transform: translate(18px, 18px);
|
||||
}
|
||||
75% {
|
||||
-webkit-transform: translate(18px, 0);
|
||||
transform: translate(18px, 0);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes animation6shape1 {
|
||||
0% {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
25% {
|
||||
-webkit-transform: translate(0, 18px);
|
||||
transform: translate(0, 18px);
|
||||
}
|
||||
50% {
|
||||
-webkit-transform: translate(18px, 18px);
|
||||
transform: translate(18px, 18px);
|
||||
}
|
||||
75% {
|
||||
-webkit-transform: translate(18px, 0);
|
||||
transform: translate(18px, 0);
|
||||
}
|
||||
}
|
||||
.loading6 .shape2 {
|
||||
-webkit-animation: animation6shape2 2s linear 0s infinite normal;
|
||||
animation: animation6shape2 2s linear 0s infinite normal;
|
||||
}
|
||||
|
||||
@-webkit-keyframes animation6shape2 {
|
||||
0% {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
25% {
|
||||
-webkit-transform: translate(-18px, 0);
|
||||
transform: translate(-18px, 0);
|
||||
}
|
||||
50% {
|
||||
-webkit-transform: translate(-18px, 18px);
|
||||
transform: translate(-18px, 18px);
|
||||
}
|
||||
75% {
|
||||
-webkit-transform: translate(0, 18px);
|
||||
transform: translate(0, 18px);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes animation6shape2 {
|
||||
0% {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
25% {
|
||||
-webkit-transform: translate(-18px, 0);
|
||||
transform: translate(-18px, 0);
|
||||
}
|
||||
50% {
|
||||
-webkit-transform: translate(-18px, 18px);
|
||||
transform: translate(-18px, 18px);
|
||||
}
|
||||
75% {
|
||||
-webkit-transform: translate(0, 18px);
|
||||
transform: translate(0, 18px);
|
||||
}
|
||||
}
|
||||
.loading6 .shape3 {
|
||||
-webkit-animation: animation6shape3 2s linear 0s infinite normal;
|
||||
animation: animation6shape3 2s linear 0s infinite normal;
|
||||
}
|
||||
|
||||
@-webkit-keyframes animation6shape3 {
|
||||
0% {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
25% {
|
||||
-webkit-transform: translate(18px, 0);
|
||||
transform: translate(18px, 0);
|
||||
}
|
||||
50% {
|
||||
-webkit-transform: translate(18px, -18px);
|
||||
transform: translate(18px, -18px);
|
||||
}
|
||||
75% {
|
||||
-webkit-transform: translate(0, -18px);
|
||||
transform: translate(0, -18px);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes animation6shape3 {
|
||||
0% {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
25% {
|
||||
-webkit-transform: translate(18px, 0);
|
||||
transform: translate(18px, 0);
|
||||
}
|
||||
50% {
|
||||
-webkit-transform: translate(18px, -18px);
|
||||
transform: translate(18px, -18px);
|
||||
}
|
||||
75% {
|
||||
-webkit-transform: translate(0, -18px);
|
||||
transform: translate(0, -18px);
|
||||
}
|
||||
}
|
||||
.loading6 .shape4 {
|
||||
-webkit-animation: animation6shape4 2s linear 0s infinite normal;
|
||||
animation: animation6shape4 2s linear 0s infinite normal;
|
||||
}
|
||||
|
||||
@-webkit-keyframes animation6shape4 {
|
||||
0% {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
25% {
|
||||
-webkit-transform: translate(0, -18px);
|
||||
transform: translate(0, -18px);
|
||||
}
|
||||
50% {
|
||||
-webkit-transform: translate(-18px, -18px);
|
||||
transform: translate(-18px, -18px);
|
||||
}
|
||||
75% {
|
||||
-webkit-transform: translate(-18px, 0);
|
||||
transform: translate(-18px, 0);
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes animation6shape4 {
|
||||
0% {
|
||||
-webkit-transform: translate(0, 0);
|
||||
transform: translate(0, 0);
|
||||
}
|
||||
25% {
|
||||
-webkit-transform: translate(0, -18px);
|
||||
transform: translate(0, -18px);
|
||||
}
|
||||
50% {
|
||||
-webkit-transform: translate(-18px, -18px);
|
||||
transform: translate(-18px, -18px);
|
||||
}
|
||||
75% {
|
||||
-webkit-transform: translate(-18px, 0);
|
||||
transform: translate(-18px, 0);
|
||||
}
|
||||
}
|
||||
</style>
|
|
@ -0,0 +1,36 @@
|
|||
<template>
|
||||
<view>
|
||||
<Loading1 v-if="loadingType==1"/>
|
||||
<Loading2 v-if="loadingType==2"/>
|
||||
<Loading3 v-if="loadingType==3"/>
|
||||
<Loading4 v-if="loadingType==4"/>
|
||||
<Loading5 v-if="loadingType==5"/>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import Loading1 from "./loading1.vue";
|
||||
import Loading2 from "./loading2.vue";
|
||||
import Loading3 from "./loading3.vue";
|
||||
import Loading4 from "./loading4.vue";
|
||||
import Loading5 from "./loading5.vue";
|
||||
export default {
|
||||
components:{Loading1,Loading2,Loading3,Loading4,Loading5},
|
||||
name: 'qiun-loading',
|
||||
props: {
|
||||
loadingType: {
|
||||
type: Number,
|
||||
default: 2
|
||||
},
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
|
||||
};
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
||||
<style>
|
||||
|
||||
</style>
|
|
@ -0,0 +1,422 @@
|
|||
/*
|
||||
* uCharts®
|
||||
* 高性能跨平台图表库,支持H5、APP、小程序(微信/支付宝/百度/头条/QQ/360)、Vue、Taro等支持canvas的框架平台
|
||||
* Copyright (c) 2021 QIUN®秋云 https://www.ucharts.cn All rights reserved.
|
||||
* Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
|
||||
* 复制使用请保留本段注释,感谢支持开源!
|
||||
*
|
||||
* uCharts®官方网站
|
||||
* https://www.uCharts.cn
|
||||
*
|
||||
* 开源地址:
|
||||
* https://gitee.com/uCharts/uCharts
|
||||
*
|
||||
* uni-app插件市场地址:
|
||||
* http://ext.dcloud.net.cn/plugin?id=271
|
||||
*
|
||||
*/
|
||||
|
||||
// 通用配置项
|
||||
|
||||
// 主题颜色配置:如每个图表类型需要不同主题,请在对应图表类型上更改color属性
|
||||
const color = ['#1890FF', '#91CB74', '#FAC858', '#EE6666', '#73C0DE', '#3CA272', '#FC8452', '#9A60B4', '#ea7ccc'];
|
||||
|
||||
const cfe = {
|
||||
//demotype为自定义图表类型
|
||||
"type": ["pie", "ring", "rose", "funnel", "line", "column", "area", "radar", "gauge","candle","demotype"],
|
||||
//增加自定义图表类型,如果需要categories,请在这里加入您的图表类型例如最后的"demotype"
|
||||
"categories": ["line", "column", "area", "radar", "gauge", "candle","demotype"],
|
||||
//instance为实例变量承载属性,option为eopts承载属性,不要删除
|
||||
"instance": {},
|
||||
"option": {},
|
||||
//下面是自定义format配置,因除H5端外的其他端无法通过props传递函数,只能通过此属性对应下标的方式来替换
|
||||
"formatter":{
|
||||
"tooltipDemo1":function(res){
|
||||
let result = ''
|
||||
for (let i in res) {
|
||||
if (i == 0) {
|
||||
result += res[i].axisValueLabel + '年销售额'
|
||||
}
|
||||
let value = '--'
|
||||
if (res[i].data !== null) {
|
||||
value = res[i].data
|
||||
}
|
||||
// #ifdef H5
|
||||
result += '\n' + res[i].seriesName + ':' + value + ' 万元'
|
||||
// #endif
|
||||
|
||||
// #ifdef APP-PLUS
|
||||
result += '<br/>' + res[i].marker + res[i].seriesName + ':' + value + ' 万元'
|
||||
// #endif
|
||||
}
|
||||
return result;
|
||||
},
|
||||
legendFormat:function(name){
|
||||
return "自定义图例+"+name;
|
||||
},
|
||||
yAxisFormatDemo:function (value, index) {
|
||||
return value + '元';
|
||||
},
|
||||
seriesFormatDemo:function(res){
|
||||
return res.name + '年' + res.value + '元';
|
||||
}
|
||||
},
|
||||
//这里演示了自定义您的图表类型的option,可以随意命名,之后在组件上 type="demotype" 后,组件会调用这个花括号里的option,如果组件上还存在eopts参数,会将demotype与eopts中option合并后渲染图表。
|
||||
"demotype":{
|
||||
"color": color,
|
||||
//在这里填写echarts的option即可
|
||||
|
||||
},
|
||||
//下面是自定义配置,请添加项目所需的通用配置
|
||||
"column": {
|
||||
"color": color,
|
||||
"title": {
|
||||
"text": ''
|
||||
},
|
||||
"tooltip": {
|
||||
"trigger": 'axis'
|
||||
},
|
||||
"grid": {
|
||||
"top": 30,
|
||||
"bottom": 50,
|
||||
"right": 15,
|
||||
"left": 40
|
||||
},
|
||||
"legend": {
|
||||
"bottom": 'left',
|
||||
},
|
||||
"toolbox": {
|
||||
"show": false,
|
||||
},
|
||||
"xAxis": {
|
||||
"type": 'category',
|
||||
"axisLabel": {
|
||||
"color": '#666666'
|
||||
},
|
||||
"axisLine": {
|
||||
"lineStyle": {
|
||||
"color": '#CCCCCC'
|
||||
}
|
||||
},
|
||||
"boundaryGap": true,
|
||||
"data": []
|
||||
},
|
||||
"yAxis": {
|
||||
"type": 'value',
|
||||
"axisTick": {
|
||||
"show": false,
|
||||
},
|
||||
"axisLabel": {
|
||||
"color": '#666666'
|
||||
},
|
||||
"axisLine": {
|
||||
"lineStyle": {
|
||||
"color": '#CCCCCC'
|
||||
}
|
||||
},
|
||||
},
|
||||
"seriesTemplate": {
|
||||
"name": '',
|
||||
"type": 'bar',
|
||||
"data": [],
|
||||
"barwidth": 20,
|
||||
"label": {
|
||||
"show": true,
|
||||
"color": "#666666",
|
||||
"position": 'top',
|
||||
},
|
||||
},
|
||||
},
|
||||
"line": {
|
||||
"color": color,
|
||||
"title": {
|
||||
"text": ''
|
||||
},
|
||||
"tooltip": {
|
||||
"trigger": 'axis'
|
||||
},
|
||||
"grid": {
|
||||
"top": 30,
|
||||
"bottom": 50,
|
||||
"right": 15,
|
||||
"left": 40
|
||||
},
|
||||
"legend": {
|
||||
"bottom": 'left',
|
||||
},
|
||||
"toolbox": {
|
||||
"show": false,
|
||||
},
|
||||
"xAxis": {
|
||||
"type": 'category',
|
||||
"axisLabel": {
|
||||
"color": '#666666'
|
||||
},
|
||||
"axisLine": {
|
||||
"lineStyle": {
|
||||
"color": '#CCCCCC'
|
||||
}
|
||||
},
|
||||
"boundaryGap": true,
|
||||
"data": []
|
||||
},
|
||||
"yAxis": {
|
||||
"type": 'value',
|
||||
"axisTick": {
|
||||
"show": false,
|
||||
},
|
||||
"axisLabel": {
|
||||
"color": '#666666'
|
||||
},
|
||||
"axisLine": {
|
||||
"lineStyle": {
|
||||
"color": '#CCCCCC'
|
||||
}
|
||||
},
|
||||
},
|
||||
"seriesTemplate": {
|
||||
"name": '',
|
||||
"type": 'line',
|
||||
"data": [],
|
||||
"barwidth": 20,
|
||||
"label": {
|
||||
"show": true,
|
||||
"color": "#666666",
|
||||
"position": 'top',
|
||||
},
|
||||
},
|
||||
},
|
||||
"area": {
|
||||
"color": color,
|
||||
"title": {
|
||||
"text": ''
|
||||
},
|
||||
"tooltip": {
|
||||
"trigger": 'axis'
|
||||
},
|
||||
"grid": {
|
||||
"top": 30,
|
||||
"bottom": 50,
|
||||
"right": 15,
|
||||
"left": 40
|
||||
},
|
||||
"legend": {
|
||||
"bottom": 'left',
|
||||
},
|
||||
"toolbox": {
|
||||
"show": false,
|
||||
},
|
||||
"xAxis": {
|
||||
"type": 'category',
|
||||
"axisLabel": {
|
||||
"color": '#666666'
|
||||
},
|
||||
"axisLine": {
|
||||
"lineStyle": {
|
||||
"color": '#CCCCCC'
|
||||
}
|
||||
},
|
||||
"boundaryGap": true,
|
||||
"data": []
|
||||
},
|
||||
"yAxis": {
|
||||
"type": 'value',
|
||||
"axisTick": {
|
||||
"show": false,
|
||||
},
|
||||
"axisLabel": {
|
||||
"color": '#666666'
|
||||
},
|
||||
"axisLine": {
|
||||
"lineStyle": {
|
||||
"color": '#CCCCCC'
|
||||
}
|
||||
},
|
||||
},
|
||||
"seriesTemplate": {
|
||||
"name": '',
|
||||
"type": 'line',
|
||||
"data": [],
|
||||
"areaStyle": {},
|
||||
"label": {
|
||||
"show": true,
|
||||
"color": "#666666",
|
||||
"position": 'top',
|
||||
},
|
||||
},
|
||||
},
|
||||
"pie": {
|
||||
"color": color,
|
||||
"title": {
|
||||
"text": ''
|
||||
},
|
||||
"tooltip": {
|
||||
"trigger": 'item'
|
||||
},
|
||||
"grid": {
|
||||
"top": 40,
|
||||
"bottom": 30,
|
||||
"right": 15,
|
||||
"left": 15
|
||||
},
|
||||
"legend": {
|
||||
"bottom": 'left',
|
||||
},
|
||||
"seriesTemplate": {
|
||||
"name": '',
|
||||
"type": 'pie',
|
||||
"data": [],
|
||||
"radius": '50%',
|
||||
"label": {
|
||||
"show": true,
|
||||
"color": "#666666",
|
||||
"position": 'top',
|
||||
},
|
||||
},
|
||||
},
|
||||
"ring": {
|
||||
"color": color,
|
||||
"title": {
|
||||
"text": ''
|
||||
},
|
||||
"tooltip": {
|
||||
"trigger": 'item'
|
||||
},
|
||||
"grid": {
|
||||
"top": 40,
|
||||
"bottom": 30,
|
||||
"right": 15,
|
||||
"left": 15
|
||||
},
|
||||
"legend": {
|
||||
"bottom": 'left',
|
||||
},
|
||||
"seriesTemplate": {
|
||||
"name": '',
|
||||
"type": 'pie',
|
||||
"data": [],
|
||||
"radius": ['40%', '70%'],
|
||||
"avoidLabelOverlap": false,
|
||||
"label": {
|
||||
"show": true,
|
||||
"color": "#666666",
|
||||
"position": 'top',
|
||||
},
|
||||
"labelLine": {
|
||||
"show": true
|
||||
},
|
||||
},
|
||||
},
|
||||
"rose": {
|
||||
"color": color,
|
||||
"title": {
|
||||
"text": ''
|
||||
},
|
||||
"tooltip": {
|
||||
"trigger": 'item'
|
||||
},
|
||||
"legend": {
|
||||
"top": 'bottom'
|
||||
},
|
||||
"seriesTemplate": {
|
||||
"name": '',
|
||||
"type": 'pie',
|
||||
"data": [],
|
||||
"radius": "55%",
|
||||
"center": ['50%', '50%'],
|
||||
"roseType": 'area',
|
||||
},
|
||||
},
|
||||
"funnel": {
|
||||
"color": color,
|
||||
"title": {
|
||||
"text": ''
|
||||
},
|
||||
"tooltip": {
|
||||
"trigger": 'item',
|
||||
"formatter": "{b} : {c}%"
|
||||
},
|
||||
"legend": {
|
||||
"top": 'bottom'
|
||||
},
|
||||
"seriesTemplate": {
|
||||
"name": '',
|
||||
"type": 'funnel',
|
||||
"left": '10%',
|
||||
"top": 60,
|
||||
"bottom": 60,
|
||||
"width": '80%',
|
||||
"min": 0,
|
||||
"max": 100,
|
||||
"minSize": '0%',
|
||||
"maxSize": '100%',
|
||||
"sort": 'descending',
|
||||
"gap": 2,
|
||||
"label": {
|
||||
"show": true,
|
||||
"position": 'inside'
|
||||
},
|
||||
"labelLine": {
|
||||
"length": 10,
|
||||
"lineStyle": {
|
||||
"width": 1,
|
||||
"type": 'solid'
|
||||
}
|
||||
},
|
||||
"itemStyle": {
|
||||
"bordercolor": '#fff',
|
||||
"borderwidth": 1
|
||||
},
|
||||
"emphasis": {
|
||||
"label": {
|
||||
"fontSize": 20
|
||||
}
|
||||
},
|
||||
"data": [],
|
||||
},
|
||||
},
|
||||
"gauge": {
|
||||
"color": color,
|
||||
"tooltip": {
|
||||
"formatter": '{a} <br/>{b} : {c}%'
|
||||
},
|
||||
"seriesTemplate": {
|
||||
"name": '业务指标',
|
||||
"type": 'gauge',
|
||||
"detail": {"formatter": '{value}%'},
|
||||
"data": [{"value": 50, "name": '完成率'}]
|
||||
},
|
||||
},
|
||||
"candle": {
|
||||
"xAxis": {
|
||||
"data": []
|
||||
},
|
||||
"yAxis": {},
|
||||
"color": color,
|
||||
"title": {
|
||||
"text": ''
|
||||
},
|
||||
"dataZoom": [{
|
||||
"type": 'inside',
|
||||
"xAxisIndex": [0, 1],
|
||||
"start": 10,
|
||||
"end": 100
|
||||
},
|
||||
{
|
||||
"show": true,
|
||||
"xAxisIndex": [0, 1],
|
||||
"type": 'slider',
|
||||
"bottom": 10,
|
||||
"start": 10,
|
||||
"end": 100
|
||||
}
|
||||
],
|
||||
"seriesTemplate": {
|
||||
"name": '',
|
||||
"type": 'k',
|
||||
"data": [],
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
export default cfe;
|
|
@ -0,0 +1,606 @@
|
|||
/*
|
||||
* uCharts®
|
||||
* 高性能跨平台图表库,支持H5、APP、小程序(微信/支付宝/百度/头条/QQ/360)、Vue、Taro等支持canvas的框架平台
|
||||
* Copyright (c) 2021 QIUN®秋云 https://www.ucharts.cn All rights reserved.
|
||||
* Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
|
||||
* 复制使用请保留本段注释,感谢支持开源!
|
||||
*
|
||||
* uCharts®官方网站
|
||||
* https://www.uCharts.cn
|
||||
*
|
||||
* 开源地址:
|
||||
* https://gitee.com/uCharts/uCharts
|
||||
*
|
||||
* uni-app插件市场地址:
|
||||
* http://ext.dcloud.net.cn/plugin?id=271
|
||||
*
|
||||
*/
|
||||
|
||||
// 主题颜色配置:如每个图表类型需要不同主题,请在对应图表类型上更改color属性
|
||||
const color = ['#1890FF', '#91CB74', '#FAC858', '#EE6666', '#73C0DE', '#3CA272', '#FC8452', '#9A60B4', '#ea7ccc'];
|
||||
|
||||
//事件转换函数,主要用作格式化x轴为时间轴,根据需求自行修改
|
||||
const formatDateTime = (timeStamp, returnType)=>{
|
||||
var date = new Date();
|
||||
date.setTime(timeStamp * 1000);
|
||||
var y = date.getFullYear();
|
||||
var m = date.getMonth() + 1;
|
||||
m = m < 10 ? ('0' + m) : m;
|
||||
var d = date.getDate();
|
||||
d = d < 10 ? ('0' + d) : d;
|
||||
var h = date.getHours();
|
||||
h = h < 10 ? ('0' + h) : h;
|
||||
var minute = date.getMinutes();
|
||||
var second = date.getSeconds();
|
||||
minute = minute < 10 ? ('0' + minute) : minute;
|
||||
second = second < 10 ? ('0' + second) : second;
|
||||
if(returnType == 'full'){return y + '-' + m + '-' + d + ' '+ h +':' + minute + ':' + second;}
|
||||
if(returnType == 'y-m-d'){return y + '-' + m + '-' + d;}
|
||||
if(returnType == 'h:m'){return h +':' + minute;}
|
||||
if(returnType == 'h:m:s'){return h +':' + minute +':' + second;}
|
||||
return [y, m, d, h, minute, second];
|
||||
}
|
||||
|
||||
const cfu = {
|
||||
//demotype为自定义图表类型,一般不需要自定义图表类型,只需要改根节点上对应的类型即可
|
||||
"type":["pie","ring","rose","word","funnel","map","arcbar","line","column","mount","bar","area","radar","gauge","candle","mix","tline","tarea","scatter","bubble","demotype"],
|
||||
"range":["饼状图","圆环图","玫瑰图","词云图","漏斗图","地图","圆弧进度条","折线图","柱状图","山峰图","条状图","区域图","雷达图","仪表盘","K线图","混合图","时间轴折线","时间轴区域","散点图","气泡图","自定义类型"],
|
||||
//增加自定义图表类型,如果需要categories,请在这里加入您的图表类型,例如最后的"demotype"
|
||||
//自定义类型时需要注意"tline","tarea","scatter","bubble"等时间轴(矢量x轴)类图表,没有categories,不需要加入categories
|
||||
"categories":["line","column","mount","bar","area","radar","gauge","candle","mix","demotype"],
|
||||
//instance为实例变量承载属性,不要删除
|
||||
"instance":{},
|
||||
//option为opts及eopts承载属性,不要删除
|
||||
"option":{},
|
||||
//下面是自定义format配置,因除H5端外的其他端无法通过props传递函数,只能通过此属性对应下标的方式来替换
|
||||
"formatter":{
|
||||
"yAxisDemo1":function(val, index, opts){return val+'元'},
|
||||
"yAxisDemo2":function(val, index, opts){return val.toFixed(2)},
|
||||
"xAxisDemo1":function(val, index, opts){return val+'年';},
|
||||
"xAxisDemo2":function(val, index, opts){return formatDateTime(val,'h:m')},
|
||||
"seriesDemo1":function(val, index, series, opts){return val+'元'},
|
||||
"tooltipDemo1":function(item, category, index, opts){
|
||||
if(index==0){
|
||||
return '随便用'+item.data+'年'
|
||||
}else{
|
||||
return '其他我没改'+item.data+'天'
|
||||
}
|
||||
},
|
||||
"pieDemo":function(val, index, series, opts){
|
||||
if(index !== undefined){
|
||||
return series[index].name+':'+series[index].data+'元'
|
||||
}
|
||||
},
|
||||
},
|
||||
//这里演示了自定义您的图表类型的option,可以随意命名,之后在组件上 type="demotype" 后,组件会调用这个花括号里的option,如果组件上还存在opts参数,会将demotype与opts中option合并后渲染图表。
|
||||
"demotype":{
|
||||
//我这里把曲线图当做了自定义图表类型,您可以根据需要随意指定类型或配置
|
||||
"type": "line",
|
||||
"color": color,
|
||||
"padding": [15,10,0,15],
|
||||
"xAxis": {
|
||||
"disableGrid": true,
|
||||
},
|
||||
"yAxis": {
|
||||
"gridType": "dash",
|
||||
"dashLength": 2,
|
||||
},
|
||||
"legend": {
|
||||
},
|
||||
"extra": {
|
||||
"line": {
|
||||
"type": "curve",
|
||||
"width": 2
|
||||
},
|
||||
}
|
||||
},
|
||||
//下面是自定义配置,请添加项目所需的通用配置
|
||||
"pie":{
|
||||
"type": "pie",
|
||||
"color": color,
|
||||
"padding": [5,5,5,5],
|
||||
"extra": {
|
||||
"pie": {
|
||||
"activeOpacity": 0.5,
|
||||
"activeRadius": 10,
|
||||
"offsetAngle": 0,
|
||||
"labelWidth": 15,
|
||||
"border": true,
|
||||
"borderWidth": 3,
|
||||
"borderColor": "#FFFFFF"
|
||||
},
|
||||
}
|
||||
},
|
||||
"ring":{
|
||||
"type": "ring",
|
||||
"color": color,
|
||||
"padding": [5,5,5,5],
|
||||
"rotate": false,
|
||||
"dataLabel": true,
|
||||
"legend": {
|
||||
"show": true,
|
||||
"position": "right",
|
||||
"lineHeight": 25,
|
||||
},
|
||||
"title": {
|
||||
"name": "收益率",
|
||||
"fontSize": 15,
|
||||
"color": "#666666"
|
||||
},
|
||||
"subtitle": {
|
||||
"name": "70%",
|
||||
"fontSize": 25,
|
||||
"color": "#7cb5ec"
|
||||
},
|
||||
"extra": {
|
||||
"ring": {
|
||||
"ringWidth":30,
|
||||
"activeOpacity": 0.5,
|
||||
"activeRadius": 10,
|
||||
"offsetAngle": 0,
|
||||
"labelWidth": 15,
|
||||
"border": true,
|
||||
"borderWidth": 3,
|
||||
"borderColor": "#FFFFFF"
|
||||
},
|
||||
},
|
||||
},
|
||||
"rose":{
|
||||
"type": "rose",
|
||||
"color": color,
|
||||
"padding": [5,5,5,5],
|
||||
"legend": {
|
||||
"show": true,
|
||||
"position": "left",
|
||||
"lineHeight": 25,
|
||||
},
|
||||
"extra": {
|
||||
"rose": {
|
||||
"type": "area",
|
||||
"minRadius": 50,
|
||||
"activeOpacity": 0.5,
|
||||
"activeRadius": 10,
|
||||
"offsetAngle": 0,
|
||||
"labelWidth": 15,
|
||||
"border": false,
|
||||
"borderWidth": 2,
|
||||
"borderColor": "#FFFFFF"
|
||||
},
|
||||
}
|
||||
},
|
||||
"word":{
|
||||
"type": "word",
|
||||
"color": color,
|
||||
"extra": {
|
||||
"word": {
|
||||
"type": "normal",
|
||||
"autoColors": false
|
||||
}
|
||||
}
|
||||
},
|
||||
"funnel":{
|
||||
"type": "funnel",
|
||||
"color": color,
|
||||
"padding": [15,15,0,15],
|
||||
"extra": {
|
||||
"funnel": {
|
||||
"activeOpacity": 0.3,
|
||||
"activeWidth": 10,
|
||||
"border": true,
|
||||
"borderWidth": 2,
|
||||
"borderColor": "#FFFFFF",
|
||||
"fillOpacity": 1,
|
||||
"labelAlign": "right"
|
||||
},
|
||||
}
|
||||
},
|
||||
"map":{
|
||||
"type": "map",
|
||||
"color": color,
|
||||
"padding": [0,0,0,0],
|
||||
"dataLabel": true,
|
||||
"extra": {
|
||||
"map": {
|
||||
"border": true,
|
||||
"borderWidth": 1,
|
||||
"borderColor": "#666666",
|
||||
"fillOpacity": 0.6,
|
||||
"activeBorderColor": "#F04864",
|
||||
"activeFillColor": "#FACC14",
|
||||
"activeFillOpacity": 1
|
||||
},
|
||||
}
|
||||
},
|
||||
"arcbar":{
|
||||
"type": "arcbar",
|
||||
"color": color,
|
||||
"title": {
|
||||
"name": "百分比",
|
||||
"fontSize": 25,
|
||||
"color": "#00FF00"
|
||||
},
|
||||
"subtitle": {
|
||||
"name": "默认标题",
|
||||
"fontSize": 15,
|
||||
"color": "#666666"
|
||||
},
|
||||
"extra": {
|
||||
"arcbar": {
|
||||
"type": "default",
|
||||
"width": 12,
|
||||
"backgroundColor": "#E9E9E9",
|
||||
"startAngle": 0.75,
|
||||
"endAngle": 0.25,
|
||||
"gap": 2
|
||||
}
|
||||
}
|
||||
},
|
||||
"line":{
|
||||
"type": "line",
|
||||
"color": color,
|
||||
"padding": [15,10,0,15],
|
||||
"xAxis": {
|
||||
"disableGrid": true,
|
||||
},
|
||||
"yAxis": {
|
||||
"gridType": "dash",
|
||||
"dashLength": 2,
|
||||
},
|
||||
"legend": {
|
||||
},
|
||||
"extra": {
|
||||
"line": {
|
||||
"type": "straight",
|
||||
"width": 2,
|
||||
"activeType": "hollow"
|
||||
},
|
||||
}
|
||||
},
|
||||
"tline":{
|
||||
"type": "line",
|
||||
"color": color,
|
||||
"padding": [15,10,0,15],
|
||||
"xAxis": {
|
||||
"disableGrid": false,
|
||||
"boundaryGap":"justify",
|
||||
},
|
||||
"yAxis": {
|
||||
"gridType": "dash",
|
||||
"dashLength": 2,
|
||||
"data":[
|
||||
{
|
||||
"min":0,
|
||||
"max":80
|
||||
}
|
||||
]
|
||||
},
|
||||
"legend": {
|
||||
},
|
||||
"extra": {
|
||||
"line": {
|
||||
"type": "curve",
|
||||
"width": 2,
|
||||
"activeType": "hollow"
|
||||
},
|
||||
}
|
||||
},
|
||||
"tarea":{
|
||||
"type": "area",
|
||||
"color": color,
|
||||
"padding": [15,10,0,15],
|
||||
"xAxis": {
|
||||
"disableGrid": true,
|
||||
"boundaryGap":"justify",
|
||||
},
|
||||
"yAxis": {
|
||||
"gridType": "dash",
|
||||
"dashLength": 2,
|
||||
"data":[
|
||||
{
|
||||
"min":0,
|
||||
"max":80
|
||||
}
|
||||
]
|
||||
},
|
||||
"legend": {
|
||||
},
|
||||
"extra": {
|
||||
"area": {
|
||||
"type": "curve",
|
||||
"opacity": 0.2,
|
||||
"addLine": true,
|
||||
"width": 2,
|
||||
"gradient": true,
|
||||
"activeType": "hollow"
|
||||
},
|
||||
}
|
||||
},
|
||||
"column":{
|
||||
"type": "column",
|
||||
"color": color,
|
||||
"padding": [15,15,0,5],
|
||||
"xAxis": {
|
||||
"disableGrid": true,
|
||||
},
|
||||
"yAxis": {
|
||||
"data":[{"min":0}]
|
||||
},
|
||||
"legend": {
|
||||
},
|
||||
"extra": {
|
||||
"column": {
|
||||
"type": "group",
|
||||
"width": 30,
|
||||
"activeBgColor": "#000000",
|
||||
"activeBgOpacity": 0.08
|
||||
},
|
||||
}
|
||||
},
|
||||
"mount":{
|
||||
"type": "mount",
|
||||
"color": color,
|
||||
"padding": [15,15,0,5],
|
||||
"xAxis": {
|
||||
"disableGrid": true,
|
||||
},
|
||||
"yAxis": {
|
||||
"data":[{"min":0}]
|
||||
},
|
||||
"legend": {
|
||||
},
|
||||
"extra": {
|
||||
"mount": {
|
||||
"type": "mount",
|
||||
"widthRatio": 1.5,
|
||||
},
|
||||
}
|
||||
},
|
||||
"bar":{
|
||||
"type": "bar",
|
||||
"color": color,
|
||||
"padding": [15,30,0,5],
|
||||
"xAxis": {
|
||||
"boundaryGap":"justify",
|
||||
"disableGrid":false,
|
||||
"min":0,
|
||||
"axisLine":false
|
||||
},
|
||||
"yAxis": {
|
||||
},
|
||||
"legend": {
|
||||
},
|
||||
"extra": {
|
||||
"bar": {
|
||||
"type": "group",
|
||||
"width": 30,
|
||||
"meterBorde": 1,
|
||||
"meterFillColor": "#FFFFFF",
|
||||
"activeBgColor": "#000000",
|
||||
"activeBgOpacity": 0.08
|
||||
},
|
||||
}
|
||||
},
|
||||
"area":{
|
||||
"type": "area",
|
||||
"color": color,
|
||||
"padding": [15,15,0,15],
|
||||
"xAxis": {
|
||||
"disableGrid": true,
|
||||
},
|
||||
"yAxis": {
|
||||
"gridType": "dash",
|
||||
"dashLength": 2,
|
||||
},
|
||||
"legend": {
|
||||
},
|
||||
"extra": {
|
||||
"area": {
|
||||
"type": "straight",
|
||||
"opacity": 0.2,
|
||||
"addLine": true,
|
||||
"width": 2,
|
||||
"gradient": false,
|
||||
"activeType": "hollow"
|
||||
},
|
||||
}
|
||||
},
|
||||
"radar":{
|
||||
"type": "radar",
|
||||
"color": color,
|
||||
"padding": [5,5,5,5],
|
||||
"dataLabel": false,
|
||||
"legend": {
|
||||
"show": true,
|
||||
"position": "right",
|
||||
"lineHeight": 25,
|
||||
},
|
||||
"extra": {
|
||||
"radar": {
|
||||
"gridType": "radar",
|
||||
"gridColor": "#CCCCCC",
|
||||
"gridCount": 3,
|
||||
"opacity": 0.2,
|
||||
"max": 200,
|
||||
"labelShow": true
|
||||
},
|
||||
}
|
||||
},
|
||||
"gauge":{
|
||||
"type": "gauge",
|
||||
"color": color,
|
||||
"title": {
|
||||
"name": "66Km/H",
|
||||
"fontSize": 25,
|
||||
"color": "#2fc25b",
|
||||
"offsetY": 50
|
||||
},
|
||||
"subtitle": {
|
||||
"name": "实时速度",
|
||||
"fontSize": 15,
|
||||
"color": "#1890ff",
|
||||
"offsetY": -50
|
||||
},
|
||||
"extra": {
|
||||
"gauge": {
|
||||
"type": "default",
|
||||
"width": 30,
|
||||
"labelColor": "#666666",
|
||||
"startAngle": 0.75,
|
||||
"endAngle": 0.25,
|
||||
"startNumber": 0,
|
||||
"endNumber": 100,
|
||||
"labelFormat": "",
|
||||
"splitLine": {
|
||||
"fixRadius": 0,
|
||||
"splitNumber": 10,
|
||||
"width": 30,
|
||||
"color": "#FFFFFF",
|
||||
"childNumber": 5,
|
||||
"childWidth": 12
|
||||
},
|
||||
"pointer": {
|
||||
"width": 24,
|
||||
"color": "auto"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"candle":{
|
||||
"type": "candle",
|
||||
"color": color,
|
||||
"padding": [15,15,0,15],
|
||||
"enableScroll": true,
|
||||
"enableMarkLine": true,
|
||||
"dataLabel": false,
|
||||
"xAxis": {
|
||||
"labelCount": 4,
|
||||
"itemCount": 40,
|
||||
"disableGrid": true,
|
||||
"gridColor": "#CCCCCC",
|
||||
"gridType": "solid",
|
||||
"dashLength": 4,
|
||||
"scrollShow": true,
|
||||
"scrollAlign": "left",
|
||||
"scrollColor": "#A6A6A6",
|
||||
"scrollBackgroundColor": "#EFEBEF"
|
||||
},
|
||||
"yAxis": {
|
||||
},
|
||||
"legend": {
|
||||
},
|
||||
"extra": {
|
||||
"candle": {
|
||||
"color": {
|
||||
"upLine": "#f04864",
|
||||
"upFill": "#f04864",
|
||||
"downLine": "#2fc25b",
|
||||
"downFill": "#2fc25b"
|
||||
},
|
||||
"average": {
|
||||
"show": true,
|
||||
"name": ["MA5","MA10","MA30"],
|
||||
"day": [5,10,20],
|
||||
"color": ["#1890ff","#2fc25b","#facc14"]
|
||||
}
|
||||
},
|
||||
"markLine": {
|
||||
"type": "dash",
|
||||
"dashLength": 5,
|
||||
"data": [
|
||||
{
|
||||
"value": 2150,
|
||||
"lineColor": "#f04864",
|
||||
"showLabel": true
|
||||
},
|
||||
{
|
||||
"value": 2350,
|
||||
"lineColor": "#f04864",
|
||||
"showLabel": true
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
"mix":{
|
||||
"type": "mix",
|
||||
"color": color,
|
||||
"padding": [15,15,0,15],
|
||||
"xAxis": {
|
||||
"disableGrid": true,
|
||||
},
|
||||
"yAxis": {
|
||||
"disabled": false,
|
||||
"disableGrid": false,
|
||||
"splitNumber": 5,
|
||||
"gridType": "dash",
|
||||
"dashLength": 4,
|
||||
"gridColor": "#CCCCCC",
|
||||
"padding": 10,
|
||||
"showTitle": true,
|
||||
"data": []
|
||||
},
|
||||
"legend": {
|
||||
},
|
||||
"extra": {
|
||||
"mix": {
|
||||
"column": {
|
||||
"width": 20
|
||||
}
|
||||
},
|
||||
}
|
||||
},
|
||||
"scatter":{
|
||||
"type": "scatter",
|
||||
"color":color,
|
||||
"padding":[15,15,0,15],
|
||||
"dataLabel":false,
|
||||
"xAxis": {
|
||||
"disableGrid": false,
|
||||
"gridType":"dash",
|
||||
"splitNumber":5,
|
||||
"boundaryGap":"justify",
|
||||
"min":0
|
||||
},
|
||||
"yAxis": {
|
||||
"disableGrid": false,
|
||||
"gridType":"dash",
|
||||
},
|
||||
"legend": {
|
||||
},
|
||||
"extra": {
|
||||
"scatter": {
|
||||
},
|
||||
}
|
||||
},
|
||||
"bubble":{
|
||||
"type": "bubble",
|
||||
"color":color,
|
||||
"padding":[15,15,0,15],
|
||||
"xAxis": {
|
||||
"disableGrid": false,
|
||||
"gridType":"dash",
|
||||
"splitNumber":5,
|
||||
"boundaryGap":"justify",
|
||||
"min":0,
|
||||
"max":250
|
||||
},
|
||||
"yAxis": {
|
||||
"disableGrid": false,
|
||||
"gridType":"dash",
|
||||
"data":[{
|
||||
"min":0,
|
||||
"max":150
|
||||
}]
|
||||
},
|
||||
"legend": {
|
||||
},
|
||||
"extra": {
|
||||
"bubble": {
|
||||
"border":2,
|
||||
"opacity": 0.5,
|
||||
},
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
export default cfu;
|
|
@ -0,0 +1,5 @@
|
|||
# uCharts JSSDK说明
|
||||
1、如不使用uCharts组件,可直接引用u-charts.js,打包编译后会`自动压缩`,压缩后体积约为`120kb`。
|
||||
2、如果120kb的体积仍需压缩,请手到uCharts官网通过在线定制选择您需要的图表。
|
||||
3、config-ucharts.js为uCharts组件的用户配置文件,升级前请`自行备份config-ucharts.js`文件,以免被强制覆盖。
|
||||
4、config-echarts.js为ECharts组件的用户配置文件,升级前请`自行备份config-echarts.js`文件,以免被强制覆盖。
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because one or more lines are too long
|
@ -0,0 +1,201 @@
|
|||
Apache License
|
||||
Version 2.0, January 2004
|
||||
http://www.apache.org/licenses/
|
||||
|
||||
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
||||
|
||||
1. Definitions.
|
||||
|
||||
"License" shall mean the terms and conditions for use, reproduction,
|
||||
and distribution as defined by Sections 1 through 9 of this document.
|
||||
|
||||
"Licensor" shall mean the copyright owner or entity authorized by
|
||||
the copyright owner that is granting the License.
|
||||
|
||||
"Legal Entity" shall mean the union of the acting entity and all
|
||||
other entities that control, are controlled by, or are under common
|
||||
control with that entity. For the purposes of this definition,
|
||||
"control" means (i) the power, direct or indirect, to cause the
|
||||
direction or management of such entity, whether by contract or
|
||||
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
||||
outstanding shares, or (iii) beneficial ownership of such entity.
|
||||
|
||||
"You" (or "Your") shall mean an individual or Legal Entity
|
||||
exercising permissions granted by this License.
|
||||
|
||||
"Source" form shall mean the preferred form for making modifications,
|
||||
including but not limited to software source code, documentation
|
||||
source, and configuration files.
|
||||
|
||||
"Object" form shall mean any form resulting from mechanical
|
||||
transformation or translation of a Source form, including but
|
||||
not limited to compiled object code, generated documentation,
|
||||
and conversions to other media types.
|
||||
|
||||
"Work" shall mean the work of authorship, whether in Source or
|
||||
Object form, made available under the License, as indicated by a
|
||||
copyright notice that is included in or attached to the work
|
||||
(an example is provided in the Appendix below).
|
||||
|
||||
"Derivative Works" shall mean any work, whether in Source or Object
|
||||
form, that is based on (or derived from) the Work and for which the
|
||||
editorial revisions, annotations, elaborations, or other modifications
|
||||
represent, as a whole, an original work of authorship. For the purposes
|
||||
of this License, Derivative Works shall not include works that remain
|
||||
separable from, or merely link (or bind by name) to the interfaces of,
|
||||
the Work and Derivative Works thereof.
|
||||
|
||||
"Contribution" shall mean any work of authorship, including
|
||||
the original version of the Work and any modifications or additions
|
||||
to that Work or Derivative Works thereof, that is intentionally
|
||||
submitted to Licensor for inclusion in the Work by the copyright owner
|
||||
or by an individual or Legal Entity authorized to submit on behalf of
|
||||
the copyright owner. For the purposes of this definition, "submitted"
|
||||
means any form of electronic, verbal, or written communication sent
|
||||
to the Licensor or its representatives, including but not limited to
|
||||
communication on electronic mailing lists, source code control systems,
|
||||
and issue tracking systems that are managed by, or on behalf of, the
|
||||
Licensor for the purpose of discussing and improving the Work, but
|
||||
excluding communication that is conspicuously marked or otherwise
|
||||
designated in writing by the copyright owner as "Not a Contribution."
|
||||
|
||||
"Contributor" shall mean Licensor and any individual or Legal Entity
|
||||
on behalf of whom a Contribution has been received by Licensor and
|
||||
subsequently incorporated within the Work.
|
||||
|
||||
2. Grant of Copyright License. Subject to the terms and conditions of
|
||||
this License, each Contributor hereby grants to You a perpetual,
|
||||
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||
copyright license to reproduce, prepare Derivative Works of,
|
||||
publicly display, publicly perform, sublicense, and distribute the
|
||||
Work and such Derivative Works in Source or Object form.
|
||||
|
||||
3. Grant of Patent License. Subject to the terms and conditions of
|
||||
this License, each Contributor hereby grants to You a perpetual,
|
||||
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||
(except as stated in this section) patent license to make, have made,
|
||||
use, offer to sell, sell, import, and otherwise transfer the Work,
|
||||
where such license applies only to those patent claims licensable
|
||||
by such Contributor that are necessarily infringed by their
|
||||
Contribution(s) alone or by combination of their Contribution(s)
|
||||
with the Work to which such Contribution(s) was submitted. If You
|
||||
institute patent litigation against any entity (including a
|
||||
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
||||
or a Contribution incorporated within the Work constitutes direct
|
||||
or contributory patent infringement, then any patent licenses
|
||||
granted to You under this License for that Work shall terminate
|
||||
as of the date such litigation is filed.
|
||||
|
||||
4. Redistribution. You may reproduce and distribute copies of the
|
||||
Work or Derivative Works thereof in any medium, with or without
|
||||
modifications, and in Source or Object form, provided that You
|
||||
meet the following conditions:
|
||||
|
||||
(a) You must give any other recipients of the Work or
|
||||
Derivative Works a copy of this License; and
|
||||
|
||||
(b) You must cause any modified files to carry prominent notices
|
||||
stating that You changed the files; and
|
||||
|
||||
(c) You must retain, in the Source form of any Derivative Works
|
||||
that You distribute, all copyright, patent, trademark, and
|
||||
attribution notices from the Source form of the Work,
|
||||
excluding those notices that do not pertain to any part of
|
||||
the Derivative Works; and
|
||||
|
||||
(d) If the Work includes a "NOTICE" text file as part of its
|
||||
distribution, then any Derivative Works that You distribute must
|
||||
include a readable copy of the attribution notices contained
|
||||
within such NOTICE file, excluding those notices that do not
|
||||
pertain to any part of the Derivative Works, in at least one
|
||||
of the following places: within a NOTICE text file distributed
|
||||
as part of the Derivative Works; within the Source form or
|
||||
documentation, if provided along with the Derivative Works; or,
|
||||
within a display generated by the Derivative Works, if and
|
||||
wherever such third-party notices normally appear. The contents
|
||||
of the NOTICE file are for informational purposes only and
|
||||
do not modify the License. You may add Your own attribution
|
||||
notices within Derivative Works that You distribute, alongside
|
||||
or as an addendum to the NOTICE text from the Work, provided
|
||||
that such additional attribution notices cannot be construed
|
||||
as modifying the License.
|
||||
|
||||
You may add Your own copyright statement to Your modifications and
|
||||
may provide additional or different license terms and conditions
|
||||
for use, reproduction, or distribution of Your modifications, or
|
||||
for any such Derivative Works as a whole, provided Your use,
|
||||
reproduction, and distribution of the Work otherwise complies with
|
||||
the conditions stated in this License.
|
||||
|
||||
5. Submission of Contributions. Unless You explicitly state otherwise,
|
||||
any Contribution intentionally submitted for inclusion in the Work
|
||||
by You to the Licensor shall be under the terms and conditions of
|
||||
this License, without any additional terms or conditions.
|
||||
Notwithstanding the above, nothing herein shall supersede or modify
|
||||
the terms of any separate license agreement you may have executed
|
||||
with Licensor regarding such Contributions.
|
||||
|
||||
6. Trademarks. This License does not grant permission to use the trade
|
||||
names, trademarks, service marks, or product names of the Licensor,
|
||||
except as required for reasonable and customary use in describing the
|
||||
origin of the Work and reproducing the content of the NOTICE file.
|
||||
|
||||
7. Disclaimer of Warranty. Unless required by applicable law or
|
||||
agreed to in writing, Licensor provides the Work (and each
|
||||
Contributor provides its Contributions) on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
||||
implied, including, without limitation, any warranties or conditions
|
||||
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
||||
PARTICULAR PURPOSE. You are solely responsible for determining the
|
||||
appropriateness of using or redistributing the Work and assume any
|
||||
risks associated with Your exercise of permissions under this License.
|
||||
|
||||
8. Limitation of Liability. In no event and under no legal theory,
|
||||
whether in tort (including negligence), contract, or otherwise,
|
||||
unless required by applicable law (such as deliberate and grossly
|
||||
negligent acts) or agreed to in writing, shall any Contributor be
|
||||
liable to You for damages, including any direct, indirect, special,
|
||||
incidental, or consequential damages of any character arising as a
|
||||
result of this License or out of the use or inability to use the
|
||||
Work (including but not limited to damages for loss of goodwill,
|
||||
work stoppage, computer failure or malfunction, or any and all
|
||||
other commercial damages or losses), even if such Contributor
|
||||
has been advised of the possibility of such damages.
|
||||
|
||||
9. Accepting Warranty or Additional Liability. While redistributing
|
||||
the Work or Derivative Works thereof, You may choose to offer,
|
||||
and charge a fee for, acceptance of support, warranty, indemnity,
|
||||
or other liability obligations and/or rights consistent with this
|
||||
License. However, in accepting such obligations, You may act only
|
||||
on Your own behalf and on Your sole responsibility, not on behalf
|
||||
of any other Contributor, and only if You agree to indemnify,
|
||||
defend, and hold each Contributor harmless for any liability
|
||||
incurred by, or claims asserted against, such Contributor by reason
|
||||
of your accepting any such warranty or additional liability.
|
||||
|
||||
END OF TERMS AND CONDITIONS
|
||||
|
||||
APPENDIX: How to apply the Apache License to your work.
|
||||
|
||||
To apply the Apache License to your work, attach the following
|
||||
boilerplate notice, with the fields enclosed by brackets "[]"
|
||||
replaced with your own identifying information. (Don't include
|
||||
the brackets!) The text should be enclosed in the appropriate
|
||||
comment syntax for the file format. We also recommend that a
|
||||
file or class name and description of purpose be included on the
|
||||
same "printed page" as the copyright notice for easier
|
||||
identification within third-party archives.
|
||||
|
||||
Copyright [yyyy] [name of copyright owner]
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
|
@ -0,0 +1,80 @@
|
|||
{
|
||||
"id": "qiun-data-charts",
|
||||
"displayName": "秋云 ucharts echarts 高性能跨全端图表组件",
|
||||
"version": "2.5.0-20230101",
|
||||
"description": "uCharts 新增正负柱状图!支持H5及APP用 ucharts echarts 渲染图表,uniapp可视化首选组件",
|
||||
"keywords": [
|
||||
"ucharts",
|
||||
"echarts",
|
||||
"f2",
|
||||
"图表",
|
||||
"可视化"
|
||||
],
|
||||
"repository": "https://gitee.com/uCharts/uCharts",
|
||||
"engines": {
|
||||
},
|
||||
"dcloudext": {
|
||||
"sale": {
|
||||
"regular": {
|
||||
"price": "0.00"
|
||||
},
|
||||
"sourcecode": {
|
||||
"price": "0.00"
|
||||
}
|
||||
},
|
||||
"contact": {
|
||||
"qq": "474119"
|
||||
},
|
||||
"declaration": {
|
||||
"ads": "无",
|
||||
"data": "插件不采集任何数据",
|
||||
"permissions": "无"
|
||||
},
|
||||
"npmurl": "https://www.npmjs.com/~qiun",
|
||||
"type": "component-vue"
|
||||
},
|
||||
"uni_modules": {
|
||||
"dependencies": [],
|
||||
"encrypt": [],
|
||||
"platforms": {
|
||||
"cloud": {
|
||||
"tcb": "y",
|
||||
"aliyun": "y"
|
||||
},
|
||||
"client": {
|
||||
"App": {
|
||||
"app-vue": "y",
|
||||
"app-nvue": "y"
|
||||
},
|
||||
"H5-mobile": {
|
||||
"Safari": "y",
|
||||
"Android Browser": "y",
|
||||
"微信浏览器(Android)": "y",
|
||||
"QQ浏览器(Android)": "y"
|
||||
},
|
||||
"H5-pc": {
|
||||
"Chrome": "y",
|
||||
"IE": "y",
|
||||
"Edge": "y",
|
||||
"Firefox": "y",
|
||||
"Safari": "y"
|
||||
},
|
||||
"小程序": {
|
||||
"微信": "y",
|
||||
"阿里": "y",
|
||||
"百度": "y",
|
||||
"字节跳动": "y",
|
||||
"QQ": "y"
|
||||
},
|
||||
"快应用": {
|
||||
"华为": "y",
|
||||
"联盟": "y"
|
||||
},
|
||||
"Vue": {
|
||||
"vue2": "y",
|
||||
"vue3": "y"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,84 @@
|
|||
![logo](https://img-blog.csdnimg.cn/4a276226973841468c1be356f8d9438b.png)
|
||||
|
||||
|
||||
[![star](https://gitee.com/uCharts/uCharts/badge/star.svg?theme=gvp)](https://gitee.com/uCharts/uCharts/stargazers)
|
||||
[![fork](https://gitee.com/uCharts/uCharts/badge/fork.svg?theme=gvp)](https://gitee.com/uCharts/uCharts/members)
|
||||
[![License](https://img.shields.io/badge/license-Apache%202-4EB1BA.svg)](https://www.apache.org/licenses/LICENSE-2.0.html)
|
||||
[![npm package](https://img.shields.io/npm/v/@qiun/ucharts.svg?style=flat-square)](https://www.npmjs.com/~qiun)
|
||||
|
||||
|
||||
## uCharts简介
|
||||
|
||||
`uCharts`是一款基于`canvas API`开发的适用于所有前端应用的图表库,开发者编写一套代码,可运行到 Web、iOS、Android(基于 uni-app / taro )、以及各种小程序(微信/支付宝/百度/头条/飞书/QQ/快手/钉钉/淘宝)、快应用等更多支持 canvas API 的平台。
|
||||
|
||||
## 官方网站
|
||||
|
||||
## [https://www.ucharts.cn](https://www.ucharts.cn)
|
||||
|
||||
## 快速体验
|
||||
|
||||
一套代码编到多个平台,依次扫描二维码,亲自体验uCharts图表跨平台效果!其他平台请自行编译。
|
||||
|
||||
![](https://www.ucharts.cn/images/web/guide/qrcode20220224.png)
|
||||
|
||||
![](https://img-blog.csdnimg.cn/7d0115593ff24ac39a224fb7c6ed72a4.png)
|
||||
|
||||
## 致开发者
|
||||
|
||||
感谢各位开发者`五年`来对秋云及uCharts的支持,uCharts的进步离不开各位开发者的鼓励与贡献。为更好的帮助各位开发者使用图表工具,我们推出了新版官网,增加了在线定制、问答社区、在线配置等一些增值服务,为确保您能更好的应用图表组件,建议您先`仔细阅读官网指南`以及`常见问题`,而不是下载下来`直接使用`。如仍然不能解决,请到`官网社区`或开通会员后加入`专属VIP会员群`提问将会很快得到回答。
|
||||
|
||||
## 视频教程
|
||||
|
||||
## [uCharts新手入门教程](https://www.bilibili.com/video/BV1qA411Q7se/?share_source=copy_web&vd_source=42a1242f9aaade6427736af69eb2e1d9)
|
||||
|
||||
|
||||
## 社群支持
|
||||
|
||||
uCharts官方拥有5个2000人的QQ群及专属VIP会员群支持,庞大的用户量证明我们一直在努力,请各位放心使用!uCharts的开源图表组件的开发,团队付出了大量的时间与精力,经过四来的考验,不会有比较明显的bug,请各位放心使用。如果您有更好的想法,可以在`码云提交Pull Requests`以帮助更多开发者完成需求,再次感谢各位对uCharts的鼓励与支持!
|
||||
|
||||
#### 官方交流群
|
||||
- 交流群1:371774600(已满)
|
||||
- 交流群2:619841586(已满)
|
||||
- 交流群3:955340127(已满)
|
||||
- 交流群4:641669795(已满)
|
||||
- 交流群5:236294809(只能扫码加入)
|
||||
|
||||
![](https://www.ucharts.cn/images/web/qq5.jpg)
|
||||
|
||||
- 口令`uniapp`
|
||||
|
||||
#### 专属VIP会员群
|
||||
- 开通会员后详见【账号详情】页面中顶部的滚动通知
|
||||
- 口令`您的用户ID`
|
||||
|
||||
## 版权信息
|
||||
|
||||
uCharts始终坚持开源,遵循 [Apache Licence 2.0](https://www.apache.org/licenses/LICENSE-2.0.html) 开源协议,意味着您无需支付任何费用,即可将uCharts应用到您的产品中。
|
||||
|
||||
注意:这并不意味着您可以将uCharts应用到非法的领域,比如涉及赌博,暴力等方面。如因此产生纠纷或法律问题,uCharts相关方及秋云科技不承担任何责任。
|
||||
|
||||
## 合作伙伴
|
||||
|
||||
[![DIY官网](https://www.ucharts.cn/images/web/guide/links/diy-gw.png)](https://www.diygw.com/)
|
||||
[![HasChat](https://www.ucharts.cn/images/web/guide/links/haschat.png)](https://gitee.com/howcode/has-chat)
|
||||
[![uViewUI](https://www.ucharts.cn/images/web/guide/links/uView.png)](https://www.uviewui.com/)
|
||||
[![图鸟UI](https://www.ucharts.cn/images/web/guide/links/tuniao.png)](https://ext.dcloud.net.cn/plugin?id=7088)
|
||||
[![thorui](https://www.ucharts.cn/images/web/guide/links/thorui.png)](https://ext.dcloud.net.cn/publisher?id=202)
|
||||
[![FirstUI](https://www.ucharts.cn/images/web/guide/links/first.png)](https://www.firstui.cn/)
|
||||
[![nProUI](https://www.ucharts.cn/images/web/guide/links/nPro.png)](https://ext.dcloud.net.cn/plugin?id=5169)
|
||||
[![GraceUI](https://www.ucharts.cn/images/web/guide/links/grace.png)](https://www.graceui.com/)
|
||||
|
||||
|
||||
## 更新记录
|
||||
|
||||
详见官网指南中说明,[点击此处查看](https://www.ucharts.cn/v2/#/guide/index?id=100)
|
||||
|
||||
|
||||
## 相关链接
|
||||
- [uCharts官网](https://www.ucharts.cn)
|
||||
- [DCloud插件市场地址](https://ext.dcloud.net.cn/plugin?id=271)
|
||||
- [uCharts码云开源托管地址](https://gitee.com/uCharts/uCharts) [![star](https://gitee.com/uCharts/uCharts/badge/star.svg?theme=gvp)](https://gitee.com/uCharts/uCharts/stargazers)
|
||||
- [uCharts npm开源地址](https://www.ucharts.cn)
|
||||
- [ECharts官网](https://echarts.apache.org/zh/index.html)
|
||||
- [ECharts配置手册](https://echarts.apache.org/zh/option.html)
|
||||
- [图表组件在项目中的应用 ReportPlus数据报表](https://www.ucharts.cn/v2/#/layout/info?id=1)
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -1,3 +1,5 @@
|
|||
## 2.2.35(2024-09-21)
|
||||
- 修复 没有选中日期时点击确定直接报错的Bug [详情](https://ask.dcloud.net.cn/question/198168)
|
||||
## 2.2.34(2024-04-24)
|
||||
- 新增 日期点击事件,在点击日期时会触发该事件。
|
||||
## 2.2.33(2024-04-15)
|
||||
|
|
|
@ -698,11 +698,11 @@
|
|||
startString = getDateTime(this.start, this.hideSecond)
|
||||
}
|
||||
[startDate, startTime] = startString.split(' ')
|
||||
if (this.start && !dateCompare(this.start, this.tempRange.startDate)) {
|
||||
if (this.start && !dateCompare(this.start, `${this.tempRange.startDate} ${this.tempRange.startTime}`)) {
|
||||
startDateLaterRangeStartDate = true
|
||||
this.tempRange.startDate = startDate
|
||||
}
|
||||
if (this.start && !dateCompare(this.start, this.tempRange.endDate)) {
|
||||
if (this.start && !dateCompare(this.start, `${this.tempRange.endDate} ${this.tempRange.endTime}`)) {
|
||||
startDateLaterRangeEndDate = true
|
||||
this.tempRange.endDate = startDate
|
||||
}
|
||||
|
@ -717,11 +717,11 @@
|
|||
}
|
||||
[endDate, endTime] = endString.split(' ')
|
||||
|
||||
if (this.end && !dateCompare(this.tempRange.startDate, this.end)) {
|
||||
if (this.end && !dateCompare(`${this.tempRange.startDate} ${this.tempRange.startTime}`, this.end)) {
|
||||
endDateEarlierRangeStartDate = true
|
||||
this.tempRange.startDate = endDate
|
||||
}
|
||||
if (this.end && !dateCompare(this.tempRange.endDate, this.end)) {
|
||||
if (this.end && !dateCompare(`${this.tempRange.endDate} ${this.tempRange.endTime}`, this.end)) {
|
||||
endDateEarlierRangeEndDate = true
|
||||
this.tempRange.endDate = endDate
|
||||
}
|
||||
|
|
|
@ -182,8 +182,8 @@ class Calendar {
|
|||
if (!date) {
|
||||
date = new Date()
|
||||
}
|
||||
|
||||
return this.calendar.find(item => item.fullDate === this.getDateObj(date).fullDate)
|
||||
const res = this.calendar.find(item => item.fullDate === this.getDateObj(date).fullDate)
|
||||
return res ? res : this.getDateObj(date)
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"id": "uni-datetime-picker",
|
||||
"displayName": "uni-datetime-picker 日期选择器",
|
||||
"version": "2.2.34",
|
||||
"version": "2.2.35",
|
||||
"description": "uni-datetime-picker 日期时间选择器,支持日历,支持范围选择",
|
||||
"keywords": [
|
||||
"uni-datetime-picker",
|
||||
|
|
|
@ -0,0 +1,62 @@
|
|||
{
|
||||
"name": "uview-plus",
|
||||
"version": "3.2.14",
|
||||
"lockfileVersion": 3,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "uview-plus",
|
||||
"version": "3.2.14",
|
||||
"dependencies": {
|
||||
"clipboard": "^2.0.11",
|
||||
"dayjs": "^1.11.3",
|
||||
"uview-plus": "file:"
|
||||
},
|
||||
"engines": {
|
||||
"HBuilderX": "^3.1.0"
|
||||
}
|
||||
},
|
||||
"node_modules/clipboard": {
|
||||
"version": "2.0.11",
|
||||
"resolved": "https://registry.npmjs.org/clipboard/-/clipboard-2.0.11.tgz",
|
||||
"integrity": "sha512-C+0bbOqkezLIsmWSvlsXS0Q0bmkugu7jcfMIACB+RDEntIzQIkdr148we28AfSloQLRdZlYL/QYyrq05j/3Faw==",
|
||||
"dependencies": {
|
||||
"good-listener": "^1.2.2",
|
||||
"select": "^1.1.2",
|
||||
"tiny-emitter": "^2.0.0"
|
||||
}
|
||||
},
|
||||
"node_modules/dayjs": {
|
||||
"version": "1.11.13",
|
||||
"resolved": "https://registry.npmjs.org/dayjs/-/dayjs-1.11.13.tgz",
|
||||
"integrity": "sha512-oaMBel6gjolK862uaPQOVTA7q3TZhuSvuMQAAglQDOWYO9A91IrAOUJEyKVlqJlHE0vq5p5UXxzdPfMH/x6xNg=="
|
||||
},
|
||||
"node_modules/delegate": {
|
||||
"version": "3.2.0",
|
||||
"resolved": "https://registry.npmjs.org/delegate/-/delegate-3.2.0.tgz",
|
||||
"integrity": "sha512-IofjkYBZaZivn0V8nnsMJGBr4jVLxHDheKSW88PyxS5QC4Vo9ZbZVvhzlSxY87fVq3STR6r+4cGepyHkcWOQSw=="
|
||||
},
|
||||
"node_modules/good-listener": {
|
||||
"version": "1.2.2",
|
||||
"resolved": "https://registry.npmjs.org/good-listener/-/good-listener-1.2.2.tgz",
|
||||
"integrity": "sha512-goW1b+d9q/HIwbVYZzZ6SsTr4IgE+WA44A0GmPIQstuOrgsFcT7VEJ48nmr9GaRtNu0XTKacFLGnBPAM6Afouw==",
|
||||
"dependencies": {
|
||||
"delegate": "^3.1.2"
|
||||
}
|
||||
},
|
||||
"node_modules/select": {
|
||||
"version": "1.1.2",
|
||||
"resolved": "https://registry.npmjs.org/select/-/select-1.1.2.tgz",
|
||||
"integrity": "sha512-OwpTSOfy6xSs1+pwcNrv0RBMOzI39Lp3qQKUTPVVPRjCdNa5JH/oPRiqsesIskK8TVgmRiHwO4KXlV2Li9dANA=="
|
||||
},
|
||||
"node_modules/tiny-emitter": {
|
||||
"version": "2.1.0",
|
||||
"resolved": "https://registry.npmjs.org/tiny-emitter/-/tiny-emitter-2.1.0.tgz",
|
||||
"integrity": "sha512-NB6Dk1A9xgQPMoGqC5CVXn123gWyte215ONT5Pp5a0yt4nlEoO1ZWeCwpncaekPHXO60i47ihFnZPiRPjRMq4Q=="
|
||||
},
|
||||
"node_modules/uview-plus": {
|
||||
"resolved": "",
|
||||
"link": true
|
||||
}
|
||||
}
|
||||
}
|
|
@ -5,21 +5,21 @@
|
|||
"version": "3.2.14",
|
||||
"description": "uview-plus已兼容vue3,全面的组件和便捷的工具会让您信手拈来,如鱼得水",
|
||||
"keywords": [
|
||||
"uview",
|
||||
"uview-plus",
|
||||
"ui",
|
||||
"ui",
|
||||
"uni-app",
|
||||
"uni-app",
|
||||
"ui"
|
||||
],
|
||||
"main": "index.js",
|
||||
"uview",
|
||||
"uview-plus",
|
||||
"ui",
|
||||
"ui",
|
||||
"uni-app",
|
||||
"uni-app",
|
||||
"ui"
|
||||
],
|
||||
"main": "index.js",
|
||||
"repository": "https://github.com/ijry/uview-plus",
|
||||
"engines": {
|
||||
"HBuilderX": "^3.1.0"
|
||||
},
|
||||
"dcloudext": {
|
||||
"sale": {
|
||||
"dcloudext": {
|
||||
"sale": {
|
||||
"regular": {
|
||||
"price": "0.00"
|
||||
},
|
||||
|
@ -35,8 +35,8 @@
|
|||
"data": "无",
|
||||
"permissions": "无"
|
||||
},
|
||||
"npmurl": "https://www.npmjs.com/package/uview-plus",
|
||||
"type": "component-vue"
|
||||
"npmurl": "https://www.npmjs.com/package/uview-plus",
|
||||
"type": "component-vue"
|
||||
},
|
||||
"uni_modules": {
|
||||
"dependencies": [],
|
||||
|
@ -44,8 +44,8 @@
|
|||
"platforms": {
|
||||
"cloud": {
|
||||
"tcb": "y",
|
||||
"aliyun": "y",
|
||||
"alipay": "n"
|
||||
"aliyun": "y",
|
||||
"alipay": "n"
|
||||
},
|
||||
"client": {
|
||||
"Vue": {
|
||||
|
@ -85,9 +85,10 @@
|
|||
},
|
||||
"dependencies": {
|
||||
"clipboard": "^2.0.11",
|
||||
"dayjs": "^1.11.3"
|
||||
"dayjs": "^1.11.3",
|
||||
"uview-plus": "file:"
|
||||
},
|
||||
"publishConfig": {
|
||||
"registry": "https://registry.npmjs.org/"
|
||||
"registry": "https://registry.npmjs.org/"
|
||||
}
|
||||
}
|
||||
|
|
|
@ -0,0 +1,20 @@
|
|||
{
|
||||
"name": "@uview-plus/types",
|
||||
"version": "3.2.5",
|
||||
"lockfileVersion": 3,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "@uview-plus/types",
|
||||
"version": "3.2.5",
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"@uview-plus/types": "file:"
|
||||
}
|
||||
},
|
||||
"node_modules/@uview-plus/types": {
|
||||
"resolved": "",
|
||||
"link": true
|
||||
}
|
||||
}
|
||||
}
|
|
@ -22,5 +22,8 @@
|
|||
"homepage": "https://github.com/ijry/uview-plus#readme",
|
||||
"publishConfig": {
|
||||
"registry": "https://registry.npmjs.org/"
|
||||
},
|
||||
"dependencies": {
|
||||
"@uview-plus/types": "file:"
|
||||
}
|
||||
}
|
||||
|
|
|
@ -22,6 +22,7 @@ function baseRequest(url, method, data, {
|
|||
url: Url + '/api' + url,
|
||||
method: method || 'GET',
|
||||
header: {
|
||||
accept:'json',
|
||||
...header
|
||||
},
|
||||
data: method != 'GET' ? data || {} : {},
|
||||
|
|
Loading…
Reference in New Issue