应用层PC端前端服务

courtReview.vue 5.7KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229
  1. <template>
  2. <div>
  3. <!-- 组庭界面 -->
  4. <el-dialog
  5. title="组庭建议"
  6. :visible="caseVisableReview"
  7. v-if="caseVisableReview"
  8. @close="cancel"
  9. destroy-on-close
  10. center
  11. >
  12. <el-form
  13. ref="formateCourtform"
  14. :model="formateCourtform"
  15. label-width="110px"
  16. label-position="left"
  17. >
  18. <el-form-item label="是否同意组庭:">
  19. <el-radio-group v-model="isAgreePendTral" @change="radioValue">
  20. <el-radio :label="1">是</el-radio>
  21. <el-radio :label="0">否</el-radio>
  22. </el-radio-group>
  23. </el-form-item>
  24. <el-tag type="warning" v-if="noArbitrator"
  25. >当前案件未指定仲裁员,请先指定仲裁员!</el-tag
  26. >
  27. <p></p>
  28. <!-- <el-form ref="form"> -->
  29. <!-- v-if="isAgreePendTral == 0 || noArbitrator" -->
  30. <div style="display: inline-flex; margin-bottom: 8px">
  31. <div v-if="isAgreePendTral !== 1">请选择仲裁员</div>
  32. <div v-if="isAgreePendTral == 1">
  33. 当前案件仲裁员
  34. </div>
  35. </div>
  36. <div
  37. v-if="isAgreePendTral == 1"
  38. class="nowarbitrator"
  39. >
  40. <el-tag size="medium">
  41. <!-- {{ formateCourtData.arbitratorName }} -->
  42. </el-tag>
  43. </div>
  44. <el-form-item
  45. label="仲裁员:"
  46. prop="Arbitor"
  47. :rules="[
  48. {
  49. required: true,
  50. message: '仲裁员不能为空',
  51. },
  52. ]"
  53. >
  54. <el-select
  55. placeholder="请选择仲裁员"
  56. @change="changeArbitor"
  57. v-model="formateCourtform.Arbitor"
  58. clearable
  59. >
  60. <el-option
  61. v-for="item in dataList"
  62. :key="item.value"
  63. :label="item.nickNameAndNum"
  64. :value="item.userId"
  65. ></el-option>
  66. </el-select>
  67. </el-form-item>
  68. </el-form>
  69. <div slot="footer" class="dialog-footer">
  70. <el-button type="primary" @click="submitForm" class="endbutton"
  71. ><span>确 定</span></el-button
  72. >
  73. <el-button @click="cancel" class="endbutton1"
  74. ><span>取 消</span></el-button
  75. >
  76. </div>
  77. </el-dialog>
  78. </div>
  79. </template>
  80. <script>
  81. import { arbitrAtor, pendTralCheck } from "@/api/formationCourt/formationCourt";
  82. export default {
  83. props: ["caseVisableReview", "formateCourtData", "queryParams"],
  84. data() {
  85. return {
  86. dataList: [],
  87. formateCourtform: {},
  88. arbitrators: [],
  89. isAgreePendTral: 1,
  90. paramsdata: {},
  91. noArbitrator: false,
  92. Arbitor: "",
  93. };
  94. },
  95. created() {
  96. this.getarbitrAtor();
  97. },
  98. watch: {
  99. caseVisableReview(val){
  100. console.log(this.formateCourtData)
  101. this.Arbitor = ""
  102. if(val){
  103. this.isAgreePendTral = 1;
  104. }
  105. },
  106. // formateCourtData: {
  107. // handler(val) {
  108. // if (val.arbitratorName == null) {
  109. // this.noArbitrator = true;
  110. // } else {
  111. // this.noArbitrator = false;
  112. // }
  113. // },
  114. // },
  115. },
  116. methods: {
  117. // 获取仲裁员信息
  118. getarbitrAtor() {
  119. arbitrAtor({}).then((res) => {
  120. this.dataList = res.rows;
  121. // console.log(this.dataList, "this.dataList");
  122. });
  123. },
  124. changeArbitor(val) {
  125. this.arbitrators = [];
  126. this.dataList.forEach((item) => {
  127. if (item.userId == val) {
  128. this.arbitrators.push({
  129. id: item.userId,
  130. arbitratorName: item.nickName,
  131. });
  132. }
  133. });
  134. },
  135. // 确认
  136. submitForm() {
  137. if (this.noArbitrator) {
  138. this.paramsdata = {
  139. id: this.formateCourtData.id,
  140. arbitrators: this.arbitrators,
  141. };
  142. } else {
  143. if (this.isAgreePendTral == 0) {
  144. this.paramsdata = {
  145. isAgreePendTral: 0,
  146. id: this.formateCourtData.id,
  147. arbitrators: this.arbitrators,
  148. };
  149. } else {
  150. this.paramsdata = {
  151. isAgreePendTral: 1,
  152. id: this.formateCourtData.id,
  153. };
  154. }
  155. }
  156. this.$refs["formateCourtform"].validate((valid) => {
  157. if (valid) {
  158. pendTralCheck(this.paramsdata).then((res) => {
  159. this.cancel();
  160. this.$modal.msgSuccess("组庭成功");
  161. this.$emit("getcaseApply", this.queryParams);
  162. // 初始化页面
  163. this.formateCourtform={}
  164. });
  165. }
  166. });
  167. },
  168. // 取消
  169. cancel() {
  170. this.$emit("cancelCaseReview");
  171. this.arbitrators = [];
  172. },
  173. radioValue(val){
  174. if(val==1){
  175. this.formateCourtform={}
  176. }else if(val==0){
  177. this.formateCourtform={}
  178. }
  179. }
  180. },
  181. };
  182. </script>
  183. <style lang="scss" scoped>
  184. ::v-deep .el-dialog {
  185. background: #ffffff;
  186. border-radius: 20px;
  187. }
  188. .endbutton {
  189. width: 124px;
  190. height: 37px;
  191. background: #0072ff;
  192. border-radius: 19px;
  193. span {
  194. width: 32px;
  195. height: 15px;
  196. font-size: 16px;
  197. font-family: Microsoft YaHei;
  198. font-weight: 400;
  199. color: #ffffff;
  200. }
  201. }
  202. .endbutton1 {
  203. width: 124px;
  204. height: 37px;
  205. background: #ffffff;
  206. border: 1px solid #d0d0d0;
  207. border-radius: 19px;
  208. span {
  209. width: 31px;
  210. height: 13px;
  211. font-size: 16px;
  212. font-family: Microsoft YaHei;
  213. font-weight: 400;
  214. color: #959595;
  215. }
  216. }
  217. .infoIcon {
  218. width: 4px;
  219. // height: 17px;
  220. background-color: #0072ff;
  221. margin-right: 5px;
  222. }
  223. .nowarbitrator {
  224. margin-left: 4%;
  225. }
  226. </style>