Compare commits

..

2 Commits

Author SHA1 Message Date
唐明明
8c35ad5956 mrege 2021-09-22 17:39:43 +08:00
唐明明
b06e4f8109 新增资产权证转让管理部分页面增加分页 2021-09-22 17:37:58 +08:00
24 changed files with 89599 additions and 93 deletions

View File

@@ -18,7 +18,8 @@ const mall = data => {
// 商品列表 // 商品列表
const list = data => { const list = data => {
return request({ return request({
url: "mall/goods" url: "mall/goods",
data
}) })
} }

View File

@@ -64,6 +64,30 @@ const marketsCreate = data => {
}) })
} }
// 转让管理
const marketsMag = data => {
return request({
url: 'markets/user/markets',
data
})
}
// 取消转让
const marketsCancel = id => {
return request({
url: 'markets/' + id + '/cancel',
method: 'POST'
})
}
// 我的成交理事
const marketsOrdersLogs = (data, name) => {
return request({
url: 'markets/orders/' + name,
data
})
}
export { export {
markets, markets,
marketsLogs, marketsLogs,
@@ -71,5 +95,8 @@ export {
marketsBuy, marketsBuy,
marketsPay, marketsPay,
marketsCreateInfo, marketsCreateInfo,
marketsCreate marketsCreate,
marketsMag,
marketsCancel,
marketsOrdersLogs
} }

View File

@@ -15,7 +15,7 @@ const index = () => {
}) })
} }
// 成交客户 // 成交客户 *********已废弃
const customer = data => { const customer = data => {
return request({ return request({
url: 'mall/statistics', url: 'mall/statistics',
@@ -23,6 +23,14 @@ const customer = data => {
}) })
} }
// 成交客户
const orderUsers = data => {
return request({
url: 'manages/order_users',
data
})
}
// 访客记录 // 访客记录
const visitors = data => { const visitors = data => {
return request({ return request({
@@ -57,6 +65,7 @@ const companiesCode = () => {
export { export {
index, index,
customer, customer,
orderUsers,
visitors, visitors,
basicsConfig, basicsConfig,
basicsInfo, basicsInfo,

View File

@@ -1,6 +1,6 @@
<template> <template>
<view class="OrderTemplate" > <view class="OrderTemplate" >
<view class="top" > <view class="top" v-if="isTop">
<view class="company"> <view class="company">
<view class="company-logo"> <view class="company-logo">
<image :src="item.shop.cover" mode="aspectFill" /> <image :src="item.shop.cover" mode="aspectFill" />
@@ -33,7 +33,11 @@
}; };
}, },
props:{ props:{
item:Object item : Object,
isTop : {
type: Boolean,
default: true
}
}, },
onShow() { onShow() {
console.log(this.item,'onshow,numtempa') console.log(this.item,'onshow,numtempa')
@@ -113,13 +117,11 @@
justify-content: flex-start; justify-content: flex-start;
box-sizing: border-box; box-sizing: border-box;
margin-top: 36rpx; margin-top: 36rpx;
.goods-img { .goods-img {
width: 120rpx; width: 120rpx;
height: 120rpx; height: 120rpx;
border-radius: 10rpx; border-radius: 10rpx;
} }
.goods { .goods {
flex: 1; flex: 1;
margin-left: 20rpx; margin-left: 20rpx;

View File

@@ -548,6 +548,21 @@
"navigationBarTitleText": "转让权证", "navigationBarTitleText": "转让权证",
"backgroundColor": "#FFFFFF" "backgroundColor": "#FFFFFF"
} }
},{
"path" : "pages/market/management",
"name" : "marketManag",
"style": {
"navigationBarTitleText": "权证转让管理",
"titleNView": {
"backgroundColor": "#FFFFFF",
"buttons": [{
"text": "转让记录",
"fontSize": "14",
"width": "80",
"color": "#e93340"
}]
}
}
} }
], ],
"tabBar": { "tabBar": {

View File

@@ -4,9 +4,7 @@
<view style="position: relative;z-index: 3;"> <view style="position: relative;z-index: 3;">
<!-- 搜索... --> <!-- 搜索... -->
<view class="mine-top-contant"> <view class="mine-top-contant">
<u-navbar back-icon-color='#fff' :background="background" title="企业优惠券中心" title-color="#fff" <u-navbar :is-back="true" :background="background" title="企业优惠券中心" title-color="#fff" :border-bottom='false'></u-navbar>
:border-bottom='false'>
</u-navbar>
<!--banner--> <!--banner-->
<swiper class="swiper" :indicator-dots="true" :autoplay="false" indicator-active-color='#fff' <swiper class="swiper" :indicator-dots="true" :autoplay="false" indicator-active-color='#fff'
indicator-color='rgba(0,0,0,.1)'> indicator-color='rgba(0,0,0,.1)'>

View File

@@ -142,7 +142,7 @@
<view class="title"> <view class="title">
限时抢购<text>海量商家优惠券</text> 限时抢购<text>海量商家优惠券</text>
</view> </view>
<navigator class="more" url="/pages/coupons/couponList">查看更多</navigator> <navigator class="more" open-type="navigate" url="/pages/coupons/couponList">查看更多</navigator>
</view> </view>
<view class="coupons" v-if="coupons.length > 0"> <view class="coupons" v-if="coupons.length > 0">
<view class="coupons-item" v-for="(item, index) in coupons" :key="index"> <view class="coupons-item" v-for="(item, index) in coupons" :key="index">
@@ -168,6 +168,8 @@
</view> </view>
<!-- 优选商品 --> <!-- 优选商品 -->
<goods-list :list="goods" priceType="CNY" @on-goods="onGoods" /> <goods-list :list="goods" priceType="CNY" @on-goods="onGoods" />
<!-- 分页 -->
<uni-load-more :status="pageStatus" :iconSize="16"></uni-load-more>
</block> </block>
</view> </view>
</template> </template>
@@ -205,14 +207,16 @@
coupons : [], coupons : [],
position : {}, position : {},
goods : [], goods : [],
pages : {},
// 广场部分 // 广场部分
industryIndex: 0, industryIndex: 0,
recommendBus : [], recommendBus : [],
hotBus : [], hotBus : [],
industryBus : [], industryBus : [],
busList : [], busList : [],
busPages : {} busPages : {},
// 分页
pageStatus : '',
page : 1
}; };
}, },
created() { created() {
@@ -268,7 +272,6 @@
// 易货首页 // 易货首页
getMall(){ getMall(){
mall().then(res => { mall().then(res => {
console.log(res.coupons)
this.classify = res.categories.slice(0, 9) this.classify = res.categories.slice(0, 9)
this.banners = res.banners this.banners = res.banners
this.coupons = res.coupons this.coupons = res.coupons
@@ -283,9 +286,15 @@
}, },
// 商品列表 // 商品列表
getGoods(){ getGoods(){
list().then(res => { list({
this.goods = res.data page: this.goodsPage
this.pages = res.page }).then(res => {
if(res.page.current === 1){
this.goods = []
}
this.goods = this.goods.concat(res.data)
this.goodsPage = res.page.current
this.pageStatus = res.page.has_more ? 'more': 'noMore'
}) })
}, },
// 商品详情 // 商品详情
@@ -324,6 +333,16 @@
} }
}) })
} }
},
// 下拉加载
onReachBottom() {
if(this.pageStatus == 'more'){
this.pageStatus = 'loading'
if(this.tabIndex === 0) {
this.goodsPage += 1
this.getGoods()
}
}
} }
} }
</script> </script>

