purchaseContractAdd.vue 63 KB

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