我使用WindowsXP下system.I混帐的bash尝试输入"CD G:"进入我的U盘在git的庆典,但它apears说:"sh.exe:CD:摹::没有这样的文件或目录".
我可以在我的系统下打开我的USB磁盘.
这有什么问题?我该如何解决这个问题?
我知道代码"git rm"可以从git存储库中删除文件,但它也会从muy计算机中删除该文件.
是否有方法从git存储库中删除文件而不从我的计算机中删除文件?
我有一个实体,有一个数组类型属性:productKey.I尝试添加一个选择typy到表单来显示productKeys,我写了代码:
1.my formType:
public function buildForm(FormBuilder $builder, array $options)
{
$builder
->add('heading','text',array('label'=>'title'))
->add('productKey','choice',array(
'required'=>TRUE,
'label'=>'choose your product',
));
}
Run Code Online (Sandbox Code Playgroud)
2.在我的Product实体中,productKey被定义为:
/**
* @var array $productKey
*
* @ORM\Column(name="productKey", type="array",nullable=true)
*/
private $productKey;
Run Code Online (Sandbox Code Playgroud)
3.在我的控制器中:
$entity = new Product();
$productKey = array("1"=>"one","2"=>"two","3"=>"three");
$entity ->setProductKey($productKey);
$formType = new TicketType($productKey);
$form = $this->createForm($formType,$entity);
return array(
'form'=>$form->createView(),
'entity'=>$entity
);
Run Code Online (Sandbox Code Playgroud)
当我运行我的项目时,无法列出productKey的值!它只是出现一个空的选择chice输入.我怎么解决呢?