|
|
@@ -0,0 +1,194 @@
|
|
|
+<template>
|
|
|
+ <view class="app-main app-content">
|
|
|
+ <view class="list-wrap role-list">
|
|
|
+ <block v-if="!$util.isEmpty(colorList)">
|
|
|
+ <view class="list" v-for="(item, index) in colorList" :key="index">
|
|
|
+ <view class="app-size-32" @click="changeColor(item)" style="width:700upx;">{{ item.name }}</view>
|
|
|
+ </view>
|
|
|
+ </block>
|
|
|
+ <block v-else>
|
|
|
+ <app-wrapper-empty title="暂无数据" :is-empty="$util.isEmpty(colorList)" />
|
|
|
+ </block>
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+</template>
|
|
|
+<script>
|
|
|
+import AppAvatarModule from '@/components/module/app-avatar'
|
|
|
+import AppWrapperEmpty from '@/components/app-wrapper-empty'
|
|
|
+import ModalModule from '@/components/plugin/modal'
|
|
|
+import AppSearchModule from "@/components/module/app-search";
|
|
|
+import { getColorList } from "@/api/item"
|
|
|
+import { mapGetters } from "vuex"
|
|
|
+export default {
|
|
|
+ name: 'colorManage',
|
|
|
+ components: {
|
|
|
+ AppAvatarModule,
|
|
|
+ AppWrapperEmpty,
|
|
|
+ ModalModule,
|
|
|
+ AppSearchModule
|
|
|
+ },
|
|
|
+ mixins: [],
|
|
|
+ data() {
|
|
|
+ return {
|
|
|
+ colorList:[]
|
|
|
+ }
|
|
|
+ },
|
|
|
+ computed: {
|
|
|
+ ...mapGetters({ loginInfo: "getLoginInfo" }),
|
|
|
+ },
|
|
|
+ methods: {
|
|
|
+ async init() {
|
|
|
+ this.getItemList()
|
|
|
+ },
|
|
|
+ getItemList() {
|
|
|
+ getColorList().then(res => {
|
|
|
+ if(res.code == 1){
|
|
|
+ this.colorList = res.data.list
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ changeColor(item){
|
|
|
+ this.$util.pageTo({url: "/admin/item/xjSelect?itemId="+item.id,type:2})
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+</script>
|
|
|
+<style lang="scss" scoped>
|
|
|
+ .app-content {
|
|
|
+ padding-bottom:50upx;
|
|
|
+ }
|
|
|
+ .input-wrap_box {
|
|
|
+ background-color: #fff;
|
|
|
+ position: fixed;
|
|
|
+ top: 0;
|
|
|
+ z-index: 10;
|
|
|
+ /* 手机mobile屏幕小于1000px */
|
|
|
+ @media screen and (max-width: 1100px) {
|
|
|
+ width: 100%;
|
|
|
+ }
|
|
|
+ /* 收银台cashier屏幕大于1000px */
|
|
|
+ @media screen and (min-width:1100px) {
|
|
|
+ width: 40%;
|
|
|
+ }
|
|
|
+ height: 100upx;
|
|
|
+ display: flex;
|
|
|
+ align-items: center;
|
|
|
+ padding: 0 30upx;
|
|
|
+ & > view:nth-child(1) {
|
|
|
+ flex: 1;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ // 列表公共
|
|
|
+ .list-wrap {
|
|
|
+ background-color: #fff;
|
|
|
+ margin-top:0upx;
|
|
|
+ .list {
|
|
|
+ @include disFlex(center, flex-start);
|
|
|
+ margin: 0 30upx;
|
|
|
+ padding: 30upx 0;
|
|
|
+ border-bottom: 2upx solid $borderColor;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ // 员工列表
|
|
|
+ .staff-list {
|
|
|
+ .list-det {
|
|
|
+ width: calc(100% - 110upx);
|
|
|
+ color: $fontColor3;
|
|
|
+ margin-left: 20upx;
|
|
|
+ @include disFlex(center, space-between);
|
|
|
+ .list-det-left {
|
|
|
+ .staff-name {
|
|
|
+ color: #333;
|
|
|
+ font-size: 30upx;
|
|
|
+ font-weight: 600;
|
|
|
+ margin-right: 10upx;
|
|
|
+ display: inline-block;
|
|
|
+ overflow: hidden;
|
|
|
+ text-overflow:ellipsis;
|
|
|
+ white-space: nowrap;
|
|
|
+ width:150upx;
|
|
|
+ }
|
|
|
+ .flex-center {
|
|
|
+ margin-top: 10upx;
|
|
|
+ }
|
|
|
+ .status-list {
|
|
|
+ margin-left: 25upx;
|
|
|
+ &:first-child {
|
|
|
+ margin-left: 0;
|
|
|
+ }
|
|
|
+ .iconfont {
|
|
|
+ // color: $fontColor3;
|
|
|
+ font-size: 24upx;
|
|
|
+ margin-right: 10upx;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ .list-det-right {
|
|
|
+ @include disFlex(center, flex-start);
|
|
|
+ & > div {
|
|
|
+ margin-left: 50upx;
|
|
|
+ &:first-child {
|
|
|
+ margin-left: 0;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ .iconfont {
|
|
|
+ font-size: 36upx;
|
|
|
+ color: $fontColor3;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ // 角色管理
|
|
|
+ .role-list {
|
|
|
+ .list {
|
|
|
+ justify-content: space-between;
|
|
|
+ }
|
|
|
+ .role-option {
|
|
|
+ @include disFlex(center, flex-start);
|
|
|
+ & > div {
|
|
|
+ margin-left: 50upx;
|
|
|
+ &:first-child {
|
|
|
+ margin-left: 0;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ .iconfont {
|
|
|
+ font-size: 36upx;
|
|
|
+ color: $fontColor3;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ // 操作记录
|
|
|
+ .axis-wrap {
|
|
|
+ position: relative;
|
|
|
+ padding: 30upx 30upx 30upx 40upx;
|
|
|
+ background-color: #fff;
|
|
|
+ .axis-list {
|
|
|
+ &:last-child .axis-det {
|
|
|
+ margin-bottom: 0;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ .axis-title {
|
|
|
+ font-size: 30upx;
|
|
|
+ font-weight: 600;
|
|
|
+ margin-bottom: 14upx;
|
|
|
+ }
|
|
|
+ .axis-det {
|
|
|
+ color: $fontColor2;
|
|
|
+ margin-bottom: 40upx;
|
|
|
+ & > div {
|
|
|
+ margin-top: 6upx;
|
|
|
+ &:first-child {
|
|
|
+ margin-top: 0;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ // 按钮
|
|
|
+ .app-footer {
|
|
|
+ justify-content: flex-end;
|
|
|
+ .admin-button-com {
|
|
|
+ width: 160upx;
|
|
|
+ margin-right: 30upx;
|
|
|
+ }
|
|
|
+ }
|
|
|
+</style>
|