| | |
| | | <view v-if="type === 'delete'" class="button" @click.stop="recoverSelected()">恢复</view>
|
| | | </view>
|
| | | </view>
|
| | | <view style="background-color: white; margin: 10rpx;">
|
| | | <view>
|
| | | <u--input
|
| | | placeholder="请输入商品名称"
|
| | | border="surround"
|
| | | v-model="query.name"
|
| | | @change="flowerLevelChange"
|
| | | ></u--input>
|
| | | </view>
|
| | | <view style="margin-top: 10px;">
|
| | | <u-radio-group
|
| | | v-model="query.level"
|
| | | placement="row"
|
| | | @change="flowerLevelChange"
|
| | | >
|
| | | <u-radio
|
| | | :customStyle="{marginBottom: '8px'}"
|
| | | v-for="(item, index) in columns_levels"
|
| | | :key="index"
|
| | | :label="item.label"
|
| | | :name="item.value"
|
| | | |
| | | >
|
| | | </u-radio>
|
| | | </u-radio-group>
|
| | | </view> |
| | | </view>
|
| | |
|
| | | <view class="p15" style="min-height: calc(100vh - 500rpx);">
|
| | | <no-data v-if="!list||list.length==0" style="width: 100%;"></no-data>
|
| | |
| | | <view class="flex1">
|
| | | <view class=" flex">
|
| | | <view class="title">{{item.name}}<span class="level">{{item.levelStr}}</span></view>
|
| | | <view class="m-l-a m-r-0"><span class="label">排名</span><span
|
| | | class="value">{{item.typeRank || '-'}}</span></view>
|
| | | <view class="m-l-a m-r-0"><span class="label t-red">排名</span><span
|
| | | class="value t-red">{{item.typeRank || '-'}}</span></view>
|
| | |
|
| | | <view class="m-l-a m-r-0">
|
| | | {{item.categoryStr || '-'}}
|
| | |
| | | return {
|
| | | type: 'all',
|
| | | query: {
|
| | | type: ''
|
| | | type: '',
|
| | | name:'',
|
| | | level:'',
|
| | | },
|
| | | content: '',
|
| | | currentInputDto: {},
|
| | |
| | | inputplaceholder: '',
|
| | | selectedFlowers: [], // 存储选中的花的 ID
|
| | | ids: [],
|
| | | columns_levels:[]
|
| | | }
|
| | | },
|
| | | onShow() {
|
| | | console.log("onShow")
|
| | | if (this.sign['flower']) {
|
| | | this.$store.dispatch('sign_clear', 'flower');
|
| | | this.refreshList()
|
| | | }
|
| | | },
|
| | | async onLoad(options) {
|
| | | console.log("onLoad")
|
| | | this.type = options.type || 'all'
|
| | | var title = ''
|
| | | this.page.size = 20
|
| | |
| | | }
|
| | | await this.$store.dispatch('sign_clear', 'flower');
|
| | | this.getList()
|
| | | // 获取商品等级
|
| | | this.getFlowerLevel()
|
| | | },
|
| | | onReachBottom() {
|
| | | console.log('onReachBottom')
|
| | |
| | | uni.stopPullDownRefresh()
|
| | | },
|
| | | methods: {
|
| | | |
| | | flowerLevelChange(){
|
| | | this.refreshList()
|
| | | },
|
| | | |
| | | async getFlowerLevel(){
|
| | | this.$http.request('get', '/api/code/value', {
|
| | | params: {
|
| | | type: 'FLOWER_LEVEL'
|
| | | }
|
| | | }).then(res => {
|
| | | var data = res.data
|
| | | // this.columns_levels_all = data || []
|
| | | let tmp = data || []
|
| | | tmp.unshift({
|
| | | label: '全部',
|
| | | value: ''
|
| | | })
|
| | | this.columns_levels=tmp
|
| | | |
| | | })
|
| | | },
|
| | | async openValue(item, key) {
|
| | | this.content = item[key] || ''
|
| | | this.currentInputDto = item
|