Commit 08077bb6fe1227c7d440527064ca957d6289ccab

Authored by weixin_45529955
1 parent b61ba2d4

修改职级 OK

... ... @@ -55,6 +55,11 @@ class Constant {
'管理员',
'店长',
],
'修改职级': [
'管理员',
'店长',
],
'员工管理': [
'管理员',
'店长',
... ...
class SellerRoleModel {
int? ret;
List<SellerRoleSunModel>? data;
String? msg;
SellerRoleModel({this.ret, this.data, this.msg});
SellerRoleModel.fromJson(Map<dynamic, dynamic> json) {
ret = json['ret'];
if (json['data'] != null) {
data = <SellerRoleSunModel>[];
json['data'].forEach((v) {
data!.add(new SellerRoleSunModel.fromJson(v));
});
}
msg = json['msg'];
}
Map<String, dynamic> toJson() {
final Map<String, dynamic> data = new Map<String, dynamic>();
data['ret'] = this.ret;
if (this.data != null) {
data['data'] = this.data!.map((v) => v.toJson()).toList();
}
data['msg'] = this.msg;
return data;
}
}
class SellerRoleSunModel {
String? id;
String? sellerid;
String? roleName;
String? roleAliasName;
String? roleType;
String? status;
String? cdate;
String? level;
SellerRoleSunModel(
{this.id,
this.sellerid,
this.roleName,
this.roleAliasName,
this.roleType,
this.status,
this.cdate,
this.level});
SellerRoleSunModel.fromJson(Map<String, dynamic> json) {
id = json['id'];
sellerid = json['sellerid'];
roleName = json['role_name'];
roleAliasName = json['role_alias_name'];
roleType = json['role_type'];
status = json['status'];
cdate = json['cdate'];
level = json['level'];
}
Map<String, dynamic> toJson() {
final Map<String, dynamic> data = new Map<String, dynamic>();
data['id'] = this.id;
data['sellerid'] = this.sellerid;
data['role_name'] = this.roleName;
data['role_alias_name'] = this.roleAliasName;
data['role_type'] = this.roleType;
data['status'] = this.status;
data['cdate'] = this.cdate;
data['level'] = this.level;
return data;
}
}
... ...
... ... @@ -611,53 +611,33 @@ class HttpUrl {
static const discount_pay_refund_apply =
"?service=App.PayOnline.DiscountPayRefundApply"; // 优惠支付订单退款
static const set_activity_config =
static const set_activity_config =
"?service=App.Activity.SetActivityConfig"; // 设置商家券赠送规则配置
static const get_activity_config =
"?service=App.Activity.GetActivityConfig"; // 获取商家券赠送规则配置
static const applyments=
"?service=App.PayOnline.Applyments"; // 二级商户进件
static const applyments = "?service=App.PayOnline.Applyments"; // 二级商户进件
static const upLoad_applyments=
static const upLoad_applyments =
"?service=App.PayOnline.UpLoadApplyments"; // 上传身份证、营业执照图片
static const get_reserve_deposit_order_list=
static const get_reserve_deposit_order_list =
"?service=App.Reserve.GetReserveDepositOrderList"; // 获取商家定金订单列表
static const get_reserve_deposit_order=
static const get_reserve_deposit_order =
"?service=App.Reserve.GetReserveDepositOrder"; // 获取商家定金订单详情
static const get_order_recharge_list=
static const get_order_recharge_list =
"?service=App.Activity.GetOrderRechargeList"; // 获取会员储值支付订单列表
static const get_order_recharge_order_info=
static const get_order_recharge_order_info =
"?service=App.Activity.GetOrderRechargeOrderInfo"; //通过支付订单号或退款订单号获取会员充值订单
static const recharge_refund_apply=
static const recharge_refund_apply =
"?service=App.PayOnline.RechargeRefundApply"; // 新版购买优惠券退款(会员充值退款)
static const get_seller_hide_conf=
static const get_seller_hide_conf =
"?service=App.Seller.GetSellerHideConf"; // 获取商家隐藏订单日期配置列表
static const get_seller_role_list =
"?service=App.Seller.GetSellerRoleList"; // 获取商家角色列表
}
... ...
import 'dart:async';
import 'dart:convert';
... ... @@ -7,9 +6,11 @@ import 'package:common_utils/common_utils.dart';
import 'package:dio/dio.dart';
import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:one_key/app.dart';
import 'package:one_key/constant/state.dart';
import 'package:one_key/models/get_seller_info_model.dart';
import 'package:one_key/models/personnel_manage_model.dart';
import 'package:one_key/models/user.dart';
import 'package:one_key/net/dio_util.dart';
import 'package:one_key/provider/personnel_provider.dart';
import 'package:one_key/provider/store_wine_provider.dart';
... ... @@ -57,13 +58,19 @@ class _PersonnelDetailPageState extends State<PersonnelDetailPage> {
bool isall = false;
bool isbook = false;
bool isserver = false;
String? position = '';
@override
void initState() {
super.initState();
position = widget.position;
WidgetsBinding.instance.addPostFrameCallback((timeStamp) {
_getSellerUserBySellerid();
_getAuthUserLists();
_getSellerRoleList();
EventBus().on('personnel_manage_detail_page', (arg) {
_getAuthUserLists(showLoading: false);
});
... ... @@ -74,9 +81,9 @@ class _PersonnelDetailPageState extends State<PersonnelDetailPage> {
// if (roleNameLogin == '管理员') {
// canEdit = true;
// } else if (roleNameLogin == '店长') {
// if (widget.position == '管理员') {
// if (position == '管理员') {
// canEdit = false;
// } else if (widget.position == '店长') {
// } else if (position == '店长') {
// if (accountLogin == data.account) {
// print('11111');
// //店长自己
... ... @@ -144,6 +151,16 @@ class _PersonnelDetailPageState extends State<PersonnelDetailPage> {
// }
}
_getSellerRoleList({bool showLoading = true}) async {
Map<String, String?> params = {
"sellerid": Provider.of<UserModel>(context, listen: false).user!.sellerid,
"sid": Provider.of<UserModel>(context, listen: false).user!.sellerid,
};
await personnelProvider.getSellerRoleList(context, params,
showLoading: showLoading);
}
//获取员工信息列表
_getAuthUserLists({bool showLoading = true}) async {
Map<String, String?> params = {
... ... @@ -153,19 +170,19 @@ class _PersonnelDetailPageState extends State<PersonnelDetailPage> {
await personnelProvider.getAuthUserLists(context, params,
showLoading: showLoading);
if (personnelProvider.dataMap != null) {
if (widget.position == '管理员') {
if (position == '管理员') {
data = personnelProvider.dataMap!.admin!.listdata![widget.index!];
} else if (widget.position == '店长') {
} else if (position == '店长') {
data = personnelProvider.dataMap!.shopowner!.listdata![widget.index!];
} else if (widget.position == '客户经理') {
} else if (position == '客户经理') {
data = personnelProvider.dataMap!.manager!.listdata![widget.index!];
} else if (widget.position == '收银员') {
} else if (position == '收银员') {
data = personnelProvider.dataMap!.cashier!.listdata![widget.index!];
} else if (widget.position == '服务员') {
} else if (position == '服务员') {
data = personnelProvider.dataMap!.waiter!.listdata![widget.index!];
} else if (widget.position == '前台') {
} else if (position == '前台') {
data = personnelProvider.dataMap!.reception!.listdata![widget.index!];
} else if (widget.position == '迎宾') {
} else if (position == '迎宾') {
data = personnelProvider.dataMap!.welcome!.listdata![widget.index!];
}
if (data!.accountType == null || data!.accountType == '1') {
... ... @@ -178,8 +195,9 @@ class _PersonnelDetailPageState extends State<PersonnelDetailPage> {
nickName = data!.nickName != null && data!.nickName != 'null'
? data!.nickName
: '暂未设置名称';
phone =
data!.phone != null && data!.userName != 'null' ? data!.phone : '添加手机号';
phone = data!.phone != null && data!.userName != 'null'
? data!.phone
: '添加手机号';
if (data!.openid == null || data!.openid == 'null') {
// _getStoreBaseinfo();
_getWechatQrcode();
... ... @@ -222,23 +240,40 @@ class _PersonnelDetailPageState extends State<PersonnelDetailPage> {
if (success) {
//删除员工成功
EventBus().emit('personnel_manage_page');
if (Navigator.canPop(context)) {
Navigator.pop(context);
}
if (Navigator.canPop(context)) {
Navigator.pop(context);
}
}
}
///编辑店员
_editAuthUser(String name, {bool showLoading = true}) async {
Map<String, String?> params = {'id': data!.id, 'user_name': name};
_editAuthUser(String roleId, {bool showLoading = true}) async {
Map<String, String?> params = {'id': data!.id, 'role_id': roleId};
bool success = await personnelProvider.editAuthUser(context, params,
showLoading: showLoading);
if (success) {
EventBus().emit('personnel_manage_page');
setState(() {
nickName = name;
int index = personnelProvider.roleList!
.indexWhere((element) => element.id == roleId);
position = personnelProvider.roleList![index].roleName;
//当前页面的角色展示刷新,我的页面取值从缓存,刷新缓存
});
UserModel userModel = Provider.of<UserModel>(context, listen: false);
if (data?.id == userModel.user!.openid) {
//如果修改的是本人的话,需要刷新缓存,我的页面会显示缓存的数据
if (App.sp!.containsKey('user')) {
String s = App.sp!.getString('user')!;
User _user = User.fromJson(json.decode(s));
_user.role_name_addition = position;
await UserModel().saveUserInfo(_user);
}
}
}
}
... ... @@ -399,12 +434,15 @@ class _PersonnelDetailPageState extends State<PersonnelDetailPage> {
'uid': data!.id,
'account_type': accountType
};
bool success = await personnelProvider.setSellerUserAccountType(context, params);
if(success && accountType == '3' && data!.id == Provider.of<UserModel>(context,listen: false).user!.openid){
//把自己设置成只服不订人员,需要跳转到已预订页面
NavigatorUtil.goHomePage(context,initialIndex: 1);
}
bool success =
await personnelProvider.setSellerUserAccountType(context, params);
if (success &&
accountType == '3' &&
data!.id ==
Provider.of<UserModel>(context, listen: false).user!.openid) {
//把自己设置成只服不订人员,需要跳转到已预订页面
NavigatorUtil.goHomePage(context, initialIndex: 1);
}
}
@override
... ... @@ -421,8 +459,8 @@ class _PersonnelDetailPageState extends State<PersonnelDetailPage> {
appBar: SystemAppBar(
'员工详情',
onTap: () {
if (Navigator.canPop(context)) {
Navigator.pop(context);
if (Navigator.canPop(context)) {
Navigator.pop(context);
}
},
),
... ... @@ -474,7 +512,7 @@ class _PersonnelDetailPageState extends State<PersonnelDetailPage> {
radius: ScreenUtil().setWidth(26 * 2),
onPressed: () {
NavigatorUtil.goPersonnalBaseInfoPage(
context, data, widget.position!);
context, data, position!);
}),
),
Column(
... ... @@ -517,7 +555,7 @@ class _PersonnelDetailPageState extends State<PersonnelDetailPage> {
textColor: MyColours.color_ffffff,
radius: ScreenUtil().setWidth(10),
onPressed: () {}),
Text('${widget.position} 工号: ${data?.account}',
Text('${position} 工号: ${data?.account}',
style: TextStyle(
color: MyColours.color_515151,
fontSize: ScreenUtil().setSp(28),
... ... @@ -563,82 +601,84 @@ class _PersonnelDetailPageState extends State<PersonnelDetailPage> {
],
),
VEmptyView(56),
if(widget.position != '管理员') Container(
height: w(84),
padding:
EdgeInsets.symmetric(horizontal: w(20), vertical: w(12)),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(
'预订与服务权限',
style: TextStyle(
fontSize: font(16), color: MyColours.color_515151),
),
VEmptyView(24),
Container(
height: w(24),
child: Row(
children: [
HEmptyView(32),
_itemRadioWidget(isall, '预订及服务', onTap: () {
if (Utils.getAuthority(context, '设置服务人员')) {
if (!isall) {
setState(() {
isall = true;
isbook = false;
isserver = false;
});
_setSellerUserAccountType('1');
if (position != '管理员')
Container(
height: w(84),
padding:
EdgeInsets.symmetric(horizontal: w(20), vertical: w(12)),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(
'预订与服务权限',
style: TextStyle(
fontSize: font(16), color: MyColours.color_515151),
),
VEmptyView(24),
Container(
height: w(24),
child: Row(
children: [
HEmptyView(32),
_itemRadioWidget(isall, '预订及服务', onTap: () {
if (Utils.getAuthority(context, '设置服务人员')) {
if (!isall) {
setState(() {
isall = true;
isbook = false;
isserver = false;
});
_setSellerUserAccountType('1');
}
} else {
Utils.showToast('您没有相关权限权限');
}
} else {
Utils.showToast('您没有相关权限权限');
}
}),
Spacer(),
_itemRadioWidget(isbook, '只订不服', onTap: () {
if (Utils.getAuthority(context, '设置服务人员')) {
if (!isbook) {
setState(() {
isbook = true;
isall = false;
isserver = false;
});
_setSellerUserAccountType('2');
}),
Spacer(),
_itemRadioWidget(isbook, '只订不服', onTap: () {
if (Utils.getAuthority(context, '设置服务人员')) {
if (!isbook) {
setState(() {
isbook = true;
isall = false;
isserver = false;
});
_setSellerUserAccountType('2');
}
} else {
Utils.showToast('您没有相关权限权限');
}
} else {
Utils.showToast('您没有相关权限权限');
}
}),
Spacer(),
_itemRadioWidget(isserver, '只服不订', onTap: () {
if (Utils.getAuthority(context, '设置服务人员')) {
if (!isserver) {
setState(() {
isserver = true;
isall = false;
isbook = false;
});
_setSellerUserAccountType('3');
}),
Spacer(),
_itemRadioWidget(isserver, '只服不订', onTap: () {
if (Utils.getAuthority(context, '设置服务人员')) {
if (!isserver) {
setState(() {
isserver = true;
isall = false;
isbook = false;
});
_setSellerUserAccountType('3');
}
} else {
Utils.showToast('您没有相关权限权限');
}
} else {
Utils.showToast('您没有相关权限权限');
}
}),
HEmptyView(30),
],
),
)
],
}),
HEmptyView(30),
],
),
)
],
),
),
),
if(widget.position != '管理员') Padding(
padding: EdgeInsets.only(left: w(20), right: w(16)),
child: MyDivider(double.infinity, w(1),
color: MyColours.color_DBDBDB)),
if (position != '管理员')
Padding(
padding: EdgeInsets.only(left: w(20), right: w(16)),
child: MyDivider(double.infinity, w(1),
color: MyColours.color_DBDBDB)),
VEmptyView(32),
(data?.openid == null || data?.openid == 'null')
... ... @@ -694,6 +734,32 @@ class _PersonnelDetailPageState extends State<PersonnelDetailPage> {
color: MyColours.color_438E93,
fontSize: ScreenUtil().setSp(28)),
)),
if (Utils.getAuthority(context, '修改职级')) VEmptyView(48),
if (Utils.getAuthority(context, '修改职级'))
InkWell(
onTap: () async {
if (personnelProvider.roleList == null ||
personnelProvider.roleList?.length == 0) {
//没有角色数据
await _getSellerRoleList();
}
await DialogUtil.changeRoleDialog(
context, personnelProvider.roleList, position ?? '',
onTap: (map) {
print(map);
String? roleId = map['role'];
if (roleId != null) {
_editAuthUser(roleId);
}
});
},
child: Text(
'修改职级',
style: TextStyle(
decoration: TextDecoration.underline,
color: MyColours.color_438E93,
fontSize: ScreenUtil().setSp(28)),
)),
VEmptyView(40),
// (userModel.user.role_name == '管理员' ||
... ... @@ -844,7 +910,7 @@ class _PersonnelDetailPageState extends State<PersonnelDetailPage> {
// ),
// HEmptyView(20),
// Text(
// widget.position,
// position,
// style: TextStyle(
// fontSize: ScreenUtil().setWidth(28),
// color: MyColours.color_199095),
... ... @@ -868,7 +934,7 @@ class _PersonnelDetailPageState extends State<PersonnelDetailPage> {
],
),
)),
if (widget.position != '管理员')
if (position != '管理员')
InkWell(
onTap: () async {
await DialogUtil.removePersonnalDialog(
... ...
... ... @@ -7,6 +7,7 @@ import 'package:one_key/models/filter_btn_model.dart';
import 'package:one_key/models/get_seller_info_model.dart';
import 'package:one_key/models/get_seller_user_by_sellerid_model.dart';
import 'package:one_key/models/personnel_manage_model.dart';
import 'package:one_key/models/seller_role_model.dart';
import 'package:one_key/net/base_resp.dart';
import 'package:one_key/net/dio_util.dart';
... ... @@ -27,6 +28,8 @@ class PersonnelProvider extends ChangeNotifier {
int? manageSelIndex; //当前选中
List<SellerUserAccountTypeSunModel>? serverList = []; //服务人员
List<SellerRoleSunModel>? roleList = [];
/// 设置账号服务类型
Future<bool> setSellerUserAccountType(
BuildContext context, Map<String, String?> params,
... ... @@ -117,6 +120,27 @@ class PersonnelProvider extends ChangeNotifier {
}
}
/// 获取角色列表
getSellerRoleList(BuildContext context, Map<String, String?> params,
{showLoading = false}) async {
try {
BaseResp<dynamic> baseResp = await DioUtil().request<dynamic>(
context, Method.post, HttpUrl.get_seller_role_list,
data: params, showLoading: showLoading);
if (baseResp != null && baseResp.code == Constant.status_success) {
roleList = SellerRoleModel.fromJson(baseResp.responseData!).data ?? [];
} else {
Utils.showToast(baseResp.msg ?? "");
}
notifyListeners();
return roleList;
} catch (error) {
print(error.toString());
}
return [];
}
/// 获取店员列表
getAuthUserLists(BuildContext context, Map<String, String?> params,
{showLoading = false}) async {
... ... @@ -133,9 +157,7 @@ class PersonnelProvider extends ChangeNotifier {
tempData[keyTemp] = {'listdata': value, 'role_id': role_id};
});
baseResp.responseData!['data'] = tempData;
dataMap = PersonnelManageModel.fromJson(
baseResp.responseData!)
.data;
dataMap = PersonnelManageModel.fromJson(baseResp.responseData!).data;
dataMap!.admin!.hasWechatNum = 0;
dataMap!.admin!.listdata!.forEach((item) {
// for (PersonnelManageSunModel item in dataMap!.admin!.listdata!) {
... ... @@ -220,8 +242,7 @@ class PersonnelProvider extends ChangeNotifier {
}
/// 添加店员
Future<bool> addSellerClerk(
BuildContext context, Map<String, String?> params,
Future<bool> addSellerClerk(BuildContext context, Map<String, String?> params,
{showLoading = false}) async {
try {
BaseResp<dynamic> baseResp = await DioUtil().request<dynamic>(
... ... @@ -242,8 +263,7 @@ class PersonnelProvider extends ChangeNotifier {
}
/// 删除店员
Future<bool> delSellerClerk(
BuildContext context, Map<String, String?> params,
Future<bool> delSellerClerk(BuildContext context, Map<String, String?> params,
{showLoading = false}) async {
try {
BaseResp<dynamic> baseResp = await DioUtil().request<dynamic>(
... ... @@ -343,8 +363,7 @@ class PersonnelProvider extends ChangeNotifier {
}
/// 设置商家接单人
Future<bool> setUserIsCall(
BuildContext context, Map<String, String?> params,
Future<bool> setUserIsCall(BuildContext context, Map<String, String?> params,
{showLoading = false}) async {
try {
BaseResp<dynamic> baseResp = await DioUtil().request<dynamic>(
... ... @@ -383,8 +402,7 @@ class PersonnelProvider extends ChangeNotifier {
}
/// 员工密码修改
Future<bool> updatePassword(
BuildContext context, Map<String, String?> params,
Future<bool> updatePassword(BuildContext context, Map<String, String?> params,
{showLoading = false}) async {
try {
BaseResp<dynamic> baseResp = await DioUtil().request<dynamic>(
... ...
... ... @@ -16,6 +16,7 @@ import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:one_key/constant/constant.dart';
import 'package:one_key/models/filter_btn_model.dart';
import 'package:one_key/models/remark.dart';
import 'package:one_key/models/seller_role_model.dart';
import 'package:one_key/models/table_list.dart';
import 'package:one_key/pages/message/message_dialog_item.dart';
import 'package:one_key/pages/message/message_dialog_item_f.dart';
... ... @@ -2530,6 +2531,195 @@ class DialogUtil {
});
}
static Future changeRoleDialog(BuildContext context,
List<SellerRoleSunModel>? roleList, String roleNameCurr,
{CustomCallBackMap? onTap}) async {
int currentIndex = 0;
if (roleNameCurr != '') {
// 存在角色数据
currentIndex =
roleList!.indexWhere((element) => element.roleName == roleNameCurr);
}
String? roleName = roleList?[currentIndex].roleName;
final action = await showDialog(
context: context,
barrierDismissible: false,
builder: (BuildContext context) {
return
// Scaffold(
// resizeToAvoidBottomInset: false,
// backgroundColor: Colors.transparent,
// body:
Center(child: StatefulBuilder(builder: (context, state) {
// globalState = state;
return Material(
color: Colors.transparent,
child: Stack(
clipBehavior: Clip.none,
children: [
Container(
margin:
EdgeInsets.only(bottom: ScreenUtil().setWidth(150)),
padding: EdgeInsets.symmetric(
horizontal: ScreenUtil().setWidth(40)),
// height: ScreenUtil().setWidth(238 * 2),
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(
ScreenUtil().setWidth(16))),
child: Card(
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.all(Radius.circular(
ScreenUtil().setWidth(16)))), //设置圆角
child: Column(
mainAxisSize: MainAxisSize.min,
children: [
VEmptyView(64),
Container(
height: ScreenUtil().setWidth(48),
alignment: Alignment.center,
child: Text('修改职级',
style: TextStyle(
fontWeight: FontWeight.bold,
fontSize: ScreenUtil().setSp(32),
color: Color.fromRGBO(0, 0, 0, 0.9))),
),
VEmptyView(40),
// Text('移除员工并把该员工的客户',
// style: TextStyle(
// fontSize: ScreenUtil().setSp(32),
// color: Color.fromRGBO(0, 0, 0, 0.6))),
VEmptyView(36),
Row(
mainAxisAlignment:
MainAxisAlignment.spaceBetween,
children: [
HEmptyView(56),
Text('将当前员工修改为',
style: TextStyle(
fontSize: ScreenUtil().setSp(28),
color: MyColours.color_515151)),
HEmptyView(32),
InkWell(
onTap: () {
List<String?> list = [];
for (SellerRoleSunModel item
in roleList!) {
list.add(item.roleName);
}
DialogUtil.showSelectCusmanDialog(
context, list, (value) async {
if (value != null) {
currentIndex = value.first;
roleName = list[value.first];
state(() {});
}
},
selecteds: currentIndex == null
? []
: [currentIndex])
.then((value) {});
},
child: Container(
padding: EdgeInsets.symmetric(
vertical: ScreenUtil().setWidth(16),
horizontal:
ScreenUtil().setWidth(24)),
width: ScreenUtil().setWidth(138 * 2),
height: ScreenUtil().setWidth(40 * 2),
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(
ScreenUtil().setWidth(20)),
border: Border.all(
color: MyColours.color_438E93,
width:
ScreenUtil().setWidth(2))),
child: Row(
crossAxisAlignment:
CrossAxisAlignment.center,
children: [
Expanded(
child: Text(
roleName ?? '',
maxLines: 1,
textAlign: TextAlign.center,
overflow: TextOverflow.ellipsis,
style: TextStyle(
fontSize:
ScreenUtil().setSp(28),
color:
MyColours.color_438E93),
)),
HEmptyView(14),
Image.asset(
Utils.getImgPath(
'c_arrow_down'),
width:
ScreenUtil().setWidth(20)),
],
),
)),
HEmptyView(56),
],
),
VEmptyView(40),
MyDivider(
double.infinity, ScreenUtil().setWidth(2),
color: MyColours.color_f3f3f3),
Row(
// mainAxisAlignment:
// MainAxisAlignment.spaceBetween,
children: [
RoundButton(
text: '取消',
width: (ScreenUtil().screenWidth -
ScreenUtil().setWidth(62) * 2) /
2,
height: ScreenUtil().setWidth(112),
// radius: ScreenUtil().setWidth(10),
gradientStart: Colors.transparent,
gradientEnd: Colors.transparent,
textColor: MyColours.color_000000,
isBold: false,
fontSize: 28,
onPressed: () {
if (Navigator.canPop(context)) {
Navigator.pop(context);
}
}),
MyDivider(ScreenUtil().setWidth(2),
ScreenUtil().setWidth(112),
color: MyColours.color_f3f3f3),
RoundButton(
text: '确定',
width: (ScreenUtil().screenWidth -
ScreenUtil().setWidth(62) * 2) /
2,
height: ScreenUtil().setWidth(112),
// radius: ScreenUtil().setWidth(10),
gradientStart: Colors.transparent,
gradientEnd: Colors.transparent,
textColor: MyColours.color_438E93,
fontSize: 28,
onPressed: () {
onTap!({
'role': roleList![currentIndex].id,
});
if (Navigator.canPop(context)) {
Navigator.pop(context);
}
}),
])
],
),
)),
],
));
}));
});
}
static Future removePersonnalDialog(
BuildContext context, List<FilterBtnModel> managerList,
{CustomCallBackMap? onTap}) async {
... ...
This diff could not be displayed because it is too large.