View File

@@ -6,7 +6,7 @@
价格 价格
<image <image
class="icon" class="icon"
mode="widthFix" :src="require(marketType == 'low' ? '@/static/icons/market_icon_low.png': '@/static/icons/market_icon_high.png')" mode="widthFix" :src="require(marketType == 'asc' ? '@/static/icons/market_icon_low.png': '@/static/icons/market_icon_high.png')"
/> />
</view> </view>
</view> </view>
@@ -23,27 +23,33 @@
data() { data() {
return { return {
tabIndex : 0, tabIndex : 0,
marketType : 'low', marketType : 'asc',
goods : [] goods : []
}; };
}, },
created() { created() {
list().then(res=>{ this.getList()
console.log(res.data)
this.goods = res.data
this.pages = res.page
})
}, },
methods:{ methods:{
onTabs(e){ onTabs(e){
let index = e.target.dataset.index let index = e.target.dataset.index
if(index == 0 && index == this.tabIndex) return if(index == 0 && index == this.tabIndex) return
if(index == 1 && index == this.tabIndex) this.marketType = this.marketType == 'low' ? 'high': 'low' if(index == 1 && index == this.tabIndex) this.marketType = this.marketType == 'asc' ? 'desc': 'asc'
this.tabIndex = index this.tabIndex = index
this.getList()
}, },
onGoods(e){ onGoods(e){
this.$Router.push({name: 'goodsDetails', params: {id: e.goods_id}}) this.$Router.push({name: 'goodsDetails', params: {id: e.goods_id}})
},
getList(){
list({
order_by: this.tabIndex == 1 ? this.marketType: ''
}).then(res=>{
this.goods = res.data
this.pages = res.page
})
} }
} }
} }

