index.vue 8.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335
  1. <template>
  2. <view class="content">
  3. <!-- 搜索框 -->
  4. <view class="sousuo">
  5. <view class="iconfont icon-sousuo" style="margin: 0 30rpx 0 30rpx;"></view>
  6. <input class="sou-text" placeholder="请输入查询内容" v-model="keyword"></input>
  7. </view>
  8. <!-- 筛选 -->
  9. <view class="select2">
  10. <view class="wei-title1 title1" v-if="select==0">
  11. <view>我收藏的</view>
  12. <view class="wei-line1"></view>
  13. </view>
  14. <view class="title1" style="rgba(0, 0, 0, 1)" v-else @click="select=0">
  15. 我收藏的
  16. <view class="wei-line1" style="background: rgba(255, 255, 255, 1);"></view>
  17. </view>
  18. <view class="wei-title1 title2" v-if="select==1">
  19. <view>我负责的</view>
  20. <view class="wei-line1"></view>
  21. </view>
  22. <view class="title2" style="rgba(0, 0, 0, 1)" v-else @click="select=1">
  23. 我负责的
  24. <view class="wei-line1" style="background: rgba(255, 255, 255, 1);"></view>
  25. </view>
  26. <view class="wei-title1 title3" v-if="select==2">
  27. <view>我参与的</view>
  28. <view class="wei-line1"></view>
  29. </view>
  30. <view class="title3" style="rgba(0, 0, 0, 1)" v-else @click="select=2">
  31. 我参与的
  32. <view class="wei-line1" style="background: rgba(255, 255, 255, 1);"></view>
  33. </view>
  34. </view>
  35. <!-- 数据列表 -->
  36. <view class="kuang">
  37. <view class="all-select">
  38. <view class="all-list" style="margin-left: 15rpx;" v-if="change==0">超时在办</view>
  39. <view class="all-list2" style="margin-left: 15rpx;" v-else @click="changeTime(0)">超时在办</view>
  40. <view class="all-list" style="margin-left: 15rpx;" v-if="change==1">预警在办</view>
  41. <view class="all-list2" style="margin-left: 15rpx;" v-else @click="changeTime(1)">预警在办</view>
  42. <view class="all-list" style="margin-left: 15rpx;" v-if="change==2">正常在办</view>
  43. <view class="all-list2" style="margin-left: 15rpx;" v-else @click="changeTime(2)">正常在办</view>
  44. <view class="all-list" style="margin-left: 15rpx;" v-if="change==3">正常办结</view>
  45. <view class="all-list2" style="margin-left: 15rpx;" v-else @click="changeTime(3)">正常办结</view>
  46. </view>
  47. <!-- 数据列表循环 -->
  48. <view class="list" v-for="(item,index) in list" :key="index">
  49. <view class="list-proname">
  50. {{item.proName}}
  51. <view class="list-kua">{{item.txt}}</view>
  52. <view class="bu-shou yishou" v-if="item.shouc==1">已收藏</view>
  53. <view class="bu-shou shou" v-else>收藏</view>
  54. <view class="bu-shou jinji" v-if="item.jinji==1">紧急</view>
  55. <view class="bu-shou norl" v-else>正常</view>
  56. <view class="bu-shou more">
  57. <view>更多</view>
  58. <view class="xiala">
  59. <view>复制</view>
  60. <view @click.stop="changePro">编辑</view>
  61. <view>删除</view>
  62. <view>评分</view>
  63. </view>
  64. </view>
  65. </view>
  66. <view class="list-dan">主办单位:{{item.danwei}}</view>
  67. <view class="list-dan">主办人:周三</view>
  68. <view class="list-dan">项目周期:{{item.danwei}}</view>
  69. <view class="list-dan">任务:30个</view>
  70. <view class="list-dan">预警次数:30次</view>
  71. <view class="list-dan">提醒次数:30次</view>
  72. <view class="list-dan" style="width: 620rpx;display: flex;">
  73. 项目进度:
  74. <progress v-if="item.batteryName!='/'" style="width: 380rpx;" :percent="item.batteryName" activeColor="rgba(0, 97, 255, 1)" border-radius="50" stroke-width="9" show-info font-size='12' active='true' />
  75. <image src="../../static/project/warn.png" style="width: 43rpx;height: 43rpx;margin-top: 10rpx;"></image>
  76. </view>
  77. </view>
  78. <view style="width: 100%;height: 100rpx;"></view>
  79. </view>
  80. <!-- 添加项目 -->
  81. <view class="serviceBtn" @click.stop="addProject"></view>
  82. </view>
  83. </template>
  84. <script>
  85. export default {
  86. data() {
  87. return {
  88. select:0,
  89. change:0,
  90. list:[
  91. {proName:'xx项目',txt:'涉外',danwei:'交通学院',jinji:1,shouc:1,batteryName:'60'},
  92. {proName:'xx项目',txt:'涉外',danwei:'交通学院',jinji:0,shouc:0,batteryName:'70'},
  93. ],
  94. }
  95. },
  96. onLoad() {
  97. },
  98. methods: {
  99. //修改时间框
  100. changeTime(a){
  101. this.change=a
  102. if(a==1){
  103. }
  104. },
  105. // 新建项目
  106. addProject(){
  107. uni.navigateTo({
  108. url:'/pages/project/addProject'
  109. })
  110. },
  111. //编辑项目
  112. changePro(){
  113. uni.navigateTo({
  114. url:'/pages/project/projectChange'
  115. })
  116. }
  117. }
  118. }
  119. </script>
  120. <style lang="scss" scoped>
  121. .content {
  122. display: flex;
  123. flex-direction: column;
  124. align-items: center;
  125. justify-content: center;
  126. .serviceBtn{
  127. position: fixed;
  128. right: 50rpx;
  129. bottom: 300rpx;
  130. display: flex;
  131. flex-direction: column;
  132. align-items: center;
  133. justify-content: center;
  134. width: 97rpx;
  135. height: 97rpx;
  136. background-image: url('../../static/project/add.png');
  137. background-size: 100%;
  138. }
  139. }
  140. /* 搜索框 */
  141. .sousuo{
  142. display: flex;
  143. align-items: center;
  144. margin: 20rpx 0 0 20rpx;
  145. width: 710rpx;
  146. height: 90rpx;
  147. border-radius: 98rpx;
  148. background: rgba(255, 255, 255, 1);
  149. }
  150. .sou-text{
  151. font-size: 28rpx;
  152. line-height: 40rpx;
  153. color: rgba(166, 166, 166, 1);
  154. width: 100%;
  155. }
  156. .sou-text>>>.uni-input-input {
  157. position: relative;
  158. display: block;
  159. height: 100%;
  160. background: none;
  161. color: inherit;
  162. opacity: 1;
  163. font: inherit;
  164. line-height: inherit;
  165. letter-spacing: inherit;
  166. text-align: inherit;
  167. text-indent: inherit;
  168. text-transform: inherit;
  169. text-shadow: inherit;
  170. width: 185px;
  171. height: 35px;
  172. border-radius: 85px;
  173. /* background: rgba(242, 242, 242, 1); */
  174. }
  175. /* 筛选 */
  176. .select2{
  177. margin: 20rpx 0 0 0;
  178. width: 100%;
  179. height: 120rpx;
  180. background: rgba(255, 255, 255, 1);
  181. }
  182. .wei-title1{
  183. color: rgba(0, 97, 255, 1);
  184. }
  185. .title1{
  186. margin: 40rpx 0 0 48rpx;
  187. font-size: 28rpx;
  188. }
  189. .title2{
  190. margin: -41px 0 0 318rpx;
  191. font-size: 28rpx;
  192. }
  193. .title3{
  194. margin: -41px 0 0 588rpx;
  195. font-size: 28rpx;
  196. }
  197. .wei-line1{
  198. margin: 31rpx 0 0 15rpx;
  199. width: 79rpx;
  200. height: 8rpx;
  201. border-radius: 75rpx;
  202. background: rgba(0, 97, 255, 1);
  203. }
  204. /* 数据列表 */
  205. .kuang{
  206. margin: 20rpx 0 0 0;
  207. width: 100%;
  208. background: rgba(255, 255, 255, 1);
  209. }
  210. .all-select{
  211. display: flex;
  212. margin: 31rpx 0 0 19rpx;
  213. width: 712rpx;
  214. height: 90rpx;
  215. border-radius: 7rpx;
  216. background: rgba(242, 247, 255, 1);
  217. align-items: center;
  218. }
  219. .all-list{
  220. width: 159rpx;
  221. height: 71rpx;
  222. border-radius: 7rpx;
  223. background: rgba(0, 97, 255, 0.1);
  224. border: 1rpx solid rgba(0, 97, 255, 1);
  225. font-size: 28rpx;
  226. line-height: 71rpx;
  227. color: rgba(0, 97, 255, 1);
  228. text-align: center;
  229. }
  230. .all-list2{
  231. width: 159rpx;
  232. height: 71rpx;
  233. border-radius: 7rpx;
  234. font-size: 28rpx;
  235. line-height: 71rpx;
  236. color: rgba(56, 56, 56, 1);
  237. text-align: center;
  238. }
  239. /* 数据列表循环 */
  240. .list{
  241. display: flex;
  242. flex-direction: column;
  243. margin: 20rpx 0 0 20rpx;
  244. width: 709rpx;
  245. height: 422rpx;
  246. border-radius: 7rpx;
  247. background: rgba(245, 248, 255, 1);
  248. box-shadow: 0px 4rpx 6rpx rgba(0, 0, 0, 0.05);
  249. font-size: 24rpx;
  250. line-height: 35rpx;
  251. }
  252. .list-proname{
  253. margin: 13rpx 0 0 29rpx;
  254. font-size: 29rpx;
  255. font-weight: 500;
  256. display: flex;
  257. }
  258. .list-kua{
  259. margin-left: 5px;
  260. width: 59rpx;
  261. height: 29rpx;
  262. border-radius: 4rpx;
  263. border: 2rpx solid rgba(33, 107, 255, 1);
  264. font-size: 22rpx;
  265. line-height: 29rpx;
  266. color: rgba(33, 107, 255, 1);
  267. text-align: center;
  268. }
  269. .bu-shou{
  270. width: 87rpx;
  271. height: 44rpx;
  272. border-radius: 7rpx;
  273. font-size: 24rpx;
  274. line-height: 44rpx;
  275. text-align: center;
  276. color: rgba(255, 255, 255, 1);
  277. }
  278. .yishou{
  279. margin: 10rpx 0 0 222rpx;
  280. background: rgba(9, 101, 98, 1);
  281. }
  282. .shou{
  283. margin: 10rpx 0 0 222rpx;
  284. background: rgba(0, 97, 255, 1);
  285. }
  286. .jinji{
  287. margin: 10rpx 0 0 15rpx;
  288. background: rgba(254, 144, 51, 1);
  289. }
  290. .norl{
  291. margin: 10rpx 0 0 15rpx;
  292. background: rgba(166, 166, 166, 1);
  293. color: rgba(255, 255, 255, 1);
  294. }
  295. .more{
  296. margin: 10rpx 0 0 15rpx;
  297. background: rgba(0, 97, 255, 1);
  298. }
  299. .xiala{
  300. z-index: 4;
  301. position: relative;
  302. width: 87rpx;
  303. height: 174rpx;
  304. border-radius: 2rpx;
  305. background: rgba(255, 255, 255, 1);
  306. box-shadow: 0px 4rpx 4rpx rgba(0, 0, 0, 0.1);
  307. color: rgba(0, 0, 0, 1);
  308. }
  309. .list-dan{
  310. margin: 9rpx 0 0 29rpx;
  311. }
  312. >>>.uni-progress-bar {
  313. border-radius: 9rpx;
  314. }
  315. >>>.uni-progress-inner-bar {
  316. border-radius: 9rpx;
  317. }
  318. >>>.uni-progress-info {
  319. margin-top: 0;
  320. margin-bottom: 0;
  321. min-width: 2em;
  322. margin-left: 15px;
  323. font-size: 24rpx;
  324. color: rgba(0, 0, 0, 1);
  325. }
  326. >>>uni-progress {
  327. // width: 42%;
  328. // margin: 25rpx 0 0 144rpx;
  329. }
  330. </style>