<template>
	<view>
		<view class="user" v-for="item in users" :key="item.code">
			<text class="title">账户 {{item.account}}</text>

			<view class="content">
				<text>密码：{{item.password}}</text>
				<text>角色：{{item.roleFlag}}</text>
				<text>电话：{{item.phone}}</text>
			</view>
		</view>


	</view>
</template>

<script>
	export default {
		data() {
			return {
				users: [],
			}
		},
		onLoad() {
			uni.request({
				url: 'http://127.0.0.1:9999/user/list',
				method: 'GET',
				data: {},
				success: res => {

					this.users = res.data.data.users;
					console.log(res.data.data.users);
				},

			})
		},
		methods: {

		}
	}
</script>

<style>
	.anniu {
		width: 116rpx;
		height: 116rpx;
		float: right;
		margin-top: 10rpx;
		margin-right: 4rpx;
	}

	.user {
		width: 702rpx;
		height: 280rpx;
		background-color: white;
		margin-top: 30rpx;
		margin-left: 24rpx;
		border-radius: 10rpx;
		padding-top: 30rpx;
	}

	.content {
		display: flex;
		flex-direction: column;
		margin-top: 30rpx;
		margin-left: 30rpx;
		line-height: 55rpx;
		font-size: 28rpx;
		color: #444546;
	}

	.title {
		font-size: 36rpx;
		margin-left: 30rpx;
		color: #282828;
		font-weight: 600;
	}
</style>