View File

@@ -1,6 +1,11 @@
<template> <template>
<view> <view>
<view class="tabs" v-if="$Route.query.type === 'my'">
<view class="item" :class="{ 'show' : tab == 'sell'}" @click="onTasb('sell')">我转让的</view>
<view class="item" :class="{ 'show' : tab == 'buys' }" @click="onTasb('buys')">我买到的</view>
</view>
<block v-if="logs.length > 0"> <block v-if="logs.length > 0">
<view :class="{'paddingTop': $Route.query.type === 'my'}">
<view class="logs" v-for="(item, index) in logs" :key="index"> <view class="logs" v-for="(item, index) in logs" :key="index">
<view class="logs-item"> <view class="logs-item">
<label>交易权证</label> <label>交易权证</label>
@@ -27,22 +32,51 @@
{{item.created_at}} {{item.created_at}}
</view> </view>
</view> </view>
</view>
</block>
<block v-else>
<view class="list-null">
<image class="icon" src="@/static/icons/listnull-icon.png" mode="widthFix" />
<view class="sub-title">暂无数据</view>
</view>
</block> </block>
</view> </view>
</template> </template>
<script> <script>
import { marketsLogs } from '@/apis/interfaces/market' import { marketsLogs, marketsOrdersLogs } from '@/apis/interfaces/market'
export default { export default {
data() { data() {
return { return {
logs: [], logs: [],
page: {} page: {},
tab : 'sell'
}; };
}, },
created(){ created(){
this.getList()
},
methods:{
onTasb(e){
this.tab = e
this.getList()
},
// 获取列表
getList(){
if(this.$Route.query.type === 'my'){
marketsOrdersLogs({}, this.tab).then(res =>{
console.log(res)
this.logs = res.data
this.page = res.page
}).catch(err => {
uni.showToast({
title: err.message,
icon : 'none'
})
})
return
}
marketsLogs().then(res => { marketsLogs().then(res => {
console.log(res.data)
this.logs = res.data this.logs = res.data
this.page = res.page this.page = res.page
}).catch(err => { }).catch(err => {
@@ -53,9 +87,35 @@
}) })
} }
} }
}
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.tabs{
position: fixed;
top: 0;
left: 0;
width: 100%;
z-index: 99;
background-color: white;
height: 90rpx;
line-height: 90rpx;
display: flex;
justify-content: space-around;
.item{
border-bottom: solid 2rpx white;
box-sizing: border-box;
&.show{
border-color: $text-price;
color: $text-price;
}
}
}
.paddingTop{
padding-top: 90rpx;
}
.logs{ .logs{
background: white; background: white;
margin-top: $margin; margin-top: $margin;
@@ -78,4 +138,29 @@
} }
} }
} }
// 空提示
.list-null{
width: 100vw;
height: 100vh;
box-sizing: border-box;
text-align: center;
background: white;
padding-bottom: 20vh;
@extend .vertical;
.sub-title{
color: $text-gray;
font-size: $title-size-m;
}
.icon{
width: 288rpx;
}
}
.employees-null{
text-align: center;
line-height: 10vh;
padding-bottom: $padding;
font-size: $title-size-m;
color: $text-gray;
}
</style> </style>

