移动端
Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.
 
 

262 rindas
7.6 KiB

  1. <template>
  2. <div class="app-container">
  3. <van-nav-bar
  4. left-arrow
  5. fixed
  6. placeholder
  7. @click-left="$router.back(-1)"
  8. >
  9. <template #title>
  10. <p style="font-weight: bold;">任务上报</p>
  11. </template>
  12. </van-nav-bar>
  13. <div class="main_box">
  14. <van-field
  15. readonly
  16. clickable
  17. label="是否在建建筑物"
  18. placeholder="请选择"
  19. v-model="sfzjjzw"
  20. @click="showSys = true"
  21. input-align="right"
  22. right-icon="arrow-down"
  23. label-width="auto"
  24. />
  25. <van-popup v-model="showSys" position="bottom">
  26. <van-picker
  27. show-toolbar
  28. :columns="sysDictionaries"
  29. @confirm="onConfirmSys"
  30. @cancel="showSys = false"
  31. />
  32. </van-popup>
  33. <van-field label="宅基地代码" v-model="jgList.zjddm" placeholder="请输入宅基地代码" input-align="right" />
  34. <!-- <van-popup v-model="showZjd" position="bottom">-->
  35. <!-- <van-picker-->
  36. <!-- show-toolbar-->
  37. <!-- @cancel="showZjd = false"-->
  38. <!-- />-->
  39. <!-- </van-popup>-->
  40. <van-field
  41. readonly
  42. clickable
  43. label="监管类型"
  44. placeholder="请选择"
  45. v-model="jglx"
  46. @click="showjglx = true"
  47. input-align="right"
  48. right-icon="arrow-down"
  49. />
  50. <van-popup v-model="showjglx" position="bottom">
  51. <van-picker
  52. show-toolbar
  53. :columns="jglxDictionaries"
  54. @confirm="onConfirmJglx"
  55. @cancel="showjglx = false"
  56. />
  57. </van-popup>
  58. <van-field
  59. readonly
  60. clickable
  61. v-model="jgList.lasj"
  62. label="立案时间"
  63. placeholder="请选择立案时间"
  64. @click="showlasj = true"
  65. input-align="right"
  66. right-icon="arrow-down"
  67. />
  68. <van-popup v-model="showlasj" position="bottom">
  69. <van-datetime-picker
  70. v-model="currentDate"
  71. type="date"
  72. title="选择年月日"
  73. :min-date="minDate"
  74. :max-date="maxDate"
  75. @confirm="onConfirmLasj"
  76. />
  77. </van-popup>
  78. <van-field label="巡查人" v-model="jgList.inspector" placeholder="请输入巡查人" input-align="right" label-width="auto"/>
  79. <van-field
  80. readonly
  81. clickable
  82. label="巡查时间"
  83. v-model="jgList.inspectorTime"
  84. placeholder="请选择巡查时间"
  85. @click="showinspectorTime = true"
  86. input-align="right"
  87. right-icon="arrow-down"
  88. />
  89. <van-popup v-model="showinspectorTime" position="bottom">
  90. <van-datetime-picker
  91. v-model="currentDate"
  92. type="date"
  93. title="选择年月日"
  94. :min-date="minDate"
  95. :max-date="maxDate"
  96. @confirm="onConfirmInspectorTime"
  97. />
  98. </van-popup>
  99. </div>
  100. <p class="main_title">违法信息</p>
  101. <div class="main_box">
  102. <van-field
  103. readonly
  104. clickable
  105. label="违法用地类型"
  106. placeholder="请选择"
  107. v-model="wfydlx"
  108. @click="showwfydlx = true"
  109. input-align="right"
  110. right-icon="arrow-down"
  111. />
  112. <van-popup v-model="showwfydlx" position="bottom">
  113. <van-picker
  114. show-toolbar
  115. :columns="wfydlxDictionaries"
  116. @confirm="onConfirmWfydlx"
  117. @cancel="showwfydlx = false"
  118. />
  119. </van-popup>
  120. <van-field v-model="jgList.wfydmj" label="违法用地面积" placeholder="请输入面积" input-align="right" label-width="auto"/>
  121. <van-field v-model="jgList.fmkje" label="罚没款金额" placeholder="请输入金额" input-align="right" label-width="auto"/>
  122. <van-field v-model="jgList.msmj" label="没收面积" placeholder="请输入面积" input-align="right" label-width="auto"/>
  123. <van-field v-model="jgList.ccmj" label="拆除面积" placeholder="请输入面积" input-align="right" label-width="auto"/>
  124. </div>
  125. <div style="padding: 16px 0;" v-if="allowCUD">
  126. <van-row>
  127. <van-col span="12" align="center">
  128. <van-button type="info" color="#B4B0B0" native-type="submit" @click="goBack" class="submitButton">取<i style="margin-right: 1em;"></i>消</van-button>
  129. </van-col>
  130. <van-col span="12" align="center">
  131. <van-button type="info" native-type="submit" @click="goAdd" class="submitButton">上<i style="margin-right: 1em;"></i>报</van-button>
  132. </van-col>
  133. </van-row>
  134. <div class="clear"></div>
  135. </div>
  136. </div>
  137. </template>
  138. <script>
  139. import { jgAdd } from "@/api/onlineHome/homestead/reporting";
  140. export default {
  141. name: "taskCloseCaseAdd",
  142. data() {
  143. return {
  144. showSys:false,
  145. showjglx:false,
  146. showlasj:false,
  147. showinspectorTime:false,
  148. showwfydlx:false,
  149. minDate: new Date(),
  150. maxDate: new Date(2025, 10, 1),
  151. currentDate: new Date(),
  152. jgList:{},
  153. sfzjjzw:'',
  154. jglx:'',
  155. wfydlx:'',
  156. wfydlxDictionaries:[],
  157. jglxDictionaries:[],
  158. sysDictionaries:[],
  159. };
  160. },
  161. created() {
  162. this.getDictionaries();
  163. this.jgList.taskId = this.$route.query.id;
  164. },
  165. computed: {
  166. allowCUD: function () {
  167. return this.$store.getters.businessLevel == '2'
  168. },
  169. },
  170. methods: {
  171. getDictionaries(){
  172. //违法用地类型
  173. this.houseGetDicts("villations_type").then((res) => {
  174. for(var i = 0 ; i < res.data.length ; i++){
  175. this.wfydlxDictionaries.push({text:res.data[i].dictLabel,value:res.data[i].dictValue});
  176. }
  177. });
  178. //监管类型
  179. this.houseGetDicts("jglx").then((res) => {
  180. for(var i = 0 ; i < res.data.length ; i++){
  181. this.jglxDictionaries.push({text:res.data[i].dictLabel,value:res.data[i].dictValue});
  182. }
  183. });
  184. //是否在建建筑物
  185. this.houseGetDicts("sys_yes_no").then((res) => {
  186. for(var i = 0 ; i < res.data.length ; i++){
  187. this.sysDictionaries.push({text:res.data[i].dictLabel,value:res.data[i].dictValue});
  188. }
  189. });
  190. },
  191. onConfirmSys(data){
  192. this.sfzjjzw = data.text;
  193. this.jgList.sfzjjzw = data.value;
  194. this.showSys = false;
  195. },
  196. onConfirmJglx(data){
  197. this.jglx = data.text;
  198. this.jgList.jglx = data.value;
  199. this.showjglx = false;
  200. },
  201. onConfirmWfydlx(data){
  202. this.wfydlx = data.text;
  203. this.jgList.wfydlx = data.value;
  204. this.showwfydlx = false;
  205. },
  206. onConfirmLasj(data){
  207. this.jgList.lasj = this.getNowFormatDate(data).substr(0,10);
  208. this.showlasj = false;
  209. },
  210. onConfirmInspectorTime(data){
  211. this.jgList.inspectorTime = this.getNowFormatDate(data).substr(0,10);
  212. this.showinspectorTime = false;
  213. },
  214. goAdd(){
  215. console.log(this.jgList)
  216. jgAdd(this.jgList).then(response => {
  217. console.log(response);
  218. this.$toast.success('保存成功');
  219. setTimeout(function(){
  220. history.go(-1)
  221. },2000)
  222. });
  223. },
  224. goBack(){
  225. window.history.go(-1)
  226. }
  227. },
  228. }
  229. </script>
  230. <style scoped lang="scss">
  231. .app-container {
  232. padding: 2% 0;
  233. }
  234. .main_title{
  235. font-size: 0.4rem;
  236. color: #1D6FE9;
  237. margin: 0.2rem 6%;
  238. position: relative;
  239. }
  240. .main_box{
  241. width: 96%;
  242. margin: 0 auto;
  243. border-radius: 6px;
  244. box-shadow: 0px 3px 6px 0px rgba(0,0,0,0.16);
  245. overflow: hidden;
  246. background-color: #FFF;
  247. }
  248. .submitButton{
  249. width: 80%;
  250. margin: 0 auto;
  251. background-color: #1D6FE9;
  252. }
  253. </style>