task.vue 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317
  1. <template>
  2. <!-- 养殖 -->
  3. <view class="" v-if="data.taskType === '2'">
  4. <view class="b-radius bg-#fff pd-10 p-rtv">
  5. <image class="w-80 h-34" src="https://yujin-szyy.oss-cn-chengdu.aliyuncs.com/szyy/images-plt/plant/port/Task_Breeding.png" mode="widthFix" style="position: absolute; top: 0; left: 0" />
  6. <image v-if="+status == 9" class="w-98 h-98" src="https://yujin-szyy.oss-cn-chengdu.aliyuncs.com/szyy/images-plt/plant/port/over.png" mode="widthFix" style="position: absolute; top: 50rpx; right: 20rpx" />
  7. <view class="d-flex j-ed f-s-22 c-#666">{{ data?.plannedStartDate }}至{{ data?.plannedEndDate }}</view>
  8. <view class="d-flex a-ed pd-16 pt-8 pb-8" @click.stop="$emit('cardClick')">
  9. <view class="c-#333 f-s-34 f-w-5 mr-6">{{ data?.variety }}</view>
  10. <view class="c-#666 f-s-26">{{ data?.genusName }}</view>
  11. </view>
  12. <view class="d-flex a-c f-s-28 pd-16 pt-8 pb-8" @click.stop="$emit('cardClick')">
  13. <view class="c-#666 w-s-no">养殖批号:</view>
  14. <view class="c-#333 f-w-5">{{ data?.plantationCode }}</view>
  15. </view>
  16. <view class="d-flex f-s-28 pd-16 pt-8 pb-8">
  17. <view class="c-#666 w-s-no">种源批号:</view>
  18. <view v-if="data?.seedCodeList.length !== 0">
  19. <view class="c-#333 f-w-5" v-for="item in data?.seedCodeList" :key="item">{{ item }}</view>
  20. </view>
  21. <view v-else>
  22. <view class="c-#666">暂无完善种源信息</view>
  23. </view>
  24. </view>
  25. <view class="d-flex a-c f-s-28 pd-16 pt-8 pb-8" @click.stop="$emit('cardClick')">
  26. <view class="c-#666 w-s-no">基地:</view>
  27. <view class="c-#333 f-w-5 tx-ov w-s-no ov-hd d-flex a-c">
  28. {{ data?.baseRef?.baseName }}
  29. <text v-if="+data?.landFlag">全部地块</text>
  30. <view v-else>
  31. <text v-for="(item, index) in data?.baseRef?.baseInfo?.landList" :key="index"><text v-if="index != 0">、</text> {{ item?.landName }}</text>
  32. </view>
  33. </view>
  34. <view class="flex1 d-flex j-ed"><up-icon name="arrow-right" size="34rpx"></up-icon></view>
  35. </view>
  36. <view class="d-flex f-s-28 pd-16 pt-8 pb-8" @click.stop="$emit('cardClick')">
  37. <view class="d-flex a-c w-50%">
  38. <view class="c-#666 w-s-no">养殖区域:</view>
  39. <view class="c-#333 f-w-5 tx-ov w-s-no ov-hd">{{ data?.breedScale }}{{ data?.breedScaleUnit }} </view>
  40. </view>
  41. <view class="d-flex a-c w-50%">
  42. <view class="c-#666 w-s-no">养殖量:</view>
  43. <view class="c-#333 f-w-5 tx-ov w-s-no ov-hd">{{ data?.plantingMgAmount }}{{ data?.plantingMgUnit }} </view>
  44. </view>
  45. </view>
  46. <view class="pd-16 pt-8 pb-8">
  47. <up-line color="#f7f7f7"></up-line>
  48. </view>
  49. <view class="pd-16 pt-8 pb-8 d-flex j-sb gap-20">
  50. <up-button :customStyle="customStyle1" @click.stop="$emit('toInformation')">
  51. <view class="d-flex a-c j-c">
  52. <image class="w-28 h-24" src="https://yujin-szyy.oss-cn-chengdu.aliyuncs.com/szyy/images-plt/plant/port/Task_Species_source_information.png" mode="widthFix" />
  53. <text class="f-s-26">种源信息</text>
  54. </view>
  55. </up-button>
  56. <up-button :customStyle="customStyle2" @click.stop="$emit('toSupervise')">
  57. <view class="d-flex a-c j-c">
  58. <image class="w-28 h-24" src="https://yujin-szyy.oss-cn-chengdu.aliyuncs.com/szyy/images-plt/plant/port/Task_Breeding_management.png" mode="widthFix" />
  59. <text class="f-s-26">饲养管理</text>
  60. </view>
  61. </up-button>
  62. <up-button :customStyle="customStyle3" @click.stop="$emit('toHarvest')">
  63. <view class="d-flex a-c j-c">
  64. <image class="w-28 h-24" src="https://yujin-szyy.oss-cn-chengdu.aliyuncs.com/szyy/images-plt/plant/port/Task_Harvest_management.png" mode="widthFix" />
  65. <text class="f-s-26">采收管理</text>
  66. </view>
  67. </up-button>
  68. </view>
  69. </view>
  70. </view>
  71. <!-- 种苗繁育 -->
  72. <view class="" v-if="data.taskType === '11'">
  73. <view class="b-radius bg-#fff pd-10 p-rtv">
  74. <image class="w-112 h-34" src="https://yujin-szyy.oss-cn-chengdu.aliyuncs.com/szyy/images-plt/plant/port/Task_Seedling_breeding.png" mode="widthFix" style="position: absolute; top: 0; left: 0" />
  75. <image v-if="+status == 9" class="w-98 h-98" src="https://yujin-szyy.oss-cn-chengdu.aliyuncs.com/szyy/images-plt/plant/port/over.png" mode="widthFix" style="position: absolute; top: 50rpx; right: 20rpx" />
  76. <view class="d-flex j-ed f-s-22 c-#666">{{ data?.plannedStartDate }} 至 {{ data?.plannedEndDate }}</view>
  77. <view class="d-flex a-ed pd-16 pt-8 pb-8" @click.stop="$emit('cardClick')">
  78. <view class="c-#333 f-s-34 f-w-5 mr-6">{{ data?.variety }}</view>
  79. <view class="c-#666 f-s-26">{{ data?.genusName }}</view>
  80. </view>
  81. <view class="d-flex f-s-28 pd-16 pt-8 pb-8" @click.stop="$emit('cardClick')">
  82. <view class="c-#666 w-s-no">繁育批号:</view>
  83. <view class="c-#333 f-w-5">{{ data?.plantationCode }}</view>
  84. </view>
  85. <view class="d-flex f-s-28 pd-16 pt-8 pb-8" @click.stop="$emit('cardClick')">
  86. <view class="c-#666 w-s-no">种源批号:</view>
  87. <view v-if="data?.seedCodeList.length !== 0">
  88. <view class="c-#333 f-w-5" v-for="item in data?.seedCodeList" :key="item">{{ item }}</view>
  89. </view>
  90. <view v-else>
  91. <view class="c-#666">暂无完善种源信息</view>
  92. </view>
  93. </view>
  94. <view class="d-flex a-c f-s-28 pd-16 pt-8 pb-8" @click.stop="$emit('cardClick')">
  95. <view class="c-#666 w-s-no">基地:</view>
  96. <view class="c-#333 f-w-5 tx-ov w-s-no ov-hd d-flex a-c">
  97. {{ data?.baseRef?.baseName }}
  98. <text v-if="+data?.landFlag">全部地块</text>
  99. <view v-else>
  100. <text v-for="(item, index) in data?.baseRef?.baseInfo?.landList" :key="index"><text v-if="index != 0">、</text> {{ item?.landName }}</text>
  101. </view>
  102. </view>
  103. <view class="flex1 d-flex j-ed"><up-icon name="arrow-right" size="34rpx"></up-icon></view>
  104. </view>
  105. <view class="d-flex f-s-28 pd-16 pt-8 pb-8" @click.stop="$emit('cardClick')">
  106. <view v-if="data?.lands[0]?.landType == '3'" class="d-flex a-c w-50%">
  107. <view class="c-#666 w-s-no">接种数量:</view>
  108. <view class="c-#333 f-w-5 tx-ov w-s-no ov-hd">{{ data?.inoculationAmount }}{{ data?.inoculationUnit }}</view>
  109. </view>
  110. <view v-else class="d-flex a-c w-50%">
  111. <view class="c-#666 w-s-no">种植面积:</view>
  112. <view class="c-#333 f-w-5 tx-ov w-s-no ov-hd">{{ data?.plantingAmount }}{{ data?.plantingUnit }} </view>
  113. </view>
  114. <view class="d-flex a-c w-50%">
  115. <view class="c-#666 w-s-no">繁育量:</view>
  116. <view class="c-#333 f-w-5 tx-ov w-s-no ov-hd">{{ data?.plantingMgAmount }}{{ data?.plantingMgUnit }} </view>
  117. </view>
  118. </view>
  119. <view class="pd-16 pt-8 pb-8">
  120. <up-line color="#f7f7f7"></up-line>
  121. </view>
  122. <view class="pd-16 pt-8 pb-8 d-flex j-sb gap-20">
  123. <up-button :customStyle="customStyle1" @click.stop="$emit('toInformation')">
  124. <view class="d-flex a-c j-c">
  125. <image class="w-28 h-24" src="https://yujin-szyy.oss-cn-chengdu.aliyuncs.com/szyy/images-plt/plant/port/Task_Species_source_information.png" mode="widthFix" />
  126. <text class="f-s-26">种源信息</text>
  127. </view>
  128. </up-button>
  129. <up-button v-if="data?.lands[0]?.landType == '3'" :customStyle="customStyle2" @click.stop="$emit('toSupervise')">
  130. <view class="d-flex a-c j-c">
  131. <image class="w-28 h-24" src="https://yujin-szyy.oss-cn-chengdu.aliyuncs.com/szyy/images-plt/plant/port/Task_Breeding_management.png" mode="widthFix" />
  132. <text class="f-s-26"> 繁育管理 </text>
  133. </view>
  134. </up-button>
  135. <up-button v-else :customStyle="customStyle2" @click.stop="$emit('toSupervise')">
  136. <view class="d-flex a-c j-c">
  137. <image class="w-28 h-24" src="https://yujin-szyy.oss-cn-chengdu.aliyuncs.com/szyy/images-plt/plant/port/Task_Breeding_management.png" mode="widthFix" />
  138. <text class="f-s-26"> 种植管理 </text>
  139. </view>
  140. </up-button>
  141. <up-button :customStyle="customStyle3" @click.stop="$emit('toHarvest')">
  142. <view class="d-flex a-c j-c">
  143. <image class="w-28 h-24" src="https://yujin-szyy.oss-cn-chengdu.aliyuncs.com/szyy/images-plt/plant/port/Task_Harvest_management.png" mode="widthFix" />
  144. <text class="f-s-26">采收管理</text>
  145. </view>
  146. </up-button>
  147. </view>
  148. </view>
  149. </view>
  150. <!-- 种植 -->
  151. <view class="" v-if="data.taskType === '1'">
  152. <view class="b-radius bg-#fff pd-10 p-rtv">
  153. <image class="w-80 h-34" src="https://yujin-szyy.oss-cn-chengdu.aliyuncs.com/szyy/images-plt/plant/port/Task_Planting.png" mode="widthFix" style="position: absolute; top: 0; left: 0" />
  154. <image v-if="+status == 9" class="w-98 h-98" src="https://yujin-szyy.oss-cn-chengdu.aliyuncs.com/szyy/images-plt/plant/port/over.png" mode="widthFix" style="position: absolute; top: 50rpx; right: 20rpx" />
  155. <view class="d-flex j-ed f-s-22 c-#666">{{ data?.plannedStartDate }}至{{ data?.plannedEndDate }}</view>
  156. <view class="d-flex a-ed pd-16 pt-8 pb-8" @click.stop="$emit('cardClick')">
  157. <view class="c-#333 f-s-34 f-w-5 mr-6">{{ data?.variety }}</view>
  158. <view class="c-#666 f-s-26">{{ data?.genusName }}</view>
  159. </view>
  160. <view class="d-flex f-s-28 pd-16 pt-8 pb-8" @click.stop="$emit('cardClick')">
  161. <view class="c-#666 w-s-no">种植批号:</view>
  162. <view class="c-#333 f-w-5">{{ data?.plantationCode }}</view>
  163. </view>
  164. <view class="d-flex f-s-28 pd-16 pt-8 pb-8" @click.stop="$emit('cardClick')">
  165. <view class="c-#666 w-s-no">种源批号:</view>
  166. <view v-if="data?.seedCodeList.length !== 0">
  167. <view class="c-#333 f-w-5" v-for="item in data?.seedCodeList" :key="item">{{ item }}</view>
  168. </view>
  169. <view v-else>
  170. <view class="c-#666">暂无完善种源信息</view>
  171. </view>
  172. </view>
  173. <view class="d-flex a-c f-s-28 pd-16 pt-8 pb-8" @click.stop="$emit('cardClick')">
  174. <view class="c-#666 w-s-no">基地:</view>
  175. <view class="c-#333 f-w-5 tx-ov w-s-no ov-hd d-flex a-c">
  176. {{ data?.baseRef?.baseName }}
  177. <text v-if="+data?.landFlag">全部地块</text>
  178. <view v-else>
  179. <text v-for="(item, index) in data?.baseRef?.baseInfo?.landList" :key="index"><text v-if="index != 0">、</text> {{ item?.landName }}</text>
  180. </view>
  181. </view>
  182. <view class="flex1 d-flex j-ed"><up-icon name="arrow-right" size="34rpx"></up-icon></view>
  183. </view>
  184. <view class="d-flex f-s-28 pd-16 pt-8 pb-8" @click.stop="$emit('cardClick')">
  185. <view class="d-flex a-c w-50%">
  186. <view class="c-#666 w-s-no">种植面积:</view>
  187. <view class="c-#333 f-w-5 tx-ov w-s-no ov-hd">{{ data?.plantingAmount }}{{ data?.plantingUnit }} </view>
  188. </view>
  189. <view class="d-flex a-c w-50%">
  190. <view class="c-#666 w-s-no">种植量:</view>
  191. <view class="c-#333 f-w-5 tx-ov w-s-no ov-hd">{{ data?.plantingMgAmount }}{{ data?.plantingMgUnit }} </view>
  192. </view>
  193. </view>
  194. <view class="pd-16 pt-8 pb-8">
  195. <up-line color="#f7f7f7"></up-line>
  196. </view>
  197. <view class="pd-16 pt-8 pb-8 d-flex j-sb gap-20">
  198. <up-button :customStyle="customStyle1" @click.stop="$emit('toInformation')">
  199. <view class="d-flex a-c j-c">
  200. <image class="w-28 h-24" src="https://yujin-szyy.oss-cn-chengdu.aliyuncs.com/szyy/images-plt/plant/port/Task_Species_source_information.png" mode="widthFix" />
  201. <text class="f-s-26">种源信息</text>
  202. </view>
  203. </up-button>
  204. <up-button :customStyle="customStyle2" @click.stop="$emit('toSupervise')">
  205. <view class="d-flex a-c j-c">
  206. <image class="w-28 h-24" src="https://yujin-szyy.oss-cn-chengdu.aliyuncs.com/szyy/images-plt/plant/port/Task_Breeding_management.png" mode="widthFix" />
  207. <text class="f-s-26"> 种植管理 </text>
  208. </view>
  209. </up-button>
  210. <up-button :customStyle="customStyle3" @click.stop="$emit('toHarvest')">
  211. <view class="d-flex a-c j-c">
  212. <image class="w-28 h-24" src="https://yujin-szyy.oss-cn-chengdu.aliyuncs.com/szyy/images-plt/plant/port/Task_Harvest_management.png" mode="widthFix" />
  213. <text class="f-s-26">采收管理</text>
  214. </view>
  215. </up-button>
  216. </view>
  217. </view>
  218. </view>
  219. <!-- 种畜繁育 -->
  220. <view class="" v-if="data.taskType === '21'">
  221. <view class="b-radius bg-#fff pd-10 p-rtv">
  222. <image class="w-112 h-34" src="https://yujin-szyy.oss-cn-chengdu.aliyuncs.com/szyy/images-plt/plant/port/Task_Breeding_Livestock.png" mode="widthFix" style="position: absolute; top: 0; left: 0" />
  223. <image v-if="+status == 9" class="w-98 h-98" src="https://yujin-szyy.oss-cn-chengdu.aliyuncs.com/szyy/images-plt/plant/port/over.png" mode="widthFix" style="position: absolute; top: 50rpx; right: 20rpx" />
  224. <view class="d-flex j-ed f-s-22 c-#666">{{ data?.plannedStartDate }}至{{ data?.plannedEndDate }}</view>
  225. <view class="d-flex a-ed pd-16 pt-8 pb-8" @click.stop="$emit('cardClick')">
  226. <view class="c-#333 f-s-34 f-w-5 mr-6">{{ data?.variety }}</view>
  227. <view class="c-#666 f-s-26">{{ data?.genusName }}</view>
  228. </view>
  229. <view class="d-flex f-s-28 pd-16 pt-8 pb-8" @click.stop="$emit('cardClick')">
  230. <view class="c-#666 w-s-no">繁育批号:</view>
  231. <view class="c-#333 f-w-5">{{ data?.plantationCode }}</view>
  232. </view>
  233. <view class="d-flex f-s-28 pd-16 pt-8 pb-8" @click.stop="$emit('cardClick')">
  234. <view class="c-#666 w-s-no">种源批号:</view>
  235. <view v-if="data?.seedCodeList.length !== 0">
  236. <view class="c-#333 f-w-5" v-for="item in data?.seedCodeList" :key="item">{{ item }}</view>
  237. </view>
  238. <view v-else>
  239. <view class="c-#666">暂无完善种源信息</view>
  240. </view>
  241. </view>
  242. <view class="d-flex a-c f-s-28 pd-16 pt-8 pb-8" @click.stop="$emit('cardClick')">
  243. <view class="c-#666 w-s-no">基地:</view>
  244. <view class="c-#333 f-w-5 tx-ov w-s-no ov-hd d-flex a-c">
  245. {{ data?.baseRef?.baseName }}
  246. <text v-if="+data?.landFlag">全部地块</text>
  247. <view v-else>
  248. <text v-for="(item, index) in data?.baseRef?.baseInfo?.landList" :key="index"> <text v-if="index != 0">、</text> {{ item?.landName }}</text>
  249. </view>
  250. </view>
  251. <view class="flex1 d-flex j-ed"><up-icon name="arrow-right" size="34rpx"></up-icon></view>
  252. </view>
  253. <view class="d-flex f-s-28 pd-16 pt-8 pb-8" @click.stop="$emit('cardClick')">
  254. <view class="d-flex a-c w-50%">
  255. <view class="c-#666 w-s-no">养殖区域:</view>
  256. <view class="c-#333 f-w-5 tx-ov w-s-no ov-hd">{{ data?.breedScale }}{{ data?.breedScaleUnit }} </view>
  257. </view>
  258. <view class="d-flex a-c w-50%">
  259. <view class="c-#666 w-s-no">养殖量:</view>
  260. <view class="c-#333 f-w-5 tx-ov w-s-no ov-hd">{{ data?.plantingMgAmount }}{{ data?.plantingMgUnit }} </view>
  261. </view>
  262. </view>
  263. <view class="pd-16 pt-8 pb-8">
  264. <up-line color="#f7f7f7"></up-line>
  265. </view>
  266. <view class="pd-16 pt-8 pb-8 d-flex j-sb gap-20">
  267. <up-button :customStyle="customStyle1" @click.stop="$emit('toInformation')">
  268. <view class="d-flex a-c j-c">
  269. <image class="w-28 h-24" src="https://yujin-szyy.oss-cn-chengdu.aliyuncs.com/szyy/images-plt/plant/port/Task_Species_source_information.png" mode="widthFix" />
  270. <text class="f-s-26">种源信息</text>
  271. </view>
  272. </up-button>
  273. <up-button :customStyle="customStyle2" @click.stop="$emit('toSupervise')">
  274. <view class="d-flex a-c j-c">
  275. <image class="w-28 h-24" src="https://yujin-szyy.oss-cn-chengdu.aliyuncs.com/szyy/images-plt/plant/port/Task_Breeding_management.png" mode="widthFix" />
  276. <text class="f-s-26">饲养管理</text>
  277. </view>
  278. </up-button>
  279. <up-button :customStyle="customStyle3" @click.stop="$emit('toHarvest')">
  280. <view class="d-flex a-c j-c">
  281. <image class="w-28 h-24" src="https://yujin-szyy.oss-cn-chengdu.aliyuncs.com/szyy/images-plt/plant/port/Task_Harvest_management.png" mode="widthFix" />
  282. <text class="f-s-26">采收管理</text>
  283. </view>
  284. </up-button>
  285. </view>
  286. </view>
  287. </view>
  288. </template>
  289. <script setup lang="ts">
  290. const props = defineProps<{ data: any; status: any }>();
  291. //按钮样式
  292. const customStyle1 = reactive({
  293. color: '#37A954',
  294. boxShadow: 'inset 0 0 10px #D7F5DF',
  295. background: '#ECFFF1',
  296. border: '2rpx solid #9BD4A9',
  297. borderRadius: '10rpx',
  298. height: '76rpx',
  299. });
  300. const customStyle2 = reactive({
  301. color: '#18BECA',
  302. boxShadow: 'inset 0 0 10px #C7F5F8',
  303. background: '#E5FDFF',
  304. border: '2rpx solid #93E8EE',
  305. borderRadius: '10rpx',
  306. height: '76rpx',
  307. });
  308. const customStyle3 = reactive({
  309. color: '#FC8834',
  310. boxShadow: 'inset 0 0 10px #FFEED7',
  311. background: '#FFFAF3',
  312. border: '2rpx solid #FFD499',
  313. borderRadius: '10rpx',
  314. height: '76rpx',
  315. });
  316. </script>