169
pages/market/management.vue Normal file
View File

@@ -0,0 +1,169 @@
<template>
<view class="NumberWeight">
<!-- 有订单列表 -->
<view v-if="lists.length > 0">
<block v-for="(item, index) in lists" :key="index">
<view class="order-item">
<view class="order-info">
<image class="order-cover" :src="item.goods.cover" mode="aspectFill"></image>
<view class="title">数字权证<text>{{item.surplus}}/{{item.stock}}</text></view>
<view class="text">锚定商品{{item.goods.goods_name}}</view>
<view class="text">交易哈希{{item.hash}}</view>
<view class="text">发布时间{{item.created_at}}</view>
</view>
<view class="order-tool">
<view class="price">{{item.price}}/</view>
<view class="order-btn" v-if="item.status.value === 1" @click="removeGoods(item.market_id, index)">取消转让</view>
<view class="order-status" v-if="item.status.value === 2">{{item.status.text}}</view>
</view>
</view>
</block>
</view>
<!-- 没有订单列表 -->
<no-list v-if="lists.length === 0" name="no-order" txt="暂无数据~" />
<u-toast ref="uToast" />
</view>
</template>
<script>
import { marketsMag, marketsCancel } from '@/apis/interfaces/market';
export default {
data() {
return {
lists: [],
page: 1,
total: 0
};
},
onLoad() {
this.getList();
},
onReachBottom() {
if (this.total > this.lists.length) {
this.page = this.page + 1;
this.getList();
} else {
this.$refs.uToast.show({
title: '吼吼吼~我是有底的~',
type: 'error',
icon: false,
duration: 3000
});
}
},
methods: {
getList() {
let data = {
perPage: 10,
page: this.page
};
marketsMag(data)
.then(res => {
console.log(res.markets.data);
this.lists = this.lists.concat(res.markets.data);
this.total = res.markets.page.total;
})
.catch(err => {
this.$refs.uToast.show({
title: err.message,
type: 'error',
icon: false,
duration: 3000
});
});
},
// 取消转让
removeGoods(id, index) {
marketsCancel(id).then(res => {
uni.showToast({
icon : 'none',
title: res
})
let statusObj = this.lists[index]
statusObj.status = {
value: 2,
text : '已取消',
}
this.$set(this.lists, index, statusObj)
}).catch(err => {
uni.showToast({
icon : 'none',
title: err.message
})
})
}
},
onNavigationBarButtonTap(){
this.$Router.push({name: "marketLogs", params: {type: 'my'}})
}
};
</script>
<style lang="scss" scoped>
.NumberWeight {
box-sizing: border-box;
// 订单列表
.order-item {
background-color: white;
margin: $margin;
border-radius: $radius;
padding: $padding;
.order-info{
position: relative;
padding-left: 188rpx;
min-height: 168rpx;
.order-cover{
position: absolute;
top: 0;
left: 0;
height: 168rpx;
width: 168rpx;
}
.title{
font-weight: bold;
font-size: $title-size-lg;
color: $text-color;
line-height: 48rpx;
height: 48rpx;
display: flex;
justify-content: space-between;
text{
font-size: 80%;
font-weight: normal;
}
}
.text{
line-height: 40rpx;
height: 40rpx;
font-size: $title-size-sm;
color: $text-gray;
@extend .nowrap;
}
}
.order-tool{
margin-top: $margin - 10;
padding-top: $padding - 10;
border-top: solid 1rpx $border-color;
display: flex;
justify-content: space-between;
.price{
color: $text-price;
font-weight: bold;
font-size: $title-size-m;
line-height: 50rpx;
}
.order-btn{
background: $text-price;
color: white;
padding: 0 $padding;
line-height: 50rpx;
border-radius: 25rpx;
font-size: $title-size-m;
}
.order-status{
color: $text-gray-m;
}
}
}
}
</style>

