小编ZaI*_*hAn的帖子

在ng build index.html在控制台中出现错误后,Angular 6

我遇到问题,请帮助我解决此问题。问题是当我ng build在CLI中执行操作时,转到dist文件夹并运行index.html文件,以便控制台获取文件路径错误。

Failed to load resource: net::ERR_FILE_NOT_FOUND
polyfills.js:1 Failed to load resource: net::ERR_FILE_NOT_FOUND
styles.js:1 Failed to load resource: net::ERR_FILE_NOT_FOUND
scripts.js:1 Failed to load resource: net::ERR_FILE_NOT_FOUND
vendor.js:1 Failed to load resource: net::ERR_FILE_NOT_FOUND
main.js:1 Failed to load resource: net::ERR_FILE_NOT_FOUND
/D:/favicon.ico:1 Failed to load resource: net::ERR_FILE_NOT_FOUND
Run Code Online (Sandbox Code Playgroud)

console.log angular-cli angular ng-build angular-builder

6
推荐指数
1
解决办法
2409
查看次数

React Native中具有相同功能名称的多个组件

我使用react-native-material-menu'spopup来显示菜单选项。

但问题是,它不适用于多种场景。

我的意思是,当我单击第一个菜单按钮时,会触发相同的方法,因此每次都会打开相同的菜单。

处理这种特殊情况的更好方法应该是什么。

 _menu = null;

 setMenuRef = ref => {
     this._menu = ref;
 };

 hideMenu = () => {
     this._menu.hide();
 };

 showMenu = () => {
     this._menu.show();
 };


  <FlatList
      data={this.state.clientsList}
      renderItem={({ item }) => {
      return (
          <View style={styles.caseItem} >
              <Card style={styles.card}>
                  <CardItem>
                     <Body>
                        <View style={styles.rowTitle}>
                           <Text style={styles.title}>{item.FullName}</Text>
                           <Menu
                                ref={this.setMenuRef}
                                button={
                                   <Icon 
                                        type="Feather" 
                                        name="more-vertical" 
                                        onPress={this.showMenu} 
                                           style{{fontSize:20,color:'#555'}} 
                                     />
                             }>
                                <MenuItem onPress={this.hideMenu}>View</MenuItem>
                                <MenuItem onPress={this.hideMenu}>Edit</MenuItem>
                                <MenuItem onPress={this.hideMenu}>Delete </MenuItem>
                            </Menu>
                        </View>

                        <View>
                            <Text style={styles.lbl}>Email: <Text style={styles.lblValue}>{item.EmailID}</Text></Text>
                            <Text style={styles.lbl}>Client …
Run Code Online (Sandbox Code Playgroud)

javascript react-native

6
推荐指数
1
解决办法
680
查看次数

在 Docker 容器 Django 中使用 Pip 安装软件包时权限被拒绝

我无法在我的 docker 容器中安装该软件包,请让我知道如何解决这个问题。

警告:

警告:当前用户不拥有或不可写入目录“/home/app/.cache/pip”或其父目录。缓存已被禁用。检查该目录的权限和所有者。如果使用 sudo 执行 pip,则应该使用 sudo 的 -H 标志。

错误:

ERROR: Could not install packages due to an OSError: [Errno 13] Permission denied: '/home/app'
Check the permissions.
Run Code Online (Sandbox Code Playgroud)

Dockerfile:

FROM python:3
ENV PYTHONDONTWRITEBYTECODE=1
ENV PYTHONUNBUFFERED=1

WORKDIR /app
EXPOSE 8000

COPY ./core/ /app/
COPY ./scripts /scripts

RUN pip install --upgrade pip
COPY requirements.txt /app/
RUN pip install -r requirements.txt && \
    adduser --disabled-password --no-create-home app && \
    mkdir -p /vol/web/static && \
    mkdir -p /vol/web/media && \
    chown -R …
Run Code Online (Sandbox Code Playgroud)

python django ubuntu pip docker

4
推荐指数
1
解决办法
8049
查看次数

使用 Gmail 与 Django 发送电子邮件不起作用

我是 Django 新手,我想使用我的 Gmail 帐户通过 Django 服务器发送电子邮件,但不幸的是,即使我已正确输入所有凭据,我在发送电子邮件时仍遇到错误,但我的 Gmail 中还有一件事帐户是“不太安全的应用程序”,必须启用,但此功能在 Gmail 中不再可用,那么现在我如何在 Django 中发送电子邮件?

error while sending the email

b'5.7.8 Username and Password not accepted. Learn more at\n5.7.8  https://support.google.com/mail/?p=BadCredentials f14-20020a05600c4e8e00b0039c5642e430sm4688852wmq.20 - gsmtp'
Run Code Online (Sandbox Code Playgroud)

django gmail smtplib

2
推荐指数
1
解决办法
2428
查看次数