Compare commits

...
3 Commits
5 changed files with 70 additions and 38 deletions
+2 -2
View File
@@ -8,8 +8,8 @@ const DOMAINS: Record<EnvType, { domain1: string; domain2: string }> = {
domain2: 'http://10.10.10.10:8889/weight', domain2: 'http://10.10.10.10:8889/weight',
}, },
trial: { trial: {
domain1: 'http://10.10.10.10:8889', domain1: 'http://device.shuziweidao.com:80/gateway',
domain2: 'http://10.10.10.10:8889/weight', domain2: 'http://device.shuziweidao.com:80/weight',
}, },
release: { release: {
domain1: 'http://device.shuziweidao.com:80/gateway', domain1: 'http://device.shuziweidao.com:80/gateway',
+37 -17
View File
@@ -83,26 +83,46 @@
} }
} }
/* 描边按钮(蓝色/红色) */ .section-right {
.ops-btn {
width: 180rpx;
height: 48rpx; height: 48rpx;
border-radius: 8rpx; display: flex;
font-size: 24rpx; flex-wrap: nowrap;
line-height: 44rpx;
text-align: center;
box-sizing: border-box;
flex-shrink: 0;
}
.ops-btn--blue { .section-right-red {
border: 2rpx solid #1385FA; height: 48rpx;
color: #1385FA; padding: 0 15rpx;
} border-radius: 8rpx;
font-size: 24rpx;
line-height: 44rpx;
box-sizing: border-box;
border: 2rpx solid #F24439;
color: #F24439;
}
.ops-btn--red { .section-right-blue {
border: 2rpx solid #F24439; height: 48rpx;
color: #F24439; display: flex;
flex-wrap: nowrap;
align-items: center;
padding: 0 15rpx;
border-radius: 8rpx;
background-color: #1385FA;
> view:nth-child(1) {
width: 32rpx;
height: 32rpx;
display: flex;
align-items: center;
margin-right: 6rpx;
}
> view:nth-child(2) {
color: #FFFFFF;
height: 24rpx;
font-size: 24rpx;
line-height: 24rpx;
}
}
} }
} }
+29 -17
View File
@@ -13,17 +13,27 @@
</view> </view>
<!-- 已配对设备行 --> <!-- 已配对设备行 -->
<block wx:if="{{ operationsEngineer }}"> <view class="section-bar">
<view class="section-bar"> <view class="section-left">
<view class="section-left"> <view class="bt-icon">
<view class="bt-icon"> <image src="/images/equipment/bluetooth.png"/>
<image src="/images/equipment/bluetooth.png"/> </view>
</view> <view class="section-title">已配对设备</view>
<view class="section-title">已配对设备</view> </view>
</view> <view class="section-right">
<view class="ops-btn ops-btn--red" bind:tap="onUnpairAll">取消全部配对</view> <block wx:if="{{ operationsEngineer }}">
</view> <view class="section-right-red" bind:tap="onUnpairAll">取消全部配对</view>
</block> </block>
<block wx:else>
<view class="section-right-blue" bind:tap="onTapAdd">
<view>
<image src="/images/addBtn.png"/>
</view>
<view>添加设备</view>
</view>
</block>
</view>
</view>
<!-- 设备列表 --> <!-- 设备列表 -->
<!-- <view class="device"> <!-- <view class="device">
@@ -86,7 +96,7 @@
<view> <view>
<image src="/images/equipment/users.png"/> <image src="/images/equipment/users.png"/>
</view> </view>
<view>用户({{ item.userNum }})</view> <view>用户管理({{ item.userNum }})</view>
</view> </view>
<block wx:if="{{item.status}}"> <block wx:if="{{item.status}}">
<view class="device-action-btn" bind:tap="onTapDataRetransfer"> <view class="device-action-btn" bind:tap="onTapDataRetransfer">
@@ -105,12 +115,14 @@
</block> </block>
<!-- 添加设备按钮 --> <!-- 添加设备按钮 -->
<view class="add-btn" bind:tap="onTapAdd"> <block wx:if="{{ operationsEngineer }}">
<view class="add-icon"> <view class="add-btn" bind:tap="onTapAdd">
<image src="/images/addBtn.png"/> <view class="add-icon">
<image src="/images/addBtn.png"/>
</view>
<view class="add-text">添加设备</view>
</view> </view>
<view class="add-text">绑定设备</view> </block>
</view>
<equipment-dialog show="{{ loadingShow }}" title="{{ loadingTitle }}" content="{{ loadingContent }}" <equipment-dialog show="{{ loadingShow }}" title="{{ loadingTitle }}" content="{{ loadingContent }}"
bind:close="onCloseLoading"/> bind:close="onCloseLoading"/>
@@ -109,7 +109,7 @@
</view> </view>
</view> </view>
<view class="submit-btn" bind:tap="onSubmit">完成并进入首页</view> <view class="submit-btn" bind:tap="onSubmit">开始使用</view>
<user-info-confirm-modal show="{{ showConfirmModal }}" userInfo="{{ serverResult }}" bind:confirm="onConfirmModalConfirm" bind:cancel="onConfirmModalCancel" /> <user-info-confirm-modal show="{{ showConfirmModal }}" userInfo="{{ serverResult }}" bind:confirm="onConfirmModalConfirm" bind:cancel="onConfirmModalCancel" />
</view> </view>
+1 -1
View File
@@ -3,7 +3,7 @@ import { ENV, type EnvType } from '../env/index'
/** 各环境接口网关地址:develop / trial 走测试网关,release 走正式网关 */ /** 各环境接口网关地址:develop / trial 走测试网关,release 走正式网关 */
const BASE_URLS: Record<EnvType, string> = { const BASE_URLS: Record<EnvType, string> = {
develop: 'http://10.10.10.10:8889/', develop: 'http://10.10.10.10:8889/',
trial: 'http://10.10.10.10:8889/', trial: 'https://device.shuziweidao.com/gateway/',
release: 'https://device.shuziweidao.com/gateway/', release: 'https://device.shuziweidao.com/gateway/',
} }