基础库
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

17 line
463 B

  1. import 'package:zhiying_comm/models/base/base_setting_model.dart';
  2. class ImageUtil {
  3. // 拼接链接
  4. static String getUrl(String originUrl) {
  5. if (originUrl.startsWith('http://') || originUrl.startsWith('https://')) {
  6. return originUrl;
  7. }
  8. BaseSettingModel setting = BaseSettingModel.setting;
  9. return (setting?.fileBucketHostProtocol ?? '') +
  10. '://' +
  11. (setting?.fileBucketHost ?? '') +
  12. '/' +
  13. originUrl;
  14. }
  15. }