View File

@@ -63,7 +63,7 @@
<view class="item-num">{{count.warrnats}}</view> <view class="item-num">{{count.warrnats}}</view>
<view class="item-title">权证持有</view> <view class="item-title">权证持有</view>
</view> </view>
<view class="item" @click="showToast"> <view class="item" @click="$Router.push({name: 'marketManag'})">
<view class="item-num">{{count.warrnat_transfer}}</view> <view class="item-num">{{count.warrnat_transfer}}</view>
<view class="item-title">权证转让</view> <view class="item-title">权证转让</view>
</view> </view>

View File

@@ -8,14 +8,19 @@
</view> </view>
<!-- 统计信息 --> <!-- 统计信息 -->
<view class="statistics"> <view class="statistics">
<view class="statistics-flex">
<picker mode="date" :fields="tabsIndex" :value="dateValue" :end="endDate" @change="pickerDate"> <picker mode="date" :fields="tabsIndex" :value="dateValue" :end="endDate" @change="pickerDate">
<view class="statistics-date"> <view class="statistics-date">
{{dateValue}}<uni-icons class="arrowdown" type="arrowdown" color="#555"></uni-icons> {{dateValue}}<uni-icons class="arrowdown" type="arrowdown" color="#555"></uni-icons>
</view> </view>
</picker> </picker>
<view class="statistics-lay" :class="{ 'show' : sort != '' || payType != '' || channel != ''}" @click="onScreening">
筛选 <uni-icons class="arrowdown" type="settings" color="gray"></uni-icons>
</view>
</view>
<view class="statistics-text"> <view class="statistics-text">
<text>成交客户 {{visitor.day}} </text> <text>成交产品数 {{visitor.goods_count}} </text>
<text>累计访客量 {{visitor.all}} </text> <text>成交产品金额 {{visitor.total}} </text>
</view> </view>
</view> </view>
<!-- 数据列表 --> <!-- 数据列表 -->
@@ -24,12 +29,18 @@
<view class="item" v-for="(item, index) in orders" :key="index"> <view class="item" v-for="(item, index) in orders" :key="index">
<image class="cover" :src="item.user.avatar" mode="aspectFill"></image> <image class="cover" :src="item.user.avatar" mode="aspectFill"></image>
<view class="title nowrap"> <view class="title nowrap">
{{item.user.username}} {{item.user.nickname}}
<view class="type">{{item.state}}</view> <view class="type">{{item.amount}}</view>
</view> </view>
<view class="sub-title nowrap">订单号: {{item.order_no}}</view> <view class="sub-title nowrap">订单号: {{item.order_no}}</view>
<view class="sub-title nowrap">{{item.created_at}}</view> <view class="sub-title nowrap">订单时间: {{item.created_at}}</view>
<view class="sub-tabs">
<text>{{item.driver}}</text>
<text>{{item.channel}}</text>
</view> </view>
</view>
<!-- 分页 -->
<uni-load-more :status="pageStatus" :iconSize="16"></uni-load-more>
</block> </block>
<block v-else> <block v-else>
<view class="list-null"> <view class="list-null">
@@ -38,12 +49,40 @@
</view> </view>
</block> </block>
</view> </view>
<!-- 列表筛选 -->
<uni-popup ref="settingsPopup" background-color="#FFFFFF" @maskClick="onReset">
<view class="popup-content">
<view class="title">排序方式</view>
<view class="popup-choose-flex">
<view class="item" :class="{'show' : sort == 'money_asc'}" @click="sort = 'money_asc'">金额从低到高</view>
<view class="item" :class="{'show' : sort == 'money_desc'}" @click="sort = 'money_desc'">金额从高到低</view>
<view class="item" :class="{'show' : sort == 'sold_asc'}" @click="sort = 'sold_asc'">销量从低到高</view>
<view class="item" :class="{'show' : sort == 'sold_desc'}" @click="sort = 'sold_desc'">销量从高到低</view>
</view>
<view class="title">支付方式</view>
<view class="popup-choose-flex">
<view class="item" :class="{'show' : payType == 'eb'}" @click="payType = 'eb'">易币交易</view>
<view class="item" :class="{'show' : payType == 'money'}" @click="payType = 'money'">现金交易</view>
</view>
<view class="title">成交渠道</view>
<view class="popup-choose-flex">
<view class="item" :class="{'show' : channel == 'app'}" @click="channel = 'app'">APP</view>
<view class="item" :class="{'show' : channel == 'mini'}" @click="channel = 'mini'">自媒体</view>
</view>
<view class="popup-btns">
<view class="item" @click="onReset">重置</view>
<view class="item" @click="onSettings">确定</view>
</view>
</view>
<view class="ios-bottom"></view>
</uni-popup>
<!-- :status="more" -->
</view> </view>
</template> </template>
<script> <script>
import getDate from '@/public/date' import getDate from '@/public/date'
import { customer } from '@/apis/interfaces/store' import { orderUsers } from '@/apis/interfaces/store'
export default { export default {
data() { data() {
return { return {
@@ -55,7 +94,12 @@
all: 0 all: 0
}, },
orders : [], orders : [],
pages : {} sort : '',
payType : '',
channel : '',
// 分页
pageStatus : '',
page : 1
}; };
}, },
created() { created() {
@@ -68,28 +112,49 @@
methods:{ methods:{
// tabs筛选 // tabs筛选
onTbas(type){ onTbas(type){
console.log(type)
getDate(type).then(res => { getDate(type).then(res => {
this.tabsIndex = type this.tabsIndex = type
this.dateValue = res this.dateValue = res
this.page = 1
this.getLists() this.getLists()
}) })
}, },
onReset(){
this.sort = ''
this.payType = ''
this.channel = ''
},
onSettings(){
this.getLists()
this.$refs.settingsPopup.close()
},
// 日期筛选 // 日期筛选
pickerDate(e){ pickerDate(e){
let dateValue = e.detail.value let dateValue = e.detail.value
this.dateValue = dateValue this.dateValue = dateValue
this.getLists() this.getLists()
}, },
// 列表筛选
onScreening(){
this.$refs.settingsPopup.open('bottom')
},
// 获取列表 // 获取列表
getLists(){ getLists(){
customer({ orderUsers({
type : this.tabsIndex, type : this.tabsIndex,
date: this.dateValue date : this.dateValue,
sort : this.sort,
pay_type : this.payType,
channel : this.channel,
page : this.page
}).then(res => { }).then(res => {
if(res.orders.page.current === 1){
this.orders = []
}
this.visitor = res.visitor this.visitor = res.visitor
this.orders = res.orders.data this.orders = this.orders.concat(res.orders.data)
this.pages = res.orders.page this.page = res.orders.page.current
this.pageStatus = res.orders.page.has_more ? 'more': 'noMore'
}).catch(err => { }).catch(err => {
uni.showToast({ uni.showToast({
title: err, title: err,
@@ -97,11 +162,68 @@
}) })
}) })
} }
},
onReachBottom() {
if(this.pageStatus == 'more'){
this.pageStatus = 'loading'
this.page += 1
this.getLists()
}
} }
} }
</script> </script>
<style lang="scss"> <style lang="scss">
// 筛选层
.popup-content{
padding: $padding * 2;
.title{
font-weight: bold;
font-size: $title-size;
color: $text-color;
margin-top: $margin;
}
.popup-choose-flex{
padding: $padding /2 0;
margin: 0 -($margin - 20rpx);
display: flex;
flex-wrap: wrap;
.item{
width: calc(33.33% - #{$margin - 10});
font-size: $title-size-sm;
text-align: center;
background: $border-color-lg;
line-height: 68rpx;
margin: $margin - 20;
color: $text-gray;
border:solid 1rpx $border-color-lg;
box-sizing: border-box;
&.show{
border:solid 1rpx $text-price;
color: $text-price;
}
}
}
.popup-btns{
padding-top: $padding*2;
display: flex;
justify-content: space-between;
margin: 0 -$margin/2;
.item{
margin: $margin/2;
color: $text-price;
background: rgba($color: $text-price, $alpha: .1);
width: calc(50% - #{$margin});
height: 80rpx;
line-height: 80rpx;
text-align: center;
&:last-child{
background-color: $text-price;
color: white;
}
}
}
}
// 空提示 // 空提示
.list-null{ .list-null{
width: 100vw; width: 100vw;
@@ -145,6 +267,9 @@
background-color: white; background-color: white;
border-bottom: solid 1rpx $border-color; border-bottom: solid 1rpx $border-color;
padding: $padding; padding: $padding;
.statistics-flex{
display: flex;
justify-content: space-between;
.statistics-date{ .statistics-date{
font-size: $title-size + 4; font-size: $title-size + 4;
font-weight: bold; font-weight: bold;
@@ -153,6 +278,19 @@
margin-left: $margin/2; margin-left: $margin/2;
} }
} }
.statistics-lay{
font-size: $title-size-sm;;
color: gray;
line-height: 50rpx;
&.show{
color: $text-price;
}
.arrowdown{
margin-left: $margin/2;
}
}
}
.statistics-text{ .statistics-text{
font-size: $title-size-sm; font-size: $title-size-sm;
color: gray; color: gray;
@@ -212,6 +350,16 @@
font-size: $title-size-sm; font-size: $title-size-sm;
color: $text-gray; color: $text-gray;
} }
.sub-tabs{
padding-top: $padding/2;
font-size: $title-size-sm;
text{
margin-right: $margin - 10;
background: $border-color-lg;
color: $text-gray;
padding: 0 ($padding/2);
}
}
} }
} }
</style> </style>

