| | |
| | | window.localStorage.setItem('id', row.id) |
| | | |
| | | } |
| | | |
| | | function closeDialog(row) { |
| | | add.value = false; |
| | | userName.value = ''; |
| | | nickName.value = ''; |
| | | password.value = ''; |
| | | selectedProjectNoa.value = ''; |
| | | } |
| | | function closeDialoga(row) { |
| | | adda.value = false; |
| | | userName.value = ''; |
| | | nickName.value = ''; |
| | | password.value = ''; |
| | | } |
| | | // 添加 |
| | | const getTableRow = async () => { |
| | | try { |
| | |
| | | tableData.value = response.data; |
| | | } else { |
| | | // 请求失败,显示错误消息 |
| | | ElMessage.error(response.msg); |
| | | ElMessage.error(response.message); |
| | | } |
| | | } catch (error) { |
| | | // 处理错误 |
| | |
| | | <el-button type="primary" style="margin-top: 10px;margin-left: 10px;" size="mini" id="searchButton" @click="add = true">{{ $t('productStock.addusers') }}</el-button> |
| | | <el-card style="flex: 1;margin-left: 10px;margin-top: 20px;" v-loading="loading"> |
| | | <div style="width: 98%; height: calc(100% - 35px); overflow-y: auto;"> |
| | | <el-table height="240" ref="table" |
| | | <el-table height="500" ref="table" |
| | | @selection-change="handleSelectionChange" |
| | | :data="tableData" :header-cell-style="{background:'#F2F3F5 ',color:'#1D2129'}"> |
| | | <el-table-column prop="userName" align="center" :label="$t('productStock.username')" min-width="180" /> |
| | |
| | | <el-button type="primary" @click="getTableRow"> |
| | | {{ $t('productStock.sure') }} |
| | | </el-button> |
| | | <el-button @click="add = false">{{ $t('productStock.cancel') }}</el-button> |
| | | <el-button @click="closeDialog">{{ $t('productStock.cancel') }}</el-button> |
| | | </div> |
| | | </template> |
| | | </el-dialog> |
| | |
| | | <el-button type="primary" @click="getTableRowa"> |
| | | {{ $t('productStock.sure') }} |
| | | </el-button> |
| | | <el-button @click="adda = false">{{ $t('productStock.cancel') }}</el-button> |
| | | <el-button @click="closeDialoga">{{ $t('productStock.cancel') }}</el-button> |
| | | </div> |
| | | </template> |
| | | </el-dialog> |