salesContractAdd.vue 63 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903
  1. <template>
  2. <div class="container">
  3. <el-row>
  4. <el-col :span="12">
  5. <h2 class="bg-left title">创建销售合同</h2>
  6. </el-col>
  7. <el-col :span="12" class="bg-right">
  8. <el-button class="bg-bottom" type="primary" size="small" @click="returnsales()"><img width="6" height="10"
  9. style="vertion-align: bottom; margin-right: 3px" src="../../../public/img/lujing.png" alt="" />返回
  10. </el-button>
  11. </el-col>
  12. </el-row>
  13. <div class="center">
  14. <ws-form ref="deptBudgetList" :model="deptBudgetList">
  15. <div class="remark">
  16. <h3>基本信息</h3>
  17. <p style="color: #8890b1">
  18. &nbsp;&nbsp;注:基本信息和货物信息均为必填项,“<span style="color:red">*</span>”
  19. 标记的条目提交后不可修改。
  20. </p>
  21. </div>
  22. <!--基本信息-->
  23. <ws-info-table>
  24. <!--合同类型-->
  25. <ws-form-item label="合同类型" span="1" class="readonly">
  26. <el-radio v-model="deptBudgetList.agreementType" label="销售合同">销售合同</el-radio>
  27. <el-radio v-model="deptBudgetList.agreementType" label="补充协议">补充协议</el-radio>
  28. </ws-form-item>
  29. <!--合同编号-->
  30. <!-- v-if="deptBudgetList.agreementType == '销售合同'" -->
  31. <ws-form-item label="合同编号" span="1" prop="contractNo" class="readonly" v-if="deptBudgetList.agreementType == '销售合同'">
  32. <ws-input v-model="deptBudgetList.contractNo" placeholder="请输入合同编号" maxlength="50" size="small"
  33. :rules="ruleDeptBudget" />
  34. </ws-form-item>
  35. <!--关联合同-->
  36. <ws-form-item prop="agreementNo" label="关联合同" span="1" v-if="deptBudgetList.agreementType == '补充协议'">
  37. <ws-select v-model="deptBudgetList.agreementNo" placeholder="请选择编号" @change="selectRelation">
  38. <ws-option v-for="item in contractNoList" :key="item.id" :label="item.contractNo"
  39. :value="item.contractNo"></ws-option>
  40. </ws-select>
  41. </ws-form-item>
  42. <!--补充协议编号-->
  43. <ws-form-item label="补充协议编号" span="1" prop="contractNo" class="readonly"
  44. v-if="deptBudgetList.agreementType == '补充协议'">
  45. <ws-input v-model="deptBudgetList.contractNo" placeholder="请输入补充协议编号" maxlength="50" size="small"
  46. :rules="ruleDeptBudget" />
  47. </ws-form-item>
  48. <!--买方-->
  49. <ws-form-item label="买方" span="1" prop="buyer" class="readonly">
  50. <!-- <ws-input v-model="deptBudgetList.buyer" placeholder="请输入买方名称" maxlength="100" size="small" /> -->
  51. <!-- <el-autocomplete class="inline-input" v-model="deptBudgetList.buyer" :fetch-suggestions="querySearch1"
  52. placeholder="请输入买方名称" @select="handleSelect"></el-autocomplete> -->
  53. <ws-select v-model="deptBudgetList.buyer" placeholder="请选择买方名称" class="typeselect"
  54. @change="buyerSelect">
  55. <ws-option v-for="item in customerinfo" :key="item.customerName" :label="item.customerName"
  56. :value="item.customerName" />
  57. </ws-select>
  58. </ws-form-item>
  59. <!--运输方式-->
  60. <ws-form-item label="运输方式" span="1" prop="shippingType">
  61. <ws-input v-model="deptBudgetList.shippingType" placeholder="请输入运输方式" maxlength="20" size="small" />
  62. </ws-form-item>
  63. <!--卖方-->
  64. <ws-form-item label="卖方" span="1" prop="seller" class="readonly">
  65. <!-- <ws-input v-model="deptBudgetList.seller" placeholder="请输入卖方名称" maxlength="100" size="small" /> -->
  66. <el-autocomplete class="inline-input" v-model="deptBudgetList.seller" :fetch-suggestions="querySearch2"
  67. placeholder="请输入卖方名称" @select="handleSelect"></el-autocomplete>
  68. </ws-form-item>
  69. <!--结算方式-->
  70. <ws-form-item label="结算方式" span="1" prop="settlementMethod">
  71. <ws-input v-model="deptBudgetList.settlementMethod" placeholder="请输入结算方式" maxlength="120" size="small" />
  72. </ws-form-item>
  73. <!--买方电话-->
  74. <ws-form-item label="买方电话" span="1" prop="contractNo">
  75. <!-- <ws-input v-model.number="deptBudgetList.buyerPhone" placeholder="请输入买方电话" maxlength="100" size="small" /> -->
  76. <el-autocomplete class="inline-input" v-model="deptBudgetList.buyerPhone" :fetch-suggestions="querySearch3"
  77. placeholder="请输入买方电话" @select="handleSelect"></el-autocomplete>
  78. </ws-form-item>
  79. <ws-form-item label="交货方式" span="1" prop="seller" class="readonly">
  80. <el-radio v-model="deptBudgetList.deliverType" v-if="deptBudgetList.priceType == '随行就市'" disabled label="1">
  81. 我方送货</el-radio>
  82. <el-radio v-model="deptBudgetList.deliverType" v-else label="1">我方送货</el-radio>
  83. <el-radio v-model="deptBudgetList.deliverType" v-if="deptBudgetList.priceType == '随行就市'" disabled label="2">
  84. 对方自提</el-radio>
  85. <el-radio v-model="deptBudgetList.deliverType" v-else label="2">对方自提</el-radio>
  86. </ws-form-item>
  87. <!--卖方电话-->
  88. <ws-form-item label="卖方电话" span="1" prop="sellerPhone">
  89. <!-- <ws-input v-model="deptBudgetList.sellerPhone" placeholder="请输入卖方电话" maxlength="100" size="small" /> -->
  90. <el-autocomplete class="inline-input" v-model="deptBudgetList.sellerPhone" :fetch-suggestions="querySearch4"
  91. placeholder="请输入卖方电话" @select="handleSelect"></el-autocomplete>
  92. </ws-form-item>
  93. <!--包装方式-->
  94. <ws-form-item label="包装方式" span="1" prop="packingMethod">
  95. <ws-select v-model="deptBudgetList.packingMethod" placeholder="" class="typeselect"
  96. @change="selectpackingMethod">
  97. <ws-option v-for="item in packtypeList" :key="item.constKey" :label="item.constValue"
  98. :value="item.constValue" />
  99. </ws-select>
  100. </ws-form-item>
  101. <!--重量(吨)-->
  102. <ws-form-item label="重量(吨)" span="1" prop="weight">
  103. <ws-input @input="weightchange" v-model="deptBudgetList.weight" placeholder="请输入重量(吨)" maxlength="100"
  104. size="small" />
  105. </ws-form-item>
  106. <!--验收方式-->
  107. <ws-form-item label="验收方式" span="1" prop="acceptanceMethod">
  108. <el-select v-model="deptBudgetList.acceptanceMethod" placeholder="请选择验收方式" style="width: 100%" clearable
  109. filterable @change="selectunitList">
  110. <el-option v-for="(item, index) in unitList" :key="item.constValue" :label="item.constValue"
  111. :value="item.constValue">
  112. <span class="unit-left" style="float: left">
  113. <span v-if="item.flag == 'delete'">
  114. {{ item.constValue }}</span>
  115. <!-- 新增文本框 -->
  116. <div style="width: 160px" v-if="item.flag !== 'delete'" @click.stop>
  117. <ws-input v-model="item.constValue" clearable maxlength="10" style="width: 100%"></ws-input>
  118. </div>
  119. </span>
  120. <span style="float: right; color: #8492a6; font-size: 13px">
  121. <!-- 对号 -->
  122. <i class="el-icon-check" style="line-height: 29px; margin-left: 10px" v-if="item.flag !== 'delete'"
  123. @click.stop="saveClick(item, index)"></i>
  124. <!-- 编辑 -->
  125. <i class="el-icon-edit" style="line-height: 29px; margin-left: 10px" v-if="item.flag == 'delete'"
  126. @click.stop="editClick(item, index)"></i>
  127. <!-- 删除 -->
  128. <i class="el-icon-delete" style="line-height: 29px" @click.stop="deleteClick(item, index)"></i>
  129. </span>
  130. </el-option>
  131. <!-- 新增按钮 -->
  132. <el-option value="" label="">
  133. <div style="
  134. text-align: right;
  135. border-top: 1px solid #dcdfe6;
  136. padding: 5px;
  137. ">
  138. <ws-button type="primary" @click.stop="addClick">{{
  139. $t('button.add')
  140. }}</ws-button>
  141. </div>
  142. </el-option>
  143. </el-select>
  144. </ws-form-item>
  145. <!--交货日期(起)-->
  146. <ws-form-item label="交货日期(起)" span="1" prop="deliveryDateStart">
  147. <ws-date-picker v-model="deptBudgetList.deliveryDateStart" type="date" placeholder="请选择交货日期(起)"
  148. value-format="yyyy-MM-dd" />
  149. </ws-form-item>
  150. <!--溢短装(%)-->
  151. <ws-form-item label="溢短装(%)" span="1" prop="overShort">
  152. <ws-input v-model="deptBudgetList.overShort" placeholder="请输入溢短装比例(%)" maxlength="100" size="small" />
  153. </ws-form-item>
  154. <!--交货日期(止)-->
  155. <ws-form-item label="交货日期(止)" span="1" prop="deliveryDateEnd">
  156. <ws-date-picker v-model="deptBudgetList.deliveryDateEnd" type="date" placeholder="请选择交货日期(止)"
  157. value-format="yyyy-MM-dd" />
  158. </ws-form-item>
  159. <!--价格类型-->
  160. <ws-form-item label="价格类型" span="1" prop="priceType">
  161. <ws-select v-model="deptBudgetList.priceType" placeholder="请选择价格类型" @change="selectpriceType">
  162. <ws-option v-for="item in priceTypeList" :key="item" :label="item" :value="item" />
  163. </ws-select>
  164. </ws-form-item>
  165. <!--合同单价(元/吨)-->
  166. <ws-form-item class="readonly" label="合同单价(元/吨)" span="1" prop="unitContractPrice"
  167. v-if="deptBudgetList.priceType == '定价销售'">
  168. <ws-input @input="pricechange" v-model="deptBudgetList.unitContractPrice" placeholder="请输入合同单价"
  169. maxlength="100" size="small" />
  170. </ws-form-item>
  171. <!--合同总价-->
  172. <ws-form-item label="合同总价" span="1" prop="totalContractPrice" v-if="deptBudgetList.priceType == '定价销售'">
  173. <ws-input v-model="deptBudgetList.totalContractPrice" placeholder="请输入合同总价" maxlength="100" size="small" />
  174. </ws-form-item>
  175. <!--签订日期-->
  176. <ws-form-item label="签订日期" span="1" prop="signingDate" v-if="deptBudgetList.agreementType == '补充协议'">
  177. <ws-date-picker v-model="deptBudgetList.signingDate" type="date" placeholder="请选择合同签订日期"
  178. value-format="yyyy-MM-dd" />
  179. </ws-form-item>
  180. <ws-form-item label="货源所在地区" span="1" prop="sourceGoods">
  181. <!-- <el-cascader
  182. :options="options_"
  183. v-model="selectedOptions"
  184. clearable
  185. size="large"
  186. placeholder="请选择货源所在地区"
  187. style="width: 200%"
  188. @change="handleChange"
  189. /> -->
  190. <el-button @click="mapInputClick('source')" class="address-btn">
  191. {{ newSelectedOptions }}
  192. </el-button>
  193. </ws-form-item>
  194. <ws-form-item label="货源详细地址" span="1" prop="sourceGoods">
  195. <ws-input v-model="deptBudgetList.sourceGoods" placeholder="请输入货源详细地址" maxlength="20" size="small" />
  196. </ws-form-item>
  197. <ws-form-item label="交货所在地区" span="1" prop="placeDelivery">
  198. <!-- <el-cascader
  199. :options="options_"
  200. v-model="selectedOptions1"
  201. clearable
  202. size="large"
  203. placeholder="请选择交货所在地区"
  204. style="width: 200%"
  205. @change="handleChange1"
  206. /> -->
  207. <el-button @click="mapInputClick('deliveryProv')" class="address-btn">
  208. {{ newSelectedOptions1 }}
  209. </el-button>
  210. </ws-form-item>
  211. <ws-form-item label="交货详细地址" span="1" prop="placeDelivery">
  212. <ws-input v-model="deptBudgetList.placeDelivery" placeholder="请输入交货详细地址" maxlength="20" size="small" />
  213. </ws-form-item>
  214. <!--签订日期-->
  215. <ws-form-item label="签订日期" span="1" prop="signingDate" v-if="deptBudgetList.agreementType == '销售合同'">
  216. <ws-date-picker v-model="deptBudgetList.signingDate" type="date" placeholder="请选择合同签订日期"
  217. value-format="yyyy-MM-dd" />
  218. </ws-form-item>
  219. <ws-form-item label="最终实际成交量(吨)" span="1" prop="finalTradingVolume">
  220. <ws-input v-model="deptBudgetList.finalTradingVolume" placeholder="请输入最终实际成交量" maxlength="100"
  221. size="small" />
  222. </ws-form-item>
  223. </ws-info-table>
  224. </ws-form>
  225. </div>
  226. <div class="wenzi">
  227. <h3>货物信息</h3>
  228. </div>
  229. <div class="center">
  230. <ws-form ref="deptBudgetList" :rules="ruleDeptBudget" :model="deptBudgetList">
  231. <!--货物信息-->
  232. <ws-info-table>
  233. <!--货名-->
  234. <ws-form-item label="货名" span="1" prop="goodsName" class="readonly">
  235. <ws-select v-model="deptBudgetList.contractGoodsInfo.goodsName" placeholder="" class="typeselect"
  236. @change="selectgoodsName">
  237. <ws-option v-for="item in goodnameList" :key="item.constKey" :label="item.constValue"
  238. :value="item.constValue" />
  239. </ws-select>
  240. </ws-form-item>
  241. <!--水分(%)<=-->
  242. <ws-form-item label="水分(%)<=" span="1" prop="waterContent">
  243. <ws-input v-model="deptBudgetList.contractGoodsInfo.waterContent" placeholder="请输入水分占比" maxlength="100"
  244. size="small" />
  245. </ws-form-item>
  246. <!--品级-->
  247. <ws-form-item label="品级" span="1" prop="grade" class="readonly">
  248. <ws-select v-model="deptBudgetList.contractGoodsInfo.grade" placeholder="" class="typeselect"
  249. @change="selectgrade">
  250. <ws-option v-for="item in gradeList" :key="item.constKey" :label="item.constValue"
  251. :value="item.constValue" />
  252. </ws-select>
  253. </ws-form-item>
  254. <!--杂质(%)<=-->
  255. <ws-form-item label="杂质(%)<=" span="1" prop="impurity">
  256. <ws-input v-model="deptBudgetList.contractGoodsInfo.impurity" placeholder="请输入杂质占比(%)" maxlength="40"
  257. size="small" />
  258. </ws-form-item>
  259. <!--容重(克/升)>=-->
  260. <ws-form-item label="容重(克/升)>=" span="1" prop="bulkDensity">
  261. <ws-input v-model="deptBudgetList.contractGoodsInfo.bulkDensity" placeholder="请输入容重" maxlength="40"
  262. size="small" />
  263. </ws-form-item>
  264. <!--霉变粒(%)<=-->
  265. <ws-form-item label="霉变粒(%)<=" span="1" prop="mildewGrain">
  266. <ws-input v-model="deptBudgetList.contractGoodsInfo.mildewGrain" placeholder="请输入霉变粒占比(%)" maxlength="40"
  267. size="small" />
  268. </ws-form-item>
  269. <!--热损伤(%)<=-->
  270. <ws-form-item label="热损伤(%)<=" span="1" prop="jiaorenli">
  271. <ws-input v-model="deptBudgetList.contractGoodsInfo.jiaorenli" placeholder="请输入输入热损伤占比(%)" maxlength="40"
  272. size="small" />
  273. </ws-form-item>
  274. <!--不完善粒(%)<=-->
  275. <ws-form-item label="不完善粒(%)<=" span="1" prop="imperfectGrain">
  276. <ws-input v-model="deptBudgetList.contractGoodsInfo.imperfectGrain" placeholder="请输入不完善粒占比(%)"
  277. maxlength="40" size="small" />
  278. </ws-form-item>
  279. </ws-info-table>
  280. </ws-form>
  281. </div>
  282. <div class="wenzi">
  283. <h3>流程信息</h3>
  284. </div>
  285. <div class="center">
  286. <ws-form ref="deptBudgetList" :rules="ruleDeptBudget" :model="deptBudgetList">
  287. <!--流程信息-->
  288. <ws-info-table>
  289. <!--合同收入(元)-->
  290. <ws-form-item label="合同收入(元)" span="1" prop="goodsNameKey">
  291. <ws-input v-model="deptBudgetList.contractProcessInfo.goodsNameKey" placeholder="请输入合同收入(元)" maxlength="100"
  292. size="small" />
  293. </ws-form-item>
  294. <!--已开发票(元)-->
  295. <ws-form-item label="已开发票(元)" span="1" prop="goodsName">
  296. <ws-input v-model="deptBudgetList.contractProcessInfo.goodsName" placeholder="请输入已开发票(元)" maxlength="100"
  297. size="small" />
  298. </ws-form-item>
  299. <!--费用支出(元)-->
  300. <ws-form-item label="费用支出(元)" span="1" prop="waterContent">
  301. <ws-input v-model="deptBudgetList.contractProcessInfo.waterContent" placeholder="请输入费用支出(元)" maxlength="100"
  302. size="small" />
  303. </ws-form-item>
  304. <!--未开发票(元)-->
  305. <ws-form-item label="未开发票(元)" span="1" prop="impurity">
  306. <ws-input v-model="deptBudgetList.contractProcessInfo.impurity" placeholder="请输入未开发票(元)" maxlength="100"
  307. size="small" />
  308. </ws-form-item>
  309. <!--未回款(元)-->
  310. <ws-form-item label="未回款(元)" span="1" prop="mildewGrain">
  311. <ws-input v-model="deptBudgetList.contractProcessInfo.mildewGrain" placeholder="请输入未回款(元)" maxlength="100"
  312. size="small" />
  313. </ws-form-item>
  314. <!--双章原件回收情况-->
  315. <ws-form-item label="双章原件回收情况" span="1" prop="grade">
  316. <ws-select v-model="deptBudgetList.contractProcessInfo.grade" placeholder="" class="typeselect"
  317. @change="selectpackingMethod">
  318. <ws-option v-for="item in ChapterTwoList" :key="item.constKey" :label="item.constValue"
  319. :value="item.constValue" />
  320. </ws-select>
  321. </ws-form-item>
  322. </ws-info-table>
  323. </ws-form>
  324. </div>
  325. <div class="wenzi">
  326. <h3>备注信息</h3>
  327. </div>
  328. <div class="ce">
  329. <ws-form ref="deptBudgetList" :rules="ruleDeptBudget" :model="deptBudgetList">
  330. <!--备注信息-->
  331. <ws-input v-model="deptBudgetList.remarks" type="textarea" row="3" placeholder="请输入备注信息,不超过200字"
  332. maxlength="3000" />
  333. <ws-upload ref="upload" :comp-id="compId" :appendix-ids="deptBudgetList.addressUrl" :size-limit="size"
  334. @onChange="onChange" accept=".jpg, .jpeg, .png, .pdf, .doc, .zip, .rar"
  335. v-hasPermission="`contractManagement.salesContract.salesContractInfo.appl`" />
  336. </ws-form>
  337. <div v-if="dialogVisible" class="map">
  338. <map-drag @marker="marker" :isShowaddress="true" v-on:addressListen="getAddress" :type="type">
  339. </map-drag>
  340. </div>
  341. </div>
  342. <div style="text-align: right; padding: 10px" class="center">
  343. <el-button class="bg-bottom" type="primary" size="small" @click="submit(deptBudgetList)">提交</el-button>
  344. </div>
  345. </div>
  346. </template>
  347. <script>
  348. import {
  349. packList,
  350. addList,
  351. xiala,
  352. addxiala,
  353. editxiala,
  354. delxiala,
  355. getRelationContractNo,
  356. getcustomerinfo
  357. } from '@/model/contarct/index'
  358. import WsUpload from '@/components/WsUpload'
  359. import {
  360. regionData,
  361. CodeToText,
  362. TextToCode
  363. } from 'element-china-area-data'
  364. import thirdPartyInspectionReportAddVue from '../system/shipInspection/thirdPartyInspectionReportAdd.vue'
  365. import mapDrag from '@/components/mapdrag/mapdrag'
  366. export default {
  367. name: 'viewSpareMoney',
  368. components: {
  369. WsUpload,
  370. mapDrag,
  371. },
  372. watch: {
  373. vesselId(val) {
  374. this.getVesselData()
  375. },
  376. isShow(val) {
  377. this.showType = val
  378. },
  379. },
  380. data() {
  381. return {
  382. restaurants1: [],
  383. restaurants2: [],
  384. restaurants3: [],
  385. restaurants4: [],
  386. customerinfo:[],
  387. //弹出框
  388. dialogViewSpareMoney: false,
  389. dialogApproveFormVisible: false,
  390. // 船舶类型
  391. monetaryKey: null,
  392. // 表格显示数据
  393. tableDate: [],
  394. // 是否显示
  395. showType: true,
  396. // 年
  397. year: '',
  398. type: '',
  399. dialogVisible: false,
  400. options_: regionData,
  401. selectedOptions: [],
  402. newSelectedOptions: '请选择货源所在地',
  403. selectedOptions1: [],
  404. newSelectedOptions1: '请选择交货所在地区',
  405. // 提交类型
  406. submitType: true,
  407. tableData: [{
  408. date: 1111,
  409. name: 'qqqq',
  410. address: 'errrtt',
  411. }, ],
  412. trainingMethods: {},
  413. packtypeList: [],
  414. compId: localStorage.getItem('ws-pf_compId'),
  415. mainReportAdd: {},
  416. appendixIdsAdd: '',
  417. size: 10,
  418. unitList: [],
  419. goodnameList: [],
  420. gradeList: [],
  421. ChapterTwoList: [],
  422. deptBudgetList: {
  423. deliverType: '1',
  424. agreementType: '销售合同',
  425. finalTradingVolume: 0,
  426. totalContractPrice: 0,
  427. contractGoodsInfo: {
  428. goodsName: '',
  429. },
  430. buyerPhone:'',
  431. contractProcessInfo: {},
  432. addressUrl: '',
  433. sourceGoods: '',
  434. placeDelivery: '',
  435. },
  436. pickerBeginDateBefore: {
  437. disabledDate: (time) => {
  438. return time.getTime() > Date.now()
  439. },
  440. },
  441. ruleDeptBudget: {
  442. contractNo: [{
  443. required: true,
  444. message: '请输入活动名称',
  445. trigger: 'blur',
  446. },
  447. {
  448. min: 6,
  449. max: 50,
  450. message: '长度在 6 到 50 个字符',
  451. trigger: 'blur',
  452. },
  453. ],
  454. },
  455. selectIntendedShip: {},
  456. interviewTypeList: {},
  457. fileList: [],
  458. priceTypeList: ['定价销售', '随行就市'],
  459. contractNoList: [],
  460. }
  461. },
  462. activated() {
  463. //cg.viewBudget
  464. //cg.viewSpareMoney
  465. // this.getVesselData();
  466. this.newSelectedOptions = '请选择货源所在地'
  467. this.newSelectedOptions1 = '请选择交货所在地'
  468. this.deptBudgetList.packingMethod = '散装'
  469. this.deptBudgetList.packingMethodKey = 1
  470. this.deptBudgetList.contractGoodsInfo.goodsName = '玉米'
  471. this.deptBudgetList.contractGoodsInfo.goodsNameKey = 1
  472. this.deptBudgetList.contractProcessInfo.grade = '未回收'
  473. this.deptBudgetList.contractProcessInfo.gradeKey = 1
  474. this.deptBudgetList.contractGoodsInfo.grade = '一等品'
  475. this.deptBudgetList.contractGoodsInfo.gradeKey = 1
  476. this.loaddata()
  477. this.showType = this.isShow
  478. },
  479. mounted() {
  480. this.restaurants1 = JSON.parse(localStorage.getItem('deptBudgetList_data1'));
  481. this.restaurants2 = JSON.parse(localStorage.getItem('deptBudgetList_data2'));
  482. this.restaurants3 = JSON.parse(localStorage.getItem('deptBudgetList_data3'));
  483. this.restaurants4 = JSON.parse(localStorage.getItem('deptBudgetList_data4'));
  484. if (!this.restaurants1) this.restaurants1 = [];
  485. if (!this.restaurants2) this.restaurants2 = [];
  486. if (!this.restaurants3) this.restaurants3 = [];
  487. if (!this.restaurants4) this.restaurants4 = [];
  488. },
  489. methods: {
  490. buyerSelect(item) {
  491. console.log(item)
  492. for (let i = 0; i < this.customerinfo.length; i++) {
  493. console.log(this.customerinfo[i].customerName,item)
  494. if(this.customerinfo[i].customerName==item){
  495. this.deptBudgetList.buyerPhone=this.customerinfo[i].customerPhone
  496. }
  497. }
  498. },
  499. querySearch1(queryString, cb) {
  500. var restaurants1 = this.restaurants1;
  501. var results = queryString ? restaurants1.filter(this.createFilter(queryString)) : restaurants1;
  502. // 调用 callback 返回建议列表的数据
  503. cb(results);
  504. },
  505. querySearch2(queryString, cb) {
  506. var restaurants2 = this.restaurants2;
  507. var results = queryString ? restaurants2.filter(this.createFilter(queryString)) : restaurants2;
  508. // 调用 callback 返回建议列表的数据
  509. cb(results);
  510. },
  511. querySearch3(queryString, cb) {
  512. var restaurants3 = this.restaurants3;
  513. var results = queryString ? restaurants3.filter(this.createFilter(queryString)) : restaurants3;
  514. // 调用 callback 返回建议列表的数据
  515. cb(results);
  516. },
  517. querySearch4(queryString, cb) {
  518. var restaurants4 = this.restaurants4;
  519. var results = queryString ? restaurants4.filter(this.createFilter(queryString)) : restaurants4;
  520. // 调用 callback 返回建议列表的数据
  521. cb(results);
  522. },
  523. createFilter(queryString) {
  524. return (restaurant) => {
  525. return (restaurant.value.toLowerCase().indexOf(queryString.toLowerCase()) === 0);
  526. };
  527. },
  528. handleSelect(item) {
  529. console.log(item);
  530. },
  531. marker: function(item) {
  532. this.deptBudgetList.warehousePositioning =
  533. item.lnglat.lat + ',' + item.lnglat.lng
  534. },
  535. getAddress(data) {
  536. console.log('getAddress', data)
  537. if (data[4] == 'source') {
  538. this.newSelectedOptions = data[0] + '/' + data[1] + '/' + data[2]
  539. this.deptBudgetList.sourceProvince = data[0]
  540. this.deptBudgetList.sourceCity = data[1]
  541. this.deptBudgetList.sourceArea = data[2]
  542. this.deptBudgetList.sourceGoods = data[3]
  543. this.deptBudgetList.sourceLocation=data[5].lat+','+data[5].lng
  544. } else {
  545. this.newSelectedOptions1 = data[0] + '/' + data[1] + '/' + data[2]
  546. this.deptBudgetList.deliveryProvince = data[0]
  547. this.deptBudgetList.deliveryCity = data[1]
  548. this.deptBudgetList.deliveryArea = data[2]
  549. this.deptBudgetList.placeDelivery = data[3]
  550. this.deptBudgetList.deliveryLocation=data[5].lat+','+data[5].lng
  551. }
  552. },
  553. mapInputClick(type) {
  554. this.dialogVisible = true
  555. this.type = type
  556. },
  557. blurMap() {
  558. this.dialogVisible = false
  559. },
  560. focusMap() {
  561. this.dialogVisible = true
  562. },
  563. // 关闭 dialog时 处理文件url 初始化upload组件
  564. handleClose() {
  565. this.dialogViewSpareMoney = false
  566. },
  567. handleChange(value) {
  568. this.selectedOptions = value
  569. },
  570. handleChange1(value) {
  571. this.selectedOptions1 = value
  572. },
  573. returnsales() {
  574. this.deptBudgetList = {
  575. deliverType: '1',
  576. agreementType: '采购合同',
  577. finalTradingVolume: 0,
  578. totalContractPrice: 0,
  579. contractGoodsInfo: {
  580. goodsName: '',
  581. },
  582. contractProcessInfo: {},
  583. addressUrl: '',
  584. }
  585. this.$router.push({
  586. path: 'salesContract',
  587. })
  588. },
  589. loaddata() {
  590. // 包装方式
  591. packList({
  592. constId: 'CON1',
  593. })
  594. .toPromise()
  595. .then((response) => {
  596. this.packtypeList = response
  597. })
  598. // 验收方式
  599. this.getUnitList()
  600. // 货名
  601. packList({
  602. constId: 'CON2',
  603. })
  604. .toPromise()
  605. .then((response) => {
  606. this.goodnameList = response
  607. })
  608. // 品级
  609. packList({
  610. constId: 'CON3',
  611. })
  612. .toPromise()
  613. .then((response) => {
  614. this.gradeList = response
  615. })
  616. // 双章
  617. packList({
  618. constId: 'CON4',
  619. })
  620. .toPromise()
  621. .then((response) => {
  622. this.ChapterTwoList = response
  623. })
  624. //关联合同
  625. getRelationContractNo({
  626. agreementType: '销售合同',
  627. goodsType: 1,
  628. })
  629. .toPromise()
  630. .then((response) => {
  631. this.contractNoList = response
  632. })
  633. getcustomerinfo({compId: localStorage.getItem('ws-pf_compId'),}).toPromise()
  634. .then((response) => {
  635. var arr=[]
  636. for (let i = 0; i < response.length; i++) {
  637. if(response[i].customerType=='个人客户'){
  638. arr.push({customerName:response[i].customerName,customerPhone:response[i].customerPhone})
  639. }else{
  640. arr.push({customerName:response[i].compName,customerPhone:response[i].customerPhone})
  641. }
  642. }
  643. this.customerinfo = arr
  644. })
  645. },
  646. selectRelation(e) {
  647. for (var i = 0; i < this.contractNoList.length; i++) {
  648. if (this.contractNoList[i].contractNo == e) {
  649. this.deptBudgetList = this.contractNoList[i]
  650. this.deptBudgetList.agreementNo = this.contractNoList[i].contractNo
  651. this.deptBudgetList.contractNo = this.contractNoList[i].contractNo
  652. this.deptBudgetList.agreementType = '补充协议'
  653. this.newSelectedOptions = this.contractNoList[i].sourceProvince + this.contractNoList[i].sourceCity + this
  654. .contractNoList[i].sourceArea
  655. this.deptBudgetList.sourceGoods = this.contractNoList[i].sourceGoods
  656. this.newSelectedOptions1 = this.contractNoList[i].deliveryProvince + this.contractNoList[i].deliveryCity +
  657. this.contractNoList[i].deliveryArea
  658. this.deptBudgetList.placeDelivery = this.contractNoList[i].placeDelivery
  659. }
  660. }
  661. },
  662. onChange() {
  663. this.$refs.upload
  664. .handleSaveBill()
  665. .then(async (response) => {
  666. this.deptBudgetList.addressUrl = response
  667. })
  668. .catch((res) => {
  669. EventBus.$emit('error', (JSON.parse(res) || {}).message)
  670. this.$refs.upload.clearFiles()
  671. })
  672. },
  673. getUnitList() {
  674. xiala({
  675. compId: localStorage.getItem('ws-pf_compId'),
  676. constCode: 'TYPEYAN',
  677. })
  678. .toPromise()
  679. .then((response) => {
  680. this.unitList = response
  681. let currItem
  682. this.unitList.forEach((item, index, arr) => {
  683. item.flag = 'delete'
  684. if (this.vModel == item.constKey) {
  685. currItem = item
  686. }
  687. })
  688. //
  689. if (currItem) {
  690. this.selectContract(currItem.constValue)
  691. }
  692. })
  693. },
  694. submit() {
  695. if (!this.deptBudgetList.contractNo) {
  696. this.$message({
  697. message: '合同编号不能为空',
  698. type: 'warning',
  699. })
  700. return
  701. }
  702. if (
  703. this.deptBudgetList.contractNo.length < 6 ||
  704. this.deptBudgetList.contractNo.length > 50
  705. ) {
  706. this.$message({
  707. message: '合同编号长度不符合要求,请输入6到50个字符之内!',
  708. type: 'warning',
  709. })
  710. return
  711. }
  712. if (!this.deptBudgetList.shippingType) {
  713. this.$message({
  714. message: '运输方式不能为空',
  715. type: 'warning',
  716. })
  717. return
  718. }
  719. if (
  720. this.deptBudgetList.shippingType.length < 1 ||
  721. this.deptBudgetList.shippingType.length > 20
  722. ) {
  723. this.$message({
  724. message: '运输方式长度不符合要求,请输入1到20个字符之内!',
  725. type: 'warning',
  726. })
  727. return
  728. }
  729. if (!this.deptBudgetList.buyer) {
  730. this.$message({
  731. message: '买方名称不能为空',
  732. type: 'warning',
  733. })
  734. return
  735. }
  736. if (this.deptBudgetList.buyer.length > 30) {
  737. this.$message({
  738. message: '买方名称长度不符合要求,请输入30个字符之内!',
  739. type: 'warning',
  740. })
  741. return
  742. }
  743. if (!this.deptBudgetList.settlementMethod) {
  744. this.$message({
  745. message: '结算方式不能为空',
  746. type: 'warning',
  747. })
  748. return
  749. }
  750. if (
  751. this.deptBudgetList.settlementMethod.length < 1 ||
  752. this.deptBudgetList.settlementMethod.length > 20
  753. ) {
  754. this.$message({
  755. message: '结算方式长度不符合要求,请输入1到20个字符之内!',
  756. type: 'warning',
  757. })
  758. return
  759. }
  760. if (!this.deptBudgetList.seller) {
  761. this.$message({
  762. message: '请输入卖方名称!',
  763. type: 'warning',
  764. })
  765. return
  766. }
  767. if (this.deptBudgetList.seller.length > 30) {
  768. this.$message({
  769. message: '卖方名称长度不符合要求,请输入30个字符之内!',
  770. type: 'warning',
  771. })
  772. return
  773. }
  774. if (!this.deptBudgetList.buyerPhone) {
  775. this.$message({
  776. message: '请输入买方电话!',
  777. type: 'warning',
  778. })
  779. return
  780. }
  781. if (isNaN(this.deptBudgetList.buyerPhone)) {
  782. this.$message({
  783. message: '输入买方电话有误!',
  784. type: 'warning',
  785. })
  786. return
  787. }
  788. if (
  789. this.deptBudgetList.buyerPhone.length < 7 ||
  790. this.deptBudgetList.buyerPhone.length > 20
  791. ) {
  792. this.$message({
  793. message: '买方电话长度不符合要求,请输入7到20个字符之内!',
  794. type: 'warning',
  795. })
  796. return
  797. }
  798. if (!this.deptBudgetList.sellerPhone) {
  799. this.$message({
  800. message: '请输入卖方电话!',
  801. type: 'warning',
  802. })
  803. return
  804. }
  805. if (isNaN(this.deptBudgetList.sellerPhone)) {
  806. this.$message({
  807. message: '输入卖方电话有误!',
  808. type: 'warning',
  809. })
  810. return
  811. }
  812. if (
  813. this.deptBudgetList.sellerPhone.length < 7 ||
  814. this.deptBudgetList.sellerPhone.length > 20
  815. ) {
  816. this.$message({
  817. message: '卖方电话长度不符合要求,请输入7到20个字符之内!',
  818. type: 'warning',
  819. })
  820. return
  821. }
  822. if (!this.deptBudgetList.acceptanceMethod) {
  823. this.$message({
  824. message: '请选择验收方式',
  825. type: 'warning',
  826. })
  827. return
  828. }
  829. if (!this.deptBudgetList.weight) {
  830. this.$message({
  831. message: '请输入重量!',
  832. type: 'warning',
  833. })
  834. return
  835. }
  836. if (
  837. isNaN(this.deptBudgetList.weight) ||
  838. (String(this.deptBudgetList.weight).indexOf('.') != -1 &&
  839. String(this.deptBudgetList.weight).length -
  840. (String(this.deptBudgetList.weight).indexOf('.') + 1) >
  841. 3) ||
  842. this.deptBudgetList.weight < 0 ||
  843. this.deptBudgetList.weight > 200000
  844. ) {
  845. this.$message({
  846. message: '输入重量有误!',
  847. type: 'warning',
  848. })
  849. return
  850. }
  851. if (!this.deptBudgetList.deliveryDateStart) {
  852. this.$message({
  853. message: '请选择交货日期(起)',
  854. type: 'warning',
  855. })
  856. return
  857. }
  858. if (!this.deptBudgetList.overShort) {
  859. this.$message({
  860. message: '请输入溢短装!',
  861. type: 'warning',
  862. })
  863. return
  864. }
  865. if (
  866. isNaN(this.deptBudgetList.overShort) ||
  867. (String(this.deptBudgetList.overShort).indexOf('.') != -1 &&
  868. String(this.deptBudgetList.overShort).length -
  869. (String(this.deptBudgetList.overShort).indexOf('.') + 1) >
  870. 2) ||
  871. this.deptBudgetList.overShort < 0 ||
  872. this.deptBudgetList.overShort > 50
  873. ) {
  874. this.$message({
  875. message: '溢短装输入有误!',
  876. type: 'warning',
  877. })
  878. return
  879. }
  880. if (!this.deptBudgetList.deliveryDateEnd) {
  881. this.$message({
  882. message: '请选择交货日期(止)',
  883. type: 'warning',
  884. })
  885. return
  886. }
  887. //时间
  888. if (
  889. new Date(this.deptBudgetList.deliveryDateStart).getTime() >
  890. new Date(this.deptBudgetList.deliveryDateEnd).getTime()
  891. ) {
  892. this.$message({
  893. message: '交货日期(止)选择错误',
  894. type: 'warning',
  895. })
  896. return
  897. }
  898. if (!this.deptBudgetList.priceType) {
  899. this.$message({
  900. message: '请选择价格类型',
  901. type: 'warning',
  902. })
  903. return
  904. }
  905. if (this.deptBudgetList.priceType == '定价销售') {
  906. if (!this.deptBudgetList.unitContractPrice) {
  907. this.$message({
  908. message: '请输入合同单价!',
  909. type: 'warning',
  910. })
  911. return
  912. }
  913. if (
  914. isNaN(this.deptBudgetList.unitContractPrice) ||
  915. (String(this.deptBudgetList.unitContractPrice).indexOf('.') != -1 &&
  916. String(this.deptBudgetList.unitContractPrice).length -
  917. (String(this.deptBudgetList.unitContractPrice).indexOf('.') + 1) >
  918. 2) ||
  919. this.deptBudgetList.unitContractPrice <= 0 ||
  920. this.deptBudgetList.unitContractPrice > 10000
  921. ) {
  922. this.$message({
  923. message: '合同单价输入有误!',
  924. type: 'warning',
  925. })
  926. return
  927. }
  928. if (!this.deptBudgetList.totalContractPrice) {
  929. this.$message({
  930. message: '请输入合同总价!',
  931. type: 'warning',
  932. })
  933. return
  934. }
  935. if (
  936. isNaN(this.deptBudgetList.totalContractPrice) ||
  937. (String(this.deptBudgetList.totalContractPrice).indexOf('.') != -1 &&
  938. String(this.deptBudgetList.totalContractPrice).length -
  939. (String(this.deptBudgetList.totalContractPrice).indexOf('.') +
  940. 1) >
  941. 2) ||
  942. this.deptBudgetList.totalContractPrice <= 0 ||
  943. this.deptBudgetList.totalContractPrice > 1000000000
  944. ) {
  945. this.$message({
  946. message: '合同总价输入有误!',
  947. type: 'warning',
  948. })
  949. return
  950. }
  951. }
  952. if (!this.newSelectedOptions) {
  953. this.$message({
  954. message: '请选择货源所在地区!',
  955. type: 'warning',
  956. })
  957. return
  958. }
  959. if (!this.deptBudgetList.sourceGoods) {
  960. this.$message({
  961. message: '请输入货源详细地址!',
  962. type: 'warning',
  963. })
  964. return
  965. }
  966. if (!this.newSelectedOptions1) {
  967. this.$message({
  968. message: '请选择交货所在地区!',
  969. type: 'warning',
  970. })
  971. return
  972. }
  973. if (!this.deptBudgetList.placeDelivery) {
  974. this.$message({
  975. message: '请输入交货详细地址!',
  976. type: 'warning',
  977. })
  978. return
  979. }
  980. if (!this.deptBudgetList.signingDate) {
  981. this.$message({
  982. message: '请选择签订日期',
  983. type: 'warning',
  984. })
  985. return
  986. }
  987. if (
  988. isNaN(this.deptBudgetList.finalTradingVolume) ||
  989. (String(this.deptBudgetList.finalTradingVolume).indexOf('.') != -1 &&
  990. String(this.deptBudgetList.finalTradingVolume).length -
  991. (String(this.deptBudgetList.finalTradingVolume).indexOf('.') + 1) >
  992. 3) ||
  993. this.deptBudgetList.finalTradingVolume < 0 ||
  994. this.deptBudgetList.finalTradingVolume > 200000
  995. ) {
  996. this.$message({
  997. message: '最终实际成交量有误!',
  998. type: 'warning',
  999. })
  1000. return
  1001. }
  1002. //货物信息
  1003. if (!this.deptBudgetList.contractGoodsInfo.goodsName) {
  1004. this.$message({
  1005. message: '请选择货名',
  1006. type: 'warning',
  1007. })
  1008. return
  1009. }
  1010. if (!this.deptBudgetList.contractGoodsInfo.waterContent) {
  1011. this.$message({
  1012. message: '请输入水分',
  1013. type: 'warning',
  1014. })
  1015. return
  1016. }
  1017. if (
  1018. (this.deptBudgetList.contractGoodsInfo.waterContent &&
  1019. String(this.deptBudgetList.contractGoodsInfo.waterContent).indexOf(
  1020. '.'
  1021. ) != -1 &&
  1022. String(this.deptBudgetList.contractGoodsInfo.waterContent).length -
  1023. (String(this.deptBudgetList.contractGoodsInfo.waterContent).indexOf(
  1024. '.'
  1025. ) +
  1026. 1) >
  1027. 2) ||
  1028. this.deptBudgetList.contractGoodsInfo.waterContent > 40 ||
  1029. this.deptBudgetList.contractGoodsInfo.waterContent < 0
  1030. ) {
  1031. this.$message({
  1032. message: '水分输入错误',
  1033. type: 'warning',
  1034. })
  1035. return
  1036. }
  1037. if (!this.deptBudgetList.contractGoodsInfo.grade) {
  1038. this.$message({
  1039. message: '请选择品级',
  1040. type: 'warning',
  1041. })
  1042. return
  1043. }
  1044. if (!this.deptBudgetList.contractGoodsInfo.impurity) {
  1045. this.$message({
  1046. message: '请输入杂质',
  1047. type: 'warning',
  1048. })
  1049. return
  1050. }
  1051. if (
  1052. (this.deptBudgetList.contractGoodsInfo.impurity &&
  1053. String(this.deptBudgetList.contractGoodsInfo.impurity).indexOf('.') !=
  1054. -1 &&
  1055. String(this.deptBudgetList.contractGoodsInfo.impurity).length -
  1056. (String(this.deptBudgetList.contractGoodsInfo.impurity).indexOf(
  1057. '.'
  1058. ) +
  1059. 1) >
  1060. 2) ||
  1061. this.deptBudgetList.contractGoodsInfo.impurity > 40 ||
  1062. this.deptBudgetList.contractGoodsInfo.impurity < 0
  1063. ) {
  1064. this.$message({
  1065. message: '杂质输入错误',
  1066. type: 'warning',
  1067. })
  1068. return
  1069. }
  1070. if (!this.deptBudgetList.contractGoodsInfo.bulkDensity) {
  1071. this.$message({
  1072. message: '请输入容重',
  1073. type: 'warning',
  1074. })
  1075. return
  1076. }
  1077. if (
  1078. (this.deptBudgetList.contractGoodsInfo.bulkDensity &&
  1079. String(this.deptBudgetList.contractGoodsInfo.bulkDensity).indexOf(
  1080. '.'
  1081. ) != -1 &&
  1082. String(this.deptBudgetList.contractGoodsInfo.bulkDensity).length -
  1083. (String(this.deptBudgetList.contractGoodsInfo.bulkDensity).indexOf(
  1084. '.'
  1085. ) +
  1086. 1) >
  1087. 2) ||
  1088. this.deptBudgetList.contractGoodsInfo.bulkDensity > 1000 ||
  1089. this.deptBudgetList.contractGoodsInfo.bulkDensity < 0
  1090. ) {
  1091. this.$message({
  1092. message: '容重输入错误',
  1093. type: 'warning',
  1094. })
  1095. return
  1096. }
  1097. if (!this.deptBudgetList.contractGoodsInfo.mildewGrain) {
  1098. this.$message({
  1099. message: '请输入霉变粒',
  1100. type: 'warning',
  1101. })
  1102. return
  1103. }
  1104. if (
  1105. !this.deptBudgetList.contractGoodsInfo.mildewGrain ||
  1106. (String(this.deptBudgetList.contractGoodsInfo.mildewGrain).indexOf(
  1107. '.'
  1108. ) != -1 &&
  1109. String(this.deptBudgetList.contractGoodsInfo.mildewGrain).length -
  1110. (String(this.deptBudgetList.contractGoodsInfo.mildewGrain).indexOf(
  1111. '.'
  1112. ) +
  1113. 1) >
  1114. 2) ||
  1115. this.deptBudgetList.contractGoodsInfo.mildewGrain > 40 ||
  1116. this.deptBudgetList.contractGoodsInfo.mildewGrain < 0
  1117. ) {
  1118. this.$message({
  1119. message: '霉变粒输入错误',
  1120. type: 'warning',
  1121. })
  1122. return
  1123. }
  1124. if (!this.deptBudgetList.contractGoodsInfo.jiaorenli) {
  1125. this.$message({
  1126. message: '请输入热损伤',
  1127. type: 'warning',
  1128. })
  1129. return
  1130. }
  1131. if (
  1132. !this.deptBudgetList.contractGoodsInfo.jiaorenli ||
  1133. (String(this.deptBudgetList.contractGoodsInfo.jiaorenli).indexOf('.') !=
  1134. -1 &&
  1135. String(this.deptBudgetList.contractGoodsInfo.jiaorenli).length -
  1136. (String(this.deptBudgetList.contractGoodsInfo.jiaorenli).indexOf(
  1137. '.'
  1138. ) +
  1139. 1) >
  1140. 2) ||
  1141. this.deptBudgetList.contractGoodsInfo.jiaorenli > 40 ||
  1142. this.deptBudgetList.contractGoodsInfo.jiaorenli < 0
  1143. ) {
  1144. this.$message({
  1145. message: '热损伤输入错误',
  1146. type: 'warning',
  1147. })
  1148. return
  1149. }
  1150. if (!this.deptBudgetList.contractGoodsInfo.imperfectGrain) {
  1151. this.$message({
  1152. message: '请输入不完善粒',
  1153. type: 'warning',
  1154. })
  1155. return
  1156. }
  1157. if (
  1158. !this.deptBudgetList.contractGoodsInfo.imperfectGrain ||
  1159. (String(this.deptBudgetList.contractGoodsInfo.imperfectGrain).indexOf(
  1160. '.'
  1161. ) != -1 &&
  1162. String(this.deptBudgetList.contractGoodsInfo.imperfectGrain).length -
  1163. (String(
  1164. this.deptBudgetList.contractGoodsInfo.imperfectGrain
  1165. ).indexOf('.') +
  1166. 1) >
  1167. 2) ||
  1168. this.deptBudgetList.contractGoodsInfo.imperfectGrain > 40 ||
  1169. this.deptBudgetList.contractGoodsInfo.imperfectGrain < 0
  1170. ) {
  1171. this.$message({
  1172. message: '不完善粒输入错误',
  1173. type: 'warning',
  1174. })
  1175. return
  1176. }
  1177. if(this.deptBudgetList.contractProcessInfo.goodsNameKey ){
  1178. if (
  1179. !this.deptBudgetList.contractProcessInfo.goodsNameKey > 1000000000 ||
  1180. this.deptBudgetList.contractProcessInfo.goodsNameKey < 100 ||
  1181. (String(this.deptBudgetList.contractProcessInfo.goodsNameKey).indexOf(
  1182. '.'
  1183. ) != -1 &&
  1184. String(this.deptBudgetList.contractProcessInfo.goodsNameKey).length -
  1185. (String(
  1186. this.deptBudgetList.contractProcessInfo.goodsNameKey
  1187. ).indexOf('.') +
  1188. 1) >
  1189. 2)
  1190. ) {
  1191. this.$message({
  1192. message: '合同收入金额输入错误',
  1193. type: 'warning',
  1194. })
  1195. return
  1196. }
  1197. }
  1198. if (
  1199. this.deptBudgetList.contractProcessInfo.waterContent > 10000000 ||
  1200. this.deptBudgetList.contractProcessInfo.waterContent < 0 ||
  1201. (String(this.deptBudgetList.contractProcessInfo.waterContent).indexOf(
  1202. '.'
  1203. ) != -1 &&
  1204. String(this.deptBudgetList.contractProcessInfo.waterContent).length -
  1205. (String(
  1206. this.deptBudgetList.contractProcessInfo.waterContent
  1207. ).indexOf('.') +
  1208. 1) >
  1209. 2)
  1210. ) {
  1211. this.$message({
  1212. message: '费用支出输入错误',
  1213. type: 'warning',
  1214. })
  1215. return
  1216. }
  1217. if (
  1218. (this.deptBudgetList.contractProcessInfo.goodsName > 1000000000) |
  1219. (this.deptBudgetList.contractProcessInfo.goodsName < 0) ||
  1220. (String(this.deptBudgetList.contractProcessInfo.goodsName).indexOf(
  1221. '.'
  1222. ) != -1 &&
  1223. String(this.deptBudgetList.contractProcessInfo.goodsName).length -
  1224. (String(this.deptBudgetList.contractProcessInfo.goodsName).indexOf(
  1225. '.'
  1226. ) +
  1227. 1) >
  1228. 2)
  1229. ) {
  1230. this.$message({
  1231. message: '已开发票金额输入错误',
  1232. type: 'warning',
  1233. })
  1234. return
  1235. }
  1236. if (
  1237. (this.deptBudgetList.contractProcessInfo.impurity > 1000000000) |
  1238. (this.deptBudgetList.contractProcessInfo.impurity < 0) ||
  1239. (String(this.deptBudgetList.contractProcessInfo.impurity).indexOf(
  1240. '.'
  1241. ) != -1 &&
  1242. String(this.deptBudgetList.contractProcessInfo.impurity).length -
  1243. (String(this.deptBudgetList.contractProcessInfo.impurity).indexOf(
  1244. '.'
  1245. ) +
  1246. 1) >
  1247. 2)
  1248. ) {
  1249. this.$message({
  1250. message: '未开发票金额输入错误',
  1251. type: 'warning',
  1252. })
  1253. return
  1254. }
  1255. if (
  1256. (!this.deptBudgetList.contractProcessInfo.mildewGrain > 1000000000) |
  1257. (this.deptBudgetList.contractProcessInfo.mildewGrain < 0) ||
  1258. (String(this.deptBudgetList.contractProcessInfo.mildewGrain).indexOf(
  1259. '.'
  1260. ) != -1 &&
  1261. String(this.deptBudgetList.contractProcessInfo.mildewGrain).length -
  1262. (String(
  1263. this.deptBudgetList.contractProcessInfo.mildewGrain
  1264. ).indexOf('.') +
  1265. 1) >
  1266. 2)
  1267. ) {
  1268. this.$message({
  1269. message: '未回款金额输入错误',
  1270. type: 'warning',
  1271. })
  1272. return
  1273. }
  1274. this.$refs.deptBudgetList.validate((valid) => {
  1275. if (valid) {
  1276. this.deptBudgetList.compId = this.compId
  1277. this.deptBudgetList.contractType = 1
  1278. this.deptBudgetList.goodsType = 1
  1279. addList(this.deptBudgetList)
  1280. .toPromise()
  1281. .then((response) => {
  1282. // 存储买方、卖方、买方电话、卖方电话
  1283. let _data = {
  1284. byer: this.deptBudgetList.buyer,
  1285. seller: this.deptBudgetList.seller,
  1286. buyerPhone: this.deptBudgetList.buyerPhone,
  1287. sellerPhone: this.deptBudgetList.sellerPhone
  1288. }
  1289. if (this.restaurants1.length <= 20) {
  1290. this.restaurants1 = this.restaurants1.filter(function(val) {
  1291. if (val.value != _data.byer) {
  1292. return val
  1293. }
  1294. })
  1295. this.restaurants1.unshift({
  1296. value: _data.byer
  1297. })
  1298. } else {
  1299. this.restaurants1.unshift({
  1300. value: _data.byer
  1301. }).pop({
  1302. value: _data.byer
  1303. })
  1304. }
  1305. localStorage.setItem('deptBudgetList_data1', JSON.stringify(this.restaurants1));
  1306. if (this.restaurants2.length <= 20) {
  1307. this.restaurants2 = this.restaurants2.filter(function(val) {
  1308. if (val.value != _data.seller) {
  1309. return val
  1310. }
  1311. })
  1312. this.restaurants2.unshift({
  1313. value: _data.seller
  1314. })
  1315. } else {
  1316. this.restaurants2.unshift({
  1317. value: _data.seller
  1318. }).pop({
  1319. value: _data.seller
  1320. })
  1321. }
  1322. localStorage.setItem('deptBudgetList_data2', JSON.stringify(this.restaurants2));
  1323. if (this.restaurants2.length <= 20) {
  1324. this.restaurants3 = this.restaurants3.filter(function(val) {
  1325. if (val.value != _data.buyerPhone) {
  1326. return val
  1327. }
  1328. })
  1329. this.restaurants3.unshift({
  1330. value: _data.buyerPhone
  1331. })
  1332. } else {
  1333. this.restaurants3.unshift({
  1334. value: _data.buyerPhone
  1335. }).pop({
  1336. value: _data.buyerPhone
  1337. })
  1338. }
  1339. localStorage.setItem('deptBudgetList_data3', JSON.stringify(this.restaurants3));
  1340. if (this.restaurants4.length <= 20) {
  1341. this.restaurants4 = this.restaurants3.filter(function(val) {
  1342. if (val.value != _data.sellerPhone) {
  1343. return val
  1344. }
  1345. })
  1346. this.restaurants4.unshift({
  1347. value: _data.sellerPhone
  1348. })
  1349. } else {
  1350. this.restaurants4.unshift({
  1351. value: _data.sellerPhone
  1352. }).pop({
  1353. value: _data.sellerPhone
  1354. })
  1355. }
  1356. localStorage.setItem('deptBudgetList_data4', JSON.stringify(this.restaurants4));
  1357. this.$message.success('添加成功')
  1358. this.deptBudgetList = {
  1359. deliverType: '1',
  1360. agreementType: '销售合同',
  1361. finalTradingVolume: 0,
  1362. totalContractPrice: 0,
  1363. contractGoodsInfo: {
  1364. goodsName: '',
  1365. },
  1366. contractProcessInfo: {},
  1367. }
  1368. this.$router.push({
  1369. path: 'salesContract',
  1370. })
  1371. })
  1372. } else {
  1373. EventBus.$emit('error', this.$t('showMessage.asteriskRequired'))
  1374. return false
  1375. }
  1376. })
  1377. },
  1378. resetForm(deptBudgetList) {
  1379. this.$refs[deptBudgetList].resetFields()
  1380. },
  1381. saveClick(item, index) {
  1382. console.log(item)
  1383. if (Object.is(item.id, 1)) {
  1384. return
  1385. }
  1386. if (Object.is(this.unitList[index].flag, 'delete')) {
  1387. this.$set(this.unitList, index, {
  1388. flag: 'check',
  1389. })
  1390. } else {
  1391. this.$set(this.unitList, index, {
  1392. flag: 'delete',
  1393. })
  1394. }
  1395. if (!item.constValue) {
  1396. this.unitList.splice(index, 1)
  1397. return
  1398. }
  1399. if (item.flag == 'add') {
  1400. item.constKey = Math.random() * 20
  1401. this.trainingMethods.compId = localStorage.getItem('ws-pf_compId')
  1402. this.trainingMethods.constKey = item.constKey
  1403. this.trainingMethods.constCode = 'TYPEYAN'
  1404. this.trainingMethods.constValue = item.constValue
  1405. this.trainingMethods.id = item.id
  1406. addxiala(this.trainingMethods)
  1407. .toPromise()
  1408. .then((response) => {
  1409. this.getUnitList()
  1410. })
  1411. } else if (item.flag == 'check') {
  1412. this.trainingMethods.compId = localStorage.getItem('ws-pf_compId')
  1413. this.trainingMethods.constKey = item.constKey
  1414. this.trainingMethods.constCode = 'TYPEYAN'
  1415. this.trainingMethods.constValue = item.constValue
  1416. this.trainingMethods.id = item.id
  1417. editxiala(this.trainingMethods)
  1418. .toPromise()
  1419. .then((response) => {
  1420. this.getUnitList()
  1421. })
  1422. }
  1423. },
  1424. handleExamine() {},
  1425. approve() {},
  1426. addClick() {
  1427. this.unitList.push({
  1428. flag: 'add',
  1429. constValue: '',
  1430. constKey: '',
  1431. })
  1432. },
  1433. selectChapterTwo(e) {
  1434. for (var i = 0; i < this.ChapterTwoList.length; i++) {
  1435. if (this.ChapterTwoList[i].constValue == e) {
  1436. this.deptBudgetList.gradeKey = this.ChapterTwoList[i].constKey
  1437. }
  1438. }
  1439. },
  1440. selectunitList(e) {
  1441. for (var i = 0; i < this.unitList.length; i++) {
  1442. if (this.unitList[i].constValue == e) {
  1443. this.deptBudgetList.packingMethodKey = this.unitList[i].constKey
  1444. }
  1445. }
  1446. },
  1447. selectgrade(e) {
  1448. for (var i = 0; i < this.gradeList.length; i++) {
  1449. if (this.gradeList[i].constValue == e) {
  1450. this.deptBudgetList.gradeKey = this.gradeList[i].constKey
  1451. this.deptBudgetList.contractGoodsInfo.gradeKey =
  1452. this.gradeList[i].constKey
  1453. }
  1454. }
  1455. },
  1456. selectgoodsName(e) {
  1457. for (var i = 0; i < this.goodnameList.length; i++) {
  1458. if (this.goodnameList[i].constValue == e) {
  1459. this.deptBudgetList.goodsNameKey = this.goodnameList[i].constKey
  1460. this.deptBudgetList.contractGoodsInfo.goodsNameKey =
  1461. this.goodnameList[i].constKey
  1462. }
  1463. }
  1464. },
  1465. selectpackingMethod(e) {
  1466. for (var i = 0; i < this.packtypeList.length; i++) {
  1467. if (this.packtypeList[i].constValue == e) {
  1468. this.deptBudgetList.acceptanceMethodKey =
  1469. this.packtypeList[i].constKey
  1470. }
  1471. }
  1472. },
  1473. selectpriceType(e) {
  1474. if (e == '随行就市') {
  1475. this.deptBudgetList.deliverType = '1'
  1476. }
  1477. },
  1478. weightchange(e) {
  1479. this.deptBudgetList.finalTradingVolume = e
  1480. },
  1481. pricechange(e) {
  1482. this.deptBudgetList.totalContractPrice = e * this.deptBudgetList.weight
  1483. },
  1484. // 编辑
  1485. editClick(item, index) {
  1486. const map = JSON.parse(JSON.stringify(item))
  1487. if (Object.is(item.id, 1)) {
  1488. return
  1489. }
  1490. if (Object.is(this.unitList[index].flag, 'delete')) {
  1491. map.flag = 'check'
  1492. this.$set(this.unitList, index, map)
  1493. } else {
  1494. map.flag = 'delete'
  1495. this.$set(this.unitList, index, map)
  1496. }
  1497. },
  1498. // 删除
  1499. deleteClick(item, index) {
  1500. if (Object.is(item.constKey, 1)) {
  1501. return
  1502. }
  1503. if (!item.constValue) {
  1504. this.unitList.splice(index, 1)
  1505. return
  1506. }
  1507. delxiala({
  1508. id: this.unitList[index].id,
  1509. })
  1510. .toPromise()
  1511. .then((response) => {
  1512. this.getUnitList()
  1513. this.pleaseChoose = ''
  1514. })
  1515. },
  1516. },
  1517. }
  1518. </script>
  1519. <style lang="scss" scoped>
  1520. /deep/.ws-info-table .el-form-item .el-form-item__content {
  1521. padding: 0 25px;
  1522. }
  1523. /deep/.ws-info-table .el-form-item {
  1524. border-right: 1px solid #cdd2dc;
  1525. border-bottom: 1px solid #cdd2dc;
  1526. }
  1527. .title {
  1528. position: relative;
  1529. }
  1530. .title::before {
  1531. content: '';
  1532. display: inline-block;
  1533. width: 5px;
  1534. height: 30px;
  1535. background: #5473e8;
  1536. position: absolute;
  1537. left: 0;
  1538. }
  1539. .el-button--primary {
  1540. background-color: #5878e8;
  1541. border-color: #5878e8;
  1542. }
  1543. .upload-demo {
  1544. margin-top: 10px;
  1545. }
  1546. .el-col {
  1547. background: #f6f7fc;
  1548. }
  1549. .readonly {
  1550. position: relative;
  1551. }
  1552. .readonly:after {
  1553. content: '*';
  1554. color: #ff2727;
  1555. position: absolute;
  1556. right: 8px;
  1557. z-index: 10;
  1558. top: 21%;
  1559. font-size: 20px;
  1560. }
  1561. /deep/.ws-info-table .el-form-item .el-form-item__content {
  1562. padding: 0 25px;
  1563. border-left: 1px solid #cdd2dc;
  1564. background: #fafbfc;
  1565. }
  1566. /deep/.ws-info-table .el-form-item .el-form-item__label {
  1567. width: 140px;
  1568. text-align: center;
  1569. background: #f0f2f6;
  1570. // border: 1px solid #cdd2dc;
  1571. }
  1572. .button-container {
  1573. display: flex;
  1574. flex-wrap: nowrap;
  1575. justify-content: space-between;
  1576. align-items: center;
  1577. background-color: #fff;
  1578. width: 100%;
  1579. height: 50px;
  1580. padding: 0 10px;
  1581. &>div {
  1582. margin-left: 10px;
  1583. display: flex;
  1584. flex-wrap: nowrap;
  1585. flex-direction: row;
  1586. &>span {
  1587. line-height: 50px;
  1588. }
  1589. }
  1590. /deep/.auditFlow-box {
  1591. position: unset;
  1592. margin-left: 10px;
  1593. &/deep/.auditFlow-icon {
  1594. width: auto;
  1595. padding-right: 30px;
  1596. }
  1597. &/deep/.auditFlow-main {
  1598. position: absolute;
  1599. }
  1600. }
  1601. }
  1602. .box-app {
  1603. display: inline-block;
  1604. float: left;
  1605. margin-left: 30px;
  1606. line-height: 50px;
  1607. }
  1608. /deep/.el-dialog {
  1609. .el-form-item {
  1610. margin-bottom: 0 !important;
  1611. .el-input--medium {
  1612. textarea {
  1613. min-height: 100px !important;
  1614. }
  1615. }
  1616. }
  1617. }
  1618. .collapse-bottom {
  1619. margin-bottom: 20px;
  1620. }
  1621. .input-main .textarea .el-textarea__inner {
  1622. width: 100%;
  1623. z-index: 1;
  1624. }
  1625. .bg-left {
  1626. padding-left: 30px;
  1627. }
  1628. .bg-right {
  1629. padding-right: 10px;
  1630. text-align: right;
  1631. }
  1632. .bg-bottom {
  1633. margin: 16px 0px;
  1634. }
  1635. .wenzi {
  1636. width: 70%;
  1637. margin: 0 auto;
  1638. }
  1639. .wenzi h3 {
  1640. display: inline-block;
  1641. left: 10px;
  1642. }
  1643. .wenzi p {
  1644. display: inline-block;
  1645. }
  1646. .center {
  1647. width: 70%;
  1648. margin: 0 auto;
  1649. }
  1650. .el-form-item {
  1651. width: 50%;
  1652. }
  1653. .el-form-item__label {
  1654. text-align: center;
  1655. }
  1656. .ce {
  1657. width: 70%;
  1658. margin: 0 auto;
  1659. }
  1660. /*.crt-main .textarea /deep/ .el-form-item__label {*/
  1661. /* height: 82px;*/
  1662. /*}*/
  1663. // 控制select为只读的时候显示样式
  1664. .hide-sel {
  1665. .el-input__inner {
  1666. border: 0px;
  1667. }
  1668. .el-icon-arrow-up {
  1669. display: none;
  1670. }
  1671. .el-textarea__inner {
  1672. background-color: #fff !important;
  1673. border: 0;
  1674. }
  1675. .el-date-editor {
  1676. i {
  1677. display: none;
  1678. }
  1679. }
  1680. .is-disabled {
  1681. .el-input__inner:hover {
  1682. background-color: #fff !important;
  1683. border: 0;
  1684. }
  1685. color: #606266;
  1686. .el-input__inner {
  1687. background-color: #fff !important;
  1688. border: 0;
  1689. color: #606266;
  1690. }
  1691. .el-textarea__inner {
  1692. background-color: #fff !important;
  1693. border: 0;
  1694. color: #606266;
  1695. }
  1696. }
  1697. }
  1698. /deep/.ws-info-table .el-form-item .el-form-item__label {
  1699. width: 130px;
  1700. }
  1701. //*号
  1702. .unchangeable {
  1703. position: absolute;
  1704. width: 9px;
  1705. height: 22px;
  1706. font-size: 16px;
  1707. font-family: PingFangSC-Medium, PingFang SC;
  1708. font-weight: 500;
  1709. color: #ff2727;
  1710. line-height: 22px;
  1711. display: inline-block;
  1712. right: 14px;
  1713. }
  1714. /deep/.el-input,
  1715. /deep/.el-date-editor {
  1716. font-size: 13px;
  1717. }
  1718. /deep/.el-textarea {
  1719. width: 101%;
  1720. margin: 0px;
  1721. }
  1722. /deep/el-date-editor--date {
  1723. width: 200px;
  1724. }
  1725. .unchanged {
  1726. position: absolute;
  1727. left: 37px;
  1728. width: 102px;
  1729. height: 14px;
  1730. font-size: 14px;
  1731. font-family: PingFangSC-Regular, PingFang SC;
  1732. font-weight: 400;
  1733. color: #afb5cb;
  1734. line-height: 14px;
  1735. }
  1736. /deep/.el-input--small .el-input__inner {
  1737. height: 32px;
  1738. line-height: 32px;
  1739. }
  1740. // 控制select为只读的时候显示样式
  1741. /deep/.ws-class-table-col {
  1742. height: auto;
  1743. padding: 0px 2px;
  1744. /deep/.el-input__inner {
  1745. padding: 0px 2px;
  1746. }
  1747. }
  1748. /deep/.is-disabled {
  1749. .el-input__prefix,
  1750. .el-input__suffix {
  1751. display: none;
  1752. }
  1753. .el-input__inner {
  1754. background-color: #fff;
  1755. border-color: #fff !important;
  1756. color: #000 !important;
  1757. font-size: 14px;
  1758. cursor: text;
  1759. padding: 0 !important;
  1760. }
  1761. }
  1762. .winseaview-view {
  1763. padding: 0 0 20px;
  1764. }
  1765. .container {
  1766. overflow: scroll;
  1767. height: 93vh;
  1768. }
  1769. .addressUrls {
  1770. width: 100%;
  1771. display: flex;
  1772. margin-top: 10px;
  1773. }
  1774. .addressUrls-item {
  1775. position: relative;
  1776. display: flex;
  1777. }
  1778. .icon-guanbi {
  1779. position: absolute;
  1780. right: 8px;
  1781. }
  1782. .addressUrl {
  1783. margin: 0px 10px;
  1784. border-radius: 3px;
  1785. }
  1786. //上传文件成功标识
  1787. /deep/.el-upload-list__item-status-label {
  1788. position: absolute;
  1789. right: 22px;
  1790. top: -1px;
  1791. line-height: inherit;
  1792. display: none;
  1793. }
  1794. .map {
  1795. position: fixed;
  1796. top: 0;
  1797. bottom: 0;
  1798. left: 0;
  1799. right: 0;
  1800. margin: auto;
  1801. width: 850px;
  1802. height: 400px;
  1803. background: gainsboro;
  1804. border-radius: 20px;
  1805. padding: 10px;
  1806. box-sizing: border-box;
  1807. z-index: 99;
  1808. }
  1809. .amap-container {
  1810. width: 100% !important;
  1811. }
  1812. .address-btn {
  1813. width: 100%;
  1814. text-align: left;
  1815. }
  1816. .inline-input {
  1817. width: 100%;
  1818. }
  1819. </style>