移动端
Não pode escolher mais do que 25 tópicos Os tópicos devem começar com uma letra ou um número, podem incluir traços ('-') e podem ter até 35 caracteres.
 
 

293 linhas
8.9 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. <van-field label="备注" v-model="jgList.bz" placeholder="填写备注" input-align="right" label-width="auto"/>
  100. </div>
  101. <p class="main_title">违法信息</p>
  102. <div class="main_box">
  103. <van-field
  104. readonly
  105. clickable
  106. label="违法用地类型"
  107. placeholder="请选择"
  108. v-model="wfydlx"
  109. @click="showwfydlx = true"
  110. input-align="right"
  111. right-icon="arrow-down"
  112. />
  113. <van-popup v-model="showwfydlx" position="bottom">
  114. <van-picker
  115. show-toolbar
  116. :columns="wfydlxDictionaries"
  117. @confirm="onConfirmWfydlx"
  118. @cancel="showwfydlx = false"
  119. />
  120. </van-popup>
  121. <van-field v-model="jgList.wfydmj" label="违法用地面积" placeholder="请输入面积" input-align="right" label-width="auto"/>
  122. <van-field v-model="jgList.fmkje" label="罚没款金额" placeholder="请输入金额" input-align="right" label-width="auto"/>
  123. <van-field v-model="jgList.msmj" label="没收面积" placeholder="请输入面积" input-align="right" label-width="auto"/>
  124. <van-field v-model="jgList.ccmj" label="拆除面积" placeholder="请输入面积" input-align="right" label-width="auto"/>
  125. <van-field
  126. readonly
  127. clickable
  128. label="整改截止时间"
  129. placeholder="选择整改截止时间"
  130. v-model="jgList.reformDeadline"
  131. @click="showReformDeadline = true"
  132. input-align="right"
  133. right-icon="arrow-down"
  134. />
  135. <van-popup v-model="showReformDeadline" position="bottom">
  136. <van-datetime-picker
  137. v-model="currentDate"
  138. type="date"
  139. title="选择年月日"
  140. :min-date="minDate"
  141. :max-date="maxDate"
  142. @confirm="onConfirmReformDeadline"
  143. />
  144. </van-popup>
  145. </div>
  146. <div style="padding: 16px 0;" v-if="allowCUD">
  147. <van-row>
  148. <van-col span="12" align="center">
  149. <van-button type="info" color="#B4B0B0" native-type="submit" @click="goBack" class="submitButton">取<i style="margin-right: 1em;"></i>消</van-button>
  150. </van-col>
  151. <van-col span="12" align="center">
  152. <van-button type="info" native-type="submit" @click="goAdd" class="submitButton">修<i style="margin-right: 1em;"></i>改</van-button>
  153. </van-col>
  154. </van-row>
  155. <div class="clear"></div>
  156. </div>
  157. </div>
  158. </template>
  159. <script>
  160. import { supervisionAdd , getSupervision } from "@/api/onlineHome/homestead/supervision";
  161. export default {
  162. name: "supervisionModify",
  163. data() {
  164. return {
  165. showSys:false,
  166. showjglx:false,
  167. showlasj:false,
  168. showinspectorTime:false,
  169. showwfydlx:false,
  170. showReformDeadline:false,
  171. minDate: new Date(),
  172. maxDate: new Date(2025, 10, 1),
  173. currentDate: new Date(),
  174. jgList:{},
  175. sfzjjzw:'',
  176. jglx:'',
  177. wfydlx:'',
  178. wfydlxDictionaries:[],
  179. jglxDictionaries:[],
  180. sysDictionaries:[],
  181. };
  182. },
  183. created() {
  184. this.getTaskGet();
  185. },
  186. computed: {
  187. allowCUD: function () {
  188. return this.$store.getters.businessLevel == '2'
  189. },
  190. },
  191. methods: {
  192. getTaskGet(){
  193. getSupervision(this.$route.query.id).then(response => {
  194. console.log(response)
  195. //违法用地类型
  196. this.houseGetDicts("villations_type").then((res) => {
  197. for(var i = 0 ; i < res.data.length ; i++){
  198. this.wfydlxDictionaries.push({text:res.data[i].dictLabel,value:res.data[i].dictValue});
  199. }
  200. this.wfydlx = this.selectDictLabel(res.data, response.data.wfydlx);
  201. });
  202. //监管类型
  203. this.houseGetDicts("jglx").then((res) => {
  204. for(var i = 0 ; i < res.data.length ; i++){
  205. this.jglxDictionaries.push({text:res.data[i].dictLabel,value:res.data[i].dictValue});
  206. }
  207. this.jglx = this.selectDictLabel(res.data, response.data.jglx);
  208. });
  209. //是否在建建筑物
  210. this.houseGetDicts("sys_yes_no").then((res) => {
  211. for(var i = 0 ; i < res.data.length ; i++){
  212. this.sysDictionaries.push({text:res.data[i].dictLabel,value:res.data[i].dictValue});
  213. }
  214. this.sfzjjzw = this.selectDictLabel(res.data, response.data.sfzjjzw);
  215. });
  216. this.jgList = response.data;
  217. });
  218. },
  219. onConfirmSys(data){
  220. this.sfzjjzw = data.text;
  221. this.jgList.sfzjjzw = data.value;
  222. this.showSys = false;
  223. },
  224. onConfirmJglx(data){
  225. this.jglx = data.text;
  226. this.jgList.jglx = data.value;
  227. this.showjglx = false;
  228. },
  229. onConfirmWfydlx(data){
  230. this.wfydlx = data.text;
  231. this.jgList.wfydlx = data.value;
  232. this.showwfydlx = false;
  233. },
  234. onConfirmLasj(data){
  235. this.jgList.lasj = this.getNowFormatDate(data).substr(0,10);
  236. this.showlasj = false;
  237. },
  238. onConfirmInspectorTime(data){
  239. this.jgList.inspectorTime = this.getNowFormatDate(data).substr(0,10);
  240. this.showinspectorTime = false;
  241. },
  242. onConfirmReformDeadline(data){
  243. this.jgList.reformDeadline = this.getNowFormatDate(data).substr(0,10);
  244. this.showReformDeadline = false;
  245. },
  246. goAdd(){
  247. supervisionAdd(this.jgList).then(response => {
  248. console.log(response);
  249. this.$toast.success('保存成功');
  250. setTimeout(function(){
  251. history.go(-1)
  252. },2000)
  253. });
  254. },
  255. goBack(){
  256. window.history.go(-1)
  257. }
  258. },
  259. }
  260. </script>
  261. <style scoped lang="scss">
  262. .app-container {
  263. padding: 2% 0;
  264. }
  265. .main_title{
  266. font-size: 0.4rem;
  267. color: #1D6FE9;
  268. margin: 0.2rem 6%;
  269. position: relative;
  270. }
  271. .main_box{
  272. width: 96%;
  273. margin: 0 auto;
  274. border-radius: 6px;
  275. box-shadow: 0px 3px 6px 0px rgba(0,0,0,0.16);
  276. overflow: hidden;
  277. background-color: #FFF;
  278. }
  279. .submitButton{
  280. width: 80%;
  281. margin: 0 auto;
  282. background-color: #1D6FE9;
  283. }
  284. </style>