Browse Source

添加农事 自定义类型

master
邓宏 2 years ago
parent
commit
269fa3579c
  1. 2
      common/request.js
  2. 4
      pages/massif/add_farming.vue
  3. 6
      store/index.js

2
common/request.js

@ -3,7 +3,7 @@ import store from "@/store"
export function host(host='default',suffix='/plant_manage'){
var url=process.env.NODE_ENV === 'development'?{
// default:`http://dpe74u.natappfree.cc` //陈
default:`http://7xa7q2.natappfree.cc` //马
default:`http://nys8cm.natappfree.cc` //马
// default:`http://7r39sr.natappfree.cc` //何
// default:`http://192.168.0.116:8080` //孙
}:{

4
pages/massif/add_farming.vue

@ -118,7 +118,7 @@
<view class="title">农事类型</view>
<view class="content">
<text :class="{active:formData.farmingType==v.value}" v-for="(v,k) in typeList" :key="k" @click="formData.farmingType=v.value">{{v.label}}</text>
<text>自定义+</text>
<text @click="isShow=true">自定义+</text>
</view>
</view>
@ -144,7 +144,7 @@
</u-form>
</view>
<u-popup :show="isShow" closeOnClickOverlay @close="isShow=false">
<input placeholder="请输入" confirm-type="done" v-model="tempType" @confirm=""/>
<input placeholder="请输入" :focus="isShow" confirm-type="done" v-model="tempType" @confirm=""/>
</u-popup>
</view>
</template>

6
store/index.js

@ -23,9 +23,9 @@ export default new Vuex.Store({
outLogin(state){
state.userInfo={}
state.token=''
// uni.reLaunch({
// url:"/pages/home/login",
// })
uni.reLaunch({
url:"/pages/home/login",
})
},
setHeadImg(state,val){
state.userInfo.avatar=val

Loading…
Cancel
Save