View File

@@ -10,7 +10,7 @@ export default getDate = (type) =>{
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
const date = new Date() const date = new Date()
const year = date.getFullYear() const year = date.getFullYear()
const month = (date.getMonth() + 1) < 9 ? '0' + (date.getMonth() + 1) : date.getMonth() const month = (date.getMonth() + 1) <= 9 ? '0' + (date.getMonth() + 1) : date.getMonth()
const day = date.getDate() const day = date.getDate()
switch(type){ switch(type){

View File

@@ -0,0 +1,10 @@
## 1.2.12021-08-24
- 新增 支持国际化
## 1.2.02021-07-30
- 组件兼容 vue3如何创建vue3项目详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834)
## 1.1.82021-05-12
- 新增 组件示例地址
## 1.1.72021-03-30
- 修复 uni-load-more 在首页使用时h5 平台报 'uni is not defined' 的 bug
## 1.1.62021-02-05
- 调整为uni_modules目录规范

View File

@@ -0,0 +1,5 @@
{
"uni-load-more.contentdown": "Pull up to show more",
"uni-load-more.contentrefresh": "loading...",
"uni-load-more.contentnomore": "No more data"
}

View File

@@ -0,0 +1,8 @@
import en from './en.json'
import zhHans from './zh-Hans.json'
import zhHant from './zh-Hant.json'
export default {
en,
'zh-Hans': zhHans,
'zh-Hant': zhHant
}

View File

@@ -0,0 +1,5 @@
{
"uni-load-more.contentdown": "上拉显示更多",
"uni-load-more.contentrefresh": "正在加载...",
"uni-load-more.contentnomore": "没有更多数据了"
}

View File

@@ -0,0 +1,5 @@
{
"uni-load-more.contentdown": "上拉顯示更多",
"uni-load-more.contentrefresh": "正在加載...",
"uni-load-more.contentnomore": "沒有更多數據了"
}

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,86 @@
{
"id": "uni-load-more",
"displayName": "uni-load-more 加载更多",
"version": "1.2.1",
"description": "LoadMore 组件,常用在列表里面,做滚动加载使用。",
"keywords": [
"uni-ui",
"uniui",
"加载更多",
"load-more"
],
"repository": "https://github.com/dcloudio/uni-ui",
"engines": {
"HBuilderX": ""
},
"directories": {
"example": "../../temps/example_temps"
},
"dcloudext": {
"category": [
"前端组件",
"通用组件"
],
"sale": {
"regular": {
"price": "0.00"
},
"sourcecode": {
"price": "0.00"
}
},
"contact": {
"qq": ""
},
"declaration": {
"ads": "无",
"data": "无",
"permissions": "无"
},
"npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui"
},
"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"
},
"快应用": {
"华为": "u",
"联盟": "u"
},
"Vue": {
"vue2": "y",
"vue3": "u"
}
}
}
}
}

View File

@@ -0,0 +1,70 @@
### LoadMore 加载更多
> **组件名uni-load-more**
> 代码块: `uLoadMore`
用于列表中,做滚动加载使用,展示 loading 的各种状态。
### 安装方式
本组件符合[easycom](https://uniapp.dcloud.io/collocation/pages?id=easycom)规范,`HBuilderX 2.5.5`起,只需将本组件导入项目,在页面`template`中即可直接使用,无需在页面中`import`和注册`components`
如需通过`npm`方式使用`uni-ui`组件,另见文档:[https://ext.dcloud.net.cn/plugin?id=55](https://ext.dcloud.net.cn/plugin?id=55)
### 使用方式
在 ``template`` 中使用组件
```html
<uni-load-more :status="more"></uni-load-more>
```
## API
### LoadMore Props
|属性名 |类型 | 可选值 |默认值 |说明 |
|:-: |:-: |:-: |:-: |:-: |
|iconSize |Number |- |24 |指定图标大小 |
|status |String |more/loading/noMore |more |loading 的状态 |
|showIcon |Boolean|- |true |是否显示 loading 图标 |
|iconType |String |snow/circle/auto |auto |指定图标样式|
|color |String |- |#777777 |图标和文字颜色 |
|contentText|Object|- |{contentdown: "上拉显示更多",contentrefresh: "正在加载...",contentnomore: "没有更多数据了"}|各状态文字说明 |
#### Status Options
|参数名称 |说明 |
|:-: |:-: |
|more |loading前 |
|loading|loading前中 |
|more |没有更多数据 |
#### IconType Options
|参数名称 |说明 |
|:-: |:-: |
|snow |ios雪花加载样式 |
|circle |安卓环形加载样式 |
|auto |根据平台自动选择加载样式 |
> **说明**
> `iconType`为`snow`时,在`APP-NVUE`平台不可设置大小,在非`APP-NVUE`平台不可设置颜色
### 事件说明
|事件名 |说明 |返回值 |
|:-: |:-: |:-: |
|clickLoadMore |点击加载更多时触发 |e.detail={status:'loading'}|
## 组件示例
点击查看:[https://hellouniapp.dcloud.net.cn/pages/extUI/load-more/load-more](https://hellouniapp.dcloud.net.cn/pages/extUI/load-more/load-more)

File diff suppressed because one or more lines are too long

45779
unpackage/dist/dev/app-plus/app-service.js vendored Normal file

File diff suppressed because one or more lines are too long

42673
unpackage/dist/dev/app-plus/app-view.js vendored Normal file

File diff suppressed because one or more lines are too long