autonym.vue 50 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599
  1. <template>
  2. <div>
  3. <div style="display: inline-block;">
  4. <div style="position: relative;display: inline-block;margin: 5px;">
  5. <span>状态:</span>
  6. <el-select v-model="statusT" style="width:150px;margin-left: 10px;" @change="select()">
  7. <el-option v-for="item in statesnum" :key="item.value" :label="item.label" :value="item.value">
  8. </el-option>
  9. </el-select>&nbsp;&nbsp;
  10. </div>
  11. <div style="position: relative;display: inline-block;margin: 5px;">
  12. <span>用户昵称:</span>
  13. <el-input style="width: 200px;" @keydown.enter.native="select" placeholder="请输入姓名" v-model="userName">
  14. </el-input>&nbsp;&nbsp;
  15. </div>
  16. <div style="position: relative;display: inline-block;margin: 5px;">
  17. <span>企业名称:</span>
  18. <el-input style="width: 200px;" @keydown.enter.native="select" placeholder="请输入企业名称"
  19. v-model="companyNameT">
  20. </el-input>&nbsp;&nbsp;
  21. </div>
  22. <div style="position: relative;display: inline-block;margin: 5px;">
  23. <span>企业电话:</span>
  24. <el-input style="width: 200px;" @keydown.enter.native="select" placeholder="请输入企业电话"
  25. v-model="companyPhoneT">
  26. </el-input>&nbsp;&nbsp;
  27. </div>
  28. <div style="margin:5px;display: inline-block;">
  29. <span>开始时间:</span>
  30. <el-date-picker style="width: 160px;margin-left: 10px;" v-model="startTime" align="right"
  31. type="date" format="yyyy-MM-dd" value-format="yyyy-MM-dd" placeholder="选择开始时间">
  32. </el-date-picker>&nbsp;&nbsp;&nbsp;
  33. </div>
  34. <div style="margin:5px;display: inline-block;">
  35. <span>截止时间:</span>
  36. <el-date-picker style="width: 160px;margin-left: 10px;" v-model="endTime" align="right" type="date"
  37. format="yyyy-MM-dd" value-format="yyyy-MM-dd" placeholder="选择截止时间">
  38. </el-date-picker>
  39. </div>
  40. <el-button style='margin: 5px;' size="mini" type="primary" icon="document" @click="select">查询
  41. </el-button>
  42. <el-button style='margin: 5px;' size="mini" type="primary" icon="document" @click="cleans">重置
  43. </el-button>
  44. <!-- v-if="isAuth('autonym:pass')" -->
  45. <el-button style='margin:0 0 20px 20px;' size="mini" type="primary" icon="document" @click="addClick()">添加
  46. </el-button>
  47. <el-button style='margin-left:15px;' size="mini" type="warning" icon="document" :disabled="!isAuth('user:daochu')" @click="exportBtn">导出Excel
  48. </el-button>
  49. </div>
  50. <div style="color: orange;"> * 导出数据提示:导出数据前请进行时间或者状态等筛选,否则导出单量过多易出现卡顿或系统崩溃</div>
  51. <el-table v-loading="tableDataLoading" :data="tableData.records">
  52. <!-- @selection-change="changeFun" <el-table-column type="selection" fixed>
  53. </el-table-column> -->
  54. <el-table-column prop="companyId" label="编号" width="80" fixed="left">
  55. </el-table-column>
  56. <!-- <el-table-column prop="classify" label="类型" width="80">
  57. <template slot-scope="scope">
  58. <span v-if="scope.row.classify==null || scope.row.classify==1 ">企业</span>
  59. <span v-else>个人</span>
  60. </template>
  61. </el-table-column> -->
  62. <el-table-column prop="userName" label="姓名" width="100" fixed="left">
  63. <template slot-scope="scope">
  64. <span style="color: #4f9dec;cursor: pointer;"
  65. @click="updates(scope.row)">{{scope.row.userName ? scope.row.userName : '未绑定'}}</span>
  66. </template>
  67. </el-table-column>
  68. <el-table-column prop="phone" label="电话" width="150">
  69. <template slot-scope="scope">
  70. <span style="color: #4f9dec;cursor: pointer;" @click="updates(scope.row)" v-if="isAuth('userList:phone')">
  71. {{ scope.row.phone ? scope.row.phone : '未绑定' }}
  72. </span>
  73. <span style="color: #4f9dec;cursor: pointer;" @click="updates(scope.row)" v-else>
  74. {{ scope.row.phone1 ? scope.row.phone1 : '-' }}
  75. </span>
  76. </template>
  77. </el-table-column>
  78. <el-table-column prop="companyLegalPerson" label="企业法人" width="100">
  79. <template slot-scope="scope">
  80. <span style="color: #4f9dec;cursor: pointer;"
  81. @click="updates(scope.row)">{{scope.row.companyLegalPerson ? scope.row.companyLegalPerson : '未绑定'}}</span>
  82. </template>
  83. </el-table-column>
  84. <!-- <el-table-column prop="phone" label="类型" width="80">
  85. <template slot-scope="scope">
  86. <span v-if="scope.row.classify==1">个人</span>
  87. <span v-else-if="scope.row.classify==2">企业</span>
  88. <span v-else>无</span>
  89. </template>
  90. </el-table-column> -->
  91. <el-table-column prop="companyAllName" label="企业名称" width="200">
  92. </el-table-column>
  93. <el-table-column prop="companyLogo" label="企业头像" width="150">
  94. <template slot-scope="scope">
  95. <div v-if="scope.row.companyLogo == null || scope.row.companyLogo == ''">
  96. 暂无图片
  97. </div>
  98. <div v-if="scope.row.companyLogo" style="display:flex;flex-wrap: wrap;">
  99. <el-popover placement="top-start" title="" trigger="hover">
  100. <img style="width: 50px; height: 50px" :src="scope.row.companyLogo" alt="" slot="reference">
  101. <img style="width: 200px; height: 200px" :src="scope.row.companyLogo" alt="">
  102. </el-popover>
  103. </div>
  104. </template>
  105. </el-table-column>
  106. <el-table-column prop="companyCertification" label="营业执照" width="150">
  107. <template slot-scope="scope">
  108. <div style="display:flex;flex-wrap: wrap;" v-if="scope.row.companyCertification">
  109. <div v-for="(item,index) in scope.row.companyCertification.split(',')" :key="index">
  110. <el-popover placement="top-start" title="" trigger="hover">
  111. <img style="width: 50px; height: 50px" :src="item" alt="" slot="reference">
  112. <img style="width: 400px; height: auto" :src="item" alt="">
  113. </el-popover>
  114. </div>
  115. </div>
  116. </template>
  117. </el-table-column>
  118. <!-- <el-table-column prop="companyCertificate" label="企业证书" width="150">
  119. <template slot-scope="scope">
  120. <div style="display:flex;flex-wrap: wrap;" v-if="scope.row.companyCertificate">
  121. <div v-for="(item,index) in scope.row.companyCertificate.split(',')" :key="index">
  122. <el-popover placement="top-start" title="" trigger="hover">
  123. <img style="width: 50px; height: 50px" :src="item" alt="" slot="reference">
  124. <img style="width: 200px; height: 200px" :src="item" alt="">
  125. </el-popover>
  126. </div>
  127. </div>
  128. </template>
  129. </el-table-column> -->
  130. <!-- <el-table-column prop="companyDutyParagraph" label="企业税号" width="160">
  131. </el-table-column> -->
  132. <el-table-column prop="companyPeople" label="企业规模">
  133. </el-table-column>
  134. <el-table-column prop="companyCreateTime" label="注册时间">
  135. </el-table-column>
  136. <el-table-column prop="companyScope" label="经营范围" width="200">
  137. </el-table-column>
  138. <el-table-column prop="companyAddress" label="企业地址" width="160">
  139. </el-table-column>
  140. <el-table-column prop="companyRegisteredFund" label="注册资金(单位:万)" width="160">
  141. </el-table-column>
  142. <el-table-column prop="email" label="企业邮箱" width="160">
  143. </el-table-column>
  144. <!-- <el-table-column prop="companyContent" label="招聘信息" width="200">
  145. <template slot-scope="scope">
  146. <div style="display: -webkit-box;-webkit-box-orient: vertical;-webkit-line-clamp: 3;overflow: hidden;max-height:80px;" >
  147. <el-popover placement="top-start" title="" trigger="hover">
  148. <div slot="reference">{{scope.row.companyContent}}</div>
  149. <div style="width: 400px;">{{scope.row.companyContent}}</div>
  150. </el-popover>
  151. </div>
  152. </template>
  153. </el-table-column> -->
  154. <el-table-column prop="companyContent" label="公司简介" width="200">
  155. <template slot-scope="scope">
  156. <div style="display: -webkit-box;-webkit-box-orient: vertical;-webkit-line-clamp: 3;overflow: hidden;max-height:80px;" >
  157. <el-popover placement="top-start" title="" trigger="hover">
  158. <div slot="reference">{{scope.row.companyContent}}</div>
  159. <div style="width: 400px;">{{scope.row.companyContent}}</div>
  160. </el-popover>
  161. </div>
  162. </template>
  163. </el-table-column>
  164. <el-table-column prop="auditContent" label="审核内容" width="160">
  165. </el-table-column>
  166. <el-table-column prop="createTime" label="创建时间" width="160">
  167. </el-table-column>
  168. <el-table-column fixed='right' prop="status" label="状态" width="160">
  169. <template slot-scope="scope">
  170. <span v-if="scope.row.status == 1">待审核</span>
  171. <span v-if="scope.row.status == 2">已通过</span>
  172. <span v-if="scope.row.status == 3">已拒绝</span>
  173. </template>
  174. </el-table-column>
  175. <el-table-column fixed='right' label="操作" width="180">
  176. <template slot-scope="scope">
  177. <el-button size="mini" type="primary" :disabled="scope.row.status !== 1 || !isAuth('autonym:jujue')"
  178. @click="refuseClick(scope.row)" style="margin: 5px;">
  179. 拒绝
  180. </el-button>
  181. <el-button size="mini" type="primary"
  182. :disabled="scope.row.status !== 1 || !isAuth('autonym:tongguo')" @click="passClicks(scope.row)"
  183. style="margin: 5px;">
  184. 通过
  185. </el-button>
  186. <el-button size="mini" type="primary" @click="addClick(scope.row)" style="margin: 5px;">
  187. 修改
  188. </el-button>
  189. <el-button size="mini" type="danger" @click="deleteClick(scope.row)" style="margin: 5px;">
  190. 删除
  191. </el-button>
  192. <el-button size="mini" type="primary" @click="fapiaoClick(scope.row)" style="margin: 5px;">
  193. 发票记录
  194. </el-button>
  195. </template>
  196. </el-table-column>
  197. </el-table>
  198. <div style="text-align: center;margin-top: 10px;">
  199. <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange"
  200. :page-sizes="[10, 20, 30, 40]" :page-size="limit" :current-page="page"
  201. layout="total,sizes, prev, pager, next,jumper" :total="tableData.total">
  202. </el-pagination>
  203. </div>
  204. <!-- 审核拒绝弹框 -->
  205. <el-dialog title="审核拒绝" :visible.sync="dialogFormVisible" center>
  206. <div style="margin-bottom: 10px;">
  207. <span
  208. style="width: 200px;display: inline-block;text-align: right;position: relative;top: -70px;">拒绝理由:</span>
  209. <el-input style="width:50%;" v-model="content" type="textarea" :rows="4" placeholder="请输入拒绝理由">
  210. </el-input>
  211. </div>
  212. <div slot="footer" class="dialog-footer">
  213. <el-button @click="dialogFormVisible = false">取 消</el-button>
  214. <el-button type="primary" @click="refuseto()">确 定</el-button>
  215. </div>
  216. </el-dialog>
  217. <!-- 添加/修改企业 -->
  218. <el-dialog :title="titles" :visible.sync="dialogFormVisibleQ" center width="80%">
  219. <div style="margin-bottom: 10px;">
  220. <span style="width: 200px;display: inline-block;text-align: right;">企业用户:</span>
  221. <el-input v-model="nickName1" @focus="userselect" style="width:45%;" placeholder="请选择企业用户">
  222. </el-input>
  223. </div>
  224. <div style="margin-bottom: 10px;">
  225. <span style="width: 200px;display: inline-block;text-align: right;">法人姓名:</span>
  226. <el-input v-model="companyLegalPerson" style="width:45%;" placeholder="请输入法人姓名">
  227. </el-input>
  228. </div>
  229. <div style="margin-bottom: 10px;">
  230. <span style="width: 200px;display: inline-block;text-align: right;">企业名称:</span>
  231. <el-input v-model="companyAllName" style="width:45%;" placeholder="请输入企业名称">
  232. </el-input>
  233. </div>
  234. <div style="margin-bottom: 10px;">
  235. <span style="width: 200px;display: inline-block;text-align: right;">企业规模:</span>
  236. <el-input v-model="companyPeople" style="width:45%;" placeholder="请输入企业规模">
  237. </el-input>
  238. </div>
  239. <div style="margin-bottom: 10px;">
  240. <span style="width: 200px;display: inline-block;text-align: right;">注册时间:</span>
  241. <el-date-picker v-model="companyCreateTime" type="date" format="yyyy-MM-dd" value-format="yyyy-MM-dd" placeholder="选择日期" style="width:45%;">
  242. </el-date-picker>
  243. </div>
  244. <!-- <div style="margin-bottom: 10px;">
  245. <span style="width: 200px;display: inline-block;text-align: right;">企业电话:</span>
  246. <el-input v-model="companyPhone" style="width:45%;" placeholder="请输入企业电话">
  247. </el-input>
  248. </div> -->
  249. <div style="margin-bottom: 10px;display:flex;">
  250. <span style="width: 200px;display: inline-block;text-align: right;">企业头像:</span>
  251. <div
  252. style=" width:148px;height:148px;border: 1px dashed #c0ccda;border-radius: 6px;text-align: center;line-height: 148px;">
  253. <el-upload class="avatar-uploader" v-model="companyLogo"
  254. :action="$http.adornUrl('alioss/upload')" :show-file-list="false"
  255. :on-success="handleAvatarSuccess5" :on-progress="onprogress">
  256. <img v-if="companyLogo!=''&&percentage==100" :src="companyLogo" class="avatar"
  257. style="border-radius: 6px;width: 148px;height: 148px;" />
  258. <i v-else class="el-icon-plus avatar-uploader-icon iconss"></i>
  259. <el-progress v-if="percentage>0&&percentage<100" type="circle" :percentage="percentage">
  260. </el-progress>
  261. </el-upload>
  262. </div>
  263. </div>
  264. <div style="margin-bottom: 10px;display:flex;align-items: center;">
  265. <span style="width: 200px;display: inline-block;text-align: right;">营业执照:</span>
  266. <div style="display: flex;flex-wrap: wrap;">
  267. <div class="imgs" v-for="(item,index) in companyCertification" :key="index" style="margin-right: 20px;">
  268. <img width="100%" class="images" height="100%" :src="item" alt="" @click="lookBtn(item)"style="margin-right: 10px;" >
  269. <span class="dels">
  270. <i class="el-icon-delete" @click="clear(index)"></i>
  271. </span>
  272. </div>
  273. <div class="imgs">
  274. <el-upload :action="$http.adornUrl('alioss/upload')"
  275. list-type="picture-card" :show-file-list="false" :on-success="handleUploadSuccess"
  276. :on-progress="onprogress1">
  277. <el-progress v-if="percentage1>0 && percentage1<100" type="circle" :percentage="percentage1">
  278. </el-progress>
  279. <i v-else class="el-icon-plus"></i>
  280. </el-upload>
  281. </div>
  282. </div>
  283. </div>
  284. <!-- <div style="margin-bottom: 10px;display:flex;">
  285. <span style="width: 200px;display: inline-block;text-align: right;">企业证书:</span>
  286. <div class="imgs" v-for="(item,index) in companyCertificate" :key="index">
  287. <img width="100%" class="images" height="100%" :src="item" alt="">
  288. <span class="dels">
  289. <i class="el-icon-delete" @click="clearQ(index)"></i>
  290. </span>
  291. </div>
  292. <div class="imgs" style="width: 50%;">
  293. <el-upload :action="$http.adornUrl('alioss/upload')"
  294. list-type="picture-card" :show-file-list="false" :on-success="handleUploadSuccessQ"
  295. :on-progress="onprogressQ">
  296. <el-progress v-if="percentageQ>0 && percentageQ<100" type="circle" :percentage="percentageQ">
  297. </el-progress>
  298. <i v-else class="el-icon-plus"></i>
  299. </el-upload>
  300. </div>
  301. </div> -->
  302. <!-- <div style="margin-bottom: 10px;">
  303. <span style="width: 200px;display: inline-block;text-align: right;">企业税号:</span>
  304. <el-input v-model="companyDutyParagraph" style="width:45%;" min="0" placeholder="请输入企业税号"></el-input>
  305. </div> -->
  306. <div style="margin-bottom: 10px;">
  307. <span style="width: 200px;display: inline-block;text-align: right;">企业地址:</span>
  308. <el-input v-model="companyAddress" style="width:45%;" min="0" placeholder="请输入企业地址"></el-input>
  309. </div>
  310. <div style="margin-bottom: 10px;">
  311. <span style="width: 200px;display: inline-block;text-align: right;">经营范围:</span>
  312. <el-button style='margin-left:15px;' plain size="mini" type="primary" icon="document" @click="qungkong">
  313. 清空选项
  314. </el-button>
  315. <!-- <el-input v-model="companyScope" style="width:45%;" min="0" placeholder="请输入经营范围">
  316. </el-input> -->
  317. <div style="margin-left: 200px;">
  318. <span v-for="(item,index) in hangyeData" :key="index">{{item.industryName}}:
  319. <el-checkbox-group v-model="companyScope">
  320. <el-checkbox v-for="(item1,index1) in item.childrenList" :label="item1.industryName"
  321. :key="index1">
  322. {{item1.industryName}}
  323. </el-checkbox>
  324. </el-checkbox-group>
  325. </span>
  326. </div>
  327. </div>
  328. <div style="margin-bottom: 10px;">
  329. <span style="width: 200px;display: inline-block;text-align: right;">注册资金(单位:万):</span>
  330. <el-input v-model="companyRegisteredFund" style="width:45%;" placeholder="请输入注册资金(单位:万)">
  331. <!-- onkeyup="value=value.replace(/^\D*(\d*(?:\.\d{0,2})?).*$/g, '$1')" -->
  332. </el-input>
  333. </div>
  334. <div style="margin-bottom: 10px;">
  335. <span style="width: 200px;display: inline-block;text-align: right;">企业邮箱:</span>
  336. <el-input v-model="email" style="width:45%;" placeholder="请输入企业邮箱">
  337. <!-- onkeyup="value=value.replace(/^\D*(\d*(?:\.\d{0,2})?).*$/g, '$1')" -->
  338. </el-input>
  339. </div>
  340. <!-- <div style="margin-bottom: 10px;">
  341. <span style="width: 200px;display: inline-block;text-align: right;">企业招聘信息:</span>
  342. <el-input v-model="companyContent" style="width:45%;" type="textarea" :rows="3" placeholder="请输入企业招聘信息">
  343. </el-input>
  344. </div> -->
  345. <div style="margin-bottom: 10px;">
  346. <span style="width: 200px;display: inline-block;text-align: right;">企业介绍:</span>
  347. <el-input v-model="companyContent" style="width:45%;" type="textarea" :rows="3" placeholder="请输入企业介绍">
  348. </el-input>
  349. </div>
  350. <div slot="footer" class="dialog-footer" style="margin-top: 30px;text-align: center;">
  351. <el-button @click="prev">取 消</el-button>
  352. <el-button type="primary" @click="addmissionNoticeTo()">确 定</el-button>
  353. </div>
  354. </el-dialog>
  355. <!-- 用户列表 -->
  356. <el-dialog title="用户列表" :visible.sync="dialogFormVisible3" center>
  357. <div style="margin:2% 0;display: inline-block;">
  358. <el-input style="width: 150px;" @keydown.enter.native="userclick" clearable placeholder="请输入手机号"
  359. v-model="phone1"></el-input>&nbsp;&nbsp;&nbsp;&nbsp;
  360. <el-input style="width: 150px;" @keydown.enter.native="userclick" clearable placeholder="请输入昵称"
  361. v-model="nickName2"></el-input>
  362. <el-button style='margin-left:15px;' size="mini" type="primary" icon="document" @click="userclick">
  363. 查询
  364. </el-button>
  365. <el-button style='margin-left:15px;' size="mini" type="primary" icon="document" @click="userclose">
  366. 重置
  367. </el-button>
  368. </div>
  369. <el-table width="780px" v-loading="tableDataLoading4" :data="userIds.records">
  370. <el-table-column fixed prop="nickName" width="220" label="昵称">
  371. <template slot-scope="scope">
  372. <span style="color: #f56c6c;">{{scope.row.userName ? scope.row.userName : '未设置'}}</span>
  373. </template>
  374. </el-table-column>
  375. <el-table-column prop="phone" width="220" label="手机号">
  376. <template slot-scope="scope">
  377. <span>{{scope.row.phone ? scope.row.phone : '未绑定'}}</span>
  378. </template>
  379. </el-table-column>
  380. <el-table-column prop="createTime" width="220" label="创建时间">
  381. </el-table-column>
  382. <el-table-column label="操作" fixed='right' width="120">
  383. <template slot-scope="scope">
  384. <el-button size="mini" type="primary" @click="confirm(scope.row)">确定
  385. </el-button>
  386. </template>
  387. </el-table-column>
  388. </el-table>
  389. <div style="text-align: center;margin-top: 10px;">
  390. <el-pagination @size-change="handleSizeChange2" @current-change="handleCurrentChange2"
  391. :page-sizes="[5, 10, 15, 20]" :page-size="size1" :current-page="page1"
  392. layout="total,sizes, prev, pager, next,jumper" :total="userIds.total">
  393. </el-pagination>
  394. </div>
  395. </el-dialog>
  396. <!-- 发票记录 -->
  397. <el-dialog title="发票记录" :visible.sync="dialogFormVisible4" center width="80%">
  398. <el-button style='margin:0 0 20px 20px;' size="mini" type="primary" icon="document" @click="addfpClick()">添加
  399. </el-button>
  400. <el-table width="780px" v-loading="tableDataLoading4" :data="userIds.list">
  401. <el-table-column prop="invoiceId" label="编号" width="80">
  402. </el-table-column>
  403. <el-table-column prop="title" label="开票信息" width="300">
  404. <template slot-scope="scope">
  405. <el-popover placement="top-start" title="" trigger="hover">
  406. <div style="display: -webkit-box;-webkit-box-orient: vertical;-webkit-line-clamp: 3;overflow: hidden;max-height:80px;" v-html="scope.row.title" slot="reference"></div>
  407. <div style="width: 500px;" v-html="scope.row.title"></div>
  408. </el-popover>
  409. </template>
  410. </el-table-column>
  411. <el-table-column prop="invoiceType" label="发票类型">
  412. <template slot-scope="scope">
  413. <span v-if="scope.row.invoiceType==1">专票</span>
  414. <span v-if="scope.row.invoiceType==2">普票</span>
  415. </template>
  416. </el-table-column>
  417. <el-table-column prop="content" label="发票内容">
  418. </el-table-column>
  419. <el-table-column prop="money" label="发票金额">
  420. </el-table-column>
  421. <el-table-column prop="status" label="发票状态">
  422. <template slot-scope="scope">
  423. <span v-if="scope.row.status==1">待开票</span>
  424. <span v-if="scope.row.status==2">已开票</span>
  425. </template>
  426. </el-table-column>
  427. <el-table-column prop="createTime" label="创建时间">
  428. </el-table-column>
  429. <el-table-column label="操作" fixed='right' width="150">
  430. <template slot-scope="scope">
  431. <el-button size="mini" type="primary" @click="updatefpBtn(scope.row)">修改
  432. </el-button>
  433. <el-button size="mini" type="danger" @click="deletefpBtn(scope.row)">删除
  434. </el-button>
  435. </template>
  436. </el-table-column>
  437. </el-table>
  438. <div style="text-align: center;margin-top: 10px;">
  439. <el-pagination @size-change="handleSizeChangeF" @current-change="handleCurrentChangeF"
  440. :page-sizes="[5, 10, 15, 20]" :page-size="size2" :current-page="page2"
  441. layout="total,sizes, prev, pager, next,jumper" :total="userIds.totalCount">
  442. </el-pagination>
  443. </div>
  444. </el-dialog>
  445. <!-- 添加/修改发票 -->
  446. <el-dialog :title="titlesFp" :visible.sync="dialogFormVisibleFp" center width="70%">
  447. <div style="margin-bottom: 10px;">
  448. <span style="width: 200px;display: inline-block;text-align: right;">发票信息:</span>
  449. <div style="margin-left: 200px;margin-top: 10px;">
  450. <quill-editor ref="myTextEditor" v-model="title" :options="quillOption"
  451. style="padding-bottom: 50px;height: 300px;width: 72%;display: inline-table;margin-bottom: 60px;">
  452. </quill-editor>
  453. </div>
  454. </div>
  455. <!-- <div style="margin-bottom: 10px;">
  456. <span style="width: 200px;display: inline-block;text-align: right;">开票信息:</span>
  457. <el-input v-model="title" style="width:45%;" min="0" placeholder="请输入开票信息">
  458. </el-input>
  459. </div> -->
  460. <div style="margin-bottom: 10px;">
  461. <span style="width: 200px;display: inline-block;text-align: right;">发票金额:</span>
  462. <el-input v-model="money" type="number" style="width:45%;" min="0" placeholder="请输入发票金额"
  463. onkeyup="value=value.replace(/^\D*(\d*(?:\.\d{0,2})?).*$/g, '$1')">
  464. </el-input>
  465. </div>
  466. <div style="margin-bottom: 10px;">
  467. <span style="width: 200px;display: inline-block;text-align: right;">发票内容:</span>
  468. <el-input v-model="content" style="width:45%;" min="0" placeholder="请输入发票内容">
  469. </el-input>
  470. </div>
  471. <div style="margin-bottom: 10px;">
  472. <span style="width: 200px;display: inline-block;text-align: right;">发票类型:</span>
  473. <el-radio-group v-model="invoiceType">
  474. <el-radio :label="1">专票</el-radio>
  475. <el-radio :label="2">普票</el-radio>
  476. </el-radio-group>
  477. </div>
  478. <div style="margin-bottom: 10px;">
  479. <span style="width: 200px;display: inline-block;text-align: right;">发票状态:</span>
  480. <el-radio-group v-model="statusF">
  481. <el-radio :label="1">待开票</el-radio>
  482. <el-radio :label="2">已开票</el-radio>
  483. </el-radio-group>
  484. </div>
  485. <div slot="footer" class="dialog-footer" style="margin-top: 30px;text-align: center;">
  486. <el-button @click="dialogFormVisibleFp=false">取 消</el-button>
  487. <el-button type="primary" @click="fapiaoNoticeTo()">确 定</el-button>
  488. </div>
  489. </el-dialog>
  490. <!-- 查看图片 -->
  491. <el-dialog title="查看图片" :visible.sync="dialogFormVisibleImg" center width="70%">
  492. <div style="width: 100%;">
  493. <img :src="imgUrl" style="width: 100%;" />
  494. </div>
  495. </el-dialog>
  496. </div>
  497. </template>
  498. <script>
  499. import {
  500. quillEditor
  501. } from 'vue-quill-editor'
  502. import 'quill/dist/quill.core.css'
  503. import 'quill/dist/quill.snow.css'
  504. import 'quill/dist/quill.bubble.css'
  505. import quillConfig from '../mission/quill-config.js'
  506. export default {
  507. name: 'news',
  508. components: {
  509. quillEditor
  510. },
  511. data() {
  512. return {
  513. limit: 10,
  514. page: 1,
  515. size1: 10,
  516. page1: 1,
  517. status: 0,
  518. statusT:0,
  519. statesnum: [{
  520. value: 0,
  521. label: '全部'
  522. },
  523. {
  524. value: 1,
  525. label: '待审核'
  526. }, {
  527. value: 2,
  528. label: '已通过'
  529. }, {
  530. value: 3,
  531. label: '已拒绝'
  532. }
  533. ],
  534. classify: '',
  535. userName: '',
  536. tableDataLoading: false,
  537. tableDataLoading4: false,
  538. dialogFormVisible: false,
  539. dialogFormVisibleQ: false,
  540. dialogFormVisibleFp:false,
  541. dialogFormVisible3: false,
  542. dialogFormVisible4: false,
  543. tableData: {},
  544. checkBoxData: [], //多选框选择的值
  545. shopId: '',
  546. companyPhoneT: '',
  547. companyNameT: '',
  548. // 企业字段
  549. titles: '添加',
  550. companyId: '',
  551. companyPhone: '',
  552. companyName: '',
  553. companyAllName: '',
  554. companyLegalPerson: '',
  555. companyCreateTime:'',
  556. companyPeople:'',
  557. companyLogo: '',
  558. companyCertification: [],
  559. companyCertificate: [],
  560. companyDutyParagraph: '',
  561. companyAddress: '',
  562. companyRegisteredFund: '',
  563. email:'',
  564. // companyDetails: '',
  565. companyContent:'',
  566. companyScope: [],
  567. nickName1: '',
  568. percentage: 0, //进度条
  569. percentage1: 0,
  570. percentageQ: 0,
  571. userIds: {},
  572. nickName2: '',
  573. phone1: '',
  574. page2:1,
  575. size2:10,
  576. userId:'',
  577. titlesFp:'添加',
  578. title:'',
  579. content:'',
  580. money:'',
  581. invoiceId:'',
  582. statusF:'',
  583. invoiceType:1,
  584. quillOption: quillConfig,
  585. info: {
  586. stockDate: this.getNowTime(), //日期
  587. },
  588. info2: {
  589. stockDate2: this.getNowTime2(), //日期
  590. },
  591. startTime: '',
  592. endTime: '',
  593. dialogFormVisibleImg:false,
  594. imgUrl:'',
  595. hangyeData: [],
  596. }
  597. },
  598. methods: {
  599. //处理默认选中当前日期
  600. getNowTime() {
  601. var now = new Date()
  602. var year = now.getFullYear() //得到年份
  603. var month = now.getMonth() //得到月份
  604. var date = now.getDate() //得到日期
  605. month = month + 1
  606. month = month.toString().padStart(2, '0')
  607. date = date.toString().padStart(2, '0')
  608. var defaultDate = `${year}-${month}-${date}`
  609. return defaultDate
  610. this.$set(this.info, 'stockDate', defaultDate)
  611. },
  612. //处理默认选中当前日期
  613. getNowTime2() {
  614. var now = new Date()
  615. var year = now.getFullYear() //得到年份
  616. var month = now.getMonth() - now.getMonth() //得到月份
  617. var date = now.getDate() - now.getDate() + 1 //得到日期
  618. month = month + 1
  619. month = month.toString().padStart(2, '0')
  620. date = date.toString().padStart(2, '0')
  621. var defaultDate = `${year}-${month}-${date}`
  622. return defaultDate
  623. this.$set(this.info, 'stockDate', defaultDate)
  624. },
  625. // 多选
  626. changeFun(val) {
  627. this.checkBoxData = val;
  628. },
  629. // 详情跳转
  630. updates(row) {
  631. this.$router.push({
  632. path: '/userDetailQ',
  633. query: {
  634. userId: row.userId
  635. }
  636. })
  637. },
  638. handleSizeChange(val) {
  639. this.limit = val;
  640. this.dataSelect()
  641. },
  642. handleCurrentChange(val) {
  643. this.page = val;
  644. this.dataSelect()
  645. },
  646. handleSizeChange2(val) {
  647. this.size1 = val
  648. this.userClass()
  649. },
  650. handleCurrentChange2(val) {
  651. this.page1 = val
  652. this.userClass()
  653. },
  654. handleSizeChangeF(val) {
  655. this.size2 = val
  656. this.userClass()
  657. },
  658. handleCurrentChangeF(val) {
  659. this.page2 = val
  660. this.userClass()
  661. },
  662. //服务通过
  663. passClick(id) {
  664. this.status = 1
  665. this.content = '同意'
  666. var ids = id ? [id] : this.checkBoxData.map(item => {
  667. return item.id
  668. })
  669. this.$http({
  670. url: this.$http.adornUrl(
  671. `student/auditStudentAuthentication/${ids}/${this.status}/${this.content}`),
  672. method: 'post',
  673. data: this.$http.adornData({})
  674. }).then(({
  675. data
  676. }) => {
  677. if (data.code == 0) {
  678. this.$message({
  679. message: '操作成功',
  680. type: 'success',
  681. duration: 1500,
  682. onClose: () => {
  683. this.content = ''
  684. this.status = ''
  685. this.dataSelect()
  686. }
  687. })
  688. } else {
  689. this.$message({
  690. message: data.msg,
  691. type: 'error',
  692. duration: 1500,
  693. onClose: () => {
  694. this.content = ''
  695. this.status = ''
  696. this.dataSelect()
  697. }
  698. })
  699. }
  700. })
  701. },
  702. //单条服务通过
  703. passClicks(row) {
  704. this.status = 1
  705. this.content = '同意'
  706. this.$http({
  707. url: this.$http.adornUrl('company/auditCompany'),
  708. method: 'post',
  709. params: this.$http.adornParams({
  710. 'status': this.status,
  711. 'ids': row.companyId,
  712. 'content': '通过'
  713. })
  714. }).then(({
  715. data
  716. }) => {
  717. if (data.code == 0) {
  718. this.$message({
  719. message: '操作成功',
  720. type: 'success',
  721. duration: 1500,
  722. onClose: () => {
  723. this.content = ''
  724. this.status = ''
  725. this.dataSelect()
  726. this.dataSelectDsh()
  727. }
  728. })
  729. } else {
  730. this.$message({
  731. message: data.msg,
  732. type: 'error',
  733. duration: 1500,
  734. onClose: () => {
  735. this.content = ''
  736. this.status = ''
  737. this.dataSelect()
  738. }
  739. })
  740. }
  741. })
  742. },
  743. //服务拒绝
  744. refuseClick(rows) {
  745. console.log('rows', rows)
  746. this.status = 2
  747. this.shopId = rows.companyId
  748. this.helpTakeId = rows.userId
  749. this.content = ''
  750. this.dialogFormVisible = true
  751. },
  752. refuseto() {
  753. if (this.content == '') {
  754. this.$notify({
  755. title: '提示',
  756. duration: 1800,
  757. message: '请输入拒绝理由',
  758. type: 'warning'
  759. });
  760. return
  761. }
  762. this.$http({
  763. url: this.$http.adornUrl('company/auditCompany'),
  764. method: 'post',
  765. params: this.$http.adornParams({
  766. 'status': this.status,
  767. 'ids': this.shopId,
  768. 'content': this.content
  769. })
  770. }).then(({
  771. data
  772. }) => {
  773. this.dialogFormVisible = false
  774. if(data.code==0){
  775. this.$message({
  776. message: '操作成功',
  777. type: 'success',
  778. duration: 1500,
  779. onClose: () => {
  780. this.content = ''
  781. this.status = ''
  782. this.dataSelect()
  783. this.dataSelectDsh()
  784. }
  785. })
  786. }else {
  787. this.$message({
  788. message: data.msg,
  789. type: 'error',
  790. duration: 1500,
  791. onClose: () => {
  792. this.content = ''
  793. this.status = ''
  794. this.dataSelect()
  795. }
  796. })
  797. }
  798. })
  799. },
  800. // 查询
  801. select() {
  802. this.page = 1
  803. this.limit = 10
  804. this.dataSelect()
  805. },
  806. // 重置
  807. cleans() {
  808. this.statusT = ''
  809. this.userName = ''
  810. this.companyPhoneT = ''
  811. this.companyNameT = ''
  812. this.startTime = ''
  813. this.endTime = ''
  814. this.dataSelect()
  815. },
  816. // 获取派单数据列表
  817. dataSelect() {
  818. if(this.startTime!=""&&this.startTime !==null){
  819. if (this.endTime == ''||this.endTime ==null) {
  820. this.$notify({
  821. title: '提示',
  822. duration: 1800,
  823. message: '请选择截止时间',
  824. type: 'warning'
  825. });
  826. return
  827. }
  828. }
  829. if(this.endTime!=""&&this.endTime !==null){
  830. if (this.startTime == ''||this.startTime ==null) {
  831. this.$notify({
  832. title: '提示',
  833. duration: 1800,
  834. message: '请选择开始时间',
  835. type: 'warning'
  836. });
  837. return
  838. }
  839. }
  840. this.tableDataLoading = true
  841. this.$http({
  842. url: this.$http.adornUrl('company/selectCompanyList'),
  843. method: 'get',
  844. params: this.$http.adornParams({
  845. 'page': this.page,
  846. 'limit': this.limit,
  847. 'status': this.statusT,
  848. 'userName': this.userName,
  849. 'companyPhone': this.companyPhoneT,
  850. 'companyName': this.companyNameT,
  851. 'startTime': this.startTime,
  852. 'endTime': this.endTime,
  853. })
  854. }).then(({
  855. data
  856. }) => {
  857. this.tableDataLoading = false
  858. if(data.data&&data.data.records.length>0){
  859. for(var i in data.data.records){
  860. var pattern = /^(13[0-9]|14[01456879]|15[0-35-9]|16[2567]|17[0-8]|18[0-9]|19[0-35-9])\d{8}$/
  861. var phone1 = data.data.records[i].phone
  862. var userName1 = data.data.records[i].userName
  863. if(pattern.test(phone1)){
  864. var one = phone1.slice(0, 3)
  865. var two = phone1.slice(7, 11)
  866. data.data.records[i].phone1 = one+'****'+two
  867. }
  868. if(pattern.test(userName1)){
  869. var one = userName1.slice(0, 3)
  870. var two = userName1.slice(7, 11)
  871. data.data.records[i].userName1 = one+'****'+two
  872. }
  873. }
  874. }
  875. this.tableData = data.data
  876. })
  877. },
  878. dataSelectDsh() {
  879. this.$http({
  880. url: this.$http.adornUrl('company/selectCompanyList'),
  881. method: 'get',
  882. params: this.$http.adornParams({
  883. 'page': this.page,
  884. 'limit': this.limit,
  885. 'status': 1,
  886. 'userName': this.userName,
  887. 'companyPhone': this.companyPhoneT,
  888. 'companyName': this.companyNameT
  889. })
  890. }).then(({
  891. data
  892. }) => {
  893. if(data.data){
  894. this.$cookie.set('numberYh', data.data.totalCount)
  895. }
  896. })
  897. },
  898. // 添加
  899. addClick(row) {
  900. if (row) {
  901. this.titles = '修改'
  902. this.companyId = row.companyId
  903. // this.companyPhone = row.companyPhone
  904. this.companyAllName = row.companyAllName
  905. this.companyLegalPerson = row.companyLegalPerson
  906. this.companyCreateTime = row.companyCreateTime
  907. this.companyPeople = row.companyPeople
  908. this.companyLogo = row.companyLogo
  909. if(row.companyCertification){
  910. this.companyCertification = row.companyCertification.split(',')
  911. }
  912. if(row.companyCertificate){
  913. this.companyCertificate = row.companyCertificate.split(',')
  914. }
  915. this.companyDutyParagraph = row.companyDutyParagraph
  916. this.companyAddress = row.companyAddress
  917. this.companyRegisteredFund = row.companyRegisteredFund
  918. this.email = row.email
  919. // this.companyDetails = row.companyDetails
  920. this.companyContent = row.companyContent
  921. if(row.companyScope){
  922. this.companyScope = row.companyScope.split(',')
  923. }
  924. this.nickName1 = row.userName
  925. this.userIdss = row.userId
  926. this.percentage = 100
  927. } else {
  928. this.titles = '添加'
  929. this.companyId = ''
  930. // this.companyPhone = ''
  931. this.companyAllName = ''
  932. this.companyLegalPerson = ''
  933. this.companyCreateTime = ''
  934. this.companyPeople = ''
  935. this.companyLogo = ''
  936. this.companyCertification = []
  937. this.companyCertificate = []
  938. this.companyDutyParagraph = ''
  939. this.companyAddress = ''
  940. this.companyRegisteredFund = ''
  941. this.email = ''
  942. // this.companyDetails = ''
  943. this.companyContent = ''
  944. this.companyScope = []
  945. this.nickName1 = ''
  946. this.nickName2 = ''
  947. this.phone = ''
  948. this.percentage = 100
  949. }
  950. this.hangyeSelect()
  951. this.dialogFormVisibleQ = true
  952. },
  953. // 获取用户列表弹框
  954. userselect() {
  955. this.dialogFormVisible3 = true
  956. this.tableDataLoading4 = true
  957. this.userClass()
  958. },
  959. // 获取用户列表
  960. userClass() {
  961. let phone = -1
  962. if (this.phone) {
  963. phone = this.phone
  964. }
  965. let nickName = -1
  966. if (this.nickName) {
  967. nickName = this.nickName
  968. }
  969. this.$http({
  970. url: this.$http.adornUrl('user/getNotHasCompanyUserList'),
  971. method: 'get',
  972. params: this.$http.adornParams({
  973. 'page': this.page1,
  974. 'limit': this.size1,
  975. 'userName': this.nickName2,
  976. 'phone': this.phone1,
  977. 'isAuthentication': 0
  978. })
  979. }).then(({
  980. data
  981. }) => {
  982. this.tableDataLoading4 = false
  983. let returnData = data.data
  984. this.userIds = returnData
  985. })
  986. },
  987. // 查询用户列表
  988. userclick() {
  989. this.page = 1
  990. this.tableDataLoading4 = true
  991. this.userClass()
  992. },
  993. // 重置用户列表数据
  994. userclose() {
  995. this.phone1 = ''
  996. this.nickName2 = ''
  997. this.tableDataLoading4 = true
  998. this.userClass()
  999. },
  1000. // 确定用户
  1001. confirm(row) {
  1002. this.userIdss = row.userId
  1003. this.nickName1 = row.userName
  1004. this.phone = row.phone
  1005. // if (this.nickName == '' || this.nickName == null) {
  1006. // this.nickName = row.phone
  1007. // }
  1008. this.dialogFormVisible3 = false
  1009. },
  1010. // 封面图片上传
  1011. handleAvatarSuccess5(file) {
  1012. this.companyLogo = file.data;
  1013. },
  1014. onprogress(event, file, fileList) {
  1015. console.log('event, file, fileList', parseInt(event.percent))
  1016. this.percentage = parseInt(event.percent)
  1017. },
  1018. // 封面图片上传
  1019. handleAvatarSuccess1(file) {
  1020. this.gameImg = file.data;
  1021. },
  1022. // 删除
  1023. clear(index) {
  1024. this.companyCertification.splice(index, 1);
  1025. },
  1026. //上传成功
  1027. handleUploadSuccess(file, fileList) {
  1028. this.companyCertification.push(file.data)
  1029. console.log('this.detailsImg', this.companyCertification)
  1030. },
  1031. onprogress1(event, file, fileList) {
  1032. console.log('详情图上传进度', parseInt(event.percent))
  1033. this.percentage1 = parseInt(event.percent)
  1034. },
  1035. // 删除
  1036. clearQ(index) {
  1037. this.companyCertificate.splice(index, 1);
  1038. },
  1039. //上传成功
  1040. handleUploadSuccessQ(file, fileList) {
  1041. this.companyCertificate.push(file.data)
  1042. console.log('this.companyCertificate', this.companyCertificate)
  1043. // this.detailsImg += file.data + ','
  1044. },
  1045. onprogressQ(event, file, fileList) {
  1046. console.log('详情图上传进度', parseInt(event.percent))
  1047. this.percentageQ = parseInt(event.percent)
  1048. },
  1049. // 确定添加
  1050. addmissionNoticeTo() {
  1051. // let photost = this.detailsImg.toString();
  1052. // console.log(this.userIdss, this.gameId, photost)
  1053. if (this.companyLegalPerson == '') {
  1054. this.$notify({
  1055. title: '提示',
  1056. duration: 1800,
  1057. message: '请输入法人姓名',
  1058. type: 'warning'
  1059. });
  1060. return
  1061. }
  1062. if (this.companyAllName == '') {
  1063. this.$notify({
  1064. title: '提示',
  1065. duration: 1800,
  1066. message: '请输入企业名称',
  1067. type: 'warning'
  1068. });
  1069. return
  1070. }
  1071. if (this.userIdss == '') {
  1072. this.$notify({
  1073. title: '提示',
  1074. duration: 1800,
  1075. message: '请选择发布人',
  1076. type: 'warning'
  1077. });
  1078. return
  1079. }
  1080. if (this.companyLogo == '') {
  1081. this.$notify({
  1082. title: '提示',
  1083. duration: 1800,
  1084. message: '请上传企业头像',
  1085. type: 'warning'
  1086. });
  1087. return
  1088. }
  1089. if (this.companyCertification.length == 0) {
  1090. this.$notify({
  1091. title: '提示',
  1092. duration: 1800,
  1093. message: '请上传营业执照',
  1094. type: 'warning'
  1095. });
  1096. return
  1097. }
  1098. if (this.companyPeople == '') {
  1099. this.$notify({
  1100. title: '提示',
  1101. duration: 1800,
  1102. message: '请输入企业规模',
  1103. type: 'warning'
  1104. });
  1105. return
  1106. }
  1107. if (this.companyCreateTime == '') {
  1108. this.$notify({
  1109. title: '提示',
  1110. duration: 1800,
  1111. message: '请选择注册时间',
  1112. type: 'warning'
  1113. });
  1114. return
  1115. }
  1116. if (this.companyScope.length == 0) {
  1117. this.$notify({
  1118. title: '提示',
  1119. duration: 1800,
  1120. message: '请选择经营范围',
  1121. type: 'warning'
  1122. });
  1123. return
  1124. }
  1125. if (this.companyAddress == '') {
  1126. this.$notify({
  1127. title: '提示',
  1128. duration: 1800,
  1129. message: '请输入企业地址',
  1130. type: 'warning'
  1131. });
  1132. return
  1133. }
  1134. if (this.companyRegisteredFund == '') {
  1135. this.$notify({
  1136. title: '提示',
  1137. duration: 1800,
  1138. message: '请输入注册资金',
  1139. type: 'warning'
  1140. });
  1141. return
  1142. }
  1143. if (this.companyContent == '') {
  1144. this.$notify({
  1145. title: '提示',
  1146. duration: 1800,
  1147. message: '请输入企业简介',
  1148. type: 'warning'
  1149. });
  1150. return
  1151. }
  1152. if (this.email == '') {
  1153. this.$notify({
  1154. title: '提示',
  1155. duration: 1800,
  1156. message: '请输入企业邮箱',
  1157. type: 'warning'
  1158. });
  1159. return
  1160. }
  1161. let urls = ''
  1162. if (this.titles == '添加') {
  1163. urls = 'company/insertCompany'
  1164. } else {
  1165. urls = 'company/updateCompany'
  1166. }
  1167. let that = this
  1168. setTimeout(function() {
  1169. that.$http({
  1170. url: that.$http.adornUrl(urls),
  1171. method: 'post',
  1172. data: that.$http.adornData({
  1173. // params: that.$http.adornParams({
  1174. 'companyCertification': that.companyCertification.toString(),
  1175. 'companyCertificate': that.companyCertificate.toString(),
  1176. // 'phone': that.companyPhone,
  1177. 'companyAllName': that.companyAllName,
  1178. 'companyLegalPerson': that.companyLegalPerson,
  1179. 'companyCreateTime':that.companyCreateTime,
  1180. 'companyPeople':that.companyPeople,
  1181. 'companyLogo': that.companyLogo,
  1182. 'companyDutyParagraph': that.companyDutyParagraph,
  1183. 'companyAddress': that.companyAddress,
  1184. 'companyRegisteredFund': that.companyRegisteredFund,
  1185. // 'companyDetails': that.companyDetails,
  1186. 'companyScope': that.companyScope.toString(),
  1187. 'userId': that.userIdss,
  1188. 'companyId': that.companyId,
  1189. 'email':that.email,
  1190. 'companyContent':that.companyContent
  1191. })
  1192. }).then(({
  1193. data
  1194. }) => {
  1195. console.log('提交结果', data)
  1196. if (data.code == 0) {
  1197. that.$message({
  1198. message: '操作成功',
  1199. type: 'success',
  1200. duration: 1500,
  1201. onClose: () => {
  1202. that.dataSelect()
  1203. that.prev()
  1204. }
  1205. })
  1206. } else {
  1207. that.$notify({
  1208. title: '提示',
  1209. duration: 1800,
  1210. message: data.msg,
  1211. type: 'warning'
  1212. });
  1213. }
  1214. })
  1215. }, 1000)
  1216. },
  1217. // 关闭添加信息弹框
  1218. prev() {
  1219. this.dialogFormVisibleQ = false
  1220. this.titles = '添加'
  1221. this.companyId = ''
  1222. this.companyPhone = ''
  1223. this.companyAllName = ''
  1224. this.companyLegalPerson = ''
  1225. this.companyCreateTime = ''
  1226. this.companyPeople = ''
  1227. this.companyLogo = ''
  1228. this.companyCertification = []
  1229. this.companyCertificate = []
  1230. this.companyDutyParagraph = ''
  1231. this.companyAddress = ''
  1232. this.companyRegisteredFund = ''
  1233. this.email = ''
  1234. // this.companyDetails = ''
  1235. this.companyContent = ''
  1236. this.companyScope = ''
  1237. this.nickName1 = ''
  1238. this.nickName2 = ''
  1239. this.phone = ''
  1240. },
  1241. // 删除
  1242. deleteClick(row) {
  1243. this.$confirm(`确定删除此条信息?`, '提示', {
  1244. confirmButtonText: '确定',
  1245. cancelButtonText: '取消',
  1246. type: 'warning'
  1247. }).then(() => {
  1248. this.$http({
  1249. url: this.$http.adornUrl('company/deleteCompany'),
  1250. method: 'post',
  1251. params: this.$http.adornParams({
  1252. 'companyId': row.companyId
  1253. })
  1254. }).then(({
  1255. data
  1256. }) => {
  1257. if (data.code == 0) {
  1258. this.$message({
  1259. message: '删除成功',
  1260. type: 'success',
  1261. duration: 1500,
  1262. onClose: () => {
  1263. this.dataSelect()
  1264. }
  1265. })
  1266. } else {
  1267. this.$notify({
  1268. title: '提示',
  1269. duration: 1800,
  1270. message: data.msg,
  1271. type: 'warning'
  1272. });
  1273. }
  1274. })
  1275. }).catch(() => {})
  1276. },
  1277. // 发票记录按钮
  1278. fapiaoClick(row){
  1279. this.userId = row.userId
  1280. this.companyId = row.companyId
  1281. this.fapiaoList()
  1282. this.dialogFormVisible4 = true
  1283. },
  1284. // 发票记录
  1285. fapiaoList(){
  1286. this.tableDataLoading4 = true
  1287. this.$http({
  1288. url: this.$http.adornUrl('invoice/selectInvoiceList'),
  1289. method: 'get',
  1290. params: this.$http.adornParams({
  1291. 'page': this.page2,
  1292. 'limit': this.size2,
  1293. 'userName': '',
  1294. 'phone': '',
  1295. 'userId': this.userId,
  1296. 'companyName':'',
  1297. 'companyAllName':'',
  1298. 'title':'',
  1299. 'content':'',
  1300. 'status':''
  1301. })
  1302. }).then(({
  1303. data
  1304. }) => {
  1305. this.tableDataLoading4 = false
  1306. let returnData = data.data
  1307. this.userIds = returnData
  1308. })
  1309. },
  1310. addfpClick(){
  1311. this.titlesFp = '添加'
  1312. this.title = ''
  1313. this.content = ''
  1314. this.invoiceType = 1
  1315. this.money = ''
  1316. this.invoiceId = ''
  1317. this.statusF = ''
  1318. this.dialogFormVisibleFp = true
  1319. },
  1320. updatefpBtn(row){
  1321. this.titlesFp = '修改'
  1322. this.title = row.title
  1323. this.content = row.content
  1324. this.money = row.money
  1325. this.invoiceId = row.invoiceId
  1326. this.invoiceType = row.invoiceType
  1327. this.statusF = Number(row.status)
  1328. this.dialogFormVisibleFp = true
  1329. },
  1330. fapiaoNoticeTo(){
  1331. if (this.title == '') {
  1332. this.$notify({
  1333. title: '提示',
  1334. duration: 1800,
  1335. message: '请输入开票信息',
  1336. type: 'warning'
  1337. });
  1338. return
  1339. }
  1340. if (this.content == '') {
  1341. this.$notify({
  1342. title: '提示',
  1343. duration: 1800,
  1344. message: '请输入发票内容',
  1345. type: 'warning'
  1346. });
  1347. return
  1348. }
  1349. if (this.money == '') {
  1350. this.$notify({
  1351. title: '提示',
  1352. duration: 1800,
  1353. message: '请输入发票金额',
  1354. type: 'warning'
  1355. });
  1356. return
  1357. }
  1358. if (this.statusF == '') {
  1359. this.$notify({
  1360. title: '提示',
  1361. duration: 1800,
  1362. message: '请选择发票状态',
  1363. type: 'warning'
  1364. });
  1365. return
  1366. }
  1367. let urls = ''
  1368. if (this.titlesFp == '添加') {
  1369. urls = 'invoice/insertInvoice'
  1370. } else {
  1371. urls = 'invoice/updateInvoice'
  1372. }
  1373. this.$http({
  1374. url: this.$http.adornUrl(urls),
  1375. method: 'post',
  1376. data: this.$http.adornData({
  1377. 'companyId': this.companyId,
  1378. 'title': this.title,
  1379. 'content': this.content,
  1380. 'money': this.money,
  1381. 'invoiceId': this.invoiceId,
  1382. 'status': this.statusF,
  1383. 'invoiceType':this.invoiceType
  1384. })
  1385. }).then(({
  1386. data
  1387. }) => {
  1388. if (data.code == 0) {
  1389. this.$message({
  1390. message: '操作成功',
  1391. type: 'success',
  1392. duration: 1500,
  1393. onClose: () => {
  1394. this.dialogFormVisibleFp = false
  1395. this.fapiaoList()
  1396. }
  1397. })
  1398. } else {
  1399. this.$notify({
  1400. title: '提示',
  1401. duration: 1800,
  1402. message: data.msg,
  1403. type: 'warning'
  1404. });
  1405. }
  1406. })
  1407. },
  1408. deletefpBtn(row){
  1409. this.$confirm(`确定删除此条信息?`, '提示', {
  1410. confirmButtonText: '确定',
  1411. cancelButtonText: '取消',
  1412. type: 'warning'
  1413. }).then(() => {
  1414. this.$http({
  1415. url: this.$http.adornUrl('invoice/deleteInvoice'),
  1416. method: 'post',
  1417. params: this.$http.adornParams({
  1418. 'invoiceId': row.invoiceId
  1419. })
  1420. }).then(({
  1421. data
  1422. }) => {
  1423. if (data.code == 0) {
  1424. this.$message({
  1425. message: '删除成功',
  1426. type: 'success',
  1427. duration: 1500,
  1428. onClose: () => {
  1429. this.fapiaoList()
  1430. }
  1431. })
  1432. } else {
  1433. this.$notify({
  1434. title: '提示',
  1435. duration: 1800,
  1436. message: data.msg,
  1437. type: 'warning'
  1438. });
  1439. }
  1440. })
  1441. }).catch(() => {})
  1442. },
  1443. // 导出
  1444. exportBtn() {
  1445. var endTime=this.endTime
  1446. if(this.endTime!=''){
  1447. endTime=this.endTime+" 23:59:59"
  1448. }
  1449. this.$http({
  1450. url: this.$http.adornUrl('company/exportExcelCompanyList'),
  1451. method: 'get',
  1452. responseType: 'blob',
  1453. params: this.$http.adornParams({
  1454. // 'page': page,
  1455. // 'size': this.size,
  1456. 'status': this.statusT,
  1457. 'userName': this.userName,
  1458. 'companyPhone': this.companyPhoneT,
  1459. 'companyName': this.companyAllName,
  1460. 'startTime': this.startTime,
  1461. 'endTime': this.endTime,
  1462. })
  1463. }).then(({
  1464. data
  1465. }) => {
  1466. let blob = new Blob([data], {
  1467. type: 'application/vnd.ms-excel,application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'
  1468. })
  1469. if (window.navigator.msSaveOrOpenBlob) {
  1470. navigator.msSaveBlob(blob)
  1471. } else {
  1472. let url = window.URL.createObjectURL(blob)
  1473. let elink = document.createElement('a')
  1474. elink.download = '企业列表.xlsx'
  1475. elink.style.display = 'none'
  1476. elink.href = url
  1477. document.body.appendChild(elink)
  1478. elink.click()
  1479. document.body.removeChild(elink)
  1480. }
  1481. })
  1482. },
  1483. // 查看图片
  1484. lookBtn(row){
  1485. this.imgUrl = row
  1486. this.dialogFormVisibleImg = true
  1487. },
  1488. // 获取一级行业数据
  1489. hangyeSelect() {
  1490. this.$http({
  1491. url: this.$http.adornUrl('admin/industry/getIndustryList'),
  1492. method: 'get',
  1493. params: this.$http.adornParams({
  1494. 'isEnable': 1
  1495. // 'page': this.page,
  1496. // 'limit': this.limit,
  1497. // 'industryName':'',
  1498. })
  1499. }).then(({
  1500. data
  1501. }) => {
  1502. if (data.code == 0) {
  1503. this.tableDataLoading = false
  1504. let returnData = data.data
  1505. this.hangyeData = returnData
  1506. } else {
  1507. this.$notify({
  1508. title: '提示',
  1509. duration: 1800,
  1510. message: data.msg,
  1511. type: 'warning'
  1512. });
  1513. }
  1514. })
  1515. },
  1516. // 清空经营范围
  1517. qungkong(){
  1518. this.companyScope = []
  1519. },
  1520. },
  1521. mounted() {
  1522. var statusN = this.$route.query.status
  1523. if(statusN){
  1524. this.status = statusN
  1525. }else{
  1526. this.status = 0
  1527. }
  1528. this.dataSelect()
  1529. }
  1530. };
  1531. </script>
  1532. <style>
  1533. .imgs {
  1534. position: relative;
  1535. border-radius: 6px;
  1536. width: 148px;
  1537. height: 148px;
  1538. margin-right: 10px;
  1539. display: inline-block;
  1540. /* margin: 0 20px; */
  1541. }
  1542. .dels {
  1543. position: absolute;
  1544. top: 0;
  1545. left: 0;
  1546. display: none;
  1547. }
  1548. .dels .el-icon-delete {
  1549. /* line-height: 148px; */
  1550. /* padding-left: 58px; */
  1551. font-size: 15px;
  1552. color: #fff;
  1553. position: relative;
  1554. bottom: 10px;
  1555. left: 140px;
  1556. background: #999;
  1557. padding: 5px;
  1558. border-radius: 50%;
  1559. }
  1560. .imgs:hover .dels {
  1561. /* width: 100%;
  1562. height: 100%; */
  1563. /* background: #000; */
  1564. display: block;
  1565. opacity: 0.5;
  1566. }
  1567. </style>