feat: ai问答
This commit is contained in:
@@ -72,7 +72,12 @@ Page({
|
||||
}
|
||||
|
||||
// 2. Prepare payload
|
||||
const mapTitle = { growth: '生长记录', repot: '换盆记录', pest: '病虫害记录', other: '日常记录' };
|
||||
const mapTitle = {
|
||||
growth: '生长记录', flower: '开花记录', repot: '换盆记录',
|
||||
prune: '修剪记录', fertilize: '施肥记录', soil: '换土记录',
|
||||
pest: '病虫害记录', medicine: '用药记录', move: '移位记录',
|
||||
other: '日常记录'
|
||||
};
|
||||
const title = mapTitle[this.data.recordType] || '日常记录';
|
||||
|
||||
const payload = {
|
||||
|
||||
@@ -8,14 +8,38 @@
|
||||
<t-icon name="thumb-up" size="32rpx" />
|
||||
<text>生长</text>
|
||||
</view>
|
||||
<view class="chip {{recordType === 'flower' ? 'active' : ''}}" bindtap="setRecordType" data-type="flower">
|
||||
<t-icon name="heart" size="32rpx" />
|
||||
<text>开花</text>
|
||||
</view>
|
||||
<view class="chip {{recordType === 'repot' ? 'active' : ''}}" bindtap="setRecordType" data-type="repot">
|
||||
<t-icon name="swap" size="32rpx" />
|
||||
<text>换盆</text>
|
||||
</view>
|
||||
<view class="chip {{recordType === 'prune' ? 'active' : ''}}" bindtap="setRecordType" data-type="prune">
|
||||
<t-icon name="cut" size="32rpx" />
|
||||
<text>修剪</text>
|
||||
</view>
|
||||
<view class="chip {{recordType === 'fertilize' ? 'active' : ''}}" bindtap="setRecordType" data-type="fertilize">
|
||||
<t-icon name="edit-1" size="32rpx" />
|
||||
<text>施肥</text>
|
||||
</view>
|
||||
<view class="chip {{recordType === 'soil' ? 'active' : ''}}" bindtap="setRecordType" data-type="soil">
|
||||
<t-icon name="layers" size="32rpx" />
|
||||
<text>换土</text>
|
||||
</view>
|
||||
<view class="chip {{recordType === 'pest' ? 'active' : ''}}" bindtap="setRecordType" data-type="pest">
|
||||
<t-icon name="error-circle" size="32rpx" />
|
||||
<text>病虫害</text>
|
||||
</view>
|
||||
<view class="chip {{recordType === 'medicine' ? 'active' : ''}}" bindtap="setRecordType" data-type="medicine">
|
||||
<t-icon name="heart-filled" size="32rpx" />
|
||||
<text>用药</text>
|
||||
</view>
|
||||
<view class="chip {{recordType === 'move' ? 'active' : ''}}" bindtap="setRecordType" data-type="move">
|
||||
<t-icon name="map-navigation" size="32rpx" />
|
||||
<text>移位</text>
|
||||
</view>
|
||||
<view class="chip {{recordType === 'other' ? 'active' : ''}}" bindtap="setRecordType" data-type="other">
|
||||
<t-icon name="file" size="32rpx" />
|
||||
<text>其他</text>
|
||||
|
||||
Reference in New Issue
